Hello,<br><br>I have a very early version of GNU's ld, part of GNU binutils, with LLVM's Link Time Optimization integrated with it. This allows the linker to link LLVM bytecode and native objects together into a single executable. It is still very early in development, and I'll be working on doing more robust testing on it in the upcoming weeks, but it at least handles simple cases. If you are interested in trying it out, and providing feedback on how it performs, especially on some other platforms (mine is amd64-linux), I would be very interested.
<br><br>If you are interested in trying this, please pick up the patches to LLVM from bugs #1055 and #1073, as they are necessary to build LLVM's LTO suitable to link into binutils. The should be in LLVM's CVS soon, but aren't yet.
<br><br>Then use the following monolithic patch from the binutils CVS. It is monolithic only because binutils includes the verbatim, and automatically generated configure and <a href="http://Makefile.in">Makefile.in</a> scripts. The changes are actually quite small, and should (hopefully) apply cleanly, even as the CVS moves -- the files changed for this process are among the least frequently changing in binutils development.
<br><a href="http://code.chandlerc.net/binutils/binutils-tot.2007.01.06.patch">http://code.chandlerc.net/binutils/binutils-tot.2007.01.06.patch</a><br><br>*or*<br><br>Grab a branch of this bzr repository of binutils. I will try and sync it to CVS every week or so, but it shouldn't be an issue for most people. It will allow actually tinkering with the implementation in a nice DRCS manner.
<br><a href="http://code.chandlerc.net/binutils/bzr">http://code.chandlerc.net/binutils/bzr</a><br><br>Finally, configure and build binutils similar to the following<br><br>cd ${BINUTILS_OBJ_ROOT}<br>${BINUTILS_SRC_ROOT}/configure --prefix=${BINUTILS_INSTALL_PATH} --with-llvm=${LLVM_INSTALL_PATH}
<br>make<br>make install<br><br>where LLVM_INSTALL_PATH is equivalent to the prefix provided LLVM when it was configured and built. If 'llvm-config' is in your path, then simply specifying '--with-llvm' may be sufficient, but i haven't tested that behavior.
<br><br><br>Please, comments, suggestions, questions, and bugs are all welcome, and hopefully this will grow to be a very usable tool.<br>-Chandler Carruth<br>