summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/sanitize-use-after-scope.c
diff options
context:
space:
mode:
authorAlexey Samsonov <vonosmas@gmail.com>2014-06-13 17:53:44 +0000
committerAlexey Samsonov <vonosmas@gmail.com>2014-06-13 17:53:44 +0000
commite595e1ade02c7581a2e2ad5392f7714b7f342c05 (patch)
tree27b1ae2e276e69e5c3dd8a813b451e800070488c /clang/test/CodeGen/sanitize-use-after-scope.c
parent51472bc600fc5622d50c6d9cefd88528b8c50f17 (diff)
downloadbcm5719-llvm-e595e1ade02c7581a2e2ad5392f7714b7f342c05.tar.gz
bcm5719-llvm-e595e1ade02c7581a2e2ad5392f7714b7f342c05.zip
Remove top-level Clang -fsanitize= flags for optional ASan features.
Init-order and use-after-return modes can currently be enabled by runtime flags. use-after-scope mode is not really working at the moment. The only problem I see is that users won't be able to disable extra instrumentation for init-order and use-after-scope by a top-level Clang flag. But this instrumentation was implicitly enabled for quite a while and we didn't hear from users hurt by it. llvm-svn: 210924
Diffstat (limited to 'clang/test/CodeGen/sanitize-use-after-scope.c')
-rw-r--r--clang/test/CodeGen/sanitize-use-after-scope.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/clang/test/CodeGen/sanitize-use-after-scope.c b/clang/test/CodeGen/sanitize-use-after-scope.c
deleted file mode 100644
index 8f920385bc2..00000000000
--- a/clang/test/CodeGen/sanitize-use-after-scope.c
+++ /dev/null
@@ -1,22 +0,0 @@
-// RUN: %clang_cc1 -S -emit-llvm -o - -fsanitize=address,use-after-scope %s \
-// RUN: | FileCheck %s -check-prefix=USE-AFTER-SCOPE
-// RUN: %clang_cc1 -S -emit-llvm -o - -fsanitize=address %s \
-// RUN: | FileCheck %s -check-prefix=ADDRESS-ONLY
-
-extern int bar(char *A, int n);
-
-// ADDRESS-ONLY-NOT: @llvm.lifetime.start
-int foo (int n) {
- if (n) {
- // USE-AFTER-SCOPE: @llvm.lifetime.start(i64 10, i8* {{.*}})
- char A[10];
- return bar(A, 1);
- // USE-AFTER-SCOPE: @llvm.lifetime.end(i64 10, i8* {{.*}})
- } else {
- // USE-AFTER-SCOPE: @llvm.lifetime.start(i64 20, i8* {{.*}})
- char A[20];
- return bar(A, 2);
- // USE-AFTER-SCOPE: @llvm.lifetime.end(i64 20, i8* {{.*}})
- }
-}
-
OpenPOWER on IntegriCloud