This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Rs6000 infrastructure cleanup (switches), revised patch #2b
- From: Michael Meissner <meissner at linux dot vnet dot ibm dot com>
- To: David Edelsohn <dje dot gcc at gmail dot com>
- Cc: Michael Meissner <meissner at linux dot vnet dot ibm dot com>, gcc-patches at gcc dot gnu dot org, bergner at vnet dot ibm dot com, segher at kernel dot crashing dot org, iain at codesourcery dot com, andreast-list at fgznet dot ch
- Date: Fri, 5 Oct 2012 15:49:21 -0400
- Subject: Re: [PATCH] Rs6000 infrastructure cleanup (switches), revised patch #2b
- References: <20120912224303.GA19348@ibm-tiger.the-meissners.org> <20120917195131.GA22648@ibm-tiger.the-meissners.org> <CAGWvnykaJM0LFiwVJRcoay4uVJtrFR-V8G=_aK6=4VQygmAx0w@mail.gmail.com> <20120920195755.GA18581@ibm-tiger.the-meissners.org> <20120927224228.GA24889@ibm-tiger.the-meissners.org> <CAGWvny=03v_EwK=48hfbN9-Z43yvqoCUZPLQ-hoC0X0W9UKDiw@mail.gmail.com>
On Wed, Oct 03, 2012 at 09:42:05PM -0400, David Edelsohn wrote:
> @@ -1115,7 +1118,8 @@ static const struct attribute_spec rs600
> { NULL, 0, 0, false, false, false, NULL, false }
> };
>
> -#ifndef MASK_STRICT_ALIGN
> +#ifndef OPTION_MASK_STRICT_ALIGN
> +#define OPTION_MASK_STRICT_ALIGN 0
> #define MASK_STRICT_ALIGN 0
> #endif
> #ifndef TARGET_PROFILE_KERNEL
>
> Why does this fragment define OPTION_MASK_STRICT_ALIGN but does not
> remove definition of MASK_STRICT_ALIGN?
To amplify a little bit more, in the first patch, I completely removed all
MASK_<xxx> names. However, this causes rs6000-cpus.def to be completely
rewritten, and as you point out, that makes it very hard to verify that we are
getting the same behavior.
So in the second patch, I added mappings from OPTION_MASK_<xxx> to MASK_<xxx>
so that rs6000-cpus.def would not change, but in the places where I changed
target_flags to rs6000_isa_flags, I also changed to use the new names.
These code fragments in rs6000.h are for the non-linux systems that don't use
the sysv4.opt switches (which provides -mstrict-align, and hence defines
MASK_STRICT_ALIGN or OPTION_MASK_STRICT_ALIGN in the new scheme).
> Similarly for
>
> -#ifndef MASK_64BIT
> +#ifndef OPTION_MASK_64BIT
> +#define OPTION_MASK_64BIT 0
> #define MASK_64BIT 0
> #endif
>
> Why define both OPTION_MASK_64BIT and MASK_64BIT?
This is for the embedded targets that don't handle the switches from sysv4.opt
nor aix64.opt that define the respective -m64 and -maix64 options.
--
Michael Meissner, IBM
5 Technology Place Drive, M/S 2757, Westford, MA 01886-3141, USA
meissner@linux.vnet.ibm.com fax +1 (978) 399-6899