<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><span class="vcard"><a class="email" href="mailto:dimitry@andric.com" title="Dimitry Andric <dimitry@andric.com>"> <span class="fn">Dimitry Andric</span></a>
</span> changed
<a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED - llvm doesn't handle @@@ in symbol names at lto time"
href="https://bugs.llvm.org/show_bug.cgi?id=36623">bug 36623</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">Resolution</td>
<td>FIXED
</td>
<td>---
</td>
</tr>
<tr>
<td style="text-align:right;">Status</td>
<td>RESOLVED
</td>
<td>REOPENED
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED - llvm doesn't handle @@@ in symbol names at lto time"
href="https://bugs.llvm.org/show_bug.cgi?id=36623#c3">Comment # 3</a>
on <a class="bz_bug_link
bz_status_REOPENED "
title="REOPENED - llvm doesn't handle @@@ in symbol names at lto time"
href="https://bugs.llvm.org/show_bug.cgi?id=36623">bug 36623</a>
from <span class="vcard"><a class="email" href="mailto:dimitry@andric.com" title="Dimitry Andric <dimitry@andric.com>"> <span class="fn">Dimitry Andric</span></a>
</span></b>
<pre>There's still an issue with this fix (either with r327930 or something else):
the symbol version gets tacked on *twice* in the final shared library.
E.g. when using test.ll from the description, and clang + lld trunk r328345:
$ ~/ins/llvm-trunk-r328345/bin/clang -O2 -fPIC -flto -c test.ll -o test.pico
warning: overriding the module target triple with x86_64-unknown-freebsd12.0
[-Woverride-module]
1 warning generated.
$ ~/ins/llvm-trunk-r328345/bin/ld.lld --eh-frame-hdr -Bshareable
--hash-style=both --enable-new-dtags -o t.so /usr/lib/crti.o
/usr/lib/crtbeginS.o -L/usr/lib -plugin
/home/dim/ins/llvm-trunk-r328345/lib/LLVMgold.so -plugin-opt=mcpu=x86-64
-plugin-opt=O2 test.pico --version-script test.ver -lgcc --as-needed -lgcc_s
--no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /usr/lib/crtendS.o
/usr/lib/crtn.o
$ readelf -sW t.so
Symbol table (.dynsym) contains 7 entries:
Num: Value Size Type Bind Vis Ndx Name
0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND
1: 0000000000000000 0 NOTYPE WEAK DEFAULT UND _Jv_RegisterClasses
2: 0000000000000000 0 FUNC WEAK DEFAULT UND
<a href="mailto:__cxa_finalize@FBSD_1.0">__cxa_finalize@FBSD_1.0</a> (3)
3: 00000000000010dc 0 FUNC GLOBAL DEFAULT 14 _fini
4: 00000000000010c8 0 FUNC GLOBAL DEFAULT 13 _init
5: 00000000000010c8 0 NOTYPE GLOBAL DEFAULT 12 foo@@VER1@@VER1 (2)
6: 00000000000031a8 0 NOTYPE GLOBAL DEFAULT 22 _end
Symbol table (.symtab) contains 21 entries:
Num: Value Size Type Bind Vis Ndx Name
0: 0000000000000000 0 NOTYPE LOCAL DEFAULT UND
1: 0000000000003000 8 OBJECT LOCAL DEFAULT 18 __CTOR_LIST__
2: 0000000000003010 8 OBJECT LOCAL DEFAULT 19 __DTOR_LIST__
3: 0000000000003020 0 OBJECT LOCAL DEFAULT 20 __JCR_LIST__
4: 0000000000001000 85 FUNC LOCAL DEFAULT 12
__do_global_dtors_aux
5: 0000000000002010 1 OBJECT LOCAL DEFAULT 16
__do_global_dtors_aux.completed
6: 0000000000002008 8 OBJECT LOCAL DEFAULT 16
__do_global_dtors_aux.p
7: 0000000000001060 38 FUNC LOCAL DEFAULT 12 frame_dummy
8: 0000000000003008 8 OBJECT LOCAL DEFAULT 18 __CTOR_END__
9: 0000000000003018 8 OBJECT LOCAL DEFAULT 19 __DTOR_END__
10: 000000000000045c 4 OBJECT LOCAL DEFAULT 11 __FRAME_END__
11: 0000000000003020 8 OBJECT LOCAL DEFAULT 20 __JCR_END__
12: 0000000000001090 54 FUNC LOCAL DEFAULT 12
__do_global_ctors_aux
13: 0000000000002000 8 OBJECT LOCAL HIDDEN 16 __dso_handle
14: 0000000000003028 0 NOTYPE LOCAL HIDDEN 21 _DYNAMIC
15: 00000000000010dc 0 FUNC GLOBAL DEFAULT 14 _fini
16: 00000000000010c8 0 FUNC GLOBAL DEFAULT 13 _init
17: 0000000000000000 0 NOTYPE WEAK DEFAULT UND _Jv_RegisterClasses
18: 0000000000000000 0 FUNC WEAK DEFAULT UND __cxa_finalize
19: 00000000000010c8 0 NOTYPE GLOBAL DEFAULT 12 foo@@VER1
20: 00000000000031a8 0 NOTYPE GLOBAL DEFAULT 22 _end
The "foo@@VER1@@VER1" dynamic symbol is clearly incorrect.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>