History log of /llvm-project-15.0.7/lldb/tools/debugserver/source/MacOSX/MachProcess.mm (Results 1 – 25 of 84)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: llvmorg-20.1.0, llvmorg-20.1.0-rc3, llvmorg-20.1.0-rc2, llvmorg-20.1.0-rc1, llvmorg-21-init, llvmorg-19.1.7, llvmorg-19.1.6, llvmorg-19.1.5, llvmorg-19.1.4, llvmorg-19.1.3, llvmorg-19.1.2, llvmorg-19.1.1, llvmorg-19.1.0, llvmorg-19.1.0-rc4, llvmorg-19.1.0-rc3, llvmorg-19.1.0-rc2, llvmorg-19.1.0-rc1, llvmorg-20-init, llvmorg-18.1.8, llvmorg-18.1.7, llvmorg-18.1.6, llvmorg-18.1.5, llvmorg-18.1.4, llvmorg-18.1.3, llvmorg-18.1.2, llvmorg-18.1.1, llvmorg-18.1.0, llvmorg-18.1.0-rc4, llvmorg-18.1.0-rc3, llvmorg-18.1.0-rc2, llvmorg-18.1.0-rc1, llvmorg-19-init, llvmorg-17.0.6, llvmorg-17.0.5, llvmorg-17.0.4, llvmorg-17.0.3, llvmorg-17.0.2, llvmorg-17.0.1, llvmorg-17.0.0, llvmorg-17.0.0-rc4, llvmorg-17.0.0-rc3, llvmorg-17.0.0-rc2, llvmorg-17.0.0-rc1, llvmorg-18-init, llvmorg-16.0.6, llvmorg-16.0.5, llvmorg-16.0.4, llvmorg-16.0.3, llvmorg-16.0.2, llvmorg-16.0.1, llvmorg-16.0.0, llvmorg-16.0.0-rc4, llvmorg-16.0.0-rc3, llvmorg-16.0.0-rc2, llvmorg-16.0.0-rc1, llvmorg-17-init, llvmorg-15.0.7, llvmorg-15.0.6, llvmorg-15.0.5, llvmorg-15.0.4, llvmorg-15.0.3, llvmorg-15.0.2, llvmorg-15.0.1, llvmorg-15.0.0, llvmorg-15.0.0-rc3, llvmorg-15.0.0-rc2, llvmorg-15.0.0-rc1, llvmorg-16-init
# ac49e902 14-Jul-2022 Jason Molenda <[email protected]>

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 filep

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

show more ...


# 9302ff09 11-Jul-2022 Jonas Devlieghere <[email protected]>

Revert "jGetLoadedDynamicLibrariesInfos can inspect machos not yet loaded"

This reverts commit 77a38f6839980bfac61babb40d83772c51427011 because (I
suspect) it breaks TestAppleSimulatorOSType.py on G

Revert "jGetLoadedDynamicLibrariesInfos can inspect machos not yet loaded"

This reverts commit 77a38f6839980bfac61babb40d83772c51427011 because (I
suspect) it breaks TestAppleSimulatorOSType.py on GreenDragon [1].

[1] https://green.lab.llvm.org/green/view/LLDB/job/lldb-cmake/45191/

show more ...


# 77a38f68 08-Jul-2022 Jason Molenda <[email protected]>

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 filep

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.

Differential Revision: https://reviews.llvm.org/D128956
rdar://95737734

show more ...


Revision tags: llvmorg-14.0.6, llvmorg-14.0.5, llvmorg-14.0.4
# bff4673b 11-May-2022 Jim Ingham <[email protected]>

Add a darwin platform setting to specify which exceptions debugserver
should not receive as exceptions (some will get converted to BSD
signals instead). This is really the only stable way to ensure

Add a darwin platform setting to specify which exceptions debugserver
should not receive as exceptions (some will get converted to BSD
signals instead). This is really the only stable way to ensure that
a Mach exception gets converted to it's equivalent BSD signal. For
programs that rely on BSD signal handlers, this has to happen or you
can't even get the program to invoke the signal handler when under
the debugger.

