[ARM] Better OR's for MVE compares
[llvm-core.git] / test / MC / AArch64 / SVE / lasta-diagnostics.s
blob37fb59a4d04bfc19c05374fa9a700d7a8850814f
1 // RUN: not llvm-mc -triple=aarch64 -show-encoding -mattr=+sve 2>&1 < %s| FileCheck %s
4 // ------------------------------------------------------------------------- //
5 // Invalid predicate
7 lasta w0, p8, z31.b
8 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid restricted predicate register, expected p0..p7 (without element suffix)
9 // CHECK-NEXT: lasta w0, p8, z31.b
10 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
12 lasta w0, p7.b, w0, z31.b
13 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid restricted predicate register, expected p0..p7 (without element suffix)
14 // CHECK-NEXT: lasta w0, p7.b, w0, z31.b
15 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
17 lasta w0, p7.q, w0, z31.b
18 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid restricted predicate register, expected p0..p7 (without element suffix)
19 // CHECK-NEXT: lasta w0, p7.q, w0, z31.b
20 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
23 // ------------------------------------------------------------------------- //
24 // Invalid element width
26 lasta x0, p7, z31.b
27 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
28 // CHECK-NEXT: lasta x0, p7, z31.b
29 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
31 lasta x0, p7, z31.h
32 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
33 // CHECK-NEXT: lasta x0, p7, z31.h
34 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
36 lasta x0, p7, z31.s
37 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
38 // CHECK-NEXT: lasta x0, p7, z31.s
39 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
41 lasta w0, p7, z31.d
42 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
43 // CHECK-NEXT: lasta w0, p7, z31.d
44 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
46 lasta b0, p7, z31.h
47 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
48 // CHECK-NEXT: lasta b0, p7, z31.h
49 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
51 lasta h0, p7, z31.s
52 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
53 // CHECK-NEXT: lasta h0, p7, z31.s
54 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
56 lasta s0, p7, z31.d
57 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
58 // CHECK-NEXT: lasta s0, p7, z31.d
59 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
61 lasta d0, p7, z31.b
62 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: invalid element width
63 // CHECK-NEXT: lasta d0, p7, z31.b
64 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
67 // --------------------------------------------------------------------------//
68 // Negative tests for instructions that are incompatible with movprfx
70 movprfx z31.d, p7/z, z6.d
71 lasta x0, p7, z31.d
72 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
73 // CHECK-NEXT: lasta x0, p7, z31.d
74 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
76 movprfx z31, z6
77 lasta x0, p7, z31.d
78 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
79 // CHECK-NEXT: lasta x0, p7, z31.d
80 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
82 movprfx z31.d, p7/z, z6.d
83 lasta d0, p7, z31.d
84 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
85 // CHECK-NEXT: lasta d0, p7, z31.d
86 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}:
88 movprfx z31, z6
89 lasta d0, p7, z31.d
90 // CHECK: [[@LINE-1]]:{{[0-9]+}}: error: instruction is unpredictable when following a movprfx, suggest replacing movprfx with mov
91 // CHECK-NEXT: lasta d0, p7, z31.d
92 // CHECK-NOT: [[@LINE-1]]:{{[0-9]+}}: