summaryrefslogtreecommitdiff
path: root/src/gpgpu-sim/gpu-cache.h
diff options
context:
space:
mode:
authorTor Aamodt <[email protected]>2010-10-18 23:06:38 -0800
committerTor Aamodt <[email protected]>2010-10-18 23:06:38 -0800
commit6c65cb0119ca7c84993cab6b8828687e1b331bd0 (patch)
tree65410ac5d6677f260a7f21add94df6a421d480e9 /src/gpgpu-sim/gpu-cache.h
parent87e4da5fc6086c3d0a661af1929255a8cbd728d7 (diff)
update lru state on hit
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 7883]
Diffstat (limited to 'src/gpgpu-sim/gpu-cache.h')
-rw-r--r--src/gpgpu-sim/gpu-cache.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/gpgpu-sim/gpu-cache.h b/src/gpgpu-sim/gpu-cache.h
index 440b98b..df08e91 100644
--- a/src/gpgpu-sim/gpu-cache.h
+++ b/src/gpgpu-sim/gpu-cache.h
@@ -403,8 +403,10 @@ public:
new_addr_type block_addr = m_config.block_addr(addr);
unsigned cache_index = (unsigned)-1;
enum cache_request_status status = m_tag_array.probe(block_addr,cache_index);
- if( status == HIT )
+ if( status == HIT ) {
+ m_tag_array.access(block_addr,time,cache_index); // update LRU state
return HIT;
+ }
if( status != RESERVATION_FAIL ) {
bool mshr_hit = m_mshrs.probe(block_addr);
bool mshr_avail = !m_mshrs.full(block_addr);