34#ifndef __MEM_CACHE_COMPRESSORS_ZERO_HH__
35#define __MEM_CACHE_COMPRESSORS_ZERO_HH__
47struct ZeroCompressorParams;
83 static std::map<int, std::string> pattern_names = {
87 return pattern_names[number];
90 std::unique_ptr<Pattern>
92 const int match_location)
const override
94 return PatternFactory::getPattern(bytes, dict_bytes, match_location);
99 std::unique_ptr<Base::CompressionData>
compress(
126 Z, 1, 0, match_location, bytes)
Cycles is a wrapper class for representing cycle counts, i.e.
A pattern that compares masked values to a masked portion of a fixed value.
A pattern containing the original uncompressed data.
A template version of the dictionary compressor that allows to choose the dictionary size.
std::array< uint8_t, sizeof(T)> DictionaryEntry
Convenience typedef for a dictionary entry.
PatternX(const DictionaryEntry bytes, const int match_location)
PatternZ(const DictionaryEntry bytes, const int match_location)
std::unique_ptr< Base::CompressionData > compress(const std::vector< Base::Chunk > &chunks, Cycles &comp_lat, Cycles &decomp_lat) override
Apply the compression process to the cache line.
std::string getName(int number) const override
Get meta-name assigned to the given pattern.
std::unique_ptr< Pattern > getPattern(const DictionaryEntry &bytes, const DictionaryEntry &dict_bytes, const int match_location) const override
Factory< PatternZ, PatternX > PatternFactory
Convenience factory declaration.
ZeroCompressorParams Params
PatternNumber
The patterns proposed in the paper.
void addToDictionary(DictionaryEntry data) override
uint64_t getNumPatterns() const override
Trick function to get the number of patterns.
DictionaryCompressor< uint64_t >::DictionaryEntry DictionaryEntry
Definition of a dictionary based cache compressor.
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.