42#ifndef __CPU_EXEC_CONTEXT_HH__
43#define __CPU_EXEC_CONTEXT_HH__
127 panic(
"ExecContext::readMem() should be overridden\n");
141 panic(
"ExecContext::initiateMemRead() should be overridden\n");
169 panic(
"ExecContext::amoMem() should be overridden\n");
180 panic(
"ExecContext::initiateMemAMO() should be overridden\n");
Defines global host-dependent types: Counter, Tick, and (indirectly) {int,uint}{8,...
The ExecContext is an abstract base class the provides the interface used by the ISA to manipulate th...
virtual Fault initiateMemRead(Addr addr, unsigned int size, Request::Flags flags, const std::vector< bool > &byte_enable)
Initiate a timing memory read operation.
virtual void armMonitor(Addr address)=0
virtual uint64_t getHtmTransactionUid() const =0
virtual Fault initiateMemAMO(Addr addr, unsigned int size, Request::Flags flags, AtomicOpFunctorPtr amo_op)
For timing-mode contexts, initiate an atomic AMO (atomic read-modify-write memory operation)
virtual bool mwait(PacketPtr pkt)=0
virtual Fault amoMem(Addr addr, uint8_t *data, unsigned int size, Request::Flags flags, AtomicOpFunctorPtr amo_op)
For atomic-mode contexts, perform an atomic AMO (a.k.a., Atomic Read-Modify-Write Memory Operation)
virtual void setRegOperand(const StaticInst *si, int idx, RegVal val)=0
virtual void * getWritableRegOperand(const StaticInst *si, int idx)=0
virtual void mwaitAtomic(ThreadContext *tc)=0
virtual Fault initiateMemMgmtCmd(Request::Flags flags)=0
Initiate a memory management command with no valid address.
virtual Fault readMem(Addr addr, uint8_t *data, unsigned int size, Request::Flags flags, const std::vector< bool > &byte_enable)
Perform an atomic memory read operation.
virtual void setRegOperand(const StaticInst *si, int idx, const void *val)=0
virtual uint64_t newHtmTransactionUid() const =0
virtual ThreadContext * tcBase() const =0
Returns a pointer to the ThreadContext.
virtual RegVal readMiscReg(int misc_reg)=0
Reads a miscellaneous register, handling any architectural side effects due to reading that register.
virtual void setMiscReg(int misc_reg, RegVal val)=0
Sets a miscellaneous register, handling any architectural side effects due to writing that register.
virtual bool readPredicate() const =0
virtual bool readMemAccPredicate() const =0
virtual const PCStateBase & pcState() const =0
virtual Fault writeMem(uint8_t *data, unsigned int size, Addr addr, Request::Flags flags, uint64_t *res, const std::vector< bool > &byte_enable)=0
For atomic-mode contexts, perform an atomic memory write operation.
virtual RegVal getRegOperand(const StaticInst *si, int idx)=0
virtual void setPredicate(bool val)=0
virtual void setStCondFailures(unsigned int sc_failures)=0
Sets the number of consecutive store conditional failures.
virtual void setMemAccPredicate(bool val)=0
virtual void setMiscRegOperand(const StaticInst *si, int idx, RegVal val)=0
virtual bool inHtmTransactionalState() const =0
virtual void getRegOperand(const StaticInst *si, int idx, void *val)=0
virtual uint64_t getHtmTransactionalDepth() const =0
virtual RegVal readMiscRegOperand(const StaticInst *si, int idx)=0
virtual unsigned int readStCondFailures() const =0
Returns the number of consecutive store conditional failures.
virtual void pcState(const PCStateBase &val)=0
virtual AddressMonitor * getAddrMonitor()=0
virtual void demapPage(Addr vaddr, uint64_t asn)=0
Invalidate a page in the DTLB and ITLB.
A Packet is used to encapsulate a transfer between two objects in the memory system (e....
Base, ISA-independent static instruction class.
ThreadContext is the external interface to all thread state for anything outside of the CPU.
std::unique_ptr< AtomicOpFunctor > AtomicOpFunctorPtr
#define panic(...)
This implements a cprintf based panic() function.
Copyright (c) 2024 - Pranith Kumar Copyright (c) 2020 Inria All rights reserved.
std::shared_ptr< FaultBase > Fault
uint64_t Addr
Address type This will probably be moved somewhere else in the near future.
Declaration of a request, the overall memory request consisting of the parts of the request that are ...