Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp3033365imj; Mon, 11 Feb 2019 12:39:15 -0800 (PST) X-Google-Smtp-Source: AHgI3IZVTYTX9ju9CAmTKN6KQU9ZLQYxh4ZsPxPE2ua4fMvR4CfBCeZ252+2Bqu2V/OJRGvbC+zD X-Received: by 2002:a65:64d9:: with SMTP id t25mr113602pgv.244.1549917555783; Mon, 11 Feb 2019 12:39:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549917555; cv=none; d=google.com; s=arc-20160816; b=tIcF/G4UY4jdA3OjsxVd4v33O1KSMNRCy8VF70NegZXCLhtyM82zWyPIT3NlVhis8F Ckdlg/H3duCYQe5lKoR398C2ca7IlgmfzJqZCeETjRjRRQQ2bAo7O6omGOULZO5ilGMz T0jsNoWCkfgOODqolwURU3gqMBowQw9AEInrLVBEgqnr+YezWvGW+gOQcq+CWzIKp8k4 PLyvCxQIsslYa7MhOoFl0deALU3wkOb7uW0FhPEljeroD+i7jK5+GSbhRcJFKl/bL8tW 3SVSqbMCFd/3PioHF1WYxIeBae2aOkhjdvrE+5cv3zbRZZERIXYn1QYX5g/F+h9nETKt ZMgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=8v5rXm2mbK57fE9mGZjp881pWNsrUC5UsBR5Fm6c7Ks=; b=vUQbN+JCByNjHGvtGDS2WRXxvBqLwhrXYi8plGtfxzvLpb7PPKnt87Pk2L1Dwm+qGh ASOv6BHOpYXMZNou2aKpbb7g3IDvbu14KX/wMm9Le1y2GhUHTTwq4fHjadlFci+nmTRa 2moNJYLgybFjCSWD9tY8Tg1cELKRiAK3v+af10Dnfb6rYJ3OrPH+7yrmccbxPfj4uB4l 0icdlsF0AUb9udsik59eMksQFeH5ZeNPdYxzSt9/PLKm9DFQ1Kr0PohJpNNv4oqn0X6E QhQpb/yDEXq6EvZw21SjO6vKFFen1f1NR1+11FIvotPpix4+k2h2Yvl9+cZ+bMwSqbUl Olyw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=CE1tTZvh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 33si11066957plt.228.2019.02.11.12.38.59; Mon, 11 Feb 2019 12:39:15 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=CE1tTZvh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732605AbfBKSef (ORCPT + 99 others); Mon, 11 Feb 2019 13:34:35 -0500 Received: from mail-ua1-f68.google.com ([209.85.222.68]:42089 "EHLO mail-ua1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732388AbfBKSe3 (ORCPT ); Mon, 11 Feb 2019 13:34:29 -0500 Received: by mail-ua1-f68.google.com with SMTP id d21so3750086uap.9 for ; Mon, 11 Feb 2019 10:34:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=8v5rXm2mbK57fE9mGZjp881pWNsrUC5UsBR5Fm6c7Ks=; b=CE1tTZvhs5KOt+Wwzp3OUQeK1wDhENGndtldlTcgSt6BWVou+3afyDDvqlPv9cWlvC i3TpqYRyxxrPv9k/SaLPXDs4lq2+7JuJR4VRBxKh74VUgInn6dCHNOLmswU5+mLf8Fy3 g6M9nMJWaec4+qhGzCdQ2NpvpQRPtDBWDTCNFlG8pLjDCNprId9mWT8Z70vVOQO4wBKj hvImSDjQM6DY2Jd6Y76Q1OTCcFGLaccVCfdqMqmovQuVkq1YeG0Anhiqy6zZDKY/AcE0 iEh7vJUwfeGAlIWbXy3xP20QNg4aFJbWT6HkIV5eXUoY6W7VlnlcYd4/MutXpeMpIHdR csQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=8v5rXm2mbK57fE9mGZjp881pWNsrUC5UsBR5Fm6c7Ks=; b=dY93nIJdBdEHb/TPhrmILkAFWr9EP68yuhHdKOUvIHtJRUqoQ5BxMHy7dL6M5vTax+ FYze9oGdI4VmIXKWisXoWTD+TTduyG46eceaXuWfFHwgoOO4cWRCMBaAbeMsfSYdA4W6 hafLVrceZXvmMmpdM7JhVIC7d0vfWIR0mQwrMlzteJgHI1RCZfBpeuzcdkwWgyaXCt2C QNgieHuGDmdX3erBUlUkhRRkC1OayfY9KofPSHWflsUafOGe8tEqlOHnCRfftk53pEUF rrDpG0e0WwEUGWFVVQpPmbLPmM20rvZ92jdVXFcPZw3Dcbv7FSDdvUjYR0lMXSgJbgGd IJzw== X-Gm-Message-State: AHQUAuYFTGwu/g35gk0Jf69C3MMY7dCPtTdXlz1qqwfdnQSZg4I8NqZq e/2TYHDuhzZfRfDlKqAQK/lgFNPLWf5MzxbQf4pGSQ== X-Received: by 2002:ab0:73c4:: with SMTP id m4mr15318574uaq.101.1549910068070; Mon, 11 Feb 2019 10:34:28 -0800 (PST) MIME-Version: 1.0 References: <8d8b3f0d-cea8-2daf-249f-29f485c49a46@linux.intel.com> <20190204103643.GA18141@krava> <6bf24b7d-2bd3-8091-cf49-363c91e4e864@linux.intel.com> <20190204114144.GC18141@krava> <20190204192721.GI5593@kernel.org> <20190204202818.GC4794@krava> <20190205133727.GF4794@krava> <20190211101957.GB14253@krava> In-Reply-To: <20190211101957.GB14253@krava> From: Stephane Eranian Date: Mon, 11 Feb 2019 10:34:16 -0800 Message-ID: Subject: Re: [RFC/PATCH 00/14] perf record: Add support to store data in directory To: Jiri Olsa Cc: Arnaldo Carvalho de Melo , Alexey Budankov , Jiri Olsa , lkml , Ingo Molnar , Namhyung Kim , Alexander Shishkin , Peter Zijlstra , Adrian Hunter , Andi Kleen Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Jiri, On Mon, Feb 11, 2019 at 2:20 AM Jiri Olsa wrote: > > On Tue, Feb 05, 2019 at 02:37:27PM +0100, Jiri Olsa wrote: > > On Mon, Feb 04, 2019 at 02:44:37PM -0800, Stephane Eranian wrote: > > > Jiri, > > > > > > While you're looking at the output format, I think it would be good > > > time to simplify the code handling perf.data file. > > > Today, perf record can emit in two formats: file mode or pipe mode. > > > This adds complexity in the code and > > > is error prone as the file mode path is tested more than the pipe mode > > > path. We have run into multiple issues with > > > the pipe mode in recent years. There is no real reason why we need to > > > maintain two formats. If I recall, the pipe format > > > was introduced because on pipes you cannot lseek to update the headers > > > and therefore some of the information present as tables > > > updated on the fly needed to be generated as pseudo records by the > > > tool. I believe that the pipe format covers all the needs and could > > > supersede the file mode format. That would simplify code in perf > > > record and eliminate the risk of errors when new headers > > > are introduced. > > > > yep, I think we have almost all the features covered for pipe mode, > > and we have all necessary events to describe events features > > > > so with some effort we could switch off the superfluos file header > > and use only events to describe events ;-) make sense, I'll check > > on it > > so following features are not synthesized: > > FEAT_OPN(TRACING_DATA, tracing_data, false), > FEAT_OPN(BUILD_ID, build_id, false), > FEAT_OPN(BRANCH_STACK, branch_stack, false), > FEAT_OPN(AUXTRACE, auxtrace, false), > FEAT_OPN(STAT, stat, false), > FEAT_OPN(CACHE, cache, true), > What do you need for BRANCH_STACK? > I think all could be added and worked around with exception > of BUILD_ID, which we store at the end (after processing > all data) and we need it early in the report phase > Buildids are injected after the fact via perf inject when in pipe mode. > maybe it's time to re-think that buildid -> mmap event > association again, because it's pain in current implementation > as well > Sure, but what do you propose? > looks like bpf code is actualy getting build ids and storing > it for the callchains in kernel.. we can check if we can do > something similar for mmap events > > jirka