summaryrefslogtreecommitdiff
path: root/src/mem/cache/tags/lru.hh
diff options
context:
space:
mode:
authorNathan Binkert <nate@binkert.org>2009-06-04 23:21:12 -0700
committerNathan Binkert <nate@binkert.org>2009-06-04 23:21:12 -0700
commit6faf377b5305f9dcc3c7b013c4d67f5accb92617 (patch)
tree0e437fb49a32dd3d2d2bec95a8dc3bdb4ddf05b0 /src/mem/cache/tags/lru.hh
parent4e3426624557b555c354035ee3961eab7554d81d (diff)
downloadgem5-6faf377b5305f9dcc3c7b013c4d67f5accb92617.tar.xz
types: clean up types, especially signed vs unsigned
Diffstat (limited to 'src/mem/cache/tags/lru.hh')
-rw-r--r--src/mem/cache/tags/lru.hh18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/mem/cache/tags/lru.hh b/src/mem/cache/tags/lru.hh
index 466095ec9..2874d8f1f 100644
--- a/src/mem/cache/tags/lru.hh
+++ b/src/mem/cache/tags/lru.hh
@@ -92,15 +92,16 @@ class LRU : public BaseTags
typedef LRUBlk BlkType;
/** Typedef for a list of pointers to the local block class. */
typedef std::list<LRUBlk*> BlkList;
+
protected:
/** The number of sets in the cache. */
- const int numSets;
+ const unsigned numSets;
/** The number of bytes in a block. */
- const int blkSize;
+ const unsigned blkSize;
/** The associativity of the cache. */
- const int assoc;
+ const unsigned assoc;
/** The hit latency. */
- const int hitLatency;
+ const unsigned hitLatency;
/** The cache sets. */
CacheSet *sets;
@@ -127,7 +128,8 @@ public:
* @param _assoc The associativity of the cache.
* @param _hit_latency The latency in cycles for a hit.
*/
- LRU(int _numSets, int _blkSize, int _assoc, int _hit_latency);
+ LRU(unsigned _numSets, unsigned _blkSize, unsigned _assoc,
+ unsigned _hit_latency);
/**
* Destructor
@@ -138,7 +140,8 @@ public:
* Return the block size.
* @return the block size.
*/
- int getBlockSize()
+ unsigned
+ getBlockSize() const
{
return blkSize;
}
@@ -148,7 +151,8 @@ public:
* size.
* @return The block size.
*/
- int getSubBlockSize()
+ unsigned
+ getSubBlockSize() const
{
return blkSize;
}