From d299e17d43aede8face10bdb6423a0b57c2cf02c Mon Sep 17 00:00:00 2001 From: Massimiliano Culpo Date: Mon, 1 Jul 2024 09:53:24 +0200 Subject: [PATCH] neoverse-v1: restore py-cinemasci (#44976) Use a different tactic for determining conflicts. Give more priority to setting False very old versions. --- lib/spack/spack/solver/asp.py | 2 +- lib/spack/spack/solver/heuristic.lp | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/spack/spack/solver/asp.py b/lib/spack/spack/solver/asp.py index f26a83f9e2..3730bc6e38 100644 --- a/lib/spack/spack/solver/asp.py +++ b/lib/spack/spack/solver/asp.py @@ -95,7 +95,7 @@ def default_clingo_control(): control = clingo().Control() control.configuration.configuration = "tweety" control.configuration.solver.heuristic = "Domain" - control.configuration.solver.opt_strategy = "usc,one" + control.configuration.solver.opt_strategy = "usc,one,1" return control diff --git a/lib/spack/spack/solver/heuristic.lp b/lib/spack/spack/solver/heuristic.lp index 1bace84312..1f31d7eae0 100644 --- a/lib/spack/spack/solver/heuristic.lp +++ b/lib/spack/spack/solver/heuristic.lp @@ -8,12 +8,12 @@ %============================================================================= % No duplicates by default (most of them will be true) -#heuristic attr("node", node(1..X-1, Package)) : max_dupes(Package, X), not virtual(Package), X > 1. [50, false] -#heuristic attr("virtual_node", node(1..X-1, Package)) : max_dupes(Package, X), virtual(Package) , X > 1. [50, false] +#heuristic attr("node", node(1..X-1, Package)) : max_dupes(Package, X), not virtual(Package), X > 1. [100, false] +#heuristic attr("virtual_node", node(1..X-1, Package)) : max_dupes(Package, X), virtual(Package) , X > 1. [100, false] % Pick preferred version #heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, 0 )), attr("node", node(PackageID, Package)). [40, true] -#heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, Weight)), attr("node", node(PackageID, Package)), Weight > 0. [40, false] +#heuristic attr("version", node(PackageID, Package), Version) : pkg_fact(Package, version_declared(Version, Weight)), attr("node", node(PackageID, Package)), Weight > 0. [40+5*Weight, false] #heuristic version_weight(node(PackageID, Package), 0) : pkg_fact(Package, version_declared(Version, 0 )), attr("node", node(PackageID, Package)). [40, true] % Use default variants