Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / bolt / test / X86 / tail-duplication-cacheline.s
blobacc49dc3483406b41afa8d49f002be5251f27cf9
1 # This reproduces a bug in TailDuplication::isInCacheLine
2 # with accessing BlockLayout past bounds (unreachable blocks).
4 # REQUIRES: system-linux
6 # RUN: llvm-mc -filetype=obj -triple x86_64-unknown-unknown \
7 # RUN: %s -o %t.o
8 # RUN: link_fdata %s %t.o %t.fdata
9 # RUN: llvm-strip --strip-unneeded %t.o
10 # RUN: %clang %cflags -no-pie %t.o -o %t.exe -Wl,-q -nostdlib
11 # RUN: llvm-bolt %t.exe -o %t.out --data %t.fdata --relocs \
12 # RUN: --tail-duplication=aggressive
13 .globl _start
14 _start:
15 jmp d
16 je _start
17 movl %esi, %edi
19 jmpq *JT0(,%rcx,8)
20 # FDATA: 1 _start #d# 1 _start #e# 1 3
22 movl 0, %esi
24 movl 0, %esi
26 jmp f
28 .rodata
29 JT0:
30 .quad g
31 .quad e