[compiler-rt] r191204 - [asan] remove -fsanitize=use-after-return from the tests (this flag now comes with asan by default)
Kostya Serebryany
kcc at google.com
Mon Sep 23 07:34:06 PDT 2013
Author: kcc
Date: Mon Sep 23 09:34:06 2013
New Revision: 191204
URL: http://llvm.org/viewvc/llvm-project?rev=191204&view=rev
Log:
[asan] remove -fsanitize=use-after-return from the tests (this flag now comes with asan by default)
Modified:
compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc
compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc
compiler-rt/trunk/lib/asan/lit_tests/TestCases/deep_call_stack.cc
compiler-rt/trunk/lib/asan/lit_tests/TestCases/stack-use-after-return.cc
compiler-rt/trunk/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc
compiler-rt/trunk/lib/asan/tests/CMakeLists.txt
Modified: compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/heavy_uar_test.cc Mon Sep 23 09:34:06 2013
@@ -1,7 +1,7 @@
// RUN: export ASAN_OPTIONS=detect_stack_use_after_return=1
-// RUN: %clangxx_asan -fsanitize=use-after-return -O0 %s -o %t && \
+// RUN: %clangxx_asan -O0 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
-// RUN: %clangxx_asan -fsanitize=use-after-return -O2 %s -o %t && \
+// RUN: %clangxx_asan -O2 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
#include <stdio.h>
Modified: compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/TestCases/Linux/uar_signals.cc Mon Sep 23 09:34:06 2013
@@ -1,7 +1,7 @@
// This test shows that the current implementation of use-after-return is
// not signal-safe.
// RUN: %clangxx_asan -O1 %s -o %t -lpthread && %t
-// RUN: %clangxx_asan -fsanitize=use-after-return -O1 %s -o %t -lpthread && %t
+// RUN: %clangxx_asan -O1 %s -o %t -lpthread && %t
#include <signal.h>
#include <stdlib.h>
#include <stdio.h>
Modified: compiler-rt/trunk/lib/asan/lit_tests/TestCases/deep_call_stack.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/TestCases/deep_call_stack.cc?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/TestCases/deep_call_stack.cc (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/TestCases/deep_call_stack.cc Mon Sep 23 09:34:06 2013
@@ -1,6 +1,6 @@
// Check that UAR mode can handle very deep recusrion.
-//
-// RUN: %clangxx_asan -fsanitize=use-after-return -O2 %s -o %t && \
+// export ASAN_OPTIONS=detect_stack_use_after_return=1
+// RUN: %clangxx_asan -O2 %s -o %t && \
// RUN: %t 2>&1 | FileCheck %s
#include <stdio.h>
Modified: compiler-rt/trunk/lib/asan/lit_tests/TestCases/stack-use-after-return.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/TestCases/stack-use-after-return.cc?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/TestCases/stack-use-after-return.cc (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/TestCases/stack-use-after-return.cc Mon Sep 23 09:34:06 2013
@@ -1,19 +1,19 @@
// RUN: export ASAN_OPTIONS=detect_stack_use_after_return=1
-// RUN: %clangxx_asan -fsanitize=use-after-return -O0 %s -o %t && \
+// RUN: %clangxx_asan -O0 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
-// RUN: %clangxx_asan -fsanitize=use-after-return -O1 %s -o %t && \
+// RUN: %clangxx_asan -O1 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
-// RUN: %clangxx_asan -fsanitize=use-after-return -O2 %s -o %t && \
+// RUN: %clangxx_asan -O2 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
-// RUN: %clangxx_asan -fsanitize=use-after-return -O3 %s -o %t && \
+// RUN: %clangxx_asan -O3 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck %s
// RUN: ASAN_OPTIONS=detect_stack_use_after_return=0 %t
// Regression test for a CHECK failure with small stack size and large frame.
-// RUN: %clangxx_asan -fsanitize=use-after-return -O3 %s -o %t -DkSize=10000 && \
+// RUN: %clangxx_asan -O3 %s -o %t -DkSize=10000 && \
// RUN: (ulimit -s 65; not %t) 2>&1 | FileCheck %s
//
// Test that we can find UAR in a thread other than main:
-// RUN: %clangxx_asan -fsanitize=use-after-return -DUseThread -O2 %s -o %t && \
+// RUN: %clangxx_asan -DUseThread -O2 %s -o %t && \
// RUN: not %t 2>&1 | FileCheck --check-prefix=THREAD %s
#include <stdio.h>
Modified: compiler-rt/trunk/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc (original)
+++ compiler-rt/trunk/lib/asan/lit_tests/TestCases/uar_and_exceptions.cc Mon Sep 23 09:34:06 2013
@@ -1,5 +1,6 @@
// Test that use-after-return works with exceptions.
-// RUN: %clangxx_asan -fsanitize=use-after-return -O0 %s -o %t && %t
+// export ASAN_OPTIONS=detect_stack_use_after_return=1
+// RUN: %clangxx_asan -O0 %s -o %t && %t
#include <stdio.h>
Modified: compiler-rt/trunk/lib/asan/tests/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/tests/CMakeLists.txt?rev=191204&r1=191203&r2=191204&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/tests/CMakeLists.txt (original)
+++ compiler-rt/trunk/lib/asan/tests/CMakeLists.txt Mon Sep 23 09:34:06 2013
@@ -67,7 +67,6 @@ set(ASAN_UNITTEST_INSTRUMENTED_CFLAGS
-mllvm -asan-globals=1
-mllvm -asan-mapping-scale=0 # default will be used
-mllvm -asan-mapping-offset-log=-1 # default will be used
- -mllvm -asan-use-after-return=0
)
if(ASAN_TESTS_USE_ZERO_BASE_SHADOW)
list(APPEND ASAN_UNITTEST_INSTRUMENTED_CFLAGS
More information about the llvm-commits
mailing list