3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-02-19 15:04:42 +00:00
Commit graph

20316 commits

Author SHA1 Message Date
Nikolaj Bjorner
279a379a1e fix build dir
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:02 -08:00
Nikolaj Bjorner
1b76944c7d try adding wasm as separate step
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
a01bd575c9 Update docs.yml 2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
9aede918bd Modify docs.yml to generate JS documentation
Updated documentation generation script to include JavaScript output.
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
50bca45237 enable js
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
17f8594756 include paramters
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
cfdd3208c6 updated with env ocaml
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
f81fe09ddb update doc
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Copilot
24eb0efbc0 Fix docs.yml workflow: update actions to v4 (#8095)
* Initial plan

* Fix docs.yml workflow: update GitHub Actions to valid versions

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>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
a2a4bb44c0 docs with ml bindings
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
5be3c6b4e8 fix indentation 2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
1f14f7542b Modify docs.yml for deployment settings
Updated the GitHub Actions workflow for documentation deployment, changing the publish directory and removing the push trigger.
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
a60bd113dc Update publish directory for documentation deployment 2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
71c20690e3 Update docs.yml 2026-02-18 20:57:01 -08:00
Copilot
604d04c8b3 Deploy docs to z3prover.github.io organization pages (#8094)
* Initial plan

* Deploy docs to z3prover.github.io organization pages

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>
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
6367736a4a Simplify CI workflow by removing emscripten steps
Removed unnecessary steps for emscripten setup and TypeScript/WASM build in the CI workflow.
2026-02-18 20:57:01 -08:00
Nikolaj Bjorner
0f990b0c11 Add working directory for wasm build step 2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
da2c4dde69 Update docs.yml 2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
6d293a8b51 Update docs.yml 2026-02-18 20:57:00 -08:00
Copilot
d26fcdd8e9 Fix docs.yml workflow: resolve WASM/native library conflict in documentation generation (#8093)
* Initial plan

* Fix docs.yml: Build native Z3 Python bindings before WASM to avoid library conflicts

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>
2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
d533260445 use new arithmetic solver for AUFLIA, fixes #8090
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
85c8c6bd6b fix #8092
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:00 -08:00
Copilot
dcd6414c7e Fix docs.yml workflow: remove conflicting native build step (#8091)
* Initial plan

* Fix docs.yml workflow to properly build and deploy documentation

- Remove `no-install: true` from setup-emsdk step to properly install emscripten
- Remove `working-directory: src/api/js` from setup-emsdk step (not needed)
- Remove manual emsdk install/activate/source commands from Build wasm step
- Remove redundant native Z3 build step that conflicted with wasm build
- Simplify Generate Documentation step by removing redundant source command

The main issue was that the native Z3 build was creating a Makefile in the build/
directory before the wasm build ran. The wasm build script then saw the Makefile
existed and skipped the emconfigure step, but the native Makefile doesn't have a
libz3.a target, causing the build to fail. Removing the native build allows the
wasm build to properly configure its own build with emscripten.

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>
2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
7f06ec3449 merge
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:57:00 -08:00
h-vetinari
a76cc36f13 BLD: Add CMake option to build Python bindings without rebuilding libz3 (redux) (#8088)
* Add CMake option to build only Python bindings without rebuilding libz3

Introduce Z3_BUILD_LIBZ3_CORE option (default ON) to control whether libz3 is built.
When set to OFF with Z3_BUILD_PYTHON_BINDINGS=ON, only Python bindings are built
using a pre-installed libz3 library. This is useful for package managers like
conda-forge to avoid rebuilding libz3 for each Python version.

Changes:
- Add Z3_BUILD_LIBZ3_CORE option in src/CMakeLists.txt
- When OFF, find and use pre-installed libz3 as imported target
- Update Python bindings CMakeLists.txt to handle both built and imported libz3
- Add documentation in README-CMake.md with usage examples

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

* Fix CMake export issues when building only Python bindings

Conditionally export Z3_EXPORTED_TARGETS only when Z3_BUILD_LIBZ3_CORE=ON
to avoid errors when building Python bindings without building libz3.

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

* Disable executable and test builds when not building libz3 core

When Z3_BUILD_LIBZ3_CORE=OFF, automatically disable Z3_BUILD_EXECUTABLE
and Z3_BUILD_TEST_EXECUTABLES to avoid build/install errors.

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

* only build src/ folder if Z3_BUILD_LIBZ3_CORE is TRUE

* move z3 python bindings to main CMake

* move more logic to main CMakeLists.txt

* move Z3_API_HEADER_FILES_TO_SCAN to main CMakeLists.txt

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
c963596723 Update docs.yml 2026-02-18 20:57:00 -08:00
Nikolaj Bjorner
0f0f6972e7 Add defaults for job run working directory 2026-02-18 20:56:59 -08:00
Nikolaj Bjorner
41ce10e438 Update docs.yml 2026-02-18 20:56:59 -08:00
Nikolaj Bjorner
9a7317ae44 Update docs.yml 2026-02-18 20:56:59 -08:00
Nikolaj Bjorner
8d62bb3941 build the ts bindings
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:59 -08:00
Nikolaj Bjorner
aa9d9f2181 build the ts bindings
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:59 -08:00
dependabot[bot]
e841b20679 Bump actions/upload-artifact from 5 to 6 (#8083)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-18 20:56:59 -08:00
Copilot
33110ddaad Build native Z3 for x64 before generating docs (#8086)
* Initial plan

* Build Z3 for ubuntu x64 and invoke JS build scripts in docs workflow

- Modified docs.yml to build Z3 natively for ubuntu-latest x64 before documentation generation
- Removed default working directory to allow explicit working-directory per step
- Added step to build Z3 using python scripts/mk_make.py
- Kept emscripten setup as required for wasm build
- Modified mk_api_doc.py to invoke npm run build:ts and npm run build:wasm as described in src/api/js/README.md
- mk_api_doc.py now runs the full build process (TypeScript + wasm) before generating documentation

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

* Source emsdk environment before generating documentation

- Added source command to ensure emscripten tools are in PATH when mk_api_doc.py runs npm scripts
- This ensures emcc and other emscripten tools are available for npm run build:wasm

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

* Revert changes to mk_api_doc.py

- Removed npm run build:ts and npm run build:wasm calls from mk_api_doc.py
- Reverted to only calling npm run docs as before

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>
2026-02-18 20:56:59 -08:00
dependabot[bot]
0f14cfd37a Bump actions/download-artifact from 6 to 7 (#8082)
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 6 to 7.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-18 20:56:59 -08:00
dependabot[bot]
fbd6a2584a Bump actions/cache from 4 to 5 (#8081)
Bumps [actions/cache](https://github.com/actions/cache) from 4 to 5.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-18 20:56:59 -08:00
Copilot
16596e0b44 Add GitHub Actions workflow to publish JavaScript/TypeScript API documentation (#8084)
* Initial plan

* Add GitHub Actions workflow to build and publish documentation

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

* Refine documentation workflow to use mk_api_doc.py and install doxygen

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

* Clarify documentation generation step name

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>
2026-02-18 20:56:59 -08:00
Copilot
3c06cee549 Fix DEL character (0x7F) not being escaped in string literals (#8080)
* Initial plan

* Fix DEL character encoding in string literals

Change condition from `ch >= 128` to `ch >= 127` to include the DEL
character (U+007F, 127) in escaped output. This ensures that the
non-printable DEL control character is properly escaped as \u{7f}
instead of being printed directly.

Also add test cases for DEL and other control characters.

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>
2026-02-18 20:56:59 -08:00
Chris Cowan
d3d770938b Typescript typedef and doc fixes take 2 (#8078)
* Fix Typescript typedef to allow `new Context`

* fix init() tsdoc example using nonexistent sat import
2026-02-18 20:56:58 -08:00
Nikolaj Bjorner
e2d568f32b Revert "Typescript typedef and doc fixes (#8073)" (#8077)
This reverts commit 6cfbcd19df.
2026-02-18 20:56:58 -08:00
Chris Cowan
13204421e7 Typescript typedef and doc fixes (#8073)
* Fix Typescript typedef to allow `new Context`

* fix init() tsdoc example using nonexistent sat import
2026-02-18 20:56:58 -08:00
Ilana Shapiro
34a40c7747 Search tree core resolution optimization (#8066)
* Add cube tree optimization about resolving cores recursively up the path, to prune. Also integrate asms into the tree so they're not tracked separately (#7960)

* draft attempt at optimizing cube tree with resolvents. have not tested/ran yet

* adding comments

* fix bug about needing to bubble resolvent upwards to highest ancestor

* fix bug where we need to cover the whole resolvent in the path when bubbling up

* clean up comments

* close entire tree when sibling resolvent is empty

* integrate asms directly into cube tree, remove separate tracking

* try to fix bug about redundant resolutions, merging close and try_resolve_upwards into once function

* separate the logic again to avoid mutual recursion

* Refactor search tree closure and resolution logic

Refactor close_with_core to simplify logic and remove unnecessary parameters. Update sibling resolvent computation and try_resolve_upwards for clarity.

* apply formatting

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

* Refactor close_with_core to use current node in lambda

* Fix formatting issues in search_tree.h

* fix build issues

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

* Update smt_parallel.cpp

* Change loop variable type in unsat core processing

* Change method to retrieve unsat core from root

---------

Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:58 -08:00
Copilot
1081916973 Implement Z3_optimize_translate for context translation (#8072)
* Initial plan

* Implement Z3_optimize_translate functionality

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

* Fix compilation errors and add tests for optimize translate

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

* Revert changes to opt_solver.cpp as requested

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>
2026-02-18 20:56:58 -08:00
Nikolaj Bjorner
3a09b0d2b5 remove stale experimental code #8063
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:58 -08:00
Nikolaj Bjorner
3669dc37b3 don't unfold recursive defs if there is an uninterpreted subterm, #7671
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:58 -08:00
Nikolaj Bjorner
b6e8f2b033 disable preprocessing only after formulas are internalized 2026-02-18 20:56:57 -08:00
Nikolaj Bjorner
d59d40a356 allow parsing declared arrays without requiring explicit select
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-02-18 20:56:57 -08:00
Lev Nachmanson
7a6eb9bb4d fix the build
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2026-02-18 20:56:57 -08:00
Copilot
5aa35eba20 Disable C++98 compatibility warnings for Clang builds (#8060)
* Initial plan

* Disable C++98 compatibility warnings for Clang to fix vcpkg build freeze

Add -Wno-c++98-compat and -Wno-c++98-compat-pedantic flags to prevent
excessive warning output when building with clang-cl or when -Weverything
is enabled. These warnings are not useful for Z3 since it requires C++20.

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>
2026-02-18 20:56:57 -08:00
Lev Nachmanson
1200c0bd0c remove unused *_signed_project() methods
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2026-02-18 20:56:57 -08:00
Nikolaj Bjorner
208c5b1b73 fix #8054
inherit denominators when evaluating polynomials
2026-02-18 20:56:57 -08:00