The output of the debug fprintf()s of the test program is: #> ./test_perf pe.size = 96 pe.type = 7 pe.config = 2 pe.disabled = 0 pe.inherit = 1 pe.exclude_guest = 0 perf_event_open(...) After which it immeditaly produces the Oops.