This builds on a previous solution to this problem which required you
start debugserver with the -U flag. This was not very discoverable
and required lldb be the one to launch debugserver, which is not always
the case.

Differential Revision: https://reviews.llvm.org/D125434

show more ...


Revision tags: llvmorg-14.0.3, llvmorg-14.0.2, llvmorg-14.0.1, llvmorg-14.0.0, llvmorg-14.0.0-rc4, llvmorg-14.0.0-rc3, llvmorg-14.0.0-rc2, llvmorg-14.0.0-rc1, llvmorg-15-init, llvmorg-13.0.1, llvmorg-13.0.1-rc3, llvmorg-13.0.1-rc2, llvmorg-13.0.1-rc1, llvmorg-13.0.0, llvmorg-13.0.0-rc4, llvmorg-13.0.0-rc3, llvmorg-13.0.0-rc2, llvmorg-13.0.0-rc1, llvmorg-14-init
# b5a84e21 16-Jul-2021 Jonas Devlieghere <[email protected]>

[debugserver] Un-conditionalize code guarded by macOS 10.10 checks

We've been requiring macOS 10.11 since 2018 so there's no point in
keeping code for 10.10 around.


Revision tags: llvmorg-12.0.1, llvmorg-12.0.1-rc4, llvmorg-12.0.1-rc3, llvmorg-12.0.1-rc2, llvmorg-12.0.1-rc1
# 8dd10602 21-May-2021 kuperxu <[email protected]>

[debugserver] Add platform cache support to improve performance.

The dyld SPI used by debugserver (_dyld_process_info_create) has become
much slower in macOS BigSur 11.3 causing a significant perfor

[debugserver] Add platform cache support to improve performance.

The dyld SPI used by debugserver (_dyld_process_info_create) has become
much slower in macOS BigSur 11.3 causing a significant performance
regression when attaching. This commit mitigates that by caching the
result when calling the SPI to compute the platform.

Differential revision: https://reviews.llvm.org/D102833

show more ...


# afee0975 13-May-2021 Jason Molenda <[email protected]>

[NFC] Add GetInferiorAddrSize method, unify code to compute

MachProcess.mm has a sequence to get the address size in
the inferior in three places; and I'm about to add a fourth
in a future patch. N

[NFC] Add GetInferiorAddrSize method, unify code to compute

MachProcess.mm has a sequence to get the address size in
the inferior in three places; and I'm about to add a fourth
in a future patch. Not a fan.

show more ...


Revision tags: llvmorg-12.0.0, llvmorg-12.0.0-rc5, llvmorg-12.0.0-rc4, llvmorg-12.0.0-rc3
# 011a8e21 25-Feb-2021 Jonas Devlieghere <[email protected]>

[debugserver] Fix logic to extract app bundle from file path

Fix the logic to find the app bundle in a path by correctly accounting
for paths containing multiple occurrences of `.app`. The new logic

[debugserver] Fix logic to extract app bundle from file path

Fix the logic to find the app bundle in a path by correctly accounting
for paths containing multiple occurrences of `.app`. The new logic will
correctly extract `com.app.Foo.app` from `com.app.Foo.app/com.app.Foo`.

rdar://74666208

Differential revision: https://reviews.llvm.org/D97441

show more ...


Revision tags: llvmorg-12.0.0-rc2, llvmorg-11.1.0, llvmorg-11.1.0-rc3, llvmorg-12.0.0-rc1, llvmorg-13-init, llvmorg-11.1.0-rc2, llvmorg-11.1.0-rc1
# edde2eb1 12-Jan-2021 Jason Molenda <[email protected]>

Add unconditional logging to debugserver for launch/attach processes

Debugging app launch/attach failures can be difficult because of
all of the messages logged to the console on a darwin system;
em

Add unconditional logging to debugserver for launch/attach processes

Debugging app launch/attach failures can be difficult because of
all of the messages logged to the console on a darwin system;
emitting specific messages around critical API calls can make it
easier to narrow the search for the console messages related to
the failure.

<rdar://problem/67220442>

Differential revision: https://reviews.llvm.org/D94357

show more ...


Revision tags: llvmorg-11.0.1, llvmorg-11.0.1-rc2
# ee607ed5 06-Dec-2020 Jonas Devlieghere <[email protected]>

