* 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
---------
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
Co-authored-by: humnrdble <83878671+humnrdble@users.noreply.github.com>
* Initial plan
* Add proper pyproject.toml metadata for dist-info creation
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
* Clean up setup.py and add comprehensive test for dist-info fix
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
* Fix build errors in setup.py and pyproject.toml
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
* Fix ModuleNotFoundError by removing dynamic version loading from pyproject.toml
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
* Remove hardcoded version from pyproject.toml, use dynamic version from setup.py
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>
Update setup.py so that we copy LICENSE.TXT to src/api/python before
creating the sdist. Any wheels built from this sdist will now
contain the LICENSE.txt file.
Fixes#7604
Rather than pulling `cmake` from PyPI unconditionally, add it to build
dependencies only if the system `cmake` executable cannot be found.
This eliminates an unnecessary dependency on systems featuring CMake,
and ensures that whenever possible, a downstream patched CMake version
is used that is more compatible with the system in question.
Add API solve_for(vars).
It takes a list of variables and returns a triangular solved form for the variables.
Currently for arithmetic. The solved form is a list with elements of the form (var, term, guard).
Variables solved in the tail of the list do not occur before in the list.
For example it can return a solution [(x, z, True), (y, x + z, True)] because first x was solved to be z,
then y was solved to be x + z which is the same as 2z.
Add congruent_explain that retuns an explanation for congruent terms.
Terms congruent in the final state after calling SimpleSolver().check() can be queried for
an explanation, i.e., a list of literals that collectively entail the equality under congruence closure.
The literals are asserted in the final state of search.
Adjust smt_context cancellation for the smt.qi.max_instantiations parameter.
It gets checked when qi-queue elements are consumed.
Prior it was checked on insertion time, which didn't allow for processing as many
instantations as there were in the queue. Moreover, it would not cancel the solver.
So it would keep adding instantations to the queue when it was full / depleted the
configuration limit.
The scoped_timer uses a std::therad. Spawning this thread fails in cases of WASM.
Instead of adapting builds and using async features at the level of WASM and the client, we expose a specialized version of z3 that doesn't use threads at all, neither for solvers nor for timers.
The tradeoff is that the periodic poll that checks for timeout directly queries the global clock each time.
We characterize it as based on polling.
- add some logic to setup.py to handle cross platform tagging correctly
this adds a dependency on setuptools>=70
- rearrange the nightly CI to use these new builds correctly