From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by sourceware.org (Postfix) with ESMTPS id 9CBE03858403 for ; Fri, 2 Feb 2024 12:05:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 9CBE03858403 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 9CBE03858403 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=195.135.223.131 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706875513; cv=none; b=AYWWt7d7GQ55iixOlZ062IX0vyDKlpWzyefZZxptfDWNIKKtNIyqt7TyjoM4CQ7tn3QsLWLZXkfuwsC16aMeK4Qdw7qWpo8EUH3NwElkZHHuzlw1moC886jV3Otnog2MRbnqoPQXwjMo7raOR7M6lrp18E48zktvzGbo2zxqIdA= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1706875513; c=relaxed/simple; bh=FtPWn6qANsquYaYZFicvX71m9M1MmmlQ4j1Q71q6KIQ=; h=DKIM-Signature:DKIM-Signature:DKIM-Signature:DKIM-Signature: Message-ID:Date:MIME-Version:Subject:To:From; b=cd7/U4UkGw1vx1SBmyM1iEsX/45p/PlG8lHT1jnFeWzpW43DkR17UGPYNjxH+d/886sv0YCcEs6CNvjAzeaP9+HA8qbl+/xzW8JdVv5BJtrxOqjorHg/JqB8XamtTFDQ4/rqeUw69BNWvxVCtFoa1FDRGUpk8ZpLebwziMNDEDs= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [10.150.64.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 933A81F770; Fri, 2 Feb 2024 12:05:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1706875510; 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=4eRzYv5rwpes9koxSnB14m5rzUKO8B+zm5OWaYwaPRQ=; b=hiz7dZw6qJKDUbYM7Wqi/GWSiEBE2mzKBQBVbUt1+vai0okWXKt+F6/5ZgNFxCksCGr2p8 kpnhLvQY3MTWj2Wxxt93MB9M2AoE7mohXqqhDJ0QWeRDb1PUQGNow9ICXCIvi4iOG/SRjO KHczBOKxDc/NARFoAKmaT4uojwmB8d4= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1706875510; 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=4eRzYv5rwpes9koxSnB14m5rzUKO8B+zm5OWaYwaPRQ=; b=gsk8EKkDQlGfCx3ZWrutVmcY/ijUsWZ6Yqt+OkiPgYltbflvXgDeUJYAl1GDD2zHEsLmmc eJZgrvsUAJU1CIDw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1706875510; 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=4eRzYv5rwpes9koxSnB14m5rzUKO8B+zm5OWaYwaPRQ=; b=hiz7dZw6qJKDUbYM7Wqi/GWSiEBE2mzKBQBVbUt1+vai0okWXKt+F6/5ZgNFxCksCGr2p8 kpnhLvQY3MTWj2Wxxt93MB9M2AoE7mohXqqhDJ0QWeRDb1PUQGNow9ICXCIvi4iOG/SRjO KHczBOKxDc/NARFoAKmaT4uojwmB8d4= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1706875510; 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=4eRzYv5rwpes9koxSnB14m5rzUKO8B+zm5OWaYwaPRQ=; b=gsk8EKkDQlGfCx3ZWrutVmcY/ijUsWZ6Yqt+OkiPgYltbflvXgDeUJYAl1GDD2zHEsLmmc eJZgrvsUAJU1CIDw== Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 747F513A58; Fri, 2 Feb 2024 12:05:10 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap1.dmz-prg2.suse.org with ESMTPSA id GgBqGnbavGWQeQAAD6G6ig (envelope-from ); Fri, 02 Feb 2024 12:05:10 +0000 Message-ID: <1cd08bde-4ac7-4918-b2df-9db9d6d4b6e3@suse.de> Date: Fri, 2 Feb 2024 13:04:58 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 1/2] gdb/testsuite: fix gdb.threads/threadcrash.exp on 32-bit arm targets Content-Language: en-US To: Guinevere Larsen , gdb-patches@sourceware.org References: <20240201155812.1189388-2-blarsen@redhat.com> <20240201155812.1189388-3-blarsen@redhat.com> From: Tom de Vries In-Reply-To: <20240201155812.1189388-3-blarsen@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Authentication-Results: smtp-out2.suse.de; none X-Spam-Level: X-Spam-Score: -1.30 X-Spamd-Result: default: False [-1.30 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; XM_UA_NO_VERSION(0.01)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; BAYES_HAM(-0.01)[47.13%]; MIME_GOOD(-0.10)[text/plain]; URIBL_BLOCKED(0.00)[sourceware.org:url]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.de:s=susede2_rsa,suse.de:s=susede2_ed25519]; NEURAL_HAM_SHORT(-0.20)[-1.000]; RCPT_COUNT_TWO(0.00)[2]; DBL_BLOCKED_OPENRESOLVER(0.00)[sourceware.org:url]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[]; MID_RHS_MATCH_FROM(0.00)[] X-Spam-Status: No, score=-12.3 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,SPF_HELO_NONE,SPF_PASS,TXREP,T_SCC_BODY_TEXT_LINE 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 2/1/24 16:58, Guinevere Larsen wrote: > There are 2 issues with the test gdb.threads/threadcrash.exp on arm > targets, both relating to issues in how the targets handles gcores. The > first is that the test fails to cout the number of threads in the > inferior and the second is that GDB can't properly backtrace from a > gcore. > > The first error is fixed on this commit by getting the convenience > variable _inferior_thread_count as opposed to calculating it based on > the output of "info threads" > > For the second, this test just emits a single xfail referring back to PR > corefiles/31294, which tracks the issues with gcores in 32-bit arm > targets. > Hi Guinevere, the fact that the PR has the corefiles component suggests that there's a problem with gdb, which means a kfail should be used. An xfail is used to indicate problems in the environment (meaning external to gdb), like a known problem in the linux kernel, or incorrect debug info generated by the compiler, etc. Thanks, - Tom > Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31294 > --- > gdb/testsuite/gdb.threads/threadcrash.exp | 15 ++++++++------- > 1 file changed, 8 insertions(+), 7 deletions(-) > > diff --git a/gdb/testsuite/gdb.threads/threadcrash.exp b/gdb/testsuite/gdb.threads/threadcrash.exp > index d3e3494cbea..362c4c5879d 100644 > --- a/gdb/testsuite/gdb.threads/threadcrash.exp > +++ b/gdb/testsuite/gdb.threads/threadcrash.exp > @@ -27,12 +27,9 @@ > proc test_thread_count {} { > set thread_count 0 > > - gdb_test_multiple "info threads" "getting thread count" -lbl { > - -re "\(Thread\|LWP\)" { > - incr thread_count > - exp_continue > - } > - -re "$::gdb_prompt " { > + gdb_test_multiple "print \$_inferior_thread_count" "getting thread count" { > + -re ".* = (\[0-9]+).*" { > + set thread_count $expect_out(1,string) > gdb_assert {$thread_count == 7} > } > } > @@ -230,4 +227,8 @@ test_live_inferior > > test_corefile > > -test_gcore > +if { [is_aarch32_target] } { > + xfail "gcore tests fail on 32-bit arm, see PR corefiles/31294" > +} else { > + test_gcore > +}