Replies: 1 comment 4 replies
-
The multiple counter example is requesting 6 hardware counters at the same time. It will fail on Pixel 7. Because Pixel 7 only leaves 3 free counters to userspace. You may try it on a newer device, like Pixel 9, which has 18 free counters. |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, I was hoping to gain some help on here regarding perf_event_open even though this is for the Android NDK. I wanted to make my own executable (similar to simpleperf), using the examples on ARM | Use perf_event_open for counting. It has two examples:
The single counter example worked fine on the Android device, but I couldn't get the multiple counter example working on an Android. The same code for multiple counters does seem to work on an Ubuntu 22.04. I was wondering why the same code might not work for Android and if you might have insights as to why that is. To be more precise, the code stops at this part:
I think the issue might lie in the defined
read_format
struct, but wasn't able to find an issue based on the perf_event_open manual. The device I am using is a Pixel 7 Pro with Android 13. And I compiled using27.2.12479018/build/cmake/android.toolchain.cmake" -DANDROID_ABI="arm64-v8a" -DANDROID_PLATFORM=android-31
.Tagged @yabinc, since @yabinc typically works on simpleperf. Any help is appreciated!
Beta Was this translation helpful? Give feedback.
All reactions