perf offcpu: Parse process id separately
authorNamhyung Kim <namhyung@kernel.org>
Thu, 11 Aug 2022 18:54:54 +0000 (11:54 -0700)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 11 Aug 2022 20:57:11 +0000 (17:57 -0300)
commitd6f415ca33e132d14743c36ad4e2b63dc8ad0b18
tree3058872a00666c4d48f8f5544299805fa183591a
parent07fc958b0cfcd8e44f0de13625a551dd16b97eb4
perf offcpu: Parse process id separately

The current target code uses thread id for tracking tasks because
perf_events need to be opened for each task.  But we can use tgid in
BPF maps and check it easily.

Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: Blake Jones <blakejones@google.com>
Cc: Hao Luo <haoluo@google.com>
Cc: Ian Rogers <irogers@google.com>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Milian Wolff <milian.wolff@kdab.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Song Liu <songliubraving@fb.com>
Cc: bpf@vger.kernel.org
Link: https://lore.kernel.org/r/20220811185456.194721-3-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/bpf_off_cpu.c