public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
From: Simon Marchi <simon.marchi@polymtl.ca>
To: Bruno Larsen <blarsen@redhat.com>, gdb-patches@sourceware.org
Subject: Re: [PATCH] gdb/testsuite: fail if gdb_start_cmd fails
Date: Mon, 28 Nov 2022 09:40:52 -0500	[thread overview]
Message-ID: <248277d8-c79d-49fe-33e7-46c12b2b4077@polymtl.ca> (raw)
In-Reply-To: <e71c266f-5b2f-d1cf-592e-e54c41b5687b@redhat.com>



On 11/28/22 05:51, Bruno Larsen wrote:
> On 18/11/2022 17:06, Simon Marchi via Gdb-patches wrote:
>> I broke gdb.ada/start.exp, and did not notice it, because it outputs an
>> UNTESTED if gdb_start_cmd fails.  I don't really see when start would
>> fail and it's not a problem that should be looked at.  Change all spots
>> that call untested after a gdb_start_cmd failure, use fail instead.
>>
>> Doing so caused some failures with the native-gdbserver board.  Some
>> tests that use "start" were relying on the fact that start would fail
>> with that board to just return with "untested".  Change them to add an
>> early return if use_gdb_stub returns true.
>>
>> Some gdb.pascal tests also failed with native-gdbserver, because they
>> did use gdb_start_cmd to start the inferior, for no good reason.
>> Convert them to use runto_main instead, which does the right thing if
>> the target is a stub.
>>
>> A further refactoring could be to make gdb_start_cmd match the expected
>> breakpoint hit and the prompt, which it doesn't do currently (it leaves
>> that to the callers, but not all of them do).
>>
>> Change-Id: I097370851213e798ff29fb6cf8ba25ef7d2be007
> 
> Hi Simon,
> 
> This patch makes sense to me, and testing shows no regressions.
> 
> Reviewed-By: Bruno Larsen <blarsen@redhat.com>

Thanks to you and Andrew, will push.

Simon

  reply	other threads:[~2022-11-28 14:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-18 16:06 Simon Marchi
2022-11-28 10:51 ` Bruno Larsen
2022-11-28 14:40   ` Simon Marchi [this message]
2022-11-28 14:34 ` 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=248277d8-c79d-49fe-33e7-46c12b2b4077@polymtl.ca \
    --to=simon.marchi@polymtl.ca \
    --cc=blarsen@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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).