Home | History | Annotate | Download | only in X86
      1 // RUN: llvm-mc -triple i386-unknown-unknown --show-encoding %s | FileCheck %s
      2 
      3 	pause
      4 // CHECK: pause
      5 // CHECK: encoding: [0xf3,0x90]
      6 	sfence
      7 // CHECK: sfence
      8 // CHECK: encoding: [0x0f,0xae,0xf8]
      9 	lfence
     10 // CHECK: lfence
     11 // CHECK: encoding: [0x0f,0xae,0xe8]
     12 	mfence
     13 // CHECK: mfence
     14 // CHECK: encoding: [0x0f,0xae,0xf0]
     15 	monitor
     16 // CHECK: monitor
     17 // CHECK: encoding: [0x0f,0x01,0xc8]
     18 	monitor %eax, %ecx, %edx
     19 // CHECK: monitor
     20 // CHECK: encoding: [0x0f,0x01,0xc8]
     21 	mwait
     22 // CHECK: mwait
     23 // CHECK: encoding: [0x0f,0x01,0xc9]
     24 	mwait %eax, %ecx
     25 // CHECK: mwait
     26 // CHECK: encoding: [0x0f,0x01,0xc9]
     27 
     28 	vmcall
     29 // CHECK: vmcall
     30 // CHECK: encoding: [0x0f,0x01,0xc1]
     31 	vmfunc
     32 // CHECK: vmfunc
     33 // CHECK: encoding: [0x0f,0x01,0xd4]
     34 	vmlaunch
     35 // CHECK: vmlaunch
     36 // CHECK: encoding: [0x0f,0x01,0xc2]
     37 	vmresume
     38 // CHECK: vmresume
     39 // CHECK: encoding: [0x0f,0x01,0xc3]
     40 	vmxoff
     41 // CHECK: vmxoff
     42 // CHECK: encoding: [0x0f,0x01,0xc4]
     43 	swapgs
     44 // CHECK: swapgs
     45 // CHECK: encoding: [0x0f,0x01,0xf8]
     46 
     47 	vmrun %eax
     48 // CHECK: vmrun %eax
     49 // CHECK: encoding: [0x0f,0x01,0xd8]
     50 	vmmcall
     51 // CHECK: vmmcall
     52 // CHECK: encoding: [0x0f,0x01,0xd9]
     53 	vmload %eax
     54 // CHECK: vmload %eax
     55 // CHECK: encoding: [0x0f,0x01,0xda]
     56 	vmsave %eax
     57 // CHECK: vmsave %eax
     58 // CHECK: encoding: [0x0f,0x01,0xdb]
     59 	stgi
     60 // CHECK: stgi
     61 // CHECK: encoding: [0x0f,0x01,0xdc]
     62 	clgi
     63 // CHECK: clgi
     64 // CHECK: encoding: [0x0f,0x01,0xdd]
     65 	skinit %eax
     66 // CHECK: skinit %eax
     67 // CHECK: encoding: [0x0f,0x01,0xde]
     68 	invlpga %ecx, %eax
     69 // CHECK: invlpga %ecx, %eax
     70 // CHECK: encoding: [0x0f,0x01,0xdf]
     71 
     72 	rdtscp
     73 // CHECK: rdtscp
     74 // CHECK:  encoding: [0x0f,0x01,0xf9]
     75 
     76 
     77 // CHECK: movl	%eax, 16(%ebp)          # encoding: [0x89,0x45,0x10]
     78 	movl	%eax, 16(%ebp)
     79 // CHECK: movl	%eax, -16(%ebp)          # encoding: [0x89,0x45,0xf0]
     80 	movl	%eax, -16(%ebp)
     81 
     82 // CHECK: testb	%bl, %cl                # encoding: [0x84,0xcb]
     83         testb %bl, %cl
     84 
     85 // CHECK: cmpl	%eax, %ebx              # encoding: [0x39,0xc3]
     86         cmpl %eax, %ebx
     87 
     88 // CHECK: addw	%ax, %ax                # encoding: [0x66,0x01,0xc0]
     89         addw %ax, %ax
     90 
     91 // CHECK: shrl	%eax                    # encoding: [0xd1,0xe8]
     92         shrl $1, %eax
     93 
     94 // CHECK: shll	%eax                    # encoding: [0xd1,0xe0]
     95         sall $1, %eax
     96 // CHECK: shll	%eax                    # encoding: [0xd1,0xe0]
     97         sal $1, %eax
     98 
     99 // moffset forms of moves, rdar://7947184
    100 movb	0, %al    // CHECK: movb 0, %al  # encoding: [0xa0,0x00,0x00,0x00,0x00]
    101 movw	0, %ax    // CHECK: movw 0, %ax  # encoding: [0x66,0xa1,0x00,0x00,0x00,0x00]
    102 movl	0, %eax   // CHECK: movl 0, %eax  # encoding: [0xa1,0x00,0x00,0x00,0x00]
    103 
    104 // rdar://7973775
    105 into
    106 // CHECK: into
    107 // CHECK:  encoding: [0xce]
    108 int3
    109 // CHECK: int3
    110 // CHECK:  encoding: [0xcc]
    111 int $4
    112 // CHECK: int $4
    113 // CHECK:  encoding: [0xcd,0x04]
    114 int $255
    115 // CHECK: int $255
    116 // CHECK:  encoding: [0xcd,0xff]
    117 
    118 // CHECK: pushfl	# encoding: [0x9c]
    119         pushf
    120 // CHECK: pushfl	# encoding: [0x9c]
    121         pushfl
    122 // CHECK: popfl	        # encoding: [0x9d]
    123         popf
    124 // CHECK: popfl	        # encoding: [0x9d]
    125         popfl
    126 
    127 // rdar://8014869
    128 retl
    129 // CHECK: ret
    130 // CHECK:  encoding: [0xc3]
    131 
    132 // rdar://7973854
    133 // CHECK: cmoval	%eax, %edx
    134 // CHECK:  encoding: [0x0f,0x47,0xd0]
    135         	cmoval	%eax,%edx
    136 
    137 // CHECK: cmovael	%eax, %edx
    138 // CHECK:  encoding: [0x0f,0x43,0xd0]
    139         	cmovael	%eax,%edx
    140 
    141 // CHECK: cmovbel	%eax, %edx
    142 // CHECK:  encoding: [0x0f,0x46,0xd0]
    143         	cmovbel	%eax,%edx
    144 
    145 // CHECK: cmovbl	%eax, %edx
    146 // CHECK:  encoding: [0x0f,0x42,0xd0]
    147         	cmovbl	%eax,%edx
    148 
    149 // CHECK: cmovbw %bx, %bx
    150 cmovnae	%bx,%bx
    151 
    152 
    153 // CHECK: cmovbel	%eax, %edx
    154 // CHECK:  encoding: [0x0f,0x46,0xd0]
    155         	cmovbel	%eax,%edx
    156 
    157 // CHECK: cmovbl	%eax, %edx
    158 // CHECK:  encoding: [0x0f,0x42,0xd0]
    159         	cmovcl	%eax,%edx
    160 
    161 // CHECK: cmovel	%eax, %edx
    162 // CHECK:  encoding: [0x0f,0x44,0xd0]
    163         	cmovel	%eax,%edx
    164 
    165 // CHECK: cmovgl	%eax, %edx
    166 // CHECK:  encoding: [0x0f,0x4f,0xd0]
    167         	cmovgl	%eax,%edx
    168 
    169 // CHECK: cmovgel	%eax, %edx
    170 // CHECK:  encoding: [0x0f,0x4d,0xd0]
    171         	cmovgel	%eax,%edx
    172 
    173 // CHECK: cmovll	%eax, %edx
    174 // CHECK:  encoding: [0x0f,0x4c,0xd0]
    175         	cmovll	%eax,%edx
    176 
    177 // CHECK: cmovlel	%eax, %edx
    178 // CHECK:  encoding: [0x0f,0x4e,0xd0]
    179         	cmovlel	%eax,%edx
    180 
    181 // CHECK: cmovbel	%eax, %edx
    182 // CHECK:  encoding: [0x0f,0x46,0xd0]
    183         	cmovnal	%eax,%edx
    184 
    185 // CHECK: cmovnel	%eax, %edx
    186 // CHECK:  encoding: [0x0f,0x45,0xd0]
    187         	cmovnel	%eax,%edx
    188 
    189 // CHECK: cmovael	%eax, %edx
    190 // CHECK:  encoding: [0x0f,0x43,0xd0]
    191         	cmovnbl	%eax,%edx
    192 
    193 // CHECK: cmoval	%eax, %edx
    194 // CHECK:  encoding: [0x0f,0x47,0xd0]
    195         	cmovnbel	%eax,%edx
    196 
    197 // CHECK: cmovael	%eax, %edx
    198 // CHECK:  encoding: [0x0f,0x43,0xd0]
    199         	cmovncl	%eax,%edx
    200 
    201 // CHECK: cmovnel	%eax, %edx
    202 // CHECK:  encoding: [0x0f,0x45,0xd0]
    203         	cmovnel	%eax,%edx
    204 
    205 // CHECK: cmovlel	%eax, %edx
    206 // CHECK:  encoding: [0x0f,0x4e,0xd0]
    207         	cmovngl	%eax,%edx
    208 
    209 // CHECK: cmovgel	%eax, %edx
    210 // CHECK:  encoding: [0x0f,0x4d,0xd0]
    211         	cmovnl	%eax,%edx
    212 
    213 // CHECK: cmovnel	%eax, %edx
    214 // CHECK:  encoding: [0x0f,0x45,0xd0]
    215         	cmovnel	%eax,%edx
    216 
    217 // CHECK: cmovlel	%eax, %edx
    218 // CHECK:  encoding: [0x0f,0x4e,0xd0]
    219         	cmovngl	%eax,%edx
    220 
    221 // CHECK: cmovll	%eax, %edx
    222 // CHECK:  encoding: [0x0f,0x4c,0xd0]
    223         	cmovngel	%eax,%edx
    224 
    225 // CHECK: cmovgel	%eax, %edx
    226 // CHECK:  encoding: [0x0f,0x4d,0xd0]
    227         	cmovnll	%eax,%edx
    228 
    229 // CHECK: cmovgl	%eax, %edx
    230 // CHECK:  encoding: [0x0f,0x4f,0xd0]
    231         	cmovnlel	%eax,%edx
    232 
    233 // CHECK: cmovnol	%eax, %edx
    234 // CHECK:  encoding: [0x0f,0x41,0xd0]
    235         	cmovnol	%eax,%edx
    236 
    237 // CHECK: cmovnpl	%eax, %edx
    238 // CHECK:  encoding: [0x0f,0x4b,0xd0]
    239         	cmovnpl	%eax,%edx
    240 
    241 // CHECK: cmovnsl	%eax, %edx
    242 // CHECK:  encoding: [0x0f,0x49,0xd0]
    243         	cmovnsl	%eax,%edx
    244 
    245 // CHECK: cmovnel	%eax, %edx
    246 // CHECK:  encoding: [0x0f,0x45,0xd0]
    247         	cmovnzl	%eax,%edx
    248 
    249 // CHECK: cmovol	%eax, %edx
    250 // CHECK:  encoding: [0x0f,0x40,0xd0]
    251         	cmovol	%eax,%edx
    252 
    253 // CHECK: cmovpl	%eax, %edx
    254 // CHECK:  encoding: [0x0f,0x4a,0xd0]
    255         	cmovpl	%eax,%edx
    256 
    257 // CHECK: cmovsl	%eax, %edx
    258 // CHECK:  encoding: [0x0f,0x48,0xd0]
    259         	cmovsl	%eax,%edx
    260 
    261 // CHECK: cmovel	%eax, %edx
    262 // CHECK:  encoding: [0x0f,0x44,0xd0]
    263         	cmovzl	%eax,%edx
    264 
    265 // CHECK: cmpps	$0, %xmm0, %xmm1
    266 // CHECK: encoding: [0x0f,0xc2,0xc8,0x00]
    267         cmpps $0, %xmm0, %xmm1
    268 // CHECK:	cmpps	$0, (%eax), %xmm1
    269 // CHECK: encoding: [0x0f,0xc2,0x08,0x00]
    270         cmpps $0, 0(%eax), %xmm1
    271 // CHECK:	cmppd	$0, %xmm0, %xmm1
    272 // CHECK: encoding: [0x66,0x0f,0xc2,0xc8,0x00]
    273         cmppd $0, %xmm0, %xmm1
    274 // CHECK:	cmppd	$0, (%eax), %xmm1
    275 // CHECK: encoding: [0x66,0x0f,0xc2,0x08,0x00]
    276         cmppd $0, 0(%eax), %xmm1
    277 // CHECK:	cmpss	$0, %xmm0, %xmm1
    278 // CHECK: encoding: [0xf3,0x0f,0xc2,0xc8,0x00]
    279         cmpss $0, %xmm0, %xmm1
    280 // CHECK:	cmpss	$0, (%eax), %xmm1
    281 // CHECK: encoding: [0xf3,0x0f,0xc2,0x08,0x00]
    282         cmpss $0, 0(%eax), %xmm1
    283 // CHECK:	cmpsd	$0, %xmm0, %xmm1
    284 // CHECK: encoding: [0xf2,0x0f,0xc2,0xc8,0x00]
    285         cmpsd $0, %xmm0, %xmm1
    286 // CHECK:	cmpsd	$0, (%eax), %xmm1
    287 // CHECK: encoding: [0xf2,0x0f,0xc2,0x08,0x00]
    288         cmpsd $0, 0(%eax), %xmm1
    289 
    290 // Check matching of instructions which embed the SSE comparison code.
    291 
    292 // CHECK: cmpps $0, %xmm0, %xmm1
    293 // CHECK: encoding: [0x0f,0xc2,0xc8,0x00]
    294         cmpeqps %xmm0, %xmm1
    295 
    296 // CHECK: cmppd $1, %xmm0, %xmm1
    297 // CHECK: encoding: [0x66,0x0f,0xc2,0xc8,0x01]
    298         cmpltpd %xmm0, %xmm1
    299 
    300 // CHECK: cmpss $2, %xmm0, %xmm1
    301 // CHECK: encoding: [0xf3,0x0f,0xc2,0xc8,0x02]
    302         cmpless %xmm0, %xmm1
    303 
    304 // CHECK: cmppd $3, %xmm0, %xmm1
    305 // CHECK: encoding: [0x66,0x0f,0xc2,0xc8,0x03]
    306         cmpunordpd %xmm0, %xmm1
    307 
    308 // CHECK: cmpps $4, %xmm0, %xmm1
    309 // CHECK: encoding: [0x0f,0xc2,0xc8,0x04]
    310         cmpneqps %xmm0, %xmm1
    311 
    312 // CHECK: cmppd $5, %xmm0, %xmm1
    313 // CHECK: encoding: [0x66,0x0f,0xc2,0xc8,0x05]
    314         cmpnltpd %xmm0, %xmm1
    315 
    316 // CHECK: cmpss $6, %xmm0, %xmm1
    317 // CHECK: encoding: [0xf3,0x0f,0xc2,0xc8,0x06]
    318         cmpnless %xmm0, %xmm1
    319 
    320 // CHECK: cmpsd $7, %xmm0, %xmm1
    321 // CHECK: encoding: [0xf2,0x0f,0xc2,0xc8,0x07]
    322         cmpordsd %xmm0, %xmm1
    323 
    324 // rdar://7995856
    325 // CHECK: fmul	%st(0)
    326 // CHECK:  encoding: [0xd8,0xc8]
    327         fmul %st(0), %st
    328 
    329 // CHECK: fadd	%st(0)
    330 // CHECK:  encoding: [0xd8,0xc0]
    331         fadd %st(0), %st
    332 
    333 // CHECK: fsub	%st(0)
    334 // CHECK:  encoding: [0xd8,0xe0]
    335         fsub %st(0), %st
    336 
    337 // CHECK: fsubr	%st(0)
    338 // CHECK:  encoding: [0xd8,0xe8]
    339         fsubr %st(0), %st
    340 
    341 // CHECK: fdivr	%st(0)
    342 // CHECK:  encoding: [0xd8,0xf8]
    343         fdivr %st(0), %st
    344 
    345 // CHECK: fdiv	%st(0)
    346 // CHECK:  encoding: [0xd8,0xf0]
    347         fdiv %st(0), %st
    348 
    349 // radr://8017519
    350 // CHECK: movl	%cs, %eax
    351 // CHECK:  encoding: [0x8c,0xc8]
    352         movl %cs, %eax
    353 
    354 // CHECK: movw	%cs, %ax
    355 // CHECK:  encoding: [0x66,0x8c,0xc8]
    356         movw %cs, %ax
    357 
    358 // CHECK: movl	%cs, (%eax)
    359 // CHECK:  encoding: [0x8c,0x08]
    360         movl %cs, (%eax)
    361 
    362 // CHECK: movw	%cs, (%eax)
    363 // CHECK:  encoding: [0x66,0x8c,0x08]
    364         movw %cs, (%eax)
    365 
    366 // CHECK: movl	%eax, %cs
    367 // CHECK:  encoding: [0x8e,0xc8]
    368         movl %eax, %cs
    369 
    370 // CHECK: movl	(%eax), %cs
    371 // CHECK:  encoding: [0x8e,0x08]
    372         movl (%eax), %cs
    373 
    374 // CHECK: movw	(%eax), %cs
    375 // CHECK:  encoding: [0x66,0x8e,0x08]
    376         movw (%eax), %cs
    377 
    378 // radr://8033374
    379 // CHECK: movl	%cr0, %eax
    380 // CHECK:  encoding: [0x0f,0x20,0xc0]
    381         movl %cr0,%eax
    382 
    383 // CHECK: movl	%cr1, %eax
    384 // CHECK:  encoding: [0x0f,0x20,0xc8]
    385         movl %cr1,%eax
    386 
    387 // CHECK: movl	%cr2, %eax
    388 // CHECK:  encoding: [0x0f,0x20,0xd0]
    389         movl %cr2,%eax
    390 
    391 // CHECK: movl	%cr3, %eax
    392 // CHECK:  encoding: [0x0f,0x20,0xd8]
    393         movl %cr3,%eax
    394 
    395 // CHECK: movl	%cr4, %eax
    396 // CHECK:  encoding: [0x0f,0x20,0xe0]
    397         movl %cr4,%eax
    398 
    399 // CHECK: movl	%dr0, %eax
    400 // CHECK:  encoding: [0x0f,0x21,0xc0]
    401         movl %dr0,%eax
    402 
    403 // CHECK: movl	%dr1, %eax
    404 // CHECK:  encoding: [0x0f,0x21,0xc8]
    405         movl %dr1,%eax
    406 
    407 // CHECK: movl	%dr1, %eax
    408 // CHECK:  encoding: [0x0f,0x21,0xc8]
    409         movl %dr1,%eax
    410 
    411 // CHECK: movl	%dr2, %eax
    412 // CHECK:  encoding: [0x0f,0x21,0xd0]
    413         movl %dr2,%eax
    414 
    415 // CHECK: movl	%dr3, %eax
    416 // CHECK:  encoding: [0x0f,0x21,0xd8]
    417         movl %dr3,%eax
    418 
    419 // CHECK: movl	%dr4, %eax
    420 // CHECK:  encoding: [0x0f,0x21,0xe0]
    421         movl %dr4,%eax
    422 
    423 // CHECK: movl	%dr5, %eax
    424 // CHECK:  encoding: [0x0f,0x21,0xe8]
    425         movl %dr5,%eax
    426 
    427 // CHECK: movl	%dr6, %eax
    428 // CHECK:  encoding: [0x0f,0x21,0xf0]
    429         movl %dr6,%eax
    430 
    431 // CHECK: movl	%dr7, %eax
    432 // CHECK:  encoding: [0x0f,0x21,0xf8]
    433         movl %dr7,%eax
    434 
    435 // radr://8017522
    436 // CHECK: wait
    437 // CHECK:  encoding: [0x9b]
    438 	fwait
    439 
    440 // rdar://7873482
    441 // CHECK: [0x65,0x8b,0x05,0x7c,0x00,0x00,0x00]
    442 // FIXME: This is a correct bug poor encoding: Use 65 a1 7c 00 00 00
    443         movl	%gs:124, %eax
    444 
    445 // CHECK: pusha
    446 // CHECK:  encoding: [0x60]
    447         	pusha
    448 
    449 // CHECK: popa
    450 // CHECK:  encoding: [0x61]
    451         	popa
    452 
    453 // CHECK: pushal
    454 // CHECK:  encoding: [0x60]
    455         	pushal
    456 
    457 // CHECK: popal
    458 // CHECK:  encoding: [0x61]
    459         	popal
    460 
    461 // CHECK: jmpl *8(%eax)
    462 // CHECK:   encoding: [0xff,0x60,0x08]
    463 	jmp	*8(%eax)
    464 
    465 // PR7465
    466 // CHECK: lcalll $2, $4660
    467 // CHECK:   encoding: [0x9a,0x34,0x12,0x00,0x00,0x02,0x00]
    468 lcalll $0x2, $0x1234
    469 
    470 
    471 // rdar://8061602
    472 L1:
    473   jcxz L1
    474 // CHECK: jcxz L1
    475 // CHECK:   encoding: [0x67,0xe3,A]
    476   jecxz L1
    477 // CHECK: jecxz L1
    478 // CHECK:   encoding: [0xe3,A]
    479 
    480 // rdar://8403974
    481 iret
    482 // CHECK: iretl
    483 // CHECK: encoding: [0xcf]
    484 iretw
    485 // CHECK: iretw
    486 // CHECK: encoding: [0x66,0xcf]
    487 iretl
    488 // CHECK: iretl
    489 // CHECK: encoding: [0xcf]
    490 
    491 // rdar://8403907
    492 sysret
    493 // CHECK: sysretl
    494 // CHECK: encoding: [0x0f,0x07]
    495 sysretl
    496 // CHECK: sysretl
    497 // CHECK: encoding: [0x0f,0x07]
    498 
    499 // rdar://8018260
    500 testl	%ecx, -24(%ebp)
    501 // CHECK: testl	-24(%ebp), %ecx
    502 testl	-24(%ebp), %ecx
    503 // CHECK: testl	-24(%ebp), %ecx
    504 
    505 
    506 // rdar://8407242
    507 push %cs
    508 // CHECK: pushl	%cs
    509 // CHECK: encoding: [0x0e]
    510 push %ds
    511 // CHECK: pushl	%ds
    512 // CHECK: encoding: [0x1e]
    513 push %ss
    514 // CHECK: pushl	%ss
    515 // CHECK: encoding: [0x16]
    516 push %es
    517 // CHECK: pushl	%es
    518 // CHECK: encoding: [0x06]
    519 push %fs
    520 // CHECK: pushl	%fs
    521 // CHECK: encoding: [0x0f,0xa0]
    522 push %gs
    523 // CHECK: pushl	%gs
    524 // CHECK: encoding: [0x0f,0xa8]
    525 
    526 pushw %cs
    527 // CHECK: pushw	%cs
    528 // CHECK: encoding: [0x66,0x0e]
    529 pushw %ds
    530 // CHECK: pushw	%ds
    531 // CHECK: encoding: [0x66,0x1e]
    532 pushw %ss
    533 // CHECK: pushw	%ss
    534 // CHECK: encoding: [0x66,0x16]
    535 pushw %es
    536 // CHECK: pushw	%es
    537 // CHECK: encoding: [0x66,0x06]
    538 pushw %fs
    539 // CHECK: pushw	%fs
    540 // CHECK: encoding: [0x66,0x0f,0xa0]
    541 pushw %gs
    542 // CHECK: pushw	%gs
    543 // CHECK: encoding: [0x66,0x0f,0xa8]
    544 
    545 pop %ss
    546 // CHECK: popl	%ss
    547 // CHECK: encoding: [0x17]
    548 pop %ds
    549 // CHECK: popl	%ds
    550 // CHECK: encoding: [0x1f]
    551 pop %es
    552 // CHECK: popl	%es
    553 // CHECK: encoding: [0x07]
    554 
    555 // rdar://8408129
    556 pushfd
    557 // CHECK: pushfl
    558 popfd
    559 // CHECK: popfl
    560 pushfl
    561 // CHECK: pushfl
    562 popfl
    563 // CHECK: popfl
    564 
    565 
    566 // rdar://8416805
    567 	setc	%bl
    568 	setnae	%bl
    569 	setnb	%bl
    570 	setnc	%bl
    571 	setna	%bl
    572 	setnbe	%bl
    573 	setpe	%bl
    574 	setpo	%bl
    575 	setnge	%bl
    576 	setnl	%bl
    577 	setng	%bl
    578 	setnle	%bl
    579 
    580 // PR8686
    581         setneb  %cl // CHECK: setne %cl
    582 	setcb	%bl // CHECK: setb %bl
    583 	setnaeb	%bl // CHECK: setb %bl
    584 
    585 
    586 // CHECK: lcalll	$31438, $31438
    587 // CHECK: lcalll	$31438, $31438
    588 // CHECK: ljmpl	$31438, $31438
    589 // CHECK: ljmpl	$31438, $31438
    590 
    591 calll	$0x7ace,$0x7ace
    592 lcalll	$0x7ace,$0x7ace
    593 jmpl	$0x7ace,$0x7ace
    594 ljmpl	$0x7ace,$0x7ace
    595 
    596 // CHECK: lcalll	$31438, $31438
    597 // CHECK: lcalll	$31438, $31438
    598 // CHECK: ljmpl	$31438, $31438
    599 // CHECK: ljmpl	$31438, $31438
    600 
    601 call	$0x7ace,$0x7ace
    602 lcall	$0x7ace,$0x7ace
    603 jmp	$0x7ace,$0x7ace
    604 ljmp	$0x7ace,$0x7ace
    605 
    606 // rdar://8456370
    607 // CHECK: calll a
    608  calll a
    609 
    610 // CHECK:	incb	%al # encoding: [0xfe,0xc0]
    611 	incb %al
    612 
    613 // CHECK:	incw	%ax # encoding: [0x66,0x40]
    614 	incw %ax
    615 
    616 // CHECK:	incl	%eax # encoding: [0x40]
    617 	incl %eax
    618 
    619 // CHECK:	decb	%al # encoding: [0xfe,0xc8]
    620 	decb %al
    621 
    622 // CHECK:	decw	%ax # encoding: [0x66,0x48]
    623 	decw %ax
    624 
    625 // CHECK:	decl	%eax # encoding: [0x48]
    626 	decl %eax
    627 
    628 // CHECK: pshufw $14, %mm4, %mm0 # encoding: [0x0f,0x70,0xc4,0x0e]
    629 pshufw $14, %mm4, %mm0
    630 
    631 // CHECK: pshufw $90, %mm4, %mm0 # encoding: [0x0f,0x70,0xc4,0x5a]
    632 // PR8288
    633 pshufw $90, %mm4, %mm0
    634 
    635 // rdar://8416805
    636 // CHECK: aaa
    637 // CHECK:  encoding: [0x37]
    638         	aaa
    639 
    640 // CHECK: aad	$1
    641 // CHECK:  encoding: [0xd5,0x01]
    642         	aad	$1
    643 
    644 // CHECK: aad
    645 // CHECK:  encoding: [0xd5,0x0a]
    646         	aad	$0xA
    647 
    648 // CHECK: aad
    649 // CHECK:  encoding: [0xd5,0x0a]
    650         	aad
    651 
    652 // CHECK: aam	$2
    653 // CHECK:  encoding: [0xd4,0x02]
    654         	aam	$2
    655 
    656 // CHECK: aam
    657 // CHECK:  encoding: [0xd4,0x0a]
    658         	aam	$0xA
    659 
    660 // CHECK: aam
    661 // CHECK:  encoding: [0xd4,0x0a]
    662         	aam
    663 
    664 // CHECK: aas
    665 // CHECK:  encoding: [0x3f]
    666         	aas
    667 
    668 // CHECK: daa
    669 // CHECK:  encoding: [0x27]
    670         	daa
    671 
    672 // CHECK: das
    673 // CHECK:  encoding: [0x2f]
    674         	das
    675 
    676 // CHECK: retw	$31438
    677 // CHECK:  encoding: [0x66,0xc2,0xce,0x7a]
    678         	retw	$0x7ace
    679 
    680 // CHECK: lretw	$31438
    681 // CHECK:  encoding: [0x66,0xca,0xce,0x7a]
    682         	lretw	$0x7ace
    683 
    684 // CHECK: bound	2(%eax), %bx
    685 // CHECK:  encoding: [0x66,0x62,0x58,0x02]
    686         	bound	2(%eax),%bx
    687 
    688 // CHECK: bound	4(%ebx), %ecx
    689 // CHECK:  encoding: [0x62,0x4b,0x04]
    690         	bound	4(%ebx),%ecx
    691 
    692 // CHECK: arpl	%bx, %bx
    693 // CHECK:  encoding: [0x63,0xdb]
    694         	arpl	%bx,%bx
    695 
    696 // CHECK: arpl	%bx, 6(%ecx)
    697 // CHECK:  encoding: [0x63,0x59,0x06]
    698         	arpl	%bx,6(%ecx)
    699 
    700 // CHECK: lgdtw	4(%eax)
    701 // CHECK:  encoding: [0x66,0x0f,0x01,0x50,0x04]
    702         	lgdtw	4(%eax)
    703 
    704 // CHECK: lgdt	4(%eax)
    705 // CHECK:  encoding: [0x0f,0x01,0x50,0x04]
    706         	lgdt	4(%eax)
    707 
    708 // CHECK: lgdt	4(%eax)
    709 // CHECK:  encoding: [0x0f,0x01,0x50,0x04]
    710         	lgdtl	4(%eax)
    711 
    712 // CHECK: lidtw	4(%eax)
    713 // CHECK:  encoding: [0x66,0x0f,0x01,0x58,0x04]
    714         	lidtw	4(%eax)
    715 
    716 // CHECK: lidt	4(%eax)
    717 // CHECK:  encoding: [0x0f,0x01,0x58,0x04]
    718         	lidt	4(%eax)
    719 
    720 // CHECK: lidt	4(%eax)
    721 // CHECK:  encoding: [0x0f,0x01,0x58,0x04]
    722         	lidtl	4(%eax)
    723 
    724 // CHECK: sgdtw	4(%eax)
    725 // CHECK:  encoding: [0x66,0x0f,0x01,0x40,0x04]
    726         	sgdtw	4(%eax)
    727 
    728 // CHECK: sgdt	4(%eax)
    729 // CHECK:  encoding: [0x0f,0x01,0x40,0x04]
    730         	sgdt	4(%eax)
    731 
    732 // CHECK: sgdt	4(%eax)
    733 // CHECK:  encoding: [0x0f,0x01,0x40,0x04]
    734         	sgdtl	4(%eax)
    735 
    736 // CHECK: sidtw	4(%eax)
    737 // CHECK:  encoding: [0x66,0x0f,0x01,0x48,0x04]
    738         	sidtw	4(%eax)
    739 
    740 // CHECK: sidt	4(%eax)
    741 // CHECK:  encoding: [0x0f,0x01,0x48,0x04]
    742         	sidt	4(%eax)
    743 
    744 // CHECK: sidt	4(%eax)
    745 // CHECK:  encoding: [0x0f,0x01,0x48,0x04]
    746         	sidtl	4(%eax)
    747 
    748 // CHECK: fcompi	%st(2)
    749 // CHECK:  encoding: [0xdf,0xf2]
    750         	fcompi	%st(2), %st
    751 
    752 // CHECK: fcompi	%st(2)
    753 // CHECK:  encoding: [0xdf,0xf2]
    754         	fcompi	%st(2)
    755 
    756 // CHECK: fcompi
    757 // CHECK:  encoding: [0xdf,0xf1]
    758         	fcompi
    759 
    760 // CHECK: fucompi	%st(2)
    761 // CHECK:  encoding: [0xdf,0xea]
    762         	fucompi	%st(2),%st
    763 
    764 // CHECK: fucompi	%st(2)
    765 // CHECK:  encoding: [0xdf,0xea]
    766         	fucompi	%st(2)
    767 
    768 // CHECK: fucompi
    769 // CHECK:  encoding: [0xdf,0xe9]
    770         	fucompi
    771 
    772 // CHECK: fldcw	32493
    773 // CHECK:  encoding: [0xd9,0x2d,0xed,0x7e,0x00,0x00]
    774         	fldcww	0x7eed
    775 
    776 // CHECK: fldcw	32493
    777 // CHECK:  encoding: [0xd9,0x2d,0xed,0x7e,0x00,0x00]
    778         	fldcw	0x7eed
    779 
    780 // CHECK: fnstcw	32493
    781 // CHECK:  encoding: [0xd9,0x3d,0xed,0x7e,0x00,0x00]
    782         	fnstcww	0x7eed
    783 
    784 // CHECK: fnstcw	32493
    785 // CHECK:  encoding: [0xd9,0x3d,0xed,0x7e,0x00,0x00]
    786         	fnstcw	0x7eed
    787 
    788 // CHECK: wait
    789 // CHECK:  encoding: [0x9b]
    790         	fstcww	0x7eed
    791 
    792 // CHECK: wait
    793 // CHECK:  encoding: [0x9b]
    794         	fstcw	0x7eed
    795 
    796 // CHECK: fnstsw	32493
    797 // CHECK:  encoding: [0xdd,0x3d,0xed,0x7e,0x00,0x00]
    798         	fnstsww	0x7eed
    799 
    800 // CHECK: fnstsw	32493
    801 // CHECK:  encoding: [0xdd,0x3d,0xed,0x7e,0x00,0x00]
    802         	fnstsw	0x7eed
    803 
    804 // CHECK: wait
    805 // CHECK:  encoding: [0x9b]
    806         	fstsww	0x7eed
    807 
    808 // CHECK: wait
    809 // CHECK:  encoding: [0x9b]
    810         	fstsw	0x7eed
    811 
    812 // CHECK: verr	32493
    813 // CHECK:  encoding: [0x0f,0x00,0x25,0xed,0x7e,0x00,0x00]
    814         	verrw	0x7eed
    815 
    816 // CHECK: verr	32493
    817 // CHECK:  encoding: [0x0f,0x00,0x25,0xed,0x7e,0x00,0x00]
    818         	verr	0x7eed
    819 
    820 // CHECK: wait
    821 // CHECK:  encoding: [0x9b]
    822         	fclex
    823 
    824 // CHECK: fnclex
    825 // CHECK:  encoding: [0xdb,0xe2]
    826         	fnclex
    827 
    828 // CHECK: ud2
    829 // CHECK:  encoding: [0x0f,0x0b]
    830         	ud2
    831 
    832 // CHECK: ud2
    833 // CHECK:  encoding: [0x0f,0x0b]
    834         	ud2a
    835 
    836 // CHECK: ud2b
    837 // CHECK:  encoding: [0x0f,0xb9]
    838         	ud2b
    839 
    840 // CHECK: loope 0
    841 // CHECK: encoding: [0xe1,A]
    842 	loopz 0
    843 
    844 // CHECK: loopne 0
    845 // CHECK: encoding: [0xe0,A]
    846 	loopnz 0
    847 
    848 // CHECK: outsb # encoding: [0x6e]
    849 // CHECK: outsb
    850 // CHECK: outsb
    851 	outsb
    852 	outsb	%ds:(%esi), %dx
    853 	outsb	(%esi), %dx
    854 
    855 // CHECK: outsw # encoding: [0x66,0x6f]
    856 // CHECK: outsw
    857 // CHECK: outsw
    858 	outsw
    859 	outsw	%ds:(%esi), %dx
    860 	outsw	(%esi), %dx
    861 
    862 // CHECK: outsl # encoding: [0x6f]
    863 // CHECK: outsl
    864 	outsl
    865 	outsl	%ds:(%esi), %dx
    866 	outsl	(%esi), %dx
    867 
    868 // CHECK: insb # encoding: [0x6c]
    869 // CHECK: insb
    870 	insb
    871 	insb	%dx, %es:(%edi)
    872 
    873 // CHECK: insw # encoding: [0x66,0x6d]
    874 // CHECK: insw
    875 	insw
    876 	insw	%dx, %es:(%edi)
    877 
    878 // CHECK: insl # encoding: [0x6d]
    879 // CHECK: insl
    880 	insl
    881 	insl	%dx, %es:(%edi)
    882 
    883 // CHECK: movsb # encoding: [0xa4]
    884 // CHECK: movsb
    885 // CHECK: movsb
    886 	movsb
    887 	movsb	%ds:(%esi), %es:(%edi)
    888 	movsb	(%esi), %es:(%edi)
    889 
    890 // CHECK: movsw # encoding: [0x66,0xa5]
    891 // CHECK: movsw
    892 // CHECK: movsw
    893 	movsw
    894 	movsw	%ds:(%esi), %es:(%edi)
    895 	movsw	(%esi), %es:(%edi)
    896 
    897 // CHECK: movsd # encoding: [0xa5]
    898 // CHECK: movsd
    899 // CHECK: movsd
    900 	movsl
    901 	movsl	%ds:(%esi), %es:(%edi)
    902 	movsl	(%esi), %es:(%edi)
    903 
    904 // CHECK: lodsb # encoding: [0xac]
    905 // CHECK: lodsb
    906 // CHECK: lodsb
    907 // CHECK: lodsb
    908 // CHECK: lodsb
    909 	lodsb
    910 	lodsb	%ds:(%esi), %al
    911 	lodsb	(%esi), %al
    912 	lods	%ds:(%esi), %al
    913 	lods	(%esi), %al
    914 
    915 // CHECK: lodsw # encoding: [0x66,0xad]
    916 // CHECK: lodsw
    917 // CHECK: lodsw
    918 // CHECK: lodsw
    919 // CHECK: lodsw
    920 	lodsw
    921 	lodsw	%ds:(%esi), %ax
    922 	lodsw	(%esi), %ax
    923 	lods	%ds:(%esi), %ax
    924 	lods	(%esi), %ax
    925 
    926 // CHECK: lodsl # encoding: [0xad]
    927 // CHECK: lodsl
    928 // CHECK: lodsl
    929 // CHECK: lodsl
    930 // CHECK: lodsl
    931 	lodsl
    932 	lodsl	%ds:(%esi), %eax
    933 	lodsl	(%esi), %eax
    934 	lods	%ds:(%esi), %eax
    935 	lods	(%esi), %eax
    936 
    937 // CHECK: stosb # encoding: [0xaa]
    938 // CHECK: stosb
    939 // CHECK: stosb
    940 	stosb
    941 	stosb	%al, %es:(%edi)
    942 	stos	%al, %es:(%edi)
    943 
    944 // CHECK: stosw # encoding: [0x66,0xab]
    945 // CHECK: stosw
    946 // CHECK: stosw
    947 	stosw
    948 	stosw	%ax, %es:(%edi)
    949 	stos	%ax, %es:(%edi)
    950 
    951 // CHECK: stosl # encoding: [0xab]
    952 // CHECK: stosl
    953 // CHECK: stosl
    954 	stosl
    955 	stosl	%eax, %es:(%edi)
    956 	stos	%eax, %es:(%edi)
    957 
    958 // CHECK: strw
    959 // CHECK: encoding: [0x66,0x0f,0x00,0xc8]
    960 	str %ax
    961 
    962 // CHECK: strl
    963 // CHECK: encoding: [0x0f,0x00,0xc8]
    964 	str %eax
    965 
    966 
    967 // PR9378
    968 // CHECK: fsubp
    969 // CHECK: encoding: [0xde,0xe1]
    970 fsubp %st,%st(1)
    971 
    972 // PR9164
    973 // CHECK: fsubp	%st(2)
    974 // CHECK: encoding: [0xde,0xe2]
    975 fsubp   %st, %st(2)
    976 
    977 // PR10345
    978 // CHECK: xchgl %eax, %eax
    979 // CHECK: encoding: [0x90]
    980 xchgl %eax, %eax
    981 
    982 // CHECK: xchgw %ax, %ax
    983 // CHECK: encoding: [0x66,0x90]
    984 xchgw %ax, %ax
    985 
    986 // CHECK: xchgl %ecx, %eax
    987 // CHECK: encoding: [0x91]
    988 xchgl %ecx, %eax
    989 
    990 // CHECK: xchgl %ecx, %eax
    991 // CHECK: encoding: [0x91]
    992 xchgl %eax, %ecx
    993 
    994 // CHECK: retw
    995 // CHECK: encoding: [0x66,0xc3]
    996 retw
    997 
    998 // CHECK: lretw
    999 // CHECK: encoding: [0x66,0xcb]
   1000 lretw
   1001