#ifndef __LRU_HH__
#define __LRU_HH__
+#include <cstring>
#include <list>
#include "mem/cache/cache_blk.hh" // base class
bool probe(Addr addr) const;
/**
- * Invalidate the block containing the given address.
- * @param asid The address space ID.
- * @param addr The address to invalidate.
- */
- void invalidateBlk(Addr addr);
-
- /**
- * Finds the given address in the cache and update replacement data.
- * Returns the access latency as a side effect.
- * @param pkt The request whose block to find.
- * @param lat The access latency.
- * @return Pointer to the cache block if found.
+ * Invalidate the given block.
+ * @param blk The block to invalidate.
*/
- LRUBlk* findBlock(Packet * &pkt, int &lat);
+ void invalidateBlk(BlkType *blk);
/**
* Finds the given address in the cache and update replacement data.
* @param compress_blocks List of blocks to compress, for adaptive comp.
* @return The block to place the replacement in.
*/
- LRUBlk* findReplacement(Packet * &pkt, PacketList &writebacks,
+ LRUBlk* findReplacement(PacketPtr &pkt, PacketList &writebacks,
BlkList &compress_blocks);
/**
*/
void readData(LRUBlk *blk, uint8_t *data)
{
- memcpy(data, blk->data, blk->size);
+ std::memcpy(data, blk->data, blk->size);
}
/**