RRZE-HPC / likwid

Performance monitoring and benchmarking suite
https://hpc.fau.de/research/tools/likwid/
GNU General Public License v3.0
1.64k stars 226 forks source link

Support of LIKWID on ARM with QNX OS #620

Closed khatrishubham88 closed 4 months ago

khatrishubham88 commented 4 months ago

Why do you need support for this specific architecture? I need ARMv8 support for QNX OS. As I see currently likwid perfmon, numa, topology very heavily relies on linux kernel events. Enabling this feature would allow bringing LIKWID to a edge devices.

Which architecture model, family and further information? CPU or accelerator? CPU:

Is the documentation of the hardware counters publicly available? Yes, public arm documents

Are there already any usable tools (commercial or open-source)? Not yet but would be widely applicable in edge community.

TomTheBear commented 4 months ago

Thanks for your request but this will be a hard to impossible task.

The most problematic part is that QNX OS does not seem to provide the perf_event API. Without this API, no counter access from user-space is possible (if QNX OS has a separation between kernel- and user-space). You could load a kernel module to flip the "allow access by user-space bit" but then you have to program the configuration setup, reading, writing, etc. yourself. This manual management code does exist for x86 because there we have direct register access but on ARM, there is no way except kernel module (there is no equivalent to msr kernel devices). This is a big part, but an even larger task is to make sure that all system-level functions behave similarly and all of them exist. Finally, LIKWID is intended for HPC systems and therefore integrates mainly HPC relevant chips. I have no clue about embedded systems but for me it is unlikely to use a recent ARM chip (Nvidia Grace, Ampere Altra, ...) in an embedded device.

khatrishubham88 commented 4 months ago

Hi Thomas, Thanks for the answer, I do understand the problem here. For now I would close this issue.

Thanks, Shubham