Dyninst::SymtabAPI::Symtab Class Reference

#include <Symtab.h>

Inheritance diagram for Dyninst::SymtabAPI::Symtab:
Dyninst::SymtabAPI::LookupInterface Dyninst::Serializable Dyninst::AnnotatableSparse

Public Types

enum  def_t { NotDefensive, Defensive }
typedef dyn_hash_map< void
*, void *, void_ptr_hasher
annos_by_type_t
typedef std::vector
< annos_by_type_t * > 
annos_t

Public Member Functions

SYMTAB_EXPORT Symtab (MappedFile *)
SYMTAB_EXPORT Symtab ()
SYMTAB_EXPORT Symtab (const Symtab &obj)
SYMTAB_EXPORT Symtab (unsigned char *mem_image, size_t image_size, const std::string &name, bool defensive_binary, bool &err)
SYMTAB_EXPORT Serializableserialize_impl (SerializerBase *sb, const char *tag="Symtab") THROW_SPEC(SerializerError)
void rebuild_symbol_hashes (SerializerBase *)
void rebuild_funcvar_hashes (SerializerBase *)
void rebuild_module_hashes (SerializerBase *)
void rebuild_region_indexes (SerializerBase *) THROW_SPEC(SerializerError)
SYMTAB_EXPORT bool exportXML (std::string filename)
SYMTAB_EXPORT bool exportBin (std::string filename)
SYMTAB_EXPORT bool getRegValueAtFrame (Address pc, Dyninst::MachRegister reg, Dyninst::MachRegisterVal &reg_result, MemRegReader *reader)
SYMTAB_EXPORT bool hasStackwalkDebugInfo ()
virtual SYMTAB_EXPORT bool findSymbol (std::vector< Symbol * > &ret, const std::string &name, Symbol::SymbolType sType=Symbol::ST_UNKNOWN, NameType nameType=anyName, bool isRegex=false, bool checkCase=false, bool includeUndefined=false)
virtual SYMTAB_EXPORT bool getAllSymbols (std::vector< Symbol * > &ret)
virtual SYMTAB_EXPORT bool getAllSymbolsByType (std::vector< Symbol * > &ret, Symbol::SymbolType sType)
std::vector< Symbol * > * findSymbolByOffset (Offset)
SYMTAB_EXPORT bool getAllUndefinedSymbols (std::vector< Symbol * > &ret)
SYMTAB_EXPORT bool getAllDefinedSymbols (std::vector< Symbol * > &ret)
SYMTAB_EXPORT bool findFuncByEntryOffset (Function *&ret, const Offset offset)
SYMTAB_EXPORT bool findFunctionsByName (std::vector< Function * > &ret, const std::string name, NameType nameType=anyName, bool isRegex=false, bool checkCase=true)
SYMTAB_EXPORT bool getAllFunctions (std::vector< Function * > &ret)
SYMTAB_EXPORT bool getContainingFunction (Offset offset, Function *&func)
SYMTAB_EXPORT bool findVariableByOffset (Variable *&ret, const Offset offset)
SYMTAB_EXPORT bool findVariablesByName (std::vector< Variable * > &ret, const std::string name, NameType nameType=anyName, bool isRegex=false, bool checkCase=true)
SYMTAB_EXPORT bool getAllVariables (std::vector< Variable * > &ret)
SYMTAB_EXPORT bool getAllModules (std::vector< Module * > &ret)
SYMTAB_EXPORT bool findModuleByOffset (Module *&ret, Offset off)
SYMTAB_EXPORT bool findModuleByName (Module *&ret, const std::string name)
SYMTAB_EXPORT ModulegetDefaultModule ()
SYMTAB_EXPORT bool getCodeRegions (std::vector< Region * > &ret)
SYMTAB_EXPORT bool getDataRegions (std::vector< Region * > &ret)
SYMTAB_EXPORT bool getAllRegions (std::vector< Region * > &ret)
SYMTAB_EXPORT bool getAllNewRegions (std::vector< Region * > &ret)
SYMTAB_EXPORT bool findRegion (Region *&ret, std::string regname)
SYMTAB_EXPORT bool findRegion (Region *&ret, const Offset addr, const unsigned long size)
SYMTAB_EXPORT bool findRegionByEntry (Region *&ret, const Offset offset)
SYMTAB_EXPORT RegionfindEnclosingRegion (const Offset offset)
SYMTAB_EXPORT bool findException (ExceptionBlock &excp, Offset addr)
SYMTAB_EXPORT bool getAllExceptions (std::vector< ExceptionBlock * > &exceptions)
SYMTAB_EXPORT bool findCatchBlock (ExceptionBlock &excp, Offset addr, unsigned size=0)
SYMTAB_EXPORT bool getFuncBindingTable (std::vector< relocationEntry > &fbt) const
SYMTAB_EXPORT bool updateFuncBindingTable (Offset stub_addr, Offset plt_addr)
SYMTAB_EXPORT bool addSymbol (Symbol *newsym)
SYMTAB_EXPORT bool addSymbol (Symbol *newSym, Symbol *referringSymbol)
SYMTAB_EXPORT FunctioncreateFunction (std::string name, Offset offset, size_t size, Module *mod=NULL)
SYMTAB_EXPORT VariablecreateVariable (std::string name, Offset offset, size_t size, Module *mod=NULL)
SYMTAB_EXPORT bool deleteFunction (Function *func)
SYMTAB_EXPORT bool deleteVariable (Variable *var)
SYMTAB_EXPORT bool isExec () const
SYMTAB_EXPORT bool isStripped ()
SYMTAB_EXPORT ObjectType getObjectType () const
SYMTAB_EXPORT Dyninst::Architecture getArchitecture ()
SYMTAB_EXPORT bool isCode (const Offset where) const
SYMTAB_EXPORT bool isData (const Offset where) const
SYMTAB_EXPORT bool isValidOffset (const Offset where) const
SYMTAB_EXPORT bool isNativeCompiler () const
SYMTAB_EXPORT bool getMappedRegions (std::vector< Region * > &mappedRegs) const
SYMTAB_EXPORT bool getAddressRanges (std::vector< std::pair< Offset, Offset > > &ranges, std::string lineSource, unsigned int LineNo)
SYMTAB_EXPORT bool getSourceLines (std::vector< Statement * > &lines, Offset addressInRange)
SYMTAB_EXPORT bool getSourceLines (std::vector< LineNoTuple > &lines, Offset addressInRange)
SYMTAB_EXPORT bool addLine (std::string lineSource, unsigned int lineNo, unsigned int lineOffset, Offset lowInclAddr, Offset highExclAddr)
SYMTAB_EXPORT bool addAddressRange (Offset lowInclAddr, Offset highExclAddr, std::string lineSource, unsigned int lineNo, unsigned int lineOffset=0)
SYMTAB_EXPORT void setTruncateLinePaths (bool value)
SYMTAB_EXPORT bool getTruncateLinePaths ()
virtual SYMTAB_EXPORT bool findType (Type *&type, std::string name)
virtual SYMTAB_EXPORT TypefindType (unsigned type_id)
virtual SYMTAB_EXPORT bool findVariableType (Type *&type, std::string name)
SYMTAB_EXPORT bool addType (Type *typ)
SYMTAB_EXPORT void parseTypesNow ()
SYMTAB_EXPORT bool findLocalVariable (std::vector< localVar * > &vars, std::string name)
SYMTAB_EXPORT bool hasRel () const
SYMTAB_EXPORT bool hasRela () const
SYMTAB_EXPORT bool hasReldyn () const
SYMTAB_EXPORT bool hasReladyn () const
SYMTAB_EXPORT bool hasRelplt () const
SYMTAB_EXPORT bool hasRelaplt () const
SYMTAB_EXPORT bool isStaticBinary () const
SYMTAB_EXPORT bool emitSymbols (Object *linkedFile, std::string filename, unsigned flag=0)
SYMTAB_EXPORT bool addRegion (Offset vaddr, void *data, unsigned int dataSize, std::string name, Region::RegionType rType_, bool loadable=false, unsigned long memAlign=sizeof(unsigned), bool tls=false)
SYMTAB_EXPORT bool addRegion (Region *newreg)
SYMTAB_EXPORT bool emit (std::string filename, unsigned flag=0)
SYMTAB_EXPORT void addDynLibSubstitution (std::string oldName, std::string newName)
SYMTAB_EXPORT std::string getDynLibSubstitution (std::string name)
SYMTAB_EXPORT bool getSegments (std::vector< Segment > &segs) const
SYMTAB_EXPORT void fixup_code_and_data (Offset newImageOffset, Offset newImageLength, Offset newDataOffset, Offset newDataLength)
SYMTAB_EXPORT bool fixup_RegionAddr (const char *name, Offset memOffset, long memSize)
SYMTAB_EXPORT bool fixup_SymbolAddr (const char *name, Offset newOffset)
SYMTAB_EXPORT bool updateRegion (const char *name, void *buffer, unsigned size)
SYMTAB_EXPORT bool updateCode (void *buffer, unsigned size)
SYMTAB_EXPORT bool updateData (void *buffer, unsigned size)
SYMTAB_EXPORT Offset getFreeOffset (unsigned size)
SYMTAB_EXPORT bool addLibraryPrereq (std::string libname)
SYMTAB_EXPORT bool addSysVDynamic (long name, long value)
SYMTAB_EXPORT bool addLinkingResource (Archive *library)
SYMTAB_EXPORT bool getLinkingResources (std::vector< Archive * > &libs)
SYMTAB_EXPORT bool addExternalSymbolReference (Symbol *externalSym, Region *localRegion, relocationEntry localRel)
SYMTAB_EXPORT bool addTrapHeader_win (Address ptr)
SYMTAB_EXPORT bool updateRelocations (Address start, Address end, Symbol *oldsym, Symbol *newsym)
SYMTAB_EXPORT std::string file () const
SYMTAB_EXPORT std::string name () const
SYMTAB_EXPORT std::string memberName () const
SYMTAB_EXPORT char * mem_image () const
SYMTAB_EXPORT Offset imageOffset () const
SYMTAB_EXPORT Offset dataOffset () const
SYMTAB_EXPORT Offset dataLength () const
SYMTAB_EXPORT Offset imageLength () const
SYMTAB_EXPORT Offset getInitOffset ()
SYMTAB_EXPORT Offset getFiniOffset ()
SYMTAB_EXPORT const char * getInterpreterName () const
SYMTAB_EXPORT unsigned getAddressWidth () const
SYMTAB_EXPORT Offset getLoadOffset () const
SYMTAB_EXPORT Offset getEntryOffset () const
SYMTAB_EXPORT Offset getBaseOffset () const
SYMTAB_EXPORT Offset getTOCoffset (Function *func=NULL) const
SYMTAB_EXPORT Offset getTOCoffset (Offset off) const
SYMTAB_EXPORT Address getLoadAddress ()
SYMTAB_EXPORT bool isDefensiveBinary () const
SYMTAB_EXPORT Offset fileToDiskOffset (Dyninst::Offset) const
SYMTAB_EXPORT Offset fileToMemOffset (Dyninst::Offset) const
SYMTAB_EXPORT std::string getDefaultNamespacePrefix () const
SYMTAB_EXPORT unsigned getNumberofRegions () const
SYMTAB_EXPORT unsigned getNumberofSymbols () const
SYMTAB_EXPORT std::vector
< std::string > & 
getDependencies ()
SYMTAB_EXPORT bool removeLibraryDependency (std::string lib)
SYMTAB_EXPORT ArchivegetParentArchive () const
SYMTAB_EXPORT ~Symtab ()
bool delSymbol (Symbol *sym)
bool deleteSymbol (Symbol *sym)
SymbolgetSymbolByIndex (unsigned)
SYMTAB_EXPORT bool canBeShared ()
SYMTAB_EXPORT ModulegetOrCreateModule (const std::string &modName, const Offset modAddr)
SYMTAB_EXPORT Offset getElfDynamicOffset ()
SYMTAB_EXPORT void getSegmentsSymReader (std::vector< SymSegment > &segs)
ObjectgetObject ()
template<class T >
AN_INLINE bool addAnnotation (const T *a, AnnotationClass< T > &a_id)
bool operator== (AnnotatableSparse &cmp)
template<class T >
AN_INLINE bool getAnnotation (T *&a, AnnotationClass< T > &a_id) const
template<class T >
bool removeAnnotation (AnnotationClass< T > &a_id)
void serializeAnnotations (SerializerBase *sb, const char *)
void annotationsReport ()

Static Public Member Functions

static SYMTAB_EXPORT void version (int &major, int &minor, int &maintenance)
static SYMTAB_EXPORT bool openFile (Symtab *&obj, std::string filename, def_t defensive_binary=NotDefensive)
static SYMTAB_EXPORT bool openFile (Symtab *&obj, void *mem_image, size_t size, std::string name, def_t defensive_binary=NotDefensive)
static SYMTAB_EXPORT SymtabfindOpenSymtab (std::string filename)
static SYMTAB_EXPORT bool closeSymtab (Symtab *)
static bool setup_module_up_ptrs (SerializerBase *, Symtab *st)
static bool fixup_relocation_symbols (SerializerBase *, Symtab *st)
static SymtabimportBin (std::string filename)
static boost::shared_ptr
< builtInTypeCollection
builtInTypes ()
static boost::shared_ptr
< typeCollection
stdTypes ()
static SYMTAB_EXPORT
std::vector< Type * > * 
getAllstdTypes ()
static SYMTAB_EXPORT
std::vector< Type * > * 
getAllbuiltInTypes ()
static SYMTAB_EXPORT SymtabError getLastSymtabError ()
static SYMTAB_EXPORT std::string printError (SymtabError serr)
static boost::shared_ptr< Typetype_Error ()
static boost::shared_ptr< Typetype_Untyped ()

Protected Member Functions

 Symtab (std::string filename, std::string member_name, Offset offset, bool &err, void *base=NULL)
 Symtab (char *img, size_t size, std::string member_name, Offset offset, bool &err, void *base=NULL)

Private Member Functions

SYMTAB_EXPORT Symtab (std::string filename, bool defensive_bin, bool &err)
SYMTAB_EXPORT bool extractInfo (Object *linkedFile)
bool extractSymbolsFromFile (Object *linkedFile, std::vector< Symbol * > &raw_syms)
bool fixSymRegion (Symbol *sym)
bool fixSymModules (std::vector< Symbol * > &raw_syms)
bool demangleSymbols (std::vector< Symbol * > &rawsyms)
bool createIndices (std::vector< Symbol * > &raw_syms, bool undefined)
bool createAggregates ()
bool fixSymModule (Symbol *&sym)
bool demangleSymbol (Symbol *&sym)
bool addSymbolToIndices (Symbol *&sym, bool undefined)
bool addSymbolToAggregates (Symbol *&sym)
bool doNotAggregate (Symbol *&sym)
bool updateIndices (Symbol *sym, std::string newName, NameType nameType)
void setModuleLanguages (dyn_hash_map< std::string, supportedLanguages > *mod_langs)
bool buildDemangledName (const std::string &mangled, std::string &pretty, std::string &typed, bool nativeCompiler, supportedLanguages lang)
bool changeType (Symbol *sym, Symbol::SymbolType oldType)
bool changeSymbolOffset (Symbol *sym, Offset newOffset)
bool deleteSymbolFromIndices (Symbol *sym)
bool changeAggregateOffset (Aggregate *agg, Offset oldOffset, Offset newOffset)
bool deleteAggregate (Aggregate *agg)
void createDefaultModule ()
ModulenewModule (const std::string &name, const Offset addr, supportedLanguages lang)
bool addSymtabVariables ()
void checkPPC64DescriptorSymbols (Object *linkedFile)
void parseLineInformation ()
void parseTypes ()
bool setDefaultNamespacePrefix (std::string &str)
bool addUserRegion (Region *newreg)
bool addUserType (Type *newtypeg)
void setTOCOffset (Offset offset)
bool getExplicitSymtabRefs (std::set< Symtab * > &refs)

