From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.polymtl.ca (smtp.polymtl.ca [132.207.4.11]) by sourceware.org (Postfix) with ESMTPS id 316583845195 for ; Mon, 28 Nov 2022 14:40:59 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 316583845195 Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=polymtl.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=polymtl.ca Received: from simark.ca (simark.ca [158.69.221.121]) (authenticated bits=0) by smtp.polymtl.ca (8.14.7/8.14.7) with ESMTP id 2ASEeq8M028468 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 28 Nov 2022 09:40:57 -0500 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp.polymtl.ca 2ASEeq8M028468 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=polymtl.ca; s=default; t=1669646457; bh=+I37l8/0dfHhMMjY6GX1cJt/emU5IT+jG02NHvgcCfI=; h=Date:Subject:To:References:From:In-Reply-To:From; b=W4F/eAJ+QuiPF1tI0LPRJK8LcVVqPRtRVIghvKVH2594pNpxxXW3RAz4HEGyC6ff9 LTyVOdhCKvi/Ch0AL74nlBiCaGjIsR3+nS7JwDxXWpY85mkHgrECHxDOz6IU3L3qAH 2NhyL4kH4cTSVC54WtpIS81RRhkfSD6huYAWYyFM= Received: from [10.0.0.11] (unknown [217.28.27.60]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id 737EF1E0CB; Mon, 28 Nov 2022 09:40:52 -0500 (EST) Message-ID: <248277d8-c79d-49fe-33e7-46c12b2b4077@polymtl.ca> Date: Mon, 28 Nov 2022 09:40:52 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Subject: Re: [PATCH] gdb/testsuite: fail if gdb_start_cmd fails Content-Language: en-US To: Bruno Larsen , gdb-patches@sourceware.org References: <20221118160647.912966-1-simon.marchi@polymtl.ca> From: Simon Marchi In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Poly-FromMTA: (simark.ca [158.69.221.121]) at Mon, 28 Nov 2022 14:40:52 +0000 X-Spam-Status: No, score=-3032.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: 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 Thanks to you and Andrew, will push. Simon