<?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 question about hardware performance counter in Intel® ISA Extensions</title>
    <link>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786508#M356</link>
    <description>Do you see any counts (e.g. INST_RETIRED) inside either/both sections of the if block?&lt;BR /&gt;If the entry into one of the sections is infrequent (e.g. once) you might not catch a count.&lt;BR /&gt;&lt;BR /&gt;Jim Dempsey</description>
    <pubDate>Tue, 10 Jul 2012 22:49:30 GMT</pubDate>
    <dc:creator>jimdempseyatthecove</dc:creator>
    <dc:date>2012-07-10T22:49:30Z</dc:date>
    <item>
      <title>question about hardware performance counter</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786507#M355</link>
      <description>Hi,
&lt;BR /&gt;
&lt;BR /&gt; I am trying to use hardware performance counter to track which branch firefox is taking 
during execution. The event I am using is TAKEN sub-event in 
BR_INST_RETIRED. And the tool I am using is Linux perf.&lt;BR /&gt;
&lt;BR /&gt; In firefox, there is a piece of code like
&lt;BR /&gt;
&lt;BR /&gt; if(flag){
&lt;BR /&gt; ..
&lt;BR /&gt; }else{
&lt;BR /&gt; ..
&lt;BR /&gt; }
&lt;BR /&gt;
&lt;BR /&gt; After compiling, the related binary codes looks like:
&lt;BR /&gt;
&lt;BR /&gt; cmp 0x0, flag
&lt;BR /&gt; je &lt;ELSE block=""&gt; &amp;lt;========================here
&lt;BR /&gt;
&lt;BR /&gt; &lt;IF block=""&gt;
&lt;BR /&gt; jmp &lt;AFTER else="" block=""&gt;
&lt;BR /&gt;
&lt;BR /&gt; &lt;ELSE block=""&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt; By loading a special web-page, only if branch is executed. But from 
the perf report, I find the "je &lt;ELSE block=""&gt;" also causes 
BR_INST_RETIRED TAKEN event. I have add some fprintf into both if and 
else branch, and I am pretty sure that only if branch is executed.
&lt;BR /&gt;
&lt;BR /&gt; So this problem is caused by "skid"? or some other reasons causing 
this problem? I can get which instruction causedBR_INST_RETIRED TAKEN from hardware performance counter, right?&lt;BR /&gt;
&lt;BR /&gt; Thanks a lot!
&lt;BR /&gt;
&lt;BR /&gt;&lt;/ELSE&gt;&lt;/ELSE&gt;&lt;/AFTER&gt;&lt;/IF&gt;&lt;/ELSE&gt;</description>
      <pubDate>Tue, 10 Jul 2012 02:33:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786507#M355</guid>
      <dc:creator>songlinhai</dc:creator>
      <dc:date>2012-07-10T02:33:34Z</dc:date>
    </item>
    <item>
      <title>question about hardware performance counter</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786508#M356</link>
      <description>Do you see any counts (e.g. INST_RETIRED) inside either/both sections of the if block?&lt;BR /&gt;If the entry into one of the sections is infrequent (e.g. once) you might not catch a count.&lt;BR /&gt;&lt;BR /&gt;Jim Dempsey</description>
      <pubDate>Tue, 10 Jul 2012 22:49:30 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786508#M356</guid>
      <dc:creator>jimdempseyatthecove</dc:creator>
      <dc:date>2012-07-10T22:49:30Z</dc:date>
    </item>
    <item>
      <title>question about hardware performance counter</title>
      <link>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786509#M357</link>
      <description>Hi Jim,&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;  I can seeINST_RETIRED in the if branch, and noINST_RETIRED in the else branch. This is reasonable, since only if branch is executed.&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt; But in my experiment, I can see "je &lt;ELSE&gt;" instruction cause TAKEN BRAN_INST_RETIRED. Does this show that the else branch will be executed? Actually else branch is not executed.&lt;/ELSE&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt; Thanks a lot!&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;                                              Linhai&lt;/DIV&gt;</description>
      <pubDate>Thu, 12 Jul 2012 00:43:15 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-ISA-Extensions/question-about-hardware-performance-counter/m-p/786509#M357</guid>
      <dc:creator>songlinhai</dc:creator>
      <dc:date>2012-07-12T00:43:15Z</dc:date>
    </item>
  </channel>
</rss>

