virtual bool isSet(Addr addr) = 0;
virtual int getCount(Addr addr) = 0;
virtual int getTotalCount() = 0;
-
- virtual int getIndex(Addr addr) = 0;
- virtual int readBit(const int index) = 0;
- virtual void writeBit(const int index, const int value) = 0;
};
#endif // __MEM_RUBY_FILTERS_ABSTRACTBLOOMFILTER_HH__
return count;
}
-int
-BlockBloomFilter::getIndex(Addr addr)
-{
- return get_index(addr);
-}
-
-int
-BlockBloomFilter::readBit(const int index)
-{
- return m_filter[index];
-}
-
-void
-BlockBloomFilter::writeBit(const int index, const int value)
-{
- m_filter[index] = value;
-}
-
int
BlockBloomFilter::get_index(Addr addr)
{
bool isSet(Addr addr);
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
private:
int get_index(Addr addr);
return count;
}
-int
-BulkBloomFilter::getIndex(Addr addr)
-{
- return get_index(addr);
-}
-
-int
-BulkBloomFilter::readBit(const int index)
-{
- return 0;
- // TODO
-}
-
-void
-BulkBloomFilter::writeBit(const int index, const int value)
-{
- // TODO
-}
-
int
BulkBloomFilter::get_index(Addr addr)
{
bool isSet(Addr addr);
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
private:
int get_index(Addr addr);
return isSet(addr)? 1: 0;
}
-int
-H3BloomFilter::getIndex(Addr addr)
-{
- return 0;
-}
-
-int
-H3BloomFilter::readBit(const int index)
-{
- return 0;
-}
-
-void
-H3BloomFilter::writeBit(const int index, const int value)
-{
-}
-
int
H3BloomFilter::getTotalCount()
{
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
-
int
operator[](const int index) const
{
return count;
}
-int
-LSB_CountingBloomFilter::getIndex(Addr addr)
-{
- return get_index(addr);
-}
-
-int
-LSB_CountingBloomFilter::readBit(const int index)
-{
- return 0;
- // TODO
-}
-
-void
-LSB_CountingBloomFilter::writeBit(const int index, const int value)
-{
- // TODO
-}
-
int
LSB_CountingBloomFilter::get_index(Addr addr)
{
bool isSet(Addr addr);
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
private:
int get_index(Addr addr);
return isSet(addr)? 1: 0;
}
-int
-MultiBitSelBloomFilter::getIndex(Addr addr)
-{
- return 0;
-}
-
-int
-MultiBitSelBloomFilter::readBit(const int index)
-{
- return 0;
-}
-
-void
-MultiBitSelBloomFilter::writeBit(const int index, const int value)
-{
-}
-
int
MultiBitSelBloomFilter::getTotalCount()
{
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
-
int
operator[](const int index) const
{
return count;
}
-int
-MultiGrainBloomFilter::getIndex(Addr addr)
-{
- return 0;
- // TODO
-}
-
-int
-MultiGrainBloomFilter::readBit(const int index)
-{
- return 0;
- // TODO
-}
-
-void
-MultiGrainBloomFilter::writeBit(const int index, const int value)
-{
- // TODO
-}
-
int
MultiGrainBloomFilter::get_block_index(Addr addr)
{
bool isSet(Addr addr);
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
private:
int get_block_index(Addr addr);
return count;
}
-int
-NonCountingBloomFilter::getIndex(Addr addr)
-{
- return get_index(addr);
-}
-
-int
-NonCountingBloomFilter::readBit(const int index)
-{
- return m_filter[index];
-}
-
-void
-NonCountingBloomFilter::writeBit(const int index, const int value)
-{
- m_filter[index] = value;
-}
-
int
NonCountingBloomFilter::get_index(Addr addr)
{
int getCount(Addr addr);
int getTotalCount();
- int getIndex(Addr addr);
- int readBit(const int index);
- void writeBit(const int index, const int value);
-
int
operator[](const int index) const
{