Skip to content

Will rr work on my system

Simon Sobisch edited this page Apr 26, 2022 · 3 revisions

This question mostly pertains to Virtual Machines rather than real hardware. To check if it's supposed to work execute the following

on Intel CPUs:

 $ perf stat -e br_inst_retired.conditional true

 Performance counter stats for 'true':

            95,027      br_inst_retired.conditional

       0.003255114 seconds time elapsed

       0.003127000 seconds user
       0.000000000 seconds sys

Check that br_inst_retired.conditional value is not zero in the output.

Note:

On newer systems you might get an error that says that there is an event syntax error and that br_inst_retired.conditional does not exist. If that occurs, try:

 $ perf stat -e br_inst_retired.cond true

on AMD Ryzen CPUs

$ perf stat -e ex_ret_cond true

 Performance counter stats for 'true':

            17.525      ex_ret_cond:u

       0,002422402 seconds time elapsed

       0,002737000 seconds user
       0,000000000 seconds sys

Check that ex_ret_cond:u value is not zero in the output.

in General

You will also likely have to change your kernel.perf_event_paranoid setting to 1, at least when recording.
That is documented on the Building-And-Installing page.