From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id JDOJBHYBwmMnXxYAWB0awg (envelope-from ) for ; Fri, 13 Jan 2023 20:12:22 -0500 Received: by simark.ca (Postfix, from userid 112) id 047061E128; Fri, 13 Jan 2023 20:12:22 -0500 (EST) Authentication-Results: simark.ca; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=irqmKr2Y; dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-8.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,NICE_REPLY_A, RCVD_IN_DNSWL_HI,RDNS_DYNAMIC,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from sourceware.org (ip-8-43-85-97.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id A83AA1E110 for ; Fri, 13 Jan 2023 20:12:21 -0500 (EST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id F37AA38425A5 for ; Sat, 14 Jan 2023 01:12:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org F37AA38425A5 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1673658740; bh=pCONYA3/eqPu/c1TYRVj0COpX6NI/8lY/WMzcZtwwug=; h=Date:Subject:To:Cc:References:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=irqmKr2YUNeLnuAUsX3/OH858bm4yGq29YN7E+H2Xo2oy0ph+bK+GZupkbzEGOQP3 u76NLvAfF9vglMQin7g2wjbDYgKtHoZZ7y5EuRSasfnCtCMTNCgnaNqlDfVH+ifRDU 4s4l+KT7ib2qMfburFuak3/eCCwLlqHqsZLJEMLk= Received: from simark.ca (simark.ca [158.69.221.121]) by sourceware.org (Postfix) with ESMTPS id 91C9D3858C50 for ; Sat, 14 Jan 2023 01:11:49 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 91C9D3858C50 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) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPSA id D6EFF1E110; Fri, 13 Jan 2023 20:11:47 -0500 (EST) Message-ID: <94f1db30-8514-3bed-3539-142ac2690187@simark.ca> Date: Fri, 13 Jan 2023 20:11:47 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [PATCH] Handle SIGSEGV in gdb selftests Content-Language: en-US To: tdevries , Tom Tromey Cc: gdb-patches@sourceware.org References: <20221215211442.2515108-1-tromey@adacore.com> <7fca4280-a259-9785-fdd1-ac802b886804@suse.de> <87pmcjba6j.fsf@tromey.com> <375589413f851bebcc3b1256273ab784@suse.de> In-Reply-To: <375589413f851bebcc3b1256273ab784@suse.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Simon Marchi via Gdb-patches Reply-To: Simon Marchi Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" On 12/26/22 03:02, tdevries via Gdb-patches wrote: > On 2022-12-16 16:11, Tom Tromey via Gdb-patches wrote: >>>>>>> "Tom" == Tom de Vries writes: >> >> Tom> 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. >>>> >> >> Tom> FWIW, that's https://sourceware.org/bugzilla/show_bug.cgi?id=29325 . >> >> Thanks, I updated the commit message. > > I ran into this again, tried out the patch and checked that it fixes the problem. > > LGTM. > > Thanks, > - Tom Hi both Toms, I still see the issue on Ubuntu 22.04, when testing with the native-extended-gdbserver board: ... Thread 1 "xgdb" received signal SIGSEGV, Segmentation fault. 0x00007ffff6d828f2 in GC_find_limit_with_bound () from /usr/lib/x86_64-linux-gnu/libgc.so.1 (gdb) FAIL: gdb.gdb/selftest.exp: xgdb is at prompt The modified code looks like this: 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 } } Shouldn't the SIGSEGV -re be before the `-i $inferior_spawn_id`? Otherwise we expect the "received signal SIGSEGV" message to come from the debugged GDB, when it's the top GDB that will print it (like when debugging any other test program). I think we don't see the problem when testing with native because the top and bottom GDBs share the same spawn id. Simon