OpenASIP
2.0
|
#include <RemoteController.hh>
Public Types | |
typedef MinimumAddressableUnit | MAU |
Public Types inherited from TTASimulationController | |
enum | SimulationStatus { STA_INITIALIZING, STA_INITIALIZED, STA_RUNNING, STA_STOPPED, STA_FINISHED } |
The states of simulation. More... | |
Public Member Functions | |
RemoteController (SimulatorFrontend &frontend, const TTAMachine::Machine &machine, const TTAProgram::Program &program) | |
virtual void | writeMem (Word address, MAU data, const AddressSpace &)=0 |
virtual MAU | readMem (Word address, const AddressSpace &)=0 |
virtual void | loadIMemImage () |
virtual void | writeIMem (const char *data, int size)=0 |
virtual void | step (double count=1)=0 |
virtual void | next (int count=1)=0 |
virtual void | run ()=0 |
virtual void | runUntil (UIntWord address)=0 |
virtual void | reset ()=0 |
virtual std::string | registerFileValue (const std::string &rfName, int registerIndex=-1)=0 |
virtual SimValue | immediateUnitRegisterValue (const std::string &iuName, int index=-1)=0 |
virtual SimValue | FUPortValue (const std::string &fuName, const std::string &portName)=0 |
virtual InstructionAddress | programCounter () const =0 |
Public Member Functions inherited from TTASimulationController | |
TTASimulationController (SimulatorFrontend &frontend, const TTAMachine::Machine &machine, const TTAProgram::Program &program) | |
virtual | ~TTASimulationController () |
virtual void | prepareToStop (StopReason reason) |
virtual unsigned int | stopReasonCount () const |
virtual StopReason | stopReason (unsigned int index) const |
virtual SimulationStatus | state () const |
virtual InstructionAddress | lastExecutedInstruction (int coreId=-1) const |
virtual ClockCycleCount | clockCount () const |
virtual MemorySystem & | memorySystem (int coreId=-1) |
virtual SimulatorFrontend & | frontend () |
virtual bool | automaticFinishImpossible () const |
virtual std::set< InstructionAddress > | findProgramExitPoints (const TTAProgram::Program &program, const TTAMachine::Machine &machine) const |
Protected Attributes | |
std::set< InstructionAddress > | exitPoints |
std::ostringstream | imemImage |
Protected Attributes inherited from TTASimulationController | |
SimulatorFrontend & | frontend_ |
Reference to the simulator frontend. More... | |
const TTAMachine::Machine & | sourceMachine_ |
The simulated Machine Object Model. More... | |
const TTAProgram::Program & | program_ |
Program object model of the simulated program. More... | |
bool | stopRequested_ |
Flag indicating that simulation should stop. More... | |
StopReasonContainer | stopReasons_ |
The set of reasons the simulation was stopped. More... | |
SimulationStatus | state_ |
The current state of the simulation. More... | |
ClockCycleCount | clockCount_ |
How many clock cycles have been simulated. More... | |
std::vector< InstructionAddress > | lastExecutedInstruction_ |
The address of the last executed instruction. More... | |
InstructionAddress | initialPC_ |
The address of the first executed instruction. More... | |
bool | automaticFinishImpossible_ |
If this is true, simulation cannot be finished automatically. More... | |
InstructionAddress | firstIllegalInstructionIndex_ |
The index of the first illegal instruction in the instruction sequence. More... | |
Additional Inherited Members | |
Protected Types inherited from TTASimulationController | |
typedef std::set< StopReason > | StopReasonContainer |
The container type for reasons why simulation stop was requested. More... | |
Protected Member Functions inherited from TTASimulationController | |
TTASimulationController (const TTASimulationController &) | |
Copying not allowed. More... | |
TTASimulationController & | operator= (const TTASimulationController &) |
Assignment not allowed. More... | |
RemoteController is a "simulation" controller base class for debuggers on hardware implementations.
RemoteController is a base class for the TCE built-in debugger and the custom debugger classes. It adds virtual interfaces to TTASimulationController, that are needed to integrate an FPGA or ASIC to the TCE debugging tools. RemoteController is a interface class, and cannot be instantiated.
Definition at line 48 of file RemoteController.hh.
Definition at line 50 of file RemoteController.hh.
RemoteController::RemoteController | ( | SimulatorFrontend & | frontend, |
const TTAMachine::Machine & | machine, | ||
const TTAProgram::Program & | program | ||
) |
Definition at line 48 of file RemoteController.cc.
References exitPoints, TTASimulationController::findProgramExitPoints(), machine, and program.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
virtual |
Create and load instruction memory image from current program.
This function generates a binary image of the instruction memory, and stores it in cache. It is then written with loadInstructions(), which in turn call the pure virtual writeIMem, that subclasses need to implement.
Definition at line 58 of file RemoteController.cc.
References ProgramImageGenerator::BINARY, TTAProgram::ProgramWriter::createBinary(), BEMGenerator::generate(), ProgramImageGenerator::generateProgramImage(), imemImage, ProgramImageGenerator::loadBEM(), ProgramImageGenerator::loadMachine(), ProgramImageGenerator::loadPrograms(), TTASimulationController::program_, TTASimulationController::sourceMachine_, and writeIMem().
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Read data from physical memory.
address | TTA's view of the memory address from which to read @space the address space from which to read the data. |
Implemented in TCEDBGController, and CustomDBGController.
Referenced by RemoteMemory::read().
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Implements TTASimulationController.
Implemented in TCEDBGController, and CustomDBGController.
|
pure virtual |
Write to phyical instruction memory.
address | TTA's view of the memory address to which to write @data buffer of raw data to write to instruction memory @size the size of the data buffer, in bytes |
Implemented in TCEDBGController, and CustomDBGController.
Referenced by loadIMemImage().
|
pure virtual |
Write data to physical memory.
address | TTA's view of the memory address to which to write @data one MAU of data to write. Needs to be masked, if MAU is less than maximum MAU size. @space the address space in which to write the data. |
Implemented in TCEDBGController, and CustomDBGController.
Referenced by RemoteMemory::write().
|
protected |
Definition at line 120 of file RemoteController.hh.
Referenced by RemoteController().
|
protected |
Definition at line 121 of file RemoteController.hh.
Referenced by loadIMemImage().