OpenASIP  2.0
Public Member Functions | Static Public Attributes | Private Types | Private Attributes | List of all members
TTAMachine::AddressSpace Class Reference

#include <AddressSpace.hh>

Inheritance diagram for TTAMachine::AddressSpace:
Inheritance graph
Collaboration diagram for TTAMachine::AddressSpace:
Collaboration graph

Public Member Functions

 AddressSpace (const std::string &name, int width, ULongWord minAddress, ULongWord maxAddress, Machine &owner)
 
 AddressSpace (const ObjectState *state, Machine &owner)
 
virtual ~AddressSpace ()
 
virtual int width () const
 
virtual ULongWord start () const
 
virtual ULongWord end () const
 
virtual void setName (const std::string &name)
 
virtual void setWidth (int width)
 
virtual void setAddressBounds (ULongWord start, ULongWord end)
 
virtual void addNumericalId (unsigned id)
 
virtual bool hasNumericalId (unsigned id) const
 
std::set< unsigned > numericalIds () const
 
bool setNumericalIds (const std::set< unsigned > &ids)
 
virtual void setShared (bool shared)
 
virtual bool isShared () const
 
virtual void setMachine (Machine &mach)
 
virtual void unsetMachine ()
 
virtual ObjectStatesaveState () const
 
virtual void loadState (const ObjectState *state)
 
bool operator== (const AddressSpace &other) const
 
bool operator!= (const AddressSpace &other) const
 
- Public Member Functions inherited from TTAMachine::Component
virtual ~Component ()
 
virtual TCEString name () const
 
virtual Machinemachine () const
 
virtual void ensureRegistration (const Component &component) const
 
virtual bool isRegistered () const
 
- Public Member Functions inherited from Serializable
virtual ~Serializable ()
 

Static Public Attributes

static const std::string OSNAME_ADDRESS_SPACE = "adress_space"
 ObjectState name for AddressSpace. More...
 
static const std::string OSKEY_WIDTH = "width"
 ObjectState attribute key for the bit width. More...
 
static const std::string OSKEY_MIN_ADDRESS = "min_a"
 ObjectState attribute key for minimum address. More...
 
static const std::string OSKEY_MAX_ADDRESS = "max_a"
 ObjectState attribute key for maximum address. More...
 
static const std::string OSKEY_SHARED_MEMORY = "shared-memory"
 
static const std::string OSKEY_NUMERICAL_ID = "numerical-id"
 
- Static Public Attributes inherited from TTAMachine::Component
static const std::string OSNAME_COMPONENT = "component"
 ObjectState name for component. More...
 
static const std::string OSKEY_NAME = "name"
 ObjectState attribute key for the name of the component. More...
 

Private Types

typedef std::set< unsigned > IDSet
 

Private Attributes

int width_
 Bit width of the minimum addressable word. More...
 
ULongWord minAddress_
 Lowest address in the address space. More...
 
ULongWord maxAddress_
 Highest address in the address space. More...
 
IDSet numericalIds_
 The numerical ids mapped to this address space. More...
 
bool shared_
 True in case this address space maps to a memory that is shared across all the cores in the multicore. More...
 

Additional Inherited Members

- Protected Member Functions inherited from TTAMachine::Component
 Component (const std::string &name)
 
 Component (const ObjectState *state)
 
void internalSetMachine (Machine &machine)
 
void internalUnsetMachine ()
 
- Protected Member Functions inherited from TTAMachine::MachinePart
 MachinePart ()
 
virtual ~MachinePart ()
 

Detailed Description

Represents an address space in the machine.

Definition at line 51 of file AddressSpace.hh.

Member Typedef Documentation

◆ IDSet

typedef std::set<unsigned> TTAMachine::AddressSpace::IDSet
private

Definition at line 95 of file AddressSpace.hh.

Constructor & Destructor Documentation

◆ AddressSpace() [1/2]

TTAMachine::AddressSpace::AddressSpace ( const std::string &  name,
int  width,
ULongWord  minAddress,
ULongWord  maxAddress,
Machine owner 
)

Constructor.

