Not using all available performance counters

Open discussion of PAPI.

Not using all available performance counters

Postby AlexSz » Sat Oct 06, 2012 8:33 pm

I've been trying to measure some events via performance counters.
Code: Select all
if(PAPI_event_name_to_code((char*)"perf::L1-DCACHE-LOADS",&eventId)!=PAPI_OK)printf("Err1");
    PAPI_add_event(EventSet,eventId);

    if(PAPI_event_name_to_code((char*)"perf::L1-DCACHE-LOAD-MISSES", &eventId)!=PAPI_OK)printf("Err2");
    PAPI_add_event(EventSet,eventId);

    if(PAPI_event_name_to_code((char*)"L2_CACHE_MISS:DATA:u=1", &eventId)!=PAPI_OK)printf("Err3");
    PAPI_add_event(EventSet,eventId);

    if(PAPI_event_name_to_code((char*)"L3_CACHE_MISSES:ANY_READ:c=3:u=1",&eventId)!=PAPI_OK)printf("Err4");
    PAPI_add_event(EventSet,eventId);


However, when I read out the events with PAPI_stop, I only get 3 counts back. It doesn't seem to matter which events I specify, it's always the same result.
I've tried the same thing by using the PERF interface to Linux 3.5.4-1-ARCH. Same thing. Is this a known problem?

Some more info:
Code: Select all
PAPI Version: 5.0.1.0

Available components and hardware information.
--------------------------------------------------------------------------------
PAPI Version             : 5.0.1.0
Vendor string and code   : AuthenticAMD (2)
Model string and code    : AMD Phenom(tm) II X4 965 Processor (4)
CPU Revision             : 3.000000
CPUID Info               : Family: 16  Model: 4  Stepping: 3
CPU Max Megahertz        : 3411
CPU Min Megahertz        : 3411
Hdw Threads per core     : 1
Cores per Socket         : 4
NUMA Nodes               : 1
CPUs per Node            : 4
Total CPUs               : 4
Running in a VM          : no
Number Hardware Counters : 4
Max Multiplex Counters   : 64
--------------------------------------------------------------------------------

Compiled-in components:
Name:   perf_events             Linux perf_event CPU counters

Active components:
Name:   perf_events             Linux perf_event CPU counters
                                Native: 202, Preset: 42, Counters: 4


--------------------------------------------------------------------------------
component.c                             PASSED
AlexSz
 
Posts: 1
Joined: Sat Oct 06, 2012 8:01 pm

Return to General discussion

Who is online

Users browsing this forum: No registered users and 2 guests

cron