I want to use PAPI 5.5.1 to check out performances about some of my text algorithms in order to observe differences about cycles, number of mispredictions and pipeline. I have checked the native events provided by the library and I have verified that they are supported by my computer with the tools papi_avail.
It works well when I try to measure up to 5 native events max simultaneously. But after, PAPI refuse to start counting.
Here is my simplified stuff :
#define NB_EVENTS 6
int CS_Events[NB_EVENTS] = {PAPI_BR_INS, PAPI_BR_MSP, PAPI_TOT_CYC, PAPI_TOT_INS, PAPI_RES_STL, PAPI_TOT_IIS};
PAPI_start_counters(CS_Events, NB_EVENTS); /* return PAPI_ECNFLCT */
PAPI_ECNFLCT 's description is :
Hardware event exists, but cannot be counted due to counter resource limitations
I didn't find anymore about this on PAPI/perf documentation. (I'm interesting about x86(32|64) and ARM processors).
So it seems there's an hardware limit for counters ?
Does it exists a table processor/limit's value to know it ?
Is there any other way to do this?
PAPI_BR_INS
is a preset event which maps to a native eventBR_INST_RETIRED:ALL_BRANCHES
on my Skylake CPU. The accepted answer (stackoverflow.com/a/51099181/1319478) talks about native events. Sometimes, preset events map to exactly one native events, but in other cases, it is not true. – quepas