]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[AArch64] Fix selection of default CPU options at configure-time
authorKyrylo Tkachov <kyrylo.tkachov@arm.com>
Wed, 12 Mar 2014 10:13:07 +0000 (10:13 +0000)
committerKyrylo Tkachov <ktkachov@gcc.gnu.org>
Wed, 12 Mar 2014 10:13:07 +0000 (10:13 +0000)
* config.gcc (aarch64*-*-*): Use ISA flags from aarch64-arches.def.
Do not define target_cpu_default2 to generic.
* config/aarch64/aarch64.h (TARGET_CPU_DEFAULT): Use generic cpu.
* config/aarch64/aarch64.c (aarch64_override_options): Update comment.
* config/aarch64/aarch64-arches.def (armv8-a): Use generic cpu.

From-SVN: r208508

gcc/ChangeLog
gcc/config.gcc
gcc/config/aarch64/aarch64-arches.def
gcc/config/aarch64/aarch64.c
gcc/config/aarch64/aarch64.h

index 446f51966f5d7b3fa49c996d225dfe3c9367f02b..cc980d95ddecb477e370e6710b2f6b86954e80ec 100644 (file)
@@ -1,3 +1,11 @@
+2014-03-12  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
+
+       * config.gcc (aarch64*-*-*): Use ISA flags from aarch64-arches.def.
+       Do not define target_cpu_default2 to generic.
+       * config/aarch64/aarch64.h (TARGET_CPU_DEFAULT): Use generic cpu.
+       * config/aarch64/aarch64.c (aarch64_override_options): Update comment.
+       * config/aarch64/aarch64-arches.def (armv8-a): Use generic cpu.
+
 2014-03-12  Jakub Jelinek  <jakub@redhat.com>
            Marc Glisse  <marc.glisse@inria.fr>
 
index 2a3deaec92658ff7eda3f039e50481276cb8d48e..3c55c88af4d3125cf537d6a8f4aaa2e877b4a57c 100644 (file)
@@ -3396,6 +3396,11 @@ case "${target}" in
                                  ${srcdir}/config/aarch64/$def | \
                                  sed -e 's/^[^,]*,[    ]*//' | \
                                  sed -e 's/,.*$//'`
+                               # Extract the architecture flags from aarch64-arches.def
+                               ext_mask=`grep "^$pattern(\"$base_val\"," \
+                                  ${srcdir}/config/aarch64/$def | \
+                                  sed -e 's/)$//' | \
+                                  sed -e 's/^.*,//'`
                          else
                                base_id=`grep "^$pattern(\"$base_val\"," \
                                  ${srcdir}/config/aarch64/$def | \
@@ -4057,10 +4062,8 @@ esac
 target_cpu_default2=
 case ${target} in
        aarch64*-*-*)
-               if test x$target_cpu_cname = x
+               if test x"$target_cpu_cname" != x
                then
-                       target_cpu_default2=TARGET_CPU_generic
-               else
                        target_cpu_default2=$target_cpu_cname
                fi
                ;;
index 5028f61bd0d08b4f3002aced1bfd58bd6aae8d6d..4b796d8c90b07eb13d564c35000d627ee21e135b 100644 (file)
@@ -26,4 +26,4 @@
    this architecture.  ARCH is the architecture revision.  FLAGS are
    the flags implied by the architecture.  */
 
-AARCH64_ARCH("armv8-a",              cortexa53,             8,  AARCH64_FL_FOR_ARCH8)
+AARCH64_ARCH("armv8-a",              generic,       8,  AARCH64_FL_FOR_ARCH8)
index f24b24838b5b5080b478b15cca98e9d11afff931..4e6728a04b4ced8e70025dae0c623e20ad605523 100644 (file)
@@ -5250,7 +5250,7 @@ aarch64_override_options (void)
 
   /* If the user did not specify a processor, choose the default
      one for them.  This will be the CPU set during configuration using
-     --with-cpu, otherwise it is "cortex-a53".  */
+     --with-cpu, otherwise it is "generic".  */
   if (!selected_cpu)
     {
       selected_cpu = &all_cores[TARGET_CPU_DEFAULT & 0x3f];
index fc21981ede0592e1ad39a4795b87ee805d26a89d..1f71ee57acef66d7db39906fe0ade8e3b5d0783b 100644 (file)
@@ -475,10 +475,10 @@ enum target_cpus
   TARGET_CPU_generic
 };
 
-/* If there is no CPU defined at configure, use "cortex-a53" as default.  */
+/* If there is no CPU defined at configure, use generic as default.  */
 #ifndef TARGET_CPU_DEFAULT
 #define TARGET_CPU_DEFAULT \
-  (TARGET_CPU_cortexa53 | (AARCH64_CPU_DEFAULT_FLAGS << 6))
+  (TARGET_CPU_generic | (AARCH64_CPU_DEFAULT_FLAGS << 6))
 #endif
 
 /* The processor for which instructions should be scheduled.  */