Sema: Record the trail step count in solver statistics

Also introduce two new frontend flags:

The -solver-scope-threshold flag sets the maximum number of scopes, which was
previously hardcoded to 1 million.

The -solver-trail-threshold flag sets the maximum number of trail steps,
which defaults to 64 million.
This commit is contained in:
Slava Pestov
2024-11-19 12:30:07 -05:00
parent a7b1e7854c
commit c8415aeac4
10 changed files with 108 additions and 54 deletions

View File

@@ -1777,6 +1777,10 @@ static bool ParseTypeCheckerArgs(TypeCheckerOptions &Opts, ArgList &Args,
Opts.DebugConstraintSolverAttempt);
setUnsignedIntegerArgument(OPT_solver_memory_threshold,
Opts.SolverMemoryThreshold);
setUnsignedIntegerArgument(OPT_solver_scope_threshold_EQ,
Opts.SolverScopeThreshold);
setUnsignedIntegerArgument(OPT_solver_trail_threshold_EQ,
Opts.SolverTrailThreshold);
setUnsignedIntegerArgument(OPT_solver_shrink_unsolved_threshold,
Opts.SolverShrinkUnsolvedThreshold);