[llvm-dev] compiler-rt only builds x86 sanitizers by default

Chris Bieneman via llvm-dev llvm-dev at lists.llvm.org
Mon Feb 22 14:30:36 PST 2016


This is a complicated problem, and it doesn’t have an easy solution.

The problem is CMake generally assumes that you’re building for one target at a time, which is a safe assumption for most projects, but doesn’t work great when you’re building a cross-compiler. The correct solution to this will be to extend the LLVM_BUILD_EXTERNAL_COMPILER_RT option to take a list of target specifiers (or triples) and configure and build compiler-rt n times.

I have plans to work on that support sometime hopefully in the next few months. Overhauling the LLVM_BUILD_EXTERNAL_COMPILER_RT option is basically the next logical step after I finish my work on the builtin libraries (See: http://reviews.llvm.org/D16653).

-Chris


> On Feb 20, 2016, at 12:09 AM, Handong Ye via llvm-dev <llvm-dev at lists.llvm.org> wrote:
> 
> Hi All, I looked into the configure and cmake files, it seems compiler-rt only target x86 by default. It is determined by COMPILER_RT_DEFAULT_TARGET_ARCH, which is coming from host TARGET triple.
> 
> Can anyone tell me why? Why not do the same as Clang is doing to build for all targets by default.
> 
> Also, if I want to make it to build for all targets by default, what's the best way to change it.
> 
> -- 
> Thanks.
> Handong
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20160222/8432acce/attachment.html>


More information about the llvm-dev mailing list