summaryrefslogtreecommitdiffstats
path: root/clang/test/Modules/check-for-sanitizer-feature.cpp
Commit message (Collapse)AuthorAgeFilesLines
* [Driver] Add float-divide-by-zero back to supported sanitizers after ↵Fangrui Song2019-07-101-1/+1
| | | | | | | | | | | | | | | | | | D63793/rC365272 D63793 removed float-divide-by-zero from the "undefined" set but it failed to add it to getSupportedSanitizers(), thus the sanitizer is rejected by the driver: clang-9: error: unsupported option '-fsanitize=float-divide-by-zero' for target 'x86_64-unknown-linux-gnu' Also, add SanitizerMask::FloatDivideByZero to a few other masks to make -fsanitize-trap, -fsanitize-recover, -fsanitize-minimal-runtime and -fsanitize-coverage work. Reviewed By: rsmith, vitalybuka Differential Revision: https://reviews.llvm.org/D64317 llvm-svn: 365587
* Improve diagnostics for config mismatches with -fmodule-file.Richard Smith2018-05-241-1/+1
| | | | | | | | Unless the user uses -Wno-module-file-config-mismatch (or -Wno-error=...), allow the AST reader to produce errors describing the nature of the config mismatch. llvm-svn: 333220
* [Modules] Handle sanitizer feature mismatches when importing modulesVedant Kumar2017-06-011-0/+66
This patch makes it an error to have a mismatch between the enabled sanitizers in a CU, and in any module being imported into the CU. Only mismatches between non-modular sanitizers are treated as errors. This patch also includes non-modular sanitizers in module hashes, in order to ensure module rebuilds occur when -fsanitize=X is toggled on and off for non-modular sanitizers, and to cut down on module rebuilds when the option is toggled for modular sanitizers. This fixes a longstanding issue with implicit modules and sanitizers, which Duncan originally diagnosed. When building with implicit modules it's possible to hit a scenario where modules are built without -fsanitize=address, and are subsequently imported into CUs with -fsanitize=address enabled. This causes strange failures at runtime. The case Duncan found affects libcxx, since its vector implementation behaves differently when ASan is enabled. Implicit module builds should "just work" when -fsanitize=X is toggled on and off across multiple compiler invocations, which is what this patch does. Differential Revision: https://reviews.llvm.org/D32724 llvm-svn: 304463
OpenPOWER on IntegriCloud