I've fixed most of the simple bugs and currently "check-llvm" test suite
has 26 failures, and "check-clang" suite has 5 failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216701
91177308-0d34-0410-b5e6-
96231b3b80d8
if(LLVM_USE_SANITIZER STREQUAL "MemoryWithOrigins")
append("-fsanitize-memory-track-origins" CMAKE_C_FLAGS CMAKE_CXX_FLAGS)
endif()
+ elseif (LLVM_USE_SANITIZER STREQUAL "Undefined")
+ append_common_sanitizer_flags()
+ append("-fsanitize=undefined -fno-sanitize=vptr -fno-sanitize-recover"
+ CMAKE_C_FLAGS CMAKE_CXX_FLAGS)
else()
message(WARNING "Unsupported value of LLVM_USE_SANITIZER: ${LLVM_USE_SANITIZER}")
endif()
**LLVM_USE_SANITIZER**:STRING
Define the sanitizer used to build LLVM binaries and tests. Possible values
- are ``Address``, ``Memory`` and ``MemoryWithOrigins``. Defaults to empty
- string.
+ are ``Address``, ``Memory``, ``MemoryWithOrigins`` and ``Undefined``.
+ Defaults to empty string.
**LLVM_BUILD_DOCS**:BOOL
Enables all enabled documentation targets (i.e. Doxgyen and Sphinx targets) to
config.environment[symbolizer] = os.environ[symbolizer]
# Propagate options for sanitizers.
-for options in ['ASAN_OPTIONS']:
+for options in ['ASAN_OPTIONS', 'UBSAN_OPTIONS']:
if options in os.environ:
config.environment[options] = os.environ[options]