Debian Codegraph @

llvm/test/MC/AArch64/SVE/fmaxnm.s

raw
1 // RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sve < %s \
2 // RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST
3 // RUN: llvm-mc -triple=aarch64 -show-encoding -mattr=+sme < %s \
4 // RUN: | FileCheck %s --check-prefixes=CHECK-ENCODING,CHECK-INST
5 // RUN: not llvm-mc -triple=aarch64 -show-encoding < %s 2>&1 \
6 // RUN: | FileCheck %s --check-prefix=CHECK-ERROR
7 // RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \
8 // RUN: | llvm-objdump -d --mattr=+sve - | FileCheck %s --check-prefix=CHECK-INST
9 // RUN: llvm-mc -triple=aarch64 -filetype=obj -mattr=+sve < %s \
10 // RUN: | llvm-objdump -d --mattr=-sve - | FileCheck %s --check-prefix=CHECK-UNKNOWN
11
12 fmaxnm z0.h, p0/m, z0.h, #0.000000000000000
13 // CHECK-INST: fmaxnm z0.h, p0/m, z0.h, #0.0
14 // CHECK-ENCODING: [0x00,0x80,0x5c,0x65]
15 // CHECK-ERROR: instruction requires: sve or sme
16 // CHECK-UNKNOWN: 655c8000 <unknown>
17
18 fmaxnm z0.h, p0/m, z0.h, #0.0
19 // CHECK-INST: fmaxnm z0.h, p0/m, z0.h, #0.0
20 // CHECK-ENCODING: [0x00,0x80,0x5c,0x65]
21 // CHECK-ERROR: instruction requires: sve or sme
22 // CHECK-UNKNOWN: 655c8000 <unknown>
23
24 fmaxnm z0.s, p0/m, z0.s, #0.0
25 // CHECK-INST: fmaxnm z0.s, p0/m, z0.s, #0.0
26 // CHECK-ENCODING: [0x00,0x80,0x9c,0x65]
27 // CHECK-ERROR: instruction requires: sve or sme
28 // CHECK-UNKNOWN: 659c8000 <unknown>
29
30 fmaxnm z0.d, p0/m, z0.d, #0.0
31 // CHECK-INST: fmaxnm z0.d, p0/m, z0.d, #0.0
32 // CHECK-ENCODING: [0x00,0x80,0xdc,0x65]
33 // CHECK-ERROR: instruction requires: sve or sme
34 // CHECK-UNKNOWN: 65dc8000 <unknown>
35
36 fmaxnm z31.h, p7/m, z31.h, #1.000000000000000
37 // CHECK-INST: fmaxnm z31.h, p7/m, z31.h, #1.0
38 // CHECK-ENCODING: [0x3f,0x9c,0x5c,0x65]
39 // CHECK-ERROR: instruction requires: sve or sme
40 // CHECK-UNKNOWN: 655c9c3f <unknown>
41
42 fmaxnm z31.h, p7/m, z31.h, #1.0
43 // CHECK-INST: fmaxnm z31.h, p7/m, z31.h, #1.0
44 // CHECK-ENCODING: [0x3f,0x9c,0x5c,0x65]
45 // CHECK-ERROR: instruction requires: sve or sme
46 // CHECK-UNKNOWN: 655c9c3f <unknown>
47
48 fmaxnm z31.s, p7/m, z31.s, #1.0
49 // CHECK-INST: fmaxnm z31.s, p7/m, z31.s, #1.0
50 // CHECK-ENCODING: [0x3f,0x9c,0x9c,0x65]
51 // CHECK-ERROR: instruction requires: sve or sme
52 // CHECK-UNKNOWN: 659c9c3f <unknown>
53
54 fmaxnm z31.d, p7/m, z31.d, #1.0
55 // CHECK-INST: fmaxnm z31.d, p7/m, z31.d, #1.0
56 // CHECK-ENCODING: [0x3f,0x9c,0xdc,0x65]
57 // CHECK-ERROR: instruction requires: sve or sme
58 // CHECK-UNKNOWN: 65dc9c3f <unknown>
59
60 fmaxnm z0.h, p7/m, z0.h, z31.h
61 // CHECK-INST: fmaxnm z0.h, p7/m, z0.h, z31.h
62 // CHECK-ENCODING: [0xe0,0x9f,0x44,0x65]
63 // CHECK-ERROR: instruction requires: sve or sme
64 // CHECK-UNKNOWN: 65449fe0 <unknown>
65
66 fmaxnm z0.s, p7/m, z0.s, z31.s
67 // CHECK-INST: fmaxnm z0.s, p7/m, z0.s, z31.s
68 // CHECK-ENCODING: [0xe0,0x9f,0x84,0x65]
69 // CHECK-ERROR: instruction requires: sve or sme
70 // CHECK-UNKNOWN: 65849fe0 <unknown>
71
72 fmaxnm z0.d, p7/m, z0.d, z31.d
73 // CHECK-INST: fmaxnm z0.d, p7/m, z0.d, z31.d
74 // CHECK-ENCODING: [0xe0,0x9f,0xc4,0x65]
75 // CHECK-ERROR: instruction requires: sve or sme
76 // CHECK-UNKNOWN: 65c49fe0 <unknown>
77
78
79 // --------------------------------------------------------------------------//
80 // Test compatibility with MOVPRFX instruction.
81
82 movprfx z31.d, p7/z, z6.d
83 // CHECK-INST: movprfx z31.d, p7/z, z6.d
84 // CHECK-ENCODING: [0xdf,0x3c,0xd0,0x04]
85 // CHECK-ERROR: instruction requires: sve or sme
86 // CHECK-UNKNOWN: 04d03cdf <unknown>
87
88 fmaxnm z31.d, p7/m, z31.d, #1.0
89 // CHECK-INST: fmaxnm z31.d, p7/m, z31.d, #1.0
90 // CHECK-ENCODING: [0x3f,0x9c,0xdc,0x65]
91 // CHECK-ERROR: instruction requires: sve or sme
92 // CHECK-UNKNOWN: 65dc9c3f <unknown>
93
94 movprfx z31, z6
95 // CHECK-INST: movprfx z31, z6
96 // CHECK-ENCODING: [0xdf,0xbc,0x20,0x04]
97 // CHECK-ERROR: instruction requires: sve or sme
98 // CHECK-UNKNOWN: 0420bcdf <unknown>
99
100 fmaxnm z31.d, p7/m, z31.d, #1.0
101 // CHECK-INST: fmaxnm z31.d, p7/m, z31.d, #1.0
102 // CHECK-ENCODING: [0x3f,0x9c,0xdc,0x65]
103 // CHECK-ERROR: instruction requires: sve or sme
104 // CHECK-UNKNOWN: 65dc9c3f <unknown>
105
106 movprfx z0.d, p7/z, z7.d
107 // CHECK-INST: movprfx z0.d, p7/z, z7.d
108 // CHECK-ENCODING: [0xe0,0x3c,0xd0,0x04]
109 // CHECK-ERROR: instruction requires: sve or sme
110 // CHECK-UNKNOWN: 04d03ce0 <unknown>
111
112 fmaxnm z0.d, p7/m, z0.d, z31.d
113 // CHECK-INST: fmaxnm z0.d, p7/m, z0.d, z31.d
114 // CHECK-ENCODING: [0xe0,0x9f,0xc4,0x65]
115 // CHECK-ERROR: instruction requires: sve or sme
116 // CHECK-UNKNOWN: 65c49fe0 <unknown>
117
118 movprfx z0, z7
119 // CHECK-INST: movprfx z0, z7
120 // CHECK-ENCODING: [0xe0,0xbc,0x20,0x04]
121 // CHECK-ERROR: instruction requires: sve or sme
122 // CHECK-UNKNOWN: 0420bce0 <unknown>
123
124 fmaxnm z0.d, p7/m, z0.d, z31.d
125 // CHECK-INST: fmaxnm z0.d, p7/m, z0.d, z31.d
126 // CHECK-ENCODING: [0xe0,0x9f,0xc4,0x65]
127 // CHECK-ERROR: instruction requires: sve or sme
128 // CHECK-UNKNOWN: 65c49fe0 <unknown>