xref: /llvm-project/llvm/test/MC/X86/align-branch-hardcode.s (revision 7ad46cfe41554627caa9e91313682ad9dd4b9c3a)
1# RUN: llvm-mc -filetype=obj -triple x86_64 --x86-align-branch-boundary=32 --x86-align-branch=jmp+call %s | llvm-objdump -d --no-show-raw-insn - | FileCheck %s
2
3  # Exercise cases where instructions to be aligned is after hardcode
4  # and thus can't add a nop in between without changing semantic.
5
6  .text
7
8  # CHECK: 1d:       int3
9  # CHECK: 1e:       jmp
10  # CHECK: 24:       int3
11  .p2align  5
12  .rept 30
13  int3
14  .endr
15  .byte 0x2e
16  jmp baz
17  int3
18
19  # CHECK: 5d:       int3
20  # CHECK: 5e:       call
21  # CHECK: 66:       int3
22  .p2align  5
23  .rept 30
24  int3
25  .endr
26  .byte 0x66
27  call *___tls_get_addr@GOT(%ecx)
28  int3
29
30  .section ".text.other"
31bar:
32  retq
33