File tree Expand file tree Collapse file tree 3 files changed +9
-8
lines changed
source/Plugins/DynamicLoader/MacOSX-DYLD Expand file tree Collapse file tree 3 files changed +9
-8
lines changed Original file line number Diff line number Diff line change 99#ifndef LLDB_TARGET_DYNAMICLOADER_H
1010#define LLDB_TARGET_DYNAMICLOADER_H
1111
12+ #include " lldb/Core/Address.h"
1213#include " lldb/Core/PluginInterface.h"
13- #include " lldb/Symbol/Symbol.h"
1414#include " lldb/Utility/FileSpec.h"
1515#include " lldb/Utility/Status.h"
1616#include " lldb/Utility/UUID.h"
@@ -25,6 +25,7 @@ namespace lldb_private {
2525class ModuleList ;
2626class Process ;
2727class SectionList ;
28+ class Symbol ;
2829class SymbolContext ;
2930class SymbolContextList ;
3031class Thread ;
@@ -329,10 +330,10 @@ class DynamicLoader : public PluginInterface {
329330 // / safe to call certain APIs or SPIs.
330331 virtual bool IsFullyInitialized () { return true ; }
331332
332- // / Return the `start` function \b symbol in the dynamic loader module.
333- // / This is the symbol the process will begin executing with
333+ // / Return the `start` \b address in the dynamic loader module.
334+ // / This is the address the process will begin executing with
334335 // / `process launch --stop-at-entry`.
335- virtual std::optional<lldb_private::Symbol> GetStartSymbol () {
336+ virtual std::optional<lldb_private::Address> GetStartAddress () {
336337 return std::nullopt ;
337338 }
338339
Original file line number Diff line number Diff line change @@ -609,7 +609,7 @@ void DynamicLoaderDarwin::UpdateDYLDImageInfoFromNewImageInfo(
609609 }
610610}
611611
612- std::optional<lldb_private::Symbol > DynamicLoaderDarwin::GetStartSymbol () {
612+ std::optional<lldb_private::Address > DynamicLoaderDarwin::GetStartAddress () {
613613 Log *log = GetLog (LLDBLog::DynamicLoader);
614614
615615 auto log_err = [log](llvm::StringLiteral err_msg) -> std::nullopt_t {
@@ -626,7 +626,7 @@ std::optional<lldb_private::Symbol> DynamicLoaderDarwin::GetStartSymbol() {
626626 if (!symbol)
627627 return log_err (" Cannot find `start` symbol in DYLD module." );
628628
629- return * symbol;
629+ return symbol-> GetAddress () ;
630630}
631631
632632void DynamicLoaderDarwin::SetDYLDModule (lldb::ModuleSP &dyld_module_sp) {
Original file line number Diff line number Diff line change @@ -56,6 +56,8 @@ class DynamicLoaderDarwin : public lldb_private::DynamicLoader {
5656
5757 virtual bool NeedToDoInitialImageFetch () = 0;
5858
59+ std::optional<lldb_private::Address> GetStartAddress () override ;
60+
5961protected:
6062 void PrivateInitialize (lldb_private::Process *process);
6163
@@ -67,8 +69,6 @@ class DynamicLoaderDarwin : public lldb_private::DynamicLoader {
6769 // Clear method for classes derived from this one
6870 virtual void DoClear () = 0;
6971
70- std::optional<lldb_private::Symbol> GetStartSymbol () override ;
71-
7272 void SetDYLDModule (lldb::ModuleSP &dyld_module_sp);
7373
7474 lldb::ModuleSP GetDYLDModule ();
You can’t perform that action at this time.
0 commit comments