Arnaldo Carvalho de Melo
100ba40217
perf tools: Fix DSO filtering when not finding a map for a sampled address
[ Upstream commit c69bf11ad3d30b6bf01cfa538ddff1a59467c734 ]
When we lookup an address and don't find a map we should filter that
sample if the user specified a list of --dso entries to filter on, fix
it.
Before:
$ perf script
sleep 274800 2843.556162: 1 cycles:u: ffffffffbb26bff4 [unknown] ([unknown])
sleep 274800 2843.556168: 1 cycles:u: ffffffffbb2b047d [unknown] ([unknown])
sleep 274800 2843.556171: 1 cycles:u: ffffffffbb2706b2 [unknown] ([unknown])
sleep 274800 2843.556174: 6 cycles:u: ffffffffbb2b0267 [unknown] ([unknown])
sleep 274800 2843.556176: 59 cycles:u: ffffffffbb2b03b1 [unknown] ([unknown])
sleep 274800 2843.556180: 691 cycles:u: ffffffffbb26bff4 [unknown] ([unknown])
sleep 274800 2843.556189: 9160 cycles:u: 7fa9550eeaa3 __GI___tunables_init+0xf3 (/usr/lib64/ld-2.32.so)
sleep 274800 2843.556312: 86937 cycles:u: 7fa9550e157b _dl_lookup_symbol_x+0x4b (/usr/lib64/ld-2.32.so)
$
So we have some samples we somehow didn't find in a map for, if we now
do:
$ perf report --stdio --dso /usr/lib64/ld-2.32.so
# dso: /usr/lib64/ld-2.32.so
#
# Total Lost Samples: 0
#
# Samples: 8 of event 'cycles:u'
# Event count (approx.): 96856
#
# Overhead Command Symbol
# ........ ....... ........................
#
89.76% sleep [.] _dl_lookup_symbol_x
9.46% sleep [.] __GI___tunables_init
0.71% sleep [k] 0xffffffffbb26bff4
0.06% sleep [k] 0xffffffffbb2b03b1
0.01% sleep [k] 0xffffffffbb2b0267
0.00% sleep [k] 0xffffffffbb2706b2
0.00% sleep [k] 0xffffffffbb2b047d
$
After this patch we get the right output with just entries for the DSOs
specified in --dso:
$ perf report --stdio --dso /usr/lib64/ld-2.32.so
# dso: /usr/lib64/ld-2.32.so
#
# Total Lost Samples: 0
#
# Samples: 8 of event 'cycles:u'
# Event count (approx.): 96856
#
# Overhead Command Symbol
# ........ ....... ........................
#
89.76% sleep [.] _dl_lookup_symbol_x
9.46% sleep [.] __GI___tunables_init
$
#
Fixes: 96415e4d3f
("perf symbols: Avoid unnecessary symbol loading when dso list is specified")
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Andi Kleen <ak@linux.intel.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jin Yao <yao.jin@linux.intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Kan Liang <kan.liang@intel.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lore.kernel.org/lkml/20210128131209.GD775562@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-03-04 11:38:03 +01:00
..
2020-08-21 10:22:23 -03:00
2020-01-14 12:02:19 -03:00
2020-05-05 16:35:32 -03:00
2020-11-12 17:55:41 -03:00
2020-08-06 09:02:43 -03:00
2019-09-20 09:19:20 -03:00
2020-11-03 08:32:43 -03:00
2019-11-28 08:08:38 -03:00
2019-11-28 08:08:38 -03:00
2020-10-14 08:46:22 -03:00
2020-05-28 10:03:27 -03:00
2019-03-11 11:56:02 -03:00
2020-06-01 12:24:23 -03:00
2018-01-17 10:23:31 -03:00
2020-08-06 08:24:03 -03:00
2020-08-06 08:24:03 -03:00
2020-03-09 21:43:25 -03:00
2020-03-09 21:43:25 -03:00
2019-01-25 15:12:09 +01:00
2019-01-25 15:12:09 +01:00
2019-02-19 16:11:56 -03:00
2019-02-19 16:11:56 -03:00
2020-05-05 16:35:29 -03:00
2020-05-05 16:35:29 -03:00
2020-09-09 11:28:28 -07:00
2019-07-29 18:34:42 -03:00
2020-06-09 12:40:04 -03:00
2019-09-20 09:19:20 -03:00
2020-05-28 10:03:27 -03:00
2020-10-14 13:27:28 -03:00
2020-11-03 09:14:45 -03:00
2020-10-14 08:46:22 -03:00
2019-08-29 17:38:32 -03:00
2019-08-26 11:58:29 -03:00
2019-07-09 10:13:27 -03:00
2019-06-05 17:36:37 +02:00
2020-10-14 13:34:26 -03:00
2020-10-14 13:34:26 -03:00
2019-08-14 10:48:39 -03:00
2020-04-16 12:19:08 -03:00
2020-09-28 09:18:06 -03:00
2020-09-28 09:18:06 -03:00
2020-08-06 09:33:57 -03:00
2020-08-06 09:33:57 -03:00
2020-05-28 10:03:26 -03:00
2019-08-31 22:24:10 -03:00
2019-08-31 22:24:10 -03:00
2019-01-25 15:12:08 +01:00
2019-07-09 10:13:26 -03:00
2019-01-25 15:12:09 +01:00
2019-05-15 16:36:49 -03:00
2020-10-13 17:03:19 -03:00
2020-10-13 17:03:19 -03:00
2019-10-15 12:05:18 -03:00
2019-09-25 09:51:49 -03:00
2020-05-28 10:03:27 -03:00
2020-05-28 10:03:27 -03:00
2019-02-06 10:00:39 -03:00
2020-03-24 10:36:00 -03:00
2019-11-29 12:20:45 -03:00
2019-08-22 17:16:57 -03:00
2020-05-28 10:03:27 -03:00
2020-09-01 12:15:52 -03:00
2020-05-05 16:35:32 -03:00
2020-08-06 09:43:37 -03:00
2020-08-06 09:43:37 -03:00
2019-11-06 15:43:05 -03:00
2019-11-06 15:43:05 -03:00
2019-11-26 11:07:46 -03:00
2019-07-29 18:34:42 -03:00
2020-08-14 09:15:47 -03:00
2019-11-12 08:32:27 -03:00
2020-05-28 10:03:28 -03:00
2019-09-20 09:19:20 -03:00
2020-10-14 11:28:52 -03:00
2020-10-14 11:28:52 -03:00
2020-10-14 11:28:52 -03:00
2019-11-19 19:12:26 -03:00
2018-12-28 16:33:02 -03:00
2018-12-28 16:33:02 -03:00
2020-11-27 14:36:15 -03:00
2019-11-06 15:43:06 -03:00
2019-09-20 09:19:20 -03:00
2020-04-03 09:37:55 -03:00
2020-08-06 09:42:20 -03:00
2021-03-04 11:38:03 +01:00
2020-07-10 08:39:14 -03:00
2019-08-31 22:24:10 -03:00
2020-09-28 09:16:21 -03:00
2020-09-28 09:16:21 -03:00
2020-05-28 10:03:24 -03:00
2020-05-28 10:03:24 -03:00
2020-05-28 10:03:24 -03:00
2020-09-28 08:55:48 -03:00
2020-09-28 08:55:48 -03:00
2019-08-15 12:26:13 -03:00
2019-08-15 12:25:55 -03:00
2020-07-30 07:01:49 -03:00
2020-07-30 07:01:49 -03:00
2020-06-22 16:28:09 -03:00
2020-07-30 07:01:49 -03:00
2019-01-08 13:28:13 -03:00
2019-11-28 08:08:38 -03:00
2019-11-28 08:08:38 -03:00
2020-05-29 16:51:38 -03:00
2019-11-29 12:20:45 -03:00
2019-09-25 16:26:41 -03:00
2018-04-12 10:33:31 -03:00
2019-08-26 11:58:29 -03:00
2019-07-09 10:13:26 -03:00
2020-11-03 08:26:55 -03:00
2020-11-27 14:19:33 -03:00
2020-10-14 11:28:12 -03:00
2020-08-06 09:35:06 -03:00
2019-07-09 10:13:26 -03:00
2020-05-28 10:03:24 -03:00
2020-05-28 10:03:24 -03:00
2020-05-05 16:35:30 -03:00
2019-06-05 17:36:37 +02:00
2020-09-17 16:08:43 -03:00
2019-06-05 17:36:37 +02:00
2019-06-05 17:37:04 +02:00
2019-01-25 15:12:10 +01:00
2020-09-22 13:46:40 -03:00
2020-05-28 10:03:27 -03:00
2019-09-20 10:28:26 -03:00
2020-03-04 10:34:10 -03:00
2019-08-29 17:38:32 -03:00
2019-09-20 09:19:20 -03:00
2021-01-19 18:27:29 +01:00
2020-09-17 15:47:12 -03:00
2019-11-26 11:07:46 -03:00
2020-10-14 08:46:22 -03:00
2020-10-13 11:01:37 -03:00
2019-11-26 11:07:46 -03:00
2020-05-05 16:35:30 -03:00
2019-08-31 19:10:40 -03:00
2020-05-28 10:03:25 -03:00
2020-05-28 10:03:25 -03:00
2019-09-20 09:19:22 -03:00
2020-10-13 13:02:20 -03:00
2020-09-28 09:16:21 -03:00
2020-03-12 11:32:46 -03:00
2020-01-06 11:46:09 -03:00
2019-09-20 10:28:21 -03:00
2019-09-20 10:28:21 -03:00
2020-04-30 10:48:32 -03:00
2020-05-28 10:03:27 -03:00
2019-08-31 19:10:19 -03:00
2020-10-14 12:24:28 -03:00
2020-09-28 09:22:39 -03:00
2020-10-14 12:24:28 -03:00
2020-09-28 09:22:39 -03:00
2020-12-30 11:53:59 +01:00
2019-05-15 16:36:49 -03:00
2020-08-14 09:15:47 -03:00
2020-08-14 09:15:47 -03:00
2019-08-31 22:24:10 -03:00
2019-08-31 22:24:10 -03:00
2020-07-10 08:20:01 -03:00
2020-07-10 08:20:01 -03:00
2020-07-10 08:20:01 -03:00
2019-10-10 09:29:33 -03:00
2019-11-28 08:08:38 -03:00
2019-09-20 09:19:20 -03:00
2019-05-28 18:37:44 -03:00
2020-05-29 16:51:38 -03:00
2020-05-29 16:51:38 -03:00
2020-09-15 09:22:42 -03:00
2020-09-15 09:22:42 -03:00
2020-10-01 12:10:56 -03:00
2020-10-14 08:46:22 -03:00
2019-11-18 19:09:23 -03:00
2020-12-30 11:54:02 +01:00
2019-11-18 19:08:02 -03:00
2020-11-27 14:36:15 -03:00
2020-09-18 09:20:47 -03:00
2020-05-28 10:03:27 -03:00
2020-04-03 09:37:55 -03:00
2020-09-28 09:16:21 -03:00
2019-01-25 15:12:10 +01:00
2019-06-05 17:37:04 +02:00
2019-01-25 15:12:10 +01:00
2020-09-17 15:47:58 -03:00
2020-09-04 14:38:15 -03:00
2019-07-09 14:59:11 -03:00
2019-07-09 14:59:11 -03:00
2019-09-20 09:19:20 -03:00
2020-04-16 12:19:15 -03:00
2018-08-08 15:26:48 -03:00
2020-05-05 16:35:29 -03:00
2018-08-03 10:34:18 -03:00
2019-09-20 09:19:20 -03:00
2019-07-29 18:34:42 -03:00
2019-07-29 18:34:42 -03:00
2021-01-19 18:27:29 +01:00
2019-11-22 10:48:13 -03:00
2019-07-09 10:13:26 -03:00
2020-04-14 08:43:18 -03:00
2020-05-28 10:03:24 -03:00
2020-05-05 16:35:29 -03:00
2020-05-28 10:03:27 -03:00
2020-04-18 09:05:01 -03:00
2019-10-11 10:57:00 -03:00
2019-10-11 10:57:00 -03:00
2019-11-28 08:08:38 -03:00
2019-02-06 10:00:38 -03:00
2020-01-30 11:55:26 +01:00
2019-01-25 15:12:09 +01:00
2020-11-27 14:31:37 -03:00
2020-09-17 15:48:08 -03:00
2020-09-17 15:48:08 -03:00
2020-09-28 09:07:08 -03:00
2019-08-31 19:10:19 -03:00
2020-10-14 13:34:26 -03:00
2020-10-14 13:34:26 -03:00
2019-07-09 10:13:26 -03:00
2019-10-15 13:03:57 -03:00
2019-07-01 22:50:40 -03:00
2019-07-09 10:13:26 -03:00
2019-01-25 15:12:10 +01:00
2019-09-20 09:19:21 -03:00
2019-08-29 17:38:31 -03:00
2020-03-24 09:37:27 -03:00
2019-08-31 22:24:05 -03:00
2020-10-14 09:25:36 -03:00
2020-10-14 08:46:42 -03:00
2020-11-03 08:30:34 -03:00
2020-11-03 08:30:34 -03:00
2019-08-31 22:24:05 -03:00
2020-11-27 14:26:33 -03:00
2020-04-03 09:37:55 -03:00
2020-05-29 16:50:29 -03:00
2020-05-29 16:50:26 -03:00
2019-09-20 09:19:20 -03:00
2017-12-27 12:15:47 -03:00
2019-08-29 08:36:12 -03:00
2019-08-29 08:36:12 -03:00
2020-05-05 16:35:29 -03:00
2020-05-05 16:35:29 -03:00
2020-04-18 09:05:01 -03:00
2020-04-18 09:05:01 -03:00
2019-10-15 08:36:22 -03:00
2019-10-15 08:36:22 -03:00
2020-07-10 08:20:01 -03:00
2020-05-05 16:35:30 -03:00
2020-05-05 16:35:29 -03:00
2020-09-17 15:47:58 -03:00
2020-09-17 15:47:58 -03:00
2020-05-28 10:03:27 -03:00
2019-11-05 08:39:27 -03:00
2020-04-30 10:48:32 -03:00
2019-08-29 17:38:32 -03:00
2019-09-20 09:19:20 -03:00
2019-11-05 08:39:27 -03:00
2019-08-29 17:38:32 -03:00
2020-09-22 13:46:40 -03:00
2020-09-22 13:45:21 -03:00
2019-11-26 11:07:46 -03:00
2020-05-28 10:03:27 -03:00
2019-11-26 11:07:46 -03:00
2019-11-26 11:07:46 -03:00
2019-09-20 09:19:20 -03:00
2020-04-16 12:19:08 -03:00
2020-09-10 11:55:37 -03:00
2019-08-31 19:10:19 -03:00
2019-11-26 11:07:46 -03:00
2019-07-09 10:13:26 -03:00
2019-09-20 09:19:20 -03:00
2020-09-01 12:15:21 -03:00