From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7390 invoked by alias); 3 Feb 2015 19:10:46 -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 7372 invoked by uid 89); 3 Feb 2015 19:10:45 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.4 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS,T_RP_MATCHES_RCVD autolearn=unavailable version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Tue, 03 Feb 2015 19:10:43 +0000 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t13JAb9c017289 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Tue, 3 Feb 2015 14:10:37 -0500 Received: from bordewijk.wildebeest.org (ovpn-116-48.ams2.redhat.com [10.36.116.48]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t13JAZsL015859 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Tue, 3 Feb 2015 14:10:36 -0500 Received: by bordewijk.wildebeest.org (Postfix, from userid 1000) id 310E781A1818; Tue, 3 Feb 2015 20:10:35 +0100 (CET) Message-ID: <1422990635.4947.29.camel@bordewijk.wildebeest.org> Subject: Re: [patch+7.9] compile: Filter out -fpreprocessed From: Mark Wielaard To: Jan Kratochvil Cc: Doug Evans , gdb-patches , gcc-patches@gcc.gnu.org Date: Tue, 03 Feb 2015 19:10:00 -0000 In-Reply-To: <20150203185912.GA26920@host1.jankratochvil.net> References: <20150116224234.GA6176@host2.jankratochvil.net> <20150203185912.GA26920@host1.jankratochvil.net> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 X-SW-Source: 2015-02/txt/msg00062.txt.bz2 On Tue, 2015-02-03 at 19:59 +0100, Jan Kratochvil wrote: > On Tue, 03 Feb 2015 19:50:40 +0100, Doug Evans wrote: > > On Fri, Jan 16, 2015 at 2:42 PM, Jan Kratochvil > > wrote: > > > [...] > > > It is wrong that gcc puts -fpreprocessed into DW_AT_producer - I may = post a gcc > > > patch for it. > >=20 > > I wasn't aware there are now rules for what can and cannot go in DW_AT_= producer. > > DW_AT_producer has gone from being informational to having a formal > > spec (in the sense that something will break if, for example, a > > particular option is mentioned). > > Is this spec written down somewhere? [At least guidelines for what > > things may lead to breakage?] >=20 > No. Do you have a suggestion where to put it? Should it be only a GNU > extension or should it be even DWARF-standardized? The gcc documentation describes it: https://gcc.gnu.org/onlinedocs/gcc/Debugging-Options.html -grecord-gcc-switches This switch causes the command-line options used to invoke the compiler that may affect code generation to be appended to the DW_AT_producer attribute in DWARF debugging information. The options are concatenated with spaces separating them from each other and from the compiler version. See also -frecord-gcc-switches for another way of storing compiler options into the object file. This is the default. -gno-record-gcc-switches Disallow appending command-line options to the DW_AT_producer attribute in DWARF debugging information. So Jan is right that gcc adding -fpreprocessed, which doesn't affect code generation, but is a preprocessor option, shouldn't be there. Cheers, Mark