<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - lld creates `.00cfg` and `.voltbl` sections, link.exe doesn't"
href="https://bugs.llvm.org/show_bug.cgi?id=45111">45111</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>lld creates `.00cfg` and `.voltbl` sections, link.exe doesn't
</td>
</tr>
<tr>
<th>Product</th>
<td>lld
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Windows NT
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>enhancement
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>COFF
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>me@veg.by
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>The issue is easy to reproduce using the latest clang from
<a href="https://llvm.org/builds/">https://llvm.org/builds/</a> (Git commit 2663a25f, 3 February 2020).
1. Create test.cpp with these contents:
#include <stdio.h>
int wmain(int argc, wchar_t* argv[])
{
printf("Hello, world!");
return 0;
}
2. Compile it and link using lld:
clang -std=c++17 -m32 -fuse-ld=lld -Oz
-Wl,-subsystem:console,-merge:.rdata=.text,-out:test1.exe test.cpp
3. Compile it and link using default link.exe:
clang -std=c++17 -m32 -Oz
-Wl,-subsystem:console,-merge:.rdata=.text,-out:test2.exe test.cpp
4. Compare section lists of the `test1.exe` and `test2.exe`. The `test1.exe`
(linked by lld) does have `.00cfg` and `.voltbl` sections; the `test2.exe`
(linked by default linker, link.exe I suppose) doesn't have these sections.
Repro files (with all the libraries) are here:
<a href="http://veg.by/files/temp/lld_00cfg_repro.7z">http://veg.by/files/temp/lld_00cfg_repro.7z</a>
It seems that these sections come from standard VC++ and Windows SDK libraries.
I guess that it is expected that lld should behave like link.exe. So, probably
it is worth to investigate what causes this difference.</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>