OpenASIP 2.2
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | List of all members
TPEF::SymbolElement Class Referenceabstract

#include <SymbolElement.hh>

Inheritance diagram for TPEF::SymbolElement:
Inheritance graph
Collaboration diagram for TPEF::SymbolElement:
Collaboration graph

Public Types

enum  SymbolBinding { STB_LOCAL = 0x0 , STB_GLOBAL = 0x1 , STB_WEAK = 0x2 }
 Binding types of symbol. More...
 
enum  SymbolType {
  STT_NOTYPE = 0x0 , STT_DATA = 0x1 , STT_CODE = 0x2 , STT_SECTION = 0x3 ,
  STT_FILE = 0x4 , STT_PROCEDURE = 0x5
}
 Type of symbol element. More...
 

Public Member Functions

 SymbolElement ()
 
virtual ~SymbolElement ()
 
virtual SymbolType type () const =0
 Returns type of symbol.
 
bool absolute () const
 
void setAbsolute (bool anAbsoluteness)
 
SymbolBinding binding () const
 
void setBinding (SymbolBinding aBinding)
 
Chunkname () const
 
void setName (Chunk *aName)
 
void setName (const ReferenceManager::SafePointer *aName)
 
Sectionsection () const
 
void setSection (Section *aSect)
 
void setSection (const ReferenceManager::SafePointer *aSect)
 
- Public Member Functions inherited from TPEF::SectionElement
virtual ~SectionElement ()
 
- Public Member Functions inherited from TPEF::SafePointable
virtual ~SafePointable ()
 

Private Attributes

bool absolute_
 Is symbol absolutely or relocating.
 
SymbolBinding bind_
 Binding of the symbol.
 
const ReferenceManager::SafePointername_
 The name of the symbol.
 
const ReferenceManager::SafePointersection_
 Section to which the symbol belongs.
 

Additional Inherited Members

- Protected Member Functions inherited from TPEF::SectionElement
 SectionElement ()
 
- Protected Member Functions inherited from TPEF::SafePointable
 SafePointable ()
 

Detailed Description

Symbol table entry.

Definition at line 52 of file SymbolElement.hh.

Member Enumeration Documentation

◆ SymbolBinding

Binding types of symbol.

Enumerator
STB_LOCAL 

Not visible outside the object file that contains it's definition.

STB_GLOBAL 

Visible to all files that are combined in TPEF file.

STB_WEAK 

Visible to all object files that are combined in the TPEF file, but with linkage priority lower than STB_GLOBAL symbols.

Definition at line 55 of file SymbolElement.hh.

55 {
56 STB_LOCAL = 0x0, ///< Not visible outside the object file that
57 ///< contains it's definition.
58 STB_GLOBAL = 0x1, ///< Visible to all files that are combined
59 ///< in TPEF file.
60 STB_WEAK = 0x2 ///< Visible to all object files that are combined
61 ///< in the TPEF file, but with linkage priority
62 ///< lower than STB_GLOBAL symbols.
63 };
@ STB_LOCAL
Not visible outside the object file that contains it's definition.
@ STB_WEAK
Visible to all object files that are combined in the TPEF file, but with linkage priority lower than ...
@ STB_GLOBAL
Visible to all files that are combined in TPEF file.

◆ SymbolType

Type of symbol element.

Enumerator
STT_NOTYPE 

Type is not defined.

STT_DATA 

Associated with data object.

STT_CODE 

Associated with executable code.

STT_SECTION 

Associated with section.

STT_FILE 

Name of symbol gives the name of source file associated with this object file.

STT_PROCEDURE 

Symbol gives indicates procedure start position in section.

Definition at line 66 of file SymbolElement.hh.

66 {
67 STT_NOTYPE = 0x0, ///< Type is not defined.
68 STT_DATA = 0x1, ///< Associated with data object.
69 STT_CODE = 0x2, ///< Associated with executable code.
70 STT_SECTION = 0x3,///< Associated with section.
71 STT_FILE = 0x4, ///< Name of symbol gives the name of source file
72 ///< associated with this object file.
73 STT_PROCEDURE = 0x5 ///< Symbol gives indicates procedure start
74 ///< position in section
75 };
@ STT_PROCEDURE
Symbol gives indicates procedure start position in section.
@ STT_FILE
Name of symbol gives the name of source file associated with this object file.
@ STT_CODE
Associated with executable code.
@ STT_NOTYPE
Type is not defined.
@ STT_SECTION
Associated with section.
@ STT_DATA
Associated with data object.

Constructor & Destructor Documentation

◆ SymbolElement()

TPEF::SymbolElement::SymbolElement ( )

Constructor.

Definition at line 46 of file SymbolElement.cc.

46 :
48 absolute_(false),
52}
static const SafePointer null
The default SafePointer that is used in null references.
const ReferenceManager::SafePointer * section_
Section to which the symbol belongs.
bool absolute_
Is symbol absolutely or relocating.
const ReferenceManager::SafePointer * name_
The name of the symbol.
SymbolBinding bind_
Binding of the symbol.

◆ ~SymbolElement()

TPEF::SymbolElement::~SymbolElement ( )
virtual

Destructor.

Definition at line 57 of file SymbolElement.cc.

57 {
58}

Member Function Documentation

◆ absolute()

bool TPEF::SymbolElement::absolute ( ) const

◆ binding()

SymbolBinding TPEF::SymbolElement::binding ( ) const

◆ name()

Chunk * TPEF::SymbolElement::name ( ) const

◆ section()

Section * TPEF::SymbolElement::section ( ) const

◆ setAbsolute()

void TPEF::SymbolElement::setAbsolute ( bool  anAbsoluteness)

◆ setBinding()

void TPEF::SymbolElement::setBinding ( SymbolBinding  aBinding)

◆ setName() [1/2]

void TPEF::SymbolElement::setName ( Chunk aName)

◆ setName() [2/2]

void TPEF::SymbolElement::setName ( const ReferenceManager::SafePointer aName)

◆ setSection() [1/2]

void TPEF::SymbolElement::setSection ( const ReferenceManager::SafePointer aSect)

◆ setSection() [2/2]

void TPEF::SymbolElement::setSection ( Section aSect)

◆ type()

virtual SymbolType TPEF::SymbolElement::type ( ) const
pure virtual

Member Data Documentation

◆ absolute_

bool TPEF::SymbolElement::absolute_
private

Is symbol absolutely or relocating.

Definition at line 99 of file SymbolElement.hh.

◆ bind_

SymbolBinding TPEF::SymbolElement::bind_
private

Binding of the symbol.

Definition at line 101 of file SymbolElement.hh.

◆ name_

const ReferenceManager::SafePointer* TPEF::SymbolElement::name_
private

The name of the symbol.

Definition at line 103 of file SymbolElement.hh.

◆ section_

const ReferenceManager::SafePointer* TPEF::SymbolElement::section_
private

Section to which the symbol belongs.

Definition at line 105 of file SymbolElement.hh.


The documentation for this class was generated from the following files: