]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR target/91050 (-mdejagnu-cpu=<cpu> does not affect the -m<cpu> assembler option)
authorPeter Bergner <bergner@linux.ibm.com>
Wed, 31 Jul 2019 17:18:40 +0000 (17:18 +0000)
committerPeter Bergner <bergner@gcc.gnu.org>
Wed, 31 Jul 2019 17:18:40 +0000 (12:18 -0500)
PR target/91050
* config/rs6000/rs6000.opt (mdejagnu-cpu=): Delete option.
* config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
use of deleted rs6000_dejagnu_cpu_index variable.
* config/rs6000/rs6000.h (DRIVER_SELF_SPECS): Define.
(SUBTARGET_DRIVER_SELF_SPECS): Likewise.
* config/darwin.h (DRIVER_SELF_SPECS): Rename from this ...
(SUBTARGET_DRIVER_SELF_SPECS): ...to this.
* config/i386/i386.h (DRIVER_SELF_SPECS): Define.
(SUBTARGET_DRIVER_SELF_SPECS): Likewise.

From-SVN: r273941

gcc/ChangeLog
gcc/config/darwin.h
gcc/config/i386/i386.h
gcc/config/rs6000/rs6000.c
gcc/config/rs6000/rs6000.h
gcc/config/rs6000/rs6000.opt

index 18f2ce2268c67e9211e2517b6aad0dbeb981c97f..7d984df15f9562e1cef09e5603cb005d1673229f 100644 (file)
@@ -1,3 +1,16 @@
+2019-07-31  Peter Bergner  <bergner@linux.ibm.com>
+
+       PR target/91050
+       * config/rs6000/rs6000.opt (mdejagnu-cpu=): Delete option.
+       * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
+       use of deleted rs6000_dejagnu_cpu_index variable.
+       * config/rs6000/rs6000.h (DRIVER_SELF_SPECS): Define.
+       (SUBTARGET_DRIVER_SELF_SPECS): Likewise.
+       * config/darwin.h (DRIVER_SELF_SPECS): Rename from this ...
+       (SUBTARGET_DRIVER_SELF_SPECS): ...to this.
+       * config/i386/i386.h (DRIVER_SELF_SPECS): Define.
+       (SUBTARGET_DRIVER_SELF_SPECS): Likewise.
+
 2019-07-31  Richard Biener  <rguenther@suse.de>
 
        PR tree-optimization/91280
index ed8798472a5abae3eada6fc5a4c0e37304d42cc9..ab5ad03f175d4d20061ba8c66f31587a3785b198 100644 (file)
@@ -125,7 +125,8 @@ extern GTY(()) int darwin_ms_struct;
 
    However, a few can be handled and we can elide options that are silently-
    ignored defaults, plus warn on obsolete ones that no longer function.  */
-#define DRIVER_SELF_SPECS                                              \
+#undef SUBTARGET_DRIVER_SELF_SPECS
+#define SUBTARGET_DRIVER_SELF_SPECS                                    \
 "%{fapple-kext|mkernel:-static}",                                      \
 "%{gfull:-g -fno-eliminate-unused-debug-symbols} %<gfull",             \
 "%{gsplit-dwarf:%ngsplit-dwarf is not supported on this platform} \
index a2fcdd4c644a5244b0a213c27a86722a3f1f1614..fba015c4260c937f68b19203ec1730df7d45cf82 100644 (file)
@@ -677,6 +677,12 @@ extern tree x86_mfence;
    with the rounding mode forced to 53 bits.  */
 #define TARGET_96_ROUND_53_LONG_DOUBLE 0
 
+#ifndef SUBTARGET_DRIVER_SELF_SPECS
+# define SUBTARGET_DRIVER_SELF_SPECS ""
+#endif
+
+#define DRIVER_SELF_SPECS SUBTARGET_DRIVER_SELF_SPECS
+
 /* -march=native handling only makes sense with compiler running on
    an x86 or x86_64 chip.  If changing this condition, also change
    the condition in driver-i386.c.  */
index edd8f2b4df8b3edc64e558093996d3023c05e643..4080c82c05f3b6a2dfd6b976d36ad81d666e0153 100644 (file)
@@ -3489,9 +3489,6 @@ rs6000_option_override_internal (bool global_init_p)
   /* Don't override by the processor default if given explicitly.  */
   set_masks &= ~rs6000_isa_flags_explicit;
 
-  if (global_init_p && rs6000_dejagnu_cpu_index >= 0)
-    rs6000_cpu_index = rs6000_dejagnu_cpu_index;
-
   /* Process the -mcpu=<xxx> and -mtune=<xxx> argument.  If the user changed
      the cpu in a target attribute or pragma, but did not specify a tuning
      option, use the cpu for the tuning option rather than the option specified
index 6c24b48a9abeca4587702d43e4db207dce773657..9c11a3e4d461f60b1855684983062ea75d797cac 100644 (file)
 #define PPC405_ERRATUM77 0
 #endif
 
+#ifndef SUBTARGET_DRIVER_SELF_SPECS
+# define SUBTARGET_DRIVER_SELF_SPECS ""
+#endif
+
+/* Only for use in the testsuite: -mdejagnu-cpu= simply overrides -mcpu=.
+   With older versions of Dejagnu the command line arguments you set in
+   RUNTESTFLAGS override those set in the testcases; with this option,
+   the testcase will always win.  Ditto for -mdejagnu-tune=.  */
+#define DRIVER_SELF_SPECS \
+  "%{mdejagnu-cpu=*: %<mcpu=* -mcpu=%*}", \
+  "%{mdejagnu-tune=*: %<mtune=* -mtune=%*}", \
+  "%{mdejagnu-*: %<mdejagnu-*}", \
+   SUBTARGET_DRIVER_SELF_SPECS
+
 #if CHECKING_P
 #define ASM_OPT_ANY ""
 #else
index 342a349e79f2c8d8385644036cc7cf1ccd69fd96..1b69507cfa8664ad300c4413db1e68363c4bfd35 100644 (file)
@@ -388,13 +388,6 @@ mtune=
 Target RejectNegative Joined Var(rs6000_tune_index) Init(-1) Enum(rs6000_cpu_opt_value) Save
 -mtune=        Schedule code for given CPU.
 
-; Only for use in the testsuite.  This simply overrides -mcpu=.  With older
-; versions of Dejagnu the command line arguments you set in RUNTESTFLAGS
-; override those set in the testcases; with this option, the testcase will
-; always win.
-mdejagnu-cpu=
-Target Undocumented RejectNegative Joined Var(rs6000_dejagnu_cpu_index) Init(-1) Enum(rs6000_cpu_opt_value) Save
-
 mtraceback=
 Target RejectNegative Joined Enum(rs6000_traceback_type) Var(rs6000_traceback)
 -mtraceback=[full,part,no]     Select type of traceback table.