From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 28431 invoked by alias); 21 Feb 2012 19:54:26 -0000 Received: (qmail 28420 invoked by uid 22791); 21 Feb 2012 19:54:25 -0000 X-SWARE-Spam-Status: No, hits=-6.8 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 21 Feb 2012 19:54:07 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q1LJrxi8006683 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 21 Feb 2012 14:54:07 -0500 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id q1LIbEHt016415; Tue, 21 Feb 2012 13:37:14 -0500 Message-ID: <4F43E459.9070706@redhat.com> Date: Tue, 21 Feb 2012 20:08:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0) Gecko/20120131 Thunderbird/10.0 MIME-Version: 1.0 To: Tom Tromey CC: gdb-patches@sourceware.org, jan.kratochvil@redhat.com Subject: Re: testsuite: prefix handling References: <20120217193546.10029.74207.stgit@hit-nxdomain.opendns.com> <20120217193648.10029.26589.stgit@hit-nxdomain.opendns.com> <87pqdd9pjs.fsf@fleche.redhat.com> <4F3EBEAC.1070805@redhat.com> <87k43l87vb.fsf@fleche.redhat.com> <4F43B6A5.3010900@redhat.com> <87wr7gt63r.fsf@fleche.redhat.com> In-Reply-To: <87wr7gt63r.fsf@fleche.redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-02/txt/msg00448.txt.bz2 On 02/21/2012 06:05 PM, Tom Tromey wrote: > > Pedro> Only a few tests weren't converted to use with_test_prefix by this > Pedro> patch. Those are ones that I found that: > > Pedro> - would require a large reindent > Pedro> - or with_test_prefix wasn't a 1-1 replacement > > I don't mind large reindents in a situation like this. > I think the resulting code would be better. > It is up to you, though; I also don't mind the status quo. I really dislike mixing in a lot of formatting changes with code changes, so I was really avoiding it. It's a harder patch to read/prove right, and a harder patch to maintain as well. If someone sent me over this change mixed in with a lots of reindents, and hadn't at least sent me a -W diff, I'd groan. :-) We can always do a "reindent" patch as follow up, perhaps even as multiple patches. > > Pedro> WDYT? > > Pedro> -proc altivec_abi_tests { extra_flags force_abi } { > Pedro> +proc altivec_abi_tests { prefix extra_flags force_abi } { with_test_prefix $prefix { > [...] > Pedro> +}} > > I think newlines and reindentation would result in prettier code. Honestly, I kind of liked the current formatting -- I was kind of reading it as a function attribute. But I don't mind seeing this re-indented either. But that's a lower priority to me. > Pedro> - altivec_abi_tests "additional_flags=-maltivec" "auto" > Pedro> + altivec_abi_tests " default ABI, auto:" "additional_flags=-maltivec" "auto" > > It would be both prettier and better encapsulation if with_test_prefix > supplied the space. Thing is I stumbled on tests that don't currently output a space. So I'm not sure we should always require spaces. Changing those would make this patch not an identity patch -- it'd produce different gdb.sum output compared to the current mainline. I can try making with_test_prefix always add the space instead as follow up, and see which tests are those, and if we'd get something non-sensical. Probably not. > > Pedro> +# Test files shall make sure all the test result lines in gdb.sum are > Pedro> +# unique in a test run, so that comparing the gdb.sum files of two > Pedro> +# test runs gives correct results. Test files that exercise > Pedro> +# variations of the same tests more than once, shall prefix the > Pedro> +# different test invocations with different identifying strings in > Pedro> +# order to make them unique. > [...] > > I love the comment. :-) -- Pedro Alves