perf trace: Sample timestamp and cpu when using record flag
PATCH 1/1 perf trace: Sample timestamp and cpu when using record flag
Sample timestamp and cpu just like the -R option.
Before:
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042After:
init-0 [001] 7364.568965353: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.530226877: irq_handler_entry: irq=1 handler=i8042
init-0 [001] 7365.542831563: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.644156299: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.694556201: irq_handler_entry: irq=18 handler=eth0Signed-off-by Li Zefan <[email protected]>
--- tools/perf/util/parse-events.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
tools/perf/util/parse-events.c +4 -1
@@ -425,8 +425,11 @@ parse_single_tracepoint_event(char *sys_name,int fd;if (flags) { -if (!strncmp (flags,"record" ,strlen (flags))) +if (!strncmp (flags,"record" ,strlen (flags))) { attr->sample_type |=PERF_SAMPLE_RAW ; + attr->sample_type |=PERF_SAMPLE_TIME ; + attr->sample_type |=PERF_SAMPLE_CPU ; + } } snprintf(evt_path, MAXPATHLEN, "%s/%s/%s/id", debugfs_path,
Signature · 1 line
1.6.3
Quoted 9 lines · Li Zefan
Sample timestamp and cpu just like the -R option.
Before:
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0 init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0 init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042 init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0 init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042
Quoted 8 lines
After:
init-0 [001] 7364.568965353: irq_handler_entry: irq=18 handler=eth0 init-0 [001] 7365.530226877: irq_handler_entry: irq=1 handler=i8042 init-0 [001] 7365.542831563: irq_handler_entry: irq=18 handler=eth0 init-0 [001] 7365.644156299: irq_handler_entry: irq=18 handler=eth0 init-0 [001] 7365.694556201: irq_handler_entry: irq=18 handler=eth0Signed-off-by Li Zefan <[email protected]>
Quoted 24 lines
--- tools/perf/util/parse-events.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)tools/perf/util/parse-events.c +4
-1@@ -425,8 +425,11 @@ parse_single_tracepoint_event(char *sys_name,int fd;if (flags) { -if (!strncmp (flags,"record" ,strlen (flags))) +if (!strncmp (flags,"record" ,strlen (flags))) { attr->sample_type |=PERF_SAMPLE_RAW ; + attr->sample_type |=PERF_SAMPLE_TIME ; + attr->sample_type |=PERF_SAMPLE_CPU ; + } } snprintf(evt_path, MAXPATHLEN, "%s/%s/%s/id", debugfs_path,Signature · 1 line
1.6.3
Commit-ID: 1281a49b7aa865a1f0d60e2b28410e6234fc686b Gitweb: http://git.kernel.org/tip/1281a49b7aa865a1f0d60e2b28410e6234fc686b Author: Li Zefan <[email protected]> AuthorDate: Thu, 17 Sep 2009 16:49:43 +0800 Committer: Ingo Molnar <[email protected]> CommitDate: Fri, 18 Sep 2009 00:30:25 +0200
perf trace: Sample timestamp and cpu when using record flag
Sample timestamp and cpu just like the -R option.
Before:
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=18 handler=eth0
init-0 [-01] 1266874889.17179869184709551615: irq_handler_entry: irq=1 handler=i8042After:
init-0 [001] 7364.568965353: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.530226877: irq_handler_entry: irq=1 handler=i8042
init-0 [001] 7365.542831563: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.644156299: irq_handler_entry: irq=18 handler=eth0
init-0 [001] 7365.694556201: irq_handler_entry: irq=18 handler=eth0Signed-off-by Li Zefan <[email protected]>
Cc Peter Zijlstra <[email protected]>
LKML-Reference: <[email protected]>
Signed-off-by Ingo Molnar <[email protected]>
--- tools/perf/util/parse-events.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
tools/perf/util/parse-events.c +4 -1
@@ -425,8 +425,11 @@ parse_single_tracepoint_event(char *sys_name,int fd;if (flags) { -if (!strncmp (flags,"record" ,strlen (flags))) +if (!strncmp (flags,"record" ,strlen (flags))) { attr->sample_type |=PERF_SAMPLE_RAW ; + attr->sample_type |=PERF_SAMPLE_TIME ; + attr->sample_type |=PERF_SAMPLE_CPU ; + } } snprintf(evt_path, MAXPATHLEN, "%s/%s/%s/id", debugfs_path,