1 /*
2  * Check that we don't assert on a duplicate static relocation added by lld
3  * against _Z6myfuncv. The same address has a dynamic relocation against it.
4  *
5  * RUN: %clang %cflags -fPIC -shared %s -o %t.so -Wl,-q -fuse-ld=lld
6  * RUN: llvm-bolt %t.so -o %t.so.bolt --relocs
7  */
8 
9 unsigned long long myfunc();
10 
11 unsigned long long (*myglobal)() = myfunc;
12 
13 unsigned long long myfunc() {
14   return reinterpret_cast<unsigned long long>(myglobal);
15 }
16