diff options
Diffstat (limited to 'src/mem/cache/tags/fa_lru.cc')
-rw-r--r-- | src/mem/cache/tags/fa_lru.cc | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/src/mem/cache/tags/fa_lru.cc b/src/mem/cache/tags/fa_lru.cc index 1b43e9892..d35e37c7b 100644 --- a/src/mem/cache/tags/fa_lru.cc +++ b/src/mem/cache/tags/fa_lru.cc @@ -69,6 +69,18 @@ FALRU::FALRU(const Params *p) fatal("Cache Size must be power of 2 for now"); blks = new FALRUBlk[numBlocks]; +} + +FALRU::~FALRU() +{ + delete[] blks; +} + +void +FALRU::init(BaseCache* cache) +{ + // Set parent cache + setCache(cache); head = &(blks[0]); head->prev = nullptr; @@ -97,11 +109,6 @@ FALRU::FALRU(const Params *p) cacheTracking.init(head, tail); } -FALRU::~FALRU() -{ - delete[] blks; -} - void FALRU::regStats() { |