3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-18 22:59:02 +00:00
Commit graph

1515 commits

Author SHA1 Message Date
Nikolaj Bjorner 4d41db3028 adding euf
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-31 14:36:16 -07:00
Nikolaj Bjorner 4244ce4aad adding ack/model
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-28 12:55:47 -07:00
Nuno Lopes a7b51d04cd remove unused file 2020-08-25 15:10:41 +01:00
Arie Gurfinkel 22b5daf85e
fix rlimit for clang-10 (#4658) 2020-08-21 10:34:10 -07:00
Nikolaj Bjorner ecb43ccca2 update smt logging format to follow SAT solver
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-20 20:00:20 -07:00
Nikolaj Bjorner 2611484525 fix #4642
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-17 08:35:15 -07:00
Nikolaj Bjorner f0308436b5 use lazy scopes to avoid push/pop overhead
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-17 08:07:06 -07:00
Caleb Stanford 2c02264a94
Regex solver updates (#4636)
* std::cout debugging statements

* comment out std::cout debugging as this is now a shared fork

* convert std::cout to TRACE statements for seq_rewriter and seq_regex

* add cases to min_length and max_length for regexes

* bug fix

* update min_length and max_length functions for REs

* initial pass on simplifying derivative normal forms by eliminating redundant predicates locally

* add seq_regex_brief trace statements

* working on debugging ref count issue

* fix ref count bug and convert trace statements to seq_regex_brief

* add compact tracing for cache hits/misses

* seq_regex fix cache hit/miss tracing and wrapper around is_nullable

* minor

* label and disable more experimental changes for testing

* minor documentation / tracing

* a few more @EXP annotations

* dead state elimination skeleton code

* progress on dead state elimination

* more progress on dead state elimination

* refactor dead state class to separate self-contained state_graph class

* finish factoring state_graph to only work with unsigned values, and implement separate functionality for expr* logic

* implement get_all_derivatives, add debug tracing

* trace statements for debugging is_nullable loop bug

* fix is_nullable loop bug

* comment out local nullable change and mark experimental

* pretty printing for state_graph

* rewrite state graph to remove the fragile assumption that all edges from a state are added at a time

* start of general cycle detection check + fix some comments

* implement full cycle detection procedure

* normalize derivative conditions to form 'ele <= a'

* order derivative conditions by character code

* fix confusing names m_to and m_from

* assign increasing state IDs from 1 instead of using get_id on AST node

* remove elim_condition call in get_dall_derivatives

* use u_map instead of uint_map to avoid memory leak

* remove unnecessary call to is_ground

* debugging

* small improvements to seq_regex_brief tracing

* fix bug on evil2 example

* save work

* new propagate code

* work in progress on using same seq sort for deriv calls

* avoid re-computing derivatives: use same head var for every derivative call

* use min_length on regexes to prune search

* simple implementation of can_be_in_cycle using rank function idea

* add a disabled experimental change

* minor cleanup comments, etc.

* seq_rewriter cleanup for PR

* typo noticed by Nikolaj

* move state graph to util/state_graph

* re-add accidentally removed line

* clean up seq_regex code removing obsolete functions and comments

* a few more cleanup items

* oops, missed merge change to fix compilation

* disabled change to lift unions to the top level and treat them seperately in seq_regex solver

* added get_overapprox_regex to over-approximate regex membership constraints

* replace calls to is_epsilon with a centrally available method in seq_decl_plugin

* simplifications and modifications in get_overapprox_regex and related

* added approximation support for sequence expressions that use ite

* removed is_app check that was redundant

* tweak differences with upstream

* rewrite derivative leaves

* enable Antimorov-style derivatives via lifting unions in the solver

* TODO placeholders for outputting state graph

* change order in seq_regex propagate_in_re

* implement a more restricted form of Antimorov derivatives via a special op code to indicate lifting unions

* minor

* new Antimorov optimizations based on BDD compatibility checking

* seq regex tracing for # of derivatives

* fix get_cofactors (currently this fix is buggy)

* partially revert get_cofactors buggy change

* re-implement get_cofactors to more efficiently explore nodes in the derivative expression

* dgml generation for state graph

* fix release build

* improved dgml output

* bug fixes in dgml generation

* dot output support for state_graph and moved dgml and dot output under CASSERT

* updated tracing of what regex corresponds to what state id with /tr:state_graph

* clean up & document Antimorov derivative support

* remove op cache tracing

* remove re_rank experimental idea

* small fix

* fix Antimorov derivative (important change for the good performance)

* remove unused and unnecessary code

* implemented simpler efficient get_cofactors alternative mk_deriv_accept

* simplifications in propagate_accept, and trace unusual cases

* document the various seq_regex tracing & debugging command-line options

* fix debug build (broken tracing)

* guard eager Antimorov lifting for possible disabling

* fix bug in propagate_accept Rule 1

* disable eager version of Antimorov lifting for performance reasons

* remove some remaining obsolete comments

Co-authored-by: calebstanford-msr <t-casta@microsoft.com>
Co-authored-by: Margus Veanes <margus@microsoft.com>
2020-08-13 12:47:36 -07:00
Nikolaj Bjorner c63ad2e834 enable ranges for bit-vectors
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-08-13 10:53:37 -07:00
Margus Veanes e5693b8a98
added support for saving state graph in dot format (#4621)
* added support for saving state graph in dot format

* moved write_dgml and write_dot under CASSERT

* updated dgml and dot generation a bit so that a state that is both and alive state is detected as having green background but red border when the invariant is vioalted
2020-08-09 14:53:29 -07:00
Rocco Salvia 3852d4516d
modular Axiom Profiler (#4619)
* Rocco first commit

* Rocco: clean the log

* Rocco: version 0.1 beta of the causality graph

* Rocco: minimal fix to separate lines

* Rocco: fix the enodes

* Rocco: our trace has to reflect same behaviour of the native trace for what concern used_enodes

* Rocco: disable trace when dummy instantiations

* Rocco: fix to enodes

* Update README.md

* Rocco: remove causality details and add the pattern (trigger)

* Rocco: add ; at the end of the bindings

* Rocco: add triggers as separate trace

* Rocco README file

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Rocco: bug in tout flush

* Update README.md

* Update README.md

* Rocco: clean code

* Ready for pull request

* Remove commented line bindings

* Add space between // and first char

* Substitute or with || for compatibility; Add space around >
2020-08-08 12:09:24 -07:00
Margus Veanes 934f87a336
dgml output generation for regex state graphs (#4620)
* dgml output generation for regex state graphs

* fixed issue in header file
2020-08-08 09:40:20 -07:00
Caleb Stanford 976e4c91b0
Integrate new regex solver (#4602)
* std::cout debugging statements

* comment out std::cout debugging as this is now a shared fork

* convert std::cout to TRACE statements for seq_rewriter and seq_regex

* add cases to min_length and max_length for regexes

* bug fix

* update min_length and max_length functions for REs

* initial pass on simplifying derivative normal forms by eliminating redundant predicates locally

* add seq_regex_brief trace statements

* working on debugging ref count issue

* fix ref count bug and convert trace statements to seq_regex_brief

* add compact tracing for cache hits/misses

* seq_regex fix cache hit/miss tracing and wrapper around is_nullable

* minor

* label and disable more experimental changes for testing

* minor documentation / tracing

* a few more @EXP annotations

* dead state elimination skeleton code

* progress on dead state elimination

* more progress on dead state elimination

* refactor dead state class to separate self-contained state_graph class

* finish factoring state_graph to only work with unsigned values, and implement separate functionality for expr* logic

* implement get_all_derivatives, add debug tracing

* trace statements for debugging is_nullable loop bug

* fix is_nullable loop bug

* comment out local nullable change and mark experimental

* pretty printing for state_graph

* rewrite state graph to remove the fragile assumption that all edges from a state are added at a time

* start of general cycle detection check + fix some comments

* implement full cycle detection procedure

* normalize derivative conditions to form 'ele <= a'

* order derivative conditions by character code

* fix confusing names m_to and m_from

* assign increasing state IDs from 1 instead of using get_id on AST node

* remove elim_condition call in get_dall_derivatives

* use u_map instead of uint_map to avoid memory leak

* remove unnecessary call to is_ground

* debugging

* small improvements to seq_regex_brief tracing

* fix bug on evil2 example

* save work

* new propagate code

* work in progress on using same seq sort for deriv calls

* avoid re-computing derivatives: use same head var for every derivative call

* use min_length on regexes to prune search

* simple implementation of can_be_in_cycle using rank function idea

* add a disabled experimental change

* minor cleanup comments, etc.

* seq_rewriter cleanup for PR

* typo noticed by Nikolaj

* move state graph to util/state_graph

* re-add accidentally removed line

* clean up seq_regex code removing obsolete functions and comments

* a few more cleanup items

* remove experimental functionality for integration

* fix compilation

* remove some tracing and TODOs

* remove old comment

* update copyright dates to 2020

* feedback from Nikolaj

* use [] for map access

* make state_graph methods constant

* avoid recursion in mark_dead_recursive and mark_live_recursive

* a possible bug fix in propagate_nonempty

* write down list of invariants in state_graph

* implement partial invariant check and insert CASSERT statements

* expand on invariant check and tracing

* finish state graph invariant check

* minor tweaks

* regex propagation: convert first two axioms to propagations

* remove obsolete regex solver functionality

Co-authored-by: calebstanford-msr <t-casta@microsoft.com>
2020-07-30 13:54:49 -07:00
Nikolaj Bjorner c7704ef9af pass algebraic manager to arith-plugin mk-numeral because rational check may overwrite the argument using the current manager deals with crash as part of #4532
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-26 17:52:28 -07:00
Nikolaj Bjorner 105f97d3ee #4582 again 2020-07-25 15:12:25 -07:00
Nikolaj Bjorner 2d4839f89e #4582 again 2020-07-25 15:09:30 -07:00
Nikolaj Bjorner 1059f6d3b8 #4582 again 2020-07-25 11:54:05 -07:00
Nikolaj Bjorner 963daab268 #4582 again 2020-07-25 11:18:20 -07:00
Nikolaj Bjorner ed58175e1b issue #4582
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-21 18:23:41 -07:00
Christoph M. Wintersteiger d3ae40130a
Fix rounding bug in mpf_manager. Fixes #2970. 2020-07-16 12:39:12 +00:00
Nuno Lopes b7caabbd0f fix crashes with MSVC 2019 2020-07-14 13:14:44 +01:00
Nuno Lopes d1a0e83423 fix crash 2020-07-13 14:25:12 +01:00
Nuno Lopes 122f5a1464 remove unused field 2020-07-12 23:12:00 +01:00
Nuno Lopes 90fc8d854f add rval methods to scoped_vector 2020-07-12 22:16:24 +01:00
Nuno Lopes f30e8ccec3 fix crashes due to my last commit 2020-07-12 19:53:22 +01:00
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
Nuno Lopes ca97bfb4b8 fix build 2020-07-05 11:44:12 +01:00
Nikolaj Bjorner 006418e027 build
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 23:34:21 -07:00
Nikolaj Bjorner f380d4cf83 mpfx
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 18:25:32 -07:00
Nikolaj Bjorner 51d43c04ea st
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 17:13:04 -07:00
Nikolaj Bjorner bf14444f7d st
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 17:07:07 -07:00
Nikolaj Bjorner d0e20e44ff booyah
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 15:56:30 -07:00
Nikolaj Bjorner 10d0404175 add rec decl/def to ML #4563
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-07-04 15:38:32 -07:00
Nikolaj Bjorner 38d6771a5e na
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-06-22 12:23:42 -07:00
Nuno Lopes 38d4418f94 simplify string_buffer::append 2020-06-18 19:55:34 +01:00
Nikolaj Bjorner 7387fc9dec avoid some bignum overhead in addmul
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-06-14 11:20:05 -07:00
Nuno Lopes ec1e733ef2 fix crash in qe_array ref counting due to wrong assignment operator of ptr_vector being called
thanks to Arie Gurfinkel for reporting this
2020-06-09 10:02:27 +01:00
Nikolaj Bjorner 9ca5b3f304 fix #4449
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-06-03 21:10:07 -07:00
Nuno Lopes e844aef896 remove a few more copy constructors, though still not enough to enable the assertion in vector
I give up for now; there are too many copies left for little return..
2020-06-03 20:32:13 +01:00
Nuno Lopes 7ac2791482 remove a bunch of constructors to avoid copies
still not enough to guarantee that vector::expand doesnt copy (WIP)
2020-06-03 17:09:27 +01:00
Nuno Lopes 98b5abb1d4 buffer: require a move constructor to avoid copies
remove unneded copy constructors from several classes
2020-06-03 11:57:49 +01:00
Nuno Lopes 3d98bccc33 fix mem leak in buffer and remove copies in interval (#4458) 2020-06-03 10:26:00 +01:00
Nuno Lopes 6a45c5d17c fix build with prehistorical compilers because of pip/manylinux 2020-05-30 11:42:27 +01:00
Nuno Lopes d8cea7c8d5 fix a few warnings & simplify debug.h header 2020-05-26 13:49:13 +01:00
Nuno Lopes 7a12cebd41 remove unused file 2020-05-24 00:10:40 +01:00
Nuno Lopes 903725314c fix gcc 9/10 warnings 2020-05-23 16:39:09 +01:00
Nuno Lopes 232f1b5fbe fix a gcc 10 warning 2020-05-19 14:44:14 +01:00
Nikolaj Bjorner 5844964d95 rename temporary macro
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-05-18 17:17:51 -07:00
Nikolaj Bjorner 8e8e9be25f st
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2020-05-18 16:49:43 -07:00