LLDB mainline
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
lldb_private::DynamicLoader Class Referenceabstract

A plug-in interface definition class for dynamic loaders. More...

#include "lldb/Target/DynamicLoader.h"

Inheritance diagram for lldb_private::DynamicLoader:
Inheritance graph
[legend]

Public Member Functions

 DynamicLoader (Process *process)
 Construct with a process.
 
virtual void DidAttach ()=0
 Called after attaching a process.
 
virtual void DidLaunch ()=0
 Called after launching a process.
 
virtual bool ProcessDidExec ()
 Helper function that can be used to detect when a process has called exec and is now a new and different process.
 
bool GetStopWhenImagesChange () const
 Get whether the process should stop when images change.
 
void SetStopWhenImagesChange (bool stop)
 Set whether the process should stop when images change.
 
virtual lldb::ThreadPlanSP GetStepThroughTrampolinePlan (Thread &thread, bool stop_others)=0
 Provides a plan to step through the dynamic loader trampoline for the current state of thread.
 
virtual void FindEquivalentSymbols (Symbol *original_symbol, ModuleList &module_list, SymbolContextList &equivalent_symbols)
 Some dynamic loaders provide features where there are a group of symbols "equivalent to" a given symbol one of which will be chosen when the symbol is bound.
 
virtual Status CanLoadImage ()=0
 Ask if it is ok to try and load or unload an shared library (image).
 
virtual bool AlwaysRelyOnEHUnwindInfo (SymbolContext &sym_ctx)
 Ask if the eh_frame information for the given SymbolContext should be relied on even when it's the first frame in a stack unwind.
 
virtual lldb::addr_t GetThreadLocalData (const lldb::ModuleSP module, const lldb::ThreadSP thread, lldb::addr_t tls_file_addr)
 Retrieves the per-module TLS block for a given thread.
 
virtual lldb::ModuleSP LoadModuleAtAddress (const lldb_private::FileSpec &file, lldb::addr_t link_map_addr, lldb::addr_t base_addr, bool base_addr_is_offset)
 Locates or creates a module given by file and updates/loads the resulting module at the virtual base address base_addr.
 
virtual bool GetSharedCacheInformation (lldb::addr_t &base_address, UUID &uuid, LazyBool &using_shared_cache, LazyBool &private_shared_cache)
 Get information about the shared cache for a process, if possible.
 
virtual bool IsFullyInitialized ()
 Return whether the dynamic loader is fully initialized and it's safe to call its APIs.
 
virtual std::optional< lldb_private::AddressGetStartAddress ()
 Return the start address in the dynamic loader module.
 
virtual void CalculateDynamicSaveCoreRanges (lldb_private::Process &process, std::vector< lldb_private::MemoryRegionInfo > &ranges, llvm::function_ref< bool(const lldb_private::Thread &)> save_thread_predicate)
 Returns a list of memory ranges that should be saved in the core file, specific for this dynamic loader.
 
- Public Member Functions inherited from lldb_private::PluginInterface
 PluginInterface ()=default
 
virtual ~PluginInterface ()=default
 
virtual llvm::StringRef GetPluginName ()=0
 
 PluginInterface (const PluginInterface &)=delete
 
PluginInterfaceoperator= (const PluginInterface &)=delete
 

Static Public Member Functions

static DynamicLoaderFindPlugin (Process *process, llvm::StringRef plugin_name)
 Find a dynamic loader plugin for a given process.
 
static lldb::ModuleSP LoadBinaryWithUUIDAndAddress (Process *process, llvm::StringRef name, UUID uuid, lldb::addr_t value, bool value_is_offset, bool force_symbol_search, bool notify, bool set_address_in_target, bool allow_memory_image_last_resort)
 Find/load a binary into lldb given a UUID and the address where it is loaded in memory, or a slide to be applied to the file address.
 

Protected Member Functions

lldb::ModuleSP FindModuleViaTarget (const FileSpec &file)
 
lldb::ModuleSP GetTargetExecutable ()
 Checks to see if the target module has changed, updates the target accordingly and returns the target executable module.
 
virtual void UpdateLoadedSections (lldb::ModuleSP module, lldb::addr_t link_map_addr, lldb::addr_t base_addr, bool base_addr_is_offset)
 Updates the load address of every allocatable section in module.
 
void UpdateLoadedSectionsCommon (lldb::ModuleSP module, lldb::addr_t base_addr, bool base_addr_is_offset)
 
virtual void UnloadSections (const lldb::ModuleSP module)
 Removes the loaded sections from the target in module.
 
void UnloadSectionsCommon (const lldb::ModuleSP module)
 
const lldb_private::SectionListGetSectionListFromModule (const lldb::ModuleSP module) const
 
int64_t ReadUnsignedIntWithSizeInBytes (lldb::addr_t addr, int size_in_bytes)
 
lldb::addr_t ReadPointer (lldb::addr_t addr)
 
void LoadOperatingSystemPlugin (bool flush)
 

Protected Attributes

Processm_process
 The process that this dynamic loader plug-in is tracking.
 

Detailed Description

A plug-in interface definition class for dynamic loaders.

Dynamic loader plug-ins track image (shared library) loading and unloading. The class is initialized given a live process that is halted at its entry point or just after attaching.

Dynamic loader plug-ins can track the process by registering callbacks using the: Process::RegisterNotificationCallbacks (const Notifications&) function.

Breakpoints can also be set in the process which can register functions that get called using: Process::BreakpointSetCallback (lldb::user_id_t, BreakpointHitCallback, void *). These breakpoint callbacks return a boolean value that indicates if the process should continue or halt and should return the global setting for this using: DynamicLoader::StopWhenImagesChange() const.

Definition at line 54 of file DynamicLoader.h.

Constructor & Destructor Documentation

◆ DynamicLoader()

DynamicLoader::DynamicLoader ( Process process)

Construct with a process.

Definition at line 64 of file DynamicLoader.cpp.

Member Function Documentation

◆ AlwaysRelyOnEHUnwindInfo()

virtual bool lldb_private::DynamicLoader::AlwaysRelyOnEHUnwindInfo ( SymbolContext sym_ctx)
inlinevirtual

Ask if the eh_frame information for the given SymbolContext should be relied on even when it's the first frame in a stack unwind.

The CFI instructions from the eh_frame section are normally only valid at call sites – places where a program could throw an exception and need to unwind out. But some Modules may be known to the system as having reliable eh_frame information at all call sites. This would be the case if the Module's contents are largely hand-written assembly with hand-written eh_frame information. Normally when unwinding from a function at the beginning of a stack unwind lldb will examine the assembly instructions to understand how the stack frame is set up and where saved registers are stored. But with hand-written assembly this is not reliable enough – we need to consult those function's hand-written eh_frame information.

Returns
True if the symbol context should use eh_frame instructions unconditionally when unwinding from this frame. Else false, the normal lldb unwind behavior of only using eh_frame when the function appears in the middle of the stack.

Reimplemented in lldb_private::DynamicLoaderDarwin, and DynamicLoaderPOSIXDYLD.

Definition at line 184 of file DynamicLoader.h.

Referenced by lldb_private::RegisterContextUnwind::GetFullUnwindPlanForFrame().

◆ CalculateDynamicSaveCoreRanges()

virtual void lldb_private::DynamicLoader::CalculateDynamicSaveCoreRanges ( lldb_private::Process process,
std::vector< lldb_private::MemoryRegionInfo > &  ranges,
llvm::function_ref< bool(const lldb_private::Thread &)>  save_thread_predicate 
)
inlinevirtual

Returns a list of memory ranges that should be saved in the core file, specific for this dynamic loader.

For example, an implementation of this function can save the thread local data of a given thread.

Definition at line 346 of file DynamicLoader.h.

Referenced by SaveDynamicLoaderSections().

◆ CanLoadImage()

virtual Status lldb_private::DynamicLoader::CanLoadImage ( )
pure virtual

Ask if it is ok to try and load or unload an shared library (image).

The dynamic loader often knows when it would be ok to try and load or unload a shared library. This function call allows the dynamic loader plug-ins to check any current dyld state to make sure it is an ok time to load a shared library.

Returns
true if it is currently ok to try and load a shared library into the process, false otherwise.

