llvm-project/lldb/tools/debugserver/source
Jason Molenda ac49e90219 jGetLoadedDynamicLibrariesInfos can inspect machos not yet loaded
jGetLoadedDynamicLibrariesInfos normally checks with dyld to find
the list of binaries loaded in the inferior, and getting the filepath,
before trying to parse the Mach-O binary in inferior memory.
This allows for debugserver to parse a Mach-O binary present in memory,
but not yet registered with dyld.  This patch also adds some simple
sanity checks that we're reading a Mach-O header before we begin
stepping through load commands, because we won't have the sanity check
of consulting dyld for the list of loaded binaries before parsing.
Also adds a testcase.

[This patch was reverted after causing a testsuite failure on a CI bot;
I haven't been able to repro the failure outside the CI, but I have a
theory that my sanity check on cputype which only matched arm64 and
x86_64 - and the CI machine may have a watch simulator that is still
using i386.]

Differential Revision: https://reviews.llvm.org/D128956
rdar://95737734
2022-07-14 00:56:14 -07:00
..
MacOSX jGetLoadedDynamicLibrariesInfos can inspect machos not yet loaded 2022-07-14 00:56:14 -07:00
ARM_DWARF_Registers.h
ARM_ehframe_Registers.h
CMakeLists.txt [debugserver ] Un-conditionalize use of libcompression 2022-04-13 14:36:25 -07:00
ChangeLog
DNB.cpp Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
DNB.h Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
DNBArch.cpp
DNBArch.h
DNBBreakpoint.cpp [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB 2022-03-31 13:21:49 -07:00
DNBBreakpoint.h
DNBDataRef.cpp [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB 2022-03-31 13:21:49 -07:00
DNBDataRef.h
DNBDefs.h Fix debugserver translation check 2022-05-05 11:31:23 -07:00
DNBError.cpp
DNBError.h
DNBLog.cpp
DNBLog.h
DNBRegisterInfo.cpp
DNBRegisterInfo.h
DNBRuntimeAction.h
DNBThreadResumeActions.cpp
DNBThreadResumeActions.h
DNBTimer.h
JSON.cpp [lldb] Move StringConvert inside debugserver 2021-09-27 14:32:42 +02:00
JSON.h
JSONGenerator.h Add DumpBinaryEscaped method to JSONGenerator, avoid extra copy 2022-04-04 14:14:02 -07:00
PThreadCondition.h
PThreadEvent.cpp
PThreadEvent.h
PThreadMutex.cpp
PThreadMutex.h
PseudoTerminal.cpp
PseudoTerminal.h
RNBContext.cpp Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
RNBContext.h Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
RNBDefs.h
RNBRemote.cpp Roll back Michał's changes to debugserver, not meant for there 2022-06-21 12:57:42 -07:00
RNBRemote.h Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
RNBServices.cpp
RNBServices.h
RNBSocket.cpp
RNBSocket.h
StdStringExtractor.cpp [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB 2022-03-31 13:21:49 -07:00
StdStringExtractor.h
StringConvert.cpp [lldb] Move StringConvert inside debugserver 2021-09-27 14:32:42 +02:00
StringConvert.h [lldb] Move StringConvert inside debugserver 2021-09-27 14:32:42 +02:00
SysSignal.cpp
SysSignal.h
TTYState.cpp [LLDB] Applying clang-tidy modernize-use-equals-default over LLDB 2022-03-31 13:21:49 -07:00
TTYState.h
debugserver.cpp Add a darwin platform setting to specify which exceptions debugserver 2022-05-18 10:16:11 -07:00
debugserver_vers.c.in
libdebugserver.cpp
libdebugserver.h