aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gas/ChangeLog7
-rw-r--r--gas/testsuite/gas/aarch64/illegal-dotproduct.d4
-rw-r--r--gas/testsuite/gas/aarch64/illegal-dotproduct.l13
-rw-r--r--gas/testsuite/gas/aarch64/illegal-dotproduct.s4
-rw-r--r--opcodes/ChangeLog5
-rw-r--r--opcodes/aarch64-opc.c3
6 files changed, 35 insertions, 1 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 69187bb..7ba30cb 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,10 @@
+2018-10-16 Matthew Malcomson <matthew.malcomson@arm.com>
+
+ * testsuite/gas/aarch64/illegal-dotproduct.d: New test.
+ * testsuite/gas/aarch64/illegal-dotproduct.l: New test.
+ * testsuite/gas/aarch64/illegal-dotproduct.s: New test.
+
+
2018-10-15 Alan Modra <amodra@gmail.com>
PR 23534
diff --git a/gas/testsuite/gas/aarch64/illegal-dotproduct.d b/gas/testsuite/gas/aarch64/illegal-dotproduct.d
new file mode 100644
index 0000000..3f8928d
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/illegal-dotproduct.d
@@ -0,0 +1,4 @@
+#as: -march=armv8.2-a+dotprod
+#name: Invalid dotproduct instructions.
+#source: illegal-dotproduct.s
+#error_output: illegal-dotproduct.l
diff --git a/gas/testsuite/gas/aarch64/illegal-dotproduct.l b/gas/testsuite/gas/aarch64/illegal-dotproduct.l
new file mode 100644
index 0000000..06d0d78
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/illegal-dotproduct.l
@@ -0,0 +1,13 @@
+[^:]+: Assembler messages:
+[^:]+:[0-9]+: Error: register element index out of range 0 to 3 at operand 3 -- `udot V0.2S,V0.8B,V0.4B\[4\]'
+[^:]+:[0-9]+: Error: operand mismatch -- `udot V0.4S,V0.8B,V0.4B\[4\]'
+[^:]+:[0-9]+: Info: did you mean this\?
+[^:]+:[0-9]+: Info: udot v0.2s, v0.8b, v0.4b\[4\]
+[^:]+:[0-9]+: Info: other valid variant\(s\):
+[^:]+:[0-9]+: Info: udot v0.4s, v0.16b, v0.4b\[4\]
+[^:]+:[0-9]+: Error: register element index out of range 0 to 3 at operand 3 -- `sdot V0.2S,V0.8B,V0.4B\[4\]'
+[^:]+:[0-9]+: Error: operand mismatch -- `sdot V0.2S,V0.8B,V0.4H\[4\]'
+[^:]+:[0-9]+: Info: did you mean this\?
+[^:]+:[0-9]+: Info: sdot v0.2s, v0.8b, v0.4b\[4\]
+[^:]+:[0-9]+: Info: other valid variant\(s\):
+[^:]+:[0-9]+: Info: sdot v0.4s, v0.16b, v0.4b\[4\]
diff --git a/gas/testsuite/gas/aarch64/illegal-dotproduct.s b/gas/testsuite/gas/aarch64/illegal-dotproduct.s
new file mode 100644
index 0000000..9c714ae
--- /dev/null
+++ b/gas/testsuite/gas/aarch64/illegal-dotproduct.s
@@ -0,0 +1,4 @@
+UDOT V0.2S, V0.8B, V0.4B[4]
+UDOT V0.4S, V0.8B, V0.4B[4]
+SDOT V0.2S, V0.8B, V0.4B[4]
+SDOT V0.2S, V0.8B, V0.4H[4]
diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog
index 42a3469..4f5e200 100644
--- a/opcodes/ChangeLog
+++ b/opcodes/ChangeLog
@@ -1,3 +1,8 @@
+2018-10-16 Matthew Malcomson <matthew.malcomson@arm.com>
+
+ * aarch64-opc.c (struct operand_qualifier_data): Change qualifier data
+ corresponding to AARCH64_OPND_QLF_S_4B qualifier.
+
2018-10-10 Jan Beulich <jbeulich@suse.com>
* i386-gen.c (opcode_modifiers): Drop Size16, Size32, and
diff --git a/opcodes/aarch64-opc.c b/opcodes/aarch64-opc.c
index 5cd57d5..44d2ca6 100644
--- a/opcodes/aarch64-opc.c
+++ b/opcodes/aarch64-opc.c
@@ -703,7 +703,7 @@ struct operand_qualifier_data aarch64_opnd_qualifiers[] =
{4, 1, 0x2, "s", OQK_OPD_VARIANT},
{8, 1, 0x3, "d", OQK_OPD_VARIANT},
{16, 1, 0x4, "q", OQK_OPD_VARIANT},
- {1, 4, 0x0, "4b", OQK_OPD_VARIANT},
+ {4, 1, 0x0, "4b", OQK_OPD_VARIANT},
{1, 4, 0x0, "4b", OQK_OPD_VARIANT},
{1, 8, 0x0, "8b", OQK_OPD_VARIANT},
@@ -2527,6 +2527,7 @@ operand_general_constraint_met_p (const aarch64_opnd_info *opnds, int idx,
else
num = 16;
num = num / aarch64_get_qualifier_esize (qualifier) - 1;
+ assert (aarch64_get_qualifier_nelem (qualifier) == 1);
/* Index out-of-range. */
if (!value_in_range_p (opnd->reglane.index, 0, num))