Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lld / test / ELF / x86-64-reloc-error-reporting.s
blobbb9c8be8accbab316743667c6762e27ce42256b4
1 // REQUIRES: x86
2 // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %S/Inputs/x86-64-reloc-error.s -o %tabs
3 // RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t
5 // We have some code in error reporting to check that
6 // section belongs to the output section. Without that
7 // check, the linker would crash, so it is useful to test it.
8 // And the easy way to do that is to trigger GC. That way .text.dumb
9 // be collected and mentioned check will execute.
11 // RUN: not ld.lld -gc-sections -shared %tabs %t -o /dev/null
13 .section .text.dumb,"ax"
14 nop
16 .section .text,"ax"
17 .globl _start
18 _start:
19 movl $big, %edx