[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190802131440.GC27223@krava>
Date: Fri, 2 Aug 2019 15:14:40 +0200
From: Jiri Olsa <jolsa@...hat.com>
To: Vince Weaver <vincent.weaver@...ne.edu>
Cc: linux-kernel@...r.kernel.org,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Namhyung Kim <namhyung@...nel.org>,
Adrian Hunter <adrian.hunter@...el.com>,
Andi Kleen <ak@...ux.intel.com>,
Chong Jiang <chongjiang@...omium.org>,
Simon Que <sque@...omium.org>
Subject: Re: [patch] perf.data documentation clarify HEADER_SAMPLE_TOPOLOGY
format
On Thu, Aug 01, 2019 at 02:30:43PM -0400, Vince Weaver wrote:
>
> The perf.data file format documentation for HEADER_SAMPLE_TOPOLOGY
> specifies the layout in a confusing manner that doesn't match the rest of
> the document. This patch attempts to describe things consistent with the
> rest of the file.
>
> Signed-off-by: Vince Weaver <vincent.weaver@...ne.edu>
>
> diff --git a/tools/perf/Documentation/perf.data-file-format.txt b/tools/perf/Documentation/perf.data-file-format.txt
> index 5f54feb19977..6a7dceaae709 100644
> --- a/tools/perf/Documentation/perf.data-file-format.txt
> +++ b/tools/perf/Documentation/perf.data-file-format.txt
> @@ -298,16 +298,21 @@ Physical memory map and its node assignments.
>
> The format of data in MEM_TOPOLOGY is as follows:
>
> - 0 - version | for future changes
> - 8 - block_size_bytes | /sys/devices/system/memory/block_size_bytes
> - 16 - count | number of nodes
> -
> -For each node we store map of physical indexes:
> -
> - 32 - node id | node index
> - 40 - size | size of bitmap
> - 48 - bitmap | bitmap of memory indexes that belongs to node
> - | /sys/devices/system/node/node<NODE>/memory<INDEX>
> + u64 version; // Currently 1
> + u64 block_size_bytes; // /sys/devices/system/memory/block_size_bytes
> + u64 count; // number of nodes
> +
> +struct memory_node {
> + u64 node_id; // node index
> + u64 size; // size of bitmap
> + struct bitmap {
> + /* size of bitmap again */
> + u64 bitmapsize;
> + /* bitmap of memory indexes that belongs to node */
> + /* /sys/devices/system/node/node<NODE>/memory<INDEX> */
> + u64 entries[(bitmapsize/64)+1];
> + }
> +}[count];
Acked-by: Jiri Olsa <jolsa@...nel.org>
thanks for doing this,
jirka
>
> The MEM_TOPOLOGY can be displayed with following command:
>
Powered by blists - more mailing lists