Go to the documentation of this file.
29 #ifndef __MEM_CACHE_COMPRESSORS_FREQUENT_VALUES_HH__
30 #define __MEM_CACHE_COMPRESSORS_FREQUENT_VALUES_HH__
49 struct FrequentValuesCompressorParams;
75 const std::string &
name)
168 bool is_invalidation);
173 std::unique_ptr<Base::CompressionData>
compress(
175 Cycles& decomp_lat)
override;
180 typedef FrequentValuesCompressorParams
Params;
228 #endif //__MEM_CACHE_COMPRESSORS_FREQUENT_VALUES_HH__
std::unique_ptr< Base::CompressionData > compress(const std::vector< Chunk > &chunks, Cycles &comp_lat, Cycles &decomp_lat) override
Apply the compression process to the cache line.
uint64_t uncompressedValue
A pseudo value is used as the representation of uncompressed values.
void probeNotify(const DataUpdate &data_update)
Process a notification event from the ProbeListener.
const bool checkSaturation
Whether an action must be performed when counters saturate.
A compressed value contains its encoding, and the compressed data itself.
VFTEntry(std::size_t num_bits)
void notify(const DataUpdate &data_update) override
const bool useHuffmanEncoding
Whether Huffman encoding is applied to the VFT indices.
void decompress(const CompressionData *comp_data, uint64_t *data) override
Apply the decompression process to the compressed data.
uint64_t value
The value is stored as a 64 bit entry to accomodate for the uncompressed value.
This compressor samples the cache for a while, trying to define the most frequently used values.
std::vector< FrequentValuesListener * > listeners
BaseCacheCompressorParams Params
void sampleValues(const std::vector< uint64_t > &data, bool is_invalidation)
Sample values from a packet, adding them to the VFT.
AssociativeSet< VFTEntry > VFT
The Value Frequency Table, a small cache that keeps track and estimates the frequency distribution of...
unsigned takenSamples
Number of samples taken so far.
const Tick codeGenerationTicks
Ticks needed to perform the CODE_GENERATION phase.
std::vector< CompressedValue > compressedValues
The values contained in the original data, after being compressed sequentially.
Cycles is a wrapper class for representing cycle counts, i.e.
A data contents update is composed of the updated block's address, the old contents,...
This encoder builds a Huffman tree using the frequency of each value to be encoded.
encoder::Huffman indexEncoder
The encoder applied to the VFT indices.
A tagged entry is an entry containing a tag.
FrequentValuesListener(FrequentValues &_parent, ProbeManager *pm, const std::string &name)
encoder::Code code
The codeword.
Associative container based on the previosuly defined Entry type Each element is indexed by a key of ...
const unsigned numSamples
Number of samples in the sampling phase.
uint64_t Tick
Tick count type.
Base cache compressor interface.
void reset()
Reset the counter to its initial value.
FrequentValuesCompressorParams Params
SatCounter32 counter
The ideal counter width (in bits) is determined by the maximum number of times a given value appears ...
virtual void invalidate()
Invalidate the block.
const unsigned numVFTEntries
Maximum number of VFT entries, and thus of codewords too.
void invalidate() override
Invalidate the block.
ProbeManager is a conduit class that lives on each SimObject, and is used to match up probe listeners...
CompressedValue(encoder::Code _code, uint64_t _value)
~FrequentValues()=default
ProbeListenerArgBase is used to define the base interface to a ProbeListenerArg (i....
const int counterBits
Number of bits in the saturating counters.
EventFunctionWrapper codeGenerationEvent
Event to handle finishing code generation and starting compression.
uint64_t value
Original value, stored both for when the codeword marks an uncompressed entry, and to verify correctn...
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
void regProbeListeners() override
Register probe listeners for this object.
void generateCodes()
End sampling phase and start the code generation.
Phase
The phase that the compressor is at.
FrequentValues(const Params &p)
Generated on Sun Jul 30 2023 01:56:57 for gem5 by doxygen 1.8.17