Go to the documentation of this file.
48 #ifndef __CPU_MINOR_EXEC_CONTEXT_HH__
49 #define __CPU_MINOR_EXEC_CONTEXT_HH__
57 #include "debug/MinorExecute.hh"
95 DPRINTF(MinorExecute,
"ExecContext setting PC: %s\n", *
inst->pc);
112 assert(byte_enable.size() == size);
114 size,
addr,
flags,
nullptr,
nullptr, byte_enable);
120 panic(
"ExecContext::initiateMemMgmtCmd() not implemented "
131 assert(byte_enable.size() == size);
133 size,
addr,
flags, res,
nullptr, byte_enable);
142 size,
addr,
flags,
nullptr, std::move(amo_op),
210 panic(
"ExecContext::getHtmTransactionUid() not"
211 "implemented on MinorCPU\n");
218 panic(
"ExecContext::newHtmTransactionUid() not"
219 "implemented on MinorCPU\n");
234 panic(
"ExecContext::getHtmTransactionalDepth() not"
235 "implemented on MinorCPU\n");
bool mwait(PacketPtr pkt) override
RegVal readMiscReg(RegIndex misc_reg) override
void getRegOperand(const StaticInst *si, int idx, void *val) override
Fault initiateMemMgmtCmd(Request::Flags flags) override
Initiate a memory management command with no valid address.
bool inHtmTransactionalState() const override
void * getWritableReg(const RegId &arch_reg) override
void armMonitor(ThreadID tid, Addr address)
constexpr decltype(nullptr) NoFault
RegVal getReg(const RegId &arch_reg) const override
void mwaitAtomic(ThreadID tid, ThreadContext *tc, BaseMMU *mmu)
void * getWritableRegOperand(const StaticInst *si, int idx) override
RegVal readMiscRegNoEffect(int misc_reg) const
RegVal readMiscReg(int misc_reg) override
Reads a miscellaneous register, handling any architectural side effects due to reading that register.
void armMonitor(Addr address) override
bool readPredicate() const override
void setRegOperand(const StaticInst *si, int idx, const void *val) override
SimpleThread & thread
ThreadState object, provides all the architectural state.
Fault writeMem(uint8_t *data, unsigned int size, Addr addr, Request::Flags flags, uint64_t *res, const std::vector< bool > &byte_enable) override
For atomic-mode contexts, perform an atomic memory write operation.
void setMiscReg(RegIndex misc_reg, RegVal val) override
BaseMMU * getMMUPtr() override
MinorCPU is an in-order CPU model with four fixed pipeline stages:
Fault initiateMemAMO(Addr addr, unsigned int size, Request::Flags flags, AtomicOpFunctorPtr amo_op) override
For timing-mode contexts, initiate an atomic AMO (atomic read-modify-write memory operation)
uint64_t newHtmTransactionUid() const override
void setMemAccPredicate(bool val) override
ExecContext(MinorCPU &cpu_, SimpleThread &thread_, Execute &execute_, MinorDynInstPtr inst_)
void setReg(const RegId &arch_reg, RegVal val) override
void mwaitAtomic(ThreadContext *tc) override
The SimpleThread object provides a combination of the ThreadState object and the ThreadContext interf...
Fault initiateMemRead(Addr addr, unsigned int size, Request::Flags flags, const std::vector< bool > &byte_enable) override
Initiate a timing memory read operation.
RegVal readMiscRegOperand(const StaticInst *si, int idx) override
LSQ & getLSQ()
To allow ExecContext to find the LSQ.
bool readMemAccPredicate()
void setStCondFailures(unsigned int st_cond_failures) override
Sets the number of consecutive store conditional failures.
Base, ISA-independent static instruction class.
ThreadContext is the external interface to all thread state for anything outside of the CPU.
void pcState(const PCStateBase &val) override
std::shared_ptr< FaultBase > Fault
bool readPredicate() const
RegVal readMiscRegNoEffect(RegIndex misc_reg) const override
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
const PCStateBase & pcState() const override
void setMemAccPredicate(bool val)
void demapPage(Addr vaddr, uint64_t asn)
MinorDynInstPtr inst
Instruction for the benefit of memory operations and for PC.
void setRegOperand(const StaticInst *si, int idx, RegVal val) override
const PCStateBase & pcState() const override
AddressMonitor * getCpuAddrMonitor(ThreadID tid)
void setPredicate(bool val) override
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
bool readMemAccPredicate() const override
unsigned int readStCondFailures() const override
Returns the number of consecutive store conditional failures.
ContextID contextId() const override
ThreadContext * getTC()
Returns the pointer to this SimpleThread's ThreadContext.
ExecContext bears the exec_context interface for Minor.
Execute & execute
The execute stage so we can peek at its contents.
RegVal getRegOperand(const StaticInst *si, int idx) override
void setMiscReg(int misc_reg, RegVal val) override
Sets a miscellaneous register, handling any architectural side effects due to writing that register.
void demapPage(Addr vaddr, uint64_t asn) override
Invalidate a page in the DTLB and ITLB.
@ MiscRegClass
Control (misc) register.
int ContextID
Globally unique thread context ID.
The ExecContext is an abstract base class the provides the interface used by the ISA to manipulate th...
uint64_t getHtmTransactionalDepth() const override
AddressMonitor * getAddrMonitor() override
bool mwait(ThreadID tid, PacketPtr pkt)
Fault pushRequest(MinorDynInstPtr 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=std::vector< bool >())
Single interface for readMem/writeMem/amoMem to issue requests into the LSQ.
std::unique_ptr< AtomicOpFunctor > AtomicOpFunctorPtr
Reference material can be found at the JEDEC website: UFS standard http://www.jedec....
void setMiscRegOperand(const StaticInst *si, int idx, RegVal val) override
void setPredicate(bool val)
Register ID: describe an architectural register with its class and index.
#define panic(...)
This implements a cprintf based panic() function.
uint64_t getHtmTransactionUid() const override
ThreadContext * tcBase() const override
Returns a pointer to the ThreadContext.
Generated on Sun Jul 30 2023 01:56:52 for gem5 by doxygen 1.8.17