Implemented in DynamicLoaderDarwinKernel, DynamicLoaderFreeBSDKernel, DynamicLoaderHexagonDYLD, DynamicLoaderMacOS, DynamicLoaderMacOSXDYLD, DynamicLoaderPOSIXDYLD, DynamicLoaderStatic, lldb_private::wasm::DynamicLoaderWasmDYLD, and lldb_private::DynamicLoaderWindowsDYLD.

Referenced by PlatformPOSIX::EvaluateLibdlExpression().

◆ DidAttach()

virtual void lldb_private::DynamicLoader::DidAttach ( )
pure virtual

◆ DidLaunch()

virtual void lldb_private::DynamicLoader::DidLaunch ( )
pure virtual

Called after launching a process.

Allow DynamicLoader plug-ins to execute some code after the process has stopped for the first time on launch.

Implemented in DynamicLoaderDarwinKernel, DynamicLoaderFreeBSDKernel, DynamicLoaderHexagonDYLD, lldb_private::DynamicLoaderDarwin, DynamicLoaderPOSIXDYLD, DynamicLoaderStatic, lldb_private::wasm::DynamicLoaderWasmDYLD, and lldb_private::DynamicLoaderWindowsDYLD.

◆ FindEquivalentSymbols()

virtual void lldb_private::DynamicLoader::FindEquivalentSymbols ( Symbol original_symbol,
ModuleList module_list,
SymbolContextList equivalent_symbols 
)
inlinevirtual

Some dynamic loaders provide features where there are a group of symbols "equivalent to" a given symbol one of which will be chosen when the symbol is bound.

If you want to set a breakpoint on one of these symbols, you really need to set it on all the equivalent symbols.

Parameters
[in]original_symbolThe symbol for which we are finding equivalences.
[in]module_listThe set of modules in which to search.
[out]equivalent_symbolsThe equivalent symbol list - any equivalent symbols found are appended to this list.

Reimplemented in lldb_private::DynamicLoaderDarwin.

Definition at line 148 of file DynamicLoader.h.

◆ FindModuleViaTarget()

ModuleSP DynamicLoader::FindModuleViaTarget ( const FileSpec file)
protected

◆ FindPlugin()

DynamicLoader * DynamicLoader::FindPlugin ( Process process,
llvm::StringRef  plugin_name 
)
static

Find a dynamic loader plugin for a given process.

Scans the installed DynamicLoader plug-ins and tries to find an instance that can be used to track image changes in process.

Parameters
[in]processThe process for which to try and locate a dynamic loader plug-in instance.
[in]plugin_nameAn optional name of a specific dynamic loader plug-in that should be used. If empty, pick the best plug-in.

Definition at line 37 of file DynamicLoader.cpp.

References lldb_private::PluginManager::GetDynamicLoaderCreateCallbackAtIndex(), and lldb_private::PluginManager::GetDynamicLoaderCreateCallbackForPluginName().

Referenced by lldb_private::Process::GetDynamicLoader(), ProcessElfCore::GetDynamicLoader(), ProcessFreeBSDKernel::GetDynamicLoader(), lldb_private::process_gdb_remote::ProcessGDBRemote::GetDynamicLoader(), ProcessMachCore::GetDynamicLoader(), ProcessKDP::GetDynamicLoader(), and lldb_private::ProcessWindows::GetDynamicLoader().

◆ GetSectionListFromModule()

const SectionList * DynamicLoader::GetSectionListFromModule ( const lldb::ModuleSP  module) const
protected

Definition at line 146 of file DynamicLoader.cpp.

References lldb_private::ObjectFile::GetSectionList().

Referenced by UnloadSectionsCommon().

◆ GetSharedCacheInformation()

virtual bool lldb_private::DynamicLoader::GetSharedCacheInformation ( lldb::addr_t base_address,
UUID uuid,
LazyBool using_shared_cache,
LazyBool private_shared_cache 
)
inlinevirtual

Get information about the shared cache for a process, if possible.

On some systems (e.g. Darwin based systems), a set of libraries that are common to most processes may be put in a single region of memory and mapped into every process, this is called the shared cache, as a performance optimization.

Many targets will not have the concept of a shared cache.

Depending on how the DynamicLoader gathers information about the shared cache, it may be able to only return basic information - like the UUID of the cache - or it may be able to return additional information about the cache.

