summaryrefslogtreecommitdiff
path: root/src/mem/cache/tags/fa_lru.cc
diff options
context:
space:
mode:
authorMarco Balboni <Marco.Balboni@ARM.com>2015-02-11 10:23:36 -0500
committerMarco Balboni <Marco.Balboni@ARM.com>2015-02-11 10:23:36 -0500
commite2828587b3f28c4f37f0fe598209290bc3d41de0 (patch)
treed0d967c233c0da3d07f045806d6c48e9b6b06190 /src/mem/cache/tags/fa_lru.cc
parent5a573762d0b27eb26a572581611df2196656641f (diff)
downloadgem5-e2828587b3f28c4f37f0fe598209290bc3d41de0.tar.xz
mem: Clarify usage of latency in the cache
This patch adds some much-needed clarity in the specification of the cache timing. For now, hit_latency and response_latency are kept as top-level parameters, but the cache itself has a number of local variables to better map the individual timing variables to different behaviours (and sub-components). The introduced variables are: - lookupLatency: latency of tag lookup, occuring on any access - forwardLatency: latency that occurs in case of outbound miss - fillLatency: latency to fill a cache block We keep the existing responseLatency The forwardLatency is used by allocateInternalBuffer() for: - MSHR allocateWriteBuffer (unchached write forwarded to WriteBuffer); - MSHR allocateMissBuffer (cacheable miss in MSHR queue); - MSHR allocateUncachedReadBuffer (unchached read allocated in MSHR queue) It is our assumption that the time for the above three buffers is the same. Similarly, for snoop responses passing through the cache we use forwardLatency.
Diffstat (limited to 'src/mem/cache/tags/fa_lru.cc')
-rw-r--r--src/mem/cache/tags/fa_lru.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/mem/cache/tags/fa_lru.cc b/src/mem/cache/tags/fa_lru.cc
index 6a63da673..ffe2cbf25 100644
--- a/src/mem/cache/tags/fa_lru.cc
+++ b/src/mem/cache/tags/fa_lru.cc
@@ -60,8 +60,6 @@ FALRU::FALRU(const Params *p)
if (!isPowerOf2(blkSize))
fatal("cache block size (in bytes) `%d' must be a power of two",
blkSize);
- if (!(hitLatency > 0))
- fatal("Access latency in cycles must be at least one cycle");
if (!isPowerOf2(size))
fatal("Cache Size must be power of 2 for now");
@@ -202,7 +200,7 @@ FALRU::accessBlock(Addr addr, bool is_secure, Cycles &lat, int context_src,
*inCache = tmp_in_cache;
}
- lat = hitLatency;
+ lat = accessLatency;
//assert(check());
return blk;
}