From: Guinevere Larsen <guinevere@redhat.com>
To: gdb-patches@sourceware.org
Cc: Guinevere Larsen <guinevere@redhat.com>
Subject: [PATCH 7/7] gdb/record: document recording multi-threaded inferiors
Date: Thu, 29 Oct 2026 17:57:43 -0300 [thread overview]
Message-ID: <20261029205743.1917668-8-guinevere@redhat.com> (raw)
In-Reply-To: <20261029205743.1917668-1-guinevere@redhat.com>
This commit adds an entry to the NEWS file about the support for
recording multi-threaded programs, as well as a quick explanation of
supporting it and the limitations to the documentation.
---
gdb/NEWS | 5 +++++
gdb/doc/gdb.texinfo | 9 ++++++++-
2 files changed, 13 insertions(+), 1 deletion(-)
diff --git a/gdb/NEWS b/gdb/NEWS
index 7303ec0e460..02a6b0d7df6 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -44,6 +44,11 @@
source is modified. Source tracking can be enabled with 'set
breakpoint source-tracking enabled on'.
+* record-full can now record inferiors that have multiple threads, with
+ some caveats. First and most important, the scheduler locking must be
+ set to "on", and the user must execute each thread individually.
+ Additionally, no new threads may be created during the recording.
+
* New targets
i386 Windows/MSVC i[34567]86-*-windows-msvc
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 66152d2582e..5888691a4e5 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -8057,11 +8057,18 @@ program counter register) and the memory of the inferior are still
changed as they normally would. Their contents are taken from the
execution log.
+If the inferior has multiple threads, they will be replayed in the
+order they were recorded in, ignoring settings that change the
+scheduler.
+
@cindex record mode
If the record for the next instruction is not in the execution log,
@value{GDBN} will debug in @dfn{record mode}. In this mode, the
inferior executes normally, and @value{GDBN} records the execution log
-for future replay.
+for future replay. For multi-threaded inferiors, the user must
+perform the scheduling by hand, executing each thread manually for the
+desired amount of time before switching to a different thread. As of
+now GDB is unable to record the creation of new threads.
The process record and replay target supports reverse execution
(@pxref{Reverse Execution}), even if the platform on which the
--
2.56.0
next prev parent reply other threads:[~2026-10-29 20:59 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-29 20:57 [PATCH 0/7] Start supporting multi-threaded inferiors with record-full Guinevere Larsen
2026-10-29 20:57 ` [PATCH 1/7] gdb/record-full: Add thread pointer to recorded instructions Guinevere Larsen
2026-10-29 20:57 ` [PATCH 2/7] gdb/record: add thread ID to the precsave format Guinevere Larsen
2026-10-29 20:57 ` [PATCH 3/7] gdb/record: Make GDB automatically switch threads when replaying Guinevere Larsen
2026-10-29 20:57 ` [PATCH 4/7] gdb: make regcache save a thread pointer, not ptid Guinevere Larsen
2026-10-29 20:57 ` [PATCH 5/7] gdb/record: Record through a thread exiting Guinevere Larsen
2026-10-29 20:57 ` [PATCH 6/7] gdb/record: Loudly warn or fail on dubious situations Guinevere Larsen
2026-10-29 20:57 ` Guinevere Larsen [this message]
2026-10-30 6:43 ` [PATCH 7/7] gdb/record: document recording multi-threaded inferiors Eli Zaretskii
2026-10-30 11:32 ` Guinevere Larsen
2026-10-30 12:44 ` Eli Zaretskii
2026-10-30 13:20 ` Guinevere Larsen
2026-10-30 13:38 ` Eli Zaretskii
2026-10-30 13:40 ` Guinevere Larsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261029205743.1917668-8-guinevere@redhat.com \
--to=guinevere@redhat.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox