summaryrefslogtreecommitdiff
path: root/src/mem/ruby/structures/CacheMemory.cc
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2015-08-14 19:28:43 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2015-08-14 19:28:43 -0500
commita706b6259a3cab71700078c4e2b91860cc2219c0 (patch)
tree19191bbcb0f466e17b7cf56c0cb569689cb2647a /src/mem/ruby/structures/CacheMemory.cc
parent5060e572ca07b98f7d84679bac81c0151dee46b9 (diff)
downloadgem5-a706b6259a3cab71700078c4e2b91860cc2219c0.tar.xz
ruby: cache memory: drop {try,test}CacheAccess functions
Diffstat (limited to 'src/mem/ruby/structures/CacheMemory.cc')
-rw-r--r--src/mem/ruby/structures/CacheMemory.cc50
1 files changed, 0 insertions, 50 deletions
diff --git a/src/mem/ruby/structures/CacheMemory.cc b/src/mem/ruby/structures/CacheMemory.cc
index 931f58a8e..ac6f823ce 100644
--- a/src/mem/ruby/structures/CacheMemory.cc
+++ b/src/mem/ruby/structures/CacheMemory.cc
@@ -158,56 +158,6 @@ CacheMemory::getAddressAtIdx(int idx) const
return entry->m_Address;
}
-bool
-CacheMemory::tryCacheAccess(Addr address, RubyRequestType type,
- DataBlock*& data_ptr)
-{
- assert(address == makeLineAddress(address));
- DPRINTF(RubyCache, "address: %s\n", address);
- int64_t cacheSet = addressToCacheSet(address);
- int loc = findTagInSet(cacheSet, address);
- if (loc != -1) {
- // Do we even have a tag match?
- AbstractCacheEntry* entry = m_cache[cacheSet][loc];
- m_replacementPolicy_ptr->touch(cacheSet, loc, curTick());
- data_ptr = &(entry->getDataBlk());
-
- if (entry->m_Permission == AccessPermission_Read_Write) {
- return true;
- }
- if ((entry->m_Permission == AccessPermission_Read_Only) &&
- (type == RubyRequestType_LD || type == RubyRequestType_IFETCH)) {
- return true;
- }
- // The line must not be accessible
- }
- data_ptr = NULL;
- return false;
-}
-
-bool
-CacheMemory::testCacheAccess(Addr address, RubyRequestType type,
- DataBlock*& data_ptr)
-{
- assert(address == makeLineAddress(address));
- DPRINTF(RubyCache, "address: %s\n", address);
- int64_t cacheSet = addressToCacheSet(address);
- int loc = findTagInSet(cacheSet, address);
-
- if (loc != -1) {
- // Do we even have a tag match?
- AbstractCacheEntry* entry = m_cache[cacheSet][loc];
- m_replacementPolicy_ptr->touch(cacheSet, loc, curTick());
- data_ptr = &(entry->getDataBlk());
-
- return m_cache[cacheSet][loc]->m_Permission !=
- AccessPermission_NotPresent;
- }
-
- data_ptr = NULL;
- return false;
-}
-
// tests to see if an address is present in the cache
bool
CacheMemory::isTagPresent(Addr address) const