summaryrefslogtreecommitdiff
path: root/src/theory/quantifiers
AgeCommit message (Collapse)Author
2021-04-14Rename public and private headers in src/include. (#6352)Aina Niemetz
2021-04-14Add internal API methods for pool-based instantiation (#6350)Andrew Reynolds
2021-04-14Merge equivalent sub-obligations instead of discarding them. (#6353)Abdalrhman Mohamed
This PR modifies the behavior of the reconstruction algorithm when the term to reconstruct contains two or more equivalent sub-terms, but one is easier to reconstruct than the others. Since we do not know which one is easier to reconstruct by matching, we match against all sub-terms. If a solution is found for one sub-term, we use it to solve the others.
2021-04-14Warn about infeasible SyGuS conjectures (#6345)Andrew Reynolds
2021-04-13Add pool instantiation strategy (#6308)Andrew Reynolds
Adds an instantiation strategy based on user-provided pool annotations. The next PR will connect this to quantifiers engine.
2021-04-13Avoid using substitute's input cache after the method call. (#6328)Abdalrhman Mohamed
As it traverses a node, Node::substitute populates its input cache with TNodes that are not preserved by the SygusReconstruct module and maybe destroyed after the method call. This PR fixes a bug where those unsafe TNodes are referenced throughout the module by passing the method a temporary copy of the cache instead.
2021-04-12Fix computation of whether a type is finite (#6312)Andrew Reynolds
This PR generalizes TypeNode::isFinite / TypeNode::isInterpretedFinite with TypeNode::getCardinalityClass. It then uses this method to fix our computation of when a type should be treated as finite. Fixes #4260, fixes #6100 (that benchmark now says unknown without an error).
2021-04-12Refactor resource manager (#6322)Gereon Kremer
This PR does another round of refactoring of the resource manager and related code. - it moves the Resource enum out of the ResourceManager class - it treats the resources in a generic way (storing the statistics in a vector) instead of the manual treatment we had before - weights no longer live in the options, but in the ResourceManager and are changed accordingly in the ResourceManager constructor - following the generic treatment of resources, it also removes all the resource-specific options --x-step in favor of a generic --rweight name=weight - removed several unused methods from the ResourceManager Note that we handle the Resource enum in a way that allows to easily use other enums as additional resources, for example InferenceId. The general idea is that we will at some point have sensible default weights (so that the cumulative resources somewhat simulate the solver runtime) and users (almost) never need to modify them.
2021-04-12Refactor and update copyright headers. (#6316)Aina Niemetz
2021-04-09Rename CVC4_ macros to CVC5_. (#6327)Aina Niemetz
2021-04-09Rename CVC4__ header guards to CVC5__. (#6326)Aina Niemetz
2021-04-09Use expr miner timeout (#6321)Andrew Reynolds
We currently were ignoring the option --sygus-expr-miner-timeout=N. This corrects the issue.
2021-04-08Add identifiers for sources of incompleteness (#6311)Andrew Reynolds
This PR classifies all internal kinds of incompleteness as identifiers. It makes it so TheoryEngine records an identifier when its incomplete flag is set. The next step will be to possibly communicate this value to the user.
2021-04-08Initial support for parametric datatypes in sygus (#6304)Andrew Reynolds
Fixes #6298. Enables parsing of par in the sygus parser, and adds support for default grammar construction. Also fixes a bug related to single invocation for non-function types.
2021-04-07Fixes for abducts (#6279)Andrew Reynolds
Fixes benchmarks 2 and 3 from #5848.
2021-04-07Add term pools utility (#6243)Andrew Reynolds
This utility will be used to track pools for pool-based instantiation.
2021-04-07Replace calls to NodeManager::mkSkolem with SkolemManager::mkDummySkolem (#6291)Andrew Reynolds
This is in preparation for refactoring skolem creation throughout the code base to improve proofs and migrate Theory::expandDefinitions to Rewriter::expandDefinitions. This PR also eliminates some unused code in TheoryArithPrivate. Followup PRs will start formalizing/eliminating calls to mkDummySkolem.
2021-04-06Remove template argument from `NodeBuilder` (#6290)Andres Noetzli
Currently, NodeBuilder takes a single template argument: An integer that determines the expected number of arguments. This argument is used to determine the size of the d_inlineNvChildSpace array. This array is used to construct nodes inline. The advantage of this is that we don't have to allocate a NodeValue on the heap for the node under construction until we are sure that the node is new. While templating the array size may save some stack space (or avoid a heap allocation if we statically know that we a fixed number of children and that number is greater than 10), it complicates the code and leads to longer compile times. Thus, this commit removes the template argument and moves some of the NodeBuilder code to a source file for faster compilation. CPU build time before change (debug build): 2429.68s CPU build time after change (debug build): 2228.44s Signed-off-by: Andres Noetzli noetzli@amazon.com
2021-04-05[proof-new] Registering proof checkers uniformly from the SMT solver (#6275)Haniel Barbosa
Each theory has its own proof checker, responsible for checking the rules pertaining to that theory. The main proof checker uses these specialized checkers. Previously the main proof checker (of the proof node manager used across the SMT solver) was connected to these theory proof checkers during initialization of the theory. This commit adds an interface to the theories for retrieving its proof checker (analogous to how one retrieves the rewriter of a theory) which is used by a new method in the theory engine to register a theory proof checker to a given proof checker according to a theory id. This is in preparation for the new unsat cores based on proofs.
2021-04-01Rename namespace CVC5 to cvc5. (#6258)Aina Niemetz
2021-03-31Rename namespace CVC4 to CVC5. (#6249)Aina Niemetz
2021-03-31Eliminate dependencies on quantifiers engine in internal quantifiers code ↵Andrew Reynolds
(#6240) This completes eliminating dependencies on quantifiers engine from internal quantifiers code. It eliminates quantifiers_engine.h as an include from src/theory/quantifiers/ apart from theory_quantifiers.cpp where it is owned. Followup PRs will further eliminate circular dependencies that arose will refactoring quantifiers engine.
2021-03-31Add missing inference ids (#6242)Andrew Reynolds
Towards having complete stats on inference ids for each lemma, fact, and conflict.
2021-03-30Implement simple tracking of instantiation lemmas (#6077)Andrew Reynolds
We require tracking of instantiation lemmas for quantifier elimination. Recently, this feature was removed in favor of reconstructing instantiations via substitutions. This does not quite work if instantiation lemmas have more complex post-processing, e.g. virtual term substitution. This PR reimplements a much simpler form of instantiation tracking that simply adds instantiation bodies to a vector, per quantified formula. It uses this vector for quantifier elimination. Fixes #5899.
2021-03-30Refactoring quantifier annotation kinds, add kinds in preparation for ↵Andrew Reynolds
pool-based instantiation (#6234) This is in preparation for a new pool-based instantiation technique.
2021-03-30Miscellaneous elimination of dependencies on quantifiers engine (#6238)Andrew Reynolds
This should be the last PR before quantifiers engine will not be passed to quantifiers modules.
2021-03-29Eliminate the use of quantifiers engine in sygus solver (#6232)Andrew Reynolds
2021-03-29Eliminate use of quantifiers engine in enumerative instantiation (#6217)Andrew Reynolds
This also makes minor updates to how term tuple enumerators are constructed.
2021-03-29Move decision manager into theory inference manager (#6231)Andrew Reynolds
This makes it so that the decision manager is accessible from TheoryInferenceManager. This is work towards breaking circular dependencies in quantifiers, and also helps simplify several other dependencies in e.g. UF and datatypes.
2021-03-26Pass term registry to quantifiers modules (#6216)Andrew Reynolds
2021-03-25Refactor construction of triggers (#6209)Andrew Reynolds
This PR centralizes our utilities for generating triggers. It also splits the statistics class from quantifiers off from quantifiers engine.
2021-03-25Add missing includes. (#6207)Gereon Kremer
This PR adds includes that are missing from source files, but currently provided by other includes. This mostly concerns <sstream> which is currently included by the statistics, which will change in the future.
2021-03-24Use inference manager to access intantiate utility instead of quantifiers ↵Andrew Reynolds
engine (#6198) Towards breaking dependencies on quantifers engine.
2021-03-23Passing term registry to ematching utilities (#6190)Andrew Reynolds
Model is now nested into term registry. This PR also resolves some complications due to namespaces within quantifiers.
2021-03-23Remove internal includes of Api header. (#6193)Aina Niemetz
2021-03-23Replace old sygus term reconstruction algorithm with a new one. (#5779)Abdalrhman Mohamed
This PR replaces the old algorithm for reconstructing sygus terms with a new "proper" implementation.
2021-03-23Moving instantiate and skolemize into quantifiers inference manager (#6188)Andrew Reynolds
After this PR, utilities for instantiation are available from the quantifiers inference manager instead of quantifiers engine. This means that the majority of the dependencies on quantifiers engine will (finally) start being cleaned up after this PR.
2021-03-22Move equality query utility into quantifiers model (#6186)Andrew Reynolds
This simplifies the initialization of quantifiers engine. This PR also makes general improvements to EqualityQuery.
2021-03-19Refactor initialization of quantifiers model and builder (#6175)Andrew Reynolds
This is in preparation for breaking several circular dependencies and moving the instantiate utility into the theory inference manager.
2021-03-18Eliminate dependency on quantifiers engine in quantifiers model (#6165)Andrew Reynolds
2021-03-17Move utilities for inferred bounds on quantifers to own class (#6159)Andrew Reynolds
This also moves some methods from TermEnumeration to QuantifiersBoundInference. This is required for breaking several cyclic dependencies within quantifiers.
2021-03-15Split inst match generator class to own file (#6125)Andrew Reynolds
2021-03-15Reorganizing initialization of term registry in quantifiers (#6127)Andrew Reynolds
This is in preparation for moving several utilities into the quantifiers inference manager. This PR moves ownership of TermRegistry and QuantifiersRegistry to TheoryQuantifiers from QuantifiersEngine.
2021-03-11Simplify instantiation match generator interface (#6121)Andrew Reynolds
2021-03-11Introduce inference ids for quantifier instantiation (#6119)Andrew Reynolds
This makes quantifiers use standard inference ids. This eliminates the need to track ad-hoc statistics, per instantiation type. This makes minor modifications to a few interfaces in quantifiers to enable this.
2021-03-11First refactoring of statistics classes (#6105)Gereon Kremer
This PR does a first round of refactoring on the statistics, in particular the Stat class and derived classes. It significantly shrinks the class hierarchy, modernizes some code (e.g. use std::chrono instead of clock_gettime), removes unused features (e.g. nesting of statistics) and does some general cleanup and consolidation. Subsequent PRs are planned to change the ownership model (right now every module owns the Stat object) which makes the whole register / unregister mechanism obsolete.
2021-03-11Delete Expr layer. (#6117)Aina Niemetz
2021-03-11Improvements and refactoring for enumeratative strategy (#6030)MikolasJanota
Refactoring out the code from `inst_strategy_enumerative` into a separate class. Some additional tricks to avoid duplicate instantiations, most notably, before instantiation, a tuple is checked if it's not a super-tuple of some tuple that had earlier resulted in a useless instantiation. Signed-off-by: mikolas <mikolas.janota@gmail.com>
2021-03-10Move ExprManager::isNAryKind to NodeManager. (#6107)Aina Niemetz
This also renames metakind::getLowerBoundForKind and metakind::getUpperBoundForKind for consistency. Note that the NodeManager class needs to be reordered to comply to our style guidelines. This PR does not reorder but introduces a public block at the top (where the rest of the public interface of the class should go eventually).
2021-03-10(proof-new) Replace witness form by original form in the internal proof ↵Andrew Reynolds
calculus (#6051) This makes a simplification to the internal proof calculus. In particular, purification skolems are no longer are special case of witness skolems. They are now independent concepts. The concept of "witness form" is replaced in most places by "original form". This is required for fixing two issues: (1) variable shadowing issues in skolemization. (2) bookkeeping issues for bound variables introduced to construct witness terms. This made the LFSC proof conversion extremely cumbersome for e.g. string reductions. In this PR, the main changes: The internals of SkolemManager are changed to use original form vs witness form when necessary. This eliminates the need to do variable renaming in SkolemManager::skolemize. the rule WITNESS_INTRO is replaced by SKOLEM_INTRO MACRO_SR_* rules use original form Proof post processing is simplified These changes imply that ppRewrite should not return WITNESS terms. Followup PRs will modify arithmetic preprocessing so that its ppRewrite method returns skolems instead.
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback