Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Simon Marchi <simark@simark.ca>
To: Andrew Burgess <aburgess@redhat.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] gdb/testsuite: mark the start of each gdb.in.* log file
Date: Wed, 16 Jul 2025 14:19:22 -0400	[thread overview]
Message-ID: <47c67727-2c45-403d-9a72-4d38eb4062e1@simark.ca> (raw)
In-Reply-To: <645cd54b3add6e39d3c8ba69e15c0a85bd0875c4.1752689517.git.aburgess@redhat.com>



On 2025-07-16 14:12, Andrew Burgess wrote:
> Emit a line in the gdb.log file each time a new gdb.in.NUM command log
> is started.  The gdb.log line includes the full filename for the new
> gdb.in.NUM file.
> 
> This change will make it trivial to go from a FAIL in the gdb.log file
> to the gdb.in.NUM file that (should) reproduce the failure.  When I
> encounter a failing test one of my first steps is usually to identify
> the gdb.in.NUM file and try re-running it to see if that reproduces
> the failure.  Some test create many very similar gdb.in.NUM files, so
> finding the exact one can sometimes be difficult.  With this patch
> that task is now trivial.
> 
> There should be no change in what is tested after this commit.
> ---
>  gdb/testsuite/lib/gdb.exp | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/gdb/testsuite/lib/gdb.exp b/gdb/testsuite/lib/gdb.exp
> index 777d64d14d1..78356bf51f0 100644
> --- a/gdb/testsuite/lib/gdb.exp
> +++ b/gdb/testsuite/lib/gdb.exp
> @@ -9990,6 +9990,10 @@ proc gdb_stdin_log_init { } {
>  
>      set logfile [standard_output_file_with_gdb_instance gdb.in]
>      set in_file [open $logfile w]
> +
> +    verbose -log ""
> +    verbose -log "Starting logfile: $logfile"
> +    verbose -log ""
>  }
>  
>  # Write to the file for logging gdb input.
> 
> base-commit: 1edefea39ff27ed2d4aed4e45ed416f3fbaf6098

Sounds like a good idea to me.

Approved-By: Simon Marchi <simon.marchi@efficios.com>

Simon

  reply	other threads:[~2025-07-16 18:19 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-16 18:12 Andrew Burgess
2025-07-16 18:19 ` Simon Marchi [this message]
2025-07-18 10:26   ` Andrew Burgess

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=47c67727-2c45-403d-9a72-4d38eb4062e1@simark.ca \
    --to=simark@simark.ca \
    --cc=aburgess@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