From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 85905 invoked by alias); 1 Apr 2015 09:13:42 -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 85883 invoked by uid 89); 1 Apr 2015 09:13:41 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,SPF_PASS,T_RP_MATCHES_RCVD autolearn=ham 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; Wed, 01 Apr 2015 09:13:40 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (Postfix) with ESMTPS id C804C8EA25; Wed, 1 Apr 2015 09:13:38 +0000 (UTC) Received: from tucnak.zalov.cz (ovpn-116-58.ams2.redhat.com [10.36.116.58]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t319Da8l010049 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 1 Apr 2015 05:13:38 -0400 Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.14.9/8.14.9) with ESMTP id t319DY2Z001465; Wed, 1 Apr 2015 11:13:34 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.14.9/8.14.9/Submit) id t319DXPN001464; Wed, 1 Apr 2015 11:13:33 +0200 Date: Wed, 01 Apr 2015 09:13:00 -0000 From: Jakub Jelinek To: Steven Bosscher Cc: David Edelsohn , Ulrich Weigand , GCC Patches Subject: Re: [PATCH] Disable ppc/spu context sensitive macros for CLK_ASM preprocessing (PR preprocessor/61977) Message-ID: <20150401091333.GK19273@tucnak.redhat.com> Reply-To: Jakub Jelinek References: <20150401084028.GJ19273@tucnak.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) X-IsSubscribed: yes X-SW-Source: 2015-04/txt/msg00007.txt.bz2 On Wed, Apr 01, 2015 at 10:57:10AM +0200, Steven Bosscher wrote: > On Wed, Apr 1, 2015 at 10:40 AM, Jakub Jelinek wrote: > > Hi! > > > > The context sensitive macros are inherently C/C++ specific, so trying to > > expand them into anything when preprocessing assembler doesn't make any > > sense to me. > > Why are the -c.c cpp builtins defined at all when preprocessing > assembly? Or in other words: should these (supposedly) > language-dependent hooks for cpp builtins be called if the > pre-processor is called stand-alone? The preprocessor, whether invoked through cpp or gcc driver, is still the C (or C++) FE, and when it doesn't preprocess with -x assembler-with-cpp, it still preprocesses C and has to define these. Most of the macros -c.c defines are needed for assembler preprocessing too, lots of things would break if there wouldn't be on x86_64 say __x86_64__ define. My patch disables just the clearly C/C++ specific macros, I mean defining __vector to __attribute__((...)) where the definition has C/C++ syntax clearly isn't very useful in assembler, and vector contextual macro that expands sometimes to something C specific neither. Jakub