summaryrefslogtreecommitdiff
path: root/run_project_tests.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2022-05-06 23:23:27 +0300
committerEli Schwartz <eschwartz93@gmail.com>2022-05-06 16:37:36 -0400
commit3ae36dee42e0152ed24a385fdd6035a391f5322f (patch)
tree113accdd74aaa47aa5792bfe2bbabbcab3acd340 /run_project_tests.py
parent6b7bc608b78f28c0508f6d61f3edbb958708e7d8 (diff)
downloadmeson-3ae36dee42e0152ed24a385fdd6035a391f5322f.tar.gz
Limit parallelism to hopefully work on machines with 160 cores.
Diffstat (limited to 'run_project_tests.py')
-rwxr-xr-xrun_project_tests.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/run_project_tests.py b/run_project_tests.py
index c37d10e17..3e1a4d155 100755
--- a/run_project_tests.py
+++ b/run_project_tests.py
@@ -1543,10 +1543,15 @@ if __name__ == '__main__':
# This fails in some CI environments for unknown reasons.
num_workers = multiprocessing.cpu_count()
except Exception as e:
- print('Could not determine number of CPUs due to the following reason:' + str(e))
+ print('Could not determine number of CPUs due to the following reason:', str(e))
print('Defaulting to using only two processes')
num_workers = 2
+ if num_workers > 64:
+ # Too much parallelism seems to trigger a potential Python bug:
+ # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1004107
+ num_workers = 64
+
parser = argparse.ArgumentParser(description="Run the test suite of Meson.")
parser.add_argument('extra_args', nargs='*',
help='arguments that are passed directly to Meson (remember to have -- before these).')