[LLVMdev] Merging Modules
Nick Lewycky
nlewycky at google.com
Thu Sep 8 11:45:21 PDT 2011
On 8 September 2011 10:57, Devang Patel <dpatel at apple.com> wrote:
> Hi Paul,
>
> On Sep 8, 2011, at 10:52 AM, Redmond, Paul wrote:
>
> Hi,****
> ** **
> Can anyone point me to some code (or offer advice) on how I can merge one
> Module into another?****
> ** **
> I have a list of Modules each containing one Function. I would like to
> combine them all into one monolithic Module before transforming and
> optimizing (The original Modules must remain unmodified)****
>
>
> See Linker::LinkModules(..).
>
Mm, I think LinkModules is destructive to one of its input modules. Try
CloneFunction
http://llvm.org/doxygen/namespacellvm.html#aabb040f50a7e75ad8d58bfc5d95636a4
maybe?
> -
> Devang
>
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110908/cca61395/attachment.html>
More information about the llvm-dev
mailing list