gem5 v24.0.0.0
|
Classes | |
class | gem5::CircularQueue< T > |
Circular queue. More... | |
class | gem5::Trie< Key, Value > |
A trie is a tree-based data structure used for data retrieval. More... | |
Typedefs | |
typedef Node * | gem5::Trie< Key, Value >::Handle |
Functions | |
gem5::CircularQueue< T >::iterator::iterator (CircularQueue *cq, size_t idx) | |
gem5::CircularQueue< T >::iterator::iterator (const iterator &it) | |
Trait reference type iterator satisfies OutputIterator, therefore reference must be T&. | |
iterator & | gem5::CircularQueue< T >::iterator::operator= (const iterator &it) |
bool | gem5::CircularQueue< T >::iterator::dereferenceable () const |
Test dereferenceability. | |
bool | gem5::CircularQueue< T >::iterator::operator== (const iterator &that) const |
InputIterator. | |
bool | gem5::CircularQueue< T >::iterator::operator!= (const iterator &that) |
Inequality operator. | |
reference | gem5::CircularQueue< T >::iterator::operator* () |
Dereference operator. | |
const_reference | gem5::CircularQueue< T >::iterator::operator* () const |
pointer | gem5::CircularQueue< T >::iterator::operator-> () |
Dereference operator. | |
const_pointer | gem5::CircularQueue< T >::iterator::operator-> () const |
iterator & | gem5::CircularQueue< T >::iterator::operator++ () |
Pre-increment operator. | |
iterator | gem5::CircularQueue< T >::iterator::operator++ (int) |
Post-increment operator. | |
iterator & | gem5::CircularQueue< T >::iterator::operator-- () |
ForwardIterator The multipass guarantee is provided by the reliance on _idx. | |
iterator | gem5::CircularQueue< T >::iterator::operator-- (int) |
Post-decrement operator. | |
iterator & | gem5::CircularQueue< T >::iterator::operator+= (const difference_type &t) |
RandomAccessIterator requirements. | |
iterator & | gem5::CircularQueue< T >::iterator::operator-= (const difference_type &t) |
iterator | gem5::CircularQueue< T >::iterator::operator+ (const difference_type &t) |
Addition operator. | |
iterator | gem5::CircularQueue< T >::iterator::operator- (const difference_type &t) |
Substraction operator. | |
difference_type | gem5::CircularQueue< T >::iterator::operator- (const iterator &that) |
Difference operator. | |
template<typename Idx > | |
std::enable_if_t< std::is_integral_v< Idx >, reference > | gem5::CircularQueue< T >::iterator::operator[] (const Idx &index) |
Index operator. | |
bool | gem5::CircularQueue< T >::iterator::operator< (const iterator &that) const |
Comparisons. | |
bool | gem5::CircularQueue< T >::iterator::operator> (const iterator &that) const |
bool | gem5::CircularQueue< T >::iterator::operator>= (const iterator &that) const |
bool | gem5::CircularQueue< T >::iterator::operator<= (const iterator &that) const |
template<typename Idx > | |
std::enable_if_t< std::is_integral_v< Idx >, reference > | gem5::CircularQueue< T >::operator[] (const Idx &index) |
gem5::CircularQueue< T >::CircularQueue (size_t size=0) | |
void | gem5::CircularQueue< T >::flush () |
Remove all the elements in the queue. | |
reference | gem5::CircularQueue< T >::front () |
reference | gem5::CircularQueue< T >::back () |
size_t | gem5::CircularQueue< T >::head () const |
size_t | gem5::CircularQueue< T >::tail () const |
size_t | gem5::CircularQueue< T >::capacity () const |
size_t | gem5::CircularQueue< T >::size () const |
void | gem5::CircularQueue< T >::pop_front (size_t num_elem=1) |
Circularly increase the head pointer. | |
void | gem5::CircularQueue< T >::pop_back () |
Circularly decrease the tail pointer. | |
void | gem5::CircularQueue< T >::push_back (typename std::vector< T >::value_type val) |
Pushes an element at the end of the queue. | |
void | gem5::CircularQueue< T >::advance_tail () |
Increases the tail by one. | |
void | gem5::CircularQueue< T >::advance_tail (size_t len) |
Increases the tail by a specified number of steps. | |
bool | gem5::CircularQueue< T >::empty () const |
Is the queue empty? | |
bool | gem5::CircularQueue< T >::full () const |
Is the queue full? A queue is full if the head is the 0^{th} element and the tail is the (size-1)^{th} element, or if the head is the n^{th} element and the tail the (n-1)^{th} element. | |
iterator | gem5::CircularQueue< T >::begin () |
Iterators. | |
iterator | gem5::CircularQueue< T >::begin () const |
iterator | gem5::CircularQueue< T >::end () |
iterator | gem5::CircularQueue< T >::end () const |
static bool | gem5::findCarry (int width, uint64_t dest, uint64_t src1, uint64_t src2) |
Calculate the carry flag from an addition. | |
static bool | gem5::findOverflow (int width, uint64_t dest, uint64_t src1, uint64_t src2) |
Calculate the overflow flag from an addition. | |
static bool | gem5::findParity (int width, uint64_t dest) |
Calculate the parity of a value. | |
static bool | gem5::findNegative (int width, uint64_t dest) |
Calculate the negative flag. | |
static bool | gem5::findZero (int width, uint64_t dest) |
Calculate the zero flag. | |
template<uint32_t Poly> | |
uint32_t | gem5::crc32 (const uint8_t *data, uint32_t crc, std::size_t size) |
Evaluate the CRC32 of the first size bytes of a data buffer, using a specific polynomium and an initial value. | |
template<class T > | |
static constexpr std::enable_if_t< std::is_integral_v< T >, int > | gem5::floorLog2 (T x) |
template<class T > | |
static constexpr int | gem5::ceilLog2 (const T &n) |
template<class T > | |
static constexpr bool | gem5::isPowerOf2 (const T &n) |
template<class T , class U > | |
static constexpr T | gem5::divCeil (const T &a, const U &b) |
template<typename T > | |
static constexpr std::enable_if_t< sizeof(T)<=sizeof(uint32_t)> | gem5::mulUnsigned (std::make_unsigned_t< T > &high, std::make_unsigned_t< T > &low, std::make_unsigned_t< T > val_a, std::make_unsigned_t< T > val_b) |
template<typename T > | |
static constexpr std::enable_if_t< sizeof(T)<=sizeof(uint32_t)> | gem5::mulSigned (std::make_signed_t< T > &high, std::make_signed_t< T > &low, std::make_signed_t< T > val_a, std::make_signed_t< T > val_b) |
template<class T , class U > | |
static constexpr T | gem5::roundUp (const T &val, const U &align) |
This function is used to align addresses in memory. | |
template<class T , class U > | |
static constexpr T | gem5::roundDown (const T &val, const U &align) |
This function is used to align addresses in memory. | |
static constexpr int | gem5::log2i (int value) |
Calculate the log2 of a power of 2 integer. | |
template<typename T > | |
std::enable_if_t< std::is_integral_v< T >, T > | gem5::Random::random () |
Use the SFINAE idiom to choose an implementation based on whether the type is integral or floating point. | |
template<typename T > | |
std::enable_if_t< std::is_integral_v< T >, T > | gem5::Random::random (T min, T max) |
gem5::Trie< Key, Value >::Trie () | |
Handle | gem5::Trie< Key, Value >::insert (Key key, unsigned width, Value *val) |
Method which inserts a key/value pair into the trie. | |
Value * | gem5::Trie< Key, Value >::lookup (Key key) |
Method which looks up the Value corresponding to a particular key. | |
Value * | gem5::Trie< Key, Value >::remove (Handle handle) |
Method to delete a value from the trie. | |
Value * | gem5::Trie< Key, Value >::remove (Key key) |
Method to lookup a value from the trie and then delete it. | |
void | gem5::Trie< Key, Value >::clear () |
A method which removes all key/value pairs from the trie. | |
Variables | |
const char * | gem5::compileDate = __DATE__ " " __TIME__ |
std::mt19937_64 | gem5::Random::gen |
Random | gem5::random_mt |
static const unsigned | gem5::Trie< Key, Value >::MaxBits = sizeof(Key) * 8 |
const char * | gem5::gem5Version = "24.0.0.0" |
Friends | |
iterator | gem5::CircularQueue< T >::iterator::operator+ (const difference_type &t, iterator &it) |
iterator | gem5::CircularQueue< T >::iterator::operator- (const difference_type &t, iterator &it) |
using | gem5::CircularQueue< T >::iterator::value_type = T |
Iterator Traits. | |
using | gem5::CircularQueue< T >::iterator::difference_type = std::ptrdiff_t |
using | gem5::CircularQueue< T >::iterator::reference = value_type& |
using | gem5::CircularQueue< T >::iterator::const_reference = const value_type& |
using | gem5::CircularQueue< T >::iterator::pointer = value_type* |
using | gem5::CircularQueue< T >::iterator::const_pointer = const value_type* |
using | gem5::CircularQueue< T >::iterator::iterator_category = std::random_access_iterator_tag |
gem5::Random::Random () | |
gem5::Random::Random (uint32_t s) | |
These are a collection of utility functions and constants defined in src/base.
using gem5::CircularQueue< T >::iterator::const_pointer = const value_type* |
Definition at line 108 of file circular_queue.hh.
using gem5::CircularQueue< T >::iterator::const_reference = const value_type& |
Definition at line 106 of file circular_queue.hh.
using gem5::CircularQueue< T >::iterator::difference_type = std::ptrdiff_t |
Definition at line 104 of file circular_queue.hh.
typedef Node* gem5::Trie< Key, Value >::Handle |
using gem5::CircularQueue< T >::iterator::iterator_category = std::random_access_iterator_tag |
Definition at line 109 of file circular_queue.hh.
using gem5::CircularQueue< T >::iterator::pointer = value_type* |
Definition at line 107 of file circular_queue.hh.
using gem5::CircularQueue< T >::iterator::reference = value_type& |
Definition at line 105 of file circular_queue.hh.
using gem5::CircularQueue< T >::iterator::value_type = T |
Iterator Traits.
Definition at line 103 of file circular_queue.hh.
|
inline |
Increases the tail by one.
This may overwrite the head if the queue is full.
Definition at line 515 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head, gem5::CircularQueue< T >::_size, and gem5::CircularQueue< T >::full().
Referenced by gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), and gem5::CircularQueue< T >::push_back().
|
inline |
Increases the tail by a specified number of steps.
This may overwrite one or more entries starting at the head if the queue is full.
len | Number of steps |
Definition at line 532 of file circular_queue.hh.
References gem5::CircularQueue< T >::_capacity, gem5::CircularQueue< T >::_head, gem5::CircularQueue< T >::_size, and gem5::ArmISA::len.
|
inline |
Definition at line 446 of file circular_queue.hh.
References gem5::CircularQueue< T >::tail().
Referenced by gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::CircularQueue< T >::push_back(), gem5::o3::LSQUnit::squash(), TEST(), and TEST().
|
inline |
Iterators.
Definition at line 565 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head.
Referenced by gem5::o3::LSQUnit::checkSnoop(), gem5::o3::LSQUnit::completeStore(), gem5::o3::LSQUnit::resetState(), gem5::o3::LSQUnit::squash(), TEST(), TEST(), TEST(), TEST(), and TEST().
|
inline |
Definition at line 572 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head.
|
inline |
Definition at line 461 of file circular_queue.hh.
References gem5::CircularQueue< T >::_capacity.
Referenced by gem5::o3::LSQUnit::drainSanityCheck(), gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::o3::LSQUnit::numFreeLoadEntries(), gem5::o3::LSQUnit::numFreeStoreEntries(), and TEST().
|
staticconstexpr |
Definition at line 84 of file intmath.hh.
References gem5::floorLog2(), and gem5::ArmISA::n.
Referenced by gem5::memory::MemCtrl::addToReadQueue(), gem5::memory::MemCtrl::addToWriteQueue(), gem5::memory::DRAMInterface::DRAMInterface(), gem5::TimingExprUn::eval(), gem5::memory::MemCtrl::CtrlStats::regStats(), gem5::RegClass::regType(), and TEST().
|
inlineexplicit |
Definition at line 412 of file circular_queue.hh.
|
inline |
A method which removes all key/value pairs from the trie.
This is more efficient than trying to remove elements individually.
Definition at line 368 of file trie.hh.
References gem5::Trie< Key, Value >::Node::clear(), and gem5::Trie< Key, Value >::head.
uint32_t gem5::crc32 | ( | const uint8_t * | data, |
uint32_t | crc, | ||
std::size_t | size ) |
Evaluate the CRC32 of the first size bytes of a data buffer, using a specific polynomium and an initial value.
The crc is accomplished by reversing the input, the initial value and the output (remainder).
data | Input data buffer pointer |
crc | Initial value of the checksum |
size | Number of bytes |
Definition at line 62 of file crc.hh.
References data, gem5::ArmISA::i, and gem5::reverseBits().
|
inline |
Test dereferenceability.
An iterator is dereferenceable if it is pointing to a non-null circular queue, and the index is within the current range of the queue.
Definition at line 143 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, gem5::CircularQueue< T >::iterator::_idx, and gem5::CircularQueue< T >::isValidIdx().
|
staticconstexpr |
Definition at line 110 of file intmath.hh.
References gem5::ArmISA::a, and gem5::ArmISA::b.
Referenced by gem5::memory::DRAMInterface::activateBank(), gem5::Process::allocateMem(), gem5::ruby::garnet::flit::deserialize(), gem5::memory::DRAMInterface::doBurstAccess(), gem5::memory::qos::MemCtrl::escalateQueues(), gem5::ruby::garnet::NetworkInterface::flitisizeMessage(), gem5::memory::DRAMInterface::Rank::flushCmdList(), gem5::DRAMPower::getDataRate(), gem5::DRAMPower::getTimingParams(), gem5::Gicv3Distributor::Gicv3Distributor(), gem5::Plic::init(), gem5::Wavefront::initRegState(), gem5::GPUComputeDriver::ioctl(), gem5::TrafficGen::parseConfig(), gem5::memory::DRAMInterface::Rank::powerDownSleep(), gem5::memory::DRAMInterface::prechargeBank(), gem5::memory::qos::MemSinkCtrl::processNextReqEvent(), gem5::memory::DRAMInterface::Rank::processRefreshEvent(), gem5::memory::DRAMSim2::readComplete(), gem5::memory::HBMCtrl::recvTimingReq(), gem5::memory::HeteroMemCtrl::recvTimingReq(), gem5::memory::MemCtrl::recvTimingReq(), gem5::memory::qos::MemSinkCtrl::recvTimingReq(), gem5::SerialLink::SerialLinkResponsePort::recvTimingReq(), gem5::SerialLink::SerialLinkRequestPort::recvTimingResp(), gem5::Clocked::resetClock(), gem5::memory::DRAMInterface::Rank::resetStats(), gem5::ruby::Consumer::scheduleEventAbsolute(), gem5::memory::DRAMInterface::Rank::scheduleWakeUpEvent(), gem5::ruby::garnet::flit::serialize(), gem5::memory::DRAMInterface::startup(), TEST(), gem5::AtomicSimpleCPU::tick(), gem5::Clocked::ticksToCycles(), gem5::SerialLink::SerialLinkRequestPort::trySendTiming(), gem5::SerialLink::SerialLinkResponsePort::trySendTiming(), gem5::Clocked::update(), gem5::memory::DRAMInterface::Rank::updatePowerStats(), and gem5::memory::DRAMSim2::writeComplete().
|
inline |
Is the queue empty?
Definition at line 548 of file circular_queue.hh.
References gem5::CircularQueue< T >::_size.
Referenced by gem5::o3::LSQUnit::checkSnoop(), gem5::o3::LSQUnit::completeStore(), gem5::CircularQueue< T >::pop_back(), TEST(), TEST(), and gem5::o3::LSQUnit::writebackStores().
|
inline |
Definition at line 580 of file circular_queue.hh.
References gem5::CircularQueue< T >::tail().
Referenced by gem5::o3::LSQUnit::checkSnoop(), gem5::o3::LSQUnit::checkViolations(), gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::o3::LSQUnit::squash(), TEST(), TEST(), TEST(), and gem5::o3::LSQUnit::writebackStores().
|
inline |
Definition at line 586 of file circular_queue.hh.
References gem5::CircularQueue< T >::tail().
|
inlinestatic |
Calculate the carry flag from an addition.
This should work even when a carry value is also added in.
Parameters: dest: The result value of the addition. src1: One of the addends that was added. src2: The other addend that was added in.
Rationale: This code analyzes the most sig. bits of the source addends and result, and deduces the carry out flag from them without needing the carry in bit.
Observe that we have four cases after an addition regarding the carry in and carry out bits:
If we have no carry in but a carry out: src1 and src2 must both be 1, with the result bit being 0. Hence, ~0 + 1 + 1 => 11, which has a high second bit. We return true.
If we have a carry in and a carry out: src1 and src2 can either be 1 and 0, or vice versa. In this case, the addition with the carry in gives a result bit of 0 but a carry out. Hence, ~0 + 1 + 0 => 10, or ~0 + 0 + 1 => 10. We return true.
Or, src1 and src2 can both be one. Along with the carry, this gives a result of 1 and a carry out of 1. Hence, ~1 + 1 + 1 => 10. We return true.
If we have no carry in and no carry out: src1 and src2 can either be 1 and 0, 0 and 1, or 0 and 0. In the first two cases the result bit is 1, which when negated does not contribute to the sum algorithm at all. In the last case the result bit is zero, but neither src1 nor src2 contribute to the sum either. Hence, ~1 + 1 + 0 => 1, ~1 + 0 + 1 => 1, ~0 + 0 + 0 => 1. So we return false for all of these cases.
If we have a carry in, but no carry out: src1 and src2 can neither be 1. So the overall result bit is 1. Hence: ~1 + 0 + 0 => 0. We return false.
Definition at line 84 of file condcodes.hh.
References gem5::ArmISA::shift, and gem5::ArmISA::width.
Referenced by gem5::X86ISA::RegOpBase::genFlags(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), and TEST().
|
inlinestatic |
Calculate the negative flag.
Definition at line 141 of file condcodes.hh.
References gem5::bits(), and gem5::ArmISA::width.
Referenced by gem5::X86ISA::RegOpBase::genFlags(), TEST(), and TEST().
|
inlinestatic |
Calculate the overflow flag from an addition.
Definition at line 98 of file condcodes.hh.
References gem5::ArmISA::shift, and gem5::ArmISA::width.
Referenced by gem5::X86ISA::RegOpBase::genFlags(), TEST(), TEST(), and TEST().
|
inlinestatic |
Calculate the parity of a value.
1 is for odd parity and 0 is for even.
Parameters: dest: a value to be tested.
Rationale: findParity simply performs bitwise XOR operations on each "pair" of bits in the dest parameter; the procedure being that a pair of ones will be XOR'ed out of the intermediate value.
This process is repeated until one last pair of bits are XOR'ed together. If the intermediate is still one, then there is exactly one high bit which does not have a corresponding high bit. Therefore, the value must have odd parity, and we return 1 accordingly. Otherwise we return 0.
Definition at line 123 of file condcodes.hh.
References gem5::ArmISA::mask, and gem5::ArmISA::width.
Referenced by gem5::X86ISA::RegOpBase::genFlags(), TEST(), TEST(), TEST(), and TEST().
|
inlinestatic |
Calculate the zero flag.
Definition at line 152 of file condcodes.hh.
References gem5::ArmISA::mask, and gem5::ArmISA::width.
Referenced by gem5::X86ISA::RegOpBase::genFlags(), TEST(), TEST(), and TEST().
|
staticconstexpr |
Definition at line 59 of file intmath.hh.
References gem5::ArmISA::ts, gem5::MipsISA::ux, and gem5::RiscvISA::x.
Referenced by gem5::ruby::Histogram::add(), gem5::CheckTable::addCheck(), gem5::AddressManager::AddressManager(), gem5::FetchUnit::FetchBufDesc::allocateBuf(), gem5::ruby::BankedArray::BankedArray(), gem5::ceilLog2(), gem5::ruby::DirectoryMemory::DirectoryMemory(), gem5::branch_prediction::SimpleIndirectPredictor::getSetIndex(), gem5::Gicv2m::Gicv2m(), gem5::StackDistProbe::handleRequest(), gem5::prefetch::BOP::hash(), gem5::ruby::CacheMemory::init(), gem5::LupioBLK::lupioBLKRead(), gem5::ruby::RubySystem::RubySystem(), gem5::prefetch::Base::setParentInfo(), gem5::branch_prediction::SimpleBTB::SimpleBTB(), and TEST().
|
inline |
Remove all the elements in the queue.
Note: This does not actually remove elements from the backing store.
Definition at line 423 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head, and gem5::CircularQueue< T >::_size.
Referenced by gem5::prefetch::DeltaCorrelatingPredictionTables::DCPTEntry::invalidate().
|
inline |
Definition at line 441 of file circular_queue.hh.
References gem5::CircularQueue< T >::head().
Referenced by gem5::o3::LSQUnit::commitLoad(), gem5::o3::LSQUnit::commitLoads(), gem5::o3::LSQUnit::commitStores(), gem5::o3::LSQUnit::completeStore(), gem5::o3::LSQUnit::getLoadHeadSeqNum(), gem5::o3::LSQUnit::getStoreHeadSeqNum(), gem5::prefetch::SBOOE::notifyFill(), TEST(), and TEST().
|
inline |
Is the queue full? A queue is full if the head is the 0^{th} element and the tail is the (size-1)^{th} element, or if the head is the n^{th} element and the tail the (n-1)^{th} element.
Definition at line 558 of file circular_queue.hh.
References gem5::CircularQueue< T >::_capacity, and gem5::CircularQueue< T >::_size.
Referenced by gem5::CircularQueue< T >::advance_tail(), gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::prefetch::DeltaCorrelatingPredictionTables::DCPTEntry::invalidate(), gem5::o3::LSQUnit::lqFull(), gem5::prefetch::SBOOE::notifyFill(), gem5::o3::LSQUnit::sqFull(), and TEST().
|
inline |
Definition at line 451 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head.
Referenced by gem5::o3::LSQUnit::completeStore(), gem5::CircularQueue< T >::front(), gem5::o3::LSQUnit::getLoadHead(), gem5::o3::LSQUnit::getStoreHead(), gem5::CircularQueue< T >::iterator::operator--(), gem5::CircularQueue< T >::iterator::operator-=(), gem5::o3::LSQUnit::read(), TEST(), TEST(), TEST(), gem5::o3::LSQUnit::write(), and gem5::o3::LSQUnit::writebackStores().
|
inline |
Method which inserts a key/value pair into the trie.
key | The key which can later be used to look up this value. |
width | How many bits of the key (from msb) should be used. |
val | A pointer to the value to store in the trie. |
Definition at line 204 of file trie.hh.
References gem5::Trie< Key, Value >::extendMask(), gem5::Trie< Key, Value >::goesAfter(), gem5::Trie< Key, Value >::head, gem5::ArmISA::i, gem5::Trie< Key, Value >::Node::kids, gem5::Trie< Key, Value >::Node::mask, gem5::Trie< Key, Value >::MaxBits, panic, gem5::Trie< Key, Value >::Node::parent, gem5::X86ISA::val, gem5::Trie< Key, Value >::Node::value, and gem5::ArmISA::width.
Referenced by gem5::X86ISA::TLB::insert().
|
staticconstexpr |
Definition at line 98 of file intmath.hh.
References gem5::ArmISA::n.
Referenced by gem5::FetchUnit::FetchBufDesc::allocateBuf(), gem5::BaseIndexingPolicy::BaseIndexingPolicy(), gem5::BaseSetAssoc::BaseSetAssoc(), gem5::branch_prediction::BiModeBP::BiModeBP(), gem5::ChunkGenerator::ChunkGenerator(), gem5::memory::DRAMInterface::DRAMInterface(), gem5::EmulationPageTable::EmulationPageTable(), gem5::PciIoBar::EndBitUnion(), gem5::FALRU::FALRU(), gem5::Gicv2m::Gicv2m(), gem5::branch_prediction::StatisticalCorrector::SCThreadHistory::initLocalHistory(), gem5::prefetch::IrregularStreamBuffer::IrregularStreamBuffer(), gem5::branch_prediction::LocalBP::LocalBP(), gem5::log2i(), gem5::MemFootprintProbe::MemFootprintProbe(), gem5::PciMemBar::PciMemBar(), gem5::roundDown(), gem5::roundUp(), gem5::ruby::RubySystem::RubySystem(), gem5::SectorTags::SectorTags(), gem5::branch_prediction::SimpleBTB::SimpleBTB(), gem5::branch_prediction::SimpleIndirectPredictor::SimpleIndirectPredictor(), gem5::prefetch::STeMS::STeMS(), gem5::o3::StoreSet::StoreSet(), TEST(), gem5::branch_prediction::TournamentBP::TournamentBP(), and gem5::StackDistCalc::updateTree().
|
inline |
Definition at line 94 of file circular_queue.hh.
|
inline |
Trait reference type iterator satisfies OutputIterator, therefore reference must be T&.
Definition at line 121 of file circular_queue.hh.
|
staticconstexpr |
Calculate the log2 of a power of 2 integer.
An | input value |
Definition at line 295 of file intmath.hh.
References gem5::ctz32(), and gem5::isPowerOf2().
|
inline |
Method which looks up the Value corresponding to a particular key.
key | The key to look up. |
Definition at line 291 of file trie.hh.
References gem5::Trie< Key, Value >::lookupHandle(), and gem5::Trie< Key, Value >::Node::value.
Referenced by gem5::X86ISA::TLB::demapPage(), gem5::X86ISA::TLB::insert(), and gem5::X86ISA::TLB::lookup().
|
staticconstexpr |
Definition at line 133 of file intmath.hh.
Referenced by gem5::mulSigned(), TEST(), TEST(), and TEST().
|
staticconstexpr |
Definition at line 120 of file intmath.hh.
Referenced by gem5::mulSignedManual(), gem5::mulUnsigned(), TEST(), TEST(), and TEST().
|
inline |
Inequality operator.
Conversely, two iterators are different if they both point to different circular queues or they point to different elements.
Definition at line 170 of file circular_queue.hh.
|
inline |
Dereference operator.
Definition at line 178 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, and gem5::CircularQueue< T >::iterator::_idx.
|
inline |
Definition at line 188 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, and gem5::CircularQueue< T >::iterator::_idx.
|
inline |
|
inline |
Pre-increment operator.
Definition at line 213 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_idx.
|
inline |
Post-increment operator.
Definition at line 225 of file circular_queue.hh.
References gem5::ArmISA::t.
|
inline |
RandomAccessIterator requirements.
Definition at line 271 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_idx, and gem5::ArmISA::t.
|
inline |
Substraction operator.
Definition at line 316 of file circular_queue.hh.
References gem5::ArmISA::t.
|
inline |
Difference operator.
that + ret == this
Definition at line 339 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_idx.
|
inline |
ForwardIterator The multipass guarantee is provided by the reliance on _idx.
BidirectionalIterator requirements. Pre-decrement operator.
Definition at line 244 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, gem5::CircularQueue< T >::iterator::_idx, and gem5::CircularQueue< T >::head().
|
inline |
Post-decrement operator.
Definition at line 258 of file circular_queue.hh.
References gem5::ArmISA::t.
|
inline |
Definition at line 281 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, gem5::CircularQueue< T >::iterator::_idx, gem5::CircularQueue< T >::head(), and gem5::ArmISA::t.
|
inline |
Dereference operator.
Rely on operator* to check for dereferenceability.
Definition at line 200 of file circular_queue.hh.
|
inline |
Definition at line 205 of file circular_queue.hh.
|
inline |
Comparisons.
Definition at line 362 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_idx.
|
inline |
Definition at line 381 of file circular_queue.hh.
|
inline |
Definition at line 127 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, and gem5::CircularQueue< T >::iterator::_idx.
|
inline |
InputIterator.
Equality operator. Two iterators must point to the same, possibly null, circular queue and the same element on it to be equal.
Definition at line 158 of file circular_queue.hh.
References gem5::CircularQueue< T >::iterator::_cq, and gem5::CircularQueue< T >::iterator::_idx.
|
inline |
Definition at line 371 of file circular_queue.hh.
|
inline |
Definition at line 376 of file circular_queue.hh.
|
inline |
Index operator.
The use of * tests for dereferenceability.
Definition at line 352 of file circular_queue.hh.
References gem5::MipsISA::index.
|
inline |
Definition at line 395 of file circular_queue.hh.
References gem5::CircularQueue< T >::_capacity, gem5::CircularQueue< T >::data, and gem5::MipsISA::index.
|
inline |
Circularly decrease the tail pointer.
Definition at line 490 of file circular_queue.hh.
References gem5::CircularQueue< T >::_size, and gem5::CircularQueue< T >::empty().
Referenced by gem5::o3::LSQUnit::squash().
|
inline |
Circularly increase the head pointer.
By increasing the head pointer we are removing elements from the begin of the circular queue.
@params num_elem number of elements to remove
Definition at line 477 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head, gem5::CircularQueue< T >::_size, and gem5::CircularQueue< T >::size().
Referenced by gem5::o3::LSQUnit::commitLoad(), gem5::o3::LSQUnit::completeStore(), and TEST().
|
inline |
Pushes an element at the end of the queue.
Definition at line 502 of file circular_queue.hh.
References gem5::CircularQueue< T >::advance_tail(), gem5::CircularQueue< T >::back(), and gem5::X86ISA::val.
Referenced by gem5::ruby::RubyPrefetcher::accessUnitFilter(), gem5::prefetch::PIF::calculatePrefetch(), gem5::prefetch::DeltaCorrelatingPredictionTables::DCPTEntry::invalidate(), gem5::prefetch::SBOOE::notifyFill(), gem5::prefetch::PIF::notifyRetiredInst(), TEST(), TEST(), TEST(), TEST(), TEST(), TEST(), and TEST().
gem5::Random::Random | ( | ) |
Definition at line 51 of file random.cc.
References gem5::statistics::init.
gem5::Random::Random | ( | uint32_t | s | ) |
Definition at line 57 of file random.cc.
References gem5::statistics::init, and gem5::ArmISA::s.
|
inline |
Use the SFINAE idiom to choose an implementation based on whether the type is integral or floating point.
Definition at line 90 of file random.hh.
References gem5::statistics::dist, and gem5::Random::gen.
Referenced by gem5::AddressManager::AddressManager(), gem5::branch_prediction::MPP_TAGE::adjustAlloc(), gem5::branch_prediction::TAGE_SC_L_TAGE::adjustAlloc(), gem5::RiscvProcess::argsInit(), gem5::branch_prediction::TAGE_SC_L_TAGE::calcDep(), gem5::Check::Check(), gem5::GUPSGen::createNextReq(), gem5::SpatterAccess::createPacket(), gem5::Linux::devRandom(), gem5::GarnetSyntheticTraffic::generatePkt(), gem5::DramGen::genStartAddr(), gem5::HybridGen::genStartAddr(), gem5::NvmGen::genStartAddr(), gem5::AddressManager::getAtomicLoc(), gem5::memory::CfiMemory::getLatency(), gem5::memory::SimpleMemory::getLatency(), gem5::AddressManager::AtomicStruct::getLoadLoc(), gem5::DramGen::getNextPacket(), gem5::HybridGen::getNextPacket(), gem5::LinearGen::getNextPacket(), gem5::NvmGen::getNextPacket(), gem5::RandomGen::getNextPacket(), gem5::StridedGen::getNextPacket(), gem5::CheckTable::getRandomCheck(), gem5::getrandomFunc(), gem5::AddressManager::AtomicStruct::getStoreLoc(), gem5::replacement_policy::Random::getVictim(), gem5::branch_prediction::MPP_TAGE::handleAllocAndUReset(), gem5::branch_prediction::TAGE_SC_L_TAGE_8KB::handleAllocAndUReset(), gem5::Episode::initActions(), gem5::Check::initiate(), gem5::SeriesRequestGenerator::initiate(), gem5::Check::initiateAction(), gem5::Check::initiateCheck(), gem5::Check::initiateFlush(), gem5::Check::initiatePrefetch(), gem5::SimpleCache::insert(), gem5::TesterThread::issueNewEpisode(), gem5::branch_prediction::LoopPredictor::loopUpdate(), gem5::HybridGen::nextPacketTick(), gem5::LinearGen::nextPacketTick(), gem5::RandomGen::nextPacketTick(), gem5::StridedGen::nextPacketTick(), gem5::TrafficGen::nextState(), gem5::branch_prediction::MPP_LoopPredictor::optionalAgeInc(), gem5::branch_prediction::TAGE_SC_L_LoopPredictor::optionalAgeInc(), gem5::ARMArchTLB::pickEntryIdxToReplace(), gem5::ConfigCache::pickEntryIdxToReplace(), gem5::IPACache::pickEntryIdxToReplace(), gem5::SMMUTLB::pickEntryIdxToReplace(), gem5::WalkCache::pickEntryIdxToReplace(), gem5::Check::pickInitiatingNode(), gem5::Check::pickValue(), gem5::ruby::random_time(), gem5::RandomStreamGen::randomPick(), gem5::ArmISA::ISA::readMiscReg(), gem5::replacement_policy::BIP::reset(), gem5::replacement_policy::BRRIP::reset(), gem5::ruby::WeightBased::route(), gem5::EtherSwitch::Interface::switchingDelay(), gem5::GarnetSyntheticTraffic::tick(), gem5::MemTest::tick(), gem5::o3::Fetch::tick(), gem5::branch_prediction::MultiperspectivePerceptron::train(), gem5::DistEtherLink::TxLink::transmit(), gem5::EtherLink::Link::transmit(), gem5::VirtIORng::RngQueue::trySend(), gem5::branch_prediction::LTAGE::update(), gem5::branch_prediction::MultiperspectivePerceptron::update(), gem5::branch_prediction::MultiperspectivePerceptronTAGE::update(), gem5::branch_prediction::TAGE::update(), and gem5::branch_prediction::TAGE_SC_L::update().
|
inline |
Definition at line 113 of file random.hh.
References gem5::statistics::dist, and gem5::Random::gen.
|
inline |
Method to delete a value from the trie.
node | A Handle to remove. |
Definition at line 308 of file trie.hh.
References gem5::Trie< Key, Value >::Node::kids, panic, gem5::Trie< Key, Value >::Node::parent, gem5::Trie< Key, Value >::remove(), gem5::X86ISA::val, and gem5::Trie< Key, Value >::Node::value.
Referenced by gem5::X86ISA::TLB::demapPage(), gem5::X86ISA::TLB::flushAll(), gem5::X86ISA::TLB::flushNonGlobal(), gem5::Trie< Key, Value >::remove(), and gem5::Trie< Key, Value >::remove().
|
inline |
Method to lookup a value from the trie and then delete it.
key | The key to look up and then remove. |
Definition at line 353 of file trie.hh.
References gem5::Trie< Key, Value >::lookupHandle(), and gem5::Trie< Key, Value >::remove().
|
staticconstexpr |
This function is used to align addresses in memory.
val | is the address to be aligned. |
align | is the alignment. Can only be a power of 2. |
align | which is less than or equal to |
val. |
Definition at line 279 of file intmath.hh.
References gem5::isPowerOf2(), gem5::ArmISA::mask, and gem5::X86ISA::val.
Referenced by gem5::Process::allocateMem(), gem5::AtomicSimpleCPU::amoMem(), gem5::ArmProcess::argsInit(), gem5::MipsProcess::argsInit(), gem5::PowerProcess::argsInit(), gem5::RiscvProcess::argsInit(), gem5::SparcProcess::argsInit(), gem5::X86ISA::X86Process::argsInit(), gem5::TLBCoalescer::canCoalesce(), gem5::VegaTLBCoalescer::canCoalesce(), gem5::FetchUnit::FetchBufDesc::checkWaveReleaseBuf(), gem5::Shader::doFunctionalAccess(), gem5::MemState::fixupFault(), gem5::VegaISA::GpuTLB::handleFuncTranslationReturn(), gem5::X86ISA::GpuTLB::handleFuncTranslationReturn(), gem5::StackDistProbe::handleRequest(), gem5::TimingSimpleCPU::initiateMemAMO(), gem5::TimingSimpleCPU::initiateMemRead(), gem5::initMemReqHelper(), gem5::initMemReqScalarHelper(), gem5::RiscvSemihosting::isSemihostingEBreak(), gem5::VegaISA::GpuTLB::issueTLBLookup(), gem5::X86ISA::GpuTLB::issueTLBLookup(), gem5::BaseCPU::mwaitAtomic(), gem5::prefetch::Base::pageAddress(), gem5::TLBCoalescer::processProbeTLBEvent(), gem5::VegaTLBCoalescer::processProbeTLBEvent(), gem5::TLBCoalescer::CpuSidePort::recvFunctional(), gem5::VegaISA::GpuTLB::CpuSidePort::recvFunctional(), gem5::VegaTLBCoalescer::CpuSidePort::recvFunctional(), gem5::X86ISA::GpuTLB::CpuSidePort::recvFunctional(), gem5::VegaISA::GpuTLB::CpuSidePort::recvTimingReq(), gem5::ComputeUnit::DTLBPort::recvTimingResp(), gem5::VegaISA::GpuTLB::MemSidePort::recvTimingResp(), gem5::X86ISA::GpuTLB::MemSidePort::recvTimingResp(), gem5::prefetch::Base::samePage(), TEST(), gem5::ComputeUnit::updatePageDivergenceDist(), gem5::TLBCoalescer::updatePhysAddresses(), gem5::VegaTLBCoalescer::updatePhysAddresses(), gem5::VegaISA::GpuTLB::walkerResponse(), and gem5::TimingSimpleCPU::writeMem().
|
staticconstexpr |
This function is used to align addresses in memory.
val | is the address to be aligned. |
align | is the alignment. Can only be a power of 2. |
align | which is greater than or equal to |
val. |
Definition at line 260 of file intmath.hh.
References gem5::isPowerOf2(), gem5::ArmISA::mask, and gem5::X86ISA::val.
Referenced by gem5::ArmProcess::argsInit(), gem5::MipsProcess::argsInit(), gem5::PowerProcess::argsInit(), gem5::RiscvProcess::argsInit(), gem5::SparcProcess::argsInit(), gem5::X86ISA::X86Process::argsInit(), gem5::ArmProcess32::ArmProcess32(), gem5::ArmProcess64::ArmProcess64(), gem5::ChunkGenerator::ChunkGenerator(), gem5::memory::PhysicalMemory::createBackingStore(), gem5::guest_abi::Argument< Aapcs32, Composite, typename std::enable_if_t< IsAapcs32CompositeV< Composite > > >::get(), gem5::X86ISA::I386Process::I386Process(), gem5::X86ISA::FsWorkload::initState(), gem5::guest_abi::Aapcs32ArgumentBase::loadFromStack(), gem5::guest_abi::Aapcs64ArgumentBase::loadFromStack(), gem5::MipsProcess::MipsProcess(), gem5::Shader::mmap(), gem5::mmapFunc(), gem5::mremapFunc(), gem5::munmapFunc(), gem5::o3::DynInst::operator new(), gem5::PowerProcess::PowerProcess(), gem5::RiscvProcess32::RiscvProcess32(), gem5::RiscvProcess64::RiscvProcess64(), gem5::ChunkGenerator::setNext(), gem5::Sparc32Process::Sparc32Process(), gem5::Sparc64Process::Sparc64Process(), TEST(), gem5::AMDGPUVM::AGPTranslationGen::translate(), gem5::AMDGPUVM::GARTTranslationGen::translate(), gem5::AMDGPUVM::MMHUBTranslationGen::translate(), gem5::AMDGPUVM::UserTranslationGen::translate(), gem5::BaseMMU::MMUTranslationGen::translate(), gem5::EmulationPageTable::PageTableTranslationGen::translate(), gem5::Process::updateBias(), gem5::MemState::updateBrkRegion(), and gem5::X86ISA::X86_64Process::X86_64Process().
|
inline |
Definition at line 466 of file circular_queue.hh.
References gem5::CircularQueue< T >::_size.
Referenced by gem5::o3::LSQUnit::commitLoads(), gem5::o3::LSQUnit::commitStores(), gem5::o3::LSQUnit::dumpInsts(), gem5::o3::LSQUnit::executeStore(), gem5::o3::LSQUnit::getCount(), gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::o3::LSQUnit::lqEmpty(), gem5::prefetch::SBOOE::notifyFill(), gem5::o3::LSQUnit::numFreeLoadEntries(), gem5::o3::LSQUnit::numFreeStoreEntries(), gem5::o3::LSQUnit::numLoads(), gem5::o3::LSQUnit::numStores(), gem5::CircularQueue< T >::pop_front(), gem5::o3::LSQUnit::sqEmpty(), gem5::o3::LSQUnit::squash(), gem5::o3::LSQUnit::startStaleTranslationFlush(), TEST(), TEST(), TEST(), and gem5::o3::LSQUnit::write().
|
inline |
Definition at line 456 of file circular_queue.hh.
References gem5::CircularQueue< T >::_head, and gem5::CircularQueue< T >::_size.
Referenced by gem5::CircularQueue< T >::back(), gem5::CircularQueue< T >::end(), gem5::CircularQueue< T >::end(), gem5::o3::LSQUnit::insertLoad(), gem5::o3::LSQUnit::insertStore(), gem5::prefetch::PIF::notifyRetiredInst(), gem5::o3::LSQUnit::squash(), TEST(), TEST(), and TEST().
|
inline |
const char * gem5::compileDate = __DATE__ " " __TIME__ |
Definition at line 35 of file date.cc.
Referenced by gem5::pybind_init_core().
const char * gem5::gem5Version = "24.0.0.0" |
Definition at line 35 of file version.cc.
Referenced by gem5::pybind_init_core().
std::mt19937_64 gem5::Random::gen |
Definition at line 69 of file random.hh.
Referenced by gem5::Random::init(), gem5::Random::random(), gem5::Random::random(), gem5::MinorCPU::randomPriority(), gem5::Random::serialize(), and gem5::Random::unserialize().
|
static |
Definition at line 127 of file trie.hh.
Referenced by gem5::Trie< Key, Value >::extendMask(), and gem5::Trie< Key, Value >::insert().
Random gem5::random_mt |
Definition at line 99 of file random.cc.
Referenced by gem5::AddressManager::AddressManager(), gem5::branch_prediction::MPP_TAGE::adjustAlloc(), gem5::branch_prediction::TAGE_SC_L_TAGE::adjustAlloc(), gem5::RiscvProcess::argsInit(), gem5::branch_prediction::TAGE_SC_L_TAGE::calcDep(), gem5::Check::Check(), gem5::GUPSGen::createNextReq(), gem5::SpatterAccess::createPacket(), gem5::GarnetSyntheticTraffic::generatePkt(), gem5::DramGen::genStartAddr(), gem5::HybridGen::genStartAddr(), gem5::NvmGen::genStartAddr(), gem5::AddressManager::getAtomicLoc(), gem5::memory::CfiMemory::getLatency(), gem5::memory::SimpleMemory::getLatency(), gem5::AddressManager::AtomicStruct::getLoadLoc(), gem5::DramGen::getNextPacket(), gem5::HybridGen::getNextPacket(), gem5::LinearGen::getNextPacket(), gem5::NvmGen::getNextPacket(), gem5::RandomGen::getNextPacket(), gem5::StridedGen::getNextPacket(), gem5::CheckTable::getRandomCheck(), gem5::getrandomFunc(), gem5::AddressManager::AtomicStruct::getStoreLoc(), gem5::replacement_policy::Random::getVictim(), gem5::branch_prediction::MPP_TAGE::handleAllocAndUReset(), gem5::branch_prediction::TAGE_SC_L_TAGE_8KB::handleAllocAndUReset(), gem5::DistIface::init(), gem5::Episode::initActions(), gem5::Check::initiate(), gem5::SeriesRequestGenerator::initiate(), gem5::Check::initiateAction(), gem5::Check::initiateCheck(), gem5::Check::initiateFlush(), gem5::Check::initiatePrefetch(), gem5::SimpleCache::insert(), gem5::TesterThread::issueNewEpisode(), gem5::branch_prediction::LoopPredictor::loopUpdate(), gem5::HybridGen::nextPacketTick(), gem5::LinearGen::nextPacketTick(), gem5::RandomGen::nextPacketTick(), gem5::StridedGen::nextPacketTick(), gem5::TrafficGen::nextState(), gem5::branch_prediction::MPP_LoopPredictor::optionalAgeInc(), gem5::branch_prediction::TAGE_SC_L_LoopPredictor::optionalAgeInc(), gem5::Check::pickInitiatingNode(), gem5::Check::pickValue(), gem5::ProtocolTester::ProtocolTester(), gem5::pybind_init_core(), gem5::ruby::random_time(), gem5::RandomStreamGen::randomPick(), gem5::MinorCPU::randomPriority(), gem5::ArmISA::ISA::readMiscReg(), gem5::replacement_policy::BIP::reset(), gem5::replacement_policy::BRRIP::reset(), gem5::ruby::WeightBased::route(), gem5::EtherSwitch::Interface::switchingDelay(), gem5::GarnetSyntheticTraffic::tick(), gem5::MemTest::tick(), gem5::o3::Fetch::tick(), gem5::branch_prediction::MultiperspectivePerceptron::train(), gem5::DistEtherLink::TxLink::transmit(), gem5::EtherLink::Link::transmit(), gem5::VirtIORng::RngQueue::trySend(), gem5::branch_prediction::LTAGE::update(), gem5::branch_prediction::MultiperspectivePerceptron::update(), gem5::branch_prediction::MultiperspectivePerceptronTAGE::update(), gem5::branch_prediction::TAGE::update(), and gem5::branch_prediction::TAGE_SC_L::update().
|
friend |
Definition at line 304 of file circular_queue.hh.
|
friend |
Definition at line 326 of file circular_queue.hh.