ETISS 0.8.0
Extendable Translating Instruction Set Simulator (version 0.8.0)
|
System Interface for the basic system IO operations and time synchronization. More...
#include <System.h>
Public Member Functions | |
virtual | ~System () |
virtual etiss::int32 | iread (ETISS_CPU *cpu, etiss::uint64 addr, etiss::uint32 len)=0 |
Instruction read operation. More... | |
virtual etiss::int32 | iwrite (ETISS_CPU *cpu, etiss::uint64 addr, etiss::uint8 *buf, etiss::uint32 len)=0 |
Instruction write operation. More... | |
virtual etiss::int32 | dread (ETISS_CPU *cpu, etiss::uint64 addr, etiss::uint8 *buf, etiss::uint32 len)=0 |
Data read operation. More... | |
virtual etiss::int32 | dwrite (ETISS_CPU *cpu, etiss::uint64 addr, etiss::uint8 *buf, etiss::uint32 len)=0 |
Data write operation. More... | |
virtual etiss::int32 | dbg_read (etiss::uint64 addr, etiss::uint8 *buf, etiss::uint32 len)=0 |
Debug read operation. More... | |
virtual etiss::int32 | dbg_write (etiss::uint64 addr, etiss::uint8 *buf, etiss::uint32 len)=0 |
Debug write operation. More... | |
virtual void | syncTime (ETISS_CPU *cpu)=0 |
Synchronize simulation time. More... | |
System Interface for the basic system IO operations and time synchronization.
Systems that are model around a CPU model, for the memory and peripherals need to implement this interface in order to be simulated with ETISS. These method are called by ETISS if required.
|
pure virtual |
Debug read operation.
This method should implement a debug read operation. The debug operations are used for data access that should not influence the simulation time. To indicate an error a non 0 value should be returned.
addr | The address from which the data should be read. |
buf | Pointer to the buffer, that contains the instruction. |
len | The length of the data in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Debug write operation.
This method should implement a debug write operation. The debug operations are used for data access that should not influence the simulation time. To indicate an error a non 0 value should be returned.
addr | The address to which the data should be written. |
buf | Pointer to the buffer, that contains the instruction. |
len | The length of the data in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Data read operation.
This method should implement a data read operation. To indicate an error a non 0 value should be returned. The CPU time needs to be increased according to the delay of this instruction operation.
cpu | Pointer to the CPU structure, that requested this operation. |
addr | The address from which the data should be read. |
buf | Pointer to the buffer, that contains the instruction. |
len | The length of the data in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Data write operation.
This method should implement a data write operation. To indicate an error a non 0 value should be returned. The CPU time needs to be increased according to the delay of this instruction operation.
cpu | Pointer to the CPU structure, that requested this operation. |
addr | The address to which the data should be written. |
buf | Pointer to the buffer, that contains the instruction. |
len | The length of the data in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Instruction read operation.
This method should implement an instruction read operation. To indicate an error a non 0 value should be returned. The CPU time needs to be increased according to the delay of this instruction operation.
cpu | Pointer to the CPU structure, that requested this operation. |
addr | The address from which the instruction should be read. |
len | The length of the instruction in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Instruction write operation.
This method should implement an instruction write operation. To indicate an error a non 0 value should be returned. The CPU time needs to be increased according to the delay of this instruction operation.
cpu | Pointer to the CPU structure, that requested this operation. |
addr | The address to which the instruction should be written. |
buf | Pointer to the buffer, that contains the instruction. |
len | The length of the instruction in bytes. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.
|
pure virtual |
Synchronize simulation time.
This method should implement the synchronization between the simulation time of the system and the CPU. This function call should allow the system to catch up with the CPU.
cpu | Pointer to the CPU structure, for which the synchronization should be performed. |
Implemented in etiss::SimpleSystem, and etiss::SimpleMemSystem.