]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Update -maltivec and -mvsx options to only enable their oldest instructions.
authorPeter Bergner <bergner@vnet.ibm.com>
Thu, 9 Mar 2017 02:49:03 +0000 (20:49 -0600)
committerAlan Modra <amodra@gmail.com>
Thu, 9 Mar 2017 03:40:50 +0000 (14:10 +1030)
Currently, the -maltivec and -mvsx GAS options enable *all* of the altivec
and vsx instructions respecitively that have ever been added.  This is in
constract to GCC's -maltivec and -mvsx options, which only enable the oldest
(ie, first) set of altivec and vsx instructions.  This patch changes GAS to
mimic GCC's behaviour with respect to -maltivec and -mvsx and it solves a
problem with trying to assemble the lxvx instruction which is different
between POWER8 and POWER9.

opcodes/
* ppc-dis.c (ppc_opts) <altivec>: Do not use PPC_OPCODE_ALTIVEC2;
<vsx>: Do not use PPC_OPCODE_VSX3;

gas/
* testsuite/gas/ppc/altivec2.d (as): Use the -mpower8 option.
(objdump): Use the -Mpower8 option.

gas/ChangeLog
gas/testsuite/gas/ppc/altivec2.d
opcodes/ChangeLog
opcodes/ppc-dis.c

index 95b380a6f11eacf74aa692c911bbb09068428e4e..e8df44483accf213d1bf0c0c598e001755a0c7bf 100644 (file)
@@ -1,3 +1,8 @@
+2017-03-08  Peter Bergner <bergner@vnet.ibm.com>
+
+       * testsuite/gas/ppc/altivec2.d (as): Use the -mpower8 option.
+       (objdump): Use the -Mpower8 option.
+
 2017-03-08  Peter Bergner  <bergner@vnet.ibm.com>
 
        Apply from master.
index fc10fb5a2e4f60ea9228fe7da4fb5e91d84612ff..26f9afa9a8c782f138a2ef2a45db73c6487d3d13 100644 (file)
@@ -1,5 +1,5 @@
-#as: -maltivec
-#objdump: -dr -Maltivec
+#as: -mpower8
+#objdump: -dr -Mpower8
 #name: Altivec ISA 2.07 instructions
 
 .*
index 0c0eb5a876c8cd57f3fe74014b77f992691d6842..30b3aa890f7af1980c55b9e63e704ce931491f87 100644 (file)
@@ -1,3 +1,8 @@
+2017-03-08  Peter Bergner  <bergner@vnet.ibm.com>
+
+       * ppc-dis.c (ppc_opts) <altivec>: Do not use PPC_OPCODE_ALTIVEC2;
+       <vsx>: Do not use PPC_OPCODE_VSX3;
+
 2017-03-08  Peter Bergner  <bergner@vnet.ibm.com>
 
        Apply from master.
index e0eff7a67bd23562376b7f00a82af666f062e334..38f7e55e6c544541eb900dccb283ed89341c8b76 100644 (file)
@@ -93,7 +93,7 @@ struct ppc_mopt ppc_opts[] = {
                | PPC_OPCODE_A2),
     0 },
   { "altivec", PPC_OPCODE_PPC,
-    PPC_OPCODE_ALTIVEC | PPC_OPCODE_ALTIVEC2 },
+    PPC_OPCODE_ALTIVEC },
   { "any",     0,
     PPC_OPCODE_ANY },
   { "booke",   PPC_OPCODE_PPC | PPC_OPCODE_BOOKE,
@@ -221,7 +221,7 @@ struct ppc_mopt ppc_opts[] = {
                | PPC_OPCODE_E500),
     PPC_OPCODE_VLE },
   { "vsx",     PPC_OPCODE_PPC,
-    PPC_OPCODE_VSX | PPC_OPCODE_VSX3 },
+    PPC_OPCODE_VSX },
   { "htm",     PPC_OPCODE_PPC,
     PPC_OPCODE_HTM },
 };