[PATCH] Added -mlink-init-bitcode-file option to pre-populate new module with IR loaded from specified file.
Eric Christopher
echristo at gmail.com
Mon Jun 8 16:06:10 PDT 2015
Cool. I think that's probably how we should go.
Thanks!
-eric
On Mon, Jun 8, 2015 at 3:23 PM Peter Collingbourne <peter at pcc.me.uk> wrote:
> I was the person who originally introduced this flag in r143314. As I
> recall this flag was introduced in order to support linking a bitcode
> module containing an implementation of a runtime library for a GPU (e.g.
> libclc).
>
> The reason I made the flag link the bitcode after compilation was that I
> wanted to avoid breaking any invariants that Clang's code generator might
> have (e.g. if both the bitcode file and the C source file define a weak
> symbol, Clang's IR generator may get confused by the presence of a
> duplicate symbol, whereas the IR linker already knows to discard one of
> them). If avoiding the IR linker provides a significant performance
> advantage, it does seem reasonable to make `-mlink-bitcode-file`
> pre-populate the module, and start fixing any assumptions we're currently
> making in the IR generator.
>
>
> http://reviews.llvm.org/D9721
>
> EMAIL PREFERENCES
> http://reviews.llvm.org/settings/panel/emailpreferences/
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20150608/226ed14d/attachment.html>
More information about the cfe-commits
mailing list