This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: GCC Mips has 31 Masks in mips.opt

Steve Ellcey <> writes:
> On Sat, 2014-01-25 at 20:34 +0000, Richard Sandiford wrote:
>> Yeah, I've been trying to use separate variables for new flags.
>> That's why a lot of the MIPS options have discrete TARGET_â variables
>> (defined via Var(TARGET_â)).  target_flags should only really be needed
>> for options whose defaults are controlled by config.gcc.
> I guess I could probably have done that for my experiments, but I didn't
> think of using Var's instead of Mask's for some reason.  It's probably
> a good idea to free up some space anyway.
>> E.g. from a quick look, -mdsp, -mdspr2, -mfp-exceptions,
>> -mfused-madd and -mips3d don't need to be masks and could easily
>> be converted to Var(TARGET_â).  That's pre-approved it works.
>> Others could be moved too with a bit more effort, but hopefully
>> those 5 will be enough for now.
> I think it would be enough for now.  Here is the patch I came up with
> and tested.  I had to tweak a couple of things in
> gcc/common/config/mips/mips-common.c so I wouldn't mind if you took a
> look at it before I checked it in.  Testing looked all right once I

Looks good, although:

> @@ -17084,9 +17084,9 @@ mips_option_override (void)
>        mips_r10k_cache_barrier = R10K_CACHE_BARRIER_NONE;
>      }
> -  /* If TARGET_DSPR2, enable MASK_DSP.  */
> +  /* If TARGET_DSPR2, enable TARGET_DSP.  */
>    if (TARGET_DSPR2)
> -    target_flags |= MASK_DSP;

I'd prefer "= true" here, in case we ever use -1 as an initial "not set"
value.  No need for a full retest for that change, spot checking would be
fine IMO.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]