gem5
v21.2.1.0
|
#include <isa.hh>
Public Types | |
enum | CP0EventType { UpdateCP0 } |
typedef ISA | CP0 |
using | Params = MipsISAParams |
![]() | |
typedef std::vector< RegClass > | RegClasses |
![]() | |
typedef SimObjectParams | Params |
Public Member Functions | |
void | clear () |
PCStateBase * | newPCState (Addr new_inst_addr=0) const override |
void | configCP () |
unsigned | getVPENum (ThreadID tid) const |
void | updateCP0ReadView (int misc_reg, ThreadID tid) |
RegVal | readMiscRegNoEffect (int misc_reg, ThreadID tid=0) const |
RegVal | readMiscReg (int misc_reg, ThreadID tid=0) |
RegVal | filterCP0Write (int misc_reg, int reg_sel, RegVal val) |
This method doesn't need to adjust the Control Register Offset since it has already been done in the calling method (setRegWithEffect) More... | |
void | setRegMask (int misc_reg, RegVal val, ThreadID tid=0) |
void | setMiscRegNoEffect (int misc_reg, RegVal val, ThreadID tid=0) |
void | setMiscReg (int misc_reg, RegVal val, ThreadID tid=0) |
void | processCP0Event (BaseCPU *cpu, CP0EventType) |
Process a CP0 event. More... | |
void | scheduleCP0Update (BaseCPU *cpu, Cycles delay=Cycles(0)) |
void | updateCPU (BaseCPU *cpu) |
ISA (const Params &p) | |
RegId | flattenRegId (const RegId ®Id) const |
int | flattenIntIndex (int reg) const |
int | flattenFloatIndex (int reg) const |
int | flattenVecIndex (int reg) const |
int | flattenVecElemIndex (int reg) const |
int | flattenVecPredIndex (int reg) const |
int | flattenCCIndex (int reg) const |
int | flattenMiscIndex (int reg) const |
bool | inUserMode () const override |
void | copyRegsFrom (ThreadContext *src) override |
![]() | |
virtual void | takeOverFrom (ThreadContext *new_tc, ThreadContext *old_tc) |
virtual void | setThreadContext (ThreadContext *_tc) |
virtual uint64_t | getExecutingAsid () const |
const RegClasses & | regClasses () const |
virtual void | handleLockedRead (const RequestPtr &req) |
virtual void | handleLockedRead (ExecContext *xc, const RequestPtr &req) |
virtual bool | handleLockedWrite (const RequestPtr &req, Addr cacheBlockMask) |
virtual bool | handleLockedWrite (ExecContext *xc, const RequestPtr &req, Addr cacheBlockMask) |
virtual void | handleLockedSnoop (PacketPtr pkt, Addr cacheBlockMask) |
virtual void | handleLockedSnoop (ExecContext *xc, PacketPtr pkt, Addr cacheBlockMask) |
virtual void | handleLockedSnoopHit () |
virtual void | handleLockedSnoopHit (ExecContext *xc) |
virtual void | globalClearExclusive () |
virtual void | globalClearExclusive (ExecContext *xc) |
![]() | |
const Params & | params () const |
SimObject (const Params &p) | |
virtual | ~SimObject () |
virtual void | init () |
init() is called after all C++ SimObjects have been created and all ports are connected. More... | |
virtual void | loadState (CheckpointIn &cp) |
loadState() is called on each SimObject when restoring from a checkpoint. More... | |
virtual void | initState () |
initState() is called on each SimObject when not restoring from a checkpoint. More... | |
virtual void | regProbePoints () |
Register probe points for this object. More... | |
virtual void | regProbeListeners () |
Register probe listeners for this object. More... | |
ProbeManager * | getProbeManager () |
Get the probe manager for this object. More... | |
virtual Port & | getPort (const std::string &if_name, PortID idx=InvalidPortID) |
Get a port with a given name and index. More... | |
virtual void | startup () |
startup() is the final initialization call before simulation. More... | |
DrainState | drain () override |
Provide a default implementation of the drain interface for objects that don't need draining. More... | |
virtual void | memWriteback () |
Write back dirty buffers to memory using functional writes. More... | |
virtual void | memInvalidate () |
Invalidate the contents of memory buffers. More... | |
void | serialize (CheckpointOut &cp) const override |
Serialize an object. More... | |
void | unserialize (CheckpointIn &cp) override |
Unserialize an object. More... | |
![]() | |
EventQueue * | eventQueue () const |
void | schedule (Event &event, Tick when) |
void | deschedule (Event &event) |
void | reschedule (Event &event, Tick when, bool always=false) |
void | schedule (Event *event, Tick when) |
void | deschedule (Event *event) |
void | reschedule (Event *event, Tick when, bool always=false) |
void | wakeupEventQueue (Tick when=(Tick) -1) |
This function is not needed by the usual gem5 event loop but may be necessary in derived EventQueues which host gem5 on other schedulers. More... | |
void | setCurTick (Tick newVal) |
EventManager (EventManager &em) | |
Event manger manages events in the event queue. More... | |
EventManager (EventManager *em) | |
EventManager (EventQueue *eq) | |
![]() | |
Serializable () | |
virtual | ~Serializable () |
void | serializeSection (CheckpointOut &cp, const char *name) const |
Serialize an object into a new section. More... | |
void | serializeSection (CheckpointOut &cp, const std::string &name) const |
void | unserializeSection (CheckpointIn &cp, const char *name) |
Unserialize an a child object. More... | |
void | unserializeSection (CheckpointIn &cp, const std::string &name) |
![]() | |
DrainState | drainState () const |
Return the current drain state of an object. More... | |
virtual void | notifyFork () |
Notify a child process of a fork. More... | |
![]() | |
Group (Group *parent, const char *name=nullptr) | |
Construct a new statistics group. More... | |
virtual | ~Group () |
virtual void | regStats () |
Callback to set stat parameters. More... | |
virtual void | resetStats () |
Callback to reset stats. More... | |
virtual void | preDumpStats () |
Callback before stats are dumped. More... | |
void | addStat (statistics::Info *info) |
Register a stat with this group. More... | |
const std::map< std::string, Group * > & | getStatGroups () const |
Get all child groups associated with this object. More... | |
const std::vector< Info * > & | getStats () const |
Get all stats associated with this object. More... | |
void | addStatGroup (const char *name, Group *block) |
Add a stat block as a child of this block. More... | |
const Info * | resolveStat (std::string name) const |
Resolve a stat by its name within this group. More... | |
void | mergeStatGroup (Group *block) |
Merge the contents (stats & children) of a block to this block. More... | |
Group ()=delete | |
Group (const Group &)=delete | |
Group & | operator= (const Group &)=delete |
![]() | |
Named (const std::string &name_) | |
virtual | ~Named ()=default |
virtual std::string | name () const |
Public Attributes | |
bool | cp0Updated |
Static Public Attributes | |
static std::string | miscRegNames [MISCREG_NUMREGS] |
Protected Types | |
enum | BankType { perProcessor, perThreadContext, perVirtProcessor } |
Protected Attributes | |
uint8_t | numThreads |
uint8_t | numVpes |
std::vector< std::vector< RegVal > > | miscRegFile |
std::vector< std::vector< RegVal > > | miscRegFile_WriteMask |
std::vector< BankType > | bankType |
![]() | |
ThreadContext * | tc = nullptr |
RegClasses | _regClasses |
![]() | |
const SimObjectParams & | _params |
Cached copy of the object parameters. More... | |
![]() | |
EventQueue * | eventq |
A pointer to this object's event queue. More... | |
Additional Inherited Members | |
![]() | |
static void | serializeAll (const std::string &cpt_dir) |
Create a checkpoint by serializing all SimObjects in the system. More... | |
static SimObject * | find (const char *name) |
Find the SimObject with the given name and return a pointer to it. More... | |
static void | setSimObjectResolver (SimObjectResolver *resolver) |
There is a single object name resolver, and it is only set when simulation is restoring from checkpoints. More... | |
static SimObjectResolver * | getSimObjectResolver () |
There is a single object name resolver, and it is only set when simulation is restoring from checkpoints. More... | |
![]() | |
static const std::string & | currentSection () |
Gets the fully-qualified name of the active section. More... | |
static void | generateCheckpointOut (const std::string &cpt_dir, std::ofstream &outstream) |
Generate a checkpoint file so that the serialization can be routed to it. More... | |
![]() | |
SimObject (const Params &p) | |
![]() | |
Drainable () | |
virtual | ~Drainable () |
virtual void | drainResume () |
Resume execution after a successful drain. More... | |
void | signalDrainDone () const |
Signal that an object is drained. More... | |
typedef ISA gem5::MipsISA::ISA::CP0 |
using gem5::MipsISA::ISA::Params = MipsISAParams |
|
protected |
gem5::MipsISA::ISA::ISA | ( | const Params & | p | ) |
Definition at line 97 of file isa.cc.
References gem5::BaseISA::_regClasses, bankType, clear(), gem5::MipsISA::i, gem5::MipsISA::MISCREG_DEBUG, gem5::MipsISA::MISCREG_EBASE, gem5::MipsISA::MISCREG_LLADDR, gem5::MipsISA::MISCREG_NUMREGS, gem5::MipsISA::MISCREG_SRS_CONF0, gem5::MipsISA::MISCREG_SRS_CONF1, gem5::MipsISA::MISCREG_SRS_CONF2, gem5::MipsISA::MISCREG_SRS_CONF3, gem5::MipsISA::MISCREG_SRS_CONF4, gem5::MipsISA::MISCREG_STATUS, gem5::MipsISA::MISCREG_TC_BIND, gem5::MipsISA::MISCREG_TC_CONTEXT, gem5::MipsISA::MISCREG_TC_HALT, gem5::MipsISA::MISCREG_TC_RESTART, gem5::MipsISA::MISCREG_TC_SCHEDULE, gem5::MipsISA::MISCREG_TC_SCHEFBACK, gem5::MipsISA::MISCREG_TC_STATUS, gem5::MipsISA::MISCREG_VPE_CONF0, gem5::MipsISA::MISCREG_VPE_CONF1, gem5::MipsISA::MISCREG_VPE_CONTROL, gem5::MipsISA::MISCREG_VPE_OPT, gem5::MipsISA::MISCREG_VPE_SCHEDULE, gem5::MipsISA::MISCREG_VPE_SCHEFBACK, gem5::MipsISA::MISCREG_YQMASK, miscRegFile, miscRegFile_WriteMask, gem5::MipsISA::NumFloatRegs, gem5::MipsISA::NumIntRegs, numThreads, numVpes, perProcessor, perThreadContext, and perVirtProcessor.
void gem5::MipsISA::ISA::clear | ( | ) |
Definition at line 159 of file isa.cc.
References gem5::MipsISA::i, gem5::ArmISA::j, gem5::MipsISA::k, gem5::MipsISA::MISCREG_NUMREGS, miscRegFile, and miscRegFile_WriteMask.
Referenced by ISA().
void gem5::MipsISA::ISA::configCP | ( | ) |
Definition at line 191 of file isa.cc.
References gem5::MipsISA::CoreSpecific::CP0_Config1_C2, gem5::MipsISA::CoreSpecific::CP0_Config1_DA, gem5::MipsISA::CoreSpecific::CP0_Config1_DL, gem5::MipsISA::CoreSpecific::CP0_Config1_DS, gem5::MipsISA::CoreSpecific::CP0_Config1_EP, gem5::MipsISA::CoreSpecific::CP0_Config1_FP, gem5::MipsISA::CoreSpecific::CP0_Config1_IA, gem5::MipsISA::CoreSpecific::CP0_Config1_IL, gem5::MipsISA::CoreSpecific::CP0_Config1_IS, gem5::MipsISA::CoreSpecific::CP0_Config1_M, gem5::MipsISA::CoreSpecific::CP0_Config1_MD, gem5::MipsISA::CoreSpecific::CP0_Config1_MMU, gem5::MipsISA::CoreSpecific::CP0_Config1_PC, gem5::MipsISA::CoreSpecific::CP0_Config1_WR, gem5::MipsISA::CoreSpecific::CP0_Config2_M, gem5::MipsISA::CoreSpecific::CP0_Config2_SA, gem5::MipsISA::CoreSpecific::CP0_Config2_SL, gem5::MipsISA::CoreSpecific::CP0_Config2_SS, gem5::MipsISA::CoreSpecific::CP0_Config2_SU, gem5::MipsISA::CoreSpecific::CP0_Config2_TA, gem5::MipsISA::CoreSpecific::CP0_Config2_TL, gem5::MipsISA::CoreSpecific::CP0_Config2_TS, gem5::MipsISA::CoreSpecific::CP0_Config2_TU, gem5::MipsISA::CoreSpecific::CP0_Config3_DSPP, gem5::MipsISA::CoreSpecific::CP0_Config3_LPA, gem5::MipsISA::CoreSpecific::CP0_Config3_MT, gem5::MipsISA::CoreSpecific::CP0_Config3_SM, gem5::MipsISA::CoreSpecific::CP0_Config3_SP, gem5::MipsISA::CoreSpecific::CP0_Config3_TL, gem5::MipsISA::CoreSpecific::CP0_Config3_VEIC, gem5::MipsISA::CoreSpecific::CP0_Config3_VInt, gem5::MipsISA::CoreSpecific::CP0_Config_AR, gem5::MipsISA::CoreSpecific::CP0_Config_AT, gem5::MipsISA::CoreSpecific::CP0_Config_BE, gem5::MipsISA::CoreSpecific::CP0_Config_MT, gem5::MipsISA::CoreSpecific::CP0_Config_VI, gem5::MipsISA::CoreSpecific::CP0_EBase_CPUNum, gem5::MipsISA::CoreSpecific::CP0_IntCtl_IPPCI, gem5::MipsISA::CoreSpecific::CP0_IntCtl_IPTI, gem5::MipsISA::CoreSpecific::CP0_PerfCtr_M, gem5::MipsISA::CoreSpecific::CP0_PerfCtr_W, gem5::MipsISA::CoreSpecific::CP0_PRId_CompanyID, gem5::MipsISA::CoreSpecific::CP0_PRId_CompanyOptions, gem5::MipsISA::CoreSpecific::CP0_PRId_ProcessorID, gem5::MipsISA::CoreSpecific::CP0_PRId_Revision, gem5::MipsISA::CoreSpecific::CP0_SrsCtl_HSS, gem5::MipsISA::CoreSpecific::CP0_WatchHi_M, DPRINTF, gem5::MipsISA::mask, gem5::MipsISA::MISCREG_BADVADDR, gem5::MipsISA::MISCREG_CAUSE, gem5::MipsISA::MISCREG_CONFIG, gem5::MipsISA::MISCREG_CONFIG1, gem5::MipsISA::MISCREG_CONFIG2, gem5::MipsISA::MISCREG_CONFIG3, gem5::MipsISA::MISCREG_CONTEXT, gem5::MipsISA::MISCREG_CP0_RANDOM, gem5::MipsISA::MISCREG_EBASE, gem5::MipsISA::MISCREG_ENTRYLO0, gem5::MipsISA::MISCREG_ENTRYLO1, gem5::MipsISA::MISCREG_INDEX, gem5::MipsISA::MISCREG_INTCTL, gem5::MipsISA::MISCREG_LLADDR, gem5::MipsISA::MISCREG_MVP_CONF0, gem5::MipsISA::MISCREG_PAGEGRAIN, gem5::MipsISA::MISCREG_PAGEMASK, gem5::MipsISA::MISCREG_PERFCNT0, gem5::MipsISA::MISCREG_PRID, gem5::MipsISA::MISCREG_SRSCTL, gem5::MipsISA::MISCREG_STATUS, gem5::MipsISA::MISCREG_TC_BIND, gem5::MipsISA::MISCREG_TC_HALT, gem5::MipsISA::MISCREG_TC_STATUS, gem5::MipsISA::MISCREG_VPE_CONF0, gem5::MipsISA::MISCREG_WATCHHI0, numThreads, numVpes, panic, gem5::MipsISA::procId, readMiscRegNoEffect(), gem5::replaceBits(), setMiscRegNoEffect(), setRegMask(), and gem5::ArmISA::status.
|
overridevirtual |
Implements gem5::BaseISA.
Definition at line 171 of file isa.cc.
References gem5::MipsISA::i, gem5::MipsISA::MISCREG_NUMREGS, gem5::MipsISA::NumFloatRegs, gem5::MipsISA::NumIntRegs, gem5::ThreadContext::pcState(), gem5::ThreadContext::readFloatRegFlat(), gem5::ThreadContext::readIntRegFlat(), gem5::ThreadContext::readMiscRegNoEffect(), gem5::ThreadContext::setFloatRegFlat(), gem5::ThreadContext::setIntRegFlat(), gem5::ThreadContext::setMiscRegNoEffect(), and gem5::BaseISA::tc.
This method doesn't need to adjust the Control Register Offset since it has already been done in the calling method (setRegWithEffect)
Definition at line 525 of file isa.cc.
References DPRINTF, miscRegFile, miscRegFile_WriteMask, and gem5::X86ISA::val.
Referenced by setMiscReg().
|
inline |
Definition at line 153 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 148 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 147 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 154 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 150 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 149 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 151 of file isa.hh.
References gem5::X86ISA::reg.
|
inline |
Definition at line 440 of file isa.cc.
References gem5::MipsISA::MISCREG_TC_BIND, and miscRegFile.
Referenced by readMiscReg(), readMiscRegNoEffect(), setMiscReg(), setMiscRegNoEffect(), and setRegMask().
|
inlineoverridevirtual |
Implements gem5::BaseISA.
Definition at line 157 of file isa.hh.
References gem5::MipsISA::MISCREG_DEBUG, gem5::MipsISA::MISCREG_STATUS, and readMiscRegNoEffect().
|
inlineoverridevirtual |
Implements gem5::BaseISA.
void gem5::MipsISA::ISA::processCP0Event | ( | BaseCPU * | cpu, |
CP0EventType | cp0EventType | ||
) |
Process a CP0 event.
Definition at line 588 of file isa.cc.
References UpdateCP0, and updateCPU().
Referenced by scheduleCP0Update().
Definition at line 461 of file isa.cc.
References bankType, DPRINTF, getVPENum(), miscRegFile, miscRegNames, and perThreadContext.
Definition at line 447 of file isa.cc.
References bankType, DPRINTF, getVPENum(), miscRegFile, miscRegNames, and perThreadContext.
Referenced by configCP(), inUserMode(), and updateCPU().
Definition at line 545 of file isa.cc.
References cp0Updated, gem5::EventBase::CPU_Tick_Pri, processCP0Event(), and UpdateCP0.
Referenced by setMiscReg().
Definition at line 502 of file isa.cc.
References bankType, DPRINTF, filterCP0Write(), gem5::ThreadContext::getCpuPtr(), getVPENum(), miscRegFile, miscRegNames, perThreadContext, scheduleCP0Update(), gem5::BaseISA::tc, and gem5::X86ISA::val.
Definition at line 474 of file isa.cc.
References bankType, DPRINTF, getVPENum(), miscRegFile, miscRegNames, perThreadContext, and gem5::X86ISA::val.
Referenced by configCP().
Definition at line 487 of file isa.cc.
References bankType, DPRINTF, getVPENum(), miscRegFile_WriteMask, miscRegNames, perThreadContext, and gem5::X86ISA::val.
Referenced by configCP().
|
inline |
void gem5::MipsISA::ISA::updateCPU | ( | BaseCPU * | cpu | ) |
Definition at line 559 of file isa.cc.
References cp0Updated, gem5::MipsISA::haltThread(), gem5::MipsISA::MISCREG_MVP_CONF0, gem5::MipsISA::MISCREG_TC_HALT, gem5::MipsISA::MISCREG_TC_STATUS, readMiscRegNoEffect(), and gem5::MipsISA::restoreThread().
Referenced by processCP0Event().
|
protected |
Definition at line 77 of file isa.hh.
Referenced by ISA(), readMiscReg(), readMiscRegNoEffect(), setMiscReg(), setMiscRegNoEffect(), and setRegMask().
bool gem5::MipsISA::ISA::cp0Updated |
Definition at line 122 of file isa.hh.
Referenced by scheduleCP0Update(), and updateCPU().
|
protected |
Definition at line 75 of file isa.hh.
Referenced by clear(), filterCP0Write(), getVPENum(), ISA(), readMiscReg(), readMiscRegNoEffect(), setMiscReg(), and setMiscRegNoEffect().
|
protected |
Definition at line 76 of file isa.hh.
Referenced by clear(), filterCP0Write(), ISA(), and setRegMask().
|
static |
Definition at line 140 of file isa.hh.
Referenced by readMiscReg(), readMiscRegNoEffect(), setMiscReg(), setMiscRegNoEffect(), and setRegMask().
|
protected |
Definition at line 65 of file isa.hh.
Referenced by configCP(), and ISA().
|
protected |
Definition at line 66 of file isa.hh.
Referenced by configCP(), and ISA().