solver: account for language preferences on reused specs #51417
Merged
alalazo merged 1 commit intospack:developfrom Oct 13, 2025
Merged
solver: account for language preferences on reused specs #51417alalazo merged 1 commit intospack:developfrom
alalazo merged 1 commit intospack:developfrom
Conversation
Member
Author
|
The performance plot is very similar to #51416 |
Due to performance and modeling reasons, the specs that are
reused in concretization are represented in the ASP problem
with their pure build dependencies trimmed.
On `develop` this means that any preference of the form:
```yaml
packages:
c:
prefer:
- llvm
```
is "disregarded" for purely reused specs, since the solver
is not aware of the compiler nodes used for them.
This PR improves the semantics of virtual preferences so
that they are respected also for reused specs. It does so
without representing their compilers as nodes - so the modeling
of the DAG is not steered towards different optimal solutions
by the missing compilers.
Signed-off-by: Massimiliano Culpo <[email protected]>
836f54c to
df6201e
Compare
2 tasks
haampie
approved these changes
Oct 13, 2025
Member
|
This PR does not apply cleanly to the 1.0 release branch, so it will be dropped from 1.0.3 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

depends on #51416
Due to performance and modeling reasons, the specs that are reused in concretization are represented in the ASP problem with their pure build dependencies trimmed. Since languages are virtual build dependencies this means that on
developpreferences of the form:are disregarded for reused specs.
This PR improves the semantics of virtual preferences so that they are respected also for reused specs. It does so without representing their compilers as nodes - so the modeling of the DAG is not steered towards different optimal solutions by the missing compilers.