[debugserver] Call posix_spawnattr_setarchpref_np throught the fn ptr.

Fourth time is the charm? Of course all of these issues don't show up
when the function is available...


# 13ee00d0 05-Dec-2020 Jonas Devlieghere <[email protected]>

[debugserver] Use dlsym for posix_spawnattr_setarchpref_np

The @available check did not work as I thought it did. Use good old
dlsym instead.


# c722096b 05-Dec-2020 Jonas Devlieghere <[email protected]>

[debugserver] Remove bridgeos availability

I didn't realize that the 'bridgeos' is not part of the public SDK.


# 0db37576 05-Dec-2020 Jonas Devlieghere <[email protected]>

[debugserver] Honor the cpu sub type if specified

Use the newly added spawnattr API, posix_spawnattr_setarchpref_np, to
select a slice preferences per cpu and subcpu types, instead of just cpu
with

[debugserver] Honor the cpu sub type if specified

Use the newly added spawnattr API, posix_spawnattr_setarchpref_np, to
select a slice preferences per cpu and subcpu types, instead of just cpu
with posix_spawnattr_setarchpref_np.

rdar://16094957

Differential revision: https://reviews.llvm.org/D92712

show more ...


Revision tags: llvmorg-11.0.1-rc1
# 27012c0f 17-Nov-2020 Alessandro Arzilli <[email protected]>

[debugserver] Add option to propagate SIGSEGV to target process

Adds a command line option that makes debugserver propagate the SIGSEGV
signal to the target process.

Motivation: I'm one of the main

[debugserver] Add option to propagate SIGSEGV to target process

Adds a command line option that makes debugserver propagate the SIGSEGV
signal to the target process.

Motivation: I'm one of the maintainers of Delve [1] a debugger for Go.
We use debugserver as our backend on macOS and one of the most often
reported bugs is that, on macOS, we don't propagate SIGSEGV back to the
target process [2]. Sometimes some programs will actually cause a
SIGSEGV, by design, and then handle it. Those programs can not be
debugged at all.

Since catching signals isn't very important for a Go debugger I'd much
rather have a command line option in debugserver that causes it to let
SIGSEGV go directly to the target process.

[1] https://github.com/go-delve/delve/
[2] https://github.com/go-delve/delve/issues/852

Differential revision: https://reviews.llvm.org/D89315

show more ...


# e763709d 13-Oct-2020 Jason Molenda <[email protected]>

Add a new launch flag option for watchos, WatchComplicationLaunch.

Link against CarouselServices on watchos, recognize the
WatchComplicationLaunch launch flag option when that framework
is available

Add a new launch flag option for watchos, WatchComplicationLaunch.

Link against CarouselServices on watchos, recognize the
WatchComplicationLaunch launch flag option when that framework
is available.

<rdar://problem/62473967>, <rdar://problem/61230088>

show more ...


Revision tags: llvmorg-11.0.0, llvmorg-11.0.0-rc6, llvmorg-11.0.0-rc5, llvmorg-11.0.0-rc4, llvmorg-11.0.0-rc3, llvmorg-11.0.0-rc2, llvmorg-11.0.0-rc1
# 7e9bab6a 25-Jul-2020 Adrian Prantl <[email protected]>

Fix debugserver's qProcessInfo reporting of maccatalyst binaries

This patch is similar in spirit to https://reviews.llvm.org/D84480,
but does the maccatalyst/macosx disambiguation. I also took the
o

Fix debugserver's qProcessInfo reporting of maccatalyst binaries

This patch is similar in spirit to https://reviews.llvm.org/D84480,
but does the maccatalyst/macosx disambiguation. I also took the
opportunity to factor out the gdb-remote packet log scanning used by
several testcases into lldbutil functions.

rdar://problem/66059257

Differential Revision: https://reviews.llvm.org/D84576

show more ...


# 58d84eb5 24-Jul-2020 Adrian Prantl <[email protected]>

debugserver: Support ios simulator load command disambiguation in qProcessInfo

This patch basically moves the disambiguation code from a place where
it was complicated to implement straight to where

