From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out1.suse.de (smtp-out1.suse.de [IPv6:2001:67c:2178:6::1c]) by sourceware.org (Postfix) with ESMTPS id 65F0138518A3 for ; Fri, 16 Dec 2022 15:17:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 65F0138518A3 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 9958C3438C; Fri, 16 Dec 2022 15:17:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1671203849; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=GV6BfTr69XsbvUqLEhMA3vrA21WyCXNHzPPZraRlXIk=; b=PdUUpk1RjxwhyxMDLYuWI8iEO8o1+cLrZ+FTukSNBhK1Stkc7CNi9wfRGUjPB0tt7u0b5n YoaV/VNCRoZTsyMEWJVwikV1C8Ckpaw/0EmQs4vltYkTmbXf3XjDp/4xIUxGlivmDgDkuN H0MopFylhMUDwkh4ECZyPZoAMinZyeY= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1671203849; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=GV6BfTr69XsbvUqLEhMA3vrA21WyCXNHzPPZraRlXIk=; b=I4lYMAkIdToQh095QqEP0/Rzr+UH6WE7E+ReRKubG8FhSwfjZMAstG1RH9u9jjQfyB+buF tCB2tCboVGC3uTDQ== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 84BFC138FD; Fri, 16 Dec 2022 15:17:29 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 1HQ5HwmMnGPcAwAAMHmgww (envelope-from ); Fri, 16 Dec 2022 15:17:29 +0000 Message-ID: <7fca4280-a259-9785-fdd1-ac802b886804@suse.de> Date: Fri, 16 Dec 2022 16:17:29 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.1 Subject: Re: [PATCH] Handle SIGSEGV in gdb selftests Content-Language: en-US To: Tom Tromey , gdb-patches@sourceware.org References: <20221215211442.2515108-1-tromey@adacore.com> From: Tom de Vries In-Reply-To: <20221215211442.2515108-1-tromey@adacore.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-12.5 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,NICE_REPLY_A,SPF_HELO_NONE,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 12/15/22 22:14, Tom Tromey via Gdb-patches wrote: > The gdb.gdb self-tests were timing out for me. Looking into it, the > problem is that the version of the Boehm GC that is used by Guile on > my machine causes a SEGV during stack probing. This unexpected stop > confuses the tests and causes repeated timeouts. > FWIW, that's https://sourceware.org/bugzilla/show_bug.cgi?id=29325 . Thanks, - Tom > This patch adapts the two failing tests. This makes them work for me, > and reduces the running time of gdb.gdb from 20 minutes to about 11 > seconds. > --- > gdb/testsuite/gdb.gdb/python-helper.exp | 6 ++++++ > gdb/testsuite/gdb.gdb/selftest.exp | 6 ++++++ > 2 files changed, 12 insertions(+) > > diff --git a/gdb/testsuite/gdb.gdb/python-helper.exp b/gdb/testsuite/gdb.gdb/python-helper.exp > index 3585ac9f0bf..fc52929489e 100644 > --- a/gdb/testsuite/gdb.gdb/python-helper.exp > +++ b/gdb/testsuite/gdb.gdb/python-helper.exp > @@ -93,6 +93,12 @@ proc test_python_helper {} { > # here. > gdb_test_multiple "continue" "start inner gdb" { > -i "$inferior_spawn_id" > + -re "received signal SIGSEGV.* in GC_.*$outer_prompt_re" { > + # Some versions of the GC used by Guile cause a SEGV > + # during stack probing. Ignore this and carry on. > + send_gdb "continue\n" > + exp_continue > + } > -re "\r\n$gdb_prompt $" { > pass $gdb_test_name > } > diff --git a/gdb/testsuite/gdb.gdb/selftest.exp b/gdb/testsuite/gdb.gdb/selftest.exp > index ca1e7cffb4e..e2b9247f65d 100644 > --- a/gdb/testsuite/gdb.gdb/selftest.exp > +++ b/gdb/testsuite/gdb.gdb/selftest.exp > @@ -75,6 +75,12 @@ proc test_with_self { } { > set test "xgdb is at prompt" > gdb_test_multiple "continue" $test { > -i "$inferior_spawn_id" > + -re "received signal SIGSEGV.* in GC_.*$gdb_prompt" { > + # Some versions of the GC used by Guile cause a SEGV > + # during stack probing. Ignore this and carry on. > + send_gdb "continue\n" > + exp_continue > + } > -re "$banner" { > pass $test > }