From: Jiri Olsa <jolsa@redhat.com>
To: Tan Xiaojun <tanxiaojun@huawei.com>
Cc: peterz@infradead.org, mingo@redhat.com, acme@kernel.org,
alexander.shishkin@linux.intel.com, namhyung@kernel.org,
songliubraving@fb.com, rostedt@goodmis.org,
kan.liang@linux.intel.com, tz.stoyanov@gmail.com,
alexey.budankov@linux.intel.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] perf record: Support aarch64 random socket_id assignment
Date: Fri, 2 Aug 2019 15:09:26 +0200 [thread overview]
Message-ID: <20190802130926.GB27223@krava> (raw)
In-Reply-To: <1564717737-21602-1-git-send-email-tanxiaojun@huawei.com>
On Fri, Aug 02, 2019 at 11:48:57AM +0800, Tan Xiaojun wrote:
> Same as the commit 01766229533f ("perf record: Support s390 random
> socket_id assignment"), aarch64 also have this problem.
>
> Without this fix:
> [root@localhost perf]# ./perf report --header -I -v
> ...
> socket_id number is too big.You may need to upgrade the perf tool.
>
> # ========
> # captured on : Thu Aug 1 22:58:38 2019
> # header version : 1
> ...
> # Core ID and Socket ID information is not available
> ...
>
> With this fix:
> [root@localhost perf]# ./perf report --header -I -v
> ...
> cpumask list: 0-31
> cpumask list: 32-63
> cpumask list: 64-95
> cpumask list: 96-127
>
> # ========
> # captured on : Thu Aug 1 22:58:38 2019
> # header version : 1
> ...
> # CPU 0: Core ID 0, Socket ID 36
> # CPU 1: Core ID 1, Socket ID 36
> ...
> # CPU 126: Core ID 126, Socket ID 8442
> # CPU 127: Core ID 127, Socket ID 8442
> ...
>
> Signed-off-by: Tan Xiaojun <tanxiaojun@huawei.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
thanks,
jirka
> ---
> tools/perf/util/header.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/tools/perf/util/header.c b/tools/perf/util/header.c
> index 20111f8..d57fb74 100644
> --- a/tools/perf/util/header.c
> +++ b/tools/perf/util/header.c
> @@ -2251,8 +2251,10 @@ static int process_cpu_topology(struct feat_fd *ff, void *data __maybe_unused)
> /* On s390 the socket_id number is not related to the numbers of cpus.
> * The socket_id number might be higher than the numbers of cpus.
> * This depends on the configuration.
> + * AArch64 is the same.
> */
> - if (ph->env.arch && !strncmp(ph->env.arch, "s390", 4))
> + if (ph->env.arch && (!strncmp(ph->env.arch, "s390", 4)
> + || !strncmp(ph->env.arch, "aarch64", 7)))
> do_core_id_test = false;
>
> for (i = 0; i < (u32)cpu_nr; i++) {
> --
> 2.7.4
>
next prev parent reply other threads:[~2019-08-02 13:09 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-02 3:48 [PATCH] perf record: Support aarch64 random socket_id assignment Tan Xiaojun
2019-08-02 13:09 ` Jiri Olsa [this message]
2019-08-13 14:23 ` Arnaldo Carvalho de Melo
2019-08-15 9:35 ` [tip:perf/core] " tip-bot for Tan Xiaojun
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190802130926.GB27223@krava \
--to=jolsa@redhat.com \
--cc=acme@kernel.org \
--cc=alexander.shishkin@linux.intel.com \
--cc=alexey.budankov@linux.intel.com \
--cc=kan.liang@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=songliubraving@fb.com \
--cc=tanxiaojun@huawei.com \
--cc=tz.stoyanov@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.