]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
aarch64: Add tests for FEAT_MOPS_GO instructions
authorYury Khrustalev <yury.khrustalev@arm.com>
Thu, 18 Dec 2025 13:43:52 +0000 (13:43 +0000)
committerAlice Carlotti <alice.carlotti@arm.com>
Sat, 27 Dec 2025 09:24:29 +0000 (09:24 +0000)
gas/testsuite/gas/aarch64/mops_go.d [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go.s [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid.d [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid.l [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid.s [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_2.d [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_2.l [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_2.s [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_3.d [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_3.l [new file with mode: 0644]
gas/testsuite/gas/aarch64/mops_go_invalid_3.s [new file with mode: 0644]

diff --git a/gas/testsuite/gas/aarch64/mops_go.d b/gas/testsuite/gas/aarch64/mops_go.d
new file mode 100644 (file)
index 0000000..ce27557
--- /dev/null
@@ -0,0 +1,68 @@
+# objdump: -dr
+
+.*
+
+
+Disassembly of section \.text:
+
+0+0 <\.text>:
+[^:]*: 1ddf0020        setgop  \[x0\]!, x1!
+[^:]*: 1ddf4020        setgom  \[x0\]!, x1!
+[^:]*: 1ddf8020        setgoe  \[x0\]!, x1!
+[^:]*: 1ddf0001        setgop  \[x1\]!, x0!
+[^:]*: 1ddf4001        setgom  \[x1\]!, x0!
+[^:]*: 1ddf8001        setgoe  \[x1\]!, x0!
+[^:]*: 1ddf020f        setgop  \[x15\]!, x16!
+[^:]*: 1ddf420f        setgom  \[x15\]!, x16!
+[^:]*: 1ddf820f        setgoe  \[x15\]!, x16!
+[^:]*: 1ddf03c2        setgop  \[x2\]!, x30!
+[^:]*: 1ddf43c2        setgom  \[x2\]!, x30!
+[^:]*: 1ddf83c2        setgoe  \[x2\]!, x30!
+[^:]*: 1ddf005e        setgop  \[x30\]!, x2!
+[^:]*: 1ddf405e        setgom  \[x30\]!, x2!
+[^:]*: 1ddf805e        setgoe  \[x30\]!, x2!
+[^:]*: 1ddf1020        setgopt \[x0\]!, x1!
+[^:]*: 1ddf5020        setgomt \[x0\]!, x1!
+[^:]*: 1ddf9020        setgoet \[x0\]!, x1!
+[^:]*: 1ddf1001        setgopt \[x1\]!, x0!
+[^:]*: 1ddf5001        setgomt \[x1\]!, x0!
+[^:]*: 1ddf9001        setgoet \[x1\]!, x0!
+[^:]*: 1ddf120f        setgopt \[x15\]!, x16!
+[^:]*: 1ddf520f        setgomt \[x15\]!, x16!
+[^:]*: 1ddf920f        setgoet \[x15\]!, x16!
+[^:]*: 1ddf13c2        setgopt \[x2\]!, x30!
+[^:]*: 1ddf53c2        setgomt \[x2\]!, x30!
+[^:]*: 1ddf93c2        setgoet \[x2\]!, x30!
+[^:]*: 1ddf105e        setgopt \[x30\]!, x2!
+[^:]*: 1ddf505e        setgomt \[x30\]!, x2!
+[^:]*: 1ddf905e        setgoet \[x30\]!, x2!
+[^:]*: 1ddf2020        setgopn \[x0\]!, x1!
+[^:]*: 1ddf6020        setgomn \[x0\]!, x1!
+[^:]*: 1ddfa020        setgoen \[x0\]!, x1!
+[^:]*: 1ddf2001        setgopn \[x1\]!, x0!
+[^:]*: 1ddf6001        setgomn \[x1\]!, x0!
+[^:]*: 1ddfa001        setgoen \[x1\]!, x0!
+[^:]*: 1ddf220f        setgopn \[x15\]!, x16!
+[^:]*: 1ddf620f        setgomn \[x15\]!, x16!
+[^:]*: 1ddfa20f        setgoen \[x15\]!, x16!
+[^:]*: 1ddf23c2        setgopn \[x2\]!, x30!
+[^:]*: 1ddf63c2        setgomn \[x2\]!, x30!
+[^:]*: 1ddfa3c2        setgoen \[x2\]!, x30!
+[^:]*: 1ddf205e        setgopn \[x30\]!, x2!
+[^:]*: 1ddf605e        setgomn \[x30\]!, x2!
+[^:]*: 1ddfa05e        setgoen \[x30\]!, x2!
+[^:]*: 1ddf3020        setgoptn        \[x0\]!, x1!
+[^:]*: 1ddf7020        setgomtn        \[x0\]!, x1!
+[^:]*: 1ddfb020        setgoetn        \[x0\]!, x1!
+[^:]*: 1ddf3001        setgoptn        \[x1\]!, x0!
+[^:]*: 1ddf7001        setgomtn        \[x1\]!, x0!
+[^:]*: 1ddfb001        setgoetn        \[x1\]!, x0!
+[^:]*: 1ddf320f        setgoptn        \[x15\]!, x16!
+[^:]*: 1ddf720f        setgomtn        \[x15\]!, x16!
+[^:]*: 1ddfb20f        setgoetn        \[x15\]!, x16!
+[^:]*: 1ddf33c2        setgoptn        \[x2\]!, x30!
+[^:]*: 1ddf73c2        setgomtn        \[x2\]!, x30!
+[^:]*: 1ddfb3c2        setgoetn        \[x2\]!, x30!
+[^:]*: 1ddf305e        setgoptn        \[x30\]!, x2!
+[^:]*: 1ddf705e        setgomtn        \[x30\]!, x2!
+[^:]*: 1ddfb05e        setgoetn        \[x30\]!, x2!
diff --git a/gas/testsuite/gas/aarch64/mops_go.s b/gas/testsuite/gas/aarch64/mops_go.s
new file mode 100644 (file)
index 0000000..24b29fb
--- /dev/null
@@ -0,0 +1,24 @@
+       .arch   armv9.6-a+mops-go
+
+       .macro  pme_seq, op, suffix, r1, r2
+       \op\()p\()\suffix \r1, \r2
+       \op\()m\()\suffix \r1, \r2
+       \op\()e\()\suffix \r1, \r2
+       .endm
+
+       .macro  set_op1_op2, op, suffix
+       pme_seq \op, \suffix, [x0]!, x1!
+       pme_seq \op, \suffix, [x1]!, x0!
+       pme_seq \op, \suffix, [x15]!, x16!
+       pme_seq \op, \suffix, [x2]!, x30!
+       pme_seq \op, \suffix, [x30]!, x2!
+       .endm
+
+       .macro  set_all, op
+       set_op1_op2 \op
+       set_op1_op2 \op, t
+       set_op1_op2 \op, n
+       set_op1_op2 \op, tn
+       .endm
+
+       set_all setgo
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid.d b/gas/testsuite/gas/aarch64/mops_go_invalid.d
new file mode 100644 (file)
index 0000000..adf9126
--- /dev/null
@@ -0,0 +1 @@
+#error_output: mops_go_invalid.l
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid.l b/gas/testsuite/gas/aarch64/mops_go_invalid.l
new file mode 100644 (file)
index 0000000..8e7f849
--- /dev/null
@@ -0,0 +1,25 @@
+[^:]+: Assembler messages:
+[^:]+:[0-9]+: Error: selected processor does not support `setgop .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgom .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgoe .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgopt .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgomt .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgoet .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgopn .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgomn .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgoen .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgoptn .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgomtn .*'
+[^:]+:[0-9]+: Error: selected processor does not support `setgoetn .*'
+[^:]+:[0-9]+: Warning: the preceding `setgop' should be followed by `setgom` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgopt' should be followed by `setgomt` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgopn' should be followed by `setgomn` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgoptn' should be followed by `setgomtn` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgom' should be followed by `setgoe` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgomt' should be followed by `setgoet` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgomn' should be followed by `setgoen` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: the preceding `setgomtn' should be followed by `setgoetn` rather than `ret` -- `ret'
+[^:]+:[0-9]+: Warning: instruction opens new dependency sequence without ending previous one .*
+[^:]+:[0-9]+: Warning: instruction opens new dependency sequence without ending previous one .*
+[^:]+:[0-9]+: Warning: instruction opens new dependency sequence without ending previous one .*
+[^:]+:[0-9]+: Warning: instruction opens new dependency sequence without ending previous one .*
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid.s b/gas/testsuite/gas/aarch64/mops_go_invalid.s
new file mode 100644 (file)
index 0000000..ef616af
--- /dev/null
@@ -0,0 +1,61 @@
+// Test for unsupported processor errors and warnings
+// about sequence of instrucions
+
+.arch          armv9.6-a
+
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x1!
+setgopt                [x0]!, x1!
+setgomt                [x0]!, x1!
+setgoet                [x0]!, x1!
+setgopn                [x0]!, x1!
+setgomn                [x0]!, x1!
+setgoen                [x0]!, x1!
+setgoptn       [x0]!, x1!
+setgomtn       [x0]!, x1!
+setgoetn       [x0]!, x1!
+
+.arch          armv9.6-a+mops-go
+
+setgop         [x0]!, x1!
+ret
+setgopt                [x0]!, x1!
+ret
+setgopn                [x0]!, x1!
+ret
+setgoptn       [x0]!, x1!
+ret
+
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+ret
+setgopt                [x0]!, x1!
+setgomt                [x0]!, x1!
+ret
+setgopn                [x0]!, x1!
+setgomn                [x0]!, x1!
+ret
+setgoptn       [x0]!, x1!
+setgomtn       [x0]!, x1!
+ret
+
+setgop         [x10]!, x11!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x1!
+
+setgopt                [x10]!, x11!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x1!
+
+setgopn                [x10]!, x11!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x1!
+
+setgoptn       [x10]!, x11!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x1!
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_2.d b/gas/testsuite/gas/aarch64/mops_go_invalid_2.d
new file mode 100644 (file)
index 0000000..9ac14e3
--- /dev/null
@@ -0,0 +1 @@
+#error_output: mops_go_invalid_2.l
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_2.l b/gas/testsuite/gas/aarch64/mops_go_invalid_2.l
new file mode 100644 (file)
index 0000000..dd0c021
--- /dev/null
@@ -0,0 +1,61 @@
+[^:]+: Assembler messages:
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgop \[x0]!,x0!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgom \[x0]!,x0!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgoe \[x0]!,x0!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgopt \[x1]!,x1!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgomt \[x1]!,x1!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgoet \[x1]!,x1!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgopn \[x2]!,x2!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgomn \[x2]!,x2!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgoen \[x2]!,x2!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgoptn \[x3]!,x3!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgomtn \[x3]!,x3!'
+[^:]+:[0-9]+: Error: the two register operands must be distinct from each other -- `setgoetn \[x3]!,x3!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgop \[xsp]!,x0!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgom \[xsp]!,x0!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgoe \[xsp]!,x0!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgopt \[xsp]!,x1!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgomt \[xsp]!,x1!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgoet \[xsp]!,x1!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgopn \[xsp]!,x2!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgomn \[xsp]!,x2!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgoen \[xsp]!,x2!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgoptn \[xsp]!,x3!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgomtn \[xsp]!,x3!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 1 -- `setgoetn \[xsp]!,x3!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgop \[x0]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgom \[x0]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgoe \[x0]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgopt \[x1]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgomt \[x1]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgoet \[x1]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgopn \[x2]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgomn \[x2]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgoen \[x2]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgoptn \[x3]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgomtn \[x3]!,xsp!'
+[^:]+:[0-9]+: Error: expected a 64-bit integer register at operand 2 -- `setgoetn \[x3]!,xsp!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgop \[x0],x0!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgom \[x0],x0!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgoe \[x0],x0!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgopt \[x1],x1!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgomt \[x1],x1!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgoet \[x1],x1!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgopn \[x2],x2!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgomn \[x2],x2!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgoen \[x2],x2!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgoptn \[x3],x3!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgomtn \[x3],x3!'
+[^:]+:[0-9]+: Error: operand 1 must be a register destination address with writeback -- `setgoetn \[x3],x3!'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgop \[x0]!,x0'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgom \[x0]!,x0'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgoe \[x0]!,x0'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgopt \[x1]!,x1'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgomt \[x1]!,x1'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgoet \[x1]!,x1'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgopn \[x2]!,x2'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgomn \[x2]!,x2'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgoen \[x2]!,x2'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgoptn \[x3]!,x3'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgomtn \[x3]!,x3'
+[^:]+:[0-9]+: Error: operand 2 must be an integer register with writeback -- `setgoetn \[x3]!,x3'
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_2.s b/gas/testsuite/gas/aarch64/mops_go_invalid_2.s
new file mode 100644 (file)
index 0000000..4a647d3
--- /dev/null
@@ -0,0 +1,74 @@
+// Test diagnostics for wrong register operands used
+// and lack of writeback
+
+.arch          armv9.6-a+mops-go
+
+// Operands must differ
+setgop         [x0]!, x0!
+setgom         [x0]!, x0!
+setgoe         [x0]!, x0!
+setgopt                [x1]!, x1!
+setgomt                [x1]!, x1!
+setgoet                [x1]!, x1!
+setgopn                [x2]!, x2!
+setgomn                [x2]!, x2!
+setgoen                [x2]!, x2!
+setgoptn       [x3]!, x3!
+setgomtn       [x3]!, x3!
+setgoetn       [x3]!, x3!
+
+// Operands must be 64-registers
+setgop         [xsp]!, x0!
+setgom         [xsp]!, x0!
+setgoe         [xsp]!, x0!
+setgopt                [xsp]!, x1!
+setgomt                [xsp]!, x1!
+setgoet                [xsp]!, x1!
+setgopn                [xsp]!, x2!
+setgomn                [xsp]!, x2!
+setgoen                [xsp]!, x2!
+setgoptn       [xsp]!, x3!
+setgomtn       [xsp]!, x3!
+setgoetn       [xsp]!, x3!
+
+// Operands must be 64-registers
+setgop         [x0]!, xsp!
+setgom         [x0]!, xsp!
+setgoe         [x0]!, xsp!
+setgopt                [x1]!, xsp!
+setgomt                [x1]!, xsp!
+setgoet                [x1]!, xsp!
+setgopn                [x2]!, xsp!
+setgomn                [x2]!, xsp!
+setgoen                [x2]!, xsp!
+setgoptn       [x3]!, xsp!
+setgomtn       [x3]!, xsp!
+setgoetn       [x3]!, xsp!
+
+// Missing writeback in 1st operand
+setgop         [x0], x0!
+setgom         [x0], x0!
+setgoe         [x0], x0!
+setgopt                [x1], x1!
+setgomt                [x1], x1!
+setgoet                [x1], x1!
+setgopn                [x2], x2!
+setgomn                [x2], x2!
+setgoen                [x2], x2!
+setgoptn       [x3], x3!
+setgomtn       [x3], x3!
+setgoetn       [x3], x3!
+
+// Missing writeback in 2nd operand
+setgop         [x0]!, x0
+setgom         [x0]!, x0
+setgoe         [x0]!, x0
+setgopt                [x1]!, x1
+setgomt                [x1]!, x1
+setgoet                [x1]!, x1
+setgopn                [x2]!, x2
+setgomn                [x2]!, x2
+setgoen                [x2]!, x2
+setgoptn       [x3]!, x3
+setgomtn       [x3]!, x3
+setgoetn       [x3]!, x3
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_3.d b/gas/testsuite/gas/aarch64/mops_go_invalid_3.d
new file mode 100644 (file)
index 0000000..b5ed410
--- /dev/null
@@ -0,0 +1 @@
+#warning_output: mops_go_invalid_3.l
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_3.l b/gas/testsuite/gas/aarch64/mops_go_invalid_3.l
new file mode 100644 (file)
index 0000000..516a088
--- /dev/null
@@ -0,0 +1,17 @@
+[^:]+: Assembler messages:
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgom \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgom \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgoe \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgoe \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgomt \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgomt \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgoet \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgoet \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgomn \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgomn \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgoen \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgoen \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgomtn \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgomtn \[x0]!,x2!'
+[^:]+:[0-9]+: Warning: destination register differs from preceding instruction at operand 1 -- `setgoetn \[x2]!,x1!'
+[^:]+:[0-9]+: Warning: size register differs from preceding instruction at operand 2 -- `setgoetn \[x0]!,x2!'
diff --git a/gas/testsuite/gas/aarch64/mops_go_invalid_3.s b/gas/testsuite/gas/aarch64/mops_go_invalid_3.s
new file mode 100644 (file)
index 0000000..905ed1a
--- /dev/null
@@ -0,0 +1,55 @@
+// Test warnings about different operands in subsequent instructions
+
+.arch          armv9.6-a+mops-go
+
+setgop         [x0]!, x1!
+setgom         [x2]!, x1!
+setgoe         [x2]!, x1!
+setgop         [x0]!, x1!
+setgom         [x0]!, x2!
+setgoe         [x0]!, x2!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x2]!, x1!
+setgop         [x0]!, x1!
+setgom         [x0]!, x1!
+setgoe         [x0]!, x2!
+
+setgopt                [x0]!, x1!
+setgomt                [x2]!, x1!
+setgoet                [x2]!, x1!
+setgopt                [x0]!, x1!
+setgomt                [x0]!, x2!
+setgoet                [x0]!, x2!
+setgopt                [x0]!, x1!
+setgomt                [x0]!, x1!
+setgoet                [x2]!, x1!
+setgopt                [x0]!, x1!
+setgomt                [x0]!, x1!
+setgoet                [x0]!, x2!
+
+setgopn                [x0]!, x1!
+setgomn                [x2]!, x1!
+setgoen                [x2]!, x1!
+setgopn                [x0]!, x1!
+setgomn                [x0]!, x2!
+setgoen                [x0]!, x2!
+setgopn                [x0]!, x1!
+setgomn                [x0]!, x1!
+setgoen                [x2]!, x1!
+setgopn                [x0]!, x1!
+setgomn                [x0]!, x1!
+setgoen                [x0]!, x2!
+
+setgoptn       [x0]!, x1!
+setgomtn       [x2]!, x1!
+setgoetn       [x2]!, x1!
+setgoptn       [x0]!, x1!
+setgomtn       [x0]!, x2!
+setgoetn       [x0]!, x2!
+setgoptn       [x0]!, x1!
+setgomtn       [x0]!, x1!
+setgoetn       [x2]!, x1!
+setgoptn       [x0]!, x1!
+setgomtn       [x0]!, x1!
+setgoetn       [x0]!, x2!