* [PATCH v6] Change message when reaching end of reverse history.
@ 2024-08-02 16:43 Alex Chronopoulos
2024-08-12 19:50 ` Guinevere Larsen
0 siblings, 1 reply; 10+ messages in thread
From: Alex Chronopoulos @ 2024-08-02 16:43 UTC (permalink / raw)
To: gdb-patches; +Cc: Alex Chronopoulos
In a record session, when we move backward, GDB switches from normal
execution to simulation. Moving forward again, the emulation continues
until the end of the reverse history. When the end is reached, the
execution stops, and a warning message is shown. This message has been
modified to indicate that the forward emulation has reached the end, but
the execution can continue as normal, and the recording will also continue.
Before this patch, the warning message shown in that case was the same as
in the reverse case. This meant that when the end of history was reached in
either backward or forward emulation, the same message was displayed:
"No more reverse-execution history."
This message has changed for these two cases. Backward emulation:
"Reached end of recorded history; stopping.
Backward execution from here not possible."
Forward emulation:
"Reached end of recorded history; stopping.
Following forward execution will be added to history."
The reason for this change is that the initial message was deceiving, for
the forward case, making the user believe that forward debugging could not
continue.
Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
---
gdb/NEWS | 5 +++
gdb/infrun.c | 9 +++++-
.../gdb.btrace/multi-thread-step.exp | 6 ++--
gdb/testsuite/gdb.btrace/nohist.exp | 2 +-
gdb/testsuite/gdb.btrace/non-stop.exp | 32 ++++++++++++-------
gdb/testsuite/gdb.btrace/stepi.exp | 14 ++++----
gdb/testsuite/gdb.reverse/break-precsave.exp | 6 ++--
gdb/testsuite/gdb.reverse/break-reverse.exp | 4 +--
.../gdb.reverse/machinestate-precsave.exp | 2 +-
gdb/testsuite/gdb.reverse/sigall-precsave.exp | 2 +-
gdb/testsuite/gdb.reverse/sigall-reverse.exp | 2 +-
.../gdb.reverse/singlejmp-reverse.exp | 6 ++--
12 files changed, 57 insertions(+), 33 deletions(-)
diff --git a/gdb/NEWS b/gdb/NEWS
index 50c033a7cfd..5d457b37796 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -20,6 +20,11 @@
* MTE (Memory Tagging Extension) debugging is now supported on AArch64 baremetal
targets.
+* In a record session, when a forward emulation reaches the end of the reverse
+ history, the warning message has been changed to indicate that the end of the
+ history has been reached. It also specifies that the forward execution can
+ continue, and the recording will also continue.
+
*** Changes in GDB 15
* The MPX commands "show/set mpx bound" have been deprecated, as Intel
diff --git a/gdb/infrun.c b/gdb/infrun.c
index 06b454bf78f..a0d1b99be3e 100644
--- a/gdb/infrun.c
+++ b/gdb/infrun.c
@@ -9266,8 +9266,15 @@ print_no_history_reason (struct ui_out *uiout)
{
if (uiout->is_mi_like_p ())
uiout->field_string ("reason", async_reason_lookup (EXEC_ASYNC_NO_HISTORY));
+ else if (execution_direction == EXEC_FORWARD)
+ uiout->text ("\nReached end of recorded history; stopping.\nFollowing "
+ "forward execution will be added to history.\n");
else
- uiout->text ("\nNo more reverse-execution history.\n");
+ {
+ gdb_assert (execution_direction == EXEC_REVERSE);
+ uiout->text ("\nReached end of recorded history; stopping.\nBackward "
+ "execution from here not possible.\n");
+ }
}
/* Print current location without a level number, if we have changed
diff --git a/gdb/testsuite/gdb.btrace/multi-thread-step.exp b/gdb/testsuite/gdb.btrace/multi-thread-step.exp
index 154db9ae515..cd20e8ad9f0 100644
--- a/gdb/testsuite/gdb.btrace/multi-thread-step.exp
+++ b/gdb/testsuite/gdb.btrace/multi-thread-step.exp
@@ -111,14 +111,14 @@ proc test_cont {} {
with_test_prefix "cont" {
gdb_test "thread 1" ".*"
with_test_prefix "thread 1" {
- gdb_test "continue" "No more reverse-execution history.*"
+ gdb_test "continue" "Reached end of recorded history.*"
check_not_replaying 1
check_replay_insn 2 2
}
gdb_test "thread 2" ".*"
with_test_prefix "thread 2" {
- gdb_test "continue" "No more reverse-execution history.*"
+ gdb_test "continue" "Reached end of recorded history.*"
check_not_replaying 1
check_not_replaying 2
@@ -128,7 +128,7 @@ proc test_cont {} {
proc test_cont_all {} {
with_test_prefix "cont-all" {
- gdb_test "continue" "No more reverse-execution history.*"
+ gdb_test "continue" "Reached end of recorded history.*"
# this works because we're lock-stepping threads that executed exactly
# the same code starting from the same instruction.
diff --git a/gdb/testsuite/gdb.btrace/nohist.exp b/gdb/testsuite/gdb.btrace/nohist.exp
index d71909181c4..ac6a41c63e4 100644
--- a/gdb/testsuite/gdb.btrace/nohist.exp
+++ b/gdb/testsuite/gdb.btrace/nohist.exp
@@ -42,7 +42,7 @@ with_test_prefix "forward" {
check_not_replaying
}
-gdb_test "reverse-continue" "No more reverse-execution history\.\r\n.*"
+gdb_test "reverse-continue" "Reached end of recorded history; stopping.*"
with_test_prefix "backward" {
check_not_replaying
diff --git a/gdb/testsuite/gdb.btrace/non-stop.exp b/gdb/testsuite/gdb.btrace/non-stop.exp
index 62c940e4cd6..5e43545f6a9 100644
--- a/gdb/testsuite/gdb.btrace/non-stop.exp
+++ b/gdb/testsuite/gdb.btrace/non-stop.exp
@@ -79,16 +79,26 @@ proc gdb_cont_to_bp_line { line threads nthreads } {
$nthreads
}
-proc gdb_cont_to_no_history { threads cmd nthreads } {
+proc gdb_cont_to_no_history_backward { threads cmd nthreads } {
gdb_cont_to $threads $cmd \
[multi_line \
- "No more reverse-execution history\." \
+ "Reached end of recorded.*Backward execution.*" \
"\[^\\\r\\\n\]*" \
"\[^\\\r\\\n\]*" \
] \
$nthreads
}
+proc gdb_cont_to_no_history_forward { threads cmd nthreads } {
+ gdb_cont_to $threads $cmd \
+ [multi_line \
+ "Reached end of recorded.*Following forward.*" \
+ "\[^\\\r\\\n\]*" \
+ "\[^\\\r\\\n\]*" \
+ ] \
+ $nthreads
+}
+
# trace the code between the two breakpoints
with_test_prefix "prepare" {
gdb_cont_to_bp_line "$srcfile:$bp_1" all 2
@@ -176,14 +186,14 @@ with_test_prefix "reverse-step" {
with_test_prefix "continue" {
with_test_prefix "thread 1" {
with_test_prefix "continue" {
- gdb_cont_to_no_history 1 "continue" 1
+ gdb_cont_to_no_history_forward 1 "continue" 1
gdb_test "thread apply 1 info record" \
".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
gdb_test "thread apply 2 info record" \
".*Replay in progress\. At instruction 5\."
}
with_test_prefix "reverse-continue" {
- gdb_cont_to_no_history 1 "reverse-continue" 1
+ gdb_cont_to_no_history_backward 1 "reverse-continue" 1
gdb_test "thread apply 1 info record" \
".*Replay in progress\. At instruction 1\."
gdb_test "thread apply 2 info record" \
@@ -193,14 +203,14 @@ with_test_prefix "continue" {
with_test_prefix "thread 2" {
with_test_prefix "continue" {
- gdb_cont_to_no_history 2 "continue" 1
+ gdb_cont_to_no_history_forward 2 "continue" 1
gdb_test "thread apply 1 info record" \
".*Replay in progress\. At instruction 1\."
gdb_test "thread apply 2 info record" \
".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
}
with_test_prefix "reverse-continue" {
- gdb_cont_to_no_history 2 "reverse-continue" 1
+ gdb_cont_to_no_history_backward 2 "reverse-continue" 1
gdb_test "thread apply 1 info record" \
".*Replay in progress\. At instruction 1\."
gdb_test "thread apply 2 info record" \
@@ -215,8 +225,8 @@ with_test_prefix "no progress" {
gdb_test "thread apply 1 record goto end" ".*"
gdb_test "thread apply 2 record goto begin" ".*"
- gdb_cont_to_no_history 1 "continue" 1
- gdb_cont_to_no_history 1 "step" 1
+ gdb_cont_to_no_history_forward 1 "continue" 1
+ gdb_cont_to_no_history_forward 1 "step" 1
gdb_test "thread apply 1 info record" \
".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
gdb_test "thread apply 2 info record" \
@@ -227,8 +237,8 @@ with_test_prefix "no progress" {
gdb_test "thread apply 1 record goto begin" ".*"
gdb_test "thread apply 2 record goto end" ".*"
- gdb_cont_to_no_history 2 "continue" 1
- gdb_cont_to_no_history 2 "step" 1
+ gdb_cont_to_no_history_forward 2 "continue" 1
+ gdb_cont_to_no_history_forward 2 "step" 1
gdb_test "thread apply 1 info record" \
".*Replay in progress\. At instruction 1\."
gdb_test "thread apply 2 info record" \
@@ -238,7 +248,7 @@ with_test_prefix "no progress" {
with_test_prefix "all" {
gdb_test "thread apply all record goto begin" ".*"
- gdb_cont_to_no_history all "continue" 2
+ gdb_cont_to_no_history_forward all "continue" 2
gdb_test "thread apply 1 info record" \
".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
gdb_test "thread apply 2 info record" \
diff --git a/gdb/testsuite/gdb.btrace/stepi.exp b/gdb/testsuite/gdb.btrace/stepi.exp
index a70a5adf046..689bc792b24 100644
--- a/gdb/testsuite/gdb.btrace/stepi.exp
+++ b/gdb/testsuite/gdb.btrace/stepi.exp
@@ -100,7 +100,7 @@ with_test_prefix "reverse-nexti.1" {
# we can't reverse-nexti any further
with_test_prefix "reverse-nexti.2" {
gdb_test "reverse-nexti" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-nexti.2"
check_replay_at 1
}
@@ -140,20 +140,20 @@ with_test_prefix "goto begin" {
with_test_prefix "reverse-stepi" {
gdb_test "reverse-stepi" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-stepi.1"
gdb_test "reverse-stepi" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-stepi.2"
check_replay_at 1
}
with_test_prefix "reverse-nexti" {
gdb_test "reverse-nexti" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-nexti.1"
gdb_test "reverse-nexti" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-nexti.2"
check_replay_at 1
}
@@ -169,10 +169,10 @@ with_test_prefix "goto begin" {
with_test_prefix "reverse-stepi" {
gdb_test "reverse-stepi" ".*main\.2.*" "reverse-stepi.1"
gdb_test "reverse-stepi" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-stepi.2"
gdb_test "reverse-stepi" \
- "No more reverse-execution history\.\r\n.*main\.2.*" \
+ "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
"reverse-stepi.3"
check_replay_at 1
}
diff --git a/gdb/testsuite/gdb.reverse/break-precsave.exp b/gdb/testsuite/gdb.reverse/break-precsave.exp
index b9d94681247..6d9b312185f 100644
--- a/gdb/testsuite/gdb.reverse/break-precsave.exp
+++ b/gdb/testsuite/gdb.reverse/break-precsave.exp
@@ -73,7 +73,7 @@ proc precsave_tests {} {
-re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
pass "go to end of main forward"
}
- -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded.*Following forward.* end of main .*" {
pass "go to end of main forward"
}
}
@@ -87,7 +87,7 @@ proc precsave_tests {} {
-re ".*Breakpoint $decimal,.*$srcfile:$main_location.*$gdb_prompt $" {
pass "main backward"
}
- -re "No more reverse-execution history.* break in main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded.*Backward execution.* break in main .*" {
pass "main backward"
}
}
@@ -103,7 +103,7 @@ proc precsave_tests {} {
-re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
pass "end of record log"
}
- -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded.*Following forward.* end of main .*" {
pass "end of record log"
}
}
diff --git a/gdb/testsuite/gdb.reverse/break-reverse.exp b/gdb/testsuite/gdb.reverse/break-reverse.exp
index 1dd327ca654..66e9712707f 100644
--- a/gdb/testsuite/gdb.reverse/break-reverse.exp
+++ b/gdb/testsuite/gdb.reverse/break-reverse.exp
@@ -64,7 +64,7 @@ gdb_test_multiple "continue" "main backward" {
-re ".*Breakpoint $decimal,.*$srcfile:$main_location.*$gdb_prompt $" {
pass "main backward"
}
- -re "No more reverse-execution history.* break in main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded history.*Backward execution.*" {
pass "main backward"
}
}
@@ -80,7 +80,7 @@ gdb_test_multiple "continue" "end of record log" {
-re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
pass "end of record log"
}
- -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded history.*Following forward.*" {
pass "end of record log"
}
}
diff --git a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
index 19c5934bfdf..cedca0f9b65 100644
--- a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
+++ b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
@@ -85,7 +85,7 @@ gdb_test_multiple "continue" "go to end of main forward" {
-re ".*Breakpoint $decimal,.*$srcfile:$endmain.*$gdb_prompt $" {
pass "go to end of main forward"
}
- -re "No more reverse-execution history.* end main .*$gdb_prompt $" {
+ -re -wrap "Reached end of recorded history.*Following forward.*" {
pass "go to end of main forward"
}
}
diff --git a/gdb/testsuite/gdb.reverse/sigall-precsave.exp b/gdb/testsuite/gdb.reverse/sigall-precsave.exp
index e5890ad7af7..aab4551c874 100644
--- a/gdb/testsuite/gdb.reverse/sigall-precsave.exp
+++ b/gdb/testsuite/gdb.reverse/sigall-precsave.exp
@@ -128,7 +128,7 @@ proc test_one_sig_reverse {prevsig} {
xfail "$testmsg (handled)"
}
}
- -re "No more reverse-execution history.*kill.*$gdb_prompt " {
+ -re "Reached end of recorded history.*Backward execution.*kill.*$gdb_prompt " {
if {$saw_signal} {
pass "$testmsg (handled)"
} else {
diff --git a/gdb/testsuite/gdb.reverse/sigall-reverse.exp b/gdb/testsuite/gdb.reverse/sigall-reverse.exp
index f2cf55b8ae4..884b178f9ee 100644
--- a/gdb/testsuite/gdb.reverse/sigall-reverse.exp
+++ b/gdb/testsuite/gdb.reverse/sigall-reverse.exp
@@ -134,7 +134,7 @@ proc test_one_sig_reverse {prevsig} {
xfail "$testmsg (handled)"
}
}
- -re "No more reverse-execution history.*kill.*$gdb_prompt " {
+ -re "Reached end of recorded.*Backward execution.*kill.*$gdb_prompt " {
if {$saw_signal} {
pass "$testmsg (handled)"
} else {
diff --git a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
index 971d88b5ce6..73923564514 100644
--- a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
+++ b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
@@ -50,11 +50,13 @@ gdb_test "next" {nodebug \(\);} "next to nodebug"
gdb_test "next" {v = 3;} "next to v = 3"
# FAIL was:
-# No more reverse-execution history.
+# Reached end of recorded history; stopping.
+# Backward execution from here not possible.
# {
gdb_test "reverse-step" {nodebug \(\);}
# FAIL was:
-# No more reverse-execution history.
+# Reached end of recorded history; stopping.
+# Backward execution from here not possible.
# {
gdb_test "reverse-next" {f \(\);}
--
2.45.2
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-02 16:43 [PATCH v6] Change message when reaching end of reverse history Alex Chronopoulos
@ 2024-08-12 19:50 ` Guinevere Larsen
2024-08-13 8:52 ` Metzger, Markus T
0 siblings, 1 reply; 10+ messages in thread
From: Guinevere Larsen @ 2024-08-12 19:50 UTC (permalink / raw)
To: Alex Chronopoulos, gdb-patches
On 8/2/24 1:43 PM, Alex Chronopoulos wrote:
> In a record session, when we move backward, GDB switches from normal
> execution to simulation. Moving forward again, the emulation continues
> until the end of the reverse history. When the end is reached, the
> execution stops, and a warning message is shown. This message has been
> modified to indicate that the forward emulation has reached the end, but
> the execution can continue as normal, and the recording will also continue.
>
> Before this patch, the warning message shown in that case was the same as
> in the reverse case. This meant that when the end of history was reached in
> either backward or forward emulation, the same message was displayed:
>
> "No more reverse-execution history."
>
> This message has changed for these two cases. Backward emulation:
>
> "Reached end of recorded history; stopping.
> Backward execution from here not possible."
>
> Forward emulation:
>
> "Reached end of recorded history; stopping.
> Following forward execution will be added to history."
>
> The reason for this change is that the initial message was deceiving, for
> the forward case, making the user believe that forward debugging could not
> continue.
>
> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
> ---
Hi! I think this is good to go in, but I would like Markus to chime in
before pushing, since he mantains the other record subsystem, so for now
Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
> gdb/NEWS | 5 +++
> gdb/infrun.c | 9 +++++-
> .../gdb.btrace/multi-thread-step.exp | 6 ++--
> gdb/testsuite/gdb.btrace/nohist.exp | 2 +-
> gdb/testsuite/gdb.btrace/non-stop.exp | 32 ++++++++++++-------
> gdb/testsuite/gdb.btrace/stepi.exp | 14 ++++----
> gdb/testsuite/gdb.reverse/break-precsave.exp | 6 ++--
> gdb/testsuite/gdb.reverse/break-reverse.exp | 4 +--
> .../gdb.reverse/machinestate-precsave.exp | 2 +-
> gdb/testsuite/gdb.reverse/sigall-precsave.exp | 2 +-
> gdb/testsuite/gdb.reverse/sigall-reverse.exp | 2 +-
> .../gdb.reverse/singlejmp-reverse.exp | 6 ++--
> 12 files changed, 57 insertions(+), 33 deletions(-)
>
> diff --git a/gdb/NEWS b/gdb/NEWS
> index 50c033a7cfd..5d457b37796 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -20,6 +20,11 @@
> * MTE (Memory Tagging Extension) debugging is now supported on AArch64 baremetal
> targets.
>
> +* In a record session, when a forward emulation reaches the end of the reverse
> + history, the warning message has been changed to indicate that the end of the
> + history has been reached. It also specifies that the forward execution can
> + continue, and the recording will also continue.
> +
> *** Changes in GDB 15
>
> * The MPX commands "show/set mpx bound" have been deprecated, as Intel
> diff --git a/gdb/infrun.c b/gdb/infrun.c
> index 06b454bf78f..a0d1b99be3e 100644
> --- a/gdb/infrun.c
> +++ b/gdb/infrun.c
> @@ -9266,8 +9266,15 @@ print_no_history_reason (struct ui_out *uiout)
> {
> if (uiout->is_mi_like_p ())
> uiout->field_string ("reason", async_reason_lookup (EXEC_ASYNC_NO_HISTORY));
> + else if (execution_direction == EXEC_FORWARD)
> + uiout->text ("\nReached end of recorded history; stopping.\nFollowing "
> + "forward execution will be added to history.\n");
> else
> - uiout->text ("\nNo more reverse-execution history.\n");
> + {
> + gdb_assert (execution_direction == EXEC_REVERSE);
> + uiout->text ("\nReached end of recorded history; stopping.\nBackward "
> + "execution from here not possible.\n");
> + }
> }
>
> /* Print current location without a level number, if we have changed
> diff --git a/gdb/testsuite/gdb.btrace/multi-thread-step.exp b/gdb/testsuite/gdb.btrace/multi-thread-step.exp
> index 154db9ae515..cd20e8ad9f0 100644
> --- a/gdb/testsuite/gdb.btrace/multi-thread-step.exp
> +++ b/gdb/testsuite/gdb.btrace/multi-thread-step.exp
> @@ -111,14 +111,14 @@ proc test_cont {} {
> with_test_prefix "cont" {
> gdb_test "thread 1" ".*"
> with_test_prefix "thread 1" {
> - gdb_test "continue" "No more reverse-execution history.*"
> + gdb_test "continue" "Reached end of recorded history.*"
>
> check_not_replaying 1
> check_replay_insn 2 2
> }
> gdb_test "thread 2" ".*"
> with_test_prefix "thread 2" {
> - gdb_test "continue" "No more reverse-execution history.*"
> + gdb_test "continue" "Reached end of recorded history.*"
>
> check_not_replaying 1
> check_not_replaying 2
> @@ -128,7 +128,7 @@ proc test_cont {} {
>
> proc test_cont_all {} {
> with_test_prefix "cont-all" {
> - gdb_test "continue" "No more reverse-execution history.*"
> + gdb_test "continue" "Reached end of recorded history.*"
>
> # this works because we're lock-stepping threads that executed exactly
> # the same code starting from the same instruction.
> diff --git a/gdb/testsuite/gdb.btrace/nohist.exp b/gdb/testsuite/gdb.btrace/nohist.exp
> index d71909181c4..ac6a41c63e4 100644
> --- a/gdb/testsuite/gdb.btrace/nohist.exp
> +++ b/gdb/testsuite/gdb.btrace/nohist.exp
> @@ -42,7 +42,7 @@ with_test_prefix "forward" {
> check_not_replaying
> }
>
> -gdb_test "reverse-continue" "No more reverse-execution history\.\r\n.*"
> +gdb_test "reverse-continue" "Reached end of recorded history; stopping.*"
>
> with_test_prefix "backward" {
> check_not_replaying
> diff --git a/gdb/testsuite/gdb.btrace/non-stop.exp b/gdb/testsuite/gdb.btrace/non-stop.exp
> index 62c940e4cd6..5e43545f6a9 100644
> --- a/gdb/testsuite/gdb.btrace/non-stop.exp
> +++ b/gdb/testsuite/gdb.btrace/non-stop.exp
> @@ -79,16 +79,26 @@ proc gdb_cont_to_bp_line { line threads nthreads } {
> $nthreads
> }
>
> -proc gdb_cont_to_no_history { threads cmd nthreads } {
> +proc gdb_cont_to_no_history_backward { threads cmd nthreads } {
> gdb_cont_to $threads $cmd \
> [multi_line \
> - "No more reverse-execution history\." \
> + "Reached end of recorded.*Backward execution.*" \
> "\[^\\\r\\\n\]*" \
> "\[^\\\r\\\n\]*" \
> ] \
> $nthreads
> }
>
> +proc gdb_cont_to_no_history_forward { threads cmd nthreads } {
> + gdb_cont_to $threads $cmd \
> + [multi_line \
> + "Reached end of recorded.*Following forward.*" \
> + "\[^\\\r\\\n\]*" \
> + "\[^\\\r\\\n\]*" \
> + ] \
> + $nthreads
> +}
> +
> # trace the code between the two breakpoints
> with_test_prefix "prepare" {
> gdb_cont_to_bp_line "$srcfile:$bp_1" all 2
> @@ -176,14 +186,14 @@ with_test_prefix "reverse-step" {
> with_test_prefix "continue" {
> with_test_prefix "thread 1" {
> with_test_prefix "continue" {
> - gdb_cont_to_no_history 1 "continue" 1
> + gdb_cont_to_no_history_forward 1 "continue" 1
> gdb_test "thread apply 1 info record" \
> ".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
> gdb_test "thread apply 2 info record" \
> ".*Replay in progress\. At instruction 5\."
> }
> with_test_prefix "reverse-continue" {
> - gdb_cont_to_no_history 1 "reverse-continue" 1
> + gdb_cont_to_no_history_backward 1 "reverse-continue" 1
> gdb_test "thread apply 1 info record" \
> ".*Replay in progress\. At instruction 1\."
> gdb_test "thread apply 2 info record" \
> @@ -193,14 +203,14 @@ with_test_prefix "continue" {
>
> with_test_prefix "thread 2" {
> with_test_prefix "continue" {
> - gdb_cont_to_no_history 2 "continue" 1
> + gdb_cont_to_no_history_forward 2 "continue" 1
> gdb_test "thread apply 1 info record" \
> ".*Replay in progress\. At instruction 1\."
> gdb_test "thread apply 2 info record" \
> ".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
> }
> with_test_prefix "reverse-continue" {
> - gdb_cont_to_no_history 2 "reverse-continue" 1
> + gdb_cont_to_no_history_backward 2 "reverse-continue" 1
> gdb_test "thread apply 1 info record" \
> ".*Replay in progress\. At instruction 1\."
> gdb_test "thread apply 2 info record" \
> @@ -215,8 +225,8 @@ with_test_prefix "no progress" {
> gdb_test "thread apply 1 record goto end" ".*"
> gdb_test "thread apply 2 record goto begin" ".*"
>
> - gdb_cont_to_no_history 1 "continue" 1
> - gdb_cont_to_no_history 1 "step" 1
> + gdb_cont_to_no_history_forward 1 "continue" 1
> + gdb_cont_to_no_history_forward 1 "step" 1
> gdb_test "thread apply 1 info record" \
> ".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
> gdb_test "thread apply 2 info record" \
> @@ -227,8 +237,8 @@ with_test_prefix "no progress" {
> gdb_test "thread apply 1 record goto begin" ".*"
> gdb_test "thread apply 2 record goto end" ".*"
>
> - gdb_cont_to_no_history 2 "continue" 1
> - gdb_cont_to_no_history 2 "step" 1
> + gdb_cont_to_no_history_forward 2 "continue" 1
> + gdb_cont_to_no_history_forward 2 "step" 1
> gdb_test "thread apply 1 info record" \
> ".*Replay in progress\. At instruction 1\."
> gdb_test "thread apply 2 info record" \
> @@ -238,7 +248,7 @@ with_test_prefix "no progress" {
> with_test_prefix "all" {
> gdb_test "thread apply all record goto begin" ".*"
>
> - gdb_cont_to_no_history all "continue" 2
> + gdb_cont_to_no_history_forward all "continue" 2
> gdb_test "thread apply 1 info record" \
> ".*Recorded \[0-9\]+ instructions \[^\\\r\\\n\]*"
> gdb_test "thread apply 2 info record" \
> diff --git a/gdb/testsuite/gdb.btrace/stepi.exp b/gdb/testsuite/gdb.btrace/stepi.exp
> index a70a5adf046..689bc792b24 100644
> --- a/gdb/testsuite/gdb.btrace/stepi.exp
> +++ b/gdb/testsuite/gdb.btrace/stepi.exp
> @@ -100,7 +100,7 @@ with_test_prefix "reverse-nexti.1" {
> # we can't reverse-nexti any further
> with_test_prefix "reverse-nexti.2" {
> gdb_test "reverse-nexti" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-nexti.2"
> check_replay_at 1
> }
> @@ -140,20 +140,20 @@ with_test_prefix "goto begin" {
>
> with_test_prefix "reverse-stepi" {
> gdb_test "reverse-stepi" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-stepi.1"
> gdb_test "reverse-stepi" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-stepi.2"
> check_replay_at 1
> }
>
> with_test_prefix "reverse-nexti" {
> gdb_test "reverse-nexti" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-nexti.1"
> gdb_test "reverse-nexti" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-nexti.2"
> check_replay_at 1
> }
> @@ -169,10 +169,10 @@ with_test_prefix "goto begin" {
> with_test_prefix "reverse-stepi" {
> gdb_test "reverse-stepi" ".*main\.2.*" "reverse-stepi.1"
> gdb_test "reverse-stepi" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-stepi.2"
> gdb_test "reverse-stepi" \
> - "No more reverse-execution history\.\r\n.*main\.2.*" \
> + "Reached end of recorded history; stopping\.\r\n.*main\.2.*" \
> "reverse-stepi.3"
> check_replay_at 1
> }
> diff --git a/gdb/testsuite/gdb.reverse/break-precsave.exp b/gdb/testsuite/gdb.reverse/break-precsave.exp
> index b9d94681247..6d9b312185f 100644
> --- a/gdb/testsuite/gdb.reverse/break-precsave.exp
> +++ b/gdb/testsuite/gdb.reverse/break-precsave.exp
> @@ -73,7 +73,7 @@ proc precsave_tests {} {
> -re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
> pass "go to end of main forward"
> }
> - -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded.*Following forward.* end of main .*" {
> pass "go to end of main forward"
> }
> }
> @@ -87,7 +87,7 @@ proc precsave_tests {} {
> -re ".*Breakpoint $decimal,.*$srcfile:$main_location.*$gdb_prompt $" {
> pass "main backward"
> }
> - -re "No more reverse-execution history.* break in main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded.*Backward execution.* break in main .*" {
> pass "main backward"
> }
> }
> @@ -103,7 +103,7 @@ proc precsave_tests {} {
> -re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
> pass "end of record log"
> }
> - -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded.*Following forward.* end of main .*" {
> pass "end of record log"
> }
> }
> diff --git a/gdb/testsuite/gdb.reverse/break-reverse.exp b/gdb/testsuite/gdb.reverse/break-reverse.exp
> index 1dd327ca654..66e9712707f 100644
> --- a/gdb/testsuite/gdb.reverse/break-reverse.exp
> +++ b/gdb/testsuite/gdb.reverse/break-reverse.exp
> @@ -64,7 +64,7 @@ gdb_test_multiple "continue" "main backward" {
> -re ".*Breakpoint $decimal,.*$srcfile:$main_location.*$gdb_prompt $" {
> pass "main backward"
> }
> - -re "No more reverse-execution history.* break in main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded history.*Backward execution.*" {
> pass "main backward"
> }
> }
> @@ -80,7 +80,7 @@ gdb_test_multiple "continue" "end of record log" {
> -re ".*Breakpoint $decimal,.*$srcfile:$end_location.*$gdb_prompt $" {
> pass "end of record log"
> }
> - -re "No more reverse-execution history.* end of main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded history.*Following forward.*" {
> pass "end of record log"
> }
> }
> diff --git a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
> index 19c5934bfdf..cedca0f9b65 100644
> --- a/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
> +++ b/gdb/testsuite/gdb.reverse/machinestate-precsave.exp
> @@ -85,7 +85,7 @@ gdb_test_multiple "continue" "go to end of main forward" {
> -re ".*Breakpoint $decimal,.*$srcfile:$endmain.*$gdb_prompt $" {
> pass "go to end of main forward"
> }
> - -re "No more reverse-execution history.* end main .*$gdb_prompt $" {
> + -re -wrap "Reached end of recorded history.*Following forward.*" {
> pass "go to end of main forward"
> }
> }
> diff --git a/gdb/testsuite/gdb.reverse/sigall-precsave.exp b/gdb/testsuite/gdb.reverse/sigall-precsave.exp
> index e5890ad7af7..aab4551c874 100644
> --- a/gdb/testsuite/gdb.reverse/sigall-precsave.exp
> +++ b/gdb/testsuite/gdb.reverse/sigall-precsave.exp
> @@ -128,7 +128,7 @@ proc test_one_sig_reverse {prevsig} {
> xfail "$testmsg (handled)"
> }
> }
> - -re "No more reverse-execution history.*kill.*$gdb_prompt " {
> + -re "Reached end of recorded history.*Backward execution.*kill.*$gdb_prompt " {
> if {$saw_signal} {
> pass "$testmsg (handled)"
> } else {
> diff --git a/gdb/testsuite/gdb.reverse/sigall-reverse.exp b/gdb/testsuite/gdb.reverse/sigall-reverse.exp
> index f2cf55b8ae4..884b178f9ee 100644
> --- a/gdb/testsuite/gdb.reverse/sigall-reverse.exp
> +++ b/gdb/testsuite/gdb.reverse/sigall-reverse.exp
> @@ -134,7 +134,7 @@ proc test_one_sig_reverse {prevsig} {
> xfail "$testmsg (handled)"
> }
> }
> - -re "No more reverse-execution history.*kill.*$gdb_prompt " {
> + -re "Reached end of recorded.*Backward execution.*kill.*$gdb_prompt " {
> if {$saw_signal} {
> pass "$testmsg (handled)"
> } else {
> diff --git a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
> index 971d88b5ce6..73923564514 100644
> --- a/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
> +++ b/gdb/testsuite/gdb.reverse/singlejmp-reverse.exp
> @@ -50,11 +50,13 @@ gdb_test "next" {nodebug \(\);} "next to nodebug"
> gdb_test "next" {v = 3;} "next to v = 3"
>
> # FAIL was:
> -# No more reverse-execution history.
> +# Reached end of recorded history; stopping.
> +# Backward execution from here not possible.
> # {
> gdb_test "reverse-step" {nodebug \(\);}
>
> # FAIL was:
> -# No more reverse-execution history.
> +# Reached end of recorded history; stopping.
> +# Backward execution from here not possible.
> # {
> gdb_test "reverse-next" {f \(\);}
--
Cheers,
Guinevere Larsen
She/Her/Hers
^ permalink raw reply [flat|nested] 10+ messages in thread* RE: [PATCH v6] Change message when reaching end of reverse history.
2024-08-12 19:50 ` Guinevere Larsen
@ 2024-08-13 8:52 ` Metzger, Markus T
2024-08-13 11:55 ` Guinevere Larsen
0 siblings, 1 reply; 10+ messages in thread
From: Metzger, Markus T @ 2024-08-13 8:52 UTC (permalink / raw)
To: Alex Chronopoulos; +Cc: gdb-patches, Guinevere Larsen
Hello Alex,
>> In a record session, when we move backward, GDB switches from normal
>> execution to simulation. Moving forward again, the emulation continues
>> until the end of the reverse history. When the end is reached, the
>> execution stops, and a warning message is shown. This message has been
>> modified to indicate that the forward emulation has reached the end, but
>> the execution can continue as normal, and the recording will also continue.
>>
>> Before this patch, the warning message shown in that case was the same as
>> in the reverse case. This meant that when the end of history was reached in
>> either backward or forward emulation, the same message was displayed:
>>
>> "No more reverse-execution history."
>>
>> This message has changed for these two cases. Backward emulation:
>>
>> "Reached end of recorded history; stopping.
>> Backward execution from here not possible."
>>
>> Forward emulation:
>>
>> "Reached end of recorded history; stopping.
>> Following forward execution will be added to history."
>>
>> The reason for this change is that the initial message was deceiving, for
>> the forward case, making the user believe that forward debugging could not
>> continue.
>>
>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
>> ---
>
>Hi! I think this is good to go in, but I would like Markus to chime in
>before pushing, since he mantains the other record subsystem, so for now
>
>Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
OK for btrace.
Markus.
Intel Deutschland GmbH
Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
Tel: +49 89 99 8853-0, www.intel.de
Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon Silva
Chairperson of the Supervisory Board: Nicole Lau
Registered Office: Munich
Commercial Register: Amtsgericht Muenchen HRB 186928
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-13 8:52 ` Metzger, Markus T
@ 2024-08-13 11:55 ` Guinevere Larsen
2024-08-13 18:18 ` Alex Chronopoulos
0 siblings, 1 reply; 10+ messages in thread
From: Guinevere Larsen @ 2024-08-13 11:55 UTC (permalink / raw)
To: Metzger, Markus T, Alex Chronopoulos; +Cc: gdb-patches
On 8/13/24 5:52 AM, Metzger, Markus T wrote:
> Hello Alex,
>
>>> In a record session, when we move backward, GDB switches from normal
>>> execution to simulation. Moving forward again, the emulation continues
>>> until the end of the reverse history. When the end is reached, the
>>> execution stops, and a warning message is shown. This message has been
>>> modified to indicate that the forward emulation has reached the end, but
>>> the execution can continue as normal, and the recording will also continue.
>>>
>>> Before this patch, the warning message shown in that case was the same as
>>> in the reverse case. This meant that when the end of history was reached in
>>> either backward or forward emulation, the same message was displayed:
>>>
>>> "No more reverse-execution history."
>>>
>>> This message has changed for these two cases. Backward emulation:
>>>
>>> "Reached end of recorded history; stopping.
>>> Backward execution from here not possible."
>>>
>>> Forward emulation:
>>>
>>> "Reached end of recorded history; stopping.
>>> Following forward execution will be added to history."
>>>
>>> The reason for this change is that the initial message was deceiving, for
>>> the forward case, making the user believe that forward debugging could not
>>> continue.
>>>
>>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
>>> ---
>> Hi! I think this is good to go in, but I would like Markus to chime in
>> before pushing, since he mantains the other record subsystem, so for now
>>
>> Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
> OK for btrace.
Awesome! Alex, feel free to change my tag to: Approved-By: Guinevere
Larsen <blarsen@redhat.com>
Do you already have write after approval rights for the repo? If not, do
you plan to send more patches, so it makes sense to go after it? If not,
I can push this for you :)
--
Cheers,
Guinevere Larsen
She/Her/Hers
>
> Markus.
> Intel Deutschland GmbH
> Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
> Tel: +49 89 99 8853-0, www.intel.de
> Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon Silva
> Chairperson of the Supervisory Board: Nicole Lau
> Registered Office: Munich
> Commercial Register: Amtsgericht Muenchen HRB 186928
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-13 11:55 ` Guinevere Larsen
@ 2024-08-13 18:18 ` Alex Chronopoulos
2024-08-13 18:26 ` Guinevere Larsen
0 siblings, 1 reply; 10+ messages in thread
From: Alex Chronopoulos @ 2024-08-13 18:18 UTC (permalink / raw)
To: Guinevere Larsen; +Cc: Metzger, Markus T, gdb-patches
[-- Attachment #1: Type: text/plain, Size: 2640 bytes --]
Hooray \o/
Thank you for the reviews.
I would like to push myself, how can I get write-after-approval rights?
On Tue, Aug 13, 2024 at 2:55 PM Guinevere Larsen <blarsen@redhat.com> wrote:
> On 8/13/24 5:52 AM, Metzger, Markus T wrote:
> > Hello Alex,
> >
> >>> In a record session, when we move backward, GDB switches from normal
> >>> execution to simulation. Moving forward again, the emulation continues
> >>> until the end of the reverse history. When the end is reached, the
> >>> execution stops, and a warning message is shown. This message has been
> >>> modified to indicate that the forward emulation has reached the end,
> but
> >>> the execution can continue as normal, and the recording will also
> continue.
> >>>
> >>> Before this patch, the warning message shown in that case was the same
> as
> >>> in the reverse case. This meant that when the end of history was
> reached in
> >>> either backward or forward emulation, the same message was displayed:
> >>>
> >>> "No more reverse-execution history."
> >>>
> >>> This message has changed for these two cases. Backward emulation:
> >>>
> >>> "Reached end of recorded history; stopping.
> >>> Backward execution from here not possible."
> >>>
> >>> Forward emulation:
> >>>
> >>> "Reached end of recorded history; stopping.
> >>> Following forward execution will be added to history."
> >>>
> >>> The reason for this change is that the initial message was deceiving,
> for
> >>> the forward case, making the user believe that forward debugging could
> not
> >>> continue.
> >>>
> >>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
> >>> ---
> >> Hi! I think this is good to go in, but I would like Markus to chime in
> >> before pushing, since he mantains the other record subsystem, so for now
> >>
> >> Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
> > OK for btrace.
>
> Awesome! Alex, feel free to change my tag to: Approved-By: Guinevere
> Larsen <blarsen@redhat.com>
>
> Do you already have write after approval rights for the repo? If not, do
> you plan to send more patches, so it makes sense to go after it? If not,
> I can push this for you :)
>
> --
> Cheers,
> Guinevere Larsen
> She/Her/Hers
>
> >
> > Markus.
> > Intel Deutschland GmbH
> > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
> > Tel: +49 89 99 8853-0, www.intel.de
> > Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon
> Silva
> > Chairperson of the Supervisory Board: Nicole Lau
> > Registered Office: Munich
> > Commercial Register: Amtsgericht Muenchen HRB 186928
>
>
[-- Attachment #2: Type: text/html, Size: 4307 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-13 18:18 ` Alex Chronopoulos
@ 2024-08-13 18:26 ` Guinevere Larsen
2024-08-23 12:25 ` Alex Chronopoulos
0 siblings, 1 reply; 10+ messages in thread
From: Guinevere Larsen @ 2024-08-13 18:26 UTC (permalink / raw)
To: Alex Chronopoulos; +Cc: gdb-patches, Tom Tromey
[-- Attachment #1: Type: text/plain, Size: 3100 bytes --]
I'm CC-ing Tom Tromey, as he's the one who usually talks about this in
the list. Tom, Could you take care of this?
--
Cheers,
Guinevere Larsen
She/Her/Hers
On 8/13/24 3:18 PM, Alex Chronopoulos wrote:
> Hooray \o/
> Thank you for the reviews.
> I would like to push myself, how can I get write-after-approval rights?
>
> On Tue, Aug 13, 2024 at 2:55 PM Guinevere Larsen <blarsen@redhat.com>
> wrote:
>
> On 8/13/24 5:52 AM, Metzger, Markus T wrote:
> > Hello Alex,
> >
> >>> In a record session, when we move backward, GDB switches from
> normal
> >>> execution to simulation. Moving forward again, the emulation
> continues
> >>> until the end of the reverse history. When the end is reached, the
> >>> execution stops, and a warning message is shown. This message
> has been
> >>> modified to indicate that the forward emulation has reached
> the end, but
> >>> the execution can continue as normal, and the recording will
> also continue.
> >>>
> >>> Before this patch, the warning message shown in that case was
> the same as
> >>> in the reverse case. This meant that when the end of history
> was reached in
> >>> either backward or forward emulation, the same message was
> displayed:
> >>>
> >>> "No more reverse-execution history."
> >>>
> >>> This message has changed for these two cases. Backward emulation:
> >>>
> >>> "Reached end of recorded history; stopping.
> >>> Backward execution from here not possible."
> >>>
> >>> Forward emulation:
> >>>
> >>> "Reached end of recorded history; stopping.
> >>> Following forward execution will be added to history."
> >>>
> >>> The reason for this change is that the initial message was
> deceiving, for
> >>> the forward case, making the user believe that forward
> debugging could not
> >>> continue.
> >>>
> >>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
> >>> ---
> >> Hi! I think this is good to go in, but I would like Markus to
> chime in
> >> before pushing, since he mantains the other record subsystem,
> so for now
> >>
> >> Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
> > OK for btrace.
>
> Awesome! Alex, feel free to change my tag to: Approved-By: Guinevere
> Larsen <blarsen@redhat.com>
>
> Do you already have write after approval rights for the repo? If
> not, do
> you plan to send more patches, so it makes sense to go after it?
> If not,
> I can push this for you :)
>
> --
> Cheers,
> Guinevere Larsen
> She/Her/Hers
>
> >
> > Markus.
> > Intel Deutschland GmbH
> > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
> > Tel: +49 89 99 8853-0, www.intel.de <http://www.intel.de>
> > Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany
> Doon Silva
> > Chairperson of the Supervisory Board: Nicole Lau
> > Registered Office: Munich
> > Commercial Register: Amtsgericht Muenchen HRB 186928
>
[-- Attachment #2: Type: text/html, Size: 6299 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-13 18:26 ` Guinevere Larsen
@ 2024-08-23 12:25 ` Alex Chronopoulos
2024-08-26 13:41 ` Guinevere Larsen
0 siblings, 1 reply; 10+ messages in thread
From: Alex Chronopoulos @ 2024-08-23 12:25 UTC (permalink / raw)
To: gdb-patches; +Cc: Guinevere Larsen
[-- Attachment #1: Type: text/plain, Size: 3166 bytes --]
Since it takes some time, could you go on and land this one? I will have
coordinated with Tom by the next time it's needed.
On Tue, Aug 13, 2024 at 9:26 PM Guinevere Larsen <blarsen@redhat.com> wrote:
> I'm CC-ing Tom Tromey, as he's the one who usually talks about this in the
> list. Tom, Could you take care of this?
>
> --
> Cheers,
> Guinevere Larsen
> She/Her/Hers
>
> On 8/13/24 3:18 PM, Alex Chronopoulos wrote:
>
> Hooray \o/
> Thank you for the reviews.
> I would like to push myself, how can I get write-after-approval rights?
>
> On Tue, Aug 13, 2024 at 2:55 PM Guinevere Larsen <blarsen@redhat.com>
> wrote:
>
>> On 8/13/24 5:52 AM, Metzger, Markus T wrote:
>> > Hello Alex,
>> >
>> >>> In a record session, when we move backward, GDB switches from normal
>> >>> execution to simulation. Moving forward again, the emulation continues
>> >>> until the end of the reverse history. When the end is reached, the
>> >>> execution stops, and a warning message is shown. This message has been
>> >>> modified to indicate that the forward emulation has reached the end,
>> but
>> >>> the execution can continue as normal, and the recording will also
>> continue.
>> >>>
>> >>> Before this patch, the warning message shown in that case was the
>> same as
>> >>> in the reverse case. This meant that when the end of history was
>> reached in
>> >>> either backward or forward emulation, the same message was displayed:
>> >>>
>> >>> "No more reverse-execution history."
>> >>>
>> >>> This message has changed for these two cases. Backward emulation:
>> >>>
>> >>> "Reached end of recorded history; stopping.
>> >>> Backward execution from here not possible."
>> >>>
>> >>> Forward emulation:
>> >>>
>> >>> "Reached end of recorded history; stopping.
>> >>> Following forward execution will be added to history."
>> >>>
>> >>> The reason for this change is that the initial message was deceiving,
>> for
>> >>> the forward case, making the user believe that forward debugging
>> could not
>> >>> continue.
>> >>>
>> >>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
>> >>> ---
>> >> Hi! I think this is good to go in, but I would like Markus to chime in
>> >> before pushing, since he mantains the other record subsystem, so for
>> now
>> >>
>> >> Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
>> > OK for btrace.
>>
>> Awesome! Alex, feel free to change my tag to: Approved-By: Guinevere
>> Larsen <blarsen@redhat.com>
>>
>> Do you already have write after approval rights for the repo? If not, do
>> you plan to send more patches, so it makes sense to go after it? If not,
>> I can push this for you :)
>>
>> --
>> Cheers,
>> Guinevere Larsen
>> She/Her/Hers
>>
>> >
>> > Markus.
>> > Intel Deutschland GmbH
>> > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
>> > Tel: +49 89 99 8853-0, www.intel.de
>> > Managing Directors: Sean Fennelly, Jeffrey Schneiderman, Tiffany Doon
>> Silva
>> > Chairperson of the Supervisory Board: Nicole Lau
>> > Registered Office: Munich
>> > Commercial Register: Amtsgericht Muenchen HRB 186928
>>
>>
[-- Attachment #2: Type: text/html, Size: 5812 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-23 12:25 ` Alex Chronopoulos
@ 2024-08-26 13:41 ` Guinevere Larsen
2024-08-27 10:17 ` Tom de Vries
0 siblings, 1 reply; 10+ messages in thread
From: Guinevere Larsen @ 2024-08-26 13:41 UTC (permalink / raw)
To: Alex Chronopoulos, gdb-patches
[-- Attachment #1: Type: text/plain, Size: 4057 bytes --]
Pushed :)
though, I'm very sorry, I messed up some git command and ended up as the
author, and only realized after the push. I don't think there's a way to
amend it once it's pushed :(
--
Cheers,
Guinevere Larsen
She/Her/Hers
On 8/23/24 9:25 AM, Alex Chronopoulos wrote:
> Since it takes some time, could you go on and land this one? I will
> have coordinated with Tom by the next time it's needed.
>
> On Tue, Aug 13, 2024 at 9:26 PM Guinevere Larsen <blarsen@redhat.com>
> wrote:
>
> I'm CC-ing Tom Tromey, as he's the one who usually talks about
> this in the list. Tom, Could you take care of this?
>
> --
> Cheers,
> Guinevere Larsen
> She/Her/Hers
>
> On 8/13/24 3:18 PM, Alex Chronopoulos wrote:
>> Hooray \o/
>> Thank you for the reviews.
>> I would like to push myself, how can I get write-after-approval
>> rights?
>>
>> On Tue, Aug 13, 2024 at 2:55 PM Guinevere Larsen
>> <blarsen@redhat.com> wrote:
>>
>> On 8/13/24 5:52 AM, Metzger, Markus T wrote:
>> > Hello Alex,
>> >
>> >>> In a record session, when we move backward, GDB switches
>> from normal
>> >>> execution to simulation. Moving forward again, the
>> emulation continues
>> >>> until the end of the reverse history. When the end is
>> reached, the
>> >>> execution stops, and a warning message is shown. This
>> message has been
>> >>> modified to indicate that the forward emulation has
>> reached the end, but
>> >>> the execution can continue as normal, and the recording
>> will also continue.
>> >>>
>> >>> Before this patch, the warning message shown in that case
>> was the same as
>> >>> in the reverse case. This meant that when the end of
>> history was reached in
>> >>> either backward or forward emulation, the same message
>> was displayed:
>> >>>
>> >>> "No more reverse-execution history."
>> >>>
>> >>> This message has changed for these two cases. Backward
>> emulation:
>> >>>
>> >>> "Reached end of recorded history; stopping.
>> >>> Backward execution from here not possible."
>> >>>
>> >>> Forward emulation:
>> >>>
>> >>> "Reached end of recorded history; stopping.
>> >>> Following forward execution will be added to history."
>> >>>
>> >>> The reason for this change is that the initial message
>> was deceiving, for
>> >>> the forward case, making the user believe that forward
>> debugging could not
>> >>> continue.
>> >>>
>> >>> Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31224
>> >>> ---
>> >> Hi! I think this is good to go in, but I would like Markus
>> to chime in
>> >> before pushing, since he mantains the other record
>> subsystem, so for now
>> >>
>> >> Reviewed-By: Guinevere Larsen <blarsen@redhat.com>
>> > OK for btrace.
>>
>> Awesome! Alex, feel free to change my tag to: Approved-By:
>> Guinevere
>> Larsen <blarsen@redhat.com>
>>
>> Do you already have write after approval rights for the repo?
>> If not, do
>> you plan to send more patches, so it makes sense to go after
>> it? If not,
>> I can push this for you :)
>>
>> --
>> Cheers,
>> Guinevere Larsen
>> She/Her/Hers
>>
>> >
>> > Markus.
>> > Intel Deutschland GmbH
>> > Registered Address: Am Campeon 10, 85579 Neubiberg, Germany
>> > Tel: +49 89 99 8853-0, www.intel.de <http://www.intel.de>
>> > Managing Directors: Sean Fennelly, Jeffrey Schneiderman,
>> Tiffany Doon Silva
>> > Chairperson of the Supervisory Board: Nicole Lau
>> > Registered Office: Munich
>> > Commercial Register: Amtsgericht Muenchen HRB 186928
>>
[-- Attachment #2: Type: text/html, Size: 8037 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-26 13:41 ` Guinevere Larsen
@ 2024-08-27 10:17 ` Tom de Vries
2024-08-27 11:07 ` Guinevere Larsen
0 siblings, 1 reply; 10+ messages in thread
From: Tom de Vries @ 2024-08-27 10:17 UTC (permalink / raw)
To: Guinevere Larsen, Alex Chronopoulos, gdb-patches
On 8/26/24 15:41, Guinevere Larsen wrote:
> Pushed :)
Hi Gwen,
After this patch got pushed, I ran into:
...
(gdb) PASS: gdb.btrace/non-stop.exp: no progress: all: thread apply all
continue: prompt
^M
Reached end of recorded history; stopping.^M
Following forward execution will be added to history.^M
test (arg=0x0) at
/data/vries/gdb/src/gdb/testsuite/gdb.btrace/non-stop.c:30^M
30 return arg; /* bp.2 */^M
^M
Reached end of recorded history; stopping.^M
Following forward execution will be added to history.^M
test (arg=0x0) at
/data/vries/gdb/src/gdb/testsuite/gdb.btrace/non-stop.c:30^M
30 return arg; /* bp.2 */^M
PASS: gdb.btrace/non-stop.exp: no progress: all: thread apply all
continue: thread 0
FAIL: gdb.btrace/non-stop.exp: no progress: all: thread apply all
continue: thread 1 (timeout)
...
I suppose the test-case needs to be updated.
Thanks,
- Tom
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [PATCH v6] Change message when reaching end of reverse history.
2024-08-27 10:17 ` Tom de Vries
@ 2024-08-27 11:07 ` Guinevere Larsen
0 siblings, 0 replies; 10+ messages in thread
From: Guinevere Larsen @ 2024-08-27 11:07 UTC (permalink / raw)
To: Tom de Vries, Alex Chronopoulos, gdb-patches
On 8/27/24 7:17 AM, Tom de Vries wrote:
> On 8/26/24 15:41, Guinevere Larsen wrote:
>> Pushed :)
>
> Hi Gwen,
>
> After this patch got pushed, I ran into:
> ...
> (gdb) PASS: gdb.btrace/non-stop.exp: no progress: all: thread apply
> all continue: prompt
> ^M
> Reached end of recorded history; stopping.^M
> Following forward execution will be added to history.^M
> test (arg=0x0) at
> /data/vries/gdb/src/gdb/testsuite/gdb.btrace/non-stop.c:30^M
> 30 return arg; /* bp.2 */^M
> ^M
> Reached end of recorded history; stopping.^M
> Following forward execution will be added to history.^M
> test (arg=0x0) at
> /data/vries/gdb/src/gdb/testsuite/gdb.btrace/non-stop.c:30^M
> 30 return arg; /* bp.2 */^M
> PASS: gdb.btrace/non-stop.exp: no progress: all: thread apply all
> continue: thread 0
> FAIL: gdb.btrace/non-stop.exp: no progress: all: thread apply all
> continue: thread 1 (timeout)
> ...
>
> I suppose the test-case needs to be updated.
The test case is updated. I think the regexes need to be fixed instead.
Right now, the test uses:
multi_line "reached end of recorded.*Following forward.*"
"\[^\\\r\\\n\]*" "\[^\\\r\\\n\]*"
the '.*' in the first line must be consuming all of the first output
(thread 0) and the next bits are finishing consuming the second input
(thread 1), so when expect tries to find the second stop message, it has
already been consumed.
I'll try to write a more exact version that doesn't do that, but my
machine doesn't support btrace so I'll need someone to double check me.
--
Cheers,
Guinevere Larsen
She/Her/Hers
>
> Thanks,
> - Tom
>
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2024-08-27 11:08 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-08-02 16:43 [PATCH v6] Change message when reaching end of reverse history Alex Chronopoulos
2024-08-12 19:50 ` Guinevere Larsen
2024-08-13 8:52 ` Metzger, Markus T
2024-08-13 11:55 ` Guinevere Larsen
2024-08-13 18:18 ` Alex Chronopoulos
2024-08-13 18:26 ` Guinevere Larsen
2024-08-23 12:25 ` Alex Chronopoulos
2024-08-26 13:41 ` Guinevere Larsen
2024-08-27 10:17 ` Tom de Vries
2024-08-27 11:07 ` Guinevere Larsen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox