3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-15 21:38:44 +00:00
Commit graph

165 commits

Author SHA1 Message Date
Nuno Lopes bb26f219fe remove unneeded constructors (last round) 2020-07-12 17:41:57 +01:00
Nuno Lopes 23e6adcad3 fix a couple hundred deref-after-free bugs due to .c_str() on a temporary string 2020-07-11 20:24:45 +01:00
Hari Govind V K b7d7ff38cb
bug fix. Handle unknown without model (#4443) 2020-05-22 10:12:42 -07:00
Hari Govind V K ed92b8437c
fix #4054 (#4277)
* flag when quantified lemmas are added to smt_context

* When solver returns unknown but cannot create child, return unknown

* handle unknowns when qlemmas and weak_abs are turned on
2020-05-21 09:58:09 -07:00
Hari Govind V K dbfa3dd7f1
[spacer] implement spacer::is_clause() (#4170)
Spacer has a different defintion of is_clause() than ast_util.
It is currently only used in assertions.

Main difference:
  x=y
where x and y are Bool atoms is considered to be an atom, so that
(or (= x y) (not (= z y)))
is a literal

Co-authored-by: Arie Gurfinkel <arie.gurfinkel@uwaterloo.ca>
2020-04-30 14:03:48 -07:00
Nikolaj Bjorner a884201d62 remove using insert_if_not_there2
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-25 15:08:51 -07:00
Nikolaj Bjorner caa5b09046 fix #4050 - have to delay model compression because it may use internal symbols that have to be transformed. model compression is used prior to displaying certificate
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-22 13:33:36 -07:00
Nikolaj Bjorner dd3e574f81 fix #3983
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-16 14:03:06 -07:00
Nikolaj Bjorner f67077b7ff warnings
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-15 17:13:02 -07:00
Lev Nachmanson ec0cd644f1 fix the build
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2020-04-11 12:28:54 -07:00
Arie Gurfinkel 1f6815213d spacer: fail with exception on quantifiers in recursive rules 2020-04-11 14:16:47 -04:00
Arie Gurfinkel 1e96570365 fix #3915 2020-04-11 14:16:29 -04:00
Arie Gurfinkel a261bd94ed silence #3788
better proof generation for the case when the query is reachable from initial
states. This case needs to be handled better so that spacer can assume
the problem is non-trivial.
2020-04-10 15:21:47 -04:00
Nikolaj Bjorner bd59fceaec na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-08 03:48:38 -07:00
Nikolaj Bjorner 8e6bb30c82 cleanup bit2bool from models #3847
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-08 03:06:01 -07:00
Nikolaj Bjorner b66360d0b5 fix #3809
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-07 11:15:34 -07:00
Nikolaj Bjorner e246f6649e tidy
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-05 13:31:48 -07:00
Nikolaj Bjorner b889b110ee bool_vector, some spacer tidy
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-05 12:59:04 -07:00
Nikolaj Bjorner 426e4cc75c fix #3557
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-03 16:37:59 -07:00
Nikolaj Bjorner 896a1b2048 fix #3679
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-04-02 15:04:56 -07:00
Arie Gurfinkel 2ec00cb81d Replace is_null with is_non_empty_string in spacer params 2020-03-31 11:21:05 -04:00
Arie Gurfinkel 6180a5276d
Logging facility for spacer plus minor improvements (#3368)
* [spacer] logging solver events

New option fp.spacer.trace_file='file.log' enables logging solving events
into a file.

These events are useful for debugging the solver, but also for visualizing
the solving process in a variety of ways

* [spacer] allow setting logic for solvers used by spacer

* [spacer] option to set arithmetic solver explicitly

* [spacer] improve of dumping solver_pool state for debugging

* fix propagate_ineqs to handle strict inequality

Co-authored-by: Nham Van Le <nv3le@precious3.eng.uwaterloo.ca>
2020-03-16 20:31:44 -07:00
Nikolaj Bjorner 541658fe02 move to abstract symbols
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-01-10 12:14:13 -08:00
Nikolaj Bjorner b76dee7a7a na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2019-11-06 18:47:06 +01:00
Nikolaj Bjorner 1e0c1cefd6 add definitions for under-specified cases of arithmetic operators #2663 #2676 #2679
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2019-11-06 18:24:22 +01:00
Arie Gurfinkel 1b83c677ea spacer: fixes lim_num_generalizer
Must check that newly constructed generalization blocks
the proof obligation.

Was only checking that generalization is entailed by the transition system!
2019-09-13 14:22:57 +02:00
Arie Gurfinkel 0d3fed9a6a spacer: lemma generalizer for small numbers
Attempts to reduce denominators in coefficients of farkas lemmas
2019-09-09 20:32:13 +02:00
Arie Gurfinkel 375c0ff9a9 Implement get_proof() in bmc and spacer engines 2019-08-12 10:29:01 -07:00
Arie Gurfinkel 92db639caf Use refutation to compute ground sat answer 2019-07-25 15:22:37 -04:00
Nikolaj Bjorner f00697cf95 fix #2155
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2019-03-03 22:33:28 -08:00
Nikolaj Bjorner 26921d1c9c fix #2155
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2019-03-03 22:32:50 -08:00
Bruce Mitchener e570940662 Prefer using empty rather than size comparisons. 2018-11-27 21:42:04 +07:00
Nikolaj Bjorner 72400f1869 fix #1927
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2018-11-12 03:43:04 -08:00
Arie Gurfinkel 6cc6ffcde2 Fix display_certificate in spacer
This is expected to work now
(query q1 :print-certificate true)
2018-11-11 09:06:22 -05:00
Arie Gurfinkel 58d93d8907 Fix add external lemmas to solver even if use_bg_invs=false
spacer.use_bg_invs controls how user-supplied invariants are used.
However, the user expects them to be used independent of the option.
2018-11-11 08:41:22 -05:00
Nikolaj Bjorner d7ecaa2ebb add stub for certificate #1926 2018-11-10 09:56:44 -08:00
Michał Janiszewski cfd0486582 Catch exceptions by const-reference
Exceptions caught by value incur needless cost in C++, most of them can
be caught by const-reference, especially as nearly none are actually
used. This could allow compiler generate a slightly more efficient code.
2018-10-16 19:16:07 +02:00
Bruce Mitchener cdfc19a885 Use nullptr. 2018-10-02 09:11:19 +07:00
Arie Gurfinkel 5d2f682f7a Enable proof mode in add_cover 2018-09-04 21:49:59 -04:00
Arie Gurfinkel 0035d9b8cb Background external invariants
Background external invariants are constraints that are assumed to be
true of the system. This commit introduces a mode in which
background invariants are used only duing inductive generalization
and lemma pushing, but not during predecessor computation.

It is believed that this will be more efficient used of background
external invariants since they will not be able to disturb how
predecessors are generalized and computed.

Based on a patch by Jorge Navas
2018-09-04 21:49:59 -04:00
Arie Gurfinkel 533e9c5837 Expand equality literals when eq_prop is disabled
When equality propagation is disabled for arithmetic,
equality atoms are expanded into inequality for potentially
better generalization with interpolation
2018-09-04 21:49:59 -04:00
Nikolaj Bjorner 84c7df75d6 record statistics setting in config_params so that fp engine can access them, fix serialization bug when check-assumptions returns unsat
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2018-08-06 16:21:27 -07:00
Arie Gurfinkel 6d75c31468 First draft of elim_term_ite xform. Not working. 2018-07-02 17:09:56 -04:00
Arie Gurfinkel 7acea2791d -tr:spacer.expand-add --> -tr:spacer_progress 2018-07-02 17:09:56 -04:00
Arie Gurfinkel 41a05e9d58 Add methods to print pob 2018-06-28 15:38:51 -04:00
Arie Gurfinkel e8e27f0daf Don't simplify bounds when normalizing a lemma 2018-06-28 15:38:50 -04:00
Arie Gurfinkel 0e5434ce0c Debug prints 2018-06-27 22:49:36 -04:00
Arie Gurfinkel 7c924c49f6 Do not evaluate quantified formulas in a model 2018-06-27 22:49:36 -04:00
Arie Gurfinkel 704c19920d Only 10 levels of weakness 2018-06-27 22:49:35 -04:00
Arie Gurfinkel 49e9480928 Fix lemma_as_cti option
Use negation of a lemma as a proof obligation. This speeds up discovering
bad lemmas that do not contain some reachable states.
2018-06-27 22:49:35 -04:00