devel/binutils in FreeBSD's ports builds gold which it installs as 
/usr/local/bin/ld.gold. The attached patch enables LTO on FreeBSD in a manner 
similar to Linux. Namely, it passes -plugin /path/to/LLVMgold.so to the linker.

In addition, if gold has been specified, it uses ld.gold, rather than ld. I'm 
not sure if that part is appropriate or not since nothing else switches linkers 
based on LTO.

-- 
Stephen Checkoway


Attachment: FreeBSD-native-LLVM-support.diff
Description: Binary data



_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to