70 std::stringstream msg;
71 msg <<
"Virtual memory: 0x" << std::hex << addr <<
" is translated into physical address 0x:" << std::hex << pma
89 std::stringstream msg;
90 msg <<
"Virtual memory: 0x" << std::hex << addr <<
" is translated into physical address 0x:" << std::hex << pma
108 std::stringstream msg;
125 std::stringstream msg;
141 return etiss::RETURNCODE::PAGEFAULT;
158 std::stringstream msg;
159 msg <<
"Virtual memory: 0x" << std::hex << addr <<
" is translated into physical address 0x:" << std::hex << pma
181 mmu_->Init(cpu, system);
212 return mmu_->GetName() + std::string(
" Wrapper");
Wrapper class to wrap aroud data MMU.
static __inline__ uint64_t
static __inline__ int32_t
std::shared_ptr< MMU > mmu_
DMMUWrapper(std::shared_ptr< MMU > mmu)
std::string _getPluginName() const
ETISS_System * unwrap(ETISS_CPU *cpu, ETISS_System *system)
SystemWrapperPlugin interface to unwrap original ETISS_System.
ETISS_System * wrap(ETISS_CPU *cpu, ETISS_System *system)
SystemWrapperPlugin interface to wrap around original ETISS_System.
static etiss_int32 dbg_write(void *handle, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
static etiss_int32 dbg_read(void *handle, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
static etiss_int32 iwrite(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
static etiss_int32 iread(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint32 length)
static void syncTime(void *handle, ETISS_CPU *cpu)
static etiss_int32 dwrite(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
static etiss_int32 dread(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
Page Table Entry (PTE) defines the composition of Page Frame Number (PFN) and relavant flags.
void log(Verbosity level, std::string msg)
write log message at the given level.
float __ovld __cnfn length(float p)
Return the length of vector p, i.e., sqrt(p.x2 + p.y 2 + ...)
basic cpu state structure needed for execution of any cpu architecture.
memory access and time synchronization functions.
etiss_int32(* dwrite)(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
write data
etiss_int32(* iread)(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint32 length)
used to simulate an instruction fetch.
void * handle
custom handle that will be passed to the functions of this structure
etiss_int32(* dbg_write)(void *handle, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
direct debug write
etiss_int32(* dbg_read)(void *handle, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
direct debug read
etiss_int32(* dread)(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
read data
void(* syncTime)(void *handle, ETISS_CPU *cpu)
called after a block to synchronize the time
etiss_int32(* iwrite)(void *handle, ETISS_CPU *cpu, etiss_uint64 addr, etiss_uint8 *buffer, etiss_uint32 length)
write instruction data over instruction bus