Always set machine type based on cpu_variant.
authorNick Clifton <nickc@redhat.com>
Mon, 12 Mar 2001 23:37:39 +0000 (23:37 +0000)
committerNick Clifton <nickc@redhat.com>
Mon, 12 Mar 2001 23:37:39 +0000 (23:37 +0000)
gas/ChangeLog
gas/config/tc-arm.c

index 9b9ab32275b534efe4fba58fab4dfb297db509dc..e88ebff4b40ba7327aa78e220b022afd8b482fc9 100644 (file)
@@ -1,3 +1,8 @@
+2001-03-12  Nick Clifton  <nickc@redhat.com>
+
+       * config/tc-arm.c (md_begin): Always set machine type based on
+       cpu_variant.
+
 2001-03-07  Alan Modra  <alan@linuxcare.com.au>
 
        * config/tc-i386.c (struct _i386_insn): Rename disp_reloc to reloc.
index 47b1fdabf533967a74cdfdfe586b70958d3e2380..9843e1fc3bcf87e41bbf50479771af318c0b041b 100644 (file)
@@ -6513,29 +6513,26 @@ md_begin ()
     }
 
   /* Catch special cases.  */
-  if (cpu_variant != (FPU_DEFAULT | CPU_DEFAULT))
+  if (cpu_variant & ARM_EXT_XSCALE)
+    mach = bfd_mach_arm_XScale;
+  else if (cpu_variant & ARM_EXT_V5E)
+    mach = bfd_mach_arm_5TE;
+  else if (cpu_variant & ARM_EXT_V5)
+    {
+      if (cpu_variant & ARM_EXT_THUMB)
+       mach = bfd_mach_arm_5T;
+      else
+       mach = bfd_mach_arm_5;
+    }
+  else if (cpu_variant & ARM_EXT_HALFWORD)
     {
-      if (cpu_variant & ARM_EXT_XSCALE)
-       mach = bfd_mach_arm_XScale;
-      else if (cpu_variant & ARM_EXT_V5E)
-       mach = bfd_mach_arm_5TE;
-      else if (cpu_variant & ARM_EXT_V5)
-       {
-         if (cpu_variant & ARM_EXT_THUMB)
-           mach = bfd_mach_arm_5T;
-         else
-           mach = bfd_mach_arm_5;
-       }
-      else if (cpu_variant & ARM_EXT_HALFWORD)
-       {
-         if (cpu_variant & ARM_EXT_THUMB)
-           mach = bfd_mach_arm_4T;
-         else
-           mach = bfd_mach_arm_4;
-       }
-      else if (cpu_variant & ARM_EXT_LONGMUL)
-       mach = bfd_mach_arm_3M;
+      if (cpu_variant & ARM_EXT_THUMB)
+       mach = bfd_mach_arm_4T;
+      else
+       mach = bfd_mach_arm_4;
     }
+  else if (cpu_variant & ARM_EXT_LONGMUL)
+    mach = bfd_mach_arm_3M;
 
   bfd_set_arch_mach (stdoutput, TARGET_ARCH, mach);
 }