gem5
v20.0.0.0
|
#include <lsq.hh>
Classes | |
class | DcachePort |
DcachePort class for the load/store queue. More... | |
class | LSQRequest |
Memory operation metadata. More... | |
class | LSQSenderState |
Derived class to hold any sender state the LSQ needs. More... | |
class | SingleDataRequest |
class | SplitDataRequest |
Public Types | |
typedef Impl::O3CPU | O3CPU |
typedef Impl::DynInstPtr | DynInstPtr |
typedef Impl::CPUPol::IEW | IEW |
typedef Impl::CPUPol::LSQUnit | LSQUnit |
Public Member Functions | |
LSQ (O3CPU *cpu_ptr, IEW *iew_ptr, DerivO3CPUParams *params) | |
Constructs an LSQ with the given parameters. More... | |
~LSQ () | |
std::string | name () const |
Returns the name of the LSQ. More... | |
void | regStats () |
Registers statistics of each LSQ unit. More... | |
void | setActiveThreads (std::list< ThreadID > *at_ptr) |
Sets the pointer to the list of active threads. More... | |
void | drainSanityCheck () const |
Perform sanity checks after a drain. More... | |
bool | isDrained () const |
Has the LSQ drained? More... | |
void | takeOverFrom () |
Takes over execution from another CPU's thread. More... | |
int | entryAmount (ThreadID num_threads) |
Number of entries needed for the given amount of threads. More... | |
void | tick () |
Ticks the LSQ. More... | |
void | insertLoad (const DynInstPtr &load_inst) |
Inserts a load into the LSQ. More... | |
void | insertStore (const DynInstPtr &store_inst) |
Inserts a store into the LSQ. More... | |
Fault | executeLoad (const DynInstPtr &inst) |
Executes a load. More... | |
Fault | executeStore (const DynInstPtr &inst) |
Executes a store. More... | |
void | commitLoads (InstSeqNum &youngest_inst, ThreadID tid) |
Commits loads up until the given sequence number for a specific thread. More... | |
void | commitStores (InstSeqNum &youngest_inst, ThreadID tid) |
Commits stores up until the given sequence number for a specific thread. More... | |
void | writebackStores () |
Attempts to write back stores until all cache ports are used or the interface becomes blocked. More... | |
void | writebackStores (ThreadID tid) |
Same as above, but only for one thread. More... | |
void | squash (const InstSeqNum &squashed_num, ThreadID tid) |
Squash instructions from a thread until the specified sequence number. More... | |
bool | violation () |
Returns whether or not there was a memory ordering violation. More... | |
bool | violation (ThreadID tid) |
Returns whether or not there was a memory ordering violation for a specific thread. More... | |
DynInstPtr | getMemDepViolator (ThreadID tid) |
Gets the instruction that caused the memory ordering violation. More... | |
int | getLoadHead (ThreadID tid) |
Returns the head index of the load queue for a specific thread. More... | |
InstSeqNum | getLoadHeadSeqNum (ThreadID tid) |
Returns the sequence number of the head of the load queue. More... | |
int | getStoreHead (ThreadID tid) |
Returns the head index of the store queue. More... | |
InstSeqNum | getStoreHeadSeqNum (ThreadID tid) |
Returns the sequence number of the head of the store queue. More... | |
int | getCount () |
Returns the number of instructions in all of the queues. More... | |
int | getCount (ThreadID tid) |
Returns the number of instructions in the queues of one thread. More... | |
int | numLoads () |
Returns the total number of loads in the load queue. More... | |
int | numLoads (ThreadID tid) |
Returns the total number of loads for a single thread. More... | |
int | numStores () |
Returns the total number of stores in the store queue. More... | |
int | numStores (ThreadID tid) |
Returns the total number of stores for a single thread. More... | |
unsigned | numFreeLoadEntries () |
Returns the number of free load entries. More... | |
unsigned | numFreeStoreEntries () |
Returns the number of free store entries. More... | |
unsigned | numFreeEntries (ThreadID tid) |
Returns the number of free entries for a specific thread. More... | |
unsigned | numFreeLoadEntries (ThreadID tid) |
Returns the number of free entries in the LQ for a specific thread. More... | |
unsigned | numFreeStoreEntries (ThreadID tid) |
Returns the number of free entries in the SQ for a specific thread. More... | |
bool | isFull () |
Returns if the LSQ is full (either LQ or SQ is full). More... | |
bool | isFull (ThreadID tid) |
Returns if the LSQ is full for a specific thread (either LQ or SQ is full). More... | |
bool | isEmpty () const |
Returns if the LSQ is empty (both LQ and SQ are empty). More... | |
bool | lqEmpty () const |
Returns if all of the LQs are empty. More... | |
bool | sqEmpty () const |
Returns if all of the SQs are empty. More... | |
bool | lqFull () |
Returns if any of the LQs are full. More... | |
bool | lqFull (ThreadID tid) |
Returns if the LQ of a given thread is full. More... | |
bool | sqFull () |
Returns if any of the SQs are full. More... | |
bool | sqFull (ThreadID tid) |
Returns if the SQ of a given thread is full. More... | |
bool | isStalled () |
Returns if the LSQ is stalled due to a memory operation that must be replayed. More... | |
bool | isStalled (ThreadID tid) |
Returns if the LSQ of a specific thread is stalled due to a memory operation that must be replayed. More... | |
bool | hasStoresToWB () |
Returns whether or not there are any stores to write back to memory. More... | |
bool | hasStoresToWB (ThreadID tid) |
Returns whether or not a specific thread has any stores to write back to memory. More... | |
int | numStoresToWB (ThreadID tid) |
Returns the number of stores a specific thread has to write back. More... | |
bool | willWB () |
Returns if the LSQ will write back to memory this cycle. More... | |
bool | willWB (ThreadID tid) |
Returns if the LSQ of a specific thread will write back to memory this cycle. More... | |
void | dumpInsts () const |
Debugging function to print out all instructions. More... | |
void | dumpInsts (ThreadID tid) const |
Debugging function to print out instructions from a specific thread. More... | |
Fault | read (LSQRequest *req, int load_idx) |
Executes a read operation, using the load specified at the load index. More... | |
Fault | write (LSQRequest *req, uint8_t *data, int store_idx) |
Executes a store operation, using the store specified at the store index. More... | |
void | recvReqRetry () |
Retry the previous send that failed. More... | |
void | completeDataAccess (PacketPtr pkt) |
bool | recvTimingResp (PacketPtr pkt) |
Handles writing back and completing the load or store that has returned from memory. More... | |
void | recvTimingSnoopReq (PacketPtr pkt) |
Fault | pushRequest (const DynInstPtr &inst, bool isLoad, uint8_t *data, unsigned int size, Addr addr, Request::Flags flags, uint64_t *res, AtomicOpFunctorPtr amo_op, const std::vector< bool > &byte_enable) |
bool | cacheBlocked () const |
Is D-cache blocked? More... | |
void | cacheBlocked (bool v) |
Set D-cache blocked status. More... | |
bool | cachePortAvailable (bool is_load) const |
Is any store port available to use? More... | |
void | cachePortBusy (bool is_load) |
Another store port is in use. More... | |
MasterPort & | getDataPort () |
Public Attributes | |
O3CPU * | cpu |
The CPU pointer. More... | |
IEW * | iewStage |
The IEW stage pointer. More... | |
Static Protected Member Functions | |
static uint32_t | maxLSQAllocation (SMTQueuePolicy pol, uint32_t entries, uint32_t numThreads, uint32_t SMTThreshold) |
Auxiliary function to calculate per-thread max LSQ allocation limit. More... | |
Protected Attributes | |
bool | _cacheBlocked |
D-cache is blocked. More... | |
int | cacheStorePorts |
The number of cache ports available each cycle (stores only). More... | |
int | usedStorePorts |
The number of used cache ports in this cycle by stores. More... | |
int | cacheLoadPorts |
The number of cache ports available each cycle (loads only). More... | |
int | usedLoadPorts |
The number of used cache ports in this cycle by loads. More... | |
SMTQueuePolicy | lsqPolicy |
The LSQ policy for SMT mode. More... | |
std::list< ThreadID > * | activeThreads |
List of Active Threads in System. More... | |
unsigned | LQEntries |
Total Size of LQ Entries. More... | |
unsigned | SQEntries |
Total Size of SQ Entries. More... | |
unsigned | maxLQEntries |
Max LQ Size - Used to Enforce Sharing Policies. More... | |
unsigned | maxSQEntries |
Max SQ Size - Used to Enforce Sharing Policies. More... | |
DcachePort | dcachePort |
Data port. More... | |
std::vector< LSQUnit > | thread |
The LSQ units for individual threads. More... | |
ThreadID | numThreads |
Number of Threads. More... | |
typedef Impl::DynInstPtr LSQ< Impl >::DynInstPtr |
LSQ< Impl >::LSQ | ( | O3CPU * | cpu_ptr, |
IEW * | iew_ptr, | ||
DerivO3CPUParams * | params | ||
) |
Constructs an LSQ with the given parameters.
Definition at line 61 of file lsq_impl.hh.
References LSQ< Impl >::cpu, LSQ< Impl >::dcachePort, DPRINTF, LSQ< Impl >::lsqPolicy, LSQ< Impl >::maxLQEntries, LSQ< Impl >::maxSQEntries, LSQ< Impl >::numThreads, panic, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::SplitDataRequest::~SplitDataRequest().
Definition at line 822 of file lsq.hh.
References LSQ< Impl >::drainSanityCheck(), LSQ< Impl >::entryAmount(), LSQ< Impl >::executeLoad(), LSQ< Impl >::executeStore(), LSQ< Impl >::insertLoad(), LSQ< Impl >::insertStore(), LSQ< Impl >::LSQSenderState::inst, LSQ< Impl >::isDrained(), LSQ< Impl >::name(), LSQ< Impl >::regStats(), LSQ< Impl >::setActiveThreads(), LSQ< Impl >::takeOverFrom(), and LSQ< Impl >::tick().
bool LSQ< Impl >::cacheBlocked | ( | ) | const |
Is D-cache blocked?
Definition at line 191 of file lsq_impl.hh.
References LSQ< Impl >::_cacheBlocked.
Referenced by LSQ< Impl >::recvReqRetry(), and LSQUnit< Impl >::trySendPacket().
void LSQ< Impl >::cacheBlocked | ( | bool | v | ) |
Set D-cache blocked status.
Definition at line 198 of file lsq_impl.hh.
References LSQ< Impl >::_cacheBlocked, and ArmISA::v.
bool LSQ< Impl >::cachePortAvailable | ( | bool | is_load | ) | const |
Is any store port available to use?
Definition at line 205 of file lsq_impl.hh.
References LSQ< Impl >::cacheLoadPorts, LSQ< Impl >::cacheStorePorts, LSQ< Impl >::usedLoadPorts, and LSQ< Impl >::usedStorePorts.
Referenced by LSQ< Impl >::cachePortBusy(), LSQUnit< Impl >::trySendPacket(), and LSQUnit< Impl >::writebackStores().
void LSQ< Impl >::cachePortBusy | ( | bool | is_load | ) |
Another store port is in use.
Definition at line 218 of file lsq_impl.hh.
References LSQ< Impl >::cachePortAvailable(), LSQ< Impl >::usedLoadPorts, and LSQ< Impl >::usedStorePorts.
Referenced by LSQUnit< Impl >::trySendPacket().
|
inline |
Commits loads up until the given sequence number for a specific thread.
Definition at line 860 of file lsq.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::tick().
|
inline |
Commits stores up until the given sequence number for a specific thread.
Definition at line 866 of file lsq.hh.
References LSQ< Impl >::thread, and LSQ< Impl >::writebackStores().
Referenced by DefaultIEW< Impl >::tick().
Definition at line 315 of file lsq_impl.hh.
References LSQ< Impl >::cpu, Packet::senderState, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::dumpInsts().
void LSQ< Impl >::drainSanityCheck | ( | ) | const |
Perform sanity checks after a drain.
Definition at line 138 of file lsq_impl.hh.
References LSQ< Impl >::isDrained(), LSQ< Impl >::numThreads, and LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::drainSanityCheck(), and LSQ< Impl >::~LSQ().
void LSQ< Impl >::dumpInsts | ( | ) | const |
Debugging function to print out all instructions.
Definition at line 672 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::willWB().
Debugging function to print out instructions from a specific thread.
Definition at line 1008 of file lsq.hh.
References addr, LSQ< Impl >::completeDataAccess(), data, LSQ< Impl >::LSQSenderState::isLoad, LSQ< Impl >::pushRequest(), LSQ< Impl >::read(), LSQ< Impl >::recvReqRetry(), LSQ< Impl >::recvTimingResp(), LSQ< Impl >::recvTimingSnoopReq(), LSQ< Impl >::thread, and LSQ< Impl >::write().
Number of entries needed for the given amount of threads.
Referenced by LSQ< Impl >::~LSQ().
Fault LSQ< Impl >::executeLoad | ( | const DynInstPtr & | inst | ) |
Executes a load.
Definition at line 248 of file lsq_impl.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::executeInsts(), and LSQ< Impl >::~LSQ().
Fault LSQ< Impl >::executeStore | ( | const DynInstPtr & | inst | ) |
Executes a store.
Definition at line 257 of file lsq_impl.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::executeInsts(), and LSQ< Impl >::~LSQ().
int LSQ< Impl >::getCount | ( | ) |
Returns the number of instructions in all of the queues.
Definition at line 379 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and Stats::total.
Referenced by LSQ< Impl >::getStoreHeadSeqNum(), and DefaultIEW< Impl >::tick().
Returns the number of instructions in the queues of one thread.
Definition at line 924 of file lsq.hh.
References LSQ< Impl >::numLoads(), and LSQ< Impl >::thread.
|
inline |
Definition at line 1056 of file lsq.hh.
References LSQ< Impl >::dcachePort.
Referenced by DefaultIEW< Impl >::startupStage().
Returns the head index of the load queue for a specific thread.
Definition at line 902 of file lsq.hh.
References LSQ< Impl >::thread.
|
inline |
Returns the sequence number of the head of the load queue.
Definition at line 906 of file lsq.hh.
References LSQ< Impl >::thread.
|
inline |
Gets the instruction that caused the memory ordering violation.
Definition at line 896 of file lsq.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::executeInsts().
Returns the head index of the store queue.
Definition at line 912 of file lsq.hh.
References LSQ< Impl >::thread.
|
inline |
Returns the sequence number of the head of the store queue.
Definition at line 916 of file lsq.hh.
References LSQ< Impl >::getCount(), and LSQ< Impl >::thread.
bool LSQ< Impl >::hasStoresToWB | ( | ) |
Returns whether or not there are any stores to write back to memory.
Definition at line 638 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads.
Referenced by DefaultIEW< Impl >::hasStoresToWB(), and LSQ< Impl >::numStores().
Returns whether or not a specific thread has any stores to write back to memory.
Definition at line 993 of file lsq.hh.
References LSQ< Impl >::thread.
void LSQ< Impl >::insertLoad | ( | const DynInstPtr & | load_inst | ) |
Inserts a load into the LSQ.
Definition at line 230 of file lsq_impl.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::dispatchInsts(), and LSQ< Impl >::~LSQ().
void LSQ< Impl >::insertStore | ( | const DynInstPtr & | store_inst | ) |
Inserts a store into the LSQ.
Definition at line 239 of file lsq_impl.hh.
References LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::dispatchInsts(), and LSQ< Impl >::~LSQ().
bool LSQ< Impl >::isDrained | ( | ) | const |
Has the LSQ drained?
Definition at line 148 of file lsq_impl.hh.
References DPRINTF, LSQ< Impl >::lqEmpty(), and LSQ< Impl >::sqEmpty().
Referenced by LSQ< Impl >::drainSanityCheck(), DefaultIEW< Impl >::isDrained(), and LSQ< Impl >::~LSQ().
bool LSQ< Impl >::isEmpty | ( | ) | const |
Returns if the LSQ is empty (both LQ and SQ are empty).
Definition at line 512 of file lsq_impl.hh.
References LSQ< Impl >::lqEmpty(), and LSQ< Impl >::sqEmpty().
Referenced by LSQ< Impl >::numStores().
bool LSQ< Impl >::isFull | ( | ) |
Returns if the LSQ is full (either LQ or SQ is full).
Definition at line 483 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, LSQ< Impl >::lqFull(), LSQ< Impl >::sqFull(), and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::isFull(), and LSQ< Impl >::numStores().
Returns if the LSQ is full for a specific thread (either LQ or SQ is full).
Definition at line 500 of file lsq_impl.hh.
References LSQ< Impl >::isFull(), LSQ< Impl >::lsqPolicy, and LSQ< Impl >::thread.
bool LSQ< Impl >::isStalled | ( | ) |
Returns if the LSQ is stalled due to a memory operation that must be replayed.
Definition at line 611 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::isStalled(), and LSQ< Impl >::numStores().
Returns if the LSQ of a specific thread is stalled due to a memory operation that must be replayed.
Definition at line 628 of file lsq_impl.hh.
References LSQ< Impl >::isStalled(), LSQ< Impl >::lsqPolicy, and LSQ< Impl >::thread.
bool LSQ< Impl >::lqEmpty | ( | ) | const |
Returns if all of the LQs are empty.
Definition at line 519 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::isDrained(), LSQ< Impl >::isEmpty(), and LSQ< Impl >::numStores().
bool LSQ< Impl >::lqFull | ( | ) |
Returns if any of the LQs are full.
Definition at line 553 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::dispatchInsts(), LSQ< Impl >::isFull(), LSQ< Impl >::lqFull(), and LSQ< Impl >::numStores().
Returns if the LQ of a given thread is full.
Definition at line 570 of file lsq_impl.hh.
References LSQ< Impl >::lqFull(), LSQ< Impl >::lsqPolicy, and LSQ< Impl >::thread.
|
inlinestaticprotected |
Auxiliary function to calculate per-thread max LSQ allocation limit.
Depending on a policy, number of entries and possibly number of threads and threshold, this function calculates how many resources each thread can occupy at most.
Definition at line 1080 of file lsq.hh.
References LSQ< Impl >::numThreads.
std::string LSQ< Impl >::name | ( | ) | const |
Returns the name of the LSQ.
Definition at line 113 of file lsq_impl.hh.
References LSQ< Impl >::iewStage.
Referenced by LSQ< Impl >::~LSQ().
Returns the number of free entries for a specific thread.
Referenced by LSQ< Impl >::numStores().
unsigned LSQ< Impl >::numFreeLoadEntries | ( | ) |
Returns the number of free load entries.
Definition at line 433 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, LSQ< Impl >::thread, and Stats::total.
Referenced by DefaultIEW< Impl >::clearStates(), LSQ< Impl >::numStores(), DefaultIEW< Impl >::startupStage(), and DefaultIEW< Impl >::tick().
Returns the number of free entries in the LQ for a specific thread.
Definition at line 469 of file lsq_impl.hh.
References LSQ< Impl >::thread.
unsigned LSQ< Impl >::numFreeStoreEntries | ( | ) |
Returns the number of free store entries.
Definition at line 451 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, LSQ< Impl >::thread, and Stats::total.
Referenced by DefaultIEW< Impl >::clearStates(), LSQ< Impl >::numStores(), DefaultIEW< Impl >::startupStage(), and DefaultIEW< Impl >::tick().
Returns the number of free entries in the SQ for a specific thread.
Definition at line 476 of file lsq_impl.hh.
References LSQ< Impl >::thread.
int LSQ< Impl >::numLoads | ( | ) |
Returns the total number of loads in the load queue.
Definition at line 397 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and Stats::total.
Referenced by LSQ< Impl >::getCount().
Returns the total number of loads for a single thread.
Definition at line 929 of file lsq.hh.
References LSQ< Impl >::numStores(), and LSQ< Impl >::thread.
int LSQ< Impl >::numStores | ( | ) |
Returns the total number of stores in the store queue.
Definition at line 415 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, LSQ< Impl >::thread, and Stats::total.
Referenced by LSQ< Impl >::numLoads().
Returns the total number of stores for a single thread.
Definition at line 934 of file lsq.hh.
References LSQ< Impl >::hasStoresToWB(), LSQ< Impl >::isEmpty(), LSQ< Impl >::isFull(), LSQ< Impl >::isStalled(), LSQ< Impl >::lqEmpty(), LSQ< Impl >::lqFull(), LSQ< Impl >::numFreeEntries(), LSQ< Impl >::numFreeLoadEntries(), LSQ< Impl >::numFreeStoreEntries(), LSQ< Impl >::sqEmpty(), LSQ< Impl >::sqFull(), and LSQ< Impl >::thread.
Returns the number of stores a specific thread has to write back.
Definition at line 996 of file lsq.hh.
References LSQ< Impl >::thread, and LSQ< Impl >::willWB().
Referenced by LSQ< Impl >::writebackStores().
Fault LSQ< Impl >::pushRequest | ( | const DynInstPtr & | inst, |
bool | isLoad, | ||
uint8_t * | data, | ||
unsigned int | size, | ||
Addr | addr, | ||
Request::Flags | flags, | ||
uint64_t * | res, | ||
AtomicOpFunctorPtr | amo_op, | ||
const std::vector< bool > & | byte_enable | ||
) |
Definition at line 686 of file lsq_impl.hh.
References LSQ< Impl >::LSQRequest::_byteEnable, LSQ< Impl >::cpu, LSQ< Impl >::LSQRequest::getVaddr(), LSQ< Impl >::LSQRequest::initiateTranslation(), LSQ< Impl >::LSQRequest::isMemAccessRequired(), LSQ< Impl >::LSQRequest::isTranslationComplete(), NoFault, LSQ< Impl >::LSQRequest::request(), LSQ< Impl >::LSQRequest::taskId(), LSQ< Impl >::thread, and transferNeedsBurst().
Referenced by LSQ< Impl >::dumpInsts().
Fault LSQ< Impl >::read | ( | LSQRequest * | req, |
int | load_idx | ||
) |
Executes a read operation, using the load specified at the load index.
Definition at line 1123 of file lsq.hh.
References LSQ< Impl >::cpu, LSQ< Impl >::LSQRequest::request(), and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::dumpInsts().
void LSQ< Impl >::recvReqRetry | ( | ) |
Retry the previous send that failed.
Definition at line 303 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, LSQ< Impl >::cacheBlocked(), LSQ< Impl >::iewStage, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::dumpInsts(), and LSQ< Impl >::DcachePort::recvFunctionalSnoop().
Handles writing back and completing the load or store that has returned from memory.
pkt | Response packet from the memory sub-system |
Definition at line 324 of file lsq_impl.hh.
References LSQ< Impl >::cpu, DPRINTF, Packet::getAddr(), Packet::isError(), Packet::isInvalidate(), LSQ< Impl >::numThreads, panic_if, Packet::senderState, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::DcachePort::DcachePort(), LSQ< Impl >::dumpInsts(), LSQ< Impl >::LSQRequest::isSplit(), LSQ< Impl >::SingleDataRequest::~SingleDataRequest(), and LSQ< Impl >::SplitDataRequest::~SplitDataRequest().
Definition at line 362 of file lsq_impl.hh.
References Packet::cmdString(), DPRINTF, Packet::getAddr(), Packet::isInvalidate(), LSQ< Impl >::numThreads, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::DcachePort::DcachePort(), and LSQ< Impl >::dumpInsts().
void LSQ< Impl >::regStats | ( | ) |
Registers statistics of each LSQ unit.
Definition at line 120 of file lsq_impl.hh.
References LSQ< Impl >::numThreads, and LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::regStats(), and LSQ< Impl >::~LSQ().
Sets the pointer to the list of active threads.
Definition at line 130 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads.
Referenced by DefaultIEW< Impl >::setActiveThreads(), and LSQ< Impl >::~LSQ().
bool LSQ< Impl >::sqEmpty | ( | ) | const |
Returns if all of the SQs are empty.
Definition at line 536 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::isDrained(), LSQ< Impl >::isEmpty(), and LSQ< Impl >::numStores().
bool LSQ< Impl >::sqFull | ( | ) |
Returns if any of the SQs are full.
Definition at line 582 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads.
Referenced by DefaultIEW< Impl >::dispatchInsts(), LSQ< Impl >::isFull(), LSQ< Impl >::numStores(), and LSQ< Impl >::sqFull().
Returns if the SQ of a given thread is full.
Definition at line 599 of file lsq_impl.hh.
References LSQ< Impl >::lsqPolicy, LSQ< Impl >::sqFull(), and LSQ< Impl >::thread.
|
inline |
Squash instructions from a thread until the specified sequence number.
Definition at line 881 of file lsq.hh.
References LSQ< Impl >::thread, and LSQ< Impl >::violation().
Referenced by DefaultIEW< Impl >::squash().
void LSQ< Impl >::takeOverFrom | ( | ) |
Takes over execution from another CPU's thread.
Definition at line 167 of file lsq_impl.hh.
References LSQ< Impl >::_cacheBlocked, LSQ< Impl >::numThreads, LSQ< Impl >::thread, and LSQ< Impl >::usedStorePorts.
Referenced by DefaultIEW< Impl >::takeOverFrom(), and LSQ< Impl >::~LSQ().
void LSQ< Impl >::tick | ( | ) |
Ticks the LSQ.
Definition at line 179 of file lsq_impl.hh.
References LSQ< Impl >::_cacheBlocked, LSQ< Impl >::cacheLoadPorts, LSQ< Impl >::iewStage, LSQ< Impl >::usedLoadPorts, and LSQ< Impl >::usedStorePorts.
Referenced by DefaultIEW< Impl >::tick(), and LSQ< Impl >::~LSQ().
bool LSQ< Impl >::violation | ( | ) |
Returns whether or not there was a memory ordering violation.
Definition at line 285 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, and LSQ< Impl >::thread.
Referenced by DefaultIEW< Impl >::executeInsts(), and LSQ< Impl >::squash().
Returns whether or not there was a memory ordering violation for a specific thread.
Definition at line 892 of file lsq.hh.
References LSQ< Impl >::thread.
bool LSQ< Impl >::willWB | ( | ) |
Returns if the LSQ will write back to memory this cycle.
Definition at line 655 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads.
Referenced by LSQ< Impl >::numStoresToWB(), and DefaultIEW< Impl >::updateStatus().
Returns if the LSQ of a specific thread will write back to memory this cycle.
Definition at line 1003 of file lsq.hh.
References LSQ< Impl >::dumpInsts(), and LSQ< Impl >::thread.
Fault LSQ< Impl >::write | ( | LSQRequest * | req, |
uint8_t * | data, | ||
int | store_idx | ||
) |
Executes a store operation, using the store specified at the store index.
Definition at line 1132 of file lsq.hh.
References LSQ< Impl >::cpu, LSQ< Impl >::LSQRequest::request(), and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::dumpInsts().
void LSQ< Impl >::writebackStores | ( | ) |
Attempts to write back stores until all cache ports are used or the interface becomes blocked.
Definition at line 266 of file lsq_impl.hh.
References LSQ< Impl >::activeThreads, DPRINTF, LSQ< Impl >::numStoresToWB(), and LSQ< Impl >::thread.
Referenced by LSQ< Impl >::commitStores(), and DefaultIEW< Impl >::tick().
Same as above, but only for one thread.
|
protected |
D-cache is blocked.
Definition at line 1060 of file lsq.hh.
Referenced by LSQ< Impl >::cacheBlocked(), LSQ< Impl >::takeOverFrom(), and LSQ< Impl >::tick().
List of Active Threads in System.
Definition at line 1098 of file lsq.hh.
Referenced by LSQ< Impl >::dumpInsts(), LSQ< Impl >::getCount(), LSQ< Impl >::hasStoresToWB(), LSQ< Impl >::isFull(), LSQ< Impl >::isStalled(), LSQ< Impl >::lqEmpty(), LSQ< Impl >::lqFull(), LSQ< Impl >::numFreeLoadEntries(), LSQ< Impl >::numFreeStoreEntries(), LSQ< Impl >::numLoads(), LSQ< Impl >::numStores(), LSQ< Impl >::recvReqRetry(), LSQ< Impl >::setActiveThreads(), LSQ< Impl >::sqEmpty(), LSQ< Impl >::sqFull(), LSQ< Impl >::violation(), LSQ< Impl >::willWB(), and LSQ< Impl >::writebackStores().
|
protected |
The number of cache ports available each cycle (loads only).
Definition at line 1066 of file lsq.hh.
Referenced by LSQ< Impl >::cachePortAvailable(), and LSQ< Impl >::tick().
|
protected |
The number of cache ports available each cycle (stores only).
Definition at line 1062 of file lsq.hh.
Referenced by LSQ< Impl >::cachePortAvailable().
The CPU pointer.
Definition at line 1042 of file lsq.hh.
Referenced by LSQ< Impl >::completeDataAccess(), LSQ< Impl >::LSQ(), LSQ< Impl >::pushRequest(), LSQ< Impl >::read(), LSQ< Impl >::recvTimingResp(), LSQ< Impl >::DcachePort::recvTimingSnoopReq(), and LSQ< Impl >::write().
|
protected |
Data port.
Definition at line 1112 of file lsq.hh.
Referenced by LSQ< Impl >::getDataPort(), and LSQ< Impl >::LSQ().
The IEW stage pointer.
Definition at line 1045 of file lsq.hh.
Referenced by LSQ< Impl >::name(), LSQ< Impl >::recvReqRetry(), and LSQ< Impl >::tick().
|
protected |
|
protected |
The LSQ policy for SMT mode.
Definition at line 1072 of file lsq.hh.
Referenced by LSQ< Impl >::isFull(), LSQ< Impl >::isStalled(), LSQ< Impl >::lqFull(), LSQ< Impl >::LSQ(), and LSQ< Impl >::sqFull().
|
protected |
Max LQ Size - Used to Enforce Sharing Policies.
Definition at line 1106 of file lsq.hh.
Referenced by LSQ< Impl >::LSQ().
|
protected |
Max SQ Size - Used to Enforce Sharing Policies.
Definition at line 1109 of file lsq.hh.
Referenced by LSQ< Impl >::LSQ().
Number of Threads.
Definition at line 1118 of file lsq.hh.
Referenced by LSQ< Impl >::drainSanityCheck(), LSQ< Impl >::LSQ(), LSQ< Impl >::maxLSQAllocation(), LSQ< Impl >::recvTimingResp(), LSQ< Impl >::recvTimingSnoopReq(), LSQ< Impl >::regStats(), and LSQ< Impl >::takeOverFrom().
|
protected |
|
protected |
The LSQ units for individual threads.
Definition at line 1115 of file lsq.hh.
Referenced by LSQ< Impl >::commitLoads(), LSQ< Impl >::commitStores(), LSQ< Impl >::completeDataAccess(), LSQ< Impl >::drainSanityCheck(), LSQ< Impl >::dumpInsts(), LSQ< Impl >::executeLoad(), LSQ< Impl >::executeStore(), LSQ< Impl >::getCount(), LSQ< Impl >::getLoadHead(), LSQ< Impl >::getLoadHeadSeqNum(), LSQ< Impl >::getMemDepViolator(), LSQ< Impl >::getStoreHead(), LSQ< Impl >::getStoreHeadSeqNum(), LSQ< Impl >::hasStoresToWB(), LSQ< Impl >::insertLoad(), LSQ< Impl >::insertStore(), LSQ< Impl >::isFull(), LSQ< Impl >::LSQRequest::isSplit(), LSQ< Impl >::isStalled(), LSQ< Impl >::lqEmpty(), LSQ< Impl >::lqFull(), LSQ< Impl >::LSQ(), LSQ< Impl >::numFreeLoadEntries(), LSQ< Impl >::numFreeStoreEntries(), LSQ< Impl >::numLoads(), LSQ< Impl >::numStores(), LSQ< Impl >::numStoresToWB(), LSQ< Impl >::pushRequest(), LSQ< Impl >::read(), LSQ< Impl >::recvReqRetry(), LSQ< Impl >::recvTimingResp(), LSQ< Impl >::recvTimingSnoopReq(), LSQ< Impl >::regStats(), LSQ< Impl >::sqEmpty(), LSQ< Impl >::sqFull(), LSQ< Impl >::squash(), LSQ< Impl >::takeOverFrom(), LSQ< Impl >::violation(), LSQ< Impl >::willWB(), LSQ< Impl >::write(), LSQ< Impl >::writebackStores(), LSQ< Impl >::SingleDataRequest::~SingleDataRequest(), and LSQ< Impl >::SplitDataRequest::~SplitDataRequest().
|
protected |
The number of used cache ports in this cycle by loads.
Definition at line 1068 of file lsq.hh.
Referenced by LSQ< Impl >::cachePortAvailable(), LSQ< Impl >::cachePortBusy(), and LSQ< Impl >::tick().
|
protected |
The number of used cache ports in this cycle by stores.
Definition at line 1064 of file lsq.hh.
Referenced by LSQ< Impl >::cachePortAvailable(), LSQ< Impl >::cachePortBusy(), LSQ< Impl >::takeOverFrom(), and LSQ< Impl >::tick().