diff options
author | David Edelsohn <dje.gcc@gmail.com> | 2020-10-19 13:11:56 -0400 |
---|---|---|
committer | David Edelsohn <dje.gcc@gmail.com> | 2020-10-20 15:38:44 -0400 |
commit | 52cb0c7b0e9eaa757c70a745f737b7393ec3137e (patch) | |
tree | 71225f338b65810a3d0c9ba446aa5c9c95c14cc8 | |
parent | 1b6f0476837205932613ddb2b3429a55c26c409d (diff) | |
download | gcc-52cb0c7b0e9eaa757c70a745f737b7393ec3137e.zip gcc-52cb0c7b0e9eaa757c70a745f737b7393ec3137e.tar.gz gcc-52cb0c7b0e9eaa757c70a745f737b7393ec3137e.tar.bz2 |
rs6000: Allow -mabi=no-altivec override on command line for AIX.
The override options machinery to set rs6000_altivec_abi for AIX
doesn't check if the option is set on the command line. This patch
checks for a command line option to not override it.
gcc/ChangeLog:
* config/rs6000/rs6000.c (rs6000_option_override_internal):
Don't implcitly enable Altivec ABI if set on the command line.
-rw-r--r-- | gcc/config/rs6000/rs6000.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index b58eeae..d05b85c 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -4324,7 +4324,9 @@ rs6000_option_override_internal (bool global_init_p) } /* Enable Altivec ABI for AIX -maltivec. */ - if (TARGET_XCOFF && (TARGET_ALTIVEC || TARGET_VSX)) + if (TARGET_XCOFF + && (TARGET_ALTIVEC || TARGET_VSX) + && !global_options_set.x_rs6000_altivec_abi) { if (main_target_opt != NULL && !main_target_opt->x_rs6000_altivec_abi) error ("target attribute or pragma changes AltiVec ABI"); |