hotspot icon indicating copy to clipboard operation
hotspot copied to clipboard

time measurements between tracepoints

Open lievenhey opened this issue 2 years ago • 2 comments

this patch allows the user to measure the time it takes between two tracepoints and shows this as a cost

lievenhey avatar Mar 07 '22 14:03 lievenhey

Currently this brakes if you have a situation like this:

c-syscalls 11991 [001]  9905.279844: syscalls:sys_enter_openat: dfd: 0xffffff9c, filename: 0x7fff7cd476a8, flags: 0x00000000, mode: 0x00000000
                  101f0b __libc_open64+0x5b (inlined)
                   85ad5 __GI__IO_file_open+0x25 (inlined)
                   85caa __GI__IO_file_fopen+0x10a (inlined)
                   79dee __fopen_internal+0x7e (/usr/lib/libc.so.6)
                    10e7 [unknown] (/home/lieven/KDAB/hotspot/build/tests/test-clients/c-syscalls/c-syscalls)
                   2d30f __libc_start_call_main+0x7f (/usr/lib/libc.so.6)
                   2d3c0 __libc_start_main_alias_2+0x80 (inlined)
                    114d [unknown] (/home/lieven/KDAB/hotspot/build/tests/test-clients/c-syscalls/c-syscalls)

c-syscalls 11991 [001]  9905.280087: syscalls:sys_enter_openat: dfd: 0xffffff9c, filename: 0x7fff7cd476a8, flags: 0x00000000, mode: 0x00000000
                  101f0b __libc_open64+0x5b (inlined)
                   85ad5 __GI__IO_file_open+0x25 (inlined)
                   85caa __GI__IO_file_fopen+0x10a (inlined)
                   79dee __fopen_internal+0x7e (/usr/lib/libc.so.6)
                    10e7 [unknown] (/home/lieven/KDAB/hotspot/build/tests/test-clients/c-syscalls/c-syscalls)
                   2d30f __libc_start_call_main+0x7f (/usr/lib/libc.so.6)
                   2d3c0 __libc_start_main_alias_2+0x80 (inlined)
                    114d [unknown] (/home/lieven/KDAB/hotspot/build/tests/test-clients/c-syscalls/c-syscalls)

I am pretty sure that my perf.data is broken but I am not sure If the file is broken: add warning if encountering such situation

lievenhey avatar Mar 07 '22 14:03 lievenhey

@lievenhey how did you get the broken perf data file? And what exactly is broken - that you get two consecutive enter events instead of enter/exit pairs?

milianw avatar Apr 10 '22 10:04 milianw