Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp1811543imj; Sun, 17 Feb 2019 15:24:39 -0800 (PST) X-Google-Smtp-Source: AHgI3IZbVfVq2w2GmWXQ25Xtnngvs5Hj4nXdlP9j+aLPh9c76URPci5Eyb/I18EVNLDkUiv0TS5t X-Received: by 2002:a63:1204:: with SMTP id h4mr19913667pgl.51.1550445879678; Sun, 17 Feb 2019 15:24:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550445879; cv=none; d=google.com; s=arc-20160816; b=unH/M7yNprl0/plZCF+7b0LBc12Mu+fOOtv4UoLVt3hiJL+ssyIKMvhSR2M4wyOVDz k1in7BdCnmCLjzmoKl5filFzln2x6qp/gO2ES8UH4LYrlXneXpbsVgkT2rVPmGZKu3hA 84bPmLthoRxgGxfSaeAWpOSmXNQSPRWVBE0x5cMn707WrG3wxEvrZQEHT4LJnByutCSU lShpfdR6+v8Bw8YcAeeQmsltK4D6PXivgbbDzSu0D8pwLOM7s00FXWyMIZv9ixd7ejWy rC24mXq+R7LgIPdl5yDxbTnPt1HIuXwZwmLvxy+Gza9i0smm+b7SBYCh15VhUB8IdVe3 7pQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=I9/5oLeaR7lZorPm7l25sGp10t4lofT2AirGGiJHylw=; b=IXIaf5OWrZb9NLoEneIURuDkcMaaayPgLyzDwsqfRPvcBAaNhlCBTX4IAKb0erG5AS eKnwdCiuy5Ic7FRrXBhF7AWP5KDJk5C2CgdWoT3wUp2W699HEw7+KQt0qXvXbwK6rj70 0gUZd/yefWHSgXPLrNO1prICvlHgPNJ2jnSbXEcpin2/ukt3AYjMOCn2LQBSTzSf+sXN ELpgOTr7hSo6hpHoUmS5LbmMQYfUiQmOJgFdEIrUNdxFxlf4/2XBYPL3vpNKvucL0d2I jLIfd60MIX+/8ijhYRMVmeEtyJ0e9GHIhZWTU1vKY51kLEgCGvbMWktEWGym/S2rUJVx +oUg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d17si10827727pgp.274.2019.02.17.15.24.22; Sun, 17 Feb 2019 15:24:39 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727250AbfBQXWx (ORCPT + 99 others); Sun, 17 Feb 2019 18:22:53 -0500 Received: from mx1.redhat.com ([209.132.183.28]:55088 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726283AbfBQXWw (ORCPT ); Sun, 17 Feb 2019 18:22:52 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D36BA7DCF3; Sun, 17 Feb 2019 23:22:51 +0000 (UTC) Received: from krava (ovpn-204-33.brq.redhat.com [10.40.204.33]) by smtp.corp.redhat.com (Postfix) with SMTP id 4C4E560BF7; Sun, 17 Feb 2019 23:22:46 +0000 (UTC) Date: Mon, 18 Feb 2019 00:22:46 +0100 From: Jiri Olsa To: Jonas Rabenstein Cc: linux-perf-users@vger.kernel.org, Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Alexander Shishkin , Namhyung Kim , Andi Kleen , Thomas Richter , Stephane Eranian , linux-kernel@vger.kernel.org Subject: Re: [PATCH] perf: update perf.data file format documentation Message-ID: <20190217232246.GB26460@krava> References: <20190215182823.303-1-jonas.rabenstein@studium.uni-erlangen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190215182823.303-1-jonas.rabenstein@studium.uni-erlangen.de> User-Agent: Mutt/1.10.1 (2018-07-13) X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Sun, 17 Feb 2019 23:22:52 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 15, 2019 at 07:28:23PM +0100, Jonas Rabenstein wrote: > I found that the documentation of the flags section is some how > different from the actual format used and expected by the perf > tools. In this patch the according section of the file format > documentation is updated to conform to the expectations of the > perf tool suite. > > Signed-off-by: Jonas Rabenstein > --- > .../perf/Documentation/perf.data-file-format.txt | 15 ++++++--------- > 1 file changed, 6 insertions(+), 9 deletions(-) > > diff --git a/tools/perf/Documentation/perf.data-file-format.txt b/tools/perf/Documentation/perf.data-file-format.txt > index dfb218feaad9..6ea199f28330 100644 > --- a/tools/perf/Documentation/perf.data-file-format.txt > +++ b/tools/perf/Documentation/perf.data-file-format.txt > @@ -43,13 +43,10 @@ struct perf_file_section { > > Flags section: > > -The header is followed by different optional headers, described by the bits set > -in flags. Only headers for which the bit is set are included. Each header > -consists of a perf_file_section located after the initial header. > -The respective perf_file_section points to the data of the additional > -header and defines its size. > - > -Some headers consist of strings, which are defined like this: > +The Flags section is placed directly after the data section and consists of a > +variable amount of information described by the flags-bitset in the perf_header. > +A lot of the headers in the Flags section are simple strings and are represented > +like this: some how I find this more confusing.. please describe what's actualy wrong with the current wording > > struct perf_header_string { > uint32_t len; > @@ -82,7 +79,7 @@ assigned by the linker to an executable. > struct build_id_event { > struct perf_event_header header; > pid_t pid; > - uint8_t build_id[24]; > + uint8_t build_id[PERF_ALIGN(24, sizeof(u64))]; isn't that always 24? I guess u meant: build_id[PERF_ALIGN(20, sizeof(u64))]; > char filename[header.size - offsetof(struct build_id_event, filename)]; > }; > > @@ -131,7 +128,7 @@ An uint64_t with the total memory in bytes. > > HEADER_CMDLINE = 11, > > -A perf_header_string with the perf command line used to collect the data. > +A perf_header_string_list with the perf arg-vector used to collect the data. nice catch thanks, jirka > > HEADER_EVENT_DESC = 12, > > -- > 2.17.1 >