]> git.baikalelectronics.ru Git - kernel.git/commit
perf bench numa: Fix cpu0 binding
authorJiri Olsa <jolsa@kernel.org>
Thu, 1 Aug 2019 14:26:42 +0000 (16:26 +0200)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 1 Aug 2019 14:34:13 +0000 (11:34 -0300)
commitc163a25a419f8ff34dfdda6e206746edc3034946
tree6d850ce7c6a7bd5f4e82c5953f05211efd89e1be
parent7b2dde91f81fff6a6f4204f0ccc5533475be9be6
perf bench numa: Fix cpu0 binding

Michael reported an issue with perf bench numa failing with binding to
cpu0 with '-0' option.

  # perf bench numa mem -p 3 -t 1 -P 512 -s 100 -zZcm0 --thp 1 -M 1 -ddd
  # Running 'numa/mem' benchmark:

   # Running main, "perf bench numa numa-mem -p 3 -t 1 -P 512 -s 100 -zZcm0 --thp 1 -M 1 -ddd"
  binding to node 0, mask: 0000000000000001 => -1
  perf: bench/numa.c:356: bind_to_memnode: Assertion `!(ret)' failed.
  Aborted (core dumped)

This happens when the cpu0 is not part of node0, which is the benchmark
assumption and we can see that's not the case for some powerpc servers.

Using correct node for cpu0 binding.

Reported-by: Michael Petlan <mpetlan@redhat.com>
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Satheesh Rajendran <sathnaga@linux.vnet.ibm.com>
Link: http://lkml.kernel.org/r/20190801142642.28004-1-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/bench/numa.c