debugserver: Support ios simulator load command disambiguation in qProcessInfo

This patch basically moves the disambiguation code from a place where
it was complicated to implement straight to where the load command is
parsed, which has the neat side affect of actually supporting all call
sites!

rdar://problem/66011909

Differential Revision: https://reviews.llvm.org/D84480

show more ...


Revision tags: llvmorg-12-init
# 851cc2f8 11-Jul-2020 Adrian Prantl <[email protected]>

Fix nesting of #ifdef

This fixes a compile error when building for an arm64 host.

Differential Revision: https://reviews.llvm.org/D83582


# 15149e40 09-Jul-2020 Adrian Prantl <[email protected]>

Fix debugserver reporting of deployment target

This patch fixes debugserver incorrectly returning the SDK version
instead of the minimum deployment target version.

rdar://problem/65001691

Differen

Fix debugserver reporting of deployment target

This patch fixes debugserver incorrectly returning the SDK version
instead of the minimum deployment target version.

rdar://problem/65001691

Differential Revision: https://reviews.llvm.org/D83443

show more ...


Revision tags: llvmorg-10.0.1, llvmorg-10.0.1-rc4, llvmorg-10.0.1-rc3
# 278874f0 01-Jul-2020 Adrian Prantl <[email protected]>

debugserver: Return a nullptr in GetPlatformString()

This un-breaks the testsuite after https://reviews.llvm.org/D82616


# 116b1033 01-Jul-2020 Adrian Prantl <[email protected]>

Revert "Revert "Improve the detection of iOS/tvOS/watchOS simulator binaries in""

This reverts commit 98c3a38a1967ece4e70891aa188c51e29ca0f8d3.


# 98c3a38a 01-Jul-2020 Jonas Devlieghere <[email protected]>

Revert "Improve the detection of iOS/tvOS/watchOS simulator binaries in"

This reverts commit 0da0437b2afbd8ebef6b11f114cca33b118e7639 to unbreak
the following tests:

lldb-api.tools/lldb-server.Test

Revert "Improve the detection of iOS/tvOS/watchOS simulator binaries in"

This reverts commit 0da0437b2afbd8ebef6b11f114cca33b118e7639 to unbreak
the following tests:

lldb-api.tools/lldb-server.TestAppleSimulatorOSType.py
lldb-api.tools/lldb-server.TestGdbRemoteAttach.py
lldb-api.tools/lldb-server.TestGdbRemoteProcessInfo.py
lldb-api.tools/lldb-server.TestGdbRemoteRegisterState.py
lldb-api.tools/lldb-server.TestGdbRemoteThreadsInStopReply.py
lldb-api.tools/lldb-server.TestLldbGdbServer.py

show more ...


# 0da0437b 30-Jun-2020 Adrian Prantl <[email protected]>

Improve the detection of iOS/tvOS/watchOS simulator binaries in
debugserver and lldb

This patch improves the heuristics for correctly identifying simulator binaries on Darwin and adds support for si

Improve the detection of iOS/tvOS/watchOS simulator binaries in
debugserver and lldb

This patch improves the heuristics for correctly identifying simulator binaries on Darwin and adds support for simulators running on Apple Silicon.

rdar://problem/64046344

Differential Revision: https://reviews.llvm.org/D82616

show more ...


Revision tags: llvmorg-10.0.1-rc2
# 0965b59b 16-Jun-2020 Jonas Devlieghere <[email protected]>

[lldb/debugserver] Rename Master/Slave to Primary/Secondary (NFC)


Revision tags: llvmorg-10.0.1-rc1
# c9537b9c 09-May-2020 Fred Riss <[email protected]>

[lldb/debugserver] Include TargetConditionals.h where needed

MachProcess.mm uses a TARGET_OS_ macro without directly including
TargetConditionals.h. This currently works as we get the header
as an i

[lldb/debugserver] Include TargetConditionals.h where needed

MachProcess.mm uses a TARGET_OS_ macro without directly including
TargetConditionals.h. This currently works as we get the header
as an indirect dependency, but might not in the future.

I just spent some time investigating an internal regression
caused by a similar issue, so I audited the codebase for such
cases.

show more ...


1234