mem-cache: Remove mumBlock redundant initialiation from FALRU
authorNikos Nikoleris <nikos.nikoleris@arm.com>
Mon, 31 Oct 2016 15:52:15 +0000 (15:52 +0000)
committerNikos Nikoleris <nikos.nikoleris@arm.com>
Fri, 2 Mar 2018 18:41:13 +0000 (18:41 +0000)
Change-Id: Id3afec0a62446d6d0f44ccb655032343037637e0
Reviewed-by: Curtis Dunham <curtis.dunham@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/8281
Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br>
Maintainer: Nikos Nikoleris <nikos.nikoleris@arm.com>

src/mem/cache/tags/base.hh
src/mem/cache/tags/fa_lru.cc

index 2c528a9830b8b8afedd9a5b1e63c8faf39db30d1..9714d9aa23d5eab3430ae7e66089e5a00ef6e4a7 100644 (file)
@@ -91,7 +91,7 @@ class BaseTags : public ClockedObject
     bool warmedUp;
 
     /** the number of blocks in the cache */
-    unsigned numBlocks;
+    const unsigned numBlocks;
 
     // Statistics
     /**
index dfd4c406013c8d777246c8c230739bf924ab9d0c..1ee34b7d840c97de092f0c51b43b081ee198c652 100644 (file)
@@ -73,8 +73,6 @@ FALRU::FALRU(const Params *p)
         cacheMask = 0;
     }
 
-    numBlocks = size/blkSize;
-
     blks = new FALRUBlk[numBlocks];
     head = &(blks[0]);
     tail = &(blks[numBlocks-1]);