Software Tuning, Performance Optimization & Platform Monitoring
Discussion regarding monitoring and software tuning methodologies, Performance Monitoring Unit (PMU) of Intel microprocessors, and platform updating.
1711 Discussions

Inaccuracy from Memory read/write bytes when using PCM-2.11 on Core i7 5960X Haswell-E

ZWang45
Beginner
321 Views

Hi All,

I try to use PCM-2.11 to measure the memory read/write bytes on Intel I7 5960X Processor Extreme Edition. 

The example “for (int i = 0; i < 200000000; i++) (int *)p_data = i;” is compiled with ICC 16.0.3.   

I have checked the assemble of the store instruction: movdqa. It means each cache line will be read first.

The PCM result shows:

BytesReadFromMC: 47615872 (wrong number)

BytesWrittenToMC: 808465920 (right number).

 

Do I need to modify the lines in cpucounters.cpp:  

void ServerPCICFGUncore::program()
{
    uint32 MCCntConfig[4] = {
        MC_CH_PCI_PMON_CTL_EVENT(0x04) + MC_CH_PCI_PMON_CTL_UMASK(3),  
        MC_CH_PCI_PMON_CTL_EVENT(0x04) + MC_CH_PCI_PMON_CTL_UMASK(12),    
    };

 

Thanks. 

 

0 Kudos
1 Reply
McCalpinJohn
Honored Contributor III
321 Views

It looks like this is an attempt to measure behavior for the initial access to the array.   The behavior of the system for page instantiation may not be what you expect. 

I recommend that you add more loops to read/write the data after it is initialized, and that you make the number of times the data is accessed after initialization an easy-to-modify variable.  You should then see that you get the expected memory access counts for subsequent accesses.


 

0 Kudos
Reply