<div dir="ltr">This reminds me of another recent question where someone wanted to run both compile and analyze actions. Is there anything that actually prevents us from running multiple actions?</div><div class="gmail_extra">

<br><br><div class="gmail_quote">On Sun, Jun 22, 2014 at 7:22 PM, Alp Toker <span dir="ltr"><<a href="mailto:alp@nuanti.com" target="_blank">alp@nuanti.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class=""><br>
On 19/06/2014 23:38, Jinwook Shin wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
I use the -emit-llvm flag to generate IR files and use LTO to link them together to produce the final executable. Sometimes LTO gives me link-time errors, so I want to avoid using it, yet I need IR files.<br>
<br>
Question: Is there a way to instruct clang to generate *both* an IR file and a regular object file at compile-time, and during the link time, use the object files only, while leaving out the IR files?<br>
</blockquote>
<br></div>
That isn't supported by the standard driver and frontend but it's a perfectly reasonable feature to request.<br>
<br>
It's missing mostly for historical reasons -- the frontend action pipeline wasn't designed to be composable, meaning you can only do one thing per invocation.<br>
<br>
The limitation doesn't apply if you use the clang C++ API to build a custom tool.<br>
<br>
Alp.<div class="im HOEnZb"><br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Thanks,<br>
JS<br>
<br>
______________________________<u></u>_________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu" target="_blank">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/cfe-dev</a><br>
</blockquote>
<br></div><span class="HOEnZb"><font color="#888888">
-- <br>
<a href="http://www.nuanti.com" target="_blank">http://www.nuanti.com</a><br>
the browser experts</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
______________________________<u></u>_________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@cs.uiuc.edu" target="_blank">cfe-dev@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev" target="_blank">http://lists.cs.uiuc.edu/<u></u>mailman/listinfo/cfe-dev</a><br>
</div></div></blockquote></div><br></div>