Open Tigerly opened 4 years ago
Note the following error message:
unrecognized argument to -fsanitize= option: ‘dataflow’
Which means you should (re)build your clang(compiler-rt) with DataFlowSanitizer
enabled.
@pannzh Thanks so much for the reply.
Actually, when I try to do - 2). compile runtime library
clang -g -fsanitize=dataflow ../dataflow/runtime/runtime.c \ -I../dataflow/runtime -c -o runtime.o
It works well. The runtime.o has been generated. So, I guess my clang is OK.
However,
when I try to do - 1). compile target source with clang
clang -g -fsanitize=dataflow -std=c11 -Xclang -load -Xclang ../build/dataflow/libLoadStorePass.so -I../dataflow/runtime -c target.c -o target.o error: unable to load plugin '../build/dataflow/libLoadStorePass.so': '../build/dataflow/libLoadStorePass.so: undefined symbol: _ZN4llvm23EnableABIBreakingChecksE'
I'm a little bit confused about that...
What's your LLVM version? I built and tested this pass with LLVM3.8, 3.9, 4.0, and maybe 5.0. Since LLVM introduce breaking changes from time to time, It's sugguested to use a dedicated version instead.
Hello,
There is an error when I try to compile the project (use "make"). Would it be possible to help to check it?
Here is the error message:
[ 75%] Building C object dataflow/runtime/CMakeFiles/runtime.dir/runtime.o cc: error: unrecognized argument to -fsanitize= option: ‘dataflow’ dataflow/runtime/CMakeFiles/runtime.dir/build.make:62: recipe for target 'dataflow/runtime/CMakeFiles/runtime.dir/runtime.o' failed make[2]: *** [dataflow/runtime/CMakeFiles/runtime.dir/runtime.o] Error 1 CMakeFiles/Makefile2:142: recipe for target 'dataflow/runtime/CMakeFiles/runtime.dir/all' failed make[1]: *** [dataflow/runtime/CMakeFiles/runtime.dir/all] Error 2 Makefile:83: recipe for target 'all' failed
Thanks in advance!