I want to measure the cache throughput of my code. We can use the performance list to display supported events. My desktop is equipped with an Intel (R) Core (TM) i5-2400 processor with a processor with a frequency of 3.10 GHz, the primary list lists cache references and cache misses, for example:
cpu-cycles OR cycles [Hardware event] stalled-cycles-frontend OR idle-cycles-frontend [Hardware event] stalled-cycles-backend OR idle-cycles-backend [Hardware event] instructions [Hardware event] cache-references [Hardware event] cache-misses [Hardware event]
I think cache misses are mapped to LLC-misses hardware events according to the Intel architecture software developer guide (I confirm this by comparing perf stat -e r412e and perf stat -e cache-misses , they gave almost the same result) . But how are cache links counted? I did not find an event or a way to get general cache references using existing hardware events. So I wonder how accurate this cache link is on my computer?
caching perf rate
Robert
source share