+2015-11-19 Matthew Wahab <matthew.wahab@arm.com>
+
+ * gas/aarch64/pan-illegal.d: New.
+ * gas/aarch64/pan-illegal.l: New.
+ * gas/aarch64/pan.s: Add tests for invalid immediates.
+
2015-11-19 Alan Modra <amodra@gmail.com>
* gas/ppc/altivec3.d: Allow for padding at end of section.
--- /dev/null
+#as: -march=armv8.1-a --defsym ERROR=1
+#source: pan.s
+#error-output: pan-illegal.l
--- /dev/null
+[^:]*: Assembler messages:
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#2'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#3'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#4'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#5'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#6'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#7'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#8'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#9'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#10'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#11'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#12'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#13'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#14'
+[^:]*:[0-9]+: Error: immediate value out of range 0 to 1 at operand 1 -- `msr pan,#15'
msr pan, x0
mrs x1, pan
+ .ifdef ERROR
+ .irp N,2,3,4,5,6,7,8,9,10,11,12,13,14,15
+ msr pan, #\N
+ .endr
+ .endif
+
.arch_extension nopan
+2015-11-19 Matthew Wahab <matthew.wahab@arm.com>
+
+ * aarch64-opc.c (operand_general_constraint_met_p): Check validity
+ of MSR PAN immediate operand.
+
2015-11-16 Nick Clifton <nickc@redhat.com>
* rx-dis.c (condition_names): Replace always and never with
{
case AARCH64_OPND_PSTATEFIELD:
assert (idx == 0 && opnds[1].type == AARCH64_OPND_UIMM4);
+ /* MSR PAN, #uimm4
+ The immediate must be #0 or #1. */
+ if (opnd->pstatefield == 0x04 /* PAN. */
+ && opnds[1].imm.value > 1)
+ {
+ set_imm_out_of_range_error (mismatch_detail, idx, 0, 1);
+ return 0;
+ }
/* MSR SPSel, #uimm4
Uses uimm4 as a control value to select the stack pointer: if
bit 0 is set it selects the current exception level's stack