Power10 byte reverse instructions
authorPeter Bergner <bergner@linux.ibm.com>
Mon, 11 May 2020 00:01:40 +0000 (09:31 +0930)
committerAlan Modra <amodra@gmail.com>
Mon, 11 May 2020 11:38:36 +0000 (21:08 +0930)
opcodes/
* ppc-opc.c (powerpc_opcodes) <brd, brh, brw>: New mnemonics.
gas/
* testsuite/gas/ppc/byte_rev.d,
* testsuite/gas/ppc/byte_rev.s: New test.
* testsuite/gas/ppc/ppc.exp: Run it.

gas/ChangeLog
gas/testsuite/gas/ppc/byte_rev.d [new file with mode: 0644]
gas/testsuite/gas/ppc/byte_rev.s [new file with mode: 0644]
gas/testsuite/gas/ppc/ppc.exp
opcodes/ChangeLog
opcodes/ppc-opc.c

index 2f1caa7133d4714a7253c3af815d2132a123c548..1e741ed7310236a36ecb7274841bbc273c58a411 100644 (file)
@@ -1,3 +1,9 @@
+2020-05-11  Peter Bergner  <bergner@linux.ibm.com>
+
+       * testsuite/gas/ppc/byte_rev.d,
+       * testsuite/gas/ppc/byte_rev.s: New test.
+       * testsuite/gas/ppc/ppc.exp: Run it.
+
 2020-05-11  Peter Bergner  <bergner@linux.ibm.com>
 
        * testsuite/gas/ppc/power10.d: Add paste. tests.
diff --git a/gas/testsuite/gas/ppc/byte_rev.d b/gas/testsuite/gas/ppc/byte_rev.d
new file mode 100644 (file)
index 0000000..ace537c
--- /dev/null
@@ -0,0 +1,13 @@
+#as: -mpower10
+#objdump: -dr -Mpower10
+#name: byte reverse
+
+.*
+
+
+Disassembly of section \.text:
+
+0+0 <_start>:
+.*:    (7c 83 01 76|76 01 83 7c)       brd     r3,r4
+.*:    (7c a4 01 b6|b6 01 a4 7c)       brh     r4,r5
+.*:    (7c c5 01 36|36 01 c5 7c)       brw     r5,r6
diff --git a/gas/testsuite/gas/ppc/byte_rev.s b/gas/testsuite/gas/ppc/byte_rev.s
new file mode 100644 (file)
index 0000000..87d4b9c
--- /dev/null
@@ -0,0 +1,5 @@
+       .text
+_start:
+       brd     3,4
+       brh     4,5
+       brw     5,6
index 6426996833350c5cc0f7bda9ccc2217d8fe06096..2b7af4fe8cbd69c04ac13f03223af24ad190b6dd 100644 (file)
@@ -131,3 +131,4 @@ run_dump_test "prefix-pcrel"
 if { [supports_ppc64] } then {
     run_dump_test "prefix-reloc"
 }
+run_dump_test "byte_rev"
index 4493cb3465e01f69e03da343ee1bfdb42f0cd4f0..f3ad3a142755d8a668fe05696e64873967c17503 100644 (file)
@@ -1,3 +1,7 @@
+2020-05-11  Peter Bergner  <bergner@linux.ibm.com>
+
+       * ppc-opc.c (powerpc_opcodes) <brd, brh, brw>: New mnemonics.
+
 2020-05-11  Peter Bergner  <bergner@linux.ibm.com>
 
        * ppc-opc.c (insert_l1opt, extract_l1opt): New functions.
index 8057f4a9d542fba1856be52d446a7c5ff57d02d8..927a8922ab8b6cd495fd6b4f039194266f34dc5a 100644 (file)
@@ -5919,6 +5919,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
 
 {"prtyw",      X(31,154),    XRB_MASK, POWER6|PPCA2|PPC476, 0,         {RA, RS}},
 
+{"brw",                X(31,155),      XRB_MASK,    POWER10,   0,              {RA, RS}},
+
 {"stdepx",     X(31,157),      X_MASK,   E500MC|PPCA2, 0,              {RS, RA0, RB}},
 
 {"stwepx",     X(31,159),      X_MASK,   E500MC|PPCA2, 0,              {RS, RA0, RB}},
@@ -5955,6 +5957,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
 
 {"prtyd",      X(31,186),      XRB_MASK, POWER6|PPCA2, 0,              {RA, RS}},
 
+{"brd",                X(31,187),      XRB_MASK,    POWER10,   0,              {RA, RS}},
+
 {"cmprb",      X(31,192),      XCMP_MASK,   POWER9,    0,              {BF, L, RA, RB}},
 
 {"icblq.",     XRC(31,198,1),  X_MASK,      E6500,     0,              {CT, RA0, RB}},
@@ -5993,6 +5997,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
 {"sleq",       XRC(31,217,0),  X_MASK,      M601,      0,              {RA, RS, RB}},
 {"sleq.",      XRC(31,217,1),  X_MASK,      M601,      0,              {RA, RS, RB}},
 
+{"brh",                X(31,219),      XRB_MASK,    POWER10,   0,              {RA, RS}},
+
 {"stbepx",     X(31,223),      X_MASK,   E500MC|PPCA2, 0,              {RS, RA0, RB}},
 
 {"cmpeqb",     X(31,224),      XCMPL_MASK,  POWER9,    0,              {BF, RA, RB}},
This page took 0.0338039999999999 seconds and 4 git commands to generate.