Hi folks,
I'm trying to get smpl_pebs from libpfm-3.2-060926 to work on a
pentium D 820 and having no luck with both cores running or just one.
From my understanding smpl_pebs counts the # of L1 cache misses so I
wrote a short program(code at very bottom) to run smpl_pebs on in
which I'm reading and writing data that is 25x the L1 cache size... I
would think is enough to overflow the pebs buffer and get output such
as:
=========
entry 000033 eflags:0x00000206 EAX:0x000011c5 ESP:0xbfe06760 IP:0x080483da
=========
but got this instead with no pebs entries:
=========
[EMAIL PROTECTED]:~/testc/debug/src> ./smpl_pebs ./testc
context [3] buffer mapped @0xb7fa9000
pebs_base=0xf9326100 pebs_end=0xf9327101 index=0xf9326100
intr=0xf9326f38 version=1.0
entry_size=40 ds_size=40
task terminated
=========
The Pentium D 820 L1 Data Cache: Two 16KB data caches / 4-way set
associative / write-through / 64 byte cache line / integrated
Is there a quick test to see if installed everything correctly? The
message in dmesg seem to indicate everything's okay:
=========
[EMAIL PROTECTED]:~/testc/debug/src> dmesg|grep perfmon
Linux version 2.6.18-perfmon2-smp ([EMAIL PROTECTED]) (gcc version 4.1.0
(SUSE Linux)) #2 SMP Wed Oct 11 22:02:37 EDT 2006
perfmon: CPU0 APIC mask=0x100ee
perfmon: version 2.2
perfmon: added sampling format default
perfmon: cores/package=2 threads/core=0
perfmon: HyperThreading supported, status off
perfmon: Data Save Area (DS) supported
perfmon: PEBS supported, status off (because of HT)
perfmon: Intel P4 PMU detected, 63 PMCs, 18 PMDs, 18 counters (40 bits)
perfmon: PMU has 18 enable PMCs
perfmon: Intel P4 PMU installed
perfmon: CPU0 APIC mask=0xee
perfmon: added sampling format PEBS
=========
+Program:
=========
#define kSize 100000
#define DEBUG 0
int main(int argc, char *argv[])
{
int temp[kSize];
int temp2[kSize];
FILE* file = NULL;
int i = 0;
printf("sleep 10\n");
sleep(10);
printf("start write array\n");
for(i = 0; i < kSize; i++)
{
temp[i] = i * 2;
if(DEBUG)
{
printf("num: %d\n", temp[i]);
}
}
printf("start copy array\n");
for(i = 0; i < kSize; i++)
{
temp2[i] = temp[i];
}
return EXIT_SUCCESS;
}
Thanks
Hua-Ying
_______________________________________________
perfmon mailing list
[email protected]
http://www.hpl.hp.com/hosted/linux/mail-archives/perfmon/