Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / bolt / test / X86 / addr32.s
blob1f926c20c7ba8d078407e5b86b7cec6cd82525af
1 # Check that we don't accidentally strip addr32 prefix
3 # RUN: llvm-mc -filetype=obj -triple x86_64-unknown-unknown %s -o %t.o
4 # RUN: ld.lld %t.o -o %t.exe -nostdlib
5 # RUN: llvm-objdump -d %t.exe | FileCheck %s
6 # RUN: llvm-bolt %t.exe -o %t.out --lite=0 --x86-strip-redundant-address-size=false
7 # RUN: llvm-objdump -d %t.out | FileCheck %s
8 # CHECK: 67 e8 {{.*}} addr32 callq {{.*}} <foo>
9 # RUN: llvm-bolt %t.exe -o %t.out --lite=0 --x86-strip-redundant-address-size=true
10 # remove test name from objdump output, to only search for addr32 in disassembly
11 # RUN: llvm-objdump -d %t.out | grep -v addr32.s | FileCheck %s --check-prefix=CHECK-STRIP
12 # CHECK-STRIP-NOT: addr32
14 .globl _start
15 .type _start, @function
16 _start:
17 .code64
18 addr32 callq foo
19 ret
20 .size _start, .-_start
22 .globl foo
23 .type foo, @function
24 foo:
25 ud2