]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
gdb, btrace: fix pr19340
authorMarkus Metzger <markus.t.metzger@intel.com>
Tue, 20 Feb 2024 11:45:39 +0000 (11:45 +0000)
committerMarkus Metzger <markus.t.metzger@intel.com>
Mon, 3 Nov 2025 06:16:24 +0000 (06:16 +0000)
commit4a9efbe8b0bb70582e00316410e23ceb884d48da
tree499cd98636e69d5872599b13a396889b1c3598e4
parent626360da44457075f2d9026f0d1d356e5b75c002
gdb, btrace: fix pr19340

GDB fails with an assertion when stopping recording on a replaying thread
and then resuming that thread.  Stopping recording left the thread
replaying but the record target is gone.

Stop replaying all threads in the selected inferior before stopping recording.

I had to change the stepping test slightly to account for different
compilers generating slightly different debug information, so when
stepping the 'return 0' after 'record stop' I would end up in a different
location depending on which compiler I used.  The test still covers all
stepping commands.

Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=19340

Approved-By: Andrew Burgess <aburgess@redhat.com>
gdb/record-btrace.c
gdb/testsuite/gdb.btrace/step.exp