Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lld / test / ELF / version-script-locals-extern.s
blobba37e7e5e7c2eecace63be6d6812892254272313
1 # REQUIRES: x86
3 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
4 # RUN: echo "FOO { local: extern \"C++\" { \"abb(int)\"; }; };" > %t.script
5 # RUN: ld.lld --version-script %t.script -shared %t.o -o %t.so
6 # RUN: llvm-readobj -V %t.so | FileCheck %s --check-prefix=ABB
7 # ABB: VersionSymbols [
8 # ABB-NEXT: Symbol {
9 # ABB-NEXT: Version: 0
10 # ABB-NEXT: Name:
11 # ABB-NEXT: }
12 # ABB-NEXT: Symbol {
13 # ABB-NEXT: Version: 1
14 # ABB-NEXT: Name: _Z3abci
15 # ABB-NEXT: }
16 # ABB-NEXT: ]
18 # RUN: llvm-mc -filetype=obj -triple=x86_64-pc-linux %s -o %t.o
19 # RUN: echo "FOO { local: extern \"C++\" { abb*; }; };" > %t.script
20 # RUN: ld.lld --version-script %t.script -shared %t.o -o %t.so
21 # RUN: llvm-readobj -V %t.so | FileCheck %s --check-prefix=ABB
23 # RUN: echo "FOO { local: extern \"C++\" { abc*; }; };" > %t.script
24 # RUN: ld.lld --version-script %t.script -shared %t.o -o %t.so
25 # RUN: llvm-readobj -V %t.so | FileCheck %s --check-prefix=ABC
26 # ABC: VersionSymbols [
27 # ABC-NEXT: Symbol {
28 # ABC-NEXT: Version: 0
29 # ABC-NEXT: Name:
30 # ABC-NEXT: }
31 # ABC-NEXT: Symbol {
32 # ABC-NEXT: Version: 1
33 # ABC-NEXT: Name: _Z3abbi
34 # ABC-NEXT: }
35 # ABC-NEXT: ]
37 .globl _Z3abbi
38 .type _Z3abbi,@function
39 _Z3abbi:
40 retq
42 .globl _Z3abci
43 .type _Z3abci,@function
44 _Z3abci:
45 retq