include/opcode/
authorAlan Modra <amodra@gmail.com>
Fri, 23 Nov 2012 03:28:13 +0000 (03:28 +0000)
committerAlan Modra <amodra@gmail.com>
Fri, 23 Nov 2012 03:28:13 +0000 (03:28 +0000)
* ppc.h (ppc_parse_cpu): Update prototype.
opcodes/
* ppc-dis.c (ppc_parse_cpu): Add "sticky" param.  Track bits
set from ppc_opts.sticky in it.  Delete "retain_mask".
(powerpc_init_dialect): Choose default dialect from info->mach
before parsing -M options.  Handle more bfd_mach_ppc variants.
Update common default to power7.
gas/
* config/tc-ppc.c (sticky): New var.
(md_parse_option, ppc_machine): Update ppc_parse_cpu calls.
gas/testsuite/
* gas/ppc/astest2.d: Pass -Mppc to objdump.
ld/testsuite/
* ld-powerpc/plt1.d: Update for default "at" branch hints.
* ld-powerpc/tlsexe.d: Likewise.
* ld-powerpc/tlsexetoc.d: Likewise.
* ld-powerpc/tlsopt1.d: Likewise.
* ld-powerpc/tlsopt1_32.d: Likewise.
* ld-powerpc/tlsopt2.d: Likewise.
* ld-powerpc/tlsopt2_32.d: Likewise.
* ld-powerpc/tlsopt4.d: Likewise.
* ld-powerpc/tlsopt4_32.d: Likewise.
* ld-powerpc/tlsso.d: Likewise.
* ld-powerpc/tlstocso.d: Likewise.

20 files changed:
gas/ChangeLog
gas/config/tc-ppc.c
gas/testsuite/ChangeLog
gas/testsuite/gas/ppc/astest2.d
include/opcode/ChangeLog
include/opcode/ppc.h
ld/testsuite/ChangeLog
ld/testsuite/ld-powerpc/plt1.d
ld/testsuite/ld-powerpc/tlsexe.d
ld/testsuite/ld-powerpc/tlsexetoc.d
ld/testsuite/ld-powerpc/tlsopt1.d
ld/testsuite/ld-powerpc/tlsopt1_32.d
ld/testsuite/ld-powerpc/tlsopt2.d
ld/testsuite/ld-powerpc/tlsopt2_32.d
ld/testsuite/ld-powerpc/tlsopt4.d
ld/testsuite/ld-powerpc/tlsopt4_32.d
ld/testsuite/ld-powerpc/tlsso.d
ld/testsuite/ld-powerpc/tlstocso.d
opcodes/ChangeLog
opcodes/ppc-dis.c

index 184d3060922c441d0eab9a693f665f6460a44a64..a56c7d62eed2129561901c92d8012a9ebe972299 100644 (file)
@@ -1,3 +1,8 @@
+2012-11-23  Alan Modra  <amodra@gmail.com>
+
+       * config/tc-ppc.c (sticky): New var.
+       (md_parse_option, ppc_machine): Update ppc_parse_cpu calls.
+
 2012-11-21  Edgar E. Iglesias <edgar.iglesias@gmail.com>
 
        * config/tc-microblaze.c (parse_reg): Parse REG_SLR, REG_SHR
index de13ab182c28a6c8182fbdf072d2053800cefd9f..e9df05684643fceb7c4b8ffa6614bd7c1a7de550 100644 (file)
@@ -223,6 +223,7 @@ unsigned long nop_limit = 4;
 /* The type of processor we are assembling for.  This is one or more
    of the PPC_OPCODE flags defined in opcode/ppc.h.  */
 ppc_cpu_t ppc_cpu = 0;
