New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tarantool
seems to fail to compile when ENABLE_ASAN=on
is used
#3070
Comments
It still supports only clang, so use CC=clang CXX=clang++ cmake -DENABLE_ASAN on systems where gcc is default compiler. Fixes #3070.
LLVM changes the API in the compiler-rt commit [1]. According to the date of the commit it is between clang-3.9.0 and clang-3.9.1. [1]: llvm-mirror/compiler-rt@0b95585 Fixes #3070.
LLVM changes the API in the compiler-rt commit [1]. According to the date of the commit it is between clang-3.9.0 and clang-3.9.1. [1]: llvm-mirror/compiler-rt@0b95585 Fixes #3070.
Thank you! To judge from CMakeError.log the build system can tell the interfaces apart. In file included from lj_obj.h:13,
from lj_str.c:9:
lj_str.c: In function ‘str_fastcmp’:
lj_def.h:242:28: error: inlining failed in call to always_inline ‘lj_getu32’: function attribute mismatch
static LJ_AINLINE uint32_t lj_getu32(const void *p)
^~~~~~~~~
lj_str.c:59:18: note: called from here
uint32_t v = lj_getu32(a+i) ^ *(const uint32_t *)(b+i);
^~~~~~~~~~~~~~
lj_str.c: At top level:
cc1: warning: unrecognized command line option ‘-Wno-parentheses-equality’
make[3]: *** [Makefile:683: lj_str.o] Error 1
make[2]: *** [CMakeFiles/libluajit.dir/build.make:62: third_party/luajit/src/libluajit.a] Error 2
make[1]: *** [CMakeFiles/Makefile2:68: CMakeFiles/libluajit.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 19%] Building C object src/lib/small/test/CMakeFiles/quota.test.dir/unit.c.o
[ 19%] Linking C executable lsregion.test
[ 19%] Linking CXX executable quota.test
[ 19%] Built target quota_lessor.test
[ 19%] Built target lsregion.test
[ 19%] Built target quota.test
make: *** [Makefile:152: all] Error 2 |
That was
|
Use
|
it'd probably be great to build this knowledge into the build system.
That's good to know but technically tarantool still fails to compile when |
Ok, I'll create follow up patch. |
I've just taken a look at #2058 and as far as I can see it covers ASan only. I think it'd be also great to try UBSan (though it apparently isn't as easy as it seems to be). I built tarantool with it and the tests crashed somewhere in luajit
|
Anyway, it's time for me to stop here. Thanks again for fixing this! |
The build time error is confusing for users. The patch makes the error explicit and moves it to the cmake stage. Follow up of #3070.
The build time error is confusing for users. The patch makes the error explicit and moves it to the cmake stage. Follow up of #3070.
LLVM changes the API in the compiler-rt commit [1]. According to the date of the commit it is between clang-3.9.0 and clang-3.9.1. [1]: llvm-mirror/compiler-rt@0b95585 Fixes tarantool#3070.
The build time error is confusing for users. The patch makes the error explicit and moves it to the cmake stage. Follow up of tarantool#3070.
llvm-mirror/compiler-rt@0b95585 seems to have broken the code depending on
__sanitizer_finish_switch_fiber
having only one argument:The text was updated successfully, but these errors were encountered: