<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 - Thin LTO .map files refer to non-existing files (got renamed)."
href="https://bugs.llvm.org/show_bug.cgi?id=37018">37018</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Thin LTO .map files refer to non-existing files (got renamed).
</td>
</tr>
<tr>
<th>Product</th>
<td>lld
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>All
</td>
</tr>
<tr>
<th>OS</th>
<td>All
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>All Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>huangs@google.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr></table>
<p>
<div>
<pre>If we use LTO and generate .map files, the resulting file contains links to
files such as
- lto.tmp
- thinlto-cache/Thin-766634.tmp.o
However, these files don't exist, because they got renamed to files like
- thinlto-cache/llvmcache-8AA1E24EA41F4393454B37AE85516B593FBC0476
As a result, the data in .map file are not as useful as they should be.
For my specific case, the problem is encountered for Chromium (Linux)
######## Repro instructions ########
cd chrome/src # Wherever this is.
gn gen out/test
gn args out/test # Launches editor.
#### Paste the following into the
is_debug = false
is_official_build = true
generate_linker_map = true
use_lld = true
use_thin_lto = true
#### Save and close
ninja -j100 -l15 -C out/test zucchini
cd out/test
gunzip zucchini.map.gz
# Open zucchini.map, note ref to lto.tmp & thinlto-cache/Thin-*.tmp.o files.
cd thinlto-cache
ls # See llvmcache-* files, but no lto.tmp or Thin-*.tmp.o files.
########
Looks like the renaming code lives in .../llvm/lib/LTO/Cachine.cpp , but .map
file is generated before rename occurs? Perhaps we should have .map refer to
final file names, or also provide a map from temp files to final files?</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>