Add "native" as a valid option value for -mcpu/-mtune= on arm (PR driver/83193).
authorMartin Liska <mliska@suse.cz>
Thu, 22 Feb 2018 12:16:58 +0000 (13:16 +0100)
committerMartin Liska <marxin@gcc.gnu.org>
Thu, 22 Feb 2018 12:16:58 +0000 (12:16 +0000)
2018-02-22  Martin Liska  <mliska@suse.cz>

PR driver/83193
* common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
Add "native" as a possible value.

From-SVN: r257900

gcc/ChangeLog
gcc/common/config/arm/arm-common.c

index d813f81a1a61364f0b1977254a64b491b7329d8b..7503cc5b61fc65a9bb3583d3b89846a9ef5507b3 100644 (file)
@@ -1,3 +1,9 @@
+2018-02-22  Martin Liska  <mliska@suse.cz>
+
+       PR driver/83193
+       * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
+       Add "native" as a possible value.
+
 2018-02-22  Martin Liska  <mliska@suse.cz>
 
        PR driver/83193
index 50f0bad3e36eb062e4eb6b7011d05589ab9b0363..a404d4b1562da7fc66b0f439f2459a90b62a170a 100644 (file)
@@ -309,6 +309,12 @@ arm_print_hint_for_cpu_option (const char *target,
   auto_vec<const char*> candidates;
   for (; list->common.name != NULL; list++)
     candidates.safe_push (list->common.name);
+
+#ifdef HAVE_LOCAL_CPU_DETECT
+  /* Add also "native" as possible value.  */
+  candidates.safe_push ("native");
+#endif
+
   char *s;
   const char *hint = candidates_list_and_hint (target, s, candidates);
   if (hint)