summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-03-09Rename sygus option name (#3977)Andrew Reynolds
This option enables the sygus solver (previous name was ceGuidedInst, deprecated from CAV 15 specific approach). It also improves when this option is set. In particular we ensure it is enabled when sygus is enabled for any reason.
2020-03-09Remove instantiation propagator infrastructure (#3975)Andrew Reynolds
2020-03-09Ensure standard miniscoping is applied before aggressive miniscoping (#3974)Andrew Reynolds
Fixes #3947.
2020-03-09Eliminate spurious assertion (#3976)Andrew Reynolds
2020-03-09DecisionEngine: Use unique_ptr for enabled strategies. (#3984)Aina Niemetz
2020-03-09Fix type issue in arith rewrite equality (#3972)Andrew Reynolds
Fixes #3952 and fixes #3940 and fixes #3941 and fixes #3968.
2020-03-09Make registration of unit clauses more robust (#3965)Andres Noetzli
Fixes #3959. It can happen that we generate a lemma that results in a unit clause that matches a unit clause that was added as an input. However, we are asserting that a unit clause can only be registered as either one of them. This commit fixes the issue by only registering a unit clause from a lemma if it is not already satisfied. I chose this fix because the existing code doesn't seem to do anything (in terms of solving) for the case where we have a unit clause that is already satisfied because of an input unit clause.
2020-03-09Increase stack size for Windows builds to 100 MB (#3943)Andres Noetzli
Fixes #3528. The default stack size for Windows builds is very limited (it seems to be 1 MB). This leads to problems for some of our users' benchmarks (see the previously mentioned issue and another email that we've received recently). Bumping the stack size to 100 MB seems to solve the issues for the benchmarks that we have received. This of course does not mean that we shouldn't continue working towards making less of our code recursive.
2020-03-09Clean up more uses of ExprManager in parsers (#3932)Andrew Reynolds
Towards parser migration. Beyond Datatypes, there are still a handful of calls to the ExprManager in the parsers. This eliminates a few missing cases from TPTP and also inlines the access of ExprManager in the places its used.
2020-03-09Convert more uses of strings to words (#3921)Andrew Reynolds
Towards theory of sequences. Also adds documentation to strncmp/rstrncmp and adds them to the Word interface.
2020-03-09Fix quoting of options on Travis (#3981)Andres Noetzli
For some reason, Travis has started to treat our `TRAVIS_CVC4_CONFIG` environment variable wrong, leading to failing builds. Travis started to wrap the argument into double quotes, so when we had single quotes around our argument list, the arguments were treated as a single argument and when we had double quotes, the second pair of double quotes terminated the first one permaturely. Declaring the environment variables individually seems to work as expected, so this commit is moving to that format.
2020-03-09Fixes for bounds on transcendental functions (#3832)Andrew Reynolds
This PR refactors and fixes how bounds are set for transcendental functions. The new code ensures that all transcendental function applications are given bounds. (Our previous failures to do so were hindering our ability to say "sat", due to NlModel::checkModel failures). There were previously two issues on why transcendental function applications were not being assigned bounds: "Slave" transcendental functions (e.g. those that we reduce via sin(t) = sin(y) ^ -pi <= y <= pi ^ y + 2*pi*N = t) were not being given bounds explicitly, Transcendental functions that are congruent to others (e.g. f(x) where f(y) exists and x=y in the current context) were being ignored and hence not bound. This PR clarifies the master/slave relationship that tracks which transcendental function applications have been purified, and furthermore tracks congruence classes. The setting of bounds and the check-model is further simplified by setting bounds on the original terms, whereas the current code sets bounds on the model values of terms. In other words, previously if we had term sin(y) and y^M = c, then we'd set bounds for sin(c), whereas the new code sets the bound on sin(y) directly. Fixes #3783. We answer unknown without an assertion failure on that benchmark now. Further work based on ignoring literals from internally generated lemmas is necessary for solving it sat.
2020-03-08Rewrite again full for DIV rewrite (#3945)Andrew Reynolds
Fixes #3944.
2020-03-07Explicit end marker for models printed in the CVC language (#3934)Ying Sheng
Fixes https://github.com/CVC4/cvc4-wishues/issues/9. When communicating with CVC4 using pipes and the CVC language, it was not possible to determine when all the lines of a model have been printed. This change adds begin and end markers as the example below: ``` MODEL BEGIN x : INT = -3; y : INT = 0; z : INT = 0; MODEL END; ```
2020-03-06Minor refactor for theory of sets (#3924)Andrew Reynolds
Flattens a block of code and refactors the main check loop, will make it easier to incorporate new extensions. It also avoids a needless call to check() for Relations when there are no relations constraints.
2020-03-06Simplify DatatypeDeclarationCommand command (#3928)Andrew Reynolds
The new API does not use inheritence for Sorts. The current DatatypeDeclarationCommand uses DatatypeType, which inherits from Type. This commit simplifies the class DatatypeType -> Type and updates the necessary code (e.g. in the printers). Notice we are not yet converting commands Type -> Sort here. It also makes the main call for constructing datatypes in the parser from DatatypeType -> api::Sort. This is in preparation for converting Expr-level Datatype to Term-level DatatypeDecl in the parsers.
2020-03-06Remove tester name from APIs (#3929)Andrew Reynolds
This removes the field "tester name" from the Expr-level and Term-level APIs. This field is an artifact of parsing and thus should be handled in the parsers. This refactor uncovered an issue in our regressions, namely our smt version >= 2.6 was not strictly complaint, since the symbol is-cons was being automatically defined for testers of constructors cons. This disables this behavior when strict mode is enabled. It updates the regressions with this issue. This is work towards parser migration.
2020-03-06Ignore model check warning in regression test (#3926)Andres Noetzli
PR #3918 added a new test case that results in a warning when checking models, which makes the regression fail. This commit adds a flag to the test to ignore that warning.
2020-03-06Make sygus datatype building independent of parser in sygus v2 (#3923)Andrew Reynolds
The current sygus v2 called the parser's mkMututalDatatypeTypes function, which unecessarily created the datatype and bound its (internally generated) constructor/selector symbols in the symbol tables of the parser. This resolves this dependency. The same issue also exists in the sygus v1 parser but is harder to resolve; I am leaving this for now since that code will be deleted in the next version of CVC4. This is work towards the SyGuS API.
2020-03-06Support default sygus grammar construction for sets (#3842)Andrew Reynolds
Fixes #3645.
2020-03-05Make output of regression script more readable (#3911)Andres Noetzli
The output of the regression script was difficult to read (especially the diffs). This commit makes the output more readable by adding colors, separators, and using a unified diff.
2020-03-05Remove --apply-to-const preprocessing pass (#3919)Andres Noetzli
Fixes #3914. The pass was only applicable to inputs with UFs that were exclusively applied to single integer values. This limitation seems to make the preprocessing pass not very useful in practice and it is subsumed by our Ackermannization pass, which can remove UFs from more complex inputs. Thus, this commit removes the preprocessing pass.
2020-03-05Add a new arith constraint proof rule: IntTightenAP (#3818)Alex Ozdemir
This rule is used when a bound on an integer expression is tightened because of integer reasoning. Before this rule was subsumed by IntHoleAP, a catch-all rule for integer reasoning. We are now articulating IntTightenAP separately, because we can produce proofs for it. For IntHoleAP, we will have to omit a hole.
2020-03-05Revert "Add a new arith constraint proof rule: IntTightenAP (#3818)"Alex Ozdemir
This reverts commit c360b3af4371cf871935a8bae96be5f8fecf741b.
2020-03-05Add a new arith constraint proof rule: IntTightenAP (#3818)Andres Noetzli
This rule is used when a bound on an integer expression is tightened because of integer reasoning. Before this rule was subsumed by IntHoleAP, a catch-all rule for integer reasoning. We are now articulating IntTightenAP separately, because we can produce proofs for it. For IntHoleAP, we will have to omit a hole.
2020-03-05Migrate a majority of the functionality in parsers to the new API (#3838)Andrew Reynolds
This PR migrates a majority of the functionality of the parsers (cvc, tptp, smt2/sygus) to the new API. The main omitted functionality not addressed in this PR is the datatypes. Largely, the Expr-level Datatype is still used throughout. Remaining tasks: Migrate the Datatypes to the new API in cvc/smt2. Eliminate the use of ExprManager::mkVar (with flags for DEFINED/GLOBAL). For the latter, I have made a utility function in Parser::mkVar that captures all calls to this function. Notice that the existing mkVar/mkBoundVar/mkDefinedFun have been renamed to the more fitting names bindVar/bindBoundVar/bindDefinedFun etc. Note: this PR contains no major code changes, each line of code should roughly correspond one-to-one with the changed version. This fixes CVC4/cvc4-projects#77, fixes CVC4/cvc4-projects#78, fixes CVC4/cvc4-projects#80, fixes CVC4/cvc4-projects#85.
2020-03-05Move ownership of DecisionEngine into PropEngine. (#3850)Aina Niemetz
This is in preparation of fixing the issue we currently have with reset-assertions. This also removes a competition hack for QF_LRA.
2020-03-05Revert "Move ownership of DecisionEngine into PropEngine. (#3850)"Aina Niemetz
This reverts commit bbba915f44f9e75eaa6238a10ba667643dacb00b.
2020-03-05Move ownership of DecisionEngine into PropEngine. (#3850)Andrew Reynolds
This is in preparation of fixing the issue we currently have with reset-assertions. This also removes a competition hack for QF_LRA.
2020-03-05Fix issues with real to int (#3918)Andrew Reynolds
This fixes a few issues in the real to int preprocessing pass. Previously it was not robust to cases where the input had constraints that were not over the reals. Fixes #3915 and fixes #3913 and fixes #3916.
2020-03-05Enable -Wshadow and fix warnings. (#3909)Mathias Preiner
Fixes all -Wshadow warnings and enables the -Wshadow compile flag globally. Co-authored-by: Clark Barrett <barrett@cs.stanford.edu> Co-authored-by: Andres Noetzli <andres.noetzli@gmail.com> Co-authored-by: Aina Niemetz <aina.niemetz@gmail.com> Co-authored-by: Alex Ozdemir <aozdemir@hmc.edu> Co-authored-by: makaimann <makaim@stanford.edu> Co-authored-by: yoni206 <yoni206@users.noreply.github.com> Co-authored-by: Andrew Reynolds <andrew.j.reynolds@gmail.com> Co-authored-by: AleksandarZeljic <zeljic@stanford.edu> Co-authored-by: Caleb Donovick <cdonovick@users.noreply.github.com> Co-authored-by: Amalee <amaleewilson@gmail.com> Co-authored-by: Scott Kovach <dskovach@gmail.com> Co-authored-by: ntsis <nekuna@gmail.com>
2020-03-03Refactoring and cleaning the type enumerator for sets (#3908)mudathirmahgoub
* Miscellaneous changes * Removed unnecessary vector of enumerators * cleanup * cleanup * cleanup * refactoring * cleanup * refactoring * used binary numbers for sets * isFinished for enumerator * format * added theory_sets_type_enumerator_white.h * format * Used BitVector class * Tracing * Documentation * moved implementation to theory_sets_type_enumerator.cpp * minor changes
2020-03-03Standardize the interface for SMT engine subsolvers (#3836)Andrew Reynolds
This standardizes the interface for using SMT engines as subsolvers in various approaches. More refactoring is possible, but this is an initial cut at cleaning things up. This will make it easy to accommodate new feature request for SyGuS (timeouts for calls to verification steps). Notice this also required adding a missing function (mkGroundTerm/isWellFounded for functions) which was caught after standardizing due to an optimization (don't create SmtEngines to check satisfiability of constant Booleans).
2020-03-02Fix `TheorySetsPrive::eqNotifyPostMerge()` (#3901)Andres Noetzli
A local declaration of `s1` was shadowing `s1`, which meant that the non-local definition of `s1` could never be not null. This meant that parts of the code were never run. This commit fixes the issue by removing the local declaration.
2020-03-02Fix variable shadowing bug in sets. (#3898)Mathias Preiner
2020-03-02 Split collect model info by types in strings (#3847)Andrew Reynolds
Towards a theory of sequences. We will need to do similar splits per type for most of the functions throughout strings.
2020-02-29Convert more uses of string to word (#3834)Andrew Reynolds
2020-02-29 Throw warning instead of error for non-constant values in check-model ↵Andrew Reynolds
stages (#3844) Fixes #3729 and fixes #3720. This updates two more stages of check-model (checking whether values assigned to terms are constants and internally checking whether assertions belonging to theories) to only throw warnings when a term/assertion has a non-constant value in the model. This is to accommodate cases where check-model is infeasible.
2020-02-28Add support for str.from_code (#3829)Andres Noetzli
This commit adds support for `str.from_code`. This is work towards supporting the new strings standard. The code currently just does an eager expansion of the operator. The commit also renames `STRING_CODE` to `STRING_TO_CODE` to better reflect the names of the operators in the new standard.
2020-02-28propEngine: Reorder class declaration according to code style guidelines. ↵Aina Niemetz
(#3846)
2020-02-28Fix assertion related to assignability in the model. (#3843)Andrew Reynolds
Fixes #3813. It appears that an assertion was hardcoded to check whether a term was a variable or APPLY_UF application whereas this check should use isAssignable. This avoids an assertion failure on the given benchmark.
2020-02-28Replace conditional rewrite pass in quantifiers with the extended rewriter ↵Andrew Reynolds
(#3841) Fixes #3839. Previously, the quantifiers rewriter had a rewriting step that was an ad-hoc version of some of the rewrites that have been incorporated into the extended rewriter. Moreover, the code for that pass was buggy. This eliminates the previous conditional rewriting step from the "term process" rewrite pass in quantifiers. It additional adds an optional (disabled by default) rewriting pass that calls the extended rewriter on the body of quantified formulas. This subsumes the previous behavior and should not be buggy. Notice that the indentation in computeProcessTerms changed and subsequently has been updated to the new coding standards. This PR relies on #3840.
2020-02-28Use enum for quantifiers rewrite steps (#3840)Andrew Reynolds
Makes trace messages easier to understand.
2020-02-27Refactor operator applications in the parser (#3831)Andrew Reynolds
This PR refactors how a term is constructed based on information regarding an operator (ParseOp) and its arguments. It also makes a few miscellaneous fixes. This includes: Indexed ops are carried in ParseOp via api::Op not Expr, getKindForFunction is limited to "APPLY" kinds from the new API, The TPTP/SMT2 parsers rely on mkTermInternal for handling associativity. TPTP should use DIVISION not DIVISION_TOTAL. This is in preparation for parser migration. These are the essential behavioral changes required for using the new API for the majority of the parser.
2020-02-27Changing TPTP parser to accomodate new API (#3837)Haniel Barbosa
Removing dependency of kinds corresponding to expressions.
2020-02-27Update purifySygusGTerm to the new API (#3830)Andrew Reynolds
Towards parser migration. (Partially) updates the central function used for synth-fun in sygus v2 to the new API. It also removes an optimization for "pure operators" from the v2 parser that is incompatible with the new API.
2020-02-27Fix large models for strings (#3835)Andrew Reynolds
Fixes #3375. Marking as "major" since in fact we produce incorrect models in production without the fix.
2020-02-27Fix -Wshadow warnings in common headers (#3826)Andres Noetzli
2020-02-26Add support for is_digit and regular expression difference (#3828)Andrew Reynolds
Towards support for the strings standard. This adds support for str.is_digit and re.diff, which both can be eliminated eager during preprocessing.
2020-02-26Disable regression that times out on debug (#3833)Andrew Reynolds
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback