changeset a89984ca7d15 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=a89984ca7d15
description:
        ruby: cache memory: drop {try,test}CacheAccess functions

diffstat:

 src/mem/ruby/structures/CacheMemory.cc |  50 ----------------------------------
 src/mem/ruby/structures/CacheMemory.hh |   9 ------
 2 files changed, 0 insertions(+), 59 deletions(-)

diffs (79 lines):

diff -r 9a0022457323 -r a89984ca7d15 src/mem/ruby/structures/CacheMemory.cc
--- a/src/mem/ruby/structures/CacheMemory.cc    Fri Aug 14 19:28:43 2015 -0500
+++ b/src/mem/ruby/structures/CacheMemory.cc    Fri Aug 14 19:28:43 2015 -0500
@@ -158,56 +158,6 @@
     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
diff -r 9a0022457323 -r a89984ca7d15 src/mem/ruby/structures/CacheMemory.hh
--- a/src/mem/ruby/structures/CacheMemory.hh    Fri Aug 14 19:28:43 2015 -0500
+++ b/src/mem/ruby/structures/CacheMemory.hh    Fri Aug 14 19:28:43 2015 -0500
@@ -56,15 +56,6 @@
 
     void init();
 
-    // Public Methods
-    // perform a cache access and see if we hit or not.  Return true on a hit.
-    bool tryCacheAccess(Addr address, RubyRequestType type,
-                        DataBlock*& data_ptr);
-
-    // similar to above, but doesn't require full access check
-    bool testCacheAccess(Addr address, RubyRequestType type,
-                         DataBlock*& data_ptr);
-
     // tests to see if an address is present in the cache
     bool isTagPresent(Addr address) const;
 
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to