Debian Codegraph @

llvm/test/tools/dsymutil/X86/thinlto.test

raw
1 $ cat foo.cpp
2 struct nontrivial {
3 nontrivial() { }
4 };
5
6 void function2()
7 {
8 static const nontrivial magic_static;
9 }
10
11 $ cat bar.cpp
12 void function2();
13
14 void function1()
15 {
16 function2();
17 }
18
19 $ xcrun clang++ -g -flto=thin -O2 foo.cpp bar.cpp -c
20 $ xcrun clang++ -flto=thin foo.o bar.o -Xlinker -object_path_lto -Xlinker lto -shared -o foobar.dylib
21
22 RUN: dsymutil -oso-prepend-path %p/../Inputs %p/../Inputs/private/tmp/thinlto/foobar.dylib -o %t.dSYM 2>&1 | FileCheck %s --allow-empty
23
24 RUN: dsymutil --linker parallel -oso-prepend-path %p/../Inputs %p/../Inputs/private/tmp/thinlto/foobar.dylib -o %t.dSYM 2>&1 | FileCheck %s --allow-empty
25
26 CHECK-NOT: could not find symbol '__ZZ9function2vE12magic_static'
27 CHECK-NOT: could not find symbol 'symbol __ZGVZ9function2vE12magic_static'