OpenASIP  2.0
Public Types | Public Member Functions | List of all members
TCEDBGController Class Reference

#include <TCEDBGController.hh>

Inheritance diagram for TCEDBGController:
Inheritance graph
Collaboration diagram for TCEDBGController:
Collaboration graph

Public Types

typedef MinimumAddressableUnit MAU
 
- Public Types inherited from RemoteController
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

 TCEDBGController (SimulatorFrontend &frontend, const TTAMachine::Machine &machine, const TTAProgram::Program &program)
 
virtual void writeMem (Word address, MAU data, const AddressSpace &)
 
virtual MAU readMem (Word address, const AddressSpace &)
 
virtual void writeIMem (const char *data, int size)
 
virtual void step (double count=1)
 
virtual void next (int count=1)
 
virtual void run ()
 
virtual void runUntil (UIntWord address)
 
virtual void reset ()
 
virtual std::string registerFileValue (const std::string &rfName, int registerIndex=-1)
 
virtual SimValue immediateUnitRegisterValue (const std::string &iuName, int index=-1)
 
virtual SimValue FUPortValue (const std::string &fuName, const std::string &portName)
 
virtual InstructionAddress programCounter () const
 
- Public Member Functions inherited from RemoteController
 RemoteController (SimulatorFrontend &frontend, const TTAMachine::Machine &machine, const TTAProgram::Program &program)
 
virtual void loadIMemImage ()
 
- 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 MemorySystemmemorySystem (int coreId=-1)
 
virtual SimulatorFrontendfrontend ()
 
virtual bool automaticFinishImpossible () const
 
virtual std::set< InstructionAddressfindProgramExitPoints (const TTAProgram::Program &program, const TTAMachine::Machine &machine) const
 

Additional Inherited Members

- Protected Types inherited from TTASimulationController
typedef std::set< StopReasonStopReasonContainer
 The container type for reasons why simulation stop was requested. More...
 
- Protected Member Functions inherited from TTASimulationController
 TTASimulationController (const TTASimulationController &)
 Copying not allowed. More...
 
TTASimulationControlleroperator= (const TTASimulationController &)
 Assignment not allowed. More...
 
- Protected Attributes inherited from RemoteController
std::set< InstructionAddressexitPoints
 
std::ostringstream imemImage
 
- Protected Attributes inherited from TTASimulationController
SimulatorFrontendfrontend_
 Reference to the simulator frontend. More...
 
const TTAMachine::MachinesourceMachine_
 The simulated Machine Object Model. More...
 
const TTAProgram::Programprogram_
 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< InstructionAddresslastExecutedInstruction_
 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...
 

Detailed Description

Definition at line 37 of file TCEDBGController.hh.

Member Typedef Documentation

◆ MAU

Definition at line 39 of file TCEDBGController.hh.

Constructor & Destructor Documentation

◆ TCEDBGController()

TCEDBGController::TCEDBGController ( SimulatorFrontend frontend,
const TTAMachine::Machine machine,
const TTAProgram::Program program 
)

Definition at line 37 of file TCEDBGController.cc.

40  :
42 }

Member Function Documentation

◆ FUPortValue()

SimValue TCEDBGController::FUPortValue ( const std::string &  fuName,
const std::string &  portName 
)
virtual

Implements RemoteController.

Definition at line 96 of file TCEDBGController.cc.

98  {
99  SimValue rv;
100  return rv;
101 }

◆ immediateUnitRegisterValue()

SimValue TCEDBGController::immediateUnitRegisterValue ( const std::string &  iuName,
int  index = -1 
)
virtual

Implements RemoteController.

Definition at line 89 of file TCEDBGController.cc.

90  {
91  SimValue rv;
92  return rv;
93 }

◆ next()

void TCEDBGController::next ( int  count = 1)
virtual

Implements RemoteController.

Definition at line 68 of file TCEDBGController.cc.

68 {}

◆ programCounter()

InstructionAddress TCEDBGController::programCounter ( ) const
virtual

Implements RemoteController.

Definition at line 104 of file TCEDBGController.cc.

104  {
105  return 0;
106 }

◆ readMem()

MAU TCEDBGController::readMem ( Word  address,
const AddressSpace  
)
virtual

Read data from physical memory.

Parameters
addressTTA's view of the memory address from which to read @space the address space from which to read the data.
Returns
one MAU of data to write. (TODO: is return value masked or not?)

Implements RemoteController.

Definition at line 52 of file TCEDBGController.cc.

54  {
55  return 0;
56 }

◆ registerFileValue()

std::string TCEDBGController::registerFileValue ( const std::string &  rfName,
int  registerIndex = -1 
)
virtual

Implements RemoteController.

Definition at line 81 of file TCEDBGController.cc.

83  {
84  std::string rv="hello";
85  return rv;
86 }

◆ reset()

void TCEDBGController::reset ( )
virtual

Implements RemoteController.

Definition at line 77 of file TCEDBGController.cc.

77  {
78 }

◆ run()

void TCEDBGController::run ( )
virtual

Implements RemoteController.

Definition at line 71 of file TCEDBGController.cc.

71 {}

◆ runUntil()

void TCEDBGController::runUntil ( UIntWord  address)
virtual

Implements RemoteController.

Definition at line 74 of file TCEDBGController.cc.

74 {}

◆ step()

void TCEDBGController::step ( double  count = 1)
virtual

Implements RemoteController.

Definition at line 65 of file TCEDBGController.cc.

65 {}

◆ writeIMem()

void TCEDBGController::writeIMem ( const char *  data,
int  size 
)
virtual

Write to phyical instruction memory.

Parameters
addressTTA'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

Implements RemoteController.

Definition at line 59 of file TCEDBGController.cc.

61  {
62 }

◆ writeMem()

void TCEDBGController::writeMem ( Word  address,
MAU  data,
const AddressSpace  
)
virtual

Write data to physical memory.

Parameters
addressTTA'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.

Implements RemoteController.

Definition at line 45 of file TCEDBGController.cc.

48  {
49 }

The documentation for this class was generated from the following files:
machine
TTAMachine::Machine * machine
the architecture definition of the estimated processor
Definition: EstimatorCmdLineUI.cc:59
SimValue
Definition: SimValue.hh:96
TTASimulationController::frontend
virtual SimulatorFrontend & frontend()
Definition: TTASimulationController.cc:181
program
find Finds info of the inner loops in the program
Definition: InnerLoopFinder.cc:80
RemoteController::RemoteController
RemoteController(SimulatorFrontend &frontend, const TTAMachine::Machine &machine, const TTAProgram::Program &program)
Definition: RemoteController.cc:48