mem: Add unused prefetch counter in caches

Added stat to the cache to account for HardPF'ed blocks that are evicted
before being referenced (over-prefetching).
This commit is contained in:
Rekai Gonzalez Alberquilla
2015-05-27 13:50:01 +01:00
parent c75ff71139
commit a3bf4aa6ec
3 changed files with 12 additions and 0 deletions

View File

@@ -1709,6 +1709,9 @@ Cache::allocateBlock(Addr addr, bool is_secure, PacketList &writebacks)
addr, is_secure ? "s" : "ns",
blk->isDirty() ? "writeback" : "clean");
if (blk->wasPrefetched()) {
unusedPrefetches++;
}
// Will send up Writeback/CleanEvict snoops via isCachedAbove
// when pushing this writeback list into the write buffer.
if (blk->isDirty() || writebackClean) {