Skip to content

Try rerunning the solver with --reorder-goals when it reaches the backjump limit. #4776

Open

Description

@sebright

This idea is from #1780 (comment). It is a way to find solutions to more dependency problems in a reasonable amount of time without enabling --reorder-goals by default. --reorder-goals sometimes finds solutions to complex dependency problems more quickly, though it usually slows down simple cases.

cabal could first run the solver without --reorder-goals, but with a backjump limit. If the first run reached the backjump limit, it could run the solver again, with --reorder-goals and a similar backjump limit. This strategy could avoid slowing down the solver in easy cases where the first run finds a solution.

Activity

  1. sebright commented on Nov 8, 2021

    @sebright
    CollaboratorAuthor

    #7784 shows that --reorder-goals can cause major slowdown for each step of dependency solving, which means that limiting the number of backjumps wouldn't be enough to limit runtime during the phase when --reorder-goals is enabled. We shouldn't implement this feature without a better way to limit runtime.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions