[PATCH] D17045: [msan] Mark fork.cc unsupported on mips64 (and make it possible to do so)

Daniel Sanders via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 9 15:11:45 PST 2016


dsanders created this revision.
dsanders added reviewers: samsonov, hans.
dsanders added a subscriber: llvm-commits.
dsanders added a dependency: D16855: [msan] Run the tests for each supported arch and suffix each one to distinguish them..

fork.cc currently hangs for mips64, preventing 'check-all' from finishing
in the 3.8 release.

We can't xfail it since that still runs the test, so we must mark it
'unsupported' instead. Unfortunately, the target triple that lit checks against
is the default target triple which in our case is different to the actual
target triple.

This patch resolves this by making '${target_arch}-arch' an available feature
for use in lit directives. We can then use that to correctly mark the test
'unsupported'. The reason for the '-arch' suffix is so that 'mips64' doesn't
also match 'mips64el' which currently passes this test.

Depends on D16855.

http://reviews.llvm.org/D17045

Files:
  test/msan/fork.cc
  test/msan/lit.cfg
  test/msan/lit.site.cfg.in

Index: test/msan/lit.site.cfg.in
===================================================================
--- test/msan/lit.site.cfg.in
+++ test/msan/lit.site.cfg.in
@@ -6,6 +6,7 @@
 
 # Tool-specific config options.
 config.name_suffix = "@MSAN_TEST_CONFIG_SUFFIX@"
+config.target_arch = "@arch@"
 config.target_cflags = "@MSAN_TEST_TARGET_CFLAGS@"
 # Load tool-specific config that would do the real work.
 lit_config.load_config(config, "@MSAN_LIT_SOURCE_DIR@/lit.cfg")
Index: test/msan/lit.cfg
===================================================================
--- test/msan/lit.cfg
+++ test/msan/lit.cfg
@@ -26,6 +26,8 @@
 config.substitutions.append( ("%clang_msan ", build_invocation(clang_msan_cflags)) )
 config.substitutions.append( ("%clangxx_msan ", build_invocation(clang_msan_cxxflags)) )
 
+config.available_features.add(config.target_arch + '-arch')
+
 # Default test suffixes.
 config.suffixes = ['.c', '.cc', '.cpp']
 
Index: test/msan/fork.cc
===================================================================
--- test/msan/fork.cc
+++ test/msan/fork.cc
@@ -10,6 +10,9 @@
 // a kernel bug:
 // https://lkml.org/lkml/2014/2/17/324
 
+// Big-endian mips64 currently hangs on this test. Mark it unsupported to allow
+// llvm-lit to finish.
+// UNSUPPORTED: mips64-arch
 
 #include <pthread.h>
 #include <unistd.h>


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D17045.47379.patch
Type: text/x-patch
Size: 1327 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160209/eba9b0df/attachment.bin>


More information about the llvm-commits mailing list