Static Private Member Functions

static boost::shared_ptr
< typeCollection
setupStdTypes ()
static boost::shared_ptr
< builtInTypeCollection
setupBuiltinTypes ()

Private Attributes

std::string member_name_
Offset member_offset_
ArchiveparentArchive_
MappedFilemf
MappedFilemfForDebugInfo
Offset imageOffset_
unsigned imageLen_
Offset dataOffset_
unsigned dataLen_
bool is_a_out
Offset main_call_addr_
bool nativeCompiler
unsigned address_width_
char * code_ptr_
char * data_ptr_
std::string interpreter_name_
Offset entry_address_
Offset base_address_
Offset load_address_
ObjectType object_type_
bool is_eel_
std::vector< Segmentsegments_
std::string defaultNamespacePrefix
unsigned no_of_sections
std::vector< Region * > regions_
std::vector< Region * > codeRegions_
std::vector< Region * > dataRegions_
dyn_hash_map< Offset, Region * > regionsByEntryAddr
unsigned newSectionInsertPoint
unsigned no_of_symbols
std::vector< Symbol * > everyDefinedSymbol
std::vector< Symbol * > undefDynSyms
std::map< std::string,
std::vector< Symbol * > > 
undefDynSymsByMangledName
std::map< std::string,
std::vector< Symbol * > > 
undefDynSymsByPrettyName
std::map< std::string,
std::vector< Symbol * > > 
undefDynSymsByTypedName
dyn_hash_map< Offset,
std::vector< Symbol * > > 
symsByOffset
dyn_hash_map< std::string,
std::vector< Symbol * > > 
symsByMangledName
dyn_hash_map< std::string,
std::vector< Symbol * > > 
symsByPrettyName
dyn_hash_map< std::string,
std::vector< Symbol * > > 
symsByTypedName
bool sorted_everyFunction
std::vector< Function * > everyFunction
dyn_hash_map< Offset, Function * > funcsByOffset
std::vector< Variable * > everyVariable
dyn_hash_map< Offset, Variable * > varsByOffset
dyn_hash_map< std::string,
Module * > 
modsByFileName
dyn_hash_map< std::string,
Module * > 
modsByFullName
std::vector< Module * > _mods
std::vector< relocationEntryrelocation_table_
std::vector< ExceptionBlock * > excpBlocks
std::vector< std::string > deps_
std::vector< Archive * > linkingResources_
std::set< Symtab * > explicitSymtabRefs_
bool isLineInfoValid_
bool isTypeInfoValid_
int nlines_
unsigned long fdptr_
char * lines_
char * stabstr_
int nstabs_
void * stabs_
char * stringpool_
bool hasRel_
bool hasRela_
bool hasReldyn_
bool hasReladyn_
bool hasRelplt_
bool hasRelaplt_
bool isStaticBinary_
bool isDefensiveBinary_
Objectobj_private
std::map< std::string,
std::string > 
dynLibSubs
unsigned _ref_cnt

Static Private Attributes

static std::vector< Symtab * > allSymtabs

Friends

class Archive
class Symbol
class Function
class Variable
class Module
class Region
class emitElf
class emitElf64
class emitElfStatic
class emitWin
class Aggregate
class relocationEntry

Detailed Description

Definition at line 70 of file Symtab.h.


Member Typedef Documentation

typedef dyn_hash_map<void *, void *, void_ptr_hasher> Dyninst::AnnotatableSparse::annos_by_type_t [inherited]

Definition at line 505 of file Annotatable.h.

typedef std::vector<annos_by_type_t *> Dyninst::AnnotatableSparse::annos_t [inherited]

Definition at line 508 of file Annotatable.h.


Member Enumeration Documentation

Enumerator:
NotDefensive 
Defensive 

Definition at line 102 of file Symtab.h.


Constructor & Destructor Documentation

SYMTAB_EXPORT Symtab::Symtab ( MappedFile mf_  ) 
SYMTAB_EXPORT Symtab::Symtab (  ) 

Definition at line 399 of file Symtab.C.

References create_printf(), createDefaultModule(), FILE__, and init_debug_symtabAPI().

Referenced by openFile().

Symtab::Symtab ( const Symtab obj  ) 
Symtab::Symtab ( unsigned char *  mem_image,
size_t  image_size,
const std::string &  name,
bool  defensive_binary,
bool &  err 
)
Symtab::~Symtab (  ) 
Symtab::Symtab ( std::string  filename,
std::string  member_name,
Offset  offset,
bool &  err,
void *  base = NULL 
) [protected]

Definition at line 1330 of file Symtab.C.

Symtab::Symtab ( char *  img,
size_t  size,
std::string  member_name,
Offset  offset,
bool &  err,
void *  base = NULL 
) [protected]

Definition at line 1359 of file Symtab.C.

Symtab::Symtab ( std::string  filename,
bool  defensive_bin,
bool &  err 
) [private]

Member Function Documentation

SYMTAB_EXPORT bool Symtab::addAddressRange ( Offset  lowInclAddr,
Offset  highExclAddr,
std::string  lineSource,
unsigned int  lineNo,
unsigned int  lineOffset = 0 
)
template<class T >
AN_INLINE bool Dyninst::AnnotatableSparse::addAnnotation ( const T *  a,
AnnotationClass< T > &  a_id 
) [inline, inherited]
SYMTAB_EXPORT void Symtab::addDynLibSubstitution ( std::string  oldName,
std::string  newName 
)

Definition at line 2676 of file Symtab.C.

References dynLibSubs.

SYMTAB_EXPORT bool Symtab::addExternalSymbolReference ( Symbol externalSym,
Region localRegion,
relocationEntry  localRel 
)
SYMTAB_EXPORT bool Symtab::addLibraryPrereq ( std::string  libname  ) 
SYMTAB_EXPORT bool Symtab::addLine ( std::string  lineSource,
unsigned int  lineNo,
unsigned int  lineOffset,
Offset  lowInclAddr,
Offset  highExclAddr 
)
SYMTAB_EXPORT bool Symtab::addLinkingResource ( Archive library  ) 

Definition at line 3821 of file Symtab.C.

References linkingResources_.

bool Symtab::addRegion ( Region newreg  ) 
bool Symtab::addRegion ( Offset  vaddr,
void *  data,
unsigned int  dataSize,
std::string  name,
Region::RegionType  rType_,
bool  loadable = false,
unsigned long  memAlign = sizeof(unsigned),
bool  tls = false 
)
bool Symtab::addSymbol ( Symbol newSym,
Symbol referringSymbol 
)
bool Symtab::addSymbol ( Symbol newsym  ) 
bool Symtab::addSymbolToAggregates ( Symbol *&  sym  )  [private]
bool Symtab::addSymbolToIndices ( Symbol *&  sym,
bool  undefined 
) [private]
bool Dyninst::SymtabAPI::Symtab::addSymtabVariables (  )  [private]
SYMTAB_EXPORT bool Symtab::addSysVDynamic ( long  name,
long  value 
)
SYMTAB_EXPORT bool Symtab::addTrapHeader_win ( Address  ptr  ) 