Parameters
[out]base_addressThe base address (load address) of the shared cache. LLDB_INVALID_ADDRESS if it cannot be determined.
[out]uuidThe UUID of the shared cache, if it can be determined. If the UUID cannot be fetched, IsValid() will be false.
[out]using_shared_cacheIf this process is using a shared cache. If unknown, eLazyBoolCalculate is returned.
[out]private_shared_cacheA LazyBool indicating whether this process is using a private shared cache. If this information cannot be fetched, eLazyBoolCalculate.
Returns
Returns false if this DynamicLoader cannot gather information about the shared cache / has no concept of a shared cache.

Reimplemented in DynamicLoaderMacOS, and DynamicLoaderMacOSXDYLD.

Definition at line 316 of file DynamicLoader.h.

References lldb_private::UUID::Clear(), lldb_private::eLazyBoolCalculate, and LLDB_INVALID_ADDRESS.

Referenced by ObjectFileMachO::GetProcessSharedCacheUUID().

◆ GetStartAddress()

virtual std::optional< lldb_private::Address > lldb_private::DynamicLoader::GetStartAddress ( )
inlinevirtual

Return the start address in the dynamic loader module.

This is the address the process will begin executing with process launch --stop-at-entry.

Reimplemented in lldb_private::DynamicLoaderDarwin.

Definition at line 337 of file DynamicLoader.h.

◆ GetStepThroughTrampolinePlan()

virtual lldb::ThreadPlanSP lldb_private::DynamicLoader::GetStepThroughTrampolinePlan ( Thread thread,
bool  stop_others 
)
pure virtual

Provides a plan to step through the dynamic loader trampoline for the current state of thread.

Parameters
[in]stop_othersWhether the plan should be set to stop other threads.
Returns
A pointer to the plan (caller owned) or NULL if we are not at such a trampoline.

Implemented in DynamicLoaderDarwinKernel, DynamicLoaderFreeBSDKernel, DynamicLoaderHexagonDYLD, lldb_private::DynamicLoaderDarwin, DynamicLoaderPOSIXDYLD, DynamicLoaderStatic, lldb_private::wasm::DynamicLoaderWasmDYLD, and lldb_private::DynamicLoaderWindowsDYLD.

Referenced by lldb_private::ThreadPlanStepThrough::LookForPlanToStepThroughFromCurrentPC().

◆ GetStopWhenImagesChange()

bool DynamicLoader::GetStopWhenImagesChange ( ) const

Get whether the process should stop when images change.

When images (executables and shared libraries) get loaded or unloaded, often debug sessions will want to try and resolve or unresolve breakpoints that are set in these images. Any breakpoints set by DynamicLoader plug-in instances should return this value to ensure consistent debug session behaviour.

Returns
Returns true if the process should stop when images change, false if the process should resume.

Definition at line 69 of file DynamicLoader.cpp.

References lldb_private::ProcessProperties::GetStopOnSharedLibraryEvents(), and m_process.

Referenced by DynamicLoaderDarwinKernel::BreakpointHit(), DynamicLoaderMacOS::NotifyBreakpointHit(), DynamicLoaderMacOSXDYLD::NotifyBreakpointHit(), DynamicLoaderHexagonDYLD::RendezvousBreakpointHit(), and DynamicLoaderPOSIXDYLD::RendezvousBreakpointHit().

◆ GetTargetExecutable()

ModuleSP DynamicLoader::GetTargetExecutable ( )
protected

◆ GetThreadLocalData()

virtual lldb::addr_t lldb_private::DynamicLoader::GetThreadLocalData ( const lldb::ModuleSP  module,
const lldb::ThreadSP  thread,
lldb::addr_t  tls_file_addr 
)
inlinevirtual

Retrieves the per-module TLS block for a given thread.

Parameters
[in]moduleThe module to query TLS data for.
[in]threadThe specific thread to query TLS data for.
Returns
If the given thread has TLS data allocated for the module, the address of the TLS block. Otherwise LLDB_INVALID_ADDRESS is returned.

Reimplemented in DynamicLoaderHexagonDYLD, lldb_private::DynamicLoaderDarwin, and DynamicLoaderPOSIXDYLD.

Definition at line 200 of file DynamicLoader.h.

References LLDB_INVALID_ADDRESS.

Referenced by lldb_private::Thread::GetThreadLocalData().

◆ IsFullyInitialized()