Parameters
nameName of the address space.
widthBit width of the minimum addressable word.
minAddressLowest address in the address space.
maxAddressHighest address in the address space.
ownerThe machine which owns the address space.
Exceptions
ComponentAlreadyExistsIf another address space by the same name is already registered to the machine.
OutOfRangeIf the some of the given parameters is out of range.
InvalidNameIf the given name is not valid for a component.

Definition at line 74 of file AddressSpace.cc.

77  : Component(name) {
78  if (width <= 0 || minAddress >= maxAddress) {
79  string procName = "AddressSpace::AddressSpace";
80  throw OutOfRange(__FILE__, __LINE__, procName);
81  }
82 
83  width_ = width;
84  minAddress_ = minAddress;
85  maxAddress_ = maxAddress;
86 
87  setMachine(owner);
88 }

References maxAddress_, minAddress_, setMachine(), width(), and width_.

Here is the call graph for this function:

◆ AddressSpace() [2/2]

TTAMachine::AddressSpace::AddressSpace ( const ObjectState state,
Machine owner 
)

Constructor.

Loads its state from the given ObjectState instance.

Parameters
stateThe ObjectState from which the name is taken.
ownerThe machine which owns the address space.
Exceptions
ObjectStateLoadingExceptionIf the machine already has an address space by the same name as the coming name of this or if the ObjectState instance is invalid.

Definition at line 103 of file AddressSpace.cc.

104  : Component(state),
105  width_(0),
106  minAddress_(0),
107  maxAddress_(0),
108  shared_(true) {
109  loadState(state);
110 
111  for (IDSet::const_iterator i = numericalIds_.begin();
112  i != numericalIds_.end(); ++i) {
113  unsigned id = (*i);
114  TTAMachine::Machine::AddressSpaceNavigator nav = owner.addressSpaceNavigator();
115  for (int asi = 0; asi < nav.count(); ++asi) {
116  AddressSpace& otherAS = *nav.item(asi);
117  if (otherAS.hasNumericalId(id)) {
119  __FILE__, __LINE__, __func__,
120  (boost::format(
121  "Address space '%s' has the same numerical "
122  "id %d as '%s'.") %
123  otherAS.name() % id % name()).str());
124  }
125  }
126  }
127 
128  try {
129  setMachine(owner);
130  } catch (ComponentAlreadyExists&) {
131  MOMTextGenerator textGenerator;
132  format errorMsg = textGenerator.text(MOMTextGenerator::
133  TXT_AS_EXISTS_BY_NAME);
134  errorMsg % name();
135  string procName = "AddressSpace::AddressSpace";
136  throw ObjectStateLoadingException(__FILE__, __LINE__, procName,
137  errorMsg.str());
138  }
139 }

References __func__, TTAMachine::Machine::addressSpaceNavigator(), TTAMachine::Machine::Navigator< ComponentType >::count(), hasNumericalId(), TTAMachine::Machine::Navigator< ComponentType >::item(), loadState(), TTAMachine::Component::name(), numericalIds_, setMachine(), and Texts::TextGenerator::text().

Here is the call graph for this function:

◆ ~AddressSpace()

TTAMachine::AddressSpace::~AddressSpace ( )
virtual

Destructor.

Definition at line 144 of file AddressSpace.cc.

144  {
145  unsetMachine();
146 }

References unsetMachine().

Here is the call graph for this function:

Member Function Documentation

◆ addNumericalId()

void TTAMachine::AddressSpace::addNumericalId ( unsigned  id)
virtual

Adds a numerical address space id that should be mapped to this address space.

