<?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 How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge in Analyzers</title>
    <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827458#M2481</link>
    <description>Hello,&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;DIV id="_mcePaste"&gt;It would be enough if I can get the sum of the L1, L2 and L3 Caches-misses htte.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;But for sandy Bridge i cannot find the events or the fomulas.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;can you help me?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Andr&lt;/DIV&gt;</description>
    <pubDate>Wed, 25 Jan 2012 15:37:48 GMT</pubDate>
    <dc:creator>eandy</dc:creator>
    <dc:date>2012-01-25T15:37:48Z</dc:date>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827455#M2478</link>
      <description>Hello,&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;I am analysing the SPEC CPU2006 Benchmarks on different CPUs with INTEL Vtunes and it works fine, so far.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;I have a Problem to count the Cache misses of the L1, L2 and L3 Cache. I cannot find the "Event Names" to do that.&lt;/DIV&gt;&lt;DIV&gt;The CPU is an INTEL i5-2400 (Sandy Bridge)&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;At all other CPUs it was easy so find the names of the events.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Can you please help me?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;regards&lt;/DIV&gt;&lt;DIV&gt;Andr&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 19 Jan 2012 20:03:54 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827455#M2478</guid>
      <dc:creator>eandy</dc:creator>
      <dc:date>2012-01-19T20:03:54Z</dc:date>
    </item>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827456#M2479</link>
      <description>&lt;P&gt;Some useful info about Sandy Bridge events can be found here:&lt;BR /&gt;&lt;A href="http://software.intel.com/en-us/articles/using-intel-vtune-amplifier-xe-to-tune-software-on-the-2nd-generation-intel-core-processor-family/"&gt;http://software.intel.com/en-us/articles/using-intel-vtune-amplifier-xe-to-tune-software-on-the-2nd-generation-intel-core-processor-family/&lt;/A&gt;&lt;BR /&gt;&lt;A href="http://software.intel.com/en-us/articles/two-part-webinar-and-two-videos-posted-all-covering-sandy-bridge-performance-tuning/"&gt;http://software.intel.com/en-us/articles/two-part-webinar-and-two-videos-posted-all-covering-sandy-bridge-performance-tuning/&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;The cache miss formulas should look this way:&lt;BR /&gt;&lt;BR /&gt;L3 cache miss&lt;BR /&gt;(180 * MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;&lt;P&gt;L2 cache miss&lt;BR /&gt;((26 * MEM_LOAD_UPOS_RETIRED.LLC_HIT_PS) + (43 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS) + (60 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS)) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;&lt;P&gt;L1 cache miss&lt;BR /&gt;((12 * MEM_LOAD_UOPS_RETIRED.L2_HIT) + (26 * MEM_LOAD_RETIRED.LLC_HIT_PS) + (43 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS) + (60 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS) + (180 * MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS)) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;</description>
      <pubDate>Fri, 20 Jan 2012 15:07:35 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827456#M2479</guid>
      <dc:creator>Kirill_R_Intel</dc:creator>
      <dc:date>2012-01-20T15:07:35Z</dc:date>
    </item>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827457#M2480</link>
      <description>Thank you for your help!&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;But are this realy theformulas to get the miss rate of the L1,L2,L3 cache?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Because with these formulas I get the result that the miss rate of the L3 is bigger than the L2 and this is bigger than the L1,shouldnotitbethe other way around?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;or do I think the wrong way?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;regards&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Andr&lt;/DIV&gt;</description>
      <pubDate>Tue, 24 Jan 2012 18:50:55 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827457#M2480</guid>
      <dc:creator>eandy</dc:creator>
      <dc:date>2012-01-24T18:50:55Z</dc:date>
    </item>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827458#M2481</link>
      <description>Hello,&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;DIV id="_mcePaste"&gt;It would be enough if I can get the sum of the L1, L2 and L3 Caches-misses htte.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;But for sandy Bridge i cannot find the events or the fomulas.&lt;/DIV&gt;&lt;DIV id="_mcePaste"&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;can you help me?&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;Andr&lt;/DIV&gt;</description>
      <pubDate>Wed, 25 Jan 2012 15:37:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827458#M2481</guid>
      <dc:creator>eandy</dc:creator>
      <dc:date>2012-01-25T15:37:48Z</dc:date>
    </item>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827459#M2482</link>
      <description>Hi Andre,&lt;BR /&gt;The formulas Kirill gives above are to calculate the impacts of L1, L2, and L3 misses in terms of cycles spent servicing them. These impacts can be measured at the function or whole application level, depending on which values you plug into them.&lt;BR /&gt;However I use the following formulas for impact, which are exclusive of each other:&lt;BR /&gt;&lt;BR /&gt;&lt;P&gt;LLC cache miss impact:&lt;/P&gt;&lt;P&gt;(180 * MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;&lt;P&gt;LLCcache hit impact(ie misses from L2 &lt;EM&gt;THAT HIT IN LLC&lt;/EM&gt;):&lt;/P&gt;&lt;P&gt;((26 * MEM_LOAD_UPOS_RETIRED.LLC_HIT_PS) + (43 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS) + (60 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS)) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;&lt;P&gt;L2 cache hit impact (ie misses from L1 &lt;EM&gt;THAT HIT IN L2&lt;/EM&gt;):&lt;BR /&gt;(12 * MEM_LOAD_UOPS_RETIRED.L2_HIT) / CPU_CLK_UNHALTED.THREAD&lt;BR /&gt;&lt;BR /&gt;Thesecan all be added to see the total impact of everything that missed the L1.&lt;BR /&gt;&lt;BR /&gt;However, you asked for Miss Rate formulas, which I interpret as (misses / total requests) for a given cache level. This is a bit hard to calculate as there are several types of requests - demand requests come from the application vs. prefetch requests generated by the hardware; code requests vs. data requests, etc. There are not events to count all of the different combinations, but I can give you these, which are for demanded data (not prefetches or instructions) and are applicable for &lt;EM&gt;SINGLE SOCKET&lt;/EM&gt; processors based on Intel Microarchitecture Codename Sandy Bridge:&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L1 Miss Rate =&amp;gt; cannot calculate.&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L2 Miss Rate =&amp;gt; &lt;BR /&gt;(sum of all types of L2 demand data misses) / (sum of L2 demanded data requests) =&amp;gt; &lt;BR /&gt;(MEM_LOAD_UOPS_RETIRED.LLC_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS + MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS) / (L2_RQSTS.ALL_DEMAND_DATA_RD)&lt;/P&gt;&lt;P&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L3 Miss Rate =&amp;gt; &lt;BR /&gt;L3 demand data misses / (sum of all types of demand data L3 requests) =&amp;gt; &lt;BR /&gt;MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS / (MEM_LOAD_UOPS_RETIRED.LLC_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS + MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS)&lt;BR /&gt;&lt;BR /&gt;To collect all of these events, you would want to create a new custom analysis type (small button at the top left of the analysis type pane in the standalone GUI), choose "New Hardware Event-Based Sampling Analysis", and then add all of the above events. Use the default sample after values, and hit OK when you are done adding them. Then run the analysis, and view the data as "Hardware Event Counts" (which will be the default). Do not use the results as "Hardware Event Sample Counts".&lt;BR /&gt;Hope this helps!&lt;/P&gt;</description>
      <pubDate>Fri, 03 Feb 2012 19:05:13 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827459#M2482</guid>
      <dc:creator>Shannon_C_Intel</dc:creator>
      <dc:date>2012-02-03T19:05:13Z</dc:date>
    </item>
    <item>
      <title>How to get the L1,L2 Cache Miss of an intel i5 Sandy Bridge</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827460#M2483</link>
      <description>Thank you for your Help!</description>
      <pubDate>Fri, 17 Feb 2012 14:10:14 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827460#M2483</guid>
      <dc:creator>eandy</dc:creator>
      <dc:date>2012-02-17T14:10:14Z</dc:date>
    </item>
    <item>
      <title>Hello Shannon, and every one.</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827461#M2484</link>
      <description>&lt;P&gt;Hello Shannon, and every one.&lt;/P&gt;
&lt;P&gt;Where come from these constants that you use in your formulas? For instance, the 26, 43 and 60 in this one:&lt;/P&gt;
&lt;P&gt;((26 * MEM_LOAD_UPOS_RETIRED.LLC_HIT_PS) + (43 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS) + (60 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS)) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;
&lt;P&gt;I guess those are the cycles needed to service a hit in LLC on each circumstance. Am I correct? I need to apply this analysis for Ivy Bridge, do you know where I can find these constants for it?&lt;/P&gt;
&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Sun, 27 Oct 2013 18:34:36 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827461#M2484</guid>
      <dc:creator>Divino_C_</dc:creator>
      <dc:date>2013-10-27T18:34:36Z</dc:date>
    </item>
    <item>
      <title>@Divino</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827462#M2485</link>
      <description>&lt;P&gt;@Divino&lt;/P&gt;
&lt;P&gt;You asked an interesting question.I agree with you that those constants can represent a cycles needed to service the events which are part of formulae.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2013 06:18:03 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827462#M2485</guid>
      <dc:creator>Bernard</dc:creator>
      <dc:date>2013-10-28T06:18:03Z</dc:date>
    </item>
    <item>
      <title>Hi Iliyapolak,</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827463#M2486</link>
      <description>&lt;P&gt;Hi Iliyapolak,&lt;/P&gt;
&lt;P&gt;In section 2.2.5.1 of this document [1] there is a table showing the best case latency for cache accesses. However, I believe these infos are for Sandy Bridge.&lt;/P&gt;
&lt;P&gt;[1]&amp;nbsp;&lt;A href="http://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-optimization-manual.pdf"&gt;http://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-optimization-manual.pdf&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Oct 2013 21:35:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827463#M2486</guid>
      <dc:creator>Divino_C_</dc:creator>
      <dc:date>2013-10-28T21:35:00Z</dc:date>
    </item>
    <item>
      <title>@ Kirill Rogozhin (Intel)</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827464#M2487</link>
      <description>&lt;P&gt;@ &lt;A href="https://community.intel.com/en-us/user/509175"&gt;Kirill Rogozhin (Intel)&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;There are 2 problems I encountered when I tried to use your formula to calculate the cache miss.&lt;/P&gt;
&lt;P&gt;1.When I calculate the L3 miss ratio, I get 90%. But my test application code is just one line using function printf. Therefore , it can't be that&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; big. And when I calculate the L2 miss ration, the result is even bigger than 1 which is obvious not correct.&lt;/P&gt;
&lt;P&gt;2.When I use hardware event :MEM_LOAD_RETIRED.LLC_HIT_PS , it shows that it's a invalid event. But on the platform of Sandybridge,&lt;/P&gt;
&lt;P&gt;I think this event should be valid. So, I've no idea what's happening.&lt;/P&gt;
&lt;P&gt;Any help would be appreciated.&lt;/P&gt;
&lt;P&gt;Sun.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Oct 2013 07:50:49 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827464#M2487</guid>
      <dc:creator>sun_s_</dc:creator>
      <dc:date>2013-10-31T07:50:49Z</dc:date>
    </item>
    <item>
      <title>Quote:Divino C. wrote:</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827465#M2488</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Divino C. wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;
&lt;P&gt;Hi Iliyapolak,&lt;/P&gt;
&lt;P&gt;In section 2.2.5.1 of this document [1] there is a table showing the best case latency for cache accesses. However, I believe these infos are for Sandy Bridge.&lt;/P&gt;
&lt;P&gt;[1]&amp;nbsp;&lt;A href="http://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-optimization-manual.pdf"&gt;http://www.intel.com/content/dam/www/public/us/en/documents/manuals/64-ia-32-architectures-optimization-manual.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;
&lt;P&gt;It is Core microarchitecture not SandyBridge(hebr. Gesher) which is Nehalem succesor.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Oct 2013 15:12:11 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827465#M2488</guid>
      <dc:creator>Bernard</dc:creator>
      <dc:date>2013-10-31T15:12:11Z</dc:date>
    </item>
    <item>
      <title>sun s., as Shannon stated</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827466#M2489</link>
      <description>&lt;P&gt;&lt;A href="http://software.intel.com/en-us/user/976139"&gt;sun s.&lt;/A&gt;, as Shannon stated above, the formulas I provided are not cache miss rates, they represent cache miss impact. For cache miss rates refer to the formulas she specified:&amp;nbsp;&lt;EM&gt;Demand Data&lt;/EM&gt;&amp;nbsp;L2 Miss Rate and&amp;nbsp;&lt;EM&gt;Demand Data&lt;/EM&gt;&amp;nbsp;L3 Miss Rate.&lt;/P&gt;</description>
      <pubDate>Wed, 06 Nov 2013 13:51:05 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827466#M2489</guid>
      <dc:creator>Kirill_R_Intel</dc:creator>
      <dc:date>2013-11-06T13:51:05Z</dc:date>
    </item>
    <item>
      <title>@Kirill Rogozhin (Intel)</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827467#M2490</link>
      <description>&lt;P&gt;@&lt;A href="http://software.intel.com/zh-cn/user/509175"&gt;Kirill Rogozhin (Intel)&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Thanks.Now I see.&lt;/P&gt;</description>
      <pubDate>Tue, 12 Nov 2013 05:01:30 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827467#M2490</guid>
      <dc:creator>sun_s_</dc:creator>
      <dc:date>2013-11-12T05:01:30Z</dc:date>
    </item>
    <item>
      <title>Quote:Shannon Cepeda (Intel)</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827468#M2491</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Shannon Cepeda (Intel) wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;Hi Andre,&lt;BR /&gt;
	The formulas Kirill gives above are to calculate the impacts of L1, L2, and L3 misses in terms of cycles spent servicing them. These impacts can be measured at the function or whole application level, depending on which values you plug into them.&lt;BR /&gt;
	However I use the following formulas for impact, which are exclusive of each other:&lt;/P&gt;

&lt;P&gt;LLC cache miss impact:&lt;/P&gt;

&lt;P&gt;(180 * MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;

&lt;P&gt;LLCcache hit impact(ie misses from L2 &lt;EM&gt;THAT HIT IN LLC&lt;/EM&gt;):&lt;/P&gt;

&lt;P&gt;((26 * MEM_LOAD_UPOS_RETIRED.LLC_HIT_PS) + (43 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS) + (60 * MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS)) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;

&lt;P&gt;L2 cache hit impact (ie misses from L1 &lt;EM&gt;THAT HIT IN L2&lt;/EM&gt;):&lt;BR /&gt;
	(12 * MEM_LOAD_UOPS_RETIRED.L2_HIT) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;

&lt;P&gt;Thesecan all be added to see the total impact of everything that missed the L1.&lt;/P&gt;

&lt;P&gt;However, you asked for Miss Rate formulas, which I interpret as (misses / total requests) for a given cache level. This is a bit hard to calculate as there are several types of requests - demand requests come from the application vs. prefetch requests generated by the hardware; code requests vs. data requests, etc. There are not events to count all of the different combinations, but I can give you these, which are for demanded data (not prefetches or instructions) and are applicable for &lt;EM&gt;SINGLE SOCKET&lt;/EM&gt; processors based on Intel Microarchitecture Codename Sandy Bridge:&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L1 Miss Rate =&amp;gt; cannot calculate.&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L2 Miss Rate =&amp;gt;&lt;BR /&gt;
	(sum of all types of L2 demand data misses) / (sum of L2 demanded data requests) =&amp;gt;&lt;BR /&gt;
	(MEM_LOAD_UOPS_RETIRED.LLC_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS + MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS) / (L2_RQSTS.ALL_DEMAND_DATA_RD)&lt;/P&gt;

&lt;P&gt;&lt;EM&gt;Demand Data&lt;/EM&gt; L3 Miss Rate =&amp;gt;&lt;BR /&gt;
	L3 demand data misses / (sum of all types of demand data L3 requests) =&amp;gt;&lt;BR /&gt;
	MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS / (MEM_LOAD_UOPS_RETIRED.LLC_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HIT_PS + MEM_LOAD_UOPS_LLC_HIT_RETIRED.XSNP_HITM_PS + MEM_LOAD_UOPS_MISC_RETIRED.LLC_MISS_PS)&lt;/P&gt;

&lt;P&gt;To collect all of these events, you would want to create a new custom analysis type (small button at the top left of the analysis type pane in the standalone GUI), choose "New Hardware Event-Based Sampling Analysis", and then add all of the above events. Use the default sample after values, and hit OK when you are done adding them. Then run the analysis, and view the data as "Hardware Event Counts" (which will be the default). Do not use the results as "Hardware Event Sample Counts".&lt;BR /&gt;
	Hope this helps!&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;Hi Shannon,&lt;/P&gt;

&lt;P&gt;&amp;nbsp; &amp;nbsp; The formulas that you provided above are for sandy bridge, right?&lt;/P&gt;

&lt;P&gt;&amp;nbsp; &amp;nbsp; I am working on i3 3220(ivy bridge) with intel vtune amplifier and I wanna to measure the L1, L2 ,L3 cache miss impact, but I cannot find formulas related. Can I use the above formulas to profiling programs running on machines with ivy bridge architecture? Could you please give some help?&lt;/P&gt;</description>
      <pubDate>Wed, 31 Dec 2014 02:40:11 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827468#M2491</guid>
      <dc:creator>Linan_H_</dc:creator>
      <dc:date>2014-12-31T02:40:11Z</dc:date>
    </item>
    <item>
      <title>@ Linan H</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827469#M2492</link>
      <description>&lt;P&gt;@ Linan H&lt;/P&gt;

&lt;P&gt;Please go to this&lt;A href="https://software.intel.com/en-us/articles/processor-specific-performance-analysis-papers"&gt; site&lt;/A&gt;, to get the article (for specific processor) which is Intel(R) VTune(TM) Amplifier tuning guide, the article should have proper L2/LLC formulas. &amp;nbsp;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 04 Jan 2015 02:12:15 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827469#M2492</guid>
      <dc:creator>Peter_W_Intel</dc:creator>
      <dc:date>2015-01-04T02:12:15Z</dc:date>
    </item>
    <item>
      <title>Quote:Peter Wang (Intel)</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827470#M2493</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Peter Wang (Intel) wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;@ Linan H&lt;/P&gt;

&lt;P&gt;Please go to this&lt;A href="https://software.intel.com/en-us/articles/processor-specific-performance-analysis-papers"&gt; site&lt;/A&gt;, to get the article (for specific processor) which is Intel(R) VTune(TM) Amplifier tuning guide, the article should have proper L2/LLC formulas. &amp;nbsp;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;Hi Peter,&lt;/P&gt;

&lt;P&gt;&amp;nbsp; &amp;nbsp; Thanks for your help!&lt;/P&gt;

&lt;P&gt;&amp;nbsp; &amp;nbsp; I've found the L2/LLC cache miss impact in the document "Using_Intel_VTune_Amplifier_XE_on_3rd_Generation_Intel_Core_Processors_1.0", but how about the L1 cache miss impact formula? If there is a L1 cache miss impact formula for sandy bridge, I believe there should be the relevant formulas for ivy bridge. Could you please help me to figure it out?&lt;/P&gt;</description>
      <pubDate>Wed, 07 Jan 2015 06:32:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827470#M2493</guid>
      <dc:creator>Linan_H_</dc:creator>
      <dc:date>2015-01-07T06:32:39Z</dc:date>
    </item>
    <item>
      <title> &gt;...but how about the L1</title>
      <link>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827471#M2494</link>
      <description>&lt;P&gt;&lt;SPAN style="font-size: 12px; line-height: 18px;"&gt;&amp;nbsp;&amp;gt;...but how about the L1 cache miss impact formula?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;The reason is that penalty of L1 Miss is low, approximate ~6 cycles (in my experience). If you really need this, configure it by your self:&lt;/P&gt;

&lt;P&gt;For example:&lt;/P&gt;

&lt;P&gt;Formula: % of cycles spent on L1 Misses&lt;/P&gt;

&lt;P&gt;(6 * MEM_LOAD_UOPS_RETIRED.L1_MISS_PS) / CPU_CLK_UNHALTED.THREAD&lt;/P&gt;

&lt;P&gt;Thresholds: Investigate if &amp;nbsp;"&lt;SPAN style="line-height: 19.5120010375977px;"&gt;% of cycles spent on L1 Misses" &amp;gt; 0.2 (20%)&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 07 Jan 2015 07:18:04 GMT</pubDate>
      <guid>https://community.intel.com/t5/Analyzers/How-to-get-the-L1-L2-Cache-Miss-of-an-intel-i5-Sandy-Bridge/m-p/827471#M2494</guid>
      <dc:creator>Peter_W_Intel</dc:creator>
      <dc:date>2015-01-07T07:18:04Z</dc:date>
    </item>
  </channel>
</rss>

