LLDB mainline
|
Public Member Functions | |
DebugMapModule (const ModuleSP &exe_module_sp, uint32_t cu_idx, const FileSpec &file_spec, const ArchSpec &arch, ConstString object_name, off_t object_offset, const llvm::sys::TimePoint<> object_mod_time) | |
~DebugMapModule () override=default | |
SymbolFile * | GetSymbolFile (bool can_create=true, lldb_private::Stream *feedback_strm=nullptr) override |
Get the module's symbol file. | |
Public Member Functions inherited from lldb_private::Module | |
Module (const FileSpec &file_spec, const ArchSpec &arch, ConstString object_name=ConstString(), lldb::offset_t object_offset=0, const llvm::sys::TimePoint<> &object_mod_time=llvm::sys::TimePoint<>()) | |
Construct with file specification and architecture. | |
Module (const ModuleSpec &module_spec) | |
~Module () override | |
Destructor. | |
bool | MatchesModuleSpec (const ModuleSpec &module_ref) |
bool | SetLoadAddress (Target &target, lldb::addr_t value, bool value_is_offset, bool &changed) |
Set the load address for all sections in a module to be the file address plus slide. | |
void | CalculateSymbolContext (SymbolContext *sc) override |
Reconstruct the object's symbol context into sc. | |
lldb::ModuleSP | CalculateSymbolContextModule () override |
void | GetDescription (llvm::raw_ostream &s, lldb::DescriptionLevel level=lldb::eDescriptionLevelFull) |
std::string | GetSpecificationDescription () const |
Get the module path and object name. | |
void | Dump (Stream *s) |
Dump a description of this object to a Stream. | |
void | DumpSymbolContext (Stream *s) override |
Dump the object's symbol context to the stream s. | |
const Symbol * | FindFirstSymbolWithNameAndType (ConstString name, lldb::SymbolType symbol_type=lldb::eSymbolTypeAny) |
Find a symbol in the object file's symbol table. | |
void | FindSymbolsWithNameAndType (ConstString name, lldb::SymbolType symbol_type, SymbolContextList &sc_list) |
void | FindSymbolsMatchingRegExAndType (const RegularExpression ®ex, lldb::SymbolType symbol_type, SymbolContextList &sc_list, Mangled::NamePreference mangling_preference=Mangled::ePreferDemangled) |
void | FindFunctionSymbols (ConstString name, uint32_t name_type_mask, SymbolContextList &sc_list) |
Find a function symbols in the object file's symbol table. | |
void | FindCompileUnits (const FileSpec &path, SymbolContextList &sc_list) |
Find compile units by partial or full path. | |
void | FindFunctions (const LookupInfo &lookup_info, const CompilerDeclContext &parent_decl_ctx, const ModuleFunctionSearchOptions &options, SymbolContextList &sc_list) |
Find functions by lookup info. | |
void | FindFunctions (ConstString name, const CompilerDeclContext &parent_decl_ctx, lldb::FunctionNameType name_type_mask, const ModuleFunctionSearchOptions &options, SymbolContextList &sc_list) |
Find functions by name. | |
void | FindFunctions (llvm::ArrayRef< CompilerContext > compiler_ctx, lldb::FunctionNameType name_type_mask, const ModuleFunctionSearchOptions &options, SymbolContextList &sc_list) |
Find functions by compiler context. | |
void | FindFunctions (const RegularExpression ®ex, const ModuleFunctionSearchOptions &options, SymbolContextList &sc_list) |
Find functions by name. | |
void | FindAddressesForLine (const lldb::TargetSP target_sp, const FileSpec &file, uint32_t line, Function *function, std::vector< Address > &output_local, std::vector< Address > &output_extern) |
Find addresses by file/line. | |
void | FindGlobalVariables (ConstString name, const CompilerDeclContext &parent_decl_ctx, size_t max_matches, VariableList &variable_list) |
Find global and static variables by name. | |
void | FindGlobalVariables (const RegularExpression ®ex, size_t max_matches, VariableList &variable_list) |
Find global and static variables by regular expression. | |
void | FindTypes (const TypeQuery &query, TypeResults &results) |
Find types using a type-matching object that contains all search parameters. | |
const ArchSpec & | GetArchitecture () const |
Get const accessor for the module architecture. | |
const FileSpec & | GetFileSpec () const |
Get const accessor for the module file specification. | |
const FileSpec & | GetPlatformFileSpec () const |
Get accessor for the module platform file specification. | |
void | SetPlatformFileSpec (const FileSpec &file) |
const FileSpec & | GetRemoteInstallFileSpec () const |
void | SetRemoteInstallFileSpec (const FileSpec &file) |
const FileSpec & | GetSymbolFileFileSpec () const |
void | PreloadSymbols () |
void | SetSymbolFileFileSpec (const FileSpec &file) |
const llvm::sys::TimePoint & | GetModificationTime () const |
const llvm::sys::TimePoint & | GetObjectModificationTime () const |
void | RegisterXcodeSDK (llvm::StringRef sdk, llvm::StringRef sysroot) |
This callback will be called by SymbolFile implementations when parsing a compile unit that contains SDK information. | |
bool | IsExecutable () |
Tells whether this module is capable of being the main executable for a process. | |
bool | IsLoadedInTarget (Target *target) |
Tells whether this module has been loaded in the target passed in. | |
bool | LoadScriptingResourceInTarget (Target *target, Status &error, Stream &feedback_stream) |
size_t | GetNumCompileUnits () |
Get the number of compile units for this module. | |
lldb::CompUnitSP | GetCompileUnitAtIndex (size_t idx) |
ConstString | GetObjectName () const |
uint64_t | GetObjectOffset () const |
virtual ObjectFile * | GetObjectFile () |
Get the object file representation for the current architecture. | |
virtual SectionList * | GetSectionList () |
Get the unified section list for the module. | |
virtual void | SectionFileAddressesChanged () |
Notify the module that the file addresses for the Sections have been updated. | |
UnwindTable & | GetUnwindTable () |
Returns a reference to the UnwindTable for this Module. | |
llvm::VersionTuple | GetVersion () |
ObjectFile * | GetMemoryObjectFile (const lldb::ProcessSP &process_sp, lldb::addr_t header_addr, Status &error, size_t size_to_read=512) |
Load an object file from memory. | |
Symtab * | GetSymtab (bool can_create=true) |
Get the module's symbol table. | |
const lldb_private::UUID & | GetUUID () |
Get a reference to the UUID value contained in this object. | |
void | ParseAllDebugSymbols () |
A debugging function that will cause everything in a module to be parsed. | |
bool | ResolveFileAddress (lldb::addr_t vm_addr, Address &so_addr) |
uint32_t | ResolveSymbolContextForAddress (const Address &so_addr, lldb::SymbolContextItem resolve_scope, SymbolContext &sc, bool resolve_tail_call_address=false) |
Resolve the symbol context for the given address. | |
uint32_t | ResolveSymbolContextForFilePath (const char *file_path, uint32_t line, bool check_inlines, lldb::SymbolContextItem resolve_scope, SymbolContextList &sc_list) |
Resolve items in the symbol context for a given file and line. | |
uint32_t | ResolveSymbolContextsForFileSpec (const FileSpec &file_spec, uint32_t line, bool check_inlines, lldb::SymbolContextItem resolve_scope, SymbolContextList &sc_list) |
Resolve items in the symbol context for a given file and line. | |
void | SetFileSpecAndObjectName (const FileSpec &file, ConstString object_name) |
bool | GetIsDynamicLinkEditor () |
llvm::Expected< lldb::TypeSystemSP > | GetTypeSystemForLanguage (lldb::LanguageType language) |
void | ForEachTypeSystem (llvm::function_ref< bool(lldb::TypeSystemSP)> callback) |
Call callback for each TypeSystem in this Module . | |
template<typename... Args> | |
void | LogMessage (Log *log, const char *format, Args &&...args) |
template<typename... Args> | |
void | LogMessageVerboseBacktrace (Log *log, const char *format, Args &&...args) |
template<typename... Args> | |
void | ReportWarning (const char *format, Args &&...args) |
template<typename... Args> | |
void | ReportError (const char *format, Args &&...args) |
template<typename... Args> | |
void | ReportErrorIfModifyDetected (const char *format, Args &&...args) |
void | ReportWarningOptimization (std::optional< lldb::user_id_t > debugger_id) |
void | ReportWarningUnsupportedLanguage (lldb::LanguageType language, std::optional< lldb::user_id_t > debugger_id) |
bool | FileHasChanged () const |
std::recursive_mutex & | GetMutex () const |
PathMappingList & | GetSourceMappingList () |
const PathMappingList & | GetSourceMappingList () const |
bool | FindSourceFile (const FileSpec &orig_spec, FileSpec &new_spec) const |
Finds a source file given a file spec using the module source path remappings (if any). | |
std::optional< std::string > | RemapSourceFile (llvm::StringRef path) const |
Remaps a source file given path into new_path. | |
bool | RemapSourceFile (const char *, std::string &) const =delete |
bool | MergeArchitecture (const ArchSpec &arch_spec) |
Update the ArchSpec to a more specific variant. | |
StatsDuration & | GetSymtabParseTime () |
Accessor for the symbol table parse time metric. | |
StatsDuration & | GetSymtabIndexTime () |
Accessor for the symbol table index time metric. | |
StatisticsMap & | GetSymbolLocatorStatistics () |
void | ResetStatistics () |
uint32_t | Hash () |
Get a unique hash for this module. | |
std::string | GetCacheKey () |
Get a unique cache key for the current module. | |
Public Member Functions inherited from lldb_private::SymbolContextScope | |
virtual | ~SymbolContextScope ()=default |
virtual CompileUnit * | CalculateSymbolContextCompileUnit () |
virtual Function * | CalculateSymbolContextFunction () |
virtual Block * | CalculateSymbolContextBlock () |
virtual Symbol * | CalculateSymbolContextSymbol () |
Public Member Functions inherited from lldb_private::UserID | |
UserID (lldb::user_id_t uid=LLDB_INVALID_UID) | |
Construct with optional user ID. | |
~UserID ()=default | |
Destructor. | |
void | Clear () |
Clears the object state. | |
lldb::user_id_t | GetID () const |
Get accessor for the user ID. | |
void | SetID (lldb::user_id_t uid) |
Set accessor for the user ID. |
Protected Attributes | |
ModuleWP | m_exe_module_wp |
const uint32_t | m_cu_idx |
Protected Attributes inherited from lldb_private::Module | |
std::recursive_mutex | m_mutex |
A mutex to keep this object happy in multi-threaded environments. | |
llvm::sys::TimePoint | m_mod_time |
The modification time for this module when it was created. | |
ArchSpec | m_arch |
The architecture for this module. | |
UUID | m_uuid |
Each module is assumed to have a unique identifier to help match it up to debug symbols. | |
FileSpec | m_file |
The file representation on disk for this module (if there is one). | |
FileSpec | m_platform_file |
The path to the module on the platform on which it is being debugged. | |
FileSpec | m_remote_install_file |
If set when debugging on remote platforms, this module will be installed at this location. | |
FileSpec | m_symfile_spec |
If this path is valid, then this is the file that will be used as the symbol file for this module. | |
ConstString | m_object_name |
The name an object within this module that is selected, or empty of the module is represented by m_file. | |
uint64_t | m_object_offset = 0 |
llvm::sys::TimePoint | m_object_mod_time |
lldb::DataBufferSP | m_data_sp |
DataBuffer containing the module image, if it was provided at construction time. | |
lldb::ObjectFileSP | m_objfile_sp |
A shared pointer to the object file parser for this module as it may or may not be shared with the SymbolFile. | |
UnwindTable | m_unwind_table |
Table of FuncUnwinders objects created for this Module's functions. | |
lldb::SymbolVendorUP | m_symfile_up |
A pointer to the symbol vendor for this module. | |
std::vector< lldb::SymbolVendorUP > | m_old_symfiles |
If anyone calls Module::SetSymbolFileFileSpec() and changes the symbol file,. | |
TypeSystemMap | m_type_system_map |
A map of any type systems associated with this module. | |
PathMappingList | m_source_mappings |
Module specific source remappings for when you have debug info for a module that doesn't match where the sources currently are. | |
lldb::SectionListUP | m_sections_up |
Unified section list for module that is used by the ObjectFile and ObjectFile instances for the debug info. | |
std::atomic< bool > | m_did_load_objfile {false} |
std::atomic< bool > | m_did_load_symfile {false} |
std::atomic< bool > | m_did_set_uuid {false} |
bool | m_file_has_changed: 1 |
bool | m_first_file_changed_log: 1 |
StatsDuration | m_symtab_parse_time |
See if the module was modified after it was initially opened. | |
StatsDuration | m_symtab_index_time |
We store a symbol named index time duration here because we might have an object file and a symbol file which both have symbol tables. | |
StatisticsMap | m_symbol_locator_duration_map |
llvm::DenseMap< llvm::stable_hash, std::unique_ptr< std::once_flag > > | m_shown_diagnostics |
A set of hashes of all warnings and errors, to avoid reporting them multiple times to the same Debugger. | |
std::recursive_mutex | m_diagnostic_mutex |
Protected Attributes inherited from lldb_private::UserID | |
lldb::user_id_t | m_uid |
The user ID that uniquely identifies an object. |
Additional Inherited Members | |
Static Public Member Functions inherited from lldb_private::Module | |
static size_t | GetNumberAllocatedModules () |
static Module * | GetAllocatedModuleAtIndex (size_t idx) |
static std::recursive_mutex & | GetAllocationModuleCollectionMutex () |
template<typename ObjFilePlugin, typename... Args> | |
static lldb::ModuleSP | CreateModuleFromObjectFile (Args &&...args) |
static DataFileCache * | GetIndexCache () |
Get the global index file cache. | |
Protected Member Functions inherited from lldb_private::Module | |
void | SymbolIndicesToSymbolContextList (Symtab *symtab, std::vector< uint32_t > &symbol_indexes, SymbolContextList &sc_list) |
bool | SetArchitecture (const ArchSpec &new_arch) |
void | SetUUID (const lldb_private::UUID &uuid) |
SectionList * | GetUnifiedSectionList () |
Definition at line 176 of file SymbolFileDWARFDebugMap.cpp.
|
inline |
Definition at line 178 of file SymbolFileDWARFDebugMap.cpp.
References m_cu_idx, m_exe_module_wp, and lldb_private::Module::Module().
|
overridedefault |
References lldb_private::Module::SymbolFile.
|
inlineoverridevirtual |
Get the module's symbol file.
If the symbol file has already been loaded, this function returns it. All arguments are ignored. If the symbol file has not been located yet, and the can_create argument is false, the function returns nullptr. If can_create is true, this function will find the best SymbolFile plug-in that can use the current object file. feedback_strm, if not null, is used to report the details of the search process.
Reimplemented from lldb_private::Module.
Definition at line 188 of file SymbolFileDWARFDebugMap.cpp.
References lldb_private::Module::GetObjectFile(), lldb_private::Module::GetSymbolFile(), lldb_private::plugin::dwarf::SymbolFileDWARFDebugMap::GetSymbolFileAsSymbolFileDWARF(), m_cu_idx, m_exe_module_wp, lldb_private::Module::m_mutex, lldb_private::Module::m_symfile_up, lldb_private::Module::ObjectFile, lldb_private::plugin::dwarf::SymbolFileDWARF::SetDebugMapModule(), lldb_private::plugin::dwarf::SymbolFileDWARF::SetFileIndex(), and lldb_private::Module::SymbolFile.
|
protected |
Definition at line 230 of file SymbolFileDWARFDebugMap.cpp.
Referenced by DebugMapModule(), and GetSymbolFile().
|
protected |
Definition at line 229 of file SymbolFileDWARFDebugMap.cpp.
Referenced by DebugMapModule(), and GetSymbolFile().