gem5 v24.0.0.0
|
The compactor tracks retired instructions addresses, leveraging the spatial and temporal locality among instructions for compaction. More...
Public Member Functions | |
CompactorEntry () | |
CompactorEntry (Addr, unsigned int, unsigned int) | |
bool | inSameSpatialRegion (Addr addr, unsigned int log_blk_size, bool update) |
Checks if a given address is in the same defined spatial region as the compactor entry. | |
bool | hasAddress (Addr target, unsigned int log_blk_size) const |
Checks if the provided address is contained in this spatial region and if its corresponding bit vector entry is set. | |
void | getPredictedAddresses (unsigned int log_blk_size, std::vector< AddrPriority > &addresses) const |
Fills the provided vector with the predicted addresses using the recorded bit vectors of the entry. | |
Public Attributes | |
Addr | trigger |
std::vector< bool > | prec |
std::vector< bool > | succ |
Private Member Functions | |
Addr | distanceFromTrigger (Addr addr, unsigned int log_blk_size) const |
Computes the distance, in cache blocks, from an address to the trigger of the entry. | |
The compactor tracks retired instructions addresses, leveraging the spatial and temporal locality among instructions for compaction.
It comprises the spatial and temporal compaction mechanisms.
Taking advantage of the spatial locality across instruction blocks, the spatial compactor combines instruction-block addresses that fall within a 'spatial region', a group of adjacent instruction blocks. When an instruction outside the current spatial region retires, the existing spatial region is sent to the temporal compactor.
The temporal compactor tracks a small number of the most-recently-observed spatial region records.
|
inline |
gem5::prefetch::PIF::CompactorEntry::CompactorEntry | ( | Addr | addr, |
unsigned int | prec_size, | ||
unsigned int | succ_size ) |
|
private |
Computes the distance, in cache blocks, from an address to the trigger of the entry.
addr | address to compute the distance from the trigger |
log_blk_distance | log_2(block size of the cache) |
Definition at line 66 of file pif.cc.
References gem5::X86ISA::trigger.
void gem5::prefetch::PIF::CompactorEntry::getPredictedAddresses | ( | unsigned int | log_blk_size, |
std::vector< AddrPriority > & | addresses ) const |
Fills the provided vector with the predicted addresses using the recorded bit vectors of the entry.
log_blk_distance | log_2(block size of the cache) |
addresses | reference to a vector to add the generated addresses |
Definition at line 111 of file pif.cc.
References gem5::ArmISA::i, gem5::RiscvISA::succ, and gem5::X86ISA::trigger.
bool gem5::prefetch::PIF::CompactorEntry::hasAddress | ( | Addr | target, |
unsigned int | log_blk_size ) const |
Checks if the provided address is contained in this spatial region and if its corresponding bit vector entry is set.
target | address to check |
log_blk_distance | log_2(block size of the cache) |
Definition at line 95 of file pif.cc.
References gem5::RiscvISA::succ, and gem5::X86ISA::trigger.
bool gem5::prefetch::PIF::CompactorEntry::inSameSpatialRegion | ( | Addr | addr, |
unsigned int | log_blk_size, | ||
bool | update ) |
Checks if a given address is in the same defined spatial region as the compactor entry.
addr | Address to check if it's inside the spatial region |
log_blk_distance | log_2(block size of the cache) |
update | if true, set the corresponding succ/prec entry |
Definition at line 77 of file pif.cc.
References gem5::MipsISA::pc, gem5::RiscvISA::succ, gem5::X86ISA::trigger, and gem5::Clocked::update().
Referenced by gem5::prefetch::PIF::notifyRetiredInst().
std::vector<bool> gem5::prefetch::PIF::CompactorEntry::prec |
Definition at line 81 of file pif.hh.
Referenced by CompactorEntry().
std::vector<bool> gem5::prefetch::PIF::CompactorEntry::succ |
Definition at line 82 of file pif.hh.
Referenced by CompactorEntry().
Addr gem5::prefetch::PIF::CompactorEntry::trigger |
Definition at line 80 of file pif.hh.
Referenced by CompactorEntry(), and gem5::prefetch::PIF::notifyRetiredInst().