[LLVMdev] Generating executable by llc.

John van Schie jcschie at cs.uu.nl
Fri Dec 28 00:03:20 PST 2007


Sanjiv,

You can use llvm-ld to link .o files together with .bc files to produce 
a native binary by passing it the -native flag. In you case, you would 
replace llc with llvm-ld.

Regards,

John

Sanjiv Gupta schreef:
> is it possible in llvm infrastructure to integrate an actual linker 
> with llc?  rather than using the native linker.
> Can it be done by adding a Module pass?
> How difficult it would be to read-in and link the traditional COFF/ELF 
> object files with this integrated linker?
> I am looking to do something like this:
>  
> a.c, b.c ----> llvm-gcc ---> a.bc, b.bc ---> llvm-link ---> 
> combined.bc , native.o ------> llc + integrated linker  ---> final 
> exeutable
>  
>  
> TIA,
> Sanjiv
> ------------------------------------------------------------------------
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
>   




More information about the llvm-dev mailing list