<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 - ThinLTO index only generates very large index files"
href="https://bugs.llvm.org/show_bug.cgi?id=42378">42378</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>ThinLTO index only generates very large index files
</td>
</tr>
<tr>
<th>Product</th>
<td>libraries
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</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>Interprocedural Optimizations
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>llvm@inglorion.net
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>While trying to make distributed ThinLTO work for Chrome, I noticed that the
index (.thinlto.bc) files generated by -plugin-opt=thinlto-index-only can get
very large. When linking chrome on Linux, every .o file in the link gets a
.thinlto.bc file about 10MB in size, which with the number of object files
taking part in that link adds up to a lot of disk space.
A smaller but hopefully still interesting case is to apply
<a href="https://crrev.com/c/1654198">https://crrev.com/c/1654198</a> to Chromium, configuring with args.gn:
is_debug = false
is_official_build = true
strip_absolute_paths_from_debug_symbols = true
and building with ninja base_unittests printing_unittests
This gives the following sizes:
137K lto.base_unittests/obj/base/i18n/number_formatting.o
0 lto.base_unittests/obj/base/i18n/number_formatting.o.imports
660K lto.base_unittests/obj/base/i18n/number_formatting.o.thinlto.bc
560 lto.printing_unittests/obj/base/i18n/number_formatting.o
0 lto.printing_unittests/obj/base/i18n/number_formatting.o.imports
124 lto.printing_unittests/obj/base/i18n/number_formatting.o.thinlto.bc
(If needed, larger files can be obtained by building different targets.)
A quick look with llvm-bcanalyzer --dump shows about 95% of the larger files to
be taken up by the strtab.
These numbers were obtained with LLVM r363966 and Chromium
<a href="https://crrev.com/c/1663415">https://crrev.com/c/1663415</a>. Similar results can be obtained with older
versions, so this doesn't appear to be a recent introduction.</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>