From 8845952b54a7574cedbbd0661e889cd4e2d5947b Mon Sep 17 00:00:00 2001 From: Alexey Samsonov Date: Mon, 12 Jan 2015 22:39:12 +0000 Subject: Reimplement -fsanitize-recover family of flags. Introduce the following -fsanitize-recover flags: - -fsanitize-recover=: Enable recovery for selected checks or group of checks. It is forbidden to explicitly list unrecoverable sanitizers here (that is, "address", "unreachable", "return"). - -fno-sanitize-recover=: Disable recovery for selected checks or group of checks. - -f(no-)?sanitize-recover is now a synonym for -f(no-)?sanitize-recover=undefined,integer and will soon be deprecated. These flags are parsed left to right, and mask of "recoverable" sanitizer is updated accordingly, much like what we do for -fsanitize= flags. -fsanitize= and -fsanitize-recover= flag families are independent. CodeGen change: If there is a single UBSan handler function, responsible for implementing multiple checks, which have different recoverable setting, then we emit two handler calls instead of one: the first one for the set of "unrecoverable" checks, another one - for set of "recoverable" checks. If all checks implemented by a handler have the same recoverability setting, then the generated code will be the same. llvm-svn: 225719 --- clang/test/CodeGen/compound-assign-overflow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clang/test/CodeGen/compound-assign-overflow.c') diff --git a/clang/test/CodeGen/compound-assign-overflow.c b/clang/test/CodeGen/compound-assign-overflow.c index 15334294d47..f126bb05d53 100644 --- a/clang/test/CodeGen/compound-assign-overflow.c +++ b/clang/test/CodeGen/compound-assign-overflow.c @@ -1,5 +1,5 @@ // Verify proper type emitted for compound assignments -// RUN: %clang_cc1 -ffreestanding -triple x86_64-apple-darwin10 -emit-llvm -o - %s -fsanitize=signed-integer-overflow,unsigned-integer-overflow | FileCheck %s +// RUN: %clang_cc1 -ffreestanding -triple x86_64-apple-darwin10 -emit-llvm -o - %s -fsanitize=signed-integer-overflow,unsigned-integer-overflow -fsanitize-recover=signed-integer-overflow,unsigned-integer-overflow | FileCheck %s #include -- cgit v1.2.3