From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 752 invoked by alias); 7 Jun 2011 19:16:32 -0000 Received: (qmail 743 invoked by uid 22791); 7 Jun 2011 19:16:32 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 07 Jun 2011 19:16:18 +0000 Received: (qmail 24866 invoked from network); 7 Jun 2011 19:16:17 -0000 Received: from unknown (HELO digraph.polyomino.org.uk) (joseph@127.0.0.2) by mail.codesourcery.com with ESMTPA; 7 Jun 2011 19:16:17 -0000 Received: from jsm28 (helo=localhost) by digraph.polyomino.org.uk with local-esmtp (Exim 4.72) (envelope-from ) id 1QU1l9-0000v1-0W; Tue, 07 Jun 2011 19:16:15 +0000 Date: Tue, 07 Jun 2011 19:19:00 -0000 From: "Joseph S. Myers" To: "H.J. Lu" cc: gcc-patches@gcc.gnu.org, Uros Bizjak Subject: Re: PATCH [1/n]: Add initial -x32 support In-Reply-To: Message-ID: References: <20110605195441.GA1225@intel.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII 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 X-SW-Source: 2011-06/txt/msg00569.txt.bz2 On Tue, 7 Jun 2011, H.J. Lu wrote: > I thought about it when I started working on it. But I couldn't find a way > to do it properly. What we have are > > #if TARGET_64BIT_DEFAULT > #define SPEC_32 "m32" > #define SPEC_64 "!m32" > #else > #define SPEC_32 "!m64" > #define SPEC_64 "m64" > #endif > > I don't know how to make -mx32, -m32 and -m64 mutually exclusive with > GCC spec processing in GCC driver. The use of Negative in the .opt file means that only one such option will be visible for specs. So you define specs such as "m64|mx32:;" to mean "neither -m64 nor -mx32 is passed (see the MIPS definitions of OPT_ARCH64 and OPT_ARCH32, for example). -- Joseph S. Myers joseph@codesourcery.com