summaryrefslogtreecommitdiff
path: root/etc
diff options
context:
space:
mode:
authorMassimiliano Culpo <massimiliano.culpo@gmail.com>2024-11-19 15:00:26 +0100
committerGitHub <noreply@github.com>2024-11-19 15:00:26 +0100
commit68aa712a3e51b2fb8596ba245dd440739be205c5 (patch)
tree509df7b21b3d4c55fd3c6fad5a4e210bdeb457c0 /etc
parent2e71bc640c1ccc273b7bc71f5791316ec1832157 (diff)
downloadspack-68aa712a3e51b2fb8596ba245dd440739be205c5.tar.gz
spack-68aa712a3e51b2fb8596ba245dd440739be205c5.tar.bz2
spack-68aa712a3e51b2fb8596ba245dd440739be205c5.tar.xz
spack-68aa712a3e51b2fb8596ba245dd440739be205c5.zip
solver: add a timeout handle for users (#47661)
This PR adds a configuration setting to allow setting time limits for concretization. For backward compatibility, the default is to set no time limit.
Diffstat (limited to 'etc')
-rw-r--r--etc/spack/defaults/concretizer.yaml8
1 files changed, 8 insertions, 0 deletions
diff --git a/etc/spack/defaults/concretizer.yaml b/etc/spack/defaults/concretizer.yaml
index 8cce19ebab..eda51c09be 100644
--- a/etc/spack/defaults/concretizer.yaml
+++ b/etc/spack/defaults/concretizer.yaml
@@ -55,3 +55,11 @@ concretizer:
splice:
explicit: []
automatic: false
+ # Maximum time, in seconds, allowed for the 'solve' phase. If set to 0, there is no time limit.
+ timeout: 0
+ # If set to true, exceeding the timeout will always result in a concretization error. If false,
+ # the best (suboptimal) model computed before the timeout is used.
+ #
+ # Setting this to false yields unreproducible results, so we advise to use that value only
+ # for debugging purposes (e.g. check which constraints can help Spack concretize faster).
+ error_on_timeout: true