virtual bool lldb_private::DynamicLoader::IsFullyInitialized ( )
inlinevirtual

Return whether the dynamic loader is fully initialized and it's safe to call its APIs.

On some systems (e.g. Darwin based systems), lldb will get notified by the dynamic loader before it itself finished initializing and it's not safe to call certain APIs or SPIs.

Reimplemented in DynamicLoaderMacOS, and DynamicLoaderMacOSXDYLD.

Definition at line 332 of file DynamicLoader.h.

Referenced by lldb_private::Thread::SafeToCallFunctions().

◆ LoadBinaryWithUUIDAndAddress()

ModuleSP DynamicLoader::LoadBinaryWithUUIDAndAddress ( Process process,
llvm::StringRef  name,
UUID  uuid,
lldb::addr_t  value,
bool  value_is_offset,
bool  force_symbol_search,
bool  notify,
bool  set_address_in_target,
bool  allow_memory_image_last_resort 
)
static

Find/load a binary into lldb given a UUID and the address where it is loaded in memory, or a slide to be applied to the file address.

May force an expensive search on the computer to find the binary by UUID, should not be used for a large number of binaries - intended for an environment where there may be one, or a few, binaries resident in memory.

Given a UUID, search for a binary and load it at the address provided, or with the slide applied, or at the file address unslid.

Given an address, try to read the binary out of memory, get the UUID, find the file if possible and load it unslid, or add the memory module.

Parameters
[in]processThe process to add this binary to.
[in]nameName of the binary, if available. If this method cannot find a matching binary on the debug host, it may create a memory module out of live memory, and the provided name will be used. If an empty StringRef is provided, a name will be constructed for the module based on the address it is loaded at.
[in]uuidUUID of the binary to be loaded. UUID may be empty, and if a load address is supplied, will read the binary from memory, get a UUID and try to find a local binary. There is a performance cost to doing this, it is not preferable.
[in]valueAddress where the binary should be loaded, or read out of memory. Or a slide value, to be applied to the file addresses of the binary.
[in]value_is_offsetA flag indicating that value is an address, or an offset to be applied to the file addresses.
[in]force_symbol_searchAllow the search to do a possibly expensive external search for the ObjectFile and/or SymbolFile.
[in]notifyWhether ModulesDidLoad should be called when a binary has been added to the Target. The caller may prefer to batch up these when loading multiple binaries.
[in]set_address_in_targetWhether the address of the binary should be set in the Target if it is added. The caller may want to set the section addresses individually, instead of loading the binary the entire based on the start address or slide. The caller is responsible for setting the load address for the binary or its segments in the Target if it passes true.
[in]allow_memory_image_last_resortIf no better binary image can be found, allow reading the binary out of memory, if possible, and create the Module based on that. May be slow to read a binary out of memory, and for unusual environments, may be no symbols mapped in memory at all.
Returns
Returns a shared pointer for the Module that has been added.

Definition at line 197 of file DynamicLoader.cpp.

References lldb_private::ModuleList::Append(), lldb_private::ModuleList::AppendIfNeeded(), lldb_private::PluginManager::DownloadObjectAndSymbolFile(), lldb_private::DynamicLoader, error(), lldb_private::FileSystem::Exists(), lldb_private::Target::GetArchitecture(), lldb_private::UUID::GetAsString(), lldb_private::Target::GetDebugger(), lldb_private::Target::GetDefaultDebugFileSearchPaths(), lldb_private::Debugger::GetErrorStream(), lldb_private::ModuleSpec::GetFileSpec(), lldb_private::Target::GetImages(), lldb_private::GetLog(), lldb_private::Target::GetPlatform(), lldb_private::ModuleList::GetSharedModule(), lldb_private::StreamString::GetString(), lldb_private::ModuleSpec::GetSymbolFileSpec(), lldb_private::Process::GetTarget(), lldb_private::ModuleSpec::GetUUID(), lldb_private::FileSystem::Instance(), lldb_private::ArchSpec::IsValid(), lldb_private::UUID::IsValid(), LLDB_INVALID_ADDRESS, LLDB_LOGF, lldb_private::PluginManager::LocateExecutableObjectFile(), lldb_private::PluginManager::LocateExecutableSymbolFile(), lldb_private::Target::ModulesDidLoad(), lldb_private::Stream::Printf(), lldb_private::Stream::PutHex64(), ReadUnnamedMemoryModule(), and lldb_private::Target::SetArchitecture().

