<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic [Intel PCM] Reference Cycles and Cycles Lost Due to Cache Misses in Software Tuning, Performance Optimization &amp; Platform Monitoring</title>
    <link>https://community.intel.com/t5/Software-Tuning-Performance/Intel-PCM-Reference-Cycles-and-Cycles-Lost-Due-to-Cache-Misses/m-p/850382#M1158</link>
    <description>&lt;DIV id="_mcePaste"&gt;&lt;DIV id="_mcePaste"&gt;Good afternoon.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;I've been using the Intel PCM to analyze my software in a way that I could measure the number of CPU cycles consumed while executing and the number of CPU cycles spent while waiting for some event (such as IO operation or waiting for a reading/writing in the memory). &amp;nbsp;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Does the value "&lt;B&gt;Reference Cycles&lt;/B&gt;", acquired through the call &lt;B&gt;getRefCycles()&lt;/B&gt;, count exclusively the number of CPU cycles wasted by the CPU while waiting for the memory? And does&amp;nbsp;&lt;B&gt;getCycles()&lt;/B&gt;&amp;nbsp;return the Executed and Waited cycles?&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;In addition, I'm interested in count the number of CPU cycles spent due to misses at the Cache Levels. For that, Intel provides the &lt;B&gt;getCyclesLostDueL2CacheMisses()&lt;/B&gt; call. However, it returns a double value (i. e. Number of Cycles Lost Due to L2CacheMisses: 0.0652477). Does this represent a percentage of the Total CPU Cycles?&amp;nbsp;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Thanks in advance.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Anderson Venturini&lt;/DIV&gt;&lt;/DIV&gt;</description>
    <pubDate>Tue, 21 Aug 2012 15:37:06 GMT</pubDate>
    <dc:creator>asventurini</dc:creator>
    <dc:date>2012-08-21T15:37:06Z</dc:date>
    <item>
      <title>[Intel PCM] Reference Cycles and Cycles Lost Due to Cache Misses</title>
      <link>https://community.intel.com/t5/Software-Tuning-Performance/Intel-PCM-Reference-Cycles-and-Cycles-Lost-Due-to-Cache-Misses/m-p/850382#M1158</link>
      <description>&lt;DIV id="_mcePaste"&gt;&lt;DIV id="_mcePaste"&gt;Good afternoon.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;I've been using the Intel PCM to analyze my software in a way that I could measure the number of CPU cycles consumed while executing and the number of CPU cycles spent while waiting for some event (such as IO operation or waiting for a reading/writing in the memory). &amp;nbsp;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Does the value "&lt;B&gt;Reference Cycles&lt;/B&gt;", acquired through the call &lt;B&gt;getRefCycles()&lt;/B&gt;, count exclusively the number of CPU cycles wasted by the CPU while waiting for the memory? And does&amp;nbsp;&lt;B&gt;getCycles()&lt;/B&gt;&amp;nbsp;return the Executed and Waited cycles?&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;In addition, I'm interested in count the number of CPU cycles spent due to misses at the Cache Levels. For that, Intel provides the &lt;B&gt;getCyclesLostDueL2CacheMisses()&lt;/B&gt; call. However, it returns a double value (i. e. Number of Cycles Lost Due to L2CacheMisses: 0.0652477). Does this represent a percentage of the Total CPU Cycles?&amp;nbsp;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Thanks in advance.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;Anderson Venturini&lt;/DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Tue, 21 Aug 2012 15:37:06 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Tuning-Performance/Intel-PCM-Reference-Cycles-and-Cycles-Lost-Due-to-Cache-Misses/m-p/850382#M1158</guid>
      <dc:creator>asventurini</dc:creator>
      <dc:date>2012-08-21T15:37:06Z</dc:date>
    </item>
    <item>
      <title>[Intel PCM] Reference Cycles and Cycles Lost Due to Cache Misse</title>
      <link>https://community.intel.com/t5/Software-Tuning-Performance/Intel-PCM-Reference-Cycles-and-Cycles-Lost-Due-to-Cache-Misses/m-p/850383#M1159</link>
      <description>Hi Anderson,&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;The getRefCycles is not counting&amp;nbsp;exclusively the number of CPU cycles wasted by the CPU while waiting for the memory. It just returns the&amp;nbsp;reference clock cycles while clock signal on the core is running.&amp;nbsp;The reference clock operates at a fixed frequency. This metric is computed from the CPU_CLK_UNHALTED.REF performance monitoring hardware event.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;The getCycles returns the number of "used" cycles (halted cycles are not counted).&amp;nbsp;This metric is computed from the CPU_CLK_UNHALTED.THREAD performance monitoring hardware event.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;As for&amp;nbsp;getCyclesLostDueL2CacheMisses: 0.065 should correspond to 6.5%. But note it is just a very rough static estimation. On a real system the number of cycles lost due to a cache miss may vary depending on location of memory (local/remote socket), memory speed, memory latency hiding when using Intel® Hyper-Threading technology, etc.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;In case of I/O, usually operating systems deschedule waiting threads from the CPU, thus your program might not consume CPU cycles during waiting at all. To profile I/O waiting times you may try the "Locks&amp;amp;Waits" analysis in the Intel® VTune Amplifier XE 2011 profiler. The tool has also very detailed memory access analysis types for Intel processors.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Best regards,&lt;/DIV&gt;&lt;DIV&gt;Roman&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 23 Aug 2012 13:33:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Software-Tuning-Performance/Intel-PCM-Reference-Cycles-and-Cycles-Lost-Due-to-Cache-Misses/m-p/850383#M1159</guid>
      <dc:creator>Roman_D_Intel</dc:creator>
      <dc:date>2012-08-23T13:33:27Z</dc:date>
    </item>
  </channel>
</rss>

