Go to the documentation of this file.
34 #include "params/BloomFilterBlock.hh"
39 :
Base(
p), masksLSBs(
p.masks_lsbs),
40 masksSizes(
p.masks_sizes)
43 "Masks haven't been properly provided");
45 "There must be at least one mask to extract an address bitfield");
49 "The bitfields must be indexable in the filter");
51 std::numeric_limits<Addr>::digits,
52 "The total size of the bitfields cannot be bigger than the " \
53 "number of bits in an address");
88 assert(hashed_addr <
filter.size());
std::vector< SatCounter8 > filter
The filter itself.
const int sizeBits
Number of bits needed to represent the size of the filter.
void unset(Addr addr) override
Perform the filter specific function to clear the corresponding entries (can be multiple) of an addre...
void set(Addr addr) override
Perform the filter specific function to set the corresponding entries (can be multiple) of an address...
std::vector< unsigned > masksSizes
Number of bits in each mask.
const unsigned offsetBits
Number of LSB bits to ignore from the the addresses.
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
int getCount(Addr addr) const override
Get the value stored in the corresponding filter entry of an address.
Block(const BloomFilterBlockParams &p)
constexpr T bits(T val, unsigned first, unsigned last)
Extract the bitfield from position 'first' to 'last' (inclusive) from 'val' and right justify it.
#define fatal_if(cond,...)
Conditional fatal macro that checks the supplied condition and only causes a fatal error if the condi...
int hash(Addr addr) const
XOR hash between bitfields of an address, provided by the mask vector.
std::vector< unsigned > masksLSBs
Position of the LSB of each mask.
Generated on Tue Mar 23 2021 19:41:24 for gem5 by doxygen 1.8.17