Referenced by ProcessMachCore::LoadBinariesViaMetadata(), ProcessMachCore::LoadBinaryViaLowmemUUID(), ObjectFileMachO::LoadCoreFileImages(), and lldb_private::process_gdb_remote::ProcessGDBRemote::LoadStubBinaries().

◆ LoadModuleAtAddress()

ModuleSP DynamicLoader::LoadModuleAtAddress ( const lldb_private::FileSpec file,
lldb::addr_t  link_map_addr,
lldb::addr_t  base_addr,
bool  base_addr_is_offset 
)
virtual

Locates or creates a module given by file and updates/loads the resulting module at the virtual base address base_addr.

Note that this calls Target::GetOrCreateModule with notify being false, so it is necessary to call Target::ModulesDidLoad afterwards.

Reimplemented in DynamicLoaderPOSIXDYLD, and lldb_private::wasm::DynamicLoaderWasmDYLD.

Definition at line 174 of file DynamicLoader.cpp.

References FindModuleViaTarget(), and UpdateLoadedSections().

Referenced by DynamicLoaderHexagonDYLD::LoadAllCurrentModules(), lldb_private::process_gdb_remote::ProcessGDBRemote::LoadModuleAtAddress(), DynamicLoaderPOSIXDYLD::LoadModuleAtAddress(), lldb_private::wasm::DynamicLoaderWasmDYLD::LoadModuleAtAddress(), and DynamicLoaderHexagonDYLD::RefreshModules().

◆ LoadOperatingSystemPlugin()

void DynamicLoader::LoadOperatingSystemPlugin ( bool  flush)
protected

◆ ProcessDidExec()

virtual bool lldb_private::DynamicLoader::ProcessDidExec ( )
inlinevirtual

Helper function that can be used to detect when a process has called exec and is now a new and different process.

This can be called when necessary to try and detect the exec. The process might be able to answer this question, but sometimes it might not be able and the dynamic loader often knows what the program entry point is. So the process and the dynamic loader can work together to detect this.

Reimplemented in DynamicLoaderMacOS, and DynamicLoaderMacOSXDYLD.

Definition at line 92 of file DynamicLoader.h.

Referenced by lldb_private::StopInfoMachException::CreateStopReasonWithMachException().

◆ ReadPointer()

addr_t DynamicLoader::ReadPointer ( lldb::addr_t  addr)
protected

◆ ReadUnsignedIntWithSizeInBytes()

int64_t DynamicLoader::ReadUnsignedIntWithSizeInBytes ( lldb::addr_t  addr,
int  size_in_bytes 
)
protected

◆ SetStopWhenImagesChange()

void DynamicLoader::SetStopWhenImagesChange ( bool  stop)

Set whether the process should stop when images change.

When images (executables and shared libraries) get loaded or unloaded, often debug sessions will want to try and resolve or unresolve breakpoints that are set in these images. The default is set so that the process stops when images change, but this can be overridden using this function callback.

Parameters
[in]stopBoolean value that indicates whether the process should stop when images change.

Definition at line 73 of file DynamicLoader.cpp.

References m_process, and lldb_private::ProcessProperties::SetStopOnSharedLibraryEvents().

◆ UnloadSections()

void DynamicLoader::UnloadSections ( const lldb::ModuleSP  module)
protectedvirtual

Removes the loaded sections from the target in module.

Parameters
moduleThe module to traverse.

Reimplemented in DynamicLoaderHexagonDYLD, and DynamicLoaderPOSIXDYLD.

Definition at line 128 of file DynamicLoader.cpp.

References UnloadSectionsCommon().

Referenced by lldb_private::DynamicLoaderDarwin::UnloadAllImages(), and lldb_private::DynamicLoaderDarwin::UnloadImages().

◆ UnloadSectionsCommon()

void DynamicLoader::UnloadSectionsCommon ( const lldb::ModuleSP  module)
protected

◆ UpdateLoadedSections()

void DynamicLoader::UpdateLoadedSections ( lldb::ModuleSP  module,
lldb::addr_t  link_map_addr,
lldb::addr_t  base_addr,
bool  base_addr_is_offset 
)
protectedvirtual

