Add better defaults for AIX3, AIX4
authorMichael Meissner <gnu@the-meissners.org>
Fri, 24 May 1996 22:10:52 +0000 (22:10 +0000)
committerMichael Meissner <gnu@the-meissners.org>
Fri, 24 May 1996 22:10:52 +0000 (22:10 +0000)
gas/ChangeLog
gas/config/tc-ppc.c

index a09680f027d66a72d0142d1956c29b10b8cda12c..de018a78c5281b01c8202a2c8bddb172d80e935f 100644 (file)
@@ -1,3 +1,7 @@
+Fri May 24 12:07:54 1996  David Edelsohn  <edelsohn@mhpcc.edu>
+
+       * config/tc-ppc.c (ppc_set_cpu): Change defaults to match AIX.
+
 Thu May 23 17:34:24 1996  Michael Meissner  <meissner@tiktok.cygnus.com>
 
        * read.c (potable): Add .skip as a synonym for .space.
index 4a6b3cc767fe83d12adbce53771534a5e003cec6..ceecd23256d9980812850f2fe6f0d5cf338be066 100644 (file)
@@ -787,17 +787,23 @@ PowerPC options:\n\
 static void
 ppc_set_cpu ()
 {
+  const char *default_os  = TARGET_OS;
   const char *default_cpu = TARGET_CPU;
 
   if (ppc_cpu == 0)
     {
-      if (strcmp (default_cpu, "rs6000") == 0)
+      if (strncmp (default_os, "aix", 3) == 0
+         && default_os[3] >= '4' && default_os[3] <= '9')
+       ppc_cpu = PPC_OPCODE_COMMON;
+      else if (strncmp (default_os, "aix3", 4) == 0)
+       ppc_cpu = PPC_OPCODE_POWER;
+      else if (strcmp (default_cpu, "rs6000") == 0)
        ppc_cpu = PPC_OPCODE_POWER;
       else if (strcmp (default_cpu, "powerpc") == 0
               || strcmp (default_cpu, "powerpcle") == 0)
        ppc_cpu = PPC_OPCODE_PPC;
       else
-       as_fatal ("Unknown default cpu = %s", default_cpu);
+       as_fatal ("Unknown default cpu = %s, os = %s", default_cpu, default_os);
     }
 }
 
@@ -1138,12 +1144,21 @@ ppc_elf_validate_fix (fixp, seg)
       && !fixp->fx_done
       && !fixp->fx_pcrel
       && fixp->fx_r_type <= BFD_RELOC_UNUSED
+      && fixp->fx_r_type != BFD_RELOC_16_GOTOFF
+      && fixp->fx_r_type != BFD_RELOC_HI16_GOTOFF
+      && fixp->fx_r_type != BFD_RELOC_LO16_GOTOFF
+      && fixp->fx_r_type != BFD_RELOC_HI16_S_GOTOFF
+      && fixp->fx_r_type != BFD_RELOC_32_BASEREL
+      && fixp->fx_r_type != BFD_RELOC_LO16_BASEREL
+      && fixp->fx_r_type != BFD_RELOC_HI16_BASEREL
+      && fixp->fx_r_type != BFD_RELOC_HI16_S_BASEREL
       && strcmp (segment_name (seg), ".got2") != 0
       && strcmp (segment_name (seg), ".dtors") != 0
       && strcmp (segment_name (seg), ".ctors") != 0
       && strcmp (segment_name (seg), ".fixup") != 0
       && strcmp (segment_name (seg), ".stab") != 0
-      && strcmp (segment_name (seg), ".gcc_except_table") != 0)
+      && strcmp (segment_name (seg), ".gcc_except_table") != 0
+      && strcmp (segment_name (seg), ".ex_shared") != 0)
     {
       if ((seg->flags & (SEC_READONLY | SEC_CODE)) != 0
          || fixp->fx_r_type != BFD_RELOC_CTOR)
This page took 0.030574 seconds and 4 git commands to generate.