summaryrefslogtreecommitdiff
path: root/src/mem/ruby/filters/NonCountingBloomFilter.cc
diff options
context:
space:
mode:
authorNilay Vaish <nilay@cs.wisc.edu>2015-08-14 12:04:51 -0500
committerNilay Vaish <nilay@cs.wisc.edu>2015-08-14 12:04:51 -0500
commit91a84c5b3cfb888794ac0245c066a4724b9a0871 (patch)
tree79a8b41aff56655dbd187934d2709fdd7488c6ed /src/mem/ruby/filters/NonCountingBloomFilter.cc
parent9ea5d9cad9381e05004de28ef25309ebe94c3a79 (diff)
downloadgem5-91a84c5b3cfb888794ac0245c066a4724b9a0871.tar.xz
ruby: replace Address by Addr
This patch eliminates the type Address defined by the ruby memory system. This memory system would now use the type Addr that is in use by the rest of the system.
Diffstat (limited to 'src/mem/ruby/filters/NonCountingBloomFilter.cc')
-rw-r--r--src/mem/ruby/filters/NonCountingBloomFilter.cc22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/mem/ruby/filters/NonCountingBloomFilter.cc b/src/mem/ruby/filters/NonCountingBloomFilter.cc
index 246189357..14bb3a245 100644
--- a/src/mem/ruby/filters/NonCountingBloomFilter.cc
+++ b/src/mem/ruby/filters/NonCountingBloomFilter.cc
@@ -64,13 +64,13 @@ NonCountingBloomFilter::clear()
}
void
-NonCountingBloomFilter::increment(const Address& addr)
+NonCountingBloomFilter::increment(Addr addr)
{
// Not used
}
void
-NonCountingBloomFilter::decrement(const Address& addr)
+NonCountingBloomFilter::decrement(Addr addr)
{
// Not used
}
@@ -86,21 +86,21 @@ NonCountingBloomFilter::merge(AbstractBloomFilter *other_filter)
}
void
-NonCountingBloomFilter::set(const Address& addr)
+NonCountingBloomFilter::set(Addr addr)
{
int i = get_index(addr);
m_filter[i] = 1;
}
void
-NonCountingBloomFilter::unset(const Address& addr)
+NonCountingBloomFilter::unset(Addr addr)
{
int i = get_index(addr);
m_filter[i] = 0;
}
bool
-NonCountingBloomFilter::isSet(const Address& addr)
+NonCountingBloomFilter::isSet(Addr addr)
{
int i = get_index(addr);
return (m_filter[i]);
@@ -108,7 +108,7 @@ NonCountingBloomFilter::isSet(const Address& addr)
int
-NonCountingBloomFilter::getCount(const Address& addr)
+NonCountingBloomFilter::getCount(Addr addr)
{
return m_filter[get_index(addr)];
}
@@ -130,7 +130,7 @@ NonCountingBloomFilter::print(ostream& out) const
}
int
-NonCountingBloomFilter::getIndex(const Address& addr)
+NonCountingBloomFilter::getIndex(Addr addr)
{
return get_index(addr);
}
@@ -148,11 +148,11 @@ NonCountingBloomFilter::writeBit(const int index, const int value)
}
int
-NonCountingBloomFilter::get_index(const Address& addr)
+NonCountingBloomFilter::get_index(Addr addr)
{
- return addr.bitSelect(RubySystem::getBlockSizeBits() + m_offset,
- RubySystem::getBlockSizeBits() + m_offset +
- m_filter_size_bits - 1);
+ return bitSelect(addr, RubySystem::getBlockSizeBits() + m_offset,
+ RubySystem::getBlockSizeBits() + m_offset +
+ m_filter_size_bits - 1);
}