diff options
author | Pat Haugen <pthaugen@us.ibm.com> | 2013-07-18 20:24:34 +0000 |
---|---|---|
committer | Pat Haugen <pthaugen@gcc.gnu.org> | 2013-07-18 20:24:34 +0000 |
commit | ed1fd9999c8162d201ac41dd25cb8bbd26798fdf (patch) | |
tree | b7dd5103aa94f188bea73d436ea8af58de425452 /gcc/config/rs6000 | |
parent | ec87a337f38641cfca278846e1f1c13e0f603a60 (diff) | |
download | gcc-ed1fd9999c8162d201ac41dd25cb8bbd26798fdf.zip gcc-ed1fd9999c8162d201ac41dd25cb8bbd26798fdf.tar.gz gcc-ed1fd9999c8162d201ac41dd25cb8bbd26798fdf.tar.bz2 |
rs6000.c (rs6000_option_override_internal): Adjust flag interaction for new Power8 flags and VSX.
* config/rs6000/rs6000.c (rs6000_option_override_internal): Adjust flag
interaction for new Power8 flags and VSX.
From-SVN: r201041
Diffstat (limited to 'gcc/config/rs6000')
-rw-r--r-- | gcc/config/rs6000/rs6000.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 3d86bd1..2616e6c 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -2966,7 +2966,10 @@ rs6000_option_override_internal (bool global_init_p) if (rs6000_isa_flags_explicit & OPTION_MASK_VSX) msg = N_("-mvsx requires hardware floating point"); else - rs6000_isa_flags &= ~ OPTION_MASK_VSX; + { + rs6000_isa_flags &= ~ OPTION_MASK_VSX; + rs6000_isa_flags_explicit |= OPTION_MASK_VSX; + } } else if (TARGET_PAIRED_FLOAT) msg = N_("-mvsx and -mpaired are incompatible"); @@ -2994,6 +2997,16 @@ rs6000_option_override_internal (bool global_init_p) } } + /* If hard-float/altivec/vsx were explicitly turned off then don't allow + the -mcpu setting to enable options that conflict. */ + if ((!TARGET_HARD_FLOAT || !TARGET_ALTIVEC || !TARGET_VSX) + && (rs6000_isa_flags_explicit & (OPTION_MASK_SOFT_FLOAT + | OPTION_MASK_ALTIVEC + | OPTION_MASK_VSX)) != 0) + rs6000_isa_flags &= ~((OPTION_MASK_P8_VECTOR | OPTION_MASK_CRYPTO + | OPTION_MASK_DIRECT_MOVE) + & ~rs6000_isa_flags_explicit); + if (TARGET_DEBUG_REG || TARGET_DEBUG_TARGET) rs6000_print_isa_options (stderr, 0, "before defaults", rs6000_isa_flags); |