diff options
author | Will Dietz <wdietz2@illinois.edu> | 2012-12-30 20:53:39 +0000 |
---|---|---|
committer | Will Dietz <wdietz2@illinois.edu> | 2012-12-30 20:53:39 +0000 |
commit | 2a5f569d882b71619cf4a9b3fe48fac6ade8b806 (patch) | |
tree | 0e3f63b4cb50e20815b1f89aad423ae96c33a0c5 | |
parent | 3676d56b71e9da957ffe9d40dc9f1d5b8bbddf81 (diff) | |
download | bcm5719-llvm-2a5f569d882b71619cf4a9b3fe48fac6ade8b806.tar.gz bcm5719-llvm-2a5f569d882b71619cf4a9b3fe48fac6ade8b806.zip |
[ubsan] Update test now that check recovery is default and has driver flag.
llvm-svn: 171265
-rw-r--r-- | compiler-rt/lib/ubsan/lit_tests/Integer/no-recover.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/compiler-rt/lib/ubsan/lit_tests/Integer/no-recover.cpp b/compiler-rt/lib/ubsan/lit_tests/Integer/no-recover.cpp index 08324bd60d2..b25d440c0fd 100644 --- a/compiler-rt/lib/ubsan/lit_tests/Integer/no-recover.cpp +++ b/compiler-rt/lib/ubsan/lit_tests/Integer/no-recover.cpp @@ -1,5 +1,6 @@ -// RUN: %clang -fsanitize=unsigned-integer-overflow -Xclang -fsanitize-recover %s -o %t && %t 2>&1 | FileCheck %s --check-prefix=RECOVER -// RUN: %clang -fsanitize=unsigned-integer-overflow %s -o %t && %t 2>&1 | FileCheck %s --check-prefix=ABORT +// RUN: %clang -fsanitize=unsigned-integer-overflow %s -o %t && %t 2>&1 | FileCheck %s --check-prefix=RECOVER +// RUN: %clang -fsanitize=unsigned-integer-overflow -fsanitize-recover %s -o %t && %t 2>&1 | FileCheck %s --check-prefix=RECOVER +// RUN: %clang -fsanitize=unsigned-integer-overflow -fno-sanitize-recover %s -o %t && %t 2>&1 | FileCheck %s --check-prefix=ABORT #include <stdint.h> @@ -12,8 +13,8 @@ int main() { uint32_t k = 0x87654321; k += 0xedcba987; - // RECOVER: no-recover.cpp:14:5: runtime error: unsigned integer overflow: 2271560481 + 3989547399 cannot be represented in type 'uint32_t' (aka 'unsigned int') - // ABORT: no-recover.cpp:14:5: runtime error: unsigned integer overflow: 2271560481 + 3989547399 cannot be represented in type 'uint32_t' (aka 'unsigned int') + // RECOVER: no-recover.cpp:[[@LINE-1]]:5: runtime error: unsigned integer overflow: 2271560481 + 3989547399 cannot be represented in type 'uint32_t' (aka 'unsigned int') + // ABORT: no-recover.cpp:[[@LINE-2]]:5: runtime error: unsigned integer overflow: 2271560481 + 3989547399 cannot be represented in type 'uint32_t' (aka 'unsigned int') (void)(uint64_t(10000000000000000000ull) + uint64_t(9000000000000000000ull)); // RECOVER: 10000000000000000000 + 9000000000000000000 cannot be represented in type 'unsigned long' |