From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id GP1IGourTWESNAAAWB0awg (envelope-from ) for ; Fri, 24 Sep 2021 06:42:19 -0400 Received: by simark.ca (Postfix, from userid 112) id 693951EE25; Fri, 24 Sep 2021 06:42:19 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,MAILING_LIST_MULTI,RDNS_DYNAMIC,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 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 CCF011EDDB for ; Fri, 24 Sep 2021 06:42:18 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 85A7E3857829 for ; Fri, 24 Sep 2021 10:42:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 85A7E3857829 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1632480138; bh=J/Fl1owHrN/Af+ZERvSQ08bbtphQaxO6mnTdl+duw70=; h=Date:To:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=tMlFyVEdW+Ota36iw3IMyJybVdoA+xlGdwHr6Jp2Tkw80Aq/uLK9OAtQZ6ZsCji/+ Q5wuBlQivjxuRcxwkVG/Du+k7Nh1iMA2o/xo/rYtzWMKUjN2yPA5YjJIePLww3Fgpj Ka78W80to2sWrWCAcZy2zzEPSTIx489TzwFGGJ+Q= Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id 510CA385842B for ; Fri, 24 Sep 2021 10:41:25 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 510CA385842B 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-out2.suse.de (Postfix) with ESMTPS id 82BB61FFE5 for ; Fri, 24 Sep 2021 10:41:24 +0000 (UTC) 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 67ED113B66 for ; Fri, 24 Sep 2021 10:41:24 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id 0ctYGFSrTWFTWAAAMHmgww (envelope-from ) for ; Fri, 24 Sep 2021 10:41:24 +0000 Date: Fri, 24 Sep 2021 12:41:22 +0200 To: gdb-patches@sourceware.org Subject: [committed][gdb/testsuite] Fix DUPLICATEs in gdb.dwarf2/implptr-64bit.exp Message-ID: <20210924104121.GA1592@delia> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) 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: Tom de Vries via Gdb-patches Reply-To: Tom de Vries Errors-To: gdb-patches-bounces+public-inbox=simark.ca@sourceware.org Sender: "Gdb-patches" Hi, When running test-case gdb.dwarf2/implptr-64bit.exp with target board unix/-m32, I noticed: ... DUPLICATE: gdb.dwarf2/implptr-64bit.exp: failed to prepare ... Fix this by using with_test_prefix. Tested on x86_64-linux. Committed to trunk. Thanks, - Tom [gdb/testsuite] Fix DUPLICATEs in gdb.dwarf2/implptr-64bit.exp --- gdb/testsuite/gdb.dwarf2/implptr-64bit.exp | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/gdb/testsuite/gdb.dwarf2/implptr-64bit.exp b/gdb/testsuite/gdb.dwarf2/implptr-64bit.exp index 03bf8c8977e..19f5ecb7929 100644 --- a/gdb/testsuite/gdb.dwarf2/implptr-64bit.exp +++ b/gdb/testsuite/gdb.dwarf2/implptr-64bit.exp @@ -21,11 +21,9 @@ if {![dwarf2_support]} { standard_testfile main.c -proc test { dwarf_version offset_size addr_size ref_addr_size two_cu } { +proc test_1 { name dwarf_version offset_size addr_size ref_addr_size two_cu } { global testfile srcfile - set name "d${dwarf_version}o${offset_size}a${addr_size}r${ref_addr_size}t${two_cu}" - # Make some DWARF for the test. set asm_file [standard_output_file ${testfile}-${name}.S] Dwarf::assemble $asm_file { @@ -137,7 +135,23 @@ proc test { dwarf_version offset_size addr_size ref_addr_size two_cu } { return -1 } - gdb_test "p/x p->f" " = 0x1010101" $name + gdb_test "p/x p->f" " = 0x1010101" +} + +proc test { dwarf_version offset_size addr_size ref_addr_size two_cu } { + + set name \ + [list \ + "d${dwarf_version}" \ + "o${offset_size}" \ + "a${addr_size}" \ + "r${ref_addr_size}" \ + "t${two_cu}"] + set name [join $name "-"] + with_test_prefix $name { + test_1 $name \ + $dwarf_version $offset_size $addr_size $ref_addr_size $two_cu + } } # DWARF_VERSION OFFSET_SIZE ADDR_SIZE REF_ADDR_SIZE TWO_CU