3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-08-26 04:56:03 +00:00
z3/src/test
Ilana Shapiro 6044389446
Parallel solving (#7771)
* very basic setup

* ensure solve_eqs is fully disabled when smt.solve_eqs=false, #7743

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* respect smt configuration parameter in elim_unconstrained simplifier

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* indentation

* add bash files for test runs

* add option to selectively disable variable solving for only ground expressions

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* remove verbose output

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* fix #7745

axioms for len(substr(...)) escaped due to nested rewriting

* ensure atomic constraints are processed by arithmetic solver

* #7739 optimization

add simplification rule for at(x, offset) = ""

Introducing j just postpones some rewrites that prevent useful simplifications. Z3 already uses common sub-expressions.
The example highlights some opportunities for simplification, noteworthy at(..) = "".
The example is solved in both versions after adding this simplification.

* fix unsound len(substr) axiom

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* FreshConst is_sort (#7748)

* #7750

add pre-processing simplification

* Add parameter validation for selected API functions

* updates to ac-plugin

fix incrementality bugs by allowing destructive updates during saturation at the cost of redoing saturation after a pop.

* enable passive, add check for bloom up-to-date

* add top-k fixed-sized min-heap priority queue for top scoring literals

* set up worker thread batch manager for multithreaded batch cubes paradigm, need to debug as I am getting segfault still

* fix bug in parallel solving batch setup

* fix bug

* allow for internalize implies

* disable pre-processing during cubing

* debugging

* remove default constructor

* remove a bunch of string copies

* Update euf_ac_plugin.cpp

include reduction rules in forward simplification

* Update euf_completion.cpp

try out restricting scope of equalities added by instantation

* Update smt_parallel.cpp

Drop non-relevant units from shared structures.

* process cubes as lists of individual lits

* merge

* Add support for Algebraic Datatypes in JavaScript/TypeScript bindings (#7734)

* Initial plan

* Add datatype type definitions to types.ts (work in progress)

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

* Complete datatype type definitions with working TypeScript compilation

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

* Implement core datatype functionality with TypeScript compilation success

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

* Complete datatype implementation with full Context integration and tests

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>

* chipping away at the new code structure

* comments

* debug infinite recursion and split cubes on existing split atoms that aren't in the cube

* share lemmas, learn from unsat core, try to debug a couple of things, there was a subtle bug that i have a hard time repro'ing

* merge

* fix #7603: race condition in Ctrl-C handling (#7755)

* fix #7603: race condition in Ctrl-C handling

* fix race in cancel_eh

* fix build

* add arithemtic saturation

* add an option to register callback on quantifier instantiation

Suppose a user propagator encodes axioms using quantifiers and uses E-matching for instantiation. If it wants to implement a custom priority scheme or drop some instances based on internal checks it can register a callback with quantifier instantiation

* missing new closure

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* add Z3_solver_propagate_on_binding to ml callback declarations

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* add python file

Signed-off-by: Lev Nachmanson <levnach@Levs-MacBook-Pro.local>

* debug under defined calls

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* more untangle params

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* precalc parameters to define the eval order

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* remove a printout

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* rename a Python file

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* add on_binding callbacks across APIs

update release notes,
add to Java, .Net, C++

* use jboolean in Native interface

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* register on_binding attribute

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* fix java build for java bindings

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* avoid interferring side-effects in function calls

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* remove theory_str and classes that are only used by it

* remove automata from python build

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* remove ref to theory_str

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>

* get the finest factorizations before project

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* rename add_lcs to add_lc

Signed-off-by: Lev Nachmanson <levnach@hotmail.com>

* resolve bad bug about l2g and g2l translators using wrong global context. add some debug prints

* initial attempt at dynamically switching from greedy to frugal splitting strategy in return_cubes. need to test. also there is some bug where the threads take forever to cancel?

* Update RELEASE_NOTES.md

* resolve bug about not translating managers correctly for the second phase of the greedy cubing, and the frugal fallback

---------

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
Signed-off-by: Lev Nachmanson <levnach@Levs-MacBook-Pro.local>
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
Co-authored-by: humnrdble <83878671+humnrdble@users.noreply.github.com>
Co-authored-by: Nuno Lopes <nuno.lopes@tecnico.ulisboa.pt>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
Co-authored-by: Lev Nachmanson <levnach@hotmail.com>
2025-08-11 09:14:20 -07:00
..
fuzzing fix test build 2023-12-22 16:19:28 +00:00
lp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
algebraic.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
api.cpp Update api.cpp 2023-02-18 18:43:20 -08:00
api_bug.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
arith_rewriter.cpp fix build of tests 2022-06-17 17:11:18 +01:00
arith_simplifier_plugin.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
ast.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
bdd.cpp Additional BDD operations; BDD vectors and finite domain abstraction 2022-08-01 18:37:11 +03:00
bit_blaster.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
bit_vector.cpp bool_vector, some spacer tidy 2020-04-05 12:59:04 -07:00
bits.cpp fix build of tests 2022-06-17 17:11:18 +01:00
buffer.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
chashtable.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
check_assumptions.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
CMakeLists.txt ho matcher draft 2025-07-04 18:01:47 -07:00
cnf_backbones.cpp fix build warnings 2024-09-30 13:09:01 -07:00
cube_clause.cpp fix build of tests 2022-06-17 17:11:18 +01:00
datalog_parser.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
ddnf.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
diff_logic.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
distribution.cpp add tests for distribution utility and fix loose ends 2023-04-13 11:19:06 -07:00
dl_context.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
dl_product_relation.cpp fix #6213 2022-07-31 18:40:59 +03:00
dl_query.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
dl_relation.cpp unused variables 2022-10-20 09:09:06 -07:00
dl_table.cpp fix build of tests 2022-06-17 17:11:18 +01:00
dl_util.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
dlist.cpp Sls (#7439) 2024-11-02 12:32:48 -07:00
doc.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
egraph.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
escaped.cpp fix build of tests 2022-06-17 17:11:18 +01:00
euf_arith_plugin.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
euf_bv_plugin.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
ex.cpp add noexcept for signature compatibility 2024-11-04 11:13:49 -08:00
expr_rand.cpp fix a couple hundred deref-after-free bugs due to .c_str() on a temporary string 2020-07-11 20:24:45 +01:00
expr_substitution.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
ext_numeral.cpp fixes 2017-08-27 11:01:45 -07:00
f2n.cpp fix build of tests 2022-06-17 17:11:18 +01:00
factor_rewriter.cpp fix build of tests 2022-06-17 17:11:18 +01:00
finder.cpp consolidate literals 2021-05-20 12:58:27 -07:00
fixed_bit_vector.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
for_each_file.cpp remove dependency on ARRAYSIZE for issue #1616 2018-08-15 22:26:14 -07:00
for_each_file.h booyah 2020-07-04 15:56:30 -07:00
get_consequences.cpp fix build of tests 2022-06-17 17:11:18 +01:00
get_implied_equalities.cpp tune for unit test, delay initialize re-solver 2018-05-13 11:49:33 -07:00
hashtable.cpp refactoring to use for-range 2025-05-15 10:57:46 -07:00
heap.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
heap_trie.cpp fix build of tests 2022-06-17 17:11:18 +01:00
hilbert_basis.cpp fix build of tests 2022-06-17 17:11:18 +01:00
ho_matcher.cpp turn on ho-matcher for completion 2025-07-07 14:08:51 +02:00
horn_subsume_model_converter.cpp fixing build 2022-11-03 22:08:21 -07:00
hwf.cpp fix #7143: type punning in test 2024-03-04 14:34:02 +00:00
im_float_config.h booyah 2020-07-04 15:56:30 -07:00
inf_rational.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
interval.cpp compile warnings 2023-02-19 10:03:38 -08:00
karr.cpp fix build of tests 2022-06-17 17:11:18 +01:00
list.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
main.cpp ho matcher draft 2025-07-04 18:01:47 -07:00
map.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
matcher.cpp Enable more tests on non-Windows. (#6199) 2022-07-29 11:48:27 +02:00
memory.cpp Enable more tests on non-Windows. (#6199) 2022-07-29 11:48:27 +02:00
model2expr.cpp fix build of tests 2022-06-17 17:11:18 +01:00
model_based_opt.cpp fix unit test 2025-02-17 20:36:38 -08:00
model_evaluator.cpp fix build of tests 2022-06-17 17:11:18 +01:00
model_retrieval.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
mpbq.cpp fix build of tests 2022-06-17 17:11:18 +01:00
mpf.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
mpff.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
mpfx.cpp fix build of tests 2022-06-17 17:11:18 +01:00
mpq.cpp fix build of tests 2022-06-17 17:11:18 +01:00
mpz.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
nlarith_util.cpp fix build of tests 2022-06-17 17:11:18 +01:00
nlsat.cpp fix the test-z3 build 2025-06-17 07:22:03 -07:00
no_overflow.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
object_allocator.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
old_interval.cpp fix build of tests 2022-06-17 17:11:18 +01:00
optional.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
parray.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
pb2bv.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
pdd.cpp Merge shared parts from polysat branch (#7063) 2023-12-28 11:11:53 -08:00
pdd_solver.cpp Arith min max (#6864) 2023-08-19 17:44:09 -07:00
permutation.cpp add apply_permutation tests (#7322) 2024-08-02 18:29:33 -07:00
polynomial.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
polynorm.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
prime_generator.cpp fix build of tests 2022-06-17 17:11:18 +01:00
proof_checker.cpp fix build of tests 2022-06-17 17:11:18 +01:00
qe_arith.cpp fix build 2025-06-06 19:21:11 +02:00
quant_elim.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
quant_solve.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
random.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
rational.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
rcf.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
region.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
sat_local_search.cpp Parallel solving (#7771) 2025-08-11 09:14:20 -07:00
sat_lookahead.cpp fix build of tests 2022-06-17 17:11:18 +01:00
sat_user_scope.cpp fix build of tests 2022-06-17 17:11:18 +01:00
scoped_timer.cpp fix build of tests 2022-06-17 17:11:18 +01:00
scoped_vector.cpp add scoped_vector invariants and unit tests (#7327) 2024-08-02 19:21:40 -07:00
simple_parser.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
simplex.cpp Spacer Global Guidance (#6026) 2022-08-30 15:47:00 -07:00
simplifier.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
sls_seq_plugin.cpp add unit test for incremental equation edit distance with repair 2024-12-15 05:53:28 -08:00
sls_test.cpp fix build for tests 2025-01-22 13:30:12 -08:00
small_object_allocator.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
smt2print_parse.cpp just use std::string 2023-10-30 17:56:44 -07:00
smt_context.cpp call it data instead of c_ptr for approaching C++11 std::vector convention. 2021-04-13 18:17:35 -07:00
solver_pool.cpp fix build of tests 2022-06-17 17:11:18 +01:00
sorting_network.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
stack.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
string_buffer.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
substitution.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
symbol.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
symbol_table.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
tbv.cpp Move tbv to util 2022-08-01 18:37:11 +03:00
test_util.h make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
theory_dl.cpp fix build of tests 2022-06-17 17:11:18 +01:00
theory_pb.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
timeout.cpp make include paths uniformly use path relative to src. #534 2017-07-31 13:24:11 -07:00
total_order.cpp fix build of tests 2022-06-17 17:11:18 +01:00
totalizer.cpp add totalizer version of rc2 2022-06-29 23:10:42 -07:00
trigo.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
udoc_relation.cpp move smt params to params directory, update release.yml 2025-06-09 10:47:22 -07:00
uint_set.cpp fix build of tests 2022-06-17 17:11:18 +01:00
upolynomial.cpp disable tracing in test code 2025-06-08 08:08:10 -07:00
value_generator.cpp fix build of tests 2022-06-17 17:11:18 +01:00
value_sweep.cpp fix build of tests 2022-06-17 17:11:18 +01:00
var_subst.cpp Centralize and document TRACE tags using X-macros (#7657) 2025-05-28 14:31:25 +01:00
vector.cpp use std::exception as base class to z3_exception 2024-11-04 11:08:15 -08:00
zstring.cpp fix build of tests 2022-06-17 17:11:18 +01:00