I'm trying to get instruction counter of a program using perf.
I already installed some packages for perf
but, when I run the perf_event_open, error is occurred.
I used like this 'fd = perf_event_open(&attr, getpid(), -1, -1, 0);'
but value of fd was -1.
error message is 'a.out: cannot create event: No such file or directory'
I compiled with /usr/local/lib/libpfm.a
and I have succeeded this work on other board.
anyone can help me??