LLVM
8.0.1
|
This class tracks which instructions are in-flight (i.e., dispatched but not retired) in the OoO backend. More...
#include "llvm/MCA/HardwareUnits/RetireControlUnit.h"
Classes | |
struct | RUToken |
Public Member Functions | |
RetireControlUnit (const MCSchedModel &SM) | |
bool | isEmpty () const |
bool | isAvailable (unsigned Quantity=1) const |
unsigned | getMaxRetirePerCycle () const |
unsigned | reserveSlot (const InstRef &IS, unsigned NumMicroOps) |
const RUToken & | peekCurrentToken () const |
void | consumeCurrentToken () |
void | onInstructionExecuted (unsigned TokenID) |
void | dump () const |
Public Member Functions inherited from llvm::mca::HardwareUnit | |
HardwareUnit ()=default | |
virtual | ~HardwareUnit () |
This class tracks which instructions are in-flight (i.e., dispatched but not retired) in the OoO backend.
This class checks on every cycle if/which instructions can be retired. Instructions are retired in program order. In the event of an instruction being retired, the pipeline that owns this RetireControlUnit (RCU) gets notified.
On instruction retired, register updates are all architecturally committed, and any physicall registers previously allocated for the retired instruction are freed.
Definition at line 37 of file RetireControlUnit.h.
llvm::mca::RetireControlUnit::RetireControlUnit | ( | const MCSchedModel & | SM | ) |
Definition at line 23 of file RetireControlUnit.cpp.
References assert(), llvm::MCSchedModel::getExtraProcessorInfo(), llvm::MCSchedModel::hasExtraProcessorInfo(), llvm::MCExtraProcessorInfo::MaxRetirePerCycle, and llvm::MCExtraProcessorInfo::ReorderBufferSize.
void llvm::mca::RetireControlUnit::consumeCurrentToken | ( | ) |
Definition at line 62 of file RetireControlUnit.cpp.
References assert(), llvm::mca::InstRef::getInstruction(), llvm::mca::RetireControlUnit::RUToken::IR, llvm::mca::RetireControlUnit::RUToken::NumSlots, and llvm::mca::Instruction::retire().
Referenced by llvm::mca::RetireStage::cycleStart(), and getMaxRetirePerCycle().
void llvm::mca::RetireControlUnit::dump | ( | ) | const |
Definition at line 81 of file RetireControlUnit.cpp.
References llvm::dbgs().
Referenced by llvm::mca::DispatchStage::dump(), and getMaxRetirePerCycle().
|
inline |
Definition at line 82 of file RetireControlUnit.h.
References consumeCurrentToken(), dump(), onInstructionExecuted(), peekCurrentToken(), and reserveSlot().
Referenced by llvm::mca::RetireStage::cycleStart().
Definition at line 69 of file RetireControlUnit.h.
References llvm::max().
Referenced by reserveSlot().
|
inline |
Definition at line 68 of file RetireControlUnit.h.
Referenced by llvm::mca::RetireStage::cycleStart().
void llvm::mca::RetireControlUnit::onInstructionExecuted | ( | unsigned | TokenID | ) |
Definition at line 74 of file RetireControlUnit.cpp.
Referenced by llvm::mca::RetireStage::execute(), and getMaxRetirePerCycle().
const RetireControlUnit::RUToken & llvm::mca::RetireControlUnit::peekCurrentToken | ( | ) | const |
Definition at line 58 of file RetireControlUnit.cpp.
Referenced by llvm::mca::RetireStage::cycleStart(), and getMaxRetirePerCycle().
Definition at line 41 of file RetireControlUnit.cpp.
References assert(), IR, isAvailable(), and llvm::max().
Referenced by getMaxRetirePerCycle().