llvm-project/llvm/test/MC/AArch64
Nirav Dave 9fa8af2180 Defer asm errors to post-statement failure
Recommitting after fixing AsmParser Initialization.

Allow errors to be deferred and emitted as part of clean up to simplify
and shorten Assembly parser code. This will allow error messages to be
emitted in helper functions and be modified by the caller which has
better context.

As part of this many minor cleanups to the Parser:

* Unify parser cleanup on error
* Add Workaround for incorrect return values in ParseDirective instances
* Tighten checks on error-signifying return values for parser functions
  and fix in-tree TargetParsers to be more consistent with the changes.
* Fix AArch64 test cases checking for spurious error messages that are
  now fixed.

These changes should be backwards compatible with current Target Parsers
so long as the error status are correctly returned in appropriate
functions.

Reviewers: rnk, majnemer

Subscribers: aemerson, jyknight, llvm-commits

Differential Revision: https://reviews.llvm.org/D24047

llvm-svn: 281336
2016-09-13 13:55:06 +00:00
..
adrp-relocation.s Update AArch64 ELF relocations to ABI 1.0 2014-11-26 10:49:18 +00:00
alias-addsubimm.s [AArch64] Implement add/adds/sub/subs/cmp/cmn with negative immediate aliases 2015-07-01 15:05:58 +00:00
alias-logicalimm.s [AArch64] Add logical alias instructions to MC AsmParser 2014-07-10 15:12:26 +00:00
arm64-adr.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-advsimd.s add support for -print-imm-hex for AArch64 2016-05-13 18:00:09 +00:00
arm64-aliases.s AArch64: allow MOV (imm) alias to be printed 2016-06-16 01:42:25 +00:00
arm64-arithmetic-encoding.s AArch64: allow MOV (imm) alias to be printed 2016-06-16 01:42:25 +00:00
arm64-arm64-fixup.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-basic-a64-instructions.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-be-datalayout.s AArch64: remove "arm64_be" support in favour of "aarch64_be". 2014-07-23 12:58:11 +00:00
arm64-bitfield-encoding.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-branch-encoding.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-condbr-without-dots.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-crypto.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-diagno-predicate.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-diags.s [AArch64] Check the size of the vector before accessing its elements. 2015-10-13 18:55:34 +00:00
arm64-directive_loh.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-elf-reloc-condbr.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
arm64-elf-relocs.s Update AArch64 ELF relocations to ABI 1.0 2014-11-26 10:49:18 +00:00
arm64-fp-encoding-error.s AArch64: disallow "fmov sD, #-0.0" during assembly. 2015-04-07 22:49:47 +00:00
arm64-fp-encoding.s [AArch64] Add ARMv8.2-A FP16 scalar instructions 2015-11-27 13:04:48 +00:00
arm64-large-relocs.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-leaf-compact-unwind.s [llvm-readobj] MachO -- correctly dump section field 'Reserved3' 2015-09-01 16:29:02 +00:00
arm64-logical-encoding.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-mapping-across-sections.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-mapping-within-section.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-memory.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-nv-cond.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-optional-hash.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-separator.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-simd-ldst.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-small-data-fixups.s [tests] Use llvm-readobj instead of macho-dump. 2015-07-28 21:58:08 +00:00
arm64-spsel-sysreg.s AArch64: TableGenerate system instruction operands. 2016-07-05 21:23:04 +00:00
arm64-system-encoding.s AArch64: TableGenerate system instruction operands. 2016-07-05 21:23:04 +00:00
arm64-target-specific-sysreg.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-tls-modifiers-darwin.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-tls-relocs.s Update AArch64 ELF relocations to ABI 1.0 2014-11-26 10:49:18 +00:00
arm64-v128_lo-diagnostics.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-variable-exprs.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-vector-lists.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
arm64-verbose-vector-case.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
armv8.1a-atomic.s AArch64: fix typo in SMIN far atomics and add tests 2015-06-02 18:37:20 +00:00
armv8.1a-lor.s [AArch64] LORID_EL1 register must be treated as read-only 2015-04-20 16:54:37 +00:00
armv8.1a-pan.s [MC layer][AArch64] llvm-mc accepts 4-bit immediate values for 2015-10-05 13:42:31 +00:00
armv8.1a-rdma.s Defer asm errors to post-statement failure 2016-09-13 13:55:06 +00:00
armv8.1a-vhe.s [AArch64] Add v8.1a "Virtualization Host Extensions" 2015-04-16 15:38:58 +00:00
armv8.2a-at.s [AArch64] Add ARMv8.2-A new AT instruction variants 2015-11-26 15:34:44 +00:00
armv8.2a-mmfr2.s [AArch64] Add ARMv8.2-A ID_A64MMFR2_EL1 register 2015-11-26 15:26:10 +00:00
armv8.2a-persistent-memory.s [AArch64] Add ARMv8.2-A persistent memory instruction 2015-11-26 15:28:47 +00:00
armv8.2a-statistical-profiling.s [AArch64] Add ARMv8.2-A Statistical Profiling Extension 2015-12-01 10:48:51 +00:00
armv8.2a-uao.s [AArch64] Add ARMv8.2-A UAO PSTATE bit 2015-11-26 15:32:30 +00:00
basic-a64-diagnostics.s [AArch64] Add ARMv8.2-A FP16 scalar instructions 2015-11-27 13:04:48 +00:00
basic-a64-instructions.s AArch64: TableGenerate system instruction operands. 2016-07-05 21:23:04 +00:00
basic-pic.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
case-insen-reg-names.s [AArch64] AsmParser should be case insensitive about accepting vector register names. 2015-06-08 21:32:16 +00:00
cyclone-crc.s AArch64: remove CRC feature from Cyclone. 2016-02-24 18:10:17 +00:00
directive-arch-negative.s AArch64 .arch directive - Include default arch attributes with extensions. 2016-09-08 17:27:03 +00:00
directive-arch.s AArch64 .arch directive - Include default arch attributes with extensions. 2016-09-08 17:27:03 +00:00
directive-cpu.s AArch64: support .cpu directive 2016-04-02 19:29:52 +00:00
dot-req-case-insensitive.s aarch64: support target-specific .req assembler directive 2014-07-02 04:50:23 +00:00
dot-req-diagnostics.s aarch64: support target-specific .req assembler directive 2014-07-02 04:50:23 +00:00
dot-req.s Fix some unnoticed/unwanted behavior change from r222319. 2015-02-04 03:10:03 +00:00
elf-extern.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-globaladdress.ll Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-objdump.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
elf-reloc-addsubimm.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-ldrlit.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-ldstunsimm.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-movw.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-pcreladdressing.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-tstb.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf-reloc-uncondbrimm.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
elf_osabi_flags.s Restore test coverage for other than ELFOSABI_NONE 2015-09-24 23:01:16 +00:00
error-location-ldr-pseudo.s [ARM,AArch64] Store source location of asm constant pool entries 2015-11-16 16:25:47 +00:00
error-location.s MCParser: diagnose missing directional labels more clearly. 2016-04-11 19:50:46 +00:00
expr-shr.s [MC] Use LShr for constant evaluation of ">>" on ELF/arm64--darwin. 2015-04-28 01:37:11 +00:00
fixup-out-of-range.s [AArch64] Better errors for out-of-range fixups 2016-04-01 09:14:50 +00:00
fullfp16-diagnostics.s [AArch64] Fix FP16 vector instructions that should only accept low registers 2015-12-09 14:32:11 +00:00
fullfp16-neon-neg.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
gicv3-regs-diagnostics.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
gicv3-regs.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
inline-asm-modifiers.s Update AArch64 ELF relocations to ABI 1.0 2014-11-26 10:49:18 +00:00
inst-directive-diagnostic.s Defer asm errors to post-statement failure 2016-09-13 13:55:06 +00:00
inst-directive.s Followup to 258750; update this test to use .p2align . 2016-01-26 00:17:24 +00:00
jump-table.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
ldr-pseudo-diagnostics.s [AArch64] ldr= pseudo-instruction silently ignored if register invalid 2015-11-16 10:25:19 +00:00
ldr-pseudo-obj-errors.s [AArch64] Better errors for out-of-range fixups 2016-04-01 09:14:50 +00:00
ldr-pseudo.s AArch64: allow MOV (imm) alias to be printed 2016-06-16 01:42:25 +00:00
lit.local.cfg Reduce verbiage of lit.local.cfg files 2014-06-09 22:42:55 +00:00
mapping-across-sections.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
mapping-within-section.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-2velem.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-3vdiff.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-aba-abd.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-across.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-add-pairwise.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-add-sub-instructions.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-bitwise-instructions.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-compare-instructions.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-crypto.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-diagnostics.s Defer asm errors to post-statement failure 2016-09-13 13:55:06 +00:00
neon-extract.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-facge-facgt.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-frsqrt-frecp.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-halving-add-sub.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-max-min-pairwise.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-max-min.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-mla-mls-instructions.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-mov.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-mul-div-instructions.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-perm.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-rounding-halving-add.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-rounding-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-saturating-add-sub.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-saturating-rounding-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-saturating-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-abs.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-add-sub.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-by-elem-mla.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-by-elem-mul.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-by-elem-saturating-mla.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-by-elem-saturating-mul.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-compare.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-cvt.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-dup.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-extract-narrow.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-fp-compare.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-mul.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-neg.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-recip.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-reduce-pairwise.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-scalar-rounding-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-saturating-add-sub.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-saturating-rounding-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-saturating-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-shift-imm.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-scalar-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-shift-left-long.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-shift.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-simd-copy.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-simd-ldst-multi-elem.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-simd-ldst-one-elem.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-simd-misc.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-simd-post-ldst-multi-elem.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-simd-shift.s [AArch64] Add ARMv8.2-A FP16 vector instructions 2015-12-08 12:16:10 +00:00
neon-sxtl.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
neon-tbl.s AArch64/ARM64: remove AArch64 from tree prior to renaming ARM64. 2014-05-24 12:42:26 +00:00
neon-uxtl.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
noneon-diagnostics.s [AArch64] Improve short-form diags on long-form Match_InvalidOperand. 2015-08-19 17:40:19 +00:00
optional-hash.s Remove redundant -mattr options from llvm-objdump commands. 2016-06-16 15:47:19 +00:00
ras-extension.s RAS extensions are part of ARMv8.2-A. This change enables them by introducing a 2016-06-03 14:03:27 +00:00
single-slash.s AArch64: allow MOV (imm) alias to be printed 2016-06-16 01:42:25 +00:00
tls-relocs.s Update tests to not be as dependent on section numbers. 2015-04-15 15:59:37 +00:00
trace-regs-diagnostics.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00
trace-regs.s AArch64/ARM64: move ARM64 into AArch64's place 2014-05-24 12:50:23 +00:00