summaryrefslogtreecommitdiffstats
path: root/Help/command
diff options
context:
space:
mode:
authorBetsy McPhail <betsy.mcphail@kitware.com>2015-06-09 12:50:44 (GMT)
committerBrad King <brad.king@kitware.com>2015-06-30 14:21:37 (GMT)
commitf62d301b9257542f5460902c400af3f947f10a66 (patch)
tree8d21c57b3f3e7b5187b8c56781d7549cf0f93f47 /Help/command
parent07c550caa20d4b1d6ebc08269d744ff6a45c0a6d (diff)
downloadCMake-f62d301b9257542f5460902c400af3f947f10a66.zip
CMake-f62d301b9257542f5460902c400af3f947f10a66.tar.gz
CMake-f62d301b9257542f5460902c400af3f947f10a66.tar.bz2
ctest: Optionally avoid starting tests that may exceed a given CPU load
Add a TestLoad setting to CTest that can be set via a new --test-load command-line option, CTEST_TEST_LOAD variable, or TEST_LOAD option to the ctest_test command. Teach cmCTestMultiProcessHandler to measure the CPU load and avoid starting tests that may take more than the spare load currently available. The expression <current_load> + <test_processors> <= <max-load> must be true to start a new test. Co-Author: Zack Galbreath <zack.galbreath@kitware.com>
Diffstat (limited to 'Help/command')
-rw-r--r--Help/command/ctest_memcheck.rst1
-rw-r--r--Help/command/ctest_test.rst8
2 files changed, 9 insertions, 0 deletions
diff --git a/Help/command/ctest_memcheck.rst b/Help/command/ctest_memcheck.rst
index 2800511..29bdf7d 100644
--- a/Help/command/ctest_memcheck.rst
+++ b/Help/command/ctest_memcheck.rst
@@ -14,6 +14,7 @@ Perform the :ref:`CTest MemCheck Step` as a :ref:`Dashboard Client`.
[EXCLUDE_LABEL <label-exclude-regex>]
[INCLUDE_LABEL <label-include-regex>]
[PARALLEL_LEVEL <level>]
+ [TEST_LOAD <threshold>]
[SCHEDULE_RANDOM <ON|OFF>]
[STOP_TIME <time-of-day>]
[RETURN_VALUE <result-var>]
diff --git a/Help/command/ctest_test.rst b/Help/command/ctest_test.rst
index af422b6..162db69 100644
--- a/Help/command/ctest_test.rst
+++ b/Help/command/ctest_test.rst
@@ -14,6 +14,7 @@ Perform the :ref:`CTest Test Step` as a :ref:`Dashboard Client`.
[EXCLUDE_LABEL <label-exclude-regex>]
[INCLUDE_LABEL <label-include-regex>]
[PARALLEL_LEVEL <level>]
+ [TEST_LOAD <threshold>]
[SCHEDULE_RANDOM <ON|OFF>]
[STOP_TIME <time-of-day>]
[RETURN_VALUE <result-var>]
@@ -61,6 +62,13 @@ The options are:
Specify a positive number representing the number of tests to
be run in parallel.
+``TEST_LOAD <threshold>``
+ While running tests in parallel, try not to start tests when they
+ may cause the CPU load to pass above a given threshold. If not
+ specified the :variable:`CTEST_TEST_LOAD` variable will be checked,
+ and then the ``--test-load`` command-line argument to :manual:`ctest(1)`.
+ See also the ``TestLoad`` setting in the :ref:`CTest Test Step`.
+
``SCHEDULE_RANDOM <ON|OFF>``
Launch tests in a random order. This may be useful for detecting
implicit test dependencies.