+ppc_cpu_t sticky = 0;
 
 /* Flags set on encountering toc relocs.  */
 enum {
@@ -1160,7 +1161,7 @@ md_parse_option (int c, char *arg)
       break;
 
     case 'm':
-      new_cpu = ppc_parse_cpu (ppc_cpu, arg);
+      new_cpu = ppc_parse_cpu (ppc_cpu, &sticky, arg);
       if (new_cpu != 0)
        {
          ppc_cpu = new_cpu;
@@ -4863,7 +4864,7 @@ ppc_machine (int ignore ATTRIBUTE_UNUSED)
          else
            ppc_cpu = cpu_history[--curr_hist];
        }
-      else if ((new_cpu = ppc_parse_cpu (ppc_cpu, cpu_string)) != 0)
+      else if ((new_cpu = ppc_parse_cpu (ppc_cpu, &sticky, cpu_string)) != 0)
        ppc_cpu = new_cpu;
       else
        as_bad (_("invalid machine `%s'"), cpu_string);
index 2661ff4b216a8f5fafb17ccdedf554f108211666..963ed8f0cc47c1020faf3f7c64ba41b681c43d79 100644 (file)
@@ -1,3 +1,7 @@
+2012-11-23  Alan Modra  <amodra@gmail.com>
+
+       * gas/ppc/astest2.d: Pass -Mppc to objdump.
+
 2012-11-21  David Holsgrove  <david.holsgrove@xilinx.com>
 
        * gas/microblaze/allinsn.s: Add swapb, swaph
index ddbd952f1b465154db8a9d2fa0bc8d97982ee659..972b9a50009a770a2349ac410a9374f2fc765215 100644 (file)
@@ -1,4 +1,4 @@
-#objdump: -Dr
+#objdump: -Dr -Mppc
 #name: PowerPC test 2
 
 .*
index 5e77fbdea6871bed6885bd1c6634dd30d22bdf38..22b5c63fe7b835c02b7c8da0f647cc1091e3dcf8 100644 (file)
@@ -1,3 +1,7 @@
+2012-11-23  Alan Modra  <amodra@gmail.com>
+
+       * ppc.h (ppc_parse_cpu): Update prototype.
+
 2012-10-14  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
 
        * hppa.h (pa_opcodes): Use "cX" completer instead of "cx" in fstqx
index 2e789d6ffd07fc9102a713c08bbdaecb63e7a6fa..e57b118b02e5a2faba62f5dbd524f03827f719c0 100644 (file)
@@ -400,6 +400,6 @@ struct powerpc_macro
 extern const struct powerpc_macro powerpc_macros[];
 extern const int powerpc_num_macros;
 
-extern ppc_cpu_t ppc_parse_cpu (ppc_cpu_t, const char *);
+extern ppc_cpu_t ppc_parse_cpu (ppc_cpu_t, ppc_cpu_t *, const char *);
 
 #endif /* PPC_H */
index 72d84456907703f858c1fcb9ee820789cf2d4ee7..c7ea4d76742acc451e32425df4886491a7e1ec00 100644 (file)
@@ -1,3 +1,17 @@
+2012-11-23  Alan Modra  <amodra@gmail.com>
+
+       * ld-powerpc/plt1.d: Update for default "at" branch hints.
+       * ld-powerpc/tlsexe.d: Likewise.
+       * ld-powerpc/tlsexetoc.d: Likewise.
+       * ld-powerpc/tlsopt1.d: Likewise.
+       * ld-powerpc/tlsopt1_32.d: Likewise.
+       * ld-powerpc/tlsopt2.d: Likewise.
+       * ld-powerpc/tlsopt2_32.d: Likewise.
+       * ld-powerpc/tlsopt4.d: Likewise.
+       * ld-powerpc/tlsopt4_32.d: Likewise.
+       * ld-powerpc/tlsso.d: Likewise.
+       * ld-powerpc/tlstocso.d: Likewise.
+
 2012-11-21  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR binutils/14493
index 98851a2c7abbea6eb7f0fe290496a4e68993cae4..73617025dc0613b7be056488b094fbdab7c29411 100644 (file)
@@ -8,7 +8,7 @@
 Disassembly of section .text:
 
 0+ <_start>:
-   0:  (42 9f 00 05|05 00 9f 42)       bcl-    20,4\*cr7\+so,4 .*
+   0:  (42 9f 00 05|05 00 9f 42)       bcl     20,4\*cr7\+so,4 .*
    4:  (7f c8 02 a6|a6 02 c8 7f)       mflr    r30
    8:  (3f de 00 00|00 00 de 3f)       addis   r30,r30,0
                        (a|8): R_PPC_REL16_HA   _GLOBAL_OFFSET_TABLE_\+0x(6|4)
index 7b374c0292670084a6a7d1b83f26fe097b078d92..01796df72436bb9af0cfba043dc05d0194e346eb 100644 (file)
@@ -71,7 +71,7 @@ Disassembly of section \.text:
 .*     (00 01 02 00|00 00 00 00) .*
 .* <__glink_PLTresolve>:
 .*     (7d 88 02 a6|a6 02 88 7d)       mflr    r12
-.*     (42 9f 00 05|05 00 9f 42)       bcl-    20,4\*cr7\+so,.*
+.*     (42 9f 00 05|05 00 9f 42)       bcl     20,4\*cr7\+so,.*
 .*     (7d 68 02 a6|a6 02 68 7d)       mflr    r11
 .*     (e8 4b ff f0|f0 ff 4b e8)       ld      r2,-16\(r11\)
 .*     (7d 88 03 a6|a6 03 88 7d)       mtlr    r12
index cdfeaa696c8dd0a36ec4c728c23a6706bb5397b1..48bde59dda4af514348d393d4380df0125f2997a 100644 (file)
@@ -55,7 +55,7 @@ Disassembly of section \.text:
 .*     (00 01 02 28|00 00 00 00) .*
 .* <__glink_PLTresolve>:
 .*     (7d 88 02 a6|a6 02 88 7d)       mflr    r12
-.*     (42 9f 00 05|05 00 9f 42)       bcl-    20,4\*cr7\+so,.*
+.*     (42 9f 00 05|05 00 9f 42)       bcl     20,4\*cr7\+so,.*
 .*     (7d 68 02 a6|a6 02 68 7d)       mflr    r11
 .*     (e8 4b ff f0|f0 ff 4b e8)       ld      r2,-16\(r11\)
 .*     (7d 88 03 a6|a6 03 88 7d)       mtlr    r12
index 4d57c352ae92be8a9477ffb8660426eae108d983..df50d77d20566e2b067c84cb909908a4cbf10892 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.no_opt1:
 0+100000ec <\.no_opt1>:
 .*:    (38 62 80 08|08 80 62 38)       addi    r3,r2,-32760
 .*:    (2c 24 00 00|00 00 24 2c)       cmpdi   r4,0
-.*:    (41 82 00 10|10 00 82 41)       beq-    .*
+.*:    (41 82 00 10|10 00 82 41)       beq     .*
 .*:    (4b ff ff f1|f1 ff ff 4b)       bl      100000e8 <\.__tls_get_addr>
 .*:    (60 00 00 00|00 00 00 60)       nop
 .*:    (48 00 00 0c|0c 00 00 48)       b       .*
index 07a559ea18ad990c15b18b71720aeb418313a9b7..ec9c7caf5adc5c177dcfa23e835d0233c8e421af 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.no_opt1:
 0+1800098 <\.no_opt1>:
 .*:    (38 6d ff f4|f4 ff 6d 38)       addi    r3,r13,-12
 .*:    (2c 04 00 00|00 00 04 2c)       cmpwi   r4,0
-.*:    (41 82 00 0c|0c 00 82 41)       beq-    .*
+.*:    (41 82 00 0c|0c 00 82 41)       beq     .*
 .*:    (4b ff ff f1|f1 ff ff 4b)       bl      1800094 <__tls_get_addr>
 .*:    (48 00 00 08|08 00 00 48)       b       .*
 .*:    (4b ff ff e9|e9 ff ff 4b)       bl      1800094 <__tls_get_addr>
index af6464c6132771e2d342042b8246e6ca14a575ee..73a9b87662c422c3cd7d1a451d55882b8f56cbc6 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.no_opt2:
 0+100000ec <\.no_opt2>:
 .*:    (38 62 80 08|08 80 62 38)       addi    r3,r2,-32760
 .*:    (2c 24 00 00|00 00 24 2c)       cmpdi   r4,0
-.*:    (41 82 00 08|08 00 82 41)       beq-    .*
+.*:    (41 82 00 08|08 00 82 41)       beq     .*
 .*:    (38 62 80 08|08 80 62 38)       addi    r3,r2,-32760
 .*:    (4b ff ff ed|ed ff ff 4b)       bl      100000e8 <\.__tls_get_addr>
 .*:    (60 00 00 00|00 00 00 60)       nop
index 9bde3c51e0ccce51d3baf346b2fd5d41cf0a7282..baffe91e974698c82f6161730a85fbdbcfaca8cb 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.no_opt2:
 0+1800098 <\.no_opt2>:
 .*:    (38 6d ff f4|f4 ff 6d 38)       addi    r3,r13,-12
 .*:    (2c 04 00 00|00 00 04 2c)       cmpwi   r4,0
-.*:    (41 82 00 08|08 00 82 41)       beq-    .*
+.*:    (41 82 00 08|08 00 82 41)       beq     .*
 .*:    (38 6d ff f4|f4 ff 6d 38)       addi    r3,r13,-12
 .*:    (4b ff ff ed|ed ff ff 4b)       bl      1800094 <__tls_get_addr>
 #pass
index e27c8ca3387dac8de42464bd41e0494fe006374f..944e97f959a72211aa1e938d20a92291e4f8712a 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.opt1:
 0+100000ec <\.opt1>:
 .*:    (3c 6d 00 00|00 00 6d 3c)       addis   r3,r13,0
 .*:    (2c 24 00 00|00 00 24 2c)       cmpdi   r4,0
-.*:    (41 82 00 10|10 00 82 41)       beq-    .*
+.*:    (41 82 00 10|10 00 82 41)       beq     .*
 .*:    (60 00 00 00|00 00 00 60)       nop
 .*:    (38 63 90 10|10 90 63 38)       addi    r3,r3,-28656
 .*:    (48 00 00 0c|0c 00 00 48)       b       .*
@@ -29,7 +29,7 @@ Disassembly of section \.opt2:
 0+1000010c <\.opt2>:
 .*:    (3c 6d 00 00|00 00 6d 3c)       addis   r3,r13,0
 .*:    (2c 24 00 00|00 00 24 2c)       cmpdi   r4,0
-.*:    (41 82 00 08|08 00 82 41)       beq-    .*
+.*:    (41 82 00 08|08 00 82 41)       beq     .*
 .*:    (3c 6d 00 00|00 00 6d 3c)       addis   r3,r13,0
 .*:    (60 00 00 00|00 00 00 60)       nop
 .*:    (38 63 90 10|10 90 63 38)       addi    r3,r3,-28656
index f62a0ea005f8cc9af59cbe30a1f5178d618643b0..59c0a6aae377fc94d1ea3f8f7969127384c2b9e0 100644 (file)
@@ -17,7 +17,7 @@ Disassembly of section \.opt1:
 0+1800098 <\.opt1>:
 .*:    (3c 62 00 00|00 00 62 3c)       addis   r3,r2,0
 .*:    (2c 04 00 00|00 00 04 2c)       cmpwi   r4,0
-.*:    (41 82 00 0c|0c 00 82 41)       beq-    .*
+.*:    (41 82 00 0c|0c 00 82 41)       beq     .*
 .*:    (38 63 90 10|10 90 63 38)       addi    r3,r3,-28656
 .*:    (48 00 00 08|08 00 00 48)       b       .*
 .*:    (38 63 90 10|10 90 63 38)       addi    r3,r3,-28656
@@ -27,7 +27,7 @@ Disassembly of section \.opt2:
 0+18000b0 <\.opt2>:
 .*:    (3c 62 00 00|00 00 62 3c)       addis   r3,r2,0
 .*:    (2c 04 00 00|00 00 04 2c)       cmpwi   r4,0
-.*:    (41 82 00 08|08 00 82 41)       beq-    .*
+.*:    (41 82 00 08|08 00 82 41)       beq     .*
 .*:    (3c 62 00 00|00 00 62 3c)       addis   r3,r2,0
 .*:    (38 63 90 10|10 90 63 38)       addi    r3,r3,-28656
 
index 21449a7f67f3c809d51057688e92c911cf647435..38c7d95c3930feb057f00ccd3efddcb86ab1f2b8 100644 (file)
@@ -59,7 +59,7 @@ Disassembly of section \.text:
 .*     (00 01 02 20|00 00 00 00) .*
 .* <__glink_PLTresolve>:
 .*     (7d 88 02 a6|a6 02 88 7d)       mflr    r12
-.*     (42 9f 00 05|05 00 9f 42)       bcl-    20,4\*cr7\+so,.*
+.*     (42 9f 00 05|05 00 9f 42)       bcl     20,4\*cr7\+so,.*
 .*     (7d 68 02 a6|a6 02 68 7d)       mflr    r11
 .*     (e8 4b ff f0|f0 ff 4b e8)       ld      r2,-16\(r11\)
 .*     (7d 88 03 a6|a6 03 88 7d)       mtlr    r12
index 5163266a70083c2f7b9be51f6f1a5c2eac23988d..32c1682a374f8fd365395a76c7f2d3b42dafff7d 100644 (file)
@@ -43,7 +43,7 @@ Disassembly of section \.text:
 .*     (00 01 02 18|00 00 00 00) .*
 .* <__glink_PLTresolve>:
 .*     (7d 88 02 a6|a6 02 88 7d)       mflr    r12
-.*     (42 9f 00 05|05 00 9f 42)       bcl-    20,4\*cr7\+so,.*
+.*     (42 9f 00 05|05 00 9f 42)       bcl     20,4\*cr7\+so,.*
 .*     (7d 68 02 a6|a6 02 68 7d)       mflr    r11
 .*     (e8 4b ff f0|f0 ff 4b e8)       ld      r2,-16\(r11\)
 .*     (7d 88 03 a6|a6 03 88 7d)       mtlr    r12
index ed74935eb73a7f7ca1df42f24ef945976ee53cf7..8a4634decdc74d9a953ac3a4f9d504b6886815d5 100644 (file)
@@ -1,3 +1,11 @@
+2012-11-23  Alan Modra  <amodra@gmail.com>
+
+       * ppc-dis.c (ppc_parse_cpu): Add "sticky" param.  Track bits
+       set from ppc_opts.sticky in it.  Delete "retain_mask".
+       (powerpc_init_dialect): Choose default dialect from info->mach
+       before parsing -M options.  Handle more bfd_mach_ppc variants.
+       Update common default to power7.
+
 2012-11-21  David Holsgrove  <david.holsgrove@xilinx.com>
 
        * microblaze-opc.h (op_code_struct): Add swapb, swaph Increase MAX_OPCODES.
index 03b31604876ab01c1456826c42f01e988fe2ddc6..41dce276bfa4a14a8dd11ae4e875bbe3a4e10c98 100644 (file)
@@ -211,13 +211,8 @@ get_powerpc_dialect (struct disassemble_info *info)
 /* Handle -m and -M options that set cpu type, and .machine arg.  */
 
 ppc_cpu_t
-ppc_parse_cpu (ppc_cpu_t ppc_cpu, const char *arg)
+ppc_parse_cpu (ppc_cpu_t ppc_cpu, ppc_cpu_t *sticky, const char *arg)
 {
-  const ppc_cpu_t retain_mask = (PPC_OPCODE_ALTIVEC | PPC_OPCODE_VSX
-                                | PPC_OPCODE_SPE | PPC_OPCODE_ANY
-                                | PPC_OPCODE_VLE | PPC_OPCODE_PMR);
-  /* Sticky bits.  */
-  ppc_cpu_t retain_flags = ppc_cpu & retain_mask;
   unsigned int i;
 
   for (i = 0; i < sizeof (ppc_opts) / sizeof (ppc_opts[0]); i++)
@@ -225,8 +220,8 @@ ppc_parse_cpu (ppc_cpu_t ppc_cpu, const char *arg)
       {
        if (ppc_opts[i].sticky)
          {
-           retain_flags |= ppc_opts[i].sticky;
-           if ((ppc_cpu & ~retain_mask) != 0)
+           *sticky |= ppc_opts[i].sticky;
+           if ((ppc_cpu & ~*sticky) != 0)
              break;
          }
        ppc_cpu = ppc_opts[i].cpu;
@@ -235,7 +230,7 @@ ppc_parse_cpu (ppc_cpu_t ppc_cpu, const char *arg)
   if (i >= sizeof (ppc_opts) / sizeof (ppc_opts[0]))
     return 0;
 
-  ppc_cpu |= retain_flags;
+  ppc_cpu |= *sticky;
   return ppc_cpu;
 }
 
@@ -245,12 +240,75 @@ static void
 powerpc_init_dialect (struct disassemble_info *info)
 {
   ppc_cpu_t dialect = 0;
+  ppc_cpu_t sticky = 0;
   char *arg;
   struct dis_private *priv = calloc (sizeof (*priv), 1);
 
   if (priv == NULL)
     priv = &private;
 
+  switch (info->mach)
+    {
+    case bfd_mach_ppc_403:
+    case bfd_mach_ppc_403gc:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_403);
+      break;
+    case bfd_mach_ppc_405:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_403 | PPC_OPCODE_405);
+      break;
+    case bfd_mach_ppc_601:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_601);
+      break;
+    case bfd_mach_ppc_a35:
+    case bfd_mach_ppc_rs64ii:
+    case bfd_mach_ppc_rs64iii:
+      dialect = (PPC_OPCODE_POWER | PPC_OPCODE_POWER2 | PPC_OPCODE_64);
+      break;
+    case bfd_mach_ppc_e500:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_SPE
+                | PPC_OPCODE_ISEL | PPC_OPCODE_EFS | PPC_OPCODE_BRLOCK
+                | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
+                | PPC_OPCODE_E500);
+      break;
+    case bfd_mach_ppc_e500mc:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
+                | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
+                | PPC_OPCODE_E500MC);
+      break;
+    case bfd_mach_ppc_e500mc64:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
+                | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
+                | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_POWER5
+                | PPC_OPCODE_POWER6 | PPC_OPCODE_POWER7);
+      break;
+    case bfd_mach_ppc_e5500:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
+                | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
+                | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_POWER4
+                | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
+                | PPC_OPCODE_POWER7);
+      break;
+    case bfd_mach_ppc_e6500:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_ISEL
+                | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK | PPC_OPCODE_RFMCI
+                | PPC_OPCODE_E500MC | PPC_OPCODE_64 | PPC_OPCODE_ALTIVEC
+                | PPC_OPCODE_ALTIVEC2 | PPC_OPCODE_E6500 | PPC_OPCODE_POWER4
+                | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6 | PPC_OPCODE_POWER7);
+      break;
+    case bfd_mach_ppc_titan:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_PMR
+                | PPC_OPCODE_RFMCI | PPC_OPCODE_TITAN);
+      break;
+    case bfd_mach_ppc_vle:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_ISEL | PPC_OPCODE_VLE);
+      break;
+    default:
+      dialect = (PPC_OPCODE_PPC | PPC_OPCODE_ISEL | PPC_OPCODE_64
+                | PPC_OPCODE_POWER4 | PPC_OPCODE_POWER5 | PPC_OPCODE_POWER6
+                | PPC_OPCODE_POWER7 | PPC_OPCODE_ALTIVEC | PPC_OPCODE_VSX
+                | PPC_OPCODE_ANY);
+    }
+
   arg = info->disassembler_options;
   while (arg != NULL)
     {
@@ -260,7 +318,7 @@ powerpc_init_dialect (struct disassemble_info *info)
       if (end != NULL)
        *end = 0;
 
-      if ((new_cpu = ppc_parse_cpu (dialect, arg)) != 0)
+      if ((new_cpu = ppc_parse_cpu (dialect, &sticky, arg)) != 0)
        dialect = new_cpu;
       else if (strcmp (arg, "32") == 0)
        dialect &= ~(ppc_cpu_t) PPC_OPCODE_64;
@@ -274,20 +332,6 @@ powerpc_init_dialect (struct disassemble_info *info)
       arg = end;
     }
 
-  if ((dialect & ~(ppc_cpu_t) PPC_OPCODE_64) == 0)
-    {
-      if (info->mach == bfd_mach_ppc64)
-       dialect |= PPC_OPCODE_64;
-      else
-       dialect &= ~(ppc_cpu_t) PPC_OPCODE_64;
-      if (info->mach == bfd_mach_ppc_vle)
-        dialect |= PPC_OPCODE_PPC | PPC_OPCODE_VLE;
-      else
-        /* Choose a reasonable default.  */
-        dialect |= (PPC_OPCODE_PPC | PPC_OPCODE_COMMON | PPC_OPCODE_601
-                   | PPC_OPCODE_ALTIVEC);
-    }
-
   info->private_data = priv;
   POWERPC_DIALECT(info) = dialect;
 }
This page took 0.04253 seconds and 4 git commands to generate.