Definition at line 3804 of file Symtab.C.

References getObject(), and Dyninst::SymtabAPI::Object::setTrapHeader().

bool Symtab::addType ( Type typ  ) 
bool Symtab::addUserRegion ( Region newreg  )  [private]
bool Symtab::addUserType ( Type newtypeg  )  [private]
void Dyninst::AnnotatableSparse::annotationsReport (  )  [inline, inherited]
bool Symtab::buildDemangledName ( const std::string &  mangled,
std::string &  pretty,
std::string &  typed,
bool  nativeCompiler,
supportedLanguages  lang 
) [private]
boost::shared_ptr< builtInTypeCollection > Symtab::builtInTypes (  )  [static]
SYMTAB_EXPORT bool Symtab::canBeShared (  ) 

Definition at line 3846 of file Symtab.C.

References MappedFile::canBeShared().

bool Symtab::changeAggregateOffset ( Aggregate agg,
Offset  oldOffset,
Offset  newOffset 
) [private]

Definition at line 209 of file Symtab-edit.C.

References funcsByOffset, and varsByOffset.

Referenced by Dyninst::SymtabAPI::Aggregate::changeSymbolOffset().

bool Symtab::changeSymbolOffset ( Symbol sym,
Offset  newOffset 
) [private]
bool Symtab::changeType ( Symbol sym,
Symbol::SymbolType  oldType 
) [private]
void Dyninst::SymtabAPI::Symtab::checkPPC64DescriptorSymbols ( Object linkedFile  )  [private]
bool Symtab::closeSymtab ( Symtab st  )  [static]

Definition at line 2049 of file Symtab.C.

References _ref_cnt, and allSymtabs.

Referenced by Dyninst::SymtabAPI::SymtabReader::~SymtabReader().

bool Symtab::createAggregates (  )  [private]

Definition at line 741 of file Symtab.C.

References addSymbolToAggregates(), doNotAggregate(), and everyDefinedSymbol.

Referenced by extractInfo().

void Symtab::createDefaultModule (  )  [private]
Function * Symtab::createFunction ( std::string  name,
Offset  offset,
size_t  size,
Module mod = NULL 
)
bool Symtab::createIndices ( std::vector< Symbol * > &  raw_syms,
bool  undefined 
) [private]

Definition at line 726 of file Symtab.C.

References addSymbolToIndices().

Referenced by extractInfo().

Variable * Symtab::createVariable ( std::string  name,
Offset  offset,
size_t  size,
Module mod = NULL 
)
SYMTAB_EXPORT Offset Symtab::dataLength (  )  const

Definition at line 440 of file Symtab.C.

References dataLen_.

SYMTAB_EXPORT Offset Symtab::dataOffset (  )  const

Definition at line 435 of file Symtab.C.

References dataOffset_.

Referenced by Dyninst::SymtabAPI::SymtabReader::dataOffset().

bool Symtab::deleteAggregate ( Aggregate agg  )  [private]
bool Symtab::deleteFunction ( Function func  ) 
bool Symtab::deleteSymbol ( Symbol sym  ) 
bool Symtab::deleteSymbolFromIndices ( Symbol sym  )  [private]
bool Symtab::deleteVariable ( Variable var  ) 
bool Dyninst::SymtabAPI::Symtab::delSymbol ( Symbol sym  )  [inline]

Definition at line 354 of file Symtab.h.

References deleteSymbol().

bool Symtab::demangleSymbol ( Symbol *&  sym  )  [private]
bool Symtab::demangleSymbols ( std::vector< Symbol * > &  rawsyms  )  [private]

Definition at line 711 of file Symtab.C.

References demangleSymbol().

Referenced by extractInfo().

bool Symtab::doNotAggregate ( Symbol *&  sym  )  [private]
SYMTAB_EXPORT bool Symtab::emit ( std::string  filename,
unsigned  flag = 0 
)
SYMTAB_EXPORT bool Symtab::emitSymbols ( Object linkedFile,
std::string  filename,
unsigned  flag = 0 
)

Definition at line 2646 of file Symtab.C.

References Dyninst::SymtabAPI::Object::emitDriver(), everyDefinedSymbol, and undefDynSyms.

Referenced by emit().

SYMTAB_EXPORT bool Dyninst::SymtabAPI::Symtab::exportBin ( std::string  filename  ) 

Referenced by openFile().

SYMTAB_EXPORT bool Dyninst::SymtabAPI::Symtab::exportXML ( std::string  filename  ) 
bool Symtab::extractInfo ( Object linkedFile  )  [private]

Definition at line 1375 of file Symtab.C.

References address_width_, base_address_, Dyninst::SymtabAPI::AObject::clearSymsToMods(), Dyninst::SymtabAPI::AObject::code_len(), Dyninst::SymtabAPI::AObject::code_off(), Dyninst::SymtabAPI::AObject::code_ptr(), code_ptr_, Dyninst::SymtabAPI::AObject::code_ptr_, codeRegions_, createAggregates(), createDefaultModule(), createIndices(), Dyninst::SymtabAPI::AObject::data_len(), Dyninst::SymtabAPI::AObject::data_off(), Dyninst::SymtabAPI::AObject::data_ptr(), data_ptr_, dataLen_, dataOffset_, dataRegions_, demangleSymbols(), deps_, entry_address_, excpBlocks, extractSymbolsFromFile(), fdptr_, FILE__, fixSymModules(), fprintf, Dyninst::SymtabAPI::Object::get_func_binding_table(), Dyninst::SymtabAPI::Object::get_line_info(), Dyninst::SymtabAPI::Object::get_stab_info(), Dyninst::SymtabAPI::AObject::getAddressWidth(), Dyninst::SymtabAPI::AObject::getAllExceptions(), Dyninst::SymtabAPI::AObject::getAllRegions(), Dyninst::SymtabAPI::AObject::getAllSymbols(), Dyninst::SymtabAPI::Object::getBaseAddress(), Dyninst::SymtabAPI::Object::getDependencies(), Dyninst::SymtabAPI::Object::getEntryAddress(), Dyninst::SymtabAPI::Object::getLoadAddress(), Dyninst::SymtabAPI::Object::getModuleLanguageInfo(), getObject(), getRegionType(), Dyninst::SymtabAPI::AObject::getSegments(), gettimeofday(), hasRel_, hasRela_, Dyninst::SymtabAPI::Object::hasReladyn(), hasReladyn_, Dyninst::SymtabAPI::Object::hasRelaplt(), hasRelaplt_, Dyninst::SymtabAPI::Object::hasReldyn(), hasReldyn_, Dyninst::SymtabAPI::Object::hasRelplt(), hasRelplt_, imageLen_, imageOffset_, Dyninst::SymtabAPI::Object::interpreter_name(), interpreter_name_, is_a_out, Dyninst::SymtabAPI::AObject::is_aout(), is_eel_, isDefensiveBinary_, Dyninst::SymtabAPI::Object::isEEL(), Dyninst::SymtabAPI::AObject::isStaticBinary(), isStaticBinary_, lines_, load_address_, nativeCompiler, newSectionInsertPoint, nlines_, Dyninst::SymtabAPI::AObject::no_of_sections(), no_of_sections, Dyninst::SymtabAPI::AObject::no_of_symbols(), no_of_symbols, nstabs_, Dyninst::SymtabAPI::Obj_Parsing, Dyninst::SymtabAPI::obj_RelocatableFile, object_type_, Dyninst::SymtabAPI::Object::objType(), parseCompilerType(), print_symbol_map(), regions_, regionsByEntryAddr, relocation_table_, Dyninst::SymtabAPI::Region::RP_RW, Dyninst::SymtabAPI::Region::RP_RWX, Dyninst::SymtabAPI::Region::RP_RX, Dyninst::SymtabAPI::Region::RT_REL, Dyninst::SymtabAPI::Region::RT_RELA, segments_, serr, setModuleLanguages(), sort_reg_by_addr(), stabs_, stabstr_, stringpool_, Dyninst::SymtabAPI::Syms_To_Functions, and undefDynSyms.

Referenced by Symtab().

bool Symtab::extractSymbolsFromFile ( Object linkedFile,
std::vector< Symbol * > &  raw_syms 
) [private]
SYMTAB_EXPORT std::string Symtab::file (  )  const
Dyninst::Offset Symtab::fileToDiskOffset ( Dyninst::Offset  fileOffset  )  const

Definition at line 769 of file Symtab-lookup.C.

References regions_.

Dyninst::Offset Symtab::fileToMemOffset ( Dyninst::Offset  fileOffset  )  const

Definition at line 779 of file Symtab-lookup.C.

References regions_.

bool Symtab::findCatchBlock ( ExceptionBlock excp,
Offset  addr,
unsigned  size = 0 
)

Returns true if the Address range addr -> addr+size contains a catch block, with excp pointing to the appropriate block

Definition at line 455 of file Symtab-lookup.C.

References excpBlocks.

Region * Symtab::findEnclosingRegion ( const Offset  offset  ) 
bool Symtab::findException ( ExceptionBlock excp,
Offset  addr 
)

Definition at line 437 of file Symtab-lookup.C.

References excpBlocks.

bool Symtab::findFuncByEntryOffset ( Function *&  ret,
const Offset  offset 
)
bool Symtab::findFunctionsByName ( std::vector< Function * > &  ret,
const std::string  name,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = true 
)
SYMTAB_EXPORT bool Symtab::findLocalVariable ( std::vector< localVar * > &  vars,
std::string  name 
)

Definition at line 2589 of file Symtab.C.

References everyFunction, and parseTypesNow().

bool Symtab::findModuleByName ( Module *&  ret,
const std::string  name 
)
bool Symtab::findModuleByOffset ( Module *&  ret,
Offset  off 
)

Definition at line 331 of file Symtab-lookup.C.

References _mods, and Dyninst::SymtabAPI::Module::addr().

Symtab * Symtab::findOpenSymtab ( std::string  filename  )  [static]

Definition at line 2073 of file Symtab.C.

References allSymtabs, MappedFile::canBeShared(), and file().

Referenced by addLibraryPrereq(), and openFile().

bool Symtab::findRegion ( Region *&  ret,
const Offset  addr,
const unsigned long  size 
)
bool Symtab::findRegion ( Region *&  ret,
std::string  regname 
)
bool Symtab::findRegionByEntry ( Region *&  ret,
const Offset  offset 
)

Definition at line 488 of file Symtab-lookup.C.

References Dyninst::SymtabAPI::No_Such_Region, regionsByEntryAddr, and serr.

bool Symtab::findSymbol ( std::vector< Symbol * > &  ret,
const std::string &  name,
Symbol::SymbolType  sType = Symbol::ST_UNKNOWN,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = false,
bool  includeUndefined = false 
) [virtual]
std::vector< Symbol * > * Symtab::findSymbolByOffset ( Offset  o  ) 

Definition at line 66 of file Symtab-lookup.C.

References symsByOffset.

Referenced by fixup_SymbolAddr().

SYMTAB_EXPORT Type * Symtab::findType ( unsigned  type_id  )  [virtual]
SYMTAB_EXPORT bool Symtab::findType ( Type *&  type,
std::string  name 
) [virtual]
bool Symtab::findVariableByOffset ( Variable *&  ret,
const Offset  offset 
)
bool Symtab::findVariablesByName ( std::vector< Variable * > &  ret,
const std::string  name,
NameType  nameType = anyName,
bool  isRegex = false,
bool  checkCase = true 
)
SYMTAB_EXPORT bool Symtab::findVariableType ( Type *&  type,
std::string  name 
) [virtual]
bool Symtab::fixSymModule ( Symbol *&  sym  )  [private]
bool Symtab::fixSymModules ( std::vector< Symbol * > &  raw_syms  )  [private]
bool Symtab::fixSymRegion ( Symbol sym  )  [private]
SYMTAB_EXPORT void Symtab::fixup_code_and_data ( Offset  newImageOffset,
Offset  newImageLength,
Offset  newDataOffset,
Offset  newDataLength 
)

Definition at line 450 of file Symtab.C.

References dataLen_, dataOffset_, imageLen_, and imageOffset_.

SYMTAB_EXPORT bool Symtab::fixup_RegionAddr ( const char *  name,
Offset  memOffset,
long  memSize 
)
bool Symtab::fixup_relocation_symbols ( SerializerBase ,
Symtab st 
) [static]

Definition at line 3024 of file Symtab.C.

References _mods, and Dyninst::SymtabAPI::Module::exec_.

SYMTAB_EXPORT bool Symtab::fixup_SymbolAddr ( const char *  name,
Offset  newOffset 
)
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Symtab::getAddressRanges ( std::vector< std::pair< Offset, Offset > > &  ranges,
std::string  lineSource,
unsigned int  LineNo 
)
SYMTAB_EXPORT unsigned Symtab::getAddressWidth (  )  const
SYMTAB_EXPORT vector< Type * > * Symtab::getAllbuiltInTypes (  )  [static]

Definition at line 2494 of file Symtab.C.

References builtInTypes().

bool Symtab::getAllDefinedSymbols ( std::vector< Symbol * > &  ret  ) 
bool Symtab::getAllExceptions ( std::vector< ExceptionBlock * > &  exceptions  ) 

Definition at line 425 of file Symtab-lookup.C.

References excpBlocks.

bool Symtab::getAllFunctions ( std::vector< Function * > &  ret  ) 
bool Symtab::getAllModules ( std::vector< Module * > &  ret  ) 

Definition at line 319 of file Symtab-lookup.C.

References _mods, Dyninst::SymtabAPI::No_Such_Module, and serr.

Referenced by add_type_info().

bool Symtab::getAllNewRegions ( std::vector< Region * > &  ret  ) 
bool Symtab::getAllRegions ( std::vector< Region * > &  ret  ) 
SYMTAB_EXPORT vector< Type * > * Symtab::getAllstdTypes (  )  [static]

Definition at line 2489 of file Symtab.C.

References stdTypes().

bool Symtab::getAllSymbols ( std::vector< Symbol * > &  ret  )  [virtual]
bool Symtab::getAllSymbolsByType ( std::vector< Symbol * > &  ret,
Symbol::SymbolType  sType 
) [virtual]
bool Symtab::getAllUndefinedSymbols ( std::vector< Symbol * > &  ret  ) 
bool Symtab::getAllVariables ( std::vector< Variable * > &  ret  ) 

Definition at line 313 of file Symtab-lookup.C.

References everyVariable.

template<class T >
AN_INLINE bool Dyninst::AnnotatableSparse::getAnnotation ( T *&  a,
AnnotationClass< T > &  a_id 
) const [inline, inherited]
SYMTAB_EXPORT Dyninst::Architecture Symtab::getArchitecture (  ) 

