PAPI support for hybrid/heterogeneous CPUs
Traditionally multi-core systems would have identical CPU cores, which
made scheduling and programming them easier.
Recently you can get hybrid (or heterogeneous CPUs) that allow power saving
by scheduling jobs across CPU cores of varying types.
This was first widely used by ARM with their big.LITTLE processors, but
recently Intel has added support with Performance and Efficiency cores.
Existing performance measurement tools need work in order to support
hybrid cores. This page describes work done on the PAPI performance
monitoring library.
Current PAPI Hybrid-Support Status (17 January 2025)
- libpfm4 support (used by PAPI to get events)
- x86 hybrid support (works upstream)
- ARM big.LITTLE support (underway.
Maintainer has set of preliminary
patches [using a different approach than our
proposed patches] but they are not merged yet)
- PAPI support
- TODO: updated patches needed to add support
(for now you can try the ones from the artifacts
with our paper)
- TODO: unit tests
- Outstanding issues
- Reporting availability of hybrid CPU cores via existing
PAPI system info interfaces
- On a hybrid system, should PAPI_TOT_INS be the sum of all
cores (performance+efficiency)? Do we need to add a new
mechanism for separating them out?
- How to handle event sampling across hybrid cores
(i.e., if you ask to be notified after 100 million
retired instructions, should this still work if your process
migrates between cores)
- Handle crashes on hybrid systems if measuring something that
does not exist on one type of core (currently trying to measure
top-down data on efficiency/atom cores will crash your
program. There's no way in Linux
to atomically check which core type
you are on before attempting to read the values)
Related Publications
A summary of our work as of November 2024 can be found in
the following ProTools 2024 (Workshop on Programming and Performance
Visualisation Tools) paper:
- W. Cunningham, V.M. Weaver.
"Performance Measurement on Heterogeneous Processors with PAPI"
Back to my projects page