From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 67130 invoked by alias); 31 Oct 2017 09:57:36 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 66994 invoked by uid 89); 31 Oct 2017 09:57:36 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=HTo:D*cavium.com X-HELO: foss.arm.com Received: from foss.arm.com (HELO foss.arm.com) (217.140.101.70) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 31 Oct 2017 09:57:35 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 9CB791529; Tue, 31 Oct 2017 02:57:32 -0700 (PDT) Received: from [192.168.1.19] (usa-sjc-mx-foss1.foss.arm.com [217.140.101.70]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 5127C3F24A; Tue, 31 Oct 2017 02:57:31 -0700 (PDT) Subject: Re: [PATCH PR79868 ][aarch64] Fix error calls in aarch64 code so they can be translated (version 2) To: sellcey@cavium.com, gcc-patches , Martin Sebor , fmarchal , "roland.illig" References: <1506381921.18449.22.camel@cavium.com> <1509396631.10159.88.camel@cavium.com> From: "Richard Earnshaw (lists)" Message-ID: <275df400-3dd4-aa10-2905-446ca8bab92c@arm.com> Date: Tue, 31 Oct 2017 10:26:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0 MIME-Version: 1.0 In-Reply-To: <1509396631.10159.88.camel@cavium.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-SW-Source: 2017-10/txt/msg02295.txt.bz2 On 30/10/17 20:50, Steve Ellcey wrote: > On Thu, 2017-10-26 at 13:56 +0100, Richard Earnshaw (lists) wrote: >>   >> I can't help feeling that all this logic is somewhat excessive and >> changing the wording of each message to include "pragma or attribute" >> would solve it equally well.  With the new context highlighting it's >> trivial to tell which subcase of usage is being referred to. >> >> R. > > I have no problem with that.  Here is a version that uses "pragma or > attribute". > > Tested on ToT with no regressions.  Ok to checkin? > > Steve Ellcey > sellcey@cavium.com > > > > ChangeLog: > > 2017-10-30  Steve Ellcey   > > PR target/79868 > * config/aarch64/aarch64-c.c (aarch64_pragma_target_parse): > Remove second argument from aarch64_process_target_attr call. > * config/aarch64/aarch64-protos.h (aarch64_process_target_attr): > Ditto. > * config/aarch64/aarch64.c (aarch64_attribute_info): Change > field type. > (aarch64_handle_attr_arch): Remove second argument. > (aarch64_handle_attr_cpu): Ditto. > (aarch64_handle_attr_tune): Ditto. > (aarch64_handle_attr_isa_flags): Ditto. > (aarch64_process_one_target_attr): Ditto. > (aarch64_process_target_attr): Ditto. > (aarch64_option_valid_attribute_p): Remove second argument. > on aarch64_process_target_attr call. > > > Testsuite ChangeLog: > > 2017-10-30  Steve Ellcey   > > PR target/79868 > * gcc.target/aarch64/spellcheck_1.c: Update dg-error string to match > new format. > * gcc.target/aarch64/spellcheck_2.c: Ditto. > * gcc.target/aarch64/spellcheck_3.c: Ditto. > * gcc.target/aarch64/target_attr_11.c: Ditto. > * gcc.target/aarch64/target_attr_12.c: Ditto. > * gcc.target/aarch64/target_attr_17.c: Ditto. > This is looking better... I may have missed some discussion on this topic, but what's the reasoning behind changing the quoting around the 'str' parameter value in - error ("unknown value %qs for 'cpu' target %s", str, pragma_or_attr); + error ("invalid name (\"%s\") in % pragma or attribute", str); And also with the new generic message does the % still make sense? My feeling is that the original text here is perhaps more appropriate. Similarly for other messages. R.