• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# RUN: llvm-mc --disassemble %s -triple=x86_64 | FileCheck %s
2
3# Coverage
4
5# CHECK: vcmptrue_usps
60xc5 0x04 0xc2 0xc7 0x1f
7
8# CHECK: vcmptrue_uspd
90xc5 0x05 0xc2 0xc7 0x1f
10
11# CHECK: vcmptrue_usss
120xc5 0x06 0xc2 0xc7 0x1f
13
14# CHECK: vcmptrue_ussd
150xc5 0x07 0xc2 0xc7 0x1f
16
17# CHECK: vcmpeq_uqps
180xc5 0x04 0xc2 0xc7 0x08
19
20# CHECK: vcmpeq_uqpd
210xc5 0x05 0xc2 0xc7 0x08
22
23# CHECK: vcmpeq_uqss
240xc5 0x06 0xc2 0xc7 0x08
25
26# CHECK: vcmpeq_uqsd
270xc5 0x07 0xc2 0xc7 0x08
28
29# CHECK: vcmpeqps
300xc5 0x04 0xc2 0xc7 0x00
31
32# CHECK: vcmpeqpd
330xc5 0x05 0xc2 0xc7 0x00
34
35# CHECK: vcmpeqss
360xc5 0x06 0xc2 0xc7 0x00
37
38# CHECK: vcmpeqsd
390xc5 0x07 0xc2 0xc7 0x00
40
41# CHECK: cmpeqps
420x0f 0xc2 0xc7 0x00
43
44# CHECK: cmpeqpd
450x66 0x0f 0xc2 0xc7 0x00
46
47# CHECK: cmpeqss
480xf3 0x0f 0xc2 0xc7 0x00
49
50# CHECK: cmpeqsd
510xf2 0x0f 0xc2 0xc7 0x00
52
53# CHECK: cmpordps
540x0f 0xc2 0xc7 0x07
55
56# CHECK: cmpordpd
570x66 0x0f 0xc2 0xc7 0x07
58
59# CHECK: cmpordss
600xf3 0x0f 0xc2 0xc7 0x07
61
62# CHECK: cmpordsd
630xf2 0x0f 0xc2 0xc7 0x07
64
65# CHECK: extrq  $2, $3, %xmm0
660x66 0x0f 0x78 0xc0 0x03 0x02
67
68# CHECK: extrq  %xmm1, %xmm0
690x66 0x0f 0x79 0xc1
70
71# CHECK: insertq $6, $5, %xmm1, %xmm0
720xf2 0x0f 0x78 0xc1 0x05 0x06
73
74# CHECK: insertq %xmm1, %xmm0
750xf2 0x0f 0x79 0xc1
76
77# CHECK: movntsd %xmm0, (%rdi)
780xf2 0x0f 0x2b 0x07
79
80# CHECK: movntss %xmm0, (%rdi)
810xf3 0x0f 0x2b 0x07
82
83# CHECK: adcxl %eax, %eax
840x66 0x0f 0x38 0xf6 0xc0
85
86# CHECK: adcxl (%rax), %eax
870x66 0x0f 0x38 0xf6 0x00
88
89# CHECK: adcxq %rax, %rax
900x66 0x48 0x0f 0x38 0xf6 0xc0
91
92# CHECK: adcxq (%rax), %rax
930x66 0x48 0x0f 0x38 0xf6 0x00
94
95# CHECK: adoxl %eax, %eax
960xf3 0x0f 0x38 0xf6 0xc0
97
98# CHECK: adoxl (%rax), %eax
990xf3 0x0f 0x38 0xf6 0x00
100
101# CHECK: adoxq %rax, %rax
1020xf3 0x48 0x0f 0x38 0xf6 0xc0
103
104# CHECK: adoxq (%rax), %rax
1050xf3 0x48 0x0f 0x38 0xf6 0x00
106
107# CHECK: xbegin	53
1080xc7 0xf8 0x35 0x00 0x00 0x00
109
110# CHECK: xbegin	53
1110x66 0xc7 0xf8 0x35 0x00
112
113# CHECK: xend
1140x0f 0x01 0xd5
115
116# CHECK: xabort $13
1170xc6 0xf8 0x0d
118
119# CHECK: xsave64 (%rax)
1200x48 0x0f 0xae 0x20
121
122# CHECK: xrstor64 (%rax)
1230x48 0x0f 0xae 0x28
124
125# CHECK: xsaveopt64 (%rax)
1260x48 0x0f 0xae 0x30
127
128# CHECK: clac
1290x0f 0x01 0xca
130
131# CHECK: stac
1320x0f 0x01 0xcb
133
134# CHECK: movabsb -6066930261531658096, %al
1350xa0 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
136
137# CHECK: movabsb -6066930261531658096, %al
1380x48 0xa0 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
139
140# CHECK: movabsw -6066930261531658096, %ax
1410x66 0xa1 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
142
143# CHECK: movabsl -6066930261531658096, %eax
1440xa1 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
145
146# CHECK: movabsq -6066930261531658096, %rax
1470x48 0xa1 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
148
149# CHECK: movabsb %al, -6066930261531658096
1500xa2 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
151
152# CHECK: movabsb %al, -6066930261531658096
1530x48 0xa2 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
154
155# CHECK: movabsw %ax, -6066930261531658096
1560x66 0xa3 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
157
158# CHECK: movabsl %eax, -6066930261531658096
1590xa3 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
160
161# CHECK: movabsq %rax, -6066930261531658096
1620x48 0xa3 0x90 0x78 0x56 0x34 0x12 0xef 0xcd 0xab
163
164# CHECK: sha1rnds4 $1, %xmm1, %xmm2
1650x0f 0x3a 0xcc 0xd1 0x01
166
167# CHECK: sha1rnds4 $1, (%rax), %xmm2
1680x0f 0x3a 0xcc 0x10 0x01
169
170# CHECK: sha1nexte %xmm1, %xmm2
1710x0f 0x38 0xc8 0xd1
172
173# CHECK: sha1nexte (%rax), %xmm2
1740x0f 0x38 0xc8 0x10
175
176# CHECK: sha1msg1 %xmm1, %xmm2
1770x0f 0x38 0xc9 0xd1
178
179# CHECK: sha1msg1 (%rax), %xmm2
1800x0f 0x38 0xc9 0x10
181
182# CHECK: sha1msg2 %xmm1, %xmm2
1830x0f 0x38 0xca 0xd1
184
185# CHECK: sha1msg2 (%rax), %xmm2
1860x0f 0x38 0xca 0x10
187
188# CHECK: sha256rnds2 (%rax), %xmm2
1890x0f 0x38 0xcb 0x10
190
191# CHECK: sha256rnds2 %xmm1, %xmm2
1920x0f 0x38 0xcb 0xd1
193
194# CHECK: sha256msg1 %xmm1, %xmm2
1950x0f 0x38 0xcc 0xd1
196
197# CHECK: sha256msg1 (%rax), %xmm2
1980x0f 0x38 0xcc 0x10
199
200# CHECK: sha256msg2 %xmm1, %xmm2
2010x0f 0x38 0xcd 0xd1
202
203# CHECK: sha256msg2 (%rax), %xmm2
2040x0f 0x38 0xcd 0x10
205
206# CHECK: incl %ecx
2070xff 0xc1
208
209# CHECK: decl %ecx
2100xff 0xc9
211
212# CHECK: incw %cx
2130x66 0xff 0xc1
214
215# CHECK: decw %cx
2160x66 0xff 0xc9
217
218# CHECK: incb %cl
2190xfe 0xc1
220
221# CHECK: decb %cl
2220xfe 0xc9
223
224# CHECK: incq %rcx
2250x48 0xff 0xc1
226
227# CHECK: decq %rcx
2280x48 0xff 0xc9
229
230# CHECK: movq %xmm0, %xmm0
2310xf3 0x0f 0x7e 0xc0
232
233# CHECK: vmovq %xmm0, %xmm0
2340xc5 0xfa 0x7e 0xc0
235
236# CHECK: vmovq %xmm0, %rax
2370xc4 0xe1 0xf9 0x7e 0xc0
238
239# CHECK: movd (%rax), %mm0
2400x48 0x0f 0x6e 0x00
241
242# CHECK: movd %rax, %mm0
2430x48 0x0f 0x6e 0xc0
244
245# CHECK: movd %mm0, (%rax)
2460x48 0x0f 0x7e 0x00
247
248# CHECK: movd %mm0, %rax
2490x48 0x0f 0x7e 0xc0
250
251# CHECK: movd (%rax), %xmm0
2520x66 0x48 0x0f 0x6e 0x00
253
254# CHECK: movd %rax, %xmm0
2550x66 0x48 0x0f 0x6e 0xc0
256
257# CHECK: movd %xmm0, (%rax)
2580x66 0x48 0x0f 0x7e 0x00
259
260# CHECK: movd %xmm0, %rax
2610x66 0x48 0x0f 0x7e 0xc0
262
263# CHECK: pextrw $3, %xmm3, %ecx
2640x66 0x0f 0x3a 0x15 0xd9 0x03
265
266# CHECK: pextrw $3, %xmm3, (%rax)
2670x66 0x0f 0x3a 0x15 0x18 0x03
268
269# CHECK: $0, 305419896(,%r8)
2700x43 0x80 0x04 0x05 0x78 0x56 0x34 0x12 0x00
271
272# CHECK: $0, 305419896(%r13,%r8)
2730x43 0x80 0x84 0x05 0x78 0x56 0x34 0x12 0x00
274
275# CHECK: $0, 305419896(,%r8)
2760x42 0x80 0x04 0x05 0x78 0x56 0x34 0x12 0x00
277
278# CHECK: $0, 305419896(%rbp,%r8)
2790x42 0x80 0x84 0x05 0x78 0x56 0x34 0x12 0x00
280
281# CHECK: $0, 305419896(,%r12)
2820x42 0x80 0x04 0x25 0x78 0x56 0x34 0x12 0x00
283
284# CHECK: $0, 305419896(%rbp,%r12)
2850x42 0x80 0x84 0x25 0x78 0x56 0x34 0x12 0x00
286
287# CHECK: $0, 305419896
2880x80 0x04 0x25 0x78 0x56 0x34 0x12 0x00
289
290# CHECK: $0, 305419896(%rbp)
2910x80 0x84 0x25 0x78 0x56 0x34 0x12 0x00
292
293# CHECK: movabsq 6510615555426900570, %rax
2940x48 0xa1 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a
295
296# CHECK: movq 1515870810, %rax
2970x67, 0x48 0xa1 0x5a 0x5a 0x5a 0x5a
298
299# CHECK: movabsq %rax, 6510615555426900570
3000x48 0xa3 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a 0x5a
301
302# CHECK: movq %rax, 1515870810
3030x67, 0x48 0xa3 0x5a 0x5a 0x5a 0x5a
304
305# CHECK: callq -32769
3060x66 0xe8 0xff 0x7f 0xff 0xff
307
308# CHECK: callq -32769
3090x66 0x66 0x48 0xe8 0xff 0x7f 0xff 0xff
310
311# CHECK: jmp -32769
3120xe9 0xff 0x7f 0xff 0xff
313
314# CHECK: jmp -32769
3150x66 0xe9 0xff 0x7f 0xff 0xff
316
317# CHECK: jmp -32769
3180x66 0x66 0x48 0xe9 0xff 0x7f 0xff 0xff
319
320# CHECK: jb -32769
3210x0f 0x82 0xff 0x7f 0xff 0xff
322
323# CHECK: jb -32769
3240x66 0x0f 0x82 0xff 0x7f 0xff 0xff
325
326# CHECK: jae -32769
3270x0f 0x83 0xff 0x7f 0xff 0xff
328
329# CHECK: jae -32769
3300x66 0x0f 0x83 0xff 0x7f 0xff 0xff
331
332# CHECK: je -32769
3330x0f 0x84 0xff 0x7f 0xff 0xff
334
335# CHECK: je -32769
3360x66 0x0f 0x84 0xff 0x7f 0xff 0xff
337
338# CHECK: jne -32769
3390x0f 0x85 0xff 0x7f 0xff 0xff
340
341# CHECK: jne -32769
3420x66 0x0f 0x85 0xff 0x7f 0xff 0xff
343
344# CHECK: jbe -32769
3450x0f 0x86 0xff 0x7f 0xff 0xff
346
347# CHECK: jbe -32769
3480x66 0x0f 0x86 0xff 0x7f 0xff 0xff
349
350# CHECK: ja -32769
3510x0f 0x87 0xff 0x7f 0xff 0xff
352
353# CHECK: ja -32769
3540x66 0x0f 0x87 0xff 0x7f 0xff 0xff
355
356# CHECK: js -32769
3570x0f 0x88 0xff 0x7f 0xff 0xff
358
359# CHECK: js -32769
3600x66 0x0f 0x88 0xff 0x7f 0xff 0xff
361
362# CHECK: jns -32769
3630x0f 0x89 0xff 0x7f 0xff 0xff
364
365# CHECK: jns -32769
3660x66 0x0f 0x89 0xff 0x7f 0xff 0xff
367
368# CHECK: jp -32769
3690x0f 0x8a 0xff 0x7f 0xff 0xff
370
371# CHECK: jp -32769
3720x66 0x0f 0x8a 0xff 0x7f 0xff 0xff
373
374# CHECK: jnp -32769
3750x0f 0x8b 0xff 0x7f 0xff 0xff
376
377# CHECK: jnp -32769
3780x66 0x0f 0x8b 0xff 0x7f 0xff 0xff
379
380# CHECK: jl -32769
3810x0f 0x8c 0xff 0x7f 0xff 0xff
382
383# CHECK: jl -32769
3840x66 0x0f 0x8c 0xff 0x7f 0xff 0xff
385
386# CHECK: jge -32769
3870x0f 0x8d 0xff 0x7f 0xff 0xff
388
389# CHECK: jge -32769
3900x66 0x0f 0x8d 0xff 0x7f 0xff 0xff
391
392# CHECK: jle -32769
3930x0f 0x8e 0xff 0x7f 0xff 0xff
394
395# CHECK: jle -32769
3960x66 0x0f 0x8e 0xff 0x7f 0xff 0xff
397
398# CHECK: jg -32769
3990x0f 0x8f 0xff 0x7f 0xff 0xff
400
401# CHECK: jg -32769
4020x66 0x0f 0x8f 0xff 0x7f 0xff 0xff
403
404# CHECK: lcallw	*-32769(%rip)
4050x66 0xff 0x1d 0xff 0x7f 0xff 0xff
406
407# CHECK: ljmpw	*-32769(%rip)
4080x66 0xff 0x2d 0xff 0x7f 0xff 0xff
409
410# CHECK: psubsb	(%rdx), %mm3
4110x0f 0xe8 0x1a
412
413# CHECK: psubsb	(%rdx), %xmm3
4140x66 0x0f 0xe8 0x1a
415
416# CHECK: addq 255(%rip), %rbx
4170x49, 0x03, 0x1d, 0xff, 0x00, 0x00, 0x00
418
419# The following 4 encodings are equivalent, as confirmed by the 'xed64'
420# decoder tool provided by Intel, which we assume to be canonical even
421# if the real silicon does something different. If that should happen,
422# then we'll all have disassembler bugs to repair.
423
424# Try all combinations of EVEX.x and REX.b:
425# CHECK: vaddps	287453952(%rip), %zmm20, %zmm15
4260x62 0x11 0x5c 0x40 0x58 0x3d 0x00 0x33 0x22 0x11
427# CHECK: vaddps	287453952(%rip), %zmm20, %zmm15
4280x62 0x31 0x5c 0x40 0x58 0x3d 0x00 0x33 0x22 0x11
429# CHECK: vaddps	287453952(%rip), %zmm20, %zmm15
4300x62 0x51 0x5c 0x40 0x58 0x3d 0x00 0x33 0x22 0x11
431# CHECK: vaddps	287453952(%rip), %zmm20, %zmm15
4320x62 0x71 0x5c 0x40 0x58 0x3d 0x00 0x33 0x22 0x11
433
434# Known bugs: these use a SIB byte. The index register is incorrectly
435# printed as an xmm register. Indeed there are "gather" load instructions
436# taking a vector of indices, but ONLY those instructions can do that.
437# The CHECK lines test the current incorrect output; FIXME is desired.
438# CHECK: vaddps (%r10,%xmm9), %zmm20, %zmm15
439# FIXME: vaddps (%r10,%r9), %zmm20, %zmm15
4400x62 0x11 0x5c 0x40 0x58 0x3c 0x0a
441
442# CHECK: vaddps (%rdx,%xmm9), %zmm20, %zmm15
443# FIXME: vaddps (%rdx,%r9), %zmm20, %zmm15
4440x62 0x31 0x5c 0x40 0x58 0x3c 0x0a
445
446# CHECK: vaddps (%r10,%xmm1), %zmm20, %zmm15
447# FIXME: vaddps (%r10,%rcx), %zmm20, %zmm15
4480x62 0x51 0x5c 0x40 0x58 0x3c 0x0a
449
450# CHECK: vaddps (%rdx,%xmm1), %zmm20, %zmm15
451# FIXME: vaddps (%rdx,%rcx), %zmm20, %zmm15
4520x62 0x71 0x5c 0x40 0x58 0x3c 0x0a
453
454# CHECK: callq 32767
4550xe8 0xff 0x7f 0x00 0x00
456
457# CHECK: callq -32769
4580xe8 0xff 0x7f 0xff 0xff
459