gem5  v22.0.0.2
Public Member Functions | Static Protected Attributes | List of all members
gem5::fastmodel::CortexR52TC Class Reference

#include <thread_context.hh>

Inheritance diagram for gem5::fastmodel::CortexR52TC:
gem5::Iris::ThreadContext gem5::ThreadContext gem5::PCEventScope

Public Member Functions

 CortexR52TC (gem5::BaseCPU *cpu, int id, System *system, gem5::BaseMMU *mmu, gem5::BaseISA *isa, iris::IrisConnectionInterface *iris_if, const std::string &iris_path)
 
bool translateAddress (Addr &paddr, Addr vaddr) override
 
void initFromIrisInstance (const ResourceMap &resources) override
 
void sendFunctional (PacketPtr pkt) override
 
RegVal readIntReg (RegIndex reg_idx) const override
 
void setIntReg (RegIndex reg_idx, RegVal val) override
 
RegVal readCCRegFlat (RegIndex idx) const override
 
void setCCRegFlat (RegIndex idx, RegVal val) override
 
const std::vector< iris::MemorySpaceId > & getBpSpaceIds () const override
 
RegVal readMiscRegNoEffect (RegIndex idx) const override
 
void setMiscRegNoEffect (RegIndex idx, const RegVal val) override
 
RegVal readIntRegFlat (RegIndex idx) const override
 
void setIntRegFlat (RegIndex idx, RegVal val) override
 
const ArmISA::VecRegContainerreadVecReg (const RegId &) const override
 
- Public Member Functions inherited from gem5::Iris::ThreadContext
 ThreadContext (gem5::BaseCPU *cpu, int id, System *system, gem5::BaseMMU *mmu, gem5::BaseISA *isa, iris::IrisConnectionInterface *iris_if, const std::string &iris_path)
 
virtual ~ThreadContext ()
 
bool schedule (PCEvent *e) override
 
bool remove (PCEvent *e) override
 
void scheduleInstCountEvent (Event *event, Tick count) override
 
void descheduleInstCountEvent (Event *event) override
 
Tick getCurrentInstCount () override
 
gem5::BaseCPU * getCpuPtr () override
 
int cpuId () const override
 
uint32_t socketId () const override
 
int threadId () const override
 
void setThreadId (int id) override
 
int contextId () const override
 
void setContextId (int id) override
 
BaseMMUgetMMUPtr () override
 
CheckerCPUgetCheckerCpuPtr () override
 
InstDecodergetDecoderPtr () override
 
SystemgetSystemPtr () override
 
BaseISAgetIsaPtr () const override
 
void sendFunctional (PacketPtr pkt) override
 
ProcessgetProcessPtr () override
 
void setProcessPtr (Process *p) override
 
Status status () const override
 
void setStatus (Status new_status) override
 
void activate () override
 Set the status to Active. More...
 
void suspend () override
 Set the status to Suspended. More...
 
void halt () override
 Set the status to Halted. More...
 
void takeOverFrom (gem5::ThreadContext *old_context) override
 
void regStats (const std::string &name) override
 
Tick readLastActivate () override
 
Tick readLastSuspend () override
 
void copyArchRegs (gem5::ThreadContext *tc) override
 
void clearArchRegs () override
 
RegVal getReg (const RegId &reg) const override
 
void getReg (const RegId &reg, void *val) const override
 
void * getWritableReg (const RegId &reg) override
 
void setReg (const RegId &reg, RegVal val) override
 
void setReg (const RegId &reg, const void *val) override
 
virtual ArmISA::VecRegContainergetWritableVecReg (const RegId &reg)
 
virtual RegVal readVecElem (const RegId &reg) const
 
virtual const ArmISA::VecPredRegContainerreadVecPredReg (const RegId &reg) const
 
virtual ArmISA::VecPredRegContainergetWritableVecPredReg (const RegId &reg)
 
virtual RegVal readCCReg (RegIndex reg_idx) const
 
virtual void setVecReg (const RegId &reg, const ArmISA::VecRegContainer &val)
 
virtual void setVecElem (const RegId &reg, RegVal val)
 
virtual void setVecPredReg (const RegId &reg, const ArmISA::VecPredRegContainer &val)
 
virtual void setCCReg (RegIndex reg_idx, RegVal val)
 
void pcStateNoRecord (const PCStateBase &val) override
 
const PCStateBasepcState () const override
 
void pcState (const PCStateBase &val) override
 
RegVal readMiscRegNoEffect (RegIndex misc_reg) const override
 
