[ARM] Better OR's for MVE compares
[llvm-core.git] / test / MC / AArch64 / SVE2 / fcvtnt-diagnostics.s
blobabfdea8c4853bdf94d89d4aa4c414d76a96c0f81
1 // RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve2 2>&1 < %s| FileCheck %s
4 // --------------------------------------------------------------------------//
5 // Invalid element width
7 fcvtnt z0.b, p0/m, z0.b
8 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
9 // CHECK-NEXT: fcvtnt z0.b, p0/m, z0.b
10 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
12 fcvtnt z0.h, p0/m, z0.h
13 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
14 // CHECK-NEXT: fcvtnt z0.h, p0/m, z0.h
15 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
17 fcvtnt z0.s, p0/m, z0.s
18 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
19 // CHECK-NEXT: fcvtnt z0.s, p0/m, z0.s
20 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
22 fcvtnt z0.d, p0/m, z0.d
23 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
24 // CHECK-NEXT: fcvtnt z0.d, p0/m, z0.d
25 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
27 fcvtnt z0.b, p0/m, z0.h
28 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
29 // CHECK-NEXT: fcvtnt z0.b, p0/m, z0.h
30 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
32 fcvtnt z0.d, p0/m, z0.q
33 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
34 // CHECK-NEXT: fcvtnt z0.d, p0/m, z0.q
35 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
38 // --------------------------------------------------------------------------//
39 // Invalid predicate operation
41 fcvtnt z0.h, p0/z, z0.s
42 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid operand for instruction
43 // CHECK-NEXT: fcvtnt z0.h, p0/z, z0.s
44 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
47 // --------------------------------------------------------------------------//
48 // Predicate not in restricted predicate range
50 fcvtnt z0.h, p8/m, z0.s
51 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid restricted predicate register, expected p0..p7 (without element suffix)
52 // CHECK-NEXT: fcvtnt z0.h, p8/m, z0.s
53 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
56 // --------------------------------------------------------------------------//
57 // Negative tests for instructions that are incompatible with movprfx
59 movprfx z0.s, p0/m, z7.s
60 fcvtnt z0.s, p7/m, z1.d
61 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
62 // CHECK-NEXT: fcvtnt z0.s, p7/m, z1.d
63 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
65 movprfx z0, z7
66 fcvtnt z0.s, p7/m, z1.d
67 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
68 // CHECK-NEXT: fcvtnt z0.s, p7/m, z1.d
69 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: