aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.python
diff options
context:
space:
mode:
authorJohn Baldwin <jhb@FreeBSD.org>2023-08-14 13:38:42 -0700
committerJohn Baldwin <jhb@FreeBSD.org>2023-08-14 13:38:42 -0700
commite1d94b3b5216e9ef8a32d229fc13f62a2f1818a6 (patch)
tree0fb726331296d41d2a6652aa77817f6506120cd2 /gdb/testsuite/gdb.python
parent12e5b10965ccfc5fe42bd129c158280cd6e834a7 (diff)
downloadbinutils-e1d94b3b5216e9ef8a32d229fc13f62a2f1818a6.zip
binutils-e1d94b3b5216e9ef8a32d229fc13f62a2f1818a6.tar.gz
binutils-e1d94b3b5216e9ef8a32d229fc13f62a2f1818a6.tar.bz2
fbsd-nat: Fix several issues with detaching.
- Detach from any child processes implicitly attached to by the kernel due to fork following that have not yet been processed by GDB's core. - Delete breakpoints before detaching. inf-ptrace::detach does not do this (somewhat surprisingly), so add an override to remove breakpoints from a process before detaching from it. This also requires explicitly draining any pending SIGTRAP events for software breakpoints before detaching. In particular, threads may need their PC adjusted due to the software breakpoint before being resumed after detach. On more modern systems using the si_code from SIGTRAP to identify software breakpoint traps, the PC is adjusted in ::wait_1 as a side effect of parsing the event. To support older kernels, ::detach fixes up the PC for any SIGTRAP stop whose potential new PC matches an existing software breakpoint.
Diffstat (limited to 'gdb/testsuite/gdb.python')
0 files changed, 0 insertions, 0 deletions