summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Samsonov <samsonov@google.com>2013-05-21 09:01:13 +0000
committerAlexey Samsonov <samsonov@google.com>2013-05-21 09:01:13 +0000
commit1c26f007ed693220d60544fc743de2a3c823b742 (patch)
tree95727f7620b126a6fd2dd74fa3f1153bfa074abc
parent1d2f22825d8d9f7a902a96404fb15c1b0d69f2e9 (diff)
downloadbcm5719-llvm-1c26f007ed693220d60544fc743de2a3c823b742.tar.gz
bcm5719-llvm-1c26f007ed693220d60544fc743de2a3c823b742.zip
[ASan] Mark some tests as working only on x86_64 and i386 arches
llvm-svn: 182360
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/asan_prelink_test.cc2
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/interface_symbols_linux.c4
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/malloc-in-qsort.cc9
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/overflow-in-qsort.cc9
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/time_null_regtest.cc3
-rw-r--r--compiler-rt/lib/asan/lit_tests/Linux/zero-base-shadow.cc3
6 files changed, 28 insertions, 2 deletions
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/asan_prelink_test.cc b/compiler-rt/lib/asan/lit_tests/Linux/asan_prelink_test.cc
index 522c1917139..c209c39c8c4 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/asan_prelink_test.cc
+++ b/compiler-rt/lib/asan/lit_tests/Linux/asan_prelink_test.cc
@@ -8,6 +8,8 @@
// RUN: %clangxx_asan -m64 -DBUILD_SO=1 -fPIC -shared %s -o %t.so -Wl,-Ttext=0x3600000000
// RUN: %clangxx_asan -m64 %t.o %t.so -Wl,-R. -o %t
// RUN: ASAN_OPTIONS=verbosity=1 %t 2>&1 | FileCheck %s
+
+// REQUIRES: x86_64-supported-target
#if BUILD_SO
int G;
int *getG() {
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/interface_symbols_linux.c b/compiler-rt/lib/asan/lit_tests/Linux/interface_symbols_linux.c
index 95746d786f9..dcef7c20822 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/interface_symbols_linux.c
+++ b/compiler-rt/lib/asan/lit_tests/Linux/interface_symbols_linux.c
@@ -27,4 +27,8 @@
// RUN: echo __asan_report_store_n >> %t.interface
// RUN: cat %t.interface | sort -u | diff %t.symbols -
+// FIXME: nm -D on powerpc somewhy shows ASan interface symbols residing
+// in "initialized data section".
+// XFAIL: powerpc-supported-arch
+
int main() { return 0; }
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/malloc-in-qsort.cc b/compiler-rt/lib/asan/lit_tests/Linux/malloc-in-qsort.cc
index a3fa255b186..0e2d3a667bf 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/malloc-in-qsort.cc
+++ b/compiler-rt/lib/asan/lit_tests/Linux/malloc-in-qsort.cc
@@ -1,10 +1,17 @@
-// RUN: %clangxx_asan -O2 %s -o %t
+// RUN: %clangxx_asan -m32 -O2 %s -o %t
+// RUN: ASAN_OPTIONS=fast_unwind_on_malloc=1 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-FAST
+// RUN: ASAN_OPTIONS=fast_unwind_on_malloc=0 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-SLOW
+// RUN: %clangxx_asan -m64 -O2 %s -o %t
// RUN: ASAN_OPTIONS=fast_unwind_on_malloc=1 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-FAST
// RUN: ASAN_OPTIONS=fast_unwind_on_malloc=0 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-SLOW
// Test how well we unwind in presence of qsort in the stack
// (i.e. if we can unwind through a function compiled w/o frame pointers).
// https://code.google.com/p/address-sanitizer/issues/detail?id=137
+
+// Fast unwinder is only avaliable on x86_64 and i386.
+// REQUIRES: x86_64-supported-target,i386-supported-target
+
#include <stdlib.h>
#include <stdio.h>
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/overflow-in-qsort.cc b/compiler-rt/lib/asan/lit_tests/Linux/overflow-in-qsort.cc
index c298991a834..05d6f2400e5 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/overflow-in-qsort.cc
+++ b/compiler-rt/lib/asan/lit_tests/Linux/overflow-in-qsort.cc
@@ -1,10 +1,17 @@
-// RUN: %clangxx_asan -O2 %s -o %t
+// RUN: %clangxx_asan -m32 -O2 %s -o %t
+// RUN: ASAN_OPTIONS=fast_unwind_on_fatal=1 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-FAST
+// RUN: ASAN_OPTIONS=fast_unwind_on_fatal=0 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-SLOW
+// RUN: %clangxx_asan -m64 -O2 %s -o %t
// RUN: ASAN_OPTIONS=fast_unwind_on_fatal=1 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-FAST
// RUN: ASAN_OPTIONS=fast_unwind_on_fatal=0 %t 2>&1 | %symbolize | FileCheck %s --check-prefix=CHECK-SLOW
// Test how well we unwind in presence of qsort in the stack
// (i.e. if we can unwind through a function compiled w/o frame pointers).
// https://code.google.com/p/address-sanitizer/issues/detail?id=137
+
+// Fast unwinder is only avaliable on x86_64 and i386.
+// REQUIRES: x86_64-supported-target,i386-supported-target
+
#include <stdlib.h>
#include <stdio.h>
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/time_null_regtest.cc b/compiler-rt/lib/asan/lit_tests/Linux/time_null_regtest.cc
index fee20edd36d..975bca3d105 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/time_null_regtest.cc
+++ b/compiler-rt/lib/asan/lit_tests/Linux/time_null_regtest.cc
@@ -1,5 +1,8 @@
// RUN: %clangxx_asan -m64 -O0 %s -fsanitize-address-zero-base-shadow -pie -o %t && %t 2>&1 | %symbolize | FileCheck %s
+// Zero-base shadow only works on x86_64 and i386.
+// REQUIRES: x86_64-supported-target
+
// A regression test for time(NULL), which caused ASan to crash in the
// zero-based shadow mode on Linux.
// FIXME: this test does not work on Darwin, because the code pages of the
diff --git a/compiler-rt/lib/asan/lit_tests/Linux/zero-base-shadow.cc b/compiler-rt/lib/asan/lit_tests/Linux/zero-base-shadow.cc
index 44779a40558..682e7e8d7e5 100644
--- a/compiler-rt/lib/asan/lit_tests/Linux/zero-base-shadow.cc
+++ b/compiler-rt/lib/asan/lit_tests/Linux/zero-base-shadow.cc
@@ -11,6 +11,9 @@
// RUN: %clangxx_asan -m32 -O2 -fsanitize-address-zero-base-shadow -fPIE -pie %s -o %t && %t 2>&1 | %symbolize > %t.out
// RUN: FileCheck %s < %t.out && FileCheck %s --check-prefix=CHECK-32 < %t.out
+// Zero-base shadow only works on x86_64 and i386.
+// REQUIRES: x86_64-supported-target,i386-supported-target
+
#include <string.h>
int main(int argc, char **argv) {
char x[10];
OpenPOWER on IntegriCloud