Handle situation where architecture has not yet been selected.
authorNick Clifton <nickc@redhat.com>
Thu, 19 Sep 2002 14:52:15 +0000 (14:52 +0000)
committerNick Clifton <nickc@redhat.com>
Thu, 19 Sep 2002 14:52:15 +0000 (14:52 +0000)
gas/ChangeLog
gas/config/tc-m68k.c

index 7c9871a7e97865e468ebe4c8e0bc76fd2e87139b..c9a9cd7894e86876b42f9f2e002745e166569bb6 100644 (file)
@@ -1,3 +1,8 @@
+2002-09-19  Nick Clifton  <nickc@redhat.com>
+
+       * config/tc-m68k.c (select_control_regs): Handle situation where
+       architecture has not yet been selected.
+
 2002-09-18  Chris Demetriou  <cgd@broadcom.com>
 
        * config/tc-mips.c (IS_SEXT_32BIT_NUM): Move closer to top of file.
index d381ee38bc21bdb8eb52156287a87f363f557c3b..4e23ced782506f4a4f55c615b5a4774f9d1cbfcf 100644 (file)
@@ -3950,6 +3950,11 @@ select_control_regs ()
   /* Note which set of "movec" control registers is available.  */
   switch (cpu_of_arch (current_architecture))
     {
+    case 0:
+      as_warn (_("architecture not yet selected: defaulting to 68020"));
+      control_regs = m68020_control_regs;
+      break;
+      
     case m68000:
       control_regs = m68000_control_regs;
       break;