[obj2yaml] - Fix a comment. NFC.
[llvm-complete.git] / test / MC / X86 / AlignedBundling / relax-in-bundle-group.s
blob036249b906b45fc1e358b659220b5732fd67798e
1 # RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu -mcpu=pentiumpro %s -o - \
2 # RUN: | llvm-objdump -disassemble - | FileCheck %s
3 # RUN: llvm-mc -filetype=obj -triple x86_64-pc-linux-gnu -mcpu=pentiumpro -mc-relax-all %s -o - \
4 # RUN: | llvm-objdump -disassemble - | FileCheck %s
6 # Test that instructions inside bundle-locked groups are relaxed even if their
7 # fixup is short enough not to warrant relaxation on its own.
9 .text
10 foo:
11 .bundle_align_mode 4
12 pushq %rbp
14 movl %edi, %ebx
15 callq bar
16 movl %eax, %r14d
17 imull $17, %ebx, %ebp
18 movl %ebx, %edi
19 callq bar
20 cmpl %r14d, %ebp
21 .bundle_lock
23 jle .L_ELSE
24 # This group would've started at 0x18 and is too long, so a chunky NOP padding
25 # is inserted to push it to 0x20.
26 # CHECK: 18: {{[a-f0-9 ]+}} nopl
28 # The long encoding for JLE should be used here even though its target is close
29 # CHECK-NEXT: 20: 0f 8e
31 addl %ebp, %eax
33 jmp .L_RET
34 # Same for the JMP
35 # CHECK: 28: e9
37 .bundle_unlock
39 .L_ELSE:
40 imull %ebx, %eax
41 .L_RET:
43 popq %rbx