RegVal readMiscReg (RegIndex misc_reg) override
 
void setMiscRegNoEffect (RegIndex misc_reg, const RegVal val) override
 
void setMiscReg (RegIndex misc_reg, const RegVal val) override
 
RegId flattenRegId (const RegId &regId) const override
 
unsigned readStCondFailures () const override
 
void setStCondFailures (unsigned sc_failures) override
 
void htmAbortTransaction (uint64_t htm_uid, HtmFailureFaultCause cause) override
 
BaseHTMCheckpointPtrgetHtmCheckpointPtr () override
 
void setHtmCheckpointPtr (BaseHTMCheckpointPtr cpt) override
 
RegVal getRegFlat (const RegId &reg) const override
 Flat register interfaces. More...
 
void getRegFlat (const RegId &reg, void *val) const override
 
void * getWritableRegFlat (const RegId &reg) override
 
void setRegFlat (const RegId &reg, RegVal val) override
 
void setRegFlat (const RegId &reg, const void *val) override
 
virtual const ArmISA::VecRegContainerreadVecRegFlat (RegIndex idx) const
 
virtual ArmISA::VecRegContainergetWritableVecRegFlat (RegIndex idx)
 
virtual void setVecRegFlat (RegIndex idx, const ArmISA::VecRegContainer &val)
 
virtual RegVal readVecElemFlat (RegIndex idx) const
 
virtual void setVecElemFlat (RegIndex idx, RegVal val)
 
virtual ArmISA::VecPredRegContainer readVecPredRegFlat (RegIndex idx) const
 
virtual ArmISA::VecPredRegContainergetWritableVecPredRegFlat (RegIndex idx)
 
virtual void setVecPredRegFlat (RegIndex idx, const ArmISA::VecPredRegContainer &val)
 
- Public Member Functions inherited from gem5::ThreadContext
bool getUseForClone ()
 
void setUseForClone (bool new_val)
 
void quiesce ()
 Quiesce thread context. More...
 
void quiesceTick (Tick resume)
 Quiesce, suspend, and schedule activate at resume. More...
 
RegVal readIntReg (RegIndex reg_idx) const
 
RegVal readFloatReg (RegIndex reg_idx) const
 
TheISA::VecRegContainer readVecReg (const RegId &reg) const
 
TheISA::VecRegContainer & getWritableVecReg (const RegId &reg)
 
RegVal readVecElem (const RegId &reg) const
 
RegVal readCCReg (RegIndex reg_idx) const
 
void setIntReg (RegIndex reg_idx, RegVal val)
 
void setFloatReg (RegIndex reg_idx, RegVal val)
 
void setVecReg (const RegId &reg, const TheISA::VecRegContainer &val)
 
void setVecElem (const RegId &reg, RegVal val)
 
void setCCReg (RegIndex reg_idx, RegVal val)
 
void pcState (Addr addr)
 
virtual int exit ()
 
RegVal readIntRegFlat (RegIndex idx) const
 
void setIntRegFlat (RegIndex idx, RegVal val)
 
RegVal readFloatRegFlat (RegIndex idx) const
 
void setFloatRegFlat (RegIndex idx, RegVal val)
 
TheISA::VecRegContainer readVecRegFlat (RegIndex idx) const
 
TheISA::VecRegContainer & getWritableVecRegFlat (RegIndex idx)
 
void setVecRegFlat (RegIndex idx, const TheISA::VecRegContainer &val)
 
RegVal readVecElemFlat (RegIndex idx) const
 
void setVecElemFlat (RegIndex idx, RegVal val)
 
RegVal readCCRegFlat (RegIndex idx) const
 
void setCCRegFlat (RegIndex idx, RegVal val)
 

Static Protected Attributes

static IdxNameMap miscRegIdxNameMap
 
static IdxNameMap intReg32IdxNameMap
 
static IdxNameMap ccRegIdxNameMap
 
static std::vector< iris::MemorySpaceId > bpSpaceIds
 

Additional Inherited Members

- Public Types inherited from gem5::Iris::ThreadContext
typedef std::map< std::string, iris::ResourceInfo > ResourceMap
 
typedef std::vector< iris::ResourceId > ResourceIds
 
typedef std::map< int, std::string > IdxNameMap
 
typedef std::unordered_map< Iris::CanonicalMsn, iris::MemorySpaceId > MemorySpaceMap
 
- Public Types inherited from gem5::ThreadContext
enum  Status { Active, Suspended, Halting, Halted }
 
- Static Public Member Functions inherited from gem5::ThreadContext
static void compare (ThreadContext *one, ThreadContext *two)
 function to compare two thread contexts (for debugging) More...
 
- Public Attributes inherited from gem5::ThreadContext
int intResult = DefaultIntResult
 
double floatResult = DefaultFloatResult
 
int intOffset = 0
 
- Static Public Attributes inherited from gem5::ThreadContext
static const int ints []
 
static const double floats []
 
static const int DefaultIntResult = 0
 
static const double DefaultFloatResult = 0.0
 
- Protected Types inherited from gem5::Iris::ThreadContext
using BpId = uint64_t
 
using BpInfoPtr = std::unique_ptr< BpInfo >
 
using BpInfoMap = std::map< Addr, BpInfoPtr >
 
using BpInfoIt = BpInfoMap::iterator
 
- Protected Member Functions inherited from gem5::Iris::ThreadContext
iris::ResourceId extractResourceId (const ResourceMap &resources, const std::string &name)
 
void extractResourceMap (ResourceIds &ids, const ResourceMap &resources, const IdxNameMap &idx_names)
 
iris::MemorySpaceId getMemorySpaceId (const Iris::CanonicalMsn &msn) const
 
void maintainStepping ()
 
BpInfoIt getOrAllocBp (Addr pc)
 
void installBp (BpInfoIt it)
 
void uninstallBp (BpInfoIt it)
 
void delBp (BpInfoIt it)
 
iris::IrisErrorCode instanceRegistryChanged (uint64_t esId, const iris::IrisValueMap &fields, uint64_t time, uint64_t sInstId, bool syncEc, std::string &error_message_out)
 
iris::IrisErrorCode phaseInitLeave (uint64_t esId, const iris::IrisValueMap &fields, uint64_t time, uint64_t sInstId, bool syncEc, std::string &error_message_out)
 
iris::IrisErrorCode simulationTimeEvent (uint64_t esId, const iris::IrisValueMap &fields, uint64_t time, uint64_t sInstId, bool syncEc, std::string &error_message_out)
 
iris::IrisErrorCode breakpointHit (uint64_t esId, const iris::IrisValueMap &fields, uint64_t time, uint64_t sInstId, bool syncEc, std::string &error_message_out)
 
iris::IrisErrorCode semihostingEvent (uint64_t esId, const iris::IrisValueMap &fields, uint64_t time, uint64_t sInstId, bool syncEc, std::string &error_message_out)
 
iris::IrisCppAdapter & call () const
 
iris::IrisCppAdapter & noThrow () const
 
void readMem (iris::MemorySpaceId space, Addr addr, void *p, size_t size)
 
void writeMem (iris::MemorySpaceId space, Addr addr, const void *p, size_t size)
 
bool translateAddress (Addr &paddr, iris::MemorySpaceId p_space, Addr vaddr, iris::MemorySpaceId v_space)
 
- Protected Attributes inherited from gem5::Iris::ThreadContext
gem5::BaseCPU * _cpu
 
int _threadId
 
ContextID _contextId
 
System_system
 
gem5::BaseMMU_mmu
 
gem5::BaseISA_isa
 
std::string _irisPath
 
iris::InstanceId _instId = iris::IRIS_UINT64_MAX
 
std::vector< ArmISA::VecRegContainervecRegs
 
std::vector< ArmISA::VecPredRegContainervecPredRegs
 
Status _status = Active
 
EventenableAfterPseudoEvent
 
ResourceIds miscRegIds
 
ResourceIds intReg32Ids
 
ResourceIds intReg64Ids
 
ResourceIds flattenedIntIds
 
ResourceIds ccRegIds
 
iris::ResourceId pcRscId = iris::IRIS_UINT64_MAX
 
iris::ResourceId icountRscId
 
ResourceIds vecRegIds
 
ResourceIds vecPredRegIds
 
std::vector< iris::MemorySpaceInfo > memorySpaces
 
std::vector< iris::MemorySupportedAddressTranslationResult > translations
 
MemorySpaceMap memorySpaceIds
 
EventQueue comInstEventQueue
 
BpInfoMap bps
 
iris::EventStreamId regEventStreamId
 
iris::EventStreamId initEventStreamId
 
iris::EventStreamId timeEventStreamId
 
iris::EventStreamId breakpointEventStreamId
 
iris::EventStreamId semihostingEventStreamId
 
iris::IrisInstance client
 
ArmISA::PCState pc
 