Numerical IDs are referred to from programs, i.e., by means of the attribute((address_space(N)). Single ADF address space can map multiple program address spaces.

Definition at line 378 of file AddressSpace.cc.

378  {
379  numericalIds_.insert(id);
380 }

References numericalIds_.

Referenced by loadState().

◆ end()

ULongWord TTAMachine::AddressSpace::end ( ) const
virtual

◆ hasNumericalId()

bool TTAMachine::AddressSpace::hasNumericalId ( unsigned  id) const
virtual

◆ isShared()

virtual bool TTAMachine::AddressSpace::isShared ( ) const
inlinevirtual

◆ loadState()

void TTAMachine::AddressSpace::loadState ( const ObjectState state)
virtual

Loads its state from the given ObjectState instance.

Parameters
stateThe ObjectState instance.
Exceptions
ObjectStateLoadingExceptionIf the given ObjectState instance   is invalid or if the machine already has an address space by the same name as the coming name of this address space.

Reimplemented from TTAMachine::Component.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 334 of file AddressSpace.cc.

334  {
335  const string procName = "AddressSpace::loadState";
336 
337  if (state->name() != OSNAME_ADDRESS_SPACE) {
338  throw ObjectStateLoadingException(__FILE__, __LINE__, procName);
339  }
340 
341  Component::loadState(state);
342 
343  try {
345  ULongWord minAddress = state->uLongAttribute(
347  ULongWord maxAddress = state->uLongAttribute(
349  setAddressBounds(minAddress, maxAddress);
350 
351  if (state->hasAttribute(OSKEY_SHARED_MEMORY)) {
352  setShared(
354  }
355 
356  for (int i = 0; i < state->childCount(); i++) {
357  ObjectState* child = state->child(i);
358  if (child->name() == OSKEY_NUMERICAL_ID) {
359  addNumericalId(child->intValue());
360  }
361  }
362 
363  } catch (Exception& e) {
364  throw ObjectStateLoadingException(__FILE__, __LINE__, procName,
365  e.errorMessage());
366  }
367 }

References addNumericalId(), ObjectState::boolAttribute(), ObjectState::child(), ObjectState::childCount(), Exception::errorMessage(), ObjectState::hasAttribute(), ObjectState::intAttribute(), ObjectState::intValue(), TTAMachine::Component::loadState(), ObjectState::name(), OSKEY_MAX_ADDRESS, OSKEY_MIN_ADDRESS, OSKEY_NUMERICAL_ID, OSKEY_SHARED_MEMORY, OSKEY_WIDTH, OSNAME_ADDRESS_SPACE, setAddressBounds(), setShared(), setWidth(), and ObjectState::uLongAttribute().

Referenced by AddressSpace().

Here is the call graph for this function:

◆ numericalIds()

std::set< unsigned > TTAMachine::AddressSpace::numericalIds ( ) const

Returns ids that are assigned to this address space.

Returns
Address space ids.

Definition at line 393 of file AddressSpace.cc.

393  {
394  return numericalIds_;
395 }

References numericalIds_.

Referenced by AddressSpaceDialog::isFreeId(), printLatexAddressSpaceDescription(), and setNumericalIds().

◆ operator!=()

bool TTAMachine::AddressSpace::operator!= ( const AddressSpace other) const

Definition at line 441 of file AddressSpace.cc.

441  {
442  return !this->operator==(other);
443 }

References operator==().

Here is the call graph for this function:

◆ operator==()

bool TTAMachine::AddressSpace::operator== ( const AddressSpace other) const

Definition at line 432 of file AddressSpace.cc.

432  {
433  return (this->width_ == other.width_
434  && this->minAddress_ == other.minAddress_
435  && this->maxAddress_ == other.maxAddress_
436  && this->numericalIds_ == other.numericalIds_
437  && this->shared_ == other.shared_);
438 }

References maxAddress_, minAddress_, numericalIds_, shared_, and width_.

Referenced by operator!=().

◆ saveState()

ObjectState * TTAMachine::AddressSpace::saveState ( ) const
virtual

Saves the contents to an ObjectState object.

Returns
The newly created ObjectState object.

Reimplemented from TTAMachine::Component.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 295 of file AddressSpace.cc.

295  {
296 
298  as->setAttribute(OSKEY_NAME, name());
299 
300  // set width
302 
303  // set min address
305 
306  // set max address
308 
309  if (!shared_) {
311  }
312 
313  for (IDSet::const_iterator i = numericalIds_.begin();
314  i != numericalIds_.end(); ++i) {
315  ObjectState* child = new ObjectState(OSKEY_NUMERICAL_ID, as);
316  child->setValue((int)(*i));
317  }
318 
319  return as;
320 }

References maxAddress_, minAddress_, TTAMachine::Component::name(), numericalIds_, OSKEY_MAX_ADDRESS, OSKEY_MIN_ADDRESS, TTAMachine::Component::OSKEY_NAME, OSKEY_NUMERICAL_ID, OSKEY_SHARED_MEMORY, OSKEY_WIDTH, OSNAME_ADDRESS_SPACE, ObjectState::setAttribute(), ObjectState::setValue(), shared_, and width_.

Referenced by ADFCombiner::addAddressSpaces().

Here is the call graph for this function:

◆ setAddressBounds()

void TTAMachine::AddressSpace::setAddressBounds ( ULongWord  start,
ULongWord  end 
)
virtual

Sets the memory address bounds of the address space.

Parameters
startThe lowest memory address.
endThe highest memory address.
Exceptions
OutOfRangeIf the given start and end addresses are illegal.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 232 of file AddressSpace.cc.

232  {
233  if (start >= end) {
234  string procName = "AddressSpace::setAddressBounds";
235  throw OutOfRange(__FILE__, __LINE__, procName);
236  }
237 
238  minAddress_ = start;
239  maxAddress_ = end;
240 }

References end(), maxAddress_, minAddress_, and start().

Referenced by loadState().

Here is the call graph for this function:

◆ setMachine()

void TTAMachine::AddressSpace::setMachine ( TTAMachine::Machine mach)
virtual

Registers the address space to a machine. Do not use this method.

Parameters
machMachine to which the address space is going to be registered.
Exceptions
ComponentAlreadyExistsIf there is another address space by the same name in the given machine.

Implements TTAMachine::Component.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 250 of file AddressSpace.cc.

250  {
251  assert(!isRegistered());
252  mach.addAddressSpace(*this);
253  internalSetMachine(mach);
254 }

References TTAMachine::Machine::addAddressSpace(), assert, TTAMachine::Component::internalSetMachine(), and TTAMachine::Component::isRegistered().

Referenced by AddressSpace().

Here is the call graph for this function:

◆ setName()

void TTAMachine::AddressSpace::setName ( const std::string &  name)
virtual

Sets the name of the address space.

Parameters
nameName of the address space.
Exceptions
ComponentAlreadyExistsIf an address space with the given name is already in the same machine.
InvalidNameIf the given name is not valid for a component.

Reimplemented from TTAMachine::Component.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 191 of file AddressSpace.cc.

191  {
192  if (name == this->name()) {
193  return;
194  }
195 
196  if (machine() != NULL) {
197  if (machine()->addressSpaceNavigator().hasItem(name)) {
198  string procName = "AddressSpace::setName";
199  throw ComponentAlreadyExists(__FILE__, __LINE__, procName);
200  } else {
202  }
203  } else {
205  }
206 }

References TTAMachine::Component::machine(), TTAMachine::Component::name(), and TTAMachine::Component::setName().

Here is the call graph for this function:

◆ setNumericalIds()

bool TTAMachine::AddressSpace::setNumericalIds ( const std::set< unsigned > &  ids)

Sets the ids for the address space.

Parameters
idsContains new ids for the address space.
Returns
True if setting the new address space ids was successful.

Definition at line 404 of file AddressSpace.cc.

404  {
405  assert (machine() != NULL);
406 
407  Machine::AddressSpaceNavigator asNavigator =
409 
410  // loop through all other address spaces and check if input parameter
411  // violates any existing ids
412  for (int i = 0; i < asNavigator.count(); i++) {
413  AddressSpace* as = asNavigator.item(i);
414 
415  if (as != this) {
416  IDSet otherIds = as->numericalIds();
417 
418  for (IDSet::iterator id = ids.begin(); id != ids.end(); ++id) {
419  if (AssocTools::containsKey(otherIds, *id)) {
420  return false;
421  }
422  }
423  }
424  }
425 
426  // no violating ids found, overwrite ids for this address space
427  numericalIds_ = ids;
428  return true;
429 }

References TTAMachine::Machine::addressSpaceNavigator(), assert, AssocTools::containsKey(), TTAMachine::Machine::Navigator< ComponentType >::count(), TTAMachine::Machine::Navigator< ComponentType >::item(), TTAMachine::Component::machine(), numericalIds(), and numericalIds_.

Here is the call graph for this function:

◆ setShared()

virtual void TTAMachine::AddressSpace::setShared ( bool  shared)
inlinevirtual

Definition at line 71 of file AddressSpace.hh.

71 { shared_ = shared; }

References shared_.

Referenced by loadState().

◆ setWidth()

void TTAMachine::AddressSpace::setWidth ( int  width)
virtual

Sets the bit width of the minimum addressable word.

Parameters
widthThe bit width of the minimum addressable word.
Exceptions
OutOfRangeIf the given width is illegal (<=0).

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 215 of file AddressSpace.cc.

215  {
216  if (width <= 0) {
217  string procName = "AddressSpace::setWidth";
218  throw OutOfRange(__FILE__, __LINE__, procName);
219  }
220 
221  width_ = width;
222 }

References width(), and width_.

Referenced by loadState(), and CodeCompressorPlugin::setImemWidth().

Here is the call graph for this function:

◆ start()

ULongWord TTAMachine::AddressSpace::start ( ) const
virtual

◆ unsetMachine()

void TTAMachine::AddressSpace::unsetMachine ( )
virtual

Removes registration of the address space from its current machine. The address space is deleted too because it cannot be unregistered.

Implements TTAMachine::Component.

Reimplemented in TTAMachine::NullAddressSpace.

Definition at line 261 of file AddressSpace.cc.

261  {
262 
263  assert(isRegistered());
264  Machine* mach = machine();
265 
266  // remove dangling pointers in function units
267  Machine::FunctionUnitNavigator fuNav = mach->functionUnitNavigator();
268  int units = fuNav.count();
269  for (int i = 0; i < units; i++) {
270  FunctionUnit* fu = fuNav.item(i);
271  if (fu->addressSpace() == this) {
272  fu->setAddressSpace(NULL);
273  }
274  }
275 
276  // remove dangling pointer in GCU
277  ControlUnit* cu = mach->controlUnit();
278  if (cu != NULL) {
279  if (cu->addressSpace() == this) {
280  cu->setAddressSpace(NULL);
281  }
282  }
283 
285  mach->deleteAddressSpace(*this);
286 }

References TTAMachine::FunctionUnit::addressSpace(), assert, TTAMachine::Machine::controlUnit(), TTAMachine::Machine::Navigator< ComponentType >::count(), TTAMachine::Machine::deleteAddressSpace(), TTAMachine::Machine::functionUnitNavigator(), TTAMachine::Component::internalUnsetMachine(), TTAMachine::Component::isRegistered(), TTAMachine::Machine::Navigator< ComponentType >::item(), TTAMachine::Component::machine(), and TTAMachine::FunctionUnit::setAddressSpace().

Referenced by ~AddressSpace().

Here is the call graph for this function:

◆ width()

int TTAMachine::AddressSpace::width ( ) const
virtual

Member Data Documentation

◆ maxAddress_

ULongWord TTAMachine::AddressSpace::maxAddress_
private

Highest address in the address space.

Definition at line 101 of file AddressSpace.hh.

Referenced by AddressSpace(), end(), operator==(), saveState(), and setAddressBounds().

◆ minAddress_

ULongWord TTAMachine::AddressSpace::minAddress_
private

Lowest address in the address space.

Definition at line 99 of file AddressSpace.hh.

Referenced by AddressSpace(), operator==(), saveState(), setAddressBounds(), and start().

◆ numericalIds_

IDSet TTAMachine::AddressSpace::numericalIds_
private

The numerical ids mapped to this address space.

Definition at line 103 of file AddressSpace.hh.

Referenced by addNumericalId(), AddressSpace(), hasNumericalId(), numericalIds(), operator==(), saveState(), and setNumericalIds().

◆ OSKEY_MAX_ADDRESS

const string TTAMachine::AddressSpace::OSKEY_MAX_ADDRESS = "max_a"
static

ObjectState attribute key for maximum address.

Definition at line 90 of file AddressSpace.hh.

Referenced by loadState(), and saveState().

◆ OSKEY_MIN_ADDRESS

const string TTAMachine::AddressSpace::OSKEY_MIN_ADDRESS = "min_a"
static

ObjectState attribute key for minimum address.

Definition at line 88 of file AddressSpace.hh.

Referenced by loadState(), and saveState().

◆ OSKEY_NUMERICAL_ID

const string TTAMachine::AddressSpace::OSKEY_NUMERICAL_ID = "numerical-id"
static

Definition at line 92 of file AddressSpace.hh.

Referenced by loadState(), and saveState().

◆ OSKEY_SHARED_MEMORY

const string TTAMachine::AddressSpace::OSKEY_SHARED_MEMORY = "shared-memory"
static

Definition at line 91 of file AddressSpace.hh.

Referenced by loadState(), and saveState().

◆ OSKEY_WIDTH

const string TTAMachine::AddressSpace::OSKEY_WIDTH = "width"
static

ObjectState attribute key for the bit width.

Definition at line 86 of file AddressSpace.hh.

Referenced by loadState(), and saveState().

◆ OSNAME_ADDRESS_SPACE

const string TTAMachine::AddressSpace::OSNAME_ADDRESS_SPACE = "adress_space"
static

ObjectState name for AddressSpace.

Definition at line 84 of file AddressSpace.hh.

Referenced by loadState(), TTAMachine::Machine::loadState(), and saveState().

◆ shared_

bool TTAMachine::AddressSpace::shared_
private

True in case this address space maps to a memory that is shared across all the cores in the multicore.

Definition at line 106 of file AddressSpace.hh.

Referenced by isShared(), operator==(), saveState(), and setShared().

◆ width_

int TTAMachine::AddressSpace::width_
private

Bit width of the minimum addressable word.

Definition at line 97 of file AddressSpace.hh.

Referenced by AddressSpace(), operator==(), saveState(), setWidth(), and width().


The documentation for this class was generated from the following files:
TTAMachine::Component::internalUnsetMachine
void internalUnsetMachine()
ObjectState::hasAttribute
bool hasAttribute(const std::string &name) const
Definition: ObjectState.cc:205
TTAMachine::Component::setName
virtual void setName(const std::string &name)
Definition: MachinePart.cc:142
TTAMachine::AddressSpace::unsetMachine
virtual void unsetMachine()
Definition: AddressSpace.cc:261
TTAMachine::Component::name
virtual TCEString name() const
Definition: MachinePart.cc:125
TTAMachine::AddressSpace::addNumericalId
virtual void addNumericalId(unsigned id)
Definition: AddressSpace.cc:378
TTAMachine::Component::isRegistered
virtual bool isRegistered() const
Definition: MachinePart.cc:177
ObjectStateLoadingException
Definition: Exception.hh:551
ObjectState::intValue
int intValue() const
AssocTools::containsKey
static bool containsKey(const ContainerType &aContainer, const KeyType &aKey)
ObjectState::uLongAttribute
ULongWord uLongAttribute(const std::string &name) const
Definition: ObjectState.cc:291
TTAMachine::AddressSpace::width_
int width_
Bit width of the minimum addressable word.
Definition: AddressSpace.hh:97
OutOfRange
Definition: Exception.hh:320
TTAMachine::AddressSpace::OSKEY_NUMERICAL_ID
static const std::string OSKEY_NUMERICAL_ID
Definition: AddressSpace.hh:92
ObjectState
Definition: ObjectState.hh:59
TTAMachine::Machine::Navigator::count
int count() const
Texts::TextGenerator::text
virtual boost::format text(int textId)
Definition: TextGenerator.cc:94
TTAMachine::Component::internalSetMachine
void internalSetMachine(Machine &machine)
TTAMachine::AddressSpace::setShared
virtual void setShared(bool shared)
Definition: AddressSpace.hh:71
TTAMachine::AddressSpace::OSNAME_ADDRESS_SPACE
static const std::string OSNAME_ADDRESS_SPACE
ObjectState name for AddressSpace.
Definition: AddressSpace.hh:84
TTAMachine::AddressSpace::OSKEY_MAX_ADDRESS
static const std::string OSKEY_MAX_ADDRESS
ObjectState attribute key for maximum address.
Definition: AddressSpace.hh:90
TTAMachine::Machine::FunctionUnitNavigator
Navigator< FunctionUnit > FunctionUnitNavigator
Navigator type for FunctionUnitNavigator.
Definition: Machine.hh:217
assert
#define assert(condition)
Definition: Application.hh:86
TTAMachine::AddressSpace::setWidth
virtual void setWidth(int width)
Definition: AddressSpace.cc:215
TTAMachine::AddressSpace::OSKEY_WIDTH
static const std::string OSKEY_WIDTH
ObjectState attribute key for the bit width.
Definition: AddressSpace.hh:86
TTAMachine::AddressSpace::AddressSpace
AddressSpace(const std::string &name, int width, ULongWord minAddress, ULongWord maxAddress, Machine &owner)
Definition: AddressSpace.cc:74
TTAMachine::AddressSpace::setAddressBounds
virtual void setAddressBounds(ULongWord start, ULongWord end)
Definition: AddressSpace.cc:232
TTAMachine::Component::Component
Component(const std::string &name)
Definition: MachinePart.cc:82
TTAMachine::Component::loadState
virtual void loadState(const ObjectState *state)
Definition: MachinePart.cc:205
__func__
#define __func__
Definition: Application.hh:67
TTAMachine::Component::OSKEY_NAME
static const std::string OSKEY_NAME
ObjectState attribute key for the name of the component.
Definition: MachinePart.hh:137
ObjectState::child
ObjectState * child(int index) const
Definition: ObjectState.cc:471
TTAMachine::AddressSpace::OSKEY_SHARED_MEMORY
static const std::string OSKEY_SHARED_MEMORY
Definition: AddressSpace.hh:91
ObjectState::childCount
int childCount() const
TTAMachine::Machine::addAddressSpace
virtual void addAddressSpace(AddressSpace &as)
Definition: Machine.cc:248
Exception
Definition: Exception.hh:54
TTAMachine::Machine::addressSpaceNavigator
virtual AddressSpaceNavigator addressSpaceNavigator() const
Definition: Machine.cc:392
ObjectState::name
std::string name() const
Exception::errorMessage
std::string errorMessage() const
Definition: Exception.cc:123
TTAMachine::AddressSpace::width
virtual int width() const
Definition: AddressSpace.cc:155
TTAMachine::AddressSpace::IDSet
std::set< unsigned > IDSet
Definition: AddressSpace.hh:95
TTAMachine::AddressSpace::OSKEY_MIN_ADDRESS
static const std::string OSKEY_MIN_ADDRESS
ObjectState attribute key for minimum address.
Definition: AddressSpace.hh:88
TTAMachine::AddressSpace::setMachine
virtual void setMachine(Machine &mach)
Definition: AddressSpace.cc:250
TTAMachine::Component::machine
virtual Machine * machine() const
MOMTextGenerator
Definition: MOMTextGenerator.hh:40
ObjectState::boolAttribute
bool boolAttribute(const std::string &name) const
Definition: ObjectState.cc:338
TTAMachine::Machine::AddressSpaceNavigator
Navigator< AddressSpace > AddressSpaceNavigator
Navigator type for AddressSpaceNavigator.
Definition: Machine.hh:219
ComponentAlreadyExists
Definition: Exception.hh:510
TTAMachine::AddressSpace::loadState
virtual void loadState(const ObjectState *state)
Definition: AddressSpace.cc:334
ObjectState::intAttribute
int intAttribute(const std::string &name) const
Definition: ObjectState.cc:276
ULongWord
unsigned long ULongWord
Definition: BaseType.hh:51
TTAMachine::Machine::Navigator::item
ComponentType * item(int index) const
TTAMachine::AddressSpace::operator==
bool operator==(const AddressSpace &other) const
Definition: AddressSpace.cc:432
TTAMachine::AddressSpace::shared_
bool shared_
True in case this address space maps to a memory that is shared across all the cores in the multicore...
Definition: AddressSpace.hh:106
TTAMachine::AddressSpace::minAddress_
ULongWord minAddress_
Lowest address in the address space.
Definition: AddressSpace.hh:99
TTAMachine::AddressSpace::numericalIds_
IDSet numericalIds_
The numerical ids mapped to this address space.
Definition: AddressSpace.hh:103
TTAMachine::AddressSpace::start
virtual ULongWord start() const
Definition: AddressSpace.cc:166
TTAMachine::Machine::Navigator
Definition: Machine.hh:186
TTAMachine::AddressSpace::end
virtual ULongWord end() const
Definition: AddressSpace.cc:177
TTAMachine::AddressSpace::maxAddress_
ULongWord maxAddress_
Highest address in the address space.
Definition: AddressSpace.hh:101
ObjectState::setValue
void setValue(const std::string &value)
ObjectState::setAttribute
void setAttribute(const std::string &name, const std::string &value)
Definition: ObjectState.cc:100