<div dir="ltr">That documentation is a bit out of date.<div><br></div><div>The LLVM gold plugin (and the lld linker) now use a different LTO API (as of a year ago). There is actually a richer set of intermediate files emitted when you do save-temps. E.g.:</div><div><br></div><div>$ clang -flto main.c foo.c -Wl,-plugin-opt=save-temps -o testsavetemps</div><div><div>$ file testsavetemps*</div><div>testsavetemps: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, not stripped</div><div>testsavetemps.0.0.preopt.bc: LLVM IR bitcode</div><div>testsavetemps.0.2.internalize.bc: LLVM IR bitcode</div><div>testsavetemps.0.4.opt.bc: LLVM IR bitcode</div><div>testsavetemps.0.5.precodegen.bc: LLVM IR bitcode</div><div>testsavetemps.o: ELF 64-bit LSB relocatable, x86-64, version 1 (SYSV), not stripped</div><div>testsavetemps.resolution.txt: ASCII text</div></div><div><br></div><div>Likely what you want is testsavetemps.0.5.precodegen.bc - the bitcode just before generating the native object (testsavetemps.o).</div><div><br></div><div>Teresa</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Sep 10, 2017 at 8:07 AM, Dipanjan Das via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br clear="all"><div>To compile an auto-tooled project to bitcode, I used to use plugin-opt=save-temps switch as explained in: <a href="http://gbalats.github.io/2015/12/10/compiling-autotooled-projects-to-LLVM-bitcode.html" target="_blank">http://gbalats.github.io/<wbr>2015/12/10/compiling-<wbr>autotooled-projects-to-LLVM-<wbr>bitcode.html</a>. This switch works with LLVM 3.8.0.</div><div><br></div><div>However, it seems to have no effect with LLVM 5.0.0. I can see intermediate bitcode files on disk, but not the final one. Is the option removed altogether? Has the switch changed?</div><span class="HOEnZb"><font color="#888888"><div><br></div>-- <br><div class="m_5135903874383188808gmail_signature"><div dir="ltr"><span><div><div dir="ltr"><p>Thanks & Regards,</p>
<div>Dipanjan</div></div></div></span></div></div>
</font></span></div>
<br>______________________________<wbr>_________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-dev</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><span style="font-family:Times;font-size:medium"><table cellspacing="0" cellpadding="0"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small"><td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Teresa Johnson |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tejohnson@google.com" target="_blank">tejohnson@google.com</a> |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"> 408-460-2413</td></tr></tbody></table></span></div>
</div>