- Protected Attributes inherited from gem5::ThreadContext
bool useForClone = false
 

Detailed Description

Definition at line 42 of file thread_context.hh.

Constructor & Destructor Documentation

◆ CortexR52TC()

gem5::fastmodel::CortexR52TC::CortexR52TC ( gem5::BaseCPU *  cpu,
int  id,
System system,
gem5::BaseMMU mmu,
gem5::BaseISA isa,
iris::IrisConnectionInterface *  iris_if,
const std::string &  iris_path 
)

Definition at line 42 of file thread_context.cc.

Member Function Documentation

◆ getBpSpaceIds()

const std::vector< iris::MemorySpaceId > & gem5::fastmodel::CortexR52TC::getBpSpaceIds ( ) const
overridevirtual

◆ initFromIrisInstance()

void gem5::fastmodel::CortexR52TC::initFromIrisInstance ( const ResourceMap resources)
overridevirtual

◆ readCCRegFlat()

RegVal gem5::fastmodel::CortexR52TC::readCCRegFlat ( RegIndex  idx) const
overridevirtual

◆ readIntReg()

RegVal gem5::fastmodel::CortexR52TC::readIntReg ( RegIndex  reg_idx) const
overridevirtual

◆ readIntRegFlat()

RegVal gem5::fastmodel::CortexR52TC::readIntRegFlat ( RegIndex  idx) const
inlineoverridevirtual

Reimplemented from gem5::Iris::ThreadContext.

Definition at line 96 of file thread_context.hh.

References panic.

◆ readMiscRegNoEffect()

RegVal gem5::fastmodel::CortexR52TC::readMiscRegNoEffect ( RegIndex  idx) const
inlineoverridevirtual

◆ readVecReg()

const ArmISA::VecRegContainer& gem5::fastmodel::CortexR52TC::readVecReg ( const RegId ) const
inlineoverridevirtual

Reimplemented from gem5::Iris::ThreadContext.

Definition at line 111 of file thread_context.hh.

References panic.

◆ sendFunctional()

void gem5::fastmodel::CortexR52TC::sendFunctional ( PacketPtr  pkt)
overridevirtual

◆ setCCRegFlat()

void gem5::fastmodel::CortexR52TC::setCCRegFlat ( RegIndex  idx,
RegVal  val 
)
overridevirtual

◆ setIntReg()

void gem5::fastmodel::CortexR52TC::setIntReg ( RegIndex  reg_idx,
RegVal  val 
)
overridevirtual

◆ setIntRegFlat()

void gem5::fastmodel::CortexR52TC::setIntRegFlat ( RegIndex  idx,
RegVal  val 
)
inlineoverridevirtual

Reimplemented from gem5::Iris::ThreadContext.

Definition at line 102 of file thread_context.hh.

References panic.

◆ setMiscRegNoEffect()

void gem5::fastmodel::CortexR52TC::setMiscRegNoEffect ( RegIndex  idx,
const RegVal  val 
)
inlineoverridevirtual

◆ translateAddress()

bool gem5::fastmodel::CortexR52TC::translateAddress ( Addr paddr,
Addr  vaddr 
)
overridevirtual

Implements gem5::Iris::ThreadContext.

Definition at line 50 of file thread_context.cc.

References gem5::MipsISA::vaddr.

Member Data Documentation

◆ bpSpaceIds

std::vector< iris::MemorySpaceId > gem5::fastmodel::CortexR52TC::bpSpaceIds
staticprotected

Definition at line 48 of file thread_context.hh.

Referenced by getBpSpaceIds().

◆ ccRegIdxNameMap

Iris::ThreadContext::IdxNameMap gem5::fastmodel::CortexR52TC::ccRegIdxNameMap
staticprotected

Definition at line 47 of file thread_context.hh.

Referenced by initFromIrisInstance().

◆ intReg32IdxNameMap

Iris::ThreadContext::IdxNameMap gem5::fastmodel::CortexR52TC::intReg32IdxNameMap
staticprotected

Definition at line 46 of file thread_context.hh.

Referenced by initFromIrisInstance().

◆ miscRegIdxNameMap

Iris::ThreadContext::IdxNameMap gem5::fastmodel::CortexR52TC::miscRegIdxNameMap
staticprotected

Definition at line 45 of file thread_context.hh.

Referenced by initFromIrisInstance(), readMiscRegNoEffect(), and setMiscRegNoEffect().


The documentation for this class was generated from the following files:

Generated on Thu Jul 28 2022 13:33:29 for gem5 by doxygen 1.8.17