[compiler-rt] r369977 - [hwasan] Fix test failure in r369721.
Evgeniy Stepanov via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 26 14:44:55 PDT 2019
Author: eugenis
Date: Mon Aug 26 14:44:55 2019
New Revision: 369977
URL: http://llvm.org/viewvc/llvm-project?rev=369977&view=rev
Log:
[hwasan] Fix test failure in r369721.
Try harder to emulate "old runtime" in the test.
To get the old behavior with the new runtime library, we need both
disable personality function wrapping and enable landing pad
instrumentation.
Modified:
compiler-rt/trunk/test/hwasan/lit.cfg.py
Modified: compiler-rt/trunk/test/hwasan/lit.cfg.py
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/hwasan/lit.cfg.py?rev=369977&r1=369976&r2=369977&view=diff
==============================================================================
--- compiler-rt/trunk/test/hwasan/lit.cfg.py (original)
+++ compiler-rt/trunk/test/hwasan/lit.cfg.py Mon Aug 26 14:44:55 2019
@@ -11,15 +11,18 @@ config.test_source_root = os.path.dirnam
# Setup default compiler flags used with -fsanitize=memory option.
clang_cflags = [config.target_cflags] + config.debug_info_flags
clang_cxxflags = config.cxx_mode_flags + clang_cflags
-clang_hwasan_oldrt_cflags = clang_cflags + ["-fsanitize=hwaddress", "-fuse-ld=lld"]
+clang_hwasan_common_cflags = clang_cflags + ["-fsanitize=hwaddress", "-fuse-ld=lld"]
if config.target_arch == 'x86_64':
# This does basically the same thing as tagged-globals on aarch64. Because
# the x86_64 implementation is for testing purposes only there is no
# equivalent target feature implemented on x86_64.
- clang_hwasan_oldrt_cflags += ["-mcmodel=large"]
-clang_hwasan_cflags = clang_hwasan_oldrt_cflags + ["-mllvm", "-hwasan-globals",
+ clang_hwasan_common_cflags += ["-mcmodel=large"]
+clang_hwasan_cflags = clang_hwasan_common_cflags + ["-mllvm", "-hwasan-globals",
"-mllvm", "-hwasan-instrument-landing-pads=0",
"-mllvm", "-hwasan-instrument-personality-functions"]
+clang_hwasan_oldrt_cflags = clang_hwasan_common_cflags + ["-mllvm", "-hwasan-instrument-landing-pads=1",
+ "-mllvm", "-hwasan-instrument-personality-functions=0"]
+
clang_hwasan_cxxflags = config.cxx_mode_flags + clang_hwasan_cflags
clang_hwasan_oldrt_cxxflags = config.cxx_mode_flags + clang_hwasan_oldrt_cflags
More information about the llvm-commits
mailing list