1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00
llvm-mirror/test/MC/ARM/it-nv.s
Tim Northover c3783b6a3e ARM: diagnose unpredictable IT instructions
IT instructions are allowed to have the 'AL' predicate, but it must never
result in an 'NV' predicated instruction. Essentially this means that all
branches must be 't' rather than 'e' if the predicate is 'AL'.

This patch adds a diagnostic for this during assembly (error because parsing
hits an assertion if allowed to continue) and an annotation during disassembly.

llvm-svn: 335593
2018-06-26 11:38:41 +00:00

48 lines
834 B
ArmAsm

@ RUN: not llvm-mc -triple thumbv7m-apple-macho %s 2> %t.errs
@ RUN: FileCheck %s < %t.errs --check-prefix=CHECK-ERRS
@ CHECK-ERRS: error: unpredictable IT predicate sequence
@ CHECK-ERRS: ite al
@ CHECK-ERRS: error: unpredictable IT predicate sequence
@ CHECK-ERRS: itee al
@ CHECK-ERRS: error: unpredictable IT predicate sequence
@ CHECK-ERRS: itet al
@ CHECK-ERRS: error: unpredictable IT predicate sequence
@ CHECK-ERRS: itte al
@ CHECK-ERRS: error: unpredictable IT predicate sequence
@ CHECK-ERRS: ittte al
ite al
itee al
itet al
itte al
ittte al
@ CHECK-ERRS-NOT: error
it al
nop
itt al
nop
nop
ittt al
nop
nop
nop
itttt al
nop
nop
nop
nop
ite eq
nopeq
nopne
iteet hi
nophi
nopls
nopls
nophi