Definition at line 2975 of file Symtab.C.

References Dyninst::SymtabAPI::Object::getArch(), and getObject().

SYMTAB_EXPORT Offset Symtab::getBaseOffset (  )  const

Definition at line 486 of file Symtab.C.

References base_address_.

bool Symtab::getCodeRegions ( std::vector< Region * > &  ret  ) 

Definition at line 384 of file Symtab-lookup.C.

References codeRegions_.

bool Symtab::getContainingFunction ( Offset  offset,
Function *&  func 
)
bool Symtab::getDataRegions ( std::vector< Region * > &  ret  ) 

Definition at line 395 of file Symtab-lookup.C.

References dataRegions_.

Module * Symtab::getDefaultModule (  ) 
SYMTAB_EXPORT string Symtab::getDefaultNamespacePrefix (  )  const

Definition at line 511 of file Symtab.C.

References defaultNamespacePrefix.

SYMTAB_EXPORT std::vector< std::string > & Symtab::getDependencies (  ) 

Definition at line 1794 of file Symtab.C.

References deps_.

SYMTAB_EXPORT std::string Symtab::getDynLibSubstitution ( std::string  name  ) 

Definition at line 2681 of file Symtab.C.

References dynLibSubs, and MappedFile::filename().

SYMTAB_EXPORT Offset Symtab::getElfDynamicOffset (  ) 

Definition at line 3666 of file Symtab.C.

References FILE__, fprintf, Dyninst::SymtabAPI::Object::getDynamicAddr(), and getObject().

SYMTAB_EXPORT Offset Symtab::getEntryOffset (  )  const

Definition at line 481 of file Symtab.C.

References entry_address_.

bool Symtab::getExplicitSymtabRefs ( std::set< Symtab * > &  refs  )  [private]

Definition at line 3816 of file Symtab.C.

References explicitSymtabRefs_.

Referenced by Dyninst::SymtabAPI::emitElfStatic::resolveSymbols().

SYMTAB_EXPORT Offset Symtab::getFiniOffset (  ) 

Definition at line 3861 of file Symtab.C.

References Dyninst::SymtabAPI::Object::getFiniAddr(), and getObject().

SYMTAB_EXPORT Offset Symtab::getFreeOffset ( unsigned  size  ) 
SYMTAB_EXPORT bool Symtab::getFuncBindingTable ( std::vector< relocationEntry > &  fbt  )  const

Definition at line 1768 of file Symtab.C.

References relocation_table_.

SYMTAB_EXPORT Offset Symtab::getInitOffset (  ) 

Definition at line 3851 of file Symtab.C.

References Dyninst::SymtabAPI::Object::getInitAddr(), and getObject().

SYMTAB_EXPORT const char * Symtab::getInterpreterName (  )  const

Definition at line 474 of file Symtab.C.

References interpreter_name_.

Referenced by Dyninst::SymtabAPI::SymtabReader::getInterpreterName().

SymtabError Symtab::getLastSymtabError (  )  [static]

Definition at line 98 of file Symtab.C.

References serr.

SYMTAB_EXPORT bool Symtab::getLinkingResources ( std::vector< Archive * > &  libs  ) 

Definition at line 3827 of file Symtab.C.

References linkingResources_.

Referenced by Dyninst::SymtabAPI::emitElfStatic::resolveSymbols().

SYMTAB_EXPORT Address Symtab::getLoadAddress (  ) 

Definition at line 3832 of file Symtab.C.

References Dyninst::SymtabAPI::Object::getLoadAddress(), and getObject().

SYMTAB_EXPORT Offset Symtab::getLoadOffset (  )  const

Definition at line 491 of file Symtab.C.

References load_address_.

SYMTAB_EXPORT bool Symtab::getMappedRegions ( std::vector< Region * > &  mappedRegs  )  const

Definition at line 2713 of file Symtab.C.

References regions_.

SYMTAB_EXPORT unsigned Symtab::getNumberofRegions (  )  const

Definition at line 3001 of file Symtab.C.

References no_of_sections.

SYMTAB_EXPORT unsigned Symtab::getNumberofSymbols (  )  const

Definition at line 3006 of file Symtab.C.

References no_of_symbols.

Object * Symtab::getObject (  ) 
SYMTAB_EXPORT ObjectType Symtab::getObjectType (  )  const
Module * Symtab::getOrCreateModule ( const std::string &  modName,
const Offset  modAddr 
)

Definition at line 1128 of file Symtab.C.

References findModuleByName(), Dyninst::SymtabAPI::lang_Unknown, and newModule().

Referenced by fixSymModule(), and fixSymModules().

SYMTAB_EXPORT Archive * Symtab::getParentArchive (  )  const

Definition at line 1798 of file Symtab.C.

References parentArchive_.

Referenced by Dyninst::SymtabAPI::emitElfStatic::resolveSymbols().

bool Symtab::getRegValueAtFrame ( Address  pc,
Dyninst::MachRegister  reg,
Dyninst::MachRegisterVal reg_result,
MemRegReader reader 
)
SYMTAB_EXPORT bool Dyninst::SymtabAPI::Symtab::getSegments ( std::vector< Segment > &  segs  )  const
void Symtab::getSegmentsSymReader ( std::vector< SymSegment > &  segs  ) 
SYMTAB_EXPORT bool Symtab::getSourceLines ( std::vector< LineNoTuple > &  lines,
Offset  addressInRange 
)

Definition at line 2370 of file Symtab.C.

References _mods, and Dyninst::SymtabAPI::LineInformation::getSourceLines().

SYMTAB_EXPORT bool Symtab::getSourceLines ( std::vector< Statement * > &  lines,
Offset  addressInRange 
)

Definition at line 2349 of file Symtab.C.

References _mods, and Dyninst::SymtabAPI::LineInformation::getSourceLines().

Symbol* Dyninst::SymtabAPI::Symtab::getSymbolByIndex ( unsigned   ) 
SYMTAB_EXPORT Offset Symtab::getTOCoffset ( Offset  off  )  const

Definition at line 501 of file Symtab.C.

References Dyninst::SymtabAPI::Object::getTOCoffset(), and obj_private.

SYMTAB_EXPORT Offset Symtab::getTOCoffset ( Function func = NULL  )  const
bool Symtab::getTruncateLinePaths (  ) 

Definition at line 2444 of file Symtab.C.

References getObject(), and Dyninst::SymtabAPI::Object::getTruncateLinePaths().

SYMTAB_EXPORT bool Symtab::hasRel (  )  const

Definition at line 2605 of file Symtab.C.

References hasRel_.

SYMTAB_EXPORT bool Symtab::hasRela (  )  const

Definition at line 2610 of file Symtab.C.

References hasRela_.

SYMTAB_EXPORT bool Symtab::hasReladyn (  )  const

Definition at line 2620 of file Symtab.C.

References hasReladyn_.

SYMTAB_EXPORT bool Symtab::hasRelaplt (  )  const

Definition at line 2630 of file Symtab.C.

References hasRelaplt_.

SYMTAB_EXPORT bool Symtab::hasReldyn (  )  const

Definition at line 2615 of file Symtab.C.

References hasReldyn_.

SYMTAB_EXPORT bool Symtab::hasRelplt (  )  const

Definition at line 2625 of file Symtab.C.

References hasRelplt_.

bool Symtab::hasStackwalkDebugInfo (  ) 
SYMTAB_EXPORT Offset Symtab::imageLength (  )  const

Definition at line 445 of file Symtab.C.

References imageLen_.

SYMTAB_EXPORT Offset Symtab::imageOffset (  )  const

