summaryrefslogtreecommitdiff
path: root/src/mem/ruby/system/CacheMemory.cc
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2012-08-27 01:00:55 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2012-08-27 01:00:55 -0500
commit9190940511b5783811bc6288dd4f22f8d18c9d26 (patch)
tree72a07f80a772d7c6f2a6f0255cee173ac631cb35 /src/mem/ruby/system/CacheMemory.cc
parent7122b83d8f92d77bccae432b4e90ba12f1babad5 (diff)
downloadgem5-9190940511b5783811bc6288dd4f22f8d18c9d26.tar.xz
Ruby: Remove RubyEventQueue
This patch removes RubyEventQueue. Consumer objects now rely on RubySystem or themselves for scheduling events.
Diffstat (limited to 'src/mem/ruby/system/CacheMemory.cc')
-rw-r--r--src/mem/ruby/system/CacheMemory.cc13
1 files changed, 4 insertions, 9 deletions
diff --git a/src/mem/ruby/system/CacheMemory.cc b/src/mem/ruby/system/CacheMemory.cc
index 6ba879e90..81d73f5b4 100644
--- a/src/mem/ruby/system/CacheMemory.cc
+++ b/src/mem/ruby/system/CacheMemory.cc
@@ -154,8 +154,7 @@ CacheMemory::tryCacheAccess(const Address& address, RubyRequestType type,
if (loc != -1) {
// Do we even have a tag match?
AbstractCacheEntry* entry = m_cache[cacheSet][loc];
- m_replacementPolicy_ptr->
- touch(cacheSet, loc, g_eventQueue_ptr->getTime());
+ m_replacementPolicy_ptr->touch(cacheSet, loc, curTick());
data_ptr = &(entry->getDataBlk());
if (entry->m_Permission == AccessPermission_Read_Write) {
@@ -183,8 +182,7 @@ CacheMemory::testCacheAccess(const Address& address, RubyRequestType type,
if (loc != -1) {
// Do we even have a tag match?
AbstractCacheEntry* entry = m_cache[cacheSet][loc];
- m_replacementPolicy_ptr->
- touch(cacheSet, loc, g_eventQueue_ptr->getTime());
+ m_replacementPolicy_ptr->touch(cacheSet, loc, curTick());
data_ptr = &(entry->getDataBlk());
return m_cache[cacheSet][loc]->m_Permission !=
@@ -258,8 +256,7 @@ CacheMemory::allocate(const Address& address, AbstractCacheEntry* entry)
set[i]->m_locked = -1;
m_tag_index[address] = i;
- m_replacementPolicy_ptr->
- touch(cacheSet, i, g_eventQueue_ptr->getTime());
+ m_replacementPolicy_ptr->touch(cacheSet, i, curTick());
return entry;
}
@@ -324,8 +321,7 @@ CacheMemory::setMRU(const Address& address)
int loc = findTagInSet(cacheSet, address);
if(loc != -1)
- m_replacementPolicy_ptr->
- touch(cacheSet, loc, g_eventQueue_ptr->getTime());
+ m_replacementPolicy_ptr->touch(cacheSet, loc, curTick());
}
void
@@ -540,4 +536,3 @@ CacheMemory::checkResourceAvailable(CacheResourceType res, Address addr)
return true;
}
}
-