From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 121230 invoked by alias); 25 Nov 2016 17:48:29 -0000 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 Received: (qmail 121097 invoked by uid 89); 25 Nov 2016 17:48:24 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.2 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_SOFTFAIL autolearn=no version=3.3.2 spammy=HX-PHP-Originating-Script:rcube.php X-HELO: simark.ca Received: from simark.ca (HELO simark.ca) (158.69.221.121) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 25 Nov 2016 17:48:22 +0000 Received: by simark.ca (Postfix, from userid 33) id 6D0B41E13C; Fri, 25 Nov 2016 12:48:21 -0500 (EST) To: Luis Machado Subject: Re: [PATCH 1/8] Fixup testcases outputting own name as a test name X-PHP-Originating-Script: 33:rcube.php MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Fri, 25 Nov 2016 17:48:00 -0000 From: Simon Marchi Cc: Pedro Alves , gdb-patches@sourceware.org In-Reply-To: <2b7ca30d-f563-dd11-7934-60505d261a24@codesourcery.com> References: <1480093744-13771-1-git-send-email-lgustavo@codesourcery.com> <1480093744-13771-2-git-send-email-lgustavo@codesourcery.com> <2b7ca30d-f563-dd11-7934-60505d261a24@codesourcery.com> Message-ID: <5cfc70b2ea19762c664d61f752c02a41@polymtl.ca> X-Sender: simon.marchi@polymtl.ca User-Agent: Roundcube Webmail/1.2.2 X-IsSubscribed: yes X-SW-Source: 2016-11/txt/msg00826.txt.bz2 On 2016-11-25 12:37, Luis Machado wrote: >> I think all these references to $binfile will put the full file >> path on gdb.sum? I think you want $testfile instead. >> >> Thanks, >> Pedro Alves >> > > They will, which may make it easier to just build the files by hand > with the output from the log file. But it has the potential to be a > big path. > > I'm fine with either approach. I think it's fine how you did in the patch. Most of the time, binfile is based on testfile, so Pedro's suggestion would work. But sometimes, we pass something else than binfile as the compilation destination (or binfile was overrident), so we would have to remember to use something else than testfile to build the error message, it seems easy to forget. I think that consistently using the same expression as is passed to gdb_compile's dest parameter is a good approach. Or maybe the error should be handled in gdb_compile instead of in each individual test, that would be even less error-prone. Of course, that doesn't hold if the issue about having the full paths in the test message is about the reproducibility (test names will have different names depending on the path where you build gdb). But since it's only for error test names, I don't know if that's a real problem.