Refactor AbstractProver flags#679
Draft
baierd wants to merge 26 commits into
Draft
Conversation
…erforms common checks before delegating to a new implementation method getUnsatCoreImpl() (that is implemented by all solvers that can generate unsat cores)
…rover that performs common checks before delegating to a new implementation method unsatCoreOverAssumptionsImpl() (that is implemented by all solvers) a default impl for unsatCoreOverAssumptionsImpl() is not possible due to javac complaining wrongly in the CI
…ould not be public
…llSatImpl after all common checks. AllSatImpl now handles all AllSat implementations and redundant checks are removed
…hecks and a delegate method that can be implemented by the solvers
…o add_common_impl_for_unsatCore_allSat
…otected for several solvers
…to protected for several solvers
…stractProver + add common checks and flag modification to the implementation of isUnsatWithAssumptions() calling the delegate and add more doc
…twuzlaAbstractProver + rename method that interprets SAT/UNSAT results to better explain what it returns and add JavaDoc
…oolector, CVC4/5, OpenSMT2, Princes and Z3OptimizationProver
…athSAT5, Yices2, Z3 and Z3Legacy + removing the now redundant checks from them
…MTInterpol + adding doc and a FIXME to unsatCoreOverAssumptionsImpl() as it fails to call isUnsat()
…king UNSAT for unsatCoreOverAssumptions() and add more doc to it and isUnsatWithAssumptionsImpl()
…bout what flag to set so that a solver impl is actually used
…mptionsWrapper by moving it (and its subclasses) up 1 package into the same package as AbstractProver + get the nested AbstractProver from other delegates if needed
… a common source that allows always getting the AbstractProver and switch common checks to be in those delegates (the helper delegates, e.g. debug/tracer etc. are not included yet)
…ented by a common source that allows always getting the AbstractProver and switch common checks to be in those delegates (the helper delegates, e.g. debug/tracer etc. are not included yet)" Due to it adding a lot of complexity that we most likely don't need. We will first try to work around this, but maybe come back to this later. This reverts commit 55f0f68.
…WithAssumptionsWrapper by moving it (and its subclasses) up 1 package into the same package as AbstractProver + get the nested AbstractProver from other delegates if needed" Due tthe solution that was worked towards was adding a lot of complexity that we most likely don't need. We will first try to work around this, but maybe come back to this later. This reverts commit bff027d.
…lving notes to AbstractProver
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.
The
AbstractProvertracks the last results of satisfiability queries and whether the prover state was changed since then. This allows us to accurately tell whether model generation, interpolant generation etc. is allowed or not.We tracked this with 2 booleans up until now. This PR proposes to switch to a single variable that is the optional of an enum. If the optional exists, the enum returns the SAT/UNSAT state. If it does not exist, then generating models/interpolants etc. are not allowed, as the state of the prover was changed since the last query returned SAT/UNSAT.
This branch is based on the branch from #674 and should only be merged after it.