RISCV_CPUComponent.h Source File
Back to the index.
Go to the documentation of this file. 1 #ifndef RISCV_CPUCOMPONENT_H
2 #define RISCV_CPUCOMPONENT_H
40 #define N_RISCV_XREGS 32
52 "a2",
"a3",
"a4",
"a5",
54 "s2",
"s3",
"s4",
"s5",
55 "s6",
"s7",
"s8",
"s9",
57 "t3",
"t4",
"t5",
"t6",
62 #define RISCV_MAX_PARCELS 12
65 #define RISCV_EXTENSION_C (1 << 1)
66 #define RISCV_EXTENSION_I (1 << 2)
110 ss.flags(std::ios::hex | std::ios::right);
111 ss << std::setfill(
'0') << std::setw(16) << (uint64_t)vaddr;
131 void Translate(uint16_t iwords[],
int nparcels,
struct DyntransIC*
ic);
132 DECLARE_DYNTRANS_INSTR(ToBeTranslated);
140 uint64_t m_extensions;
146 #endif // RISCV_CPUCOMPONENT_H
virtual string VirtualAddressAsString(uint64_t vaddr)
Format a virtual address as a displayable string.
RISCV_CPUComponent()
Constructs a RISCV_CPUComponent.
virtual void(*)(CPUDyntransComponent *, DyntransIC *) GetDyntransToBeTranslated()
virtual bool FunctionTraceReturnImpl(int64_t &retval)
StateVariables make up the persistent state of Component objects.
virtual bool PreRunCheckForComponent(GXemul *gxemul)
Checks the state of this component, before starting execution.
virtual int FunctionTraceArgumentCount()
A base-class for processors Component implementations that use dynamic translation.
virtual int GetDyntransICshift() const
virtual int64_t FunctionTraceArgument(int n)
struct arm_instr_call * ic
static void RunUnitTests(int &nSucceeded, int &nFailures)
A Component representing a RISC-V processor.
virtual void ShowRegisters(GXemul *gxemul, const vector< string > &arguments) const
static string GetAttribute(const string &attributeName)
virtual uint64_t PCtoInstructionAddress(uint64_t pc)
Convert PC value to instuction address.
virtual void ResetState()
Resets the state variables of this component.
virtual bool CheckVariableWrite(StateVariable &var, const string &oldValue)
Checks whether a write to a variable is OK.
virtual size_t DisassembleInstruction(uint64_t vaddr, vector< string > &result)
Disassembles an instruction into readable strings.
virtual bool VirtualToPhysical(uint64_t vaddr, uint64_t &paddr, bool &writable)
Virtual to physical address translation (MMU).
static refcount_ptr< Component > Create(const ComponentCreateArgs &args)
Creates a RISCV_CPUComponent.
Generated on Tue Aug 25 2020 19:25:06 for GXemul by
1.8.18