[cfe-dev] Build Clang with CMake and Intel Compiler

Kostya Serebryany kcc at google.com
Wed Mar 19 05:22:29 PDT 2014


This error reports comes from building tsan (ThreadSanitizer) run-time.
First: do you need it?
Second: try to hack compiler-rt/lib/sanitizer_common/sanitizer_asm.h
to disable CFI directives.

Apparently icpc is not fully gcc-compatible it it barks on -funwind-tables

--kcc


On Wed, Mar 19, 2014 at 4:07 PM, Marvin Damschen
<marvin.damschen at gullz.de>wrote:

> Hello everyone,
>
> keep failing to build Clang 3.4 with icpc, giving me 'Error: CFI
> instruction used without previous .cfi_startproc' repeatedly. I tried
> CMAKE_BUILD_TYPE=DEBUG and compiler flags -g and
> -fno-asynchronous-unwind-tables, but it was no use. I am using icpc 14
> (in GCC 4.8 compatibility mode) on Scientific Linux 6.4. I hope you can
> help me out. LLVM without Clang succeeds to build.
>
> On a related note, is there a canonical way to disable all the Sanitizers?
>
> Best regards,
> Marvin
>
> [ 66%] Built target clang_rt.ubsan-x86_64
> [ 66%] Built target clang_rt.ubsan-x86_64-symbols
> [ 66%] Built target clang_rt.ubsan_cxx-x86_64
> [ 66%] Built target clang_rt.ubsan_cxx-x86_64-symbols
> [ 66%] Building CXX object
>
> projects/compiler-rt/lib/tsan/CMakeFiles/clang_rt.tsan-x86_64.dir/rtl/tsan_interface_atomic.cc.o
> icpc: command line warning #10006: ignoring unknown option
> '-funwind-tables'
> icpc: command line warning #10006: ignoring unknown option '-Wno-gnu'
> icpc: command line warning #10006: ignoring unknown option
> '-Wframe-larger-than=512'
> /tmpdir/ccsscratch/16720/icpcxWB4IQas_.s: Assembler messages:
> /tmpdir/ccsscratch/16720/icpcxWB4IQas_.s:4098: Error: CFI instruction
> used without previous .cfi_startproc
> /tmpdir/ccsscratch/16720/icpcxWB4IQas_.s:4807: Error: CFI instruction
> used without previous .cfi_startproc
> ...
> /tmpdir/ccsscratch/16720/icpcxWB4IQas_.s:45623: Error: CFI instruction
> used without previous .cfi_startproc
> /tmpdir/ccsscratch/16720/icpcxWB4IQas_.s:45623: Error: CFI instruction
> used without previous .cfi_startproc
> make[2]: ***
>
> [projects/compiler-rt/lib/tsan/CMakeFiles/clang_rt.tsan-x86_64.dir/rtl/tsan_interface_atomic.cc.o]
> Error 1
> make[1]: ***
> [projects/compiler-rt/lib/tsan/CMakeFiles/clang_rt.tsan-x86_64.dir/all]
> Error 2
> make: *** [all] Error 2
>
>
> _______________________________________________
> cfe-dev mailing list
> cfe-dev at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20140319/3e3c9a78/attachment.html>


More information about the cfe-dev mailing list