[PATCH] D15099: lit: Support RunSafely remote execution
Matthias Braun via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 30 20:47:52 PST 2015
MatzeB created this revision.
MatzeB added reviewers: jmolloy, rengolin, beanz, cmatthews.
MatzeB added a subscriber: llvm-commits.
http://reviews.llvm.org/D15099
Files:
CMakeLists.txt
lit.cfg
lit.site.cfg.in
Index: lit.site.cfg.in
===================================================================
--- lit.site.cfg.in
+++ lit.site.cfg.in
@@ -2,5 +2,9 @@
config.test_source_root = "@CMAKE_BINARY_DIR@"
config.test_suite_root = "@CMAKE_SOURCE_DIR@"
+config.remote_client = "@TEST_SUITE_REMOTE_CLIENT@"
+config.remote_host = "@TEST_SUITE_REMOTE_HOST@"
+config.remote_user = "@TEST_SUITE_REMOTE_USER@"
+config.remote_port = "@TEST_SUITE_REMOTE_PORT@"
lit_config.load_config(config, "@CMAKE_SOURCE_DIR@/lit.cfg")
Index: lit.cfg
===================================================================
--- lit.cfg
+++ lit.cfg
@@ -108,10 +108,19 @@
if stdout is not None or stderr is not None:
raise Exception("stdout/stderr redirection in combination with RunSafely not implemented yet")
- timeit = "%s/tools/timeit" % config.test_source_root
runsafely = "%s/RunSafely.sh" % config.test_suite_root
+ runsafely_prefix = [ runsafely ]
+ if config.remote_host:
+ runsafely_prefix += [ "-r", config.remote_host ]
+ if config.remote_user:
+ runsafely_prefix += [ "-l", config.remote_user ]
+ if config.remote_client:
+ runsafely_prefix += [ "-rc", config.remote_client ]
+ if config.remote_port:
+ runsafely_prefix += [ "-rp", config.remote_port ]
+ timeit = "%s/tools/timeit-target" % config.test_source_root
timeout = "7200"
- runsafely_prefix = [runsafely, "-t", timeit, timeout, stdin, outfile]
+ runsafely_prefix += [ "-t", timeit, timeout, stdin, outfile ]
new_commandline = " ".join(map(quote, runsafely_prefix + tokens))
return new_commandline
@@ -204,3 +213,5 @@
config.test_format = TestSuiteTest()
config.suffixes = ['.test']
config.excludes = ['ABI-Testsuite']
+if 'SSH_AUTH_SOCK' in os.environ:
+ config.environment['SSH_AUTH_SOCK'] = os.environ['SSH_AUTH_SOCK']
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt
+++ CMakeLists.txt
@@ -32,6 +32,13 @@
Please delete them.")
endif()
+# Remote configuration (will be set in lit.site.cfg)
+set(TEST_SUITE_REMOTE_CLIENT "ssh" CACHE STRING "Remote execution client")
+set(TEST_SUITE_REMOTE_HOST "" CACHE STRING "Remote execution host")
+set(TEST_SUITE_REMOTE_USER "" CACHE STRING "Remote execution user")
+set(TEST_SUITE_REMOTE_PORT "" CACHE STRING "Remote execution port")
+mark_as_advanced(TEST_SUITE_REMOTE_USER TEST_SUITE_REMOTE_PORT)
+
include(MakefileFunctions)
include(SingleMultiSource)
find_package(YACC)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D15099.41459.patch
Type: text/x-patch
Size: 2544 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151201/323a8d04/attachment.bin>
More information about the llvm-commits
mailing list