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 8842A3858D35 for ; Fri, 24 Mar 2023 14:17:35 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8842A3858D35 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 32OEHU9E024497 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Fri, 24 Mar 2023 10:17:34 -0400 DKIM-Filter: OpenDKIM Filter v2.11.0 smtp.polymtl.ca 32OEHU9E024497 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=polymtl.ca; s=default; t=1679667455; bh=SdZim3yDcWwdFZ1MMxLqrfm0zk4KSX74KG7lBiV5YJ4=; h=Date:Subject:To:References:From:In-Reply-To:From; b=U2i9xX1BZScPRPQVpomtq5UxseRPQL036S58tSi/B1+RJInVJfiQ7S2L+Tzodve06 rweo1Sl8hGqniRBLrrDDSxgHxPyaZpMYkDUR5BpnZaNgUfMCZnC9ag+i8wqFGy2N68 7K024IfBR3oz0luBMAr4AiCMYaFKtE9c//3WXG0U= Received: from [172.16.42.115] (modemcable092.73-163-184.mc.videotron.ca [184.163.73.92]) (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 04DF71E0D3; Fri, 24 Mar 2023 10:17:29 -0400 (EDT) Message-ID: Date: Fri, 24 Mar 2023 10:17:29 -0400 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH] [gdb/testsuite] Fix gdb.cp/m-static.exp regression on Ubuntu 20.04 Content-Language: fr To: Tom de Vries , gdb-patches@sourceware.org References: <20230323134716.2853-1-tdevries@suse.de> From: Simon Marchi In-Reply-To: <20230323134716.2853-1-tdevries@suse.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Poly-FromMTA: (simark.ca [158.69.221.121]) at Fri, 24 Mar 2023 14:17:30 +0000 X-Spam-Status: No, score=-3031.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,KAM_NUMSUBJECT,NICE_REPLY_A,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=no 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 3/23/23 09:47, Tom de Vries wrote: > In commit 722c4596034 ("[gdb/testsuite] Fix gdb.cp/*.exp for remote host"), I > needed to change ".*/" into "(.*/)?" in: > ... > gdb_test "info variable everywhere" \ > "File .*/m-static\[.\]h.*const int gnu_obj_4::everywhere;" > ... > > However, due to that fact that I got this output: > ... > (gdb) info variable everywhere^M > All variables matching regular expression "everywhere":^M > ^M > File /data/vries/gdb/src/gdb/testsuite/gdb.cp/m-static.h:^M > 8: const int gnu_obj_4::everywhere;^M > ^M > File /data/vries/gdb/src/gdb/testsuite/gdb.cp/m-static1.cc:^M > 8: const int gnu_obj_4::everywhere;^M > ... > I decided to make the matching somewhat stricter, to make sure that the two > matched lines were subsequent. > > The commit turned out to be more strict than intended, and caused a regression > on Ubuntu 20.04, where the output was instead: > ... > (gdb) info variable everywhere^M > All variables matching regular expression "everywhere":^M > ^M > File /data/vries/gdb/src/gdb/testsuite/gdb.cp/m-static.h:^M > 8: const int gnu_obj_4::everywhere;^M > ... > > At that point I realized I'm looking at a bug (filed as PR symtab/30265), > which manifests on openSUSE Leap 15.4 for native and readnow, and on Ubuntu > 20.04 for readnow, but not for native. > > Before my commit, the test-case passed whether the bug manifested or not. > > After my commit, the test-case only passed when the bug manifested. > > Fix the test-case regression by reverting to the situation before the commit: > pass whether the bug manifests or not. We could add an xfail for the PR, but > I'm expecting a fix soon, so that doesn't look worth the effort. > > Tested on x86_64-linux, both on openSUSE Leap 15.4 and Ubuntu 20.04, both with > native and readnow. > > Reported-By: Simon Marchi For those wondering, this is already pushed :) Simon