<div> namespace options {</div><div>+ enum generate_bc { BC_NO, BC_ALSO, BC_ONLY};</div><div> static bool generate_api_file = false;</div><div><br></div><div>Please fix the whitespace; you're missing a space after BC_ONLY before }</div>
<div><br></div><div><div>+ if (options::generate_bc_file == options::BC_ONLY)</div><div>+ exit(0);</div></div><div><br></div><div>Eww!! I assume there's no other way to implement this, or else you would've done that instead.</div>
<div><br></div><div>Some day, we should teach gold to let a plugin generate the output. It could be useful for things like ld -r on bitcode files, for example. Until then, this will have to do.</div><div><br></div><div>Nick</div>
<br><div class="gmail_quote">On 3 June 2010 13:23, Rafael Espindola <span dir="ltr"><<a href="mailto:espindola@google.com">espindola@google.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
With the attached patch we have:<br>
<br>
ld ... -o foo -plugin-opt=emit-llvm produces foo only (a bc file).<br>
<div class="im">ld ... -o foo -plugin-opt=also-emit-llvm produces foo.bc and foo.<br>
ld ... -o foo -plugin-opt=also-emit-llvm=bar.bc produces bar.bc and foo.<br>
<br>
</div>is it OK?<br>
<div><div></div><div class="h5"><br>
Cheers,<br>
--<br>
Rafael Ávila de Espíndola<br>
</div></div><br>_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
<br></blockquote></div><br>