]> granicus.if.org Git - clang/commitdiff
Remove 24 instances of 'REQUIRES: shell'
authorReid Kleckner <rnk@google.com>
Thu, 20 Oct 2016 23:11:45 +0000 (23:11 +0000)
committerReid Kleckner <rnk@google.com>
Thu, 20 Oct 2016 23:11:45 +0000 (23:11 +0000)
Tests fall into one of the following categories:

- The requirement was unnecessary

- Additional quoting was required for backslashes in paths (see "sed -e
  's/\\/\\\\/g'") in the sanitizer tests.

- OpenMP used 'REQUIRES: shell' as a proxy for the test failing on
  Windows. Those tests fail there reliably, so use XFAIL instead.

I tried not to remove shell requirements that were added to suppress
flaky test failures, but if I screwed up, we can add it back as needed.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@284793 91177308-0d34-0410-b5e6-96231b3b80d8

24 files changed:
test/Analysis/plist-html-macros.c
test/CodeGen/address-safety-attr.cpp
test/CodeGen/asan-globals.cpp
test/CodeGen/sanitize-init-order.cpp
test/CodeGen/sanitize-thread-attr.cpp
test/CodeGen/ubsan-blacklist.c
test/Driver/fsanitize-blacklist.c
test/Driver/rewrite-map-in-diagnostics.c
test/Modules/ModuleDebugInfo.cpp
test/Modules/ModuleDebugInfo.m
test/Modules/dependency-dump-dependent-module.m
test/Modules/empty.modulemap
test/Modules/explicit-build-extra-files.cpp
test/Modules/prune.m
test/Modules/signal.m
test/OpenMP/task_firstprivate_codegen.cpp
test/OpenMP/task_private_codegen.cpp
test/OpenMP/taskloop_firstprivate_codegen.cpp
test/OpenMP/taskloop_lastprivate_codegen.cpp
test/OpenMP/taskloop_private_codegen.cpp
test/OpenMP/taskloop_simd_firstprivate_codegen.cpp
test/OpenMP/taskloop_simd_lastprivate_codegen.cpp
test/OpenMP/taskloop_simd_private_codegen.cpp
test/PCH/debug-info-pch-path.c

index 954aab09972513d4a7dc93562a24ce3c3f05ec74..dbdbb30c4b2f9564c563dbae5cc147c4a087f9f7 100644 (file)
@@ -1,12 +1,11 @@
-// REQUIRES: shell
 // RUN: %clang_cc1 -analyze -analyzer-checker=core -verify %s
 // (sanity check)
 
 // RUN: rm -rf %t.dir
 // RUN: mkdir -p %t.dir
 // RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=plist-html -o %t.dir/index.plist %s
-// RUN: ls %t.dir | grep \\.html | count 1
-// RUN: grep \\.html %t.dir/index.plist | count 1
+// RUN: ls %t.dir | grep '\.html' | count 1
+// RUN: grep '\.html' %t.dir/index.plist | count 1
 
 // This tests two things: that the two calls to null_deref below are coalesced
 // into a single bug by both the plist and HTML diagnostics, and that the plist
index 402d6bad909de809dc59175a9547554eba865e62..0038b34cc26ff20ee9b92b69993a4e097ff7f09b 100644 (file)
@@ -9,12 +9,11 @@ int DefinedInDifferentFile(int *a);
 // RUN: echo "fun:*BlacklistedFunction*" > %t.func.blacklist
 // RUN: %clang_cc1 -std=c++11 -triple x86_64-apple-darwin -emit-llvm -o - %s -include %t.extra-source.cpp -fsanitize=address -fsanitize-blacklist=%t.func.blacklist | FileCheck -check-prefix=BLFUNC %s
 
-// RUN: echo "src:%s" > %t.file.blacklist
+// The blacklist file uses regexps, so escape backslashes, which are common in
+// Windows paths.
+// RUN: echo "src:%s" | sed -e 's/\\/\\\\/g' > %t.file.blacklist
 // RUN: %clang_cc1 -std=c++11 -triple x86_64-apple-darwin -emit-llvm -o - %s -include %t.extra-source.cpp -fsanitize=address -fsanitize-blacklist=%t.file.blacklist | FileCheck -check-prefix=BLFILE %s
 
-// FIXME: %t.file.blacklist is like "src:x:\path\to\clang\test\CodeGen\address-safety-attr.cpp"
-// REQUIRES: shell
-
 // The sanitize_address attribute should be attached to functions
 // when AddressSanitizer is enabled, unless no_sanitize_address attribute
 // is present.
index b6a323f0322c918751b5b830f2dff41a823e93ea..93abb0023cfa9402a9ee0cd7c6c478a00502326e 100644 (file)
@@ -1,9 +1,9 @@
 // RUN: echo "int extra_global;" > %t.extra-source.cpp
 // RUN: echo "global:*blacklisted_global*" > %t.blacklist
 // RUN: %clang_cc1 -include %t.extra-source.cpp -fsanitize=address -fsanitize-blacklist=%t.blacklist -emit-llvm -o - %s | FileCheck %s
-// RUN: echo "src:%s" > %t.blacklist-src
+// The blacklist file uses regexps, so Windows path backslashes.
+// RUN: echo "src:%s" | sed -e 's/\\/\\\\/g' > %t.blacklist-src
 // RUN: %clang_cc1 -include %t.extra-source.cpp -fsanitize=address -fsanitize-blacklist=%t.blacklist-src -emit-llvm -o - %s | FileCheck %s --check-prefix=BLACKLIST-SRC
-// REQUIRES: shell
 
 int global;
 int dyn_init_global = global;
index ee53f7b0771eb7b67514fa09fc2ddc90965d9724..894f75e967391735e4bbb8deffddd21680ef73ca 100644 (file)
@@ -1,12 +1,11 @@
 // RUN: %clang_cc1 -fsanitize=address -emit-llvm -o - %s | FileCheck %s
 
 // Test blacklist functionality.
-// RUN: echo "src:%s=init" > %t-file.blacklist
+// RUN: echo "src:%s=init" | sed -e 's/\\/\\\\/g' > %t-file.blacklist
 // RUN: echo "type:PODWithCtorAndDtor=init" > %t-type.blacklist
 // RUN: echo "type:NS::PODWithCtor=init" >> %t-type.blacklist
 // RUN: %clang_cc1 -fsanitize=address -fsanitize-blacklist=%t-file.blacklist -emit-llvm -o - %s | FileCheck %s --check-prefix=BLACKLIST
 // RUN: %clang_cc1 -fsanitize=address -fsanitize-blacklist=%t-type.blacklist -emit-llvm -o - %s | FileCheck %s --check-prefix=BLACKLIST
-// REQUIRES: shell
 
 struct PODStruct {
   int x;
index 46cab4dbf92fffccc5c6fa2456cdc5be62d7ab64..cffe70a51efdf79ec3dce661c6ca40869d39b67e 100644 (file)
@@ -1,10 +1,8 @@
 // RUN: %clang_cc1 -triple x86_64-apple-darwin -emit-llvm -o - %s | FileCheck -check-prefix=WITHOUT %s
 // RUN: %clang_cc1 -triple x86_64-apple-darwin -emit-llvm -o - %s -fsanitize=thread | FileCheck -check-prefix=TSAN %s
-// RUN: echo "src:%s" > %t
+// RUN: echo "src:%s" | sed -e 's/\\/\\\\/g' > %t
 // RUN: %clang_cc1 -triple x86_64-apple-darwin -emit-llvm -o - %s -fsanitize=thread -fsanitize-blacklist=%t | FileCheck -check-prefix=BL %s
 
-// REQUIRES: shell
-
 // The sanitize_thread attribute should be attached to functions
 // when ThreadSanitizer is enabled, unless no_sanitize_thread attribute
 // is present.
index f6e38822bff829e6a3f64908133ac483a17db032..666003bd9233c1c47e2cec749022a97bc287ce62 100644 (file)
@@ -1,13 +1,10 @@
 // Verify ubsan doesn't emit checks for blacklisted functions and files
 // RUN: echo "fun:hash" > %t-func.blacklist
-// RUN: echo "src:%s" > %t-file.blacklist
+// RUN: echo "src:%s" | sed -e 's/\\/\\\\/g' > %t-file.blacklist
 // RUN: %clang_cc1 -fsanitize=unsigned-integer-overflow -emit-llvm %s -o - | FileCheck %s --check-prefix=DEFAULT
 // RUN: %clang_cc1 -fsanitize=unsigned-integer-overflow -fsanitize-blacklist=%t-func.blacklist -emit-llvm %s -o - | FileCheck %s --check-prefix=FUNC
 // RUN: %clang_cc1 -fsanitize=unsigned-integer-overflow -fsanitize-blacklist=%t-file.blacklist -emit-llvm %s -o - | FileCheck %s --check-prefix=FILE
 
-// FIXME: %t-file.blacklist contains DOSish paths.
-// REQUIRES: shell
-
 unsigned i;
 
 // DEFAULT: @hash
index 9edbbaf2bd8d1adc9bfd21b18ce5cdbd9262d7f8..adf776fcae73f325185689b69fde2687119bc568 100644 (file)
@@ -1,7 +1,7 @@
 // General blacklist usage.
 
 // PR12920
-// REQUIRES: clang-driver, shell
+// REQUIRES: clang-driver
 
 // Make sure we don't match the -NOT lines with the linker invocation.
 // Delimiters match the start of the cc1 and the start of the linker lines
index 4aea0ec031456bdb8de3f32898dd9a77c864e119..7c5811539ef140a382cf05aa3c353cd3cb9221b1 100644 (file)
@@ -9,6 +9,3 @@
 // CHECK: note: diagnostic msg: {{.*}}rewrite.map
 
 // REQUIRES: crash-recovery
-
-// FIXME: This doesn't fail on "env clang". Investigating.
-// REQUIRES: shell
index 1bc0613f427e3a95c74a8ed5f69a14414cef562c..71b05e5aeb8bdde320c46761523974904b9588b3 100644 (file)
@@ -1,7 +1,7 @@
 // Test that (the same) debug info is emitted for an Objective-C++
 // module and a C++ precompiled header.
 
-// REQUIRES: asserts, shell
+// REQUIRES: asserts
 
 // Modules:
 // RUN: rm -rf %t
index ce35c7c8361ffa19b53a25298e3d330210a52ab6..d1a0e8d5e80a889f0f81442d971477be1922d9d4 100644 (file)
@@ -1,7 +1,7 @@
 // Test that debug info is emitted for an Objective-C module and
 // a precompiled header.
 
-// REQUIRES: asserts, shell
+// REQUIRES: asserts
 
 // Modules:
 // RUN: rm -rf %t
index df7f5326bb6cfcc21492e8a9274c635d68ec95f3..2430726d3ae5a1f5ee38912c63d49ca742a6d5ab 100644 (file)
@@ -14,9 +14,3 @@
 // VFS: 'name': "Sub2.h"
 
 @import AlsoDependsOnModule;
-
-// FIXME: This fails on win32 due to ERROR_FILENAME_EXCED_RANGE
-// if the working directory is too deep.
-// We should make Win32/Path.inc capable of long pathnames with '\\?\'.
-// For now, this is suppressed on win32.
-// REQUIRES: shell
index 0d1718409d551cd62101e36e21577d6deae6b82d..aa9eba66a4f8169d5d6788b73912bc2b9790b30e 100644 (file)
@@ -14,7 +14,6 @@
 // RUN: diff %t/base.pcm %t/check.pcm
 //
 // We expect an empty module to be less than 30KB (and at least 10K, for now).
-// REQUIRES: shell
 // RUN: wc -c %t/base.pcm | FileCheck --check-prefix=CHECK-SIZE %s
 // CHECK-SIZE: {{(^|[^0-9])[12][0-9][0-9][0-9][0-9]($|[^0-9])}}
 
index 6cec420832d62462f091bdc5439695c009c7e11c..965aea13ae13eaad30773fea648578680b58622a 100644 (file)
@@ -1,5 +1,3 @@
-// REQUIRES: shell
-//
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cd %t
index 6676407c9acd8ab9eb87dc46a878cd79c8038119..58992f9c006d210341b5adcc1523898cad3e6f7f 100644 (file)
@@ -5,9 +5,6 @@
 @import Module;
 #endif
 
-// We need 'touch' and 'find' for this test to work.
-// REQUIRES: shell
-
 // Clear out the module cache
 // RUN: rm -rf %t
 // Run Clang twice so we end up creating the timestamp file (the second time).
@@ -28,7 +25,7 @@
 // Set the DependsOnModule access time back more than four days.
 // This shouldn't prune anything, because the timestamp has been updated, so
 // the pruning mechanism won't fire.
-// RUN: find %t -name DependsOnModule*.pcm | xargs touch -a -t 201101010000
+// RUN: find %t -name DependsOnModule*.pcm | sed -e 's/\\/\//g' | xargs touch -a -t 201101010000
 // RUN: %clang_cc1 -fmodules -fimplicit-module-maps -F %S/Inputs -fmodules-cache-path=%t -fmodules -fmodules-prune-interval=172800 -fmodules-prune-after=345600 %s -verify
 // RUN: ls %t | grep modules.timestamp
 // RUN: ls -R %t | grep ^Module.*pcm
@@ -37,7 +34,7 @@
 // Set both timestamp and DependsOnModule.pcm back beyond the cutoff.
 // This should trigger pruning, which will remove DependsOnModule but not Module.
 // RUN: touch -m -a -t 201101010000 %t/modules.timestamp 
-// RUN: find %t -name DependsOnModule*.pcm | xargs touch -a -t 201101010000
+// RUN: find %t -name DependsOnModule*.pcm | sed -e 's/\\/\//g' | xargs touch -a -t 201101010000
 // RUN: %clang_cc1 -fmodules -fimplicit-module-maps -F %S/Inputs -fmodules-cache-path=%t -fmodules -fmodules-prune-interval=172800 -fmodules-prune-after=345600 %s -verify
 // RUN: ls %t | grep modules.timestamp
 // RUN: ls -R %t | grep ^Module.*pcm
index 37a35506447d685954c13c9c02ba901b2f243ba6..4d0885e56c8b9a90a1e049468dedf3ec8f5798b6 100644 (file)
@@ -1,4 +1,4 @@
-// REQUIRES: crash-recovery,shell
+// REQUIRES: crash-recovery
 // RUN: rm -rf %t
 
 // Crash building module.
index 0d8e1c4afe4e5ff24abc05e63a614b4ee09c5aa5..b17729312a22782431ac6f359fbdaa510435b061 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32.
-// REQUIRES: shell
+// XFAIL: win32
 #ifndef ARRAY
 #ifndef HEADER
 #define HEADER
index 97155a73f1bd0c5495c82d1ccccd50d1c3eeb83a..2e2ae844d2f06a590f56b4858992820f45f80f14 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32. Investigating.
-// REQUIRES: shell
+// XFAIL: win32
 
 #ifndef ARRAY
 #ifndef HEADER
index 822a5c687dc76af23a0cef11e6178b34f4824fe7..d6886e391332138d34be2fed1304cb658d5e4117 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32.
-// REQUIRES: shell
+// XFAIL: win32
 #ifndef ARRAY
 #ifndef HEADER
 #define HEADER
index 8414b6f963f9819ba6667c0973e5c01404f7b4d2..c8293ebae876475cbfd01286a843710c86955b3f 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32.
-// REQUIRES: shell
+// XFAIL: win32
 #ifndef ARRAY
 #ifndef HEADER
 #define HEADER
index 38b20c579393bf215a7f419dfa6816b4dad6e928..630a5c120250c077da0dec041cea8f8e3476aee8 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32. Investigating.
-// REQUIRES: shell
+// XFAIL: win32
 
 #ifndef ARRAY
 #ifndef HEADER
index 0b87ddd9acb1220244e95d013465efb4670328f9..01a4f28e5b7bfb68894a867cc659eafa8d5a97e9 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32.
-// REQUIRES: shell
+// XFAIL: win32
 #ifndef ARRAY
 #ifndef HEADER
 #define HEADER
index e3562a8f0c62d8f4da4d0127eefe400c8b006f9e..856285d7c21c3adc26a2681fe6c521e2d53d301e 100644 (file)
@@ -6,8 +6,8 @@
 // RUN: %clang_cc1 -verify -fopenmp -x c++ -std=c++11 -DARRAY -triple x86_64-apple-darwin10 -emit-llvm %s -o - | FileCheck -check-prefix=ARRAY %s
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
-// It doesn't pass on win32.
-// REQUIRES: shell
+// XFAIL: win32
+
 #ifndef ARRAY
 #ifndef HEADER
 #define HEADER
index 557601e9c93e4013843e3523b188df13d76bd349..985a2b5828708e8b2d629e0340bc5e9843d02958 100644 (file)
@@ -7,7 +7,7 @@
 // expected-no-diagnostics
 // REQUIRES: x86-registered-target
 // It doesn't pass on win32. Investigating.
-// REQUIRES: shell
+// XFAIL: win32
 
 #ifndef ARRAY
 #ifndef HEADER
index 402d44da918d38e5dc4a7dc61385525de69311e7..015086f726e88d263067365c402bba6dc645dd7b 100644 (file)
@@ -1,5 +1,3 @@
-// REQUIRES: shell
-//
 // RUN: rm -rf %t
 // RUN: mkdir %t
 // RUN: cd %t