ppc: support ffnmsubs instruction
authorDmitry Selyutin <ghostmansd@gmail.com>
Sun, 28 May 2023 22:04:57 +0000 (01:04 +0300)
committerDmitry Selyutin <ghostmansd@gmail.com>
Tue, 14 Nov 2023 19:53:37 +0000 (22:53 +0300)
gas/testsuite/gas/ppc/ffnmsubs.d [new file with mode: 0644]
gas/testsuite/gas/ppc/ffnmsubs.s [new file with mode: 0644]
gas/testsuite/gas/ppc/ppc.exp
opcodes/ppc-opc.c

diff --git a/gas/testsuite/gas/ppc/ffnmsubs.d b/gas/testsuite/gas/ppc/ffnmsubs.d
new file mode 100644 (file)
index 0000000..b362c2e
--- /dev/null
@@ -0,0 +1,14 @@
+#as: -mlibresoc
+#objdump: -dr -Mlibresoc
+
+.*:     file format .*
+
+
+Disassembly of section \.text:
+0+ <\.text>:
+.*:\s+(ef e0 00 0c|0c 00 e0 ef)\s+ffnmsubs\s+f31,f0,f0
+.*:\s+(ec 1f 00 0c|0c 00 1f ec)\s+ffnmsubs\s+f0,f31,f0
+.*:\s+(ec 00 f8 0c|0c f8 00 ec)\s+ffnmsubs\s+f0,f0,f31
+.*:\s+(ef e0 00 0d|0d 00 e0 ef)\s+ffnmsubs.\s+f31,f0,f0
+.*:\s+(ec 1f 00 0d|0d 00 1f ec)\s+ffnmsubs.\s+f0,f31,f0
+.*:\s+(ec 00 f8 0d|0d f8 00 ec)\s+ffnmsubs.\s+f0,f0,f31
diff --git a/gas/testsuite/gas/ppc/ffnmsubs.s b/gas/testsuite/gas/ppc/ffnmsubs.s
new file mode 100644 (file)
index 0000000..9d33c9e
--- /dev/null
@@ -0,0 +1,6 @@
+ffnmsubs 31,0,0
+ffnmsubs 0,31,0
+ffnmsubs 0,0,31
+ffnmsubs. 31,0,0
+ffnmsubs. 0,31,0
+ffnmsubs. 0,0,31
index fb26dc571466a576707ca9b992e2cd7446a02bdf..222363e7f1c4d670aa90c421fc43dc472de9f9a9 100644 (file)
@@ -177,3 +177,4 @@ run_dump_test "maddedus"
 run_dump_test "minmax"
 run_dump_test "ffmsubs"
 run_dump_test "ffmadds"
+run_dump_test "ffnmsubs"
index 8b7174c649cafffdefccd9c77b5690efa9d28326..315a884f926ef3965af166e9532916448b865bad 100644 (file)
@@ -9191,6 +9191,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
 {"ffmadds",    A(59,5,0),      AFRC_MASK,   SFFS,      PPCVLE,         {FRT, FRA, FRB}},
 {"ffmadds.",   A(59,5,1),      AFRC_MASK,   SFFS,      PPCVLE,         {FRT, FRA, FRB}},
 
+{"ffnmsubs",   A(59,6,0),      AFRC_MASK,   SFFS,      PPCVLE,         {FRT, FRA, FRB}},
+{"ffnmsubs.",  A(59,6,1),      AFRC_MASK,   SFFS,      PPCVLE,         {FRT, FRA, FRB}},
+
 {"fdivs",      A(59,18,0),     AFRC_MASK,   PPC,       PPCEFS|PPCVLE,  {FRT, FRA, FRB}},
 {"fdivs.",     A(59,18,1),     AFRC_MASK,   PPC,       PPCEFS|PPCVLE,  {FRT, FRA, FRB}},