title: Using Intel's PIN tool to count the number of cache hits/misses in a program
body: <p>I've been trying to write a pintool to instrument cache hits and misses in a given program. 
  I found that there are calls such as INS_IsMemoryRead/Write to determine if the instruction is a LD/ST. </p>
  
  <ul>
  <li>Is there a way to determine if the instruction had a cache hit or miss? </li>
  <li>If so, is it also possible to get the number of cycles spent fetching the data from the cache/memory?</li>
  </ul>