Updates the load address of every allocatable section in module.

Parameters
moduleThe module to traverse.
link_map_addrThe virtual address of the link map for the module.
base_addrThe virtual base address module is loaded at.

Reimplemented in DynamicLoaderHexagonDYLD, and DynamicLoaderPOSIXDYLD.

Definition at line 114 of file DynamicLoader.cpp.

References UpdateLoadedSectionsCommon().

Referenced by lldb_private::DynamicLoaderWindowsDYLD::DidAttach(), lldb_private::DynamicLoaderWindowsDYLD::DidLaunch(), LoadModuleAtAddress(), and lldb_private::wasm::DynamicLoaderWasmDYLD::LoadModuleAtAddress().

◆ UpdateLoadedSectionsCommon()

void DynamicLoader::UpdateLoadedSectionsCommon ( lldb::ModuleSP  module,
lldb::addr_t  base_addr,
bool  base_addr_is_offset 
)
protected

Member Data Documentation

◆ m_process

Process* lldb_private::DynamicLoader::m_process
protected

The process that this dynamic loader plug-in is tracking.

Definition at line 404 of file DynamicLoader.h.

Referenced by DynamicLoaderMacOS::AddBinaries(), DynamicLoaderMacOSXDYLD::AddModulesUsingImageInfosAddress(), lldb_private::DynamicLoaderDarwin::AddModulesUsingPreloadedModules(), lldb_private::DynamicLoaderDarwin::AlwaysRelyOnEHUnwindInfo(), DynamicLoaderMacOS::CanLoadImage(), DynamicLoaderDarwinKernel::Clear(), lldb_private::DynamicLoaderDarwin::Clear(), DynamicLoaderMacOS::ClearDYLDHandoverBreakpoint(), DynamicLoaderMacOS::ClearNotificationBreakpoint(), DynamicLoaderMacOSXDYLD::ClearNotificationBreakpoint(), DynamicLoaderPOSIXDYLD::ComputeLoadOffset(), DynamicLoaderDarwinKernel::DidAttach(), DynamicLoaderHexagonDYLD::DidAttach(), lldb_private::DynamicLoaderDarwin::DidAttach(), DynamicLoaderPOSIXDYLD::DidAttach(), lldb_private::wasm::DynamicLoaderWasmDYLD::DidAttach(), lldb_private::DynamicLoaderWindowsDYLD::DidAttach(), DynamicLoaderDarwinKernel::DidLaunch(), lldb_private::DynamicLoaderDarwin::DidLaunch(), DynamicLoaderPOSIXDYLD::DidLaunch(), lldb_private::DynamicLoaderWindowsDYLD::DidLaunch(), DynamicLoaderMacOS::DoClear(), DynamicLoaderMacOSXDYLD::DoClear(), DynamicLoaderMacOS::DoInitialImageFetch(), DynamicLoaderMacOSXDYLD::DoInitialImageFetch(), DynamicLoaderPOSIXDYLD::EntryBreakpointHit(), FindModuleViaTarget(), lldb_private::DynamicLoaderDarwin::FindTargetModuleForImageInfo(), DynamicLoaderMacOS::GetDyldLockVariableAddressFromModule(), DynamicLoaderHexagonDYLD::GetEntryPoint(), DynamicLoaderPOSIXDYLD::GetEntryPoint(), lldb_private::DynamicLoaderWindowsDYLD::GetLoadAddress(), DynamicLoaderMacOS::GetNotificationFuncAddrFromImageInfos(), lldb_private::DynamicLoaderDarwin::GetPThreadLibraryModule(), DynamicLoaderMacOS::GetSharedCacheInformation(), DynamicLoaderMacOSXDYLD::GetSharedCacheInformation(), lldb_private::DynamicLoaderWindowsDYLD::GetStepThroughTrampolinePlan(), GetStopWhenImagesChange(), GetTargetExecutable(), DynamicLoaderHexagonDYLD::GetTargetExecutable(), DynamicLoaderHexagonDYLD::GetThreadLocalData(), lldb_private::DynamicLoaderDarwin::GetThreadLocalData(), DynamicLoaderMacOSXDYLD::InitializeFromAllImageInfos(), DynamicLoaderPOSIXDYLD::IsCoreFile(), DynamicLoaderMacOS::IsFullyInitialized(), DynamicLoaderHexagonDYLD::LoadAllCurrentModules(), DynamicLoaderPOSIXDYLD::LoadAllCurrentModules(), DynamicLoaderStatic::LoadAllImagesAtFileAddresses(), DynamicLoaderPOSIXDYLD::LoadInterpreterModule(), DynamicLoaderDarwinKernel::LoadKernelModuleIfNeeded(), DynamicLoaderPOSIXDYLD::LoadModuleAtAddress(), lldb_private::wasm::DynamicLoaderWasmDYLD::LoadModuleAtAddress(), LoadOperatingSystemPlugin(), DynamicLoaderPOSIXDYLD::LoadVDSO(), DynamicLoaderMacOS::NotifyBreakpointHit(), DynamicLoaderMacOSXDYLD::NotifyBreakpointHit(), lldb_private::DynamicLoaderWindowsDYLD::OnLoadModule(), lldb_private::DynamicLoaderWindowsDYLD::OnUnloadModule(), DynamicLoaderDarwinKernel::ParseKextSummaries(), DynamicLoaderDarwinKernel::PrivateInitialize(), lldb_private::DynamicLoaderDarwin::PrivateInitialize(), lldb_private::DynamicLoaderDarwin::PrivateProcessStateChanged(), DynamicLoaderPOSIXDYLD::ProbeEntry(), DynamicLoaderMacOS::ProcessDidExec(), DynamicLoaderMacOSXDYLD::ProcessDidExec(), DynamicLoaderMacOSXDYLD::ReadAllImageInfosStructure(), DynamicLoaderMacOSXDYLD::ReadDYLDInfoFromMemoryAndSetNotificationCallback(), DynamicLoaderMacOSXDYLD::ReadImageInfos(), DynamicLoaderDarwinKernel::ReadKextSummaries(), DynamicLoaderDarwinKernel::ReadKextSummaryHeader(), DynamicLoaderMacOSXDYLD::ReadMachHeader(), ReadPointer(), ReadUnsignedIntWithSizeInBytes(), DynamicLoaderHexagonDYLD::RefreshModules(), DynamicLoaderPOSIXDYLD::RefreshModules(), DynamicLoaderMacOSXDYLD::RemoveModulesUsingImageInfosAddress(), DynamicLoaderHexagonDYLD::RendezvousBreakpointHit(), DynamicLoaderPOSIXDYLD::RendezvousBreakpointHit(), DynamicLoaderPOSIXDYLD::ResolveExecutableModule(), DynamicLoaderMacOS::SetDYLDHandoverBreakpoint(), DynamicLoaderMacOS::SetNotificationBreakpoint(), DynamicLoaderMacOSXDYLD::SetNotificationBreakpoint(), DynamicLoaderDarwinKernel::SetNotificationBreakpointIfNeeded(), DynamicLoaderHexagonDYLD::SetRendezvousBreakpoint(), DynamicLoaderPOSIXDYLD::SetRendezvousBreakpoint(), SetStopWhenImagesChange(), lldb_private::DynamicLoaderDarwin::UnloadAllImages(), lldb_private::DynamicLoaderDarwin::UnloadImages(), lldb_private::DynamicLoaderDarwin::UnloadModuleSections(), DynamicLoaderHexagonDYLD::UnloadSections(), UnloadSectionsCommon(), lldb_private::DynamicLoaderDarwin::UpdateDYLDImageInfoFromNewImageInfo(), DynamicLoaderMacOSXDYLD::UpdateImageInfosHeaderAndLoadCommands(), lldb_private::DynamicLoaderDarwin::UpdateImageLoadAddress(), DynamicLoaderHexagonDYLD::UpdateLoadedSections(), UpdateLoadedSectionsCommon(), lldb_private::DynamicLoaderDarwin::UpdateSpecialBinariesFromPreloadedModules(), DynamicLoaderHexagonDYLD::~DynamicLoaderHexagonDYLD(), DynamicLoaderMacOS::~DynamicLoaderMacOS(), DynamicLoaderMacOSXDYLD::~DynamicLoaderMacOSXDYLD(), and DynamicLoaderPOSIXDYLD::~DynamicLoaderPOSIXDYLD().


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