linux/tools/perf/util
Adrian Hunter 256d92bc93 perf thread-stack: Fix thread stack processing for the idle task
perf creates a single 'struct thread' to represent the idle task. That
is because threads are identified by PID and TID, and the idle task
always has PID == TID == 0.

However, there are actually separate idle tasks for each CPU. That
creates a problem for thread stack processing which assumes that each
thread has a single stack, not one stack per CPU.

Fix that by passing through the CPU number, and in the case of the idle
"thread", pick the thread stack from an array based on the CPU number.

Signed-off-by: Adrian Hunter <adrian.hunter@intel.com>
Acked-by: Jiri Olsa <jolsa@kernel.org>
Link: http://lkml.kernel.org/r/20181221120620.9659-8-adrian.hunter@intel.com
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
2019-01-02 11:03:17 -03:00
..
c++
cs-etm-decoder perf cs-etm: Generate branch sample for exception packet 2018-12-18 12:24:00 -03:00
include
intel-pt-decoder perf script: Fix LBR skid dump problems in brstackinsn 2018-12-28 16:33:02 -03:00
libunwind
scripting-engines tools lib traceevent, perf tools: Rename 'struct tep_event_format' to 'struct tep_event' 2018-12-17 14:56:02 -03:00
annotate.c perf annotate: Introduce basic support for ARC 2018-12-17 14:59:42 -03:00
annotate.h perf annotate: Compute average IPC and IPC coverage per symbol 2018-12-17 14:55:32 -03:00
arm-spe-pkt-decoder.c
arm-spe-pkt-decoder.h
arm-spe.c
arm-spe.h
auxtrace.c perf auxtrace: Alter addr_filter__entire_dso() to work if there are no symbols 2018-12-18 12:21:44 -03:00
auxtrace.h
block-range.c
block-range.h
bpf-loader.c perf bpf-loader: Fix debugging message typo 2018-12-17 14:56:39 -03:00
bpf-loader.h
bpf-prologue.c
bpf-prologue.h
branch.c
branch.h
Build perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
build-id.c
build-id.h
cache.h
call-path.c
call-path.h
callchain.c
callchain.h
cgroup.c
cgroup.h
cloexec.c
cloexec.h
color.c
color.h
comm.c
comm.h
compress.h
config.c perf config: Modify size factor of snprintf 2018-12-17 14:59:40 -03:00
config.h
counts.c
counts.h
cpumap.c
cpumap.h
cs-etm.c perf cs-etm: Generate branch sample for exception packet 2018-12-18 12:24:00 -03:00
cs-etm.h
ctype.c
data-convert-bt.c
data-convert-bt.h
data-convert.h
data.c
data.h
db-export.c
db-export.h
debug.c
debug.h
demangle-java.c
demangle-java.h
demangle-rust.c
demangle-rust.h
drv_configs.c
drv_configs.h
dso.c perf dso: Export data_file_size() method there are no symbols 2018-12-18 12:21:44 -03:00
dso.h perf dso: Export data_file_size() method there are no symbols 2018-12-18 12:21:44 -03:00
dump-insn.c perf script: Fix LBR skid dump problems in brstackinsn 2018-12-28 16:33:02 -03:00
dump-insn.h perf script: Fix LBR skid dump problems in brstackinsn 2018-12-28 16:33:02 -03:00
dwarf-aux.c
dwarf-aux.h
dwarf-regs.c
env.c perf env: Also consider env->arch == NULL as local operation 2018-12-17 14:54:02 -03:00
env.h
event.c perf tools: Allow specifying proc-map-timeout in config file 2018-12-17 14:56:57 -03:00
event.h perf tools: Allow specifying proc-map-timeout in config file 2018-12-17 14:56:57 -03:00
evlist.c perf tools: Add missing sigqueue() prototype for systems lacking it 2018-12-18 12:23:56 -03:00
evlist.h perf record: Enable asynchronous trace writing 2018-12-17 14:55:08 -03:00
evsel.c perf tools: Fix crash on synthesizing the unit 2018-11-12 08:37:49 -08:00
evsel.h tools lib traceevent, perf tools: Rename 'struct tep_event_format' to 'struct tep_event' 2018-12-17 14:56:02 -03:00
evsel_fprintf.c perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
expr.h
expr.y
find-vdso-map.c
genelf.c
genelf.h
genelf_debug.c
generate-cmdlist.sh
get_current_dir_name.c tools build feature: Check if get_current_dir_name() is available 2018-11-19 12:12:17 -08:00
group.h
header.c perf header: Fix up argument to ctime() 2018-12-18 12:23:56 -03:00
header.h
help-unknown-cmd.c
help-unknown-cmd.h
hist.c perf tools: Fix diverse comment typos 2018-12-17 14:56:47 -03:00
hist.h perf report: Display average IPC and IPC coverage per symbol 2018-12-17 14:55:44 -03:00
intel-bts.c perf thread-stack: Fix thread stack processing for the idle task 2019-01-02 11:03:17 -03:00
intel-bts.h
intel-pt.c perf thread-stack: Fix thread stack processing for the idle task 2019-01-02 11:03:17 -03:00
intel-pt.h
intlist.c
intlist.h
jit.h
jitdump.c perf tools: Fix diverse comment typos 2018-12-17 14:56:47 -03:00
jitdump.h
kvm-stat.h
levenshtein.c
levenshtein.h
llvm-utils.c
llvm-utils.h
lzma.c
machine.c perf tools: Allow specifying proc-map-timeout in config file 2018-12-17 14:56:57 -03:00
machine.h perf tools: Allow specifying proc-map-timeout in config file 2018-12-17 14:56:57 -03:00
map.c perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
map.h perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
mem-events.c
mem-events.h
mem2node.c
mem2node.h
memswap.c
memswap.h
metricgroup.c
metricgroup.h
mmap.c perf record: Fix memory leak on AIO objects deallocation 2018-12-17 14:59:34 -03:00
mmap.h perf record: Extend trace writing to multi AIO 2018-12-17 14:55:11 -03:00
namespaces.c perf tools: Restore proper cwd on return from mnt namespace 2018-11-19 12:12:26 -08:00
namespaces.h perf tools: Restore proper cwd on return from mnt namespace 2018-11-19 12:12:26 -08:00
ordered-events.c perf ordered_events: Add first_time() method 2018-12-17 15:02:17 -03:00
ordered-events.h perf ordered_events: Add first_time() method 2018-12-17 15:02:17 -03:00
parse-branch-options.c
parse-branch-options.h
parse-events.c perf parse-events: Fix unchecked usage of strncpy() 2018-12-17 14:59:30 -03:00
parse-events.h
parse-events.l
parse-events.y
parse-regs-options.c
parse-regs-options.h
path.c
path.h
perf-hooks-list.h
perf-hooks.c
perf-hooks.h
PERF-VERSION-GEN
perf_regs.c
perf_regs.h
pmu.c perf pmu: Move *_cpuid_str() weak functions to header.c 2018-11-21 22:39:59 -03:00
pmu.h
pmu.l
pmu.y
print_binary.c
print_binary.h
probe-event.c perf tools: Fix diverse comment typos 2018-12-17 14:56:47 -03:00
probe-event.h
probe-file.c perf probe: Fix unchecked usage of strncpy() 2018-12-17 14:59:28 -03:00
probe-file.h
probe-finder.c
probe-finder.h
pstack.c
pstack.h
python-ext-sources
python.c perf python: Do not force closing original perf descriptor in evlist.get_pollfd() 2018-12-28 16:33:02 -03:00
rb_resort.h
rblist.c
rblist.h
record.c
rwsem.c
rwsem.h
s390-cpumsf-kernel.h
s390-cpumsf.c perf tools: Cast off_t to s64 to avoid warning on bionic libc 2018-12-18 12:23:57 -03:00
s390-cpumsf.h
sane_ctype.h
session.c perf ordered_events: Add private data member 2018-12-17 14:57:30 -03:00
session.h
setns.c
setup.py
smt.c
smt.h
sort.c perf tools: Fix diverse comment typos 2018-12-17 14:56:47 -03:00
sort.h perf report: Display average IPC and IPC coverage per symbol 2018-12-17 14:55:44 -03:00
srccode.c perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
srccode.h perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
srcline.c perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
srcline.h perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
stat-display.c perf stat: Fix CSV mode column output for non-cgroup events 2018-12-17 14:53:41 -03:00
stat-shadow.c perf stat: Fix shadow stats for clock events 2018-12-17 14:53:30 -03:00
stat.c
stat.h
strbuf.c
strbuf.h
strfilter.c
strfilter.h
string.c
string2.h
strlist.c
strlist.h
svghelper.c perf svghelper: Fix unchecked usage of strncpy() 2018-12-17 14:59:20 -03:00
svghelper.h
symbol-elf.c Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2018-11-03 18:13:43 -07:00
symbol-minimal.c
symbol.c perf symbols: Relax checks on perf-PID.map ownership 2018-12-18 16:17:41 -03:00
symbol.h perf annotate: Create a annotate2 flag in struct symbol 2018-12-17 14:55:40 -03:00
symbol_fprintf.c
syscalltbl.c
syscalltbl.h
target.c
target.h
term.c
term.h
thread-stack.c perf thread-stack: Fix thread stack processing for the idle task 2019-01-02 11:03:17 -03:00
thread-stack.h perf thread-stack: Fix thread stack processing for the idle task 2019-01-02 11:03:17 -03:00
thread.c perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
thread.h perf tools: Support 'srccode' output 2018-12-17 14:57:07 -03:00
thread_map.c
thread_map.h
time-utils.c
time-utils.h
tool.h
top.c perf top: Move perf_top__reset_sample_counters() to after counts display 2018-12-17 14:58:47 -03:00
top.h perf top: Save and display the drop count stats 2018-12-17 14:58:33 -03:00
trace-event-info.c
trace-event-parse.c tools lib traceevent, perf tools: Rename 'struct tep_event_format' to 'struct tep_event' 2018-12-17 14:56:02 -03:00
trace-event-read.c perf tools: traceevent API cleanup, remove __tep_data2host*() 2018-12-17 14:56:08 -03:00
trace-event-scripting.c
trace-event.c tools lib traceevent, perf tools: Rename 'struct tep_event_format' to 'struct tep_event' 2018-12-17 14:56:02 -03:00
trace-event.h tools lib traceevent, perf tools: Rename 'struct tep_event_format' to 'struct tep_event' 2018-12-17 14:56:02 -03:00
trigger.h
tsc.c
tsc.h
units.c
units.h
unwind-libdw.c perf unwind: Take pgoff into account when reporting elf to libdwfl 2018-10-31 09:57:50 -03:00
unwind-libdw.h
unwind-libunwind-local.c
unwind-libunwind.c
unwind.h
usage.c
util-cxx.h
util.c
util.h tools build feature: Check if get_current_dir_name() is available 2018-11-19 12:12:17 -08:00
values.c
values.h
vdso.c
vdso.h
xyarray.c
xyarray.h
zlib.c