Definition at line 430 of file Symtab.C.

References imageOffset_.

Referenced by Dyninst::SymtabAPI::SymtabReader::imageOffset().

Symtab * Symtab::importBin ( std::string  filename  )  [static]

Definition at line 2010 of file Symtab.C.

Referenced by openFile().

bool Symtab::isCode ( const Offset  where  )  const
bool Symtab::isData ( const Offset  where  )  const
SYMTAB_EXPORT bool Symtab::isDefensiveBinary (  )  const

Definition at line 3841 of file Symtab.C.

References isDefensiveBinary_.

Referenced by createFunction().

SYMTAB_EXPORT bool Symtab::isExec (  )  const
SYMTAB_EXPORT bool Symtab::isNativeCompiler (  )  const
SYMTAB_EXPORT bool Symtab::isStaticBinary (  )  const
SYMTAB_EXPORT bool Symtab::isStripped (  ) 

Definition at line 420 of file Symtab.C.

References findRegion(), and no_of_symbols.

bool Symtab::isValidOffset ( const Offset  where  )  const

Definition at line 1676 of file Symtab.C.

References isCode(), and isData().

SYMTAB_EXPORT char * Symtab::mem_image (  )  const

Definition at line 2980 of file Symtab.C.

References MappedFile::base_addr().

SYMTAB_EXPORT std::string Symtab::memberName (  )  const

Definition at line 2996 of file Symtab.C.

References member_name_.

Referenced by Dyninst::SymtabAPI::emitElfStatic::resolveSymbols().

SYMTAB_EXPORT std::string Symtab::name (  )  const
Module * Symtab::newModule ( const std::string &  name,
const Offset  addr,
supportedLanguages  lang 
) [private]
bool Symtab::openFile ( Symtab *&  obj,
void *  mem_image,
size_t  size,
std::string  name,
def_t  defensive_binary = NotDefensive 
) [static]

Definition at line 2016 of file Symtab.C.

References allSymtabs, Defensive, gettimeofday(), and Symtab().

bool Symtab::openFile ( Symtab *&  obj,
std::string  filename,
def_t  defensive_binary = NotDefensive 
) [static]
bool Dyninst::AnnotatableSparse::operator== ( AnnotatableSparse cmp  )  [inline, inherited]
void Symtab::parseLineInformation (  )  [private]
void Symtab::parseTypes (  )  [private]
void Symtab::parseTypesNow (  ) 
std::string Symtab::printError ( SymtabError  serr  )  [static]
void Symtab::rebuild_funcvar_hashes ( SerializerBase sb  ) 
void Symtab::rebuild_module_hashes ( SerializerBase sb  ) 
void Symtab::rebuild_region_indexes ( SerializerBase sb  ) 
void Symtab::rebuild_symbol_hashes ( SerializerBase sb  ) 
template<class T >
bool Dyninst::AnnotatableSparse::removeAnnotation ( AnnotationClass< T > &  a_id  )  [inline, inherited]
SYMTAB_EXPORT bool Symtab::removeLibraryDependency ( std::string  lib  ) 
Serializable * Symtab::serialize_impl ( SerializerBase sb,
const char *  tag = "Symtab" 
)

Definition at line 3183 of file Symtab.C.

void Dyninst::AnnotatableSparse::serializeAnnotations ( SerializerBase sb,
const char *   
) [inline, inherited]
bool Dyninst::SymtabAPI::Symtab::setDefaultNamespacePrefix ( std::string &  str  )  [private]
void Symtab::setModuleLanguages ( dyn_hash_map< std::string, supportedLanguages > *  mod_langs  )  [private]
void Symtab::setTOCOffset ( Offset  offset  )  [private]
void Symtab::setTruncateLinePaths ( bool  value  ) 

Definition at line 2439 of file Symtab.C.

References getObject(), and Dyninst::SymtabAPI::Object::setTruncateLinePaths().

bool Symtab::setup_module_up_ptrs ( SerializerBase ,
Symtab st 
) [static]

Definition at line 3011 of file Symtab.C.

References _mods, and Dyninst::SymtabAPI::Module::exec_.

boost::shared_ptr< builtInTypeCollection > Symtab::setupBuiltinTypes (  )  [static, private]

Definition at line 169 of file Symtab.C.

References builtInTypes().

Referenced by builtInTypes().

boost::shared_ptr< typeCollection > Symtab::setupStdTypes (  )  [static, private]

Definition at line 306 of file Symtab.C.

References Dyninst::SymtabAPI::Type::decrRefCount(), and stdTypes().

Referenced by stdTypes().

boost::shared_ptr< typeCollection > Symtab::stdTypes (  )  [static]
boost::shared_ptr< Type > Symtab::type_Error (  )  [static]
boost::shared_ptr< Type > Symtab::type_Untyped (  )  [static]

Definition at line 149 of file Symtab.C.

References Dyninst::SymtabAPI::dataUnknownType.

Referenced by Dyninst::SymtabAPI::parseStabString().

SYMTAB_EXPORT bool Symtab::updateCode ( void *  buffer,
unsigned  size 
)

Definition at line 2839 of file Symtab.C.

References updateRegion().

SYMTAB_EXPORT bool Symtab::updateData ( void *  buffer,
unsigned  size 
)

Definition at line 2844 of file Symtab.C.

References updateRegion().

SYMTAB_EXPORT bool Symtab::updateFuncBindingTable ( Offset  stub_addr,
Offset  plt_addr 
)

Definition at line 1774 of file Symtab.C.

References relocation_table_.

bool Symtab::updateIndices ( Symbol sym,
std::string  newName,
NameType  nameType 
) [private]
SYMTAB_EXPORT bool Symtab::updateRegion ( const char *  name,
void *  buffer,
unsigned  size 
)

Definition at line 2827 of file Symtab.C.

References findRegion(), and Dyninst::SymtabAPI::Region::setPtrToRawData().

Referenced by updateCode(), and updateData().

SYMTAB_EXPORT bool Symtab::updateRelocations ( Address  start,
Address  end,
Symbol oldsym,
Symbol newsym 
)

Definition at line 450 of file Symtab-edit.C.

References codeRegions_.

void Symtab::version ( int &  major,
int &  minor,
int &  maintenance 
) [static]

Definition at line 79 of file Symtab.C.

References Symtab_maintenance_version, Symtab_major_version, and Symtab_minor_version.


Friends And Related Function Documentation

friend class Aggregate [friend]

Definition at line 85 of file Symtab.h.

friend class Archive [friend]

Definition at line 75 of file Symtab.h.

friend class emitElf [friend]

Definition at line 81 of file Symtab.h.

friend class emitElf64 [friend]

Definition at line 82 of file Symtab.h.

friend class emitElfStatic [friend]

Definition at line 83 of file Symtab.h.

friend class emitWin [friend]

Definition at line 84 of file Symtab.h.

friend class Function [friend]

Definition at line 77 of file Symtab.h.

Referenced by addSymbolToAggregates().

friend class Module [friend]

Definition at line 79 of file Symtab.h.

Referenced by createDefaultModule(), newModule(), and Symtab().

friend class Region [friend]

Definition at line 80 of file Symtab.h.

Referenced by addRegion(), and Symtab().

friend class relocationEntry [friend]

Definition at line 86 of file Symtab.h.

Referenced by Symtab().

friend class Symbol [friend]

Definition at line 76 of file Symtab.h.

Referenced by addExternalSymbolReference(), createFunction(), and createVariable().

friend class Variable [friend]

Definition at line 78 of file Symtab.h.

Referenced by addSymbolToAggregates().


Field Documentation

std::vector<Module *> Dyninst::SymtabAPI::Symtab::_mods [private]

Definition at line 616 of file Symtab.h.

Referenced by closeSymtab().

Definition at line 463 of file Symtab.h.

Referenced by extractInfo(), and getAddressWidth().

std::vector< Symtab * > Symtab::allSymtabs [static, private]

Definition at line 477 of file Symtab.h.

Referenced by closeSymtab(), findOpenSymtab(), openFile(), and ~Symtab().

Definition at line 468 of file Symtab.h.

Referenced by extractInfo(), getBaseOffset(), and Symtab().

Definition at line 464 of file Symtab.h.

Referenced by extractInfo(), and Symtab().

Definition at line 465 of file Symtab.h.

Referenced by extractInfo(), and Symtab().

Definition at line 456 of file Symtab.h.

Referenced by dataLength(), extractInfo(), fixup_code_and_data(), and Symtab().

Definition at line 455 of file Symtab.h.

Referenced by dataOffset(), extractInfo(), fixup_code_and_data(), and Symtab().

Definition at line 484 of file Symtab.h.

Referenced by addRegion(), extractInfo(), fixup_RegionAddr(), getDataRegions(), isData(), and ~Symtab().

Definition at line 478 of file Symtab.h.

Referenced by getDefaultNamespacePrefix(), and Symtab().

std::vector<std::string> Dyninst::SymtabAPI::Symtab::deps_ [private]

Definition at line 569 of file Symtab.h.

Referenced by extractInfo(), getDependencies(), Symtab(), and ~Symtab().

std::map<std::string, std::string> Dyninst::SymtabAPI::Symtab::dynLibSubs [private]

Definition at line 609 of file Symtab.h.

Referenced by addDynLibSubstitution(), and getDynLibSubstitution().

Definition at line 467 of file Symtab.h.

Referenced by extractInfo(), getEntryOffset(), and Symtab().

Definition at line 567 of file Symtab.h.

Referenced by extractInfo(), findCatchBlock(), findException(), getAllExceptions(), Symtab(), and ~Symtab().

Definition at line 576 of file Symtab.h.

Referenced by addExternalSymbolReference(), and getExplicitSymtabRefs().

unsigned long Dyninst::SymtabAPI::Symtab::fdptr_ [private]

Definition at line 584 of file Symtab.h.

Referenced by extractInfo().

Definition at line 592 of file Symtab.h.

Referenced by extractInfo(), hasRel(), and Symtab().

Definition at line 593 of file Symtab.h.

Referenced by extractInfo(), hasRela(), and Symtab().

Definition at line 595 of file Symtab.h.

Referenced by extractInfo(), hasReladyn(), and Symtab().

Definition at line 597 of file Symtab.h.

Referenced by extractInfo(), hasRelaplt(), and Symtab().

Definition at line 594 of file Symtab.h.

Referenced by extractInfo(), hasReldyn(), and Symtab().

Definition at line 596 of file Symtab.h.

Referenced by extractInfo(), hasRelplt(), and Symtab().

Definition at line 454 of file Symtab.h.

Referenced by extractInfo(), fixup_code_and_data(), imageLength(), and Symtab().

Definition at line 453 of file Symtab.h.

Referenced by createDefaultModule(), extractInfo(), fixup_code_and_data(), imageOffset(), and Symtab().

Definition at line 466 of file Symtab.h.

Referenced by extractInfo(), and getInterpreterName().

Definition at line 458 of file Symtab.h.

Referenced by extractInfo(), isExec(), and Symtab().

Definition at line 471 of file Symtab.h.

Referenced by extractInfo(), and Symtab().

Definition at line 600 of file Symtab.h.

Referenced by extractInfo(), isDefensiveBinary(), and Symtab().

Definition at line 599 of file Symtab.h.

Referenced by extractInfo(), isStaticBinary(), and Symtab().

Definition at line 581 of file Symtab.h.

Referenced by parseTypes(), parseTypesNow(), and Symtab().

Definition at line 585 of file Symtab.h.

Referenced by extractInfo().

Definition at line 572 of file Symtab.h.

Referenced by addLinkingResource(), and getLinkingResources().

Definition at line 469 of file Symtab.h.

Referenced by extractInfo(), getLoadOffset(), and Symtab().

Definition at line 459 of file Symtab.h.

Referenced by Symtab().

Definition at line 447 of file Symtab.h.

Referenced by memberName(), Dyninst::SymtabAPI::Archive::parseMember(), and Symtab().

Definition at line 448 of file Symtab.h.

Referenced by Dyninst::SymtabAPI::Archive::parseMember(), and Symtab().

Definition at line 450 of file Symtab.h.

Referenced by isCode(), isData(), Symtab(), and ~Symtab().

Definition at line 451 of file Symtab.h.

dyn_hash_map<std::string, Module *> Dyninst::SymtabAPI::Symtab::modsByFileName [private]
dyn_hash_map<std::string, Module *> Dyninst::SymtabAPI::Symtab::modsByFullName [private]

Definition at line 461 of file Symtab.h.

Referenced by demangleSymbol(), extractInfo(), isNativeCompiler(), and Symtab().

Definition at line 488 of file Symtab.h.

Referenced by addRegion(), extractInfo(), and getFreeOffset().

Definition at line 583 of file Symtab.h.

Referenced by extractInfo().

Definition at line 481 of file Symtab.h.

Referenced by extractInfo(), getNumberofRegions(), and Symtab().

Definition at line 491 of file Symtab.h.

Referenced by extractInfo(), getNumberofSymbols(), and isStripped().

Definition at line 587 of file Symtab.h.

Referenced by extractInfo().

Definition at line 606 of file Symtab.h.

Referenced by getObject(), getSegmentsSymReader(), getTOCoffset(), setTOCOffset(), Symtab(), and ~Symtab().

Definition at line 470 of file Symtab.h.

Referenced by extractInfo(), getObjectType(), and Symtab().

Definition at line 449 of file Symtab.h.

Referenced by getParentArchive(), and Dyninst::SymtabAPI::Archive::parseMember().

std::vector<Region *> Dyninst::SymtabAPI::Symtab::regions_ [private]

Definition at line 485 of file Symtab.h.

Referenced by extractInfo(), findRegionByEntry(), fixup_RegionAddr(), Symtab(), and ~Symtab().

Definition at line 472 of file Symtab.h.

Referenced by extractInfo().

Definition at line 588 of file Symtab.h.

Referenced by extractInfo().

Definition at line 586 of file Symtab.h.

Referenced by extractInfo().

Definition at line 589 of file Symtab.h.

Referenced by extractInfo().

dyn_hash_map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::symsByMangledName [private]
dyn_hash_map<Offset, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::symsByOffset [private]
dyn_hash_map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::symsByPrettyName [private]
dyn_hash_map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::symsByTypedName [private]
std::map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::undefDynSymsByMangledName [private]

Definition at line 500 of file Symtab.h.

Referenced by addSymbolToIndices(), deleteSymbolFromIndices(), findSymbol(), and ~Symtab().

std::map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::undefDynSymsByPrettyName [private]

Definition at line 501 of file Symtab.h.

Referenced by addSymbolToIndices(), deleteSymbolFromIndices(), findSymbol(), and ~Symtab().

std::map<std::string, std::vector<Symbol *> > Dyninst::SymtabAPI::Symtab::undefDynSymsByTypedName [private]

Definition at line 502 of file Symtab.h.

Referenced by addSymbolToIndices(), deleteSymbolFromIndices(), findSymbol(), and ~Symtab().


The documentation for this class was generated from the following files:
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 12 Jul 2013 for SymtabAPI by  doxygen 1.6.1