3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-11-09 23:52:02 +00:00
Commit graph

121 commits

Author SHA1 Message Date
Lev Nachmanson
37c9f1c7c2 remove some non-deterministic behavior in theory_lra.cpp
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2025-10-29 21:37:05 -07:00
Lev Nachmanson
ba83ec929a passing with open ai codex on some non-deterministic param eval
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2025-10-29 06:25:03 -07:00
Lev Nachmanson
c739e581e4 non-deterministic calls are marked
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2025-10-28 19:13:12 -07:00
Lev Nachmanson
54257b6629 revert the change
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2025-10-28 19:00:46 -07:00
Lev Nachmanson
51f6dfeb83 fix some argument-evaluation non-determinism, and mark the rest
Signed-off-by: Lev Nachmanson <levnach@hotmail.com>
2025-10-28 18:01:44 -07:00
Nikolaj Bjorner
e3139d4e03 #7750
add pre-processing simplification
2025-07-27 13:38:36 -07:00
LeeYoungJoon
0a93ff515d
Centralize and document TRACE tags using X-macros (#7657)
* Introduce X-macro-based trace tag definition
- Created trace_tags.def to centralize TRACE tag definitions
- Each tag includes a symbolic name and description
- Set up enum class TraceTag for type-safe usage in TRACE macros

* Add script to generate Markdown documentation from trace_tags.def
- Python script parses trace_tags.def and outputs trace_tags.md

* Refactor TRACE_NEW to prepend TraceTag and pass enum to is_trace_enabled

* trace: improve trace tag handling system with hierarchical tagging

- Introduce hierarchical tag-class structure: enabling a tag class activates all child tags
- Unify TRACE, STRACE, SCTRACE, and CTRACE under enum TraceTag
- Implement initial version of trace_tag.def using X(tag, tag_class, description)
  (class names and descriptions to be refined in a future update)

* trace: replace all string-based TRACE tags with enum TraceTag
- Migrated all TRACE, STRACE, SCTRACE, and CTRACE macros to use enum TraceTag values instead of raw string literals

* trace : add cstring header

* trace : Add Markdown documentation generation from trace_tags.def via mk_api_doc.py

* trace : rename macro parameter 'class' to 'tag_class' and remove Unicode comment in trace_tags.h.

* trace : Add TODO comment for future implementation of tag_class activation

* trace : Disable code related to tag_class until implementation is ready (#7663).
2025-05-28 14:31:25 +01:00
Nikolaj Bjorner
80f00f191a fix #7572 and fix #7574
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2025-03-07 10:46:29 -08:00
Nikolaj Bjorner
f67e1b8b8b only allow flip if it doesn't increase unsat score
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2025-01-02 08:39:43 -08:00
Nikolaj Bjorner
3433b14dfa separate fixed from bits to allow updates that break tabu
- range and fixed restrictions on terms are based on constraints and can be violated temporarily.
- bv_eval currently does not allow updating over fixed bits which leads to non-termination. TODO
- lookahead only considers tabu when setting values of variables.
2024-12-30 17:47:18 -08:00
Nikolaj Bjorner
f41134d1b6 h
- avoid more platform specific behavior when using m_mk_extract,
- rename mk_eq in bool_rewriter to mk_eq_plain to distinguish it from mk_eq_rw
- rework bv_lookahead to be more closely based on sls_engine, which has much better heuristic behavior than attempt 1.
2024-12-28 17:40:25 -08:00
Nikolaj Bjorner
85d3041a80 avoid platform non-reproducibility due to argument evaluation ordering 2024-12-23 17:13:51 -08:00
Nikolaj Bjorner
3b2315d771 remove verbose output 2024-12-21 15:52:57 +01:00
Nikolaj Bjorner
578804acf4 fix #7460 2024-12-21 14:42:23 +01:00
Nikolaj Bjorner
ecdfab81a6 fix #7434
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2024-10-28 17:51:01 -07:00
Nikolaj Bjorner
ba5cec7704 additional rewrites for bv2int 2024-09-22 21:29:12 +03:00
Nikolaj Bjorner
fa7fc8ef5e Refactor bv_rewriter functions using unified variable assignment and early break logic 2024-09-22 13:04:49 +03:00
Nikolaj Bjorner
d66609ea14 fix #7389
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2024-09-22 02:41:11 +03:00
Nikolaj Bjorner
13be3c3fbb reset model converter between rounds to elim-unconstrained. 2023-12-18 16:57:52 -08:00
Nikolaj Bjorner
0daa05aab2 add ability to log selected bv rewrites 2023-12-18 16:57:52 -08:00
Nikolaj Bjorner
e9abdbb7a4 fix #7011
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2023-11-29 15:08:08 -08:00
Jakob Rath
57e92b2a59
Fix bvnego (#6750) 2023-06-07 11:24:40 -07:00
Antti Hyvärinen
12e45c9d17
Implement proposed smtlib2 bitvector overflow predicates (#6715)
* Logical names for function declarations in c++

Currently, for example, the function declaration symbol member for
checking whether multiplication *does not* overflow is called
`m_bv_smul_ovfl`.  Since we are introducing the upcoming smtlib2 symbols
that check that multpliciation *does* overflow, the not overflow check
symbols are renamed to `m_bv_smul_no_ovfl` etc.

* Implement smtlib overflow preds for multiplication

Smtlib2 is being extended to include overflow predicates for bit
vectors (see https://groups.google.com/u/1/g/smt-lib/c/J4D99wT0aKI).
This commit introduces the predicates `bvumulo` and `bvsmulo` that
return `true` if the unsigned multiplication overflows or the signed
multiplication underflows or overflows, respectively.

* Move mul overflow predicates to BV logic

* Add a todo on illogical argument order

* Implement mk_unary_pred for bv

* Implement bvnego

* Implement bvuaddo

* Implement bvsaddo

* Implement bvusubo

* Implement bvssubo

* Implement bvsdivo
2023-05-09 10:37:46 -07:00
Nikolaj Bjorner
c0f80f92ba deal with compiler warnings (unused variables etc) 2023-02-18 17:53:37 -08:00
Nikolaj Bjorner
d415f07386 memory leak on proof justifications
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2023-01-10 18:58:25 -08:00
Nikolaj Bjorner
61b90e64b2 disable new simplifcation for multiplier until really understood
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2023-01-08 14:17:49 -08:00
Nikolaj Bjorner
fcea32344e add missing tactic descriptions, add rewrite for tamagochi
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2023-01-08 13:32:26 -08:00
Nikolaj Bjorner
87095950cb fix #6477 2022-12-04 13:02:45 -08:00
Nikolaj Bjorner
79e6d4e32d tune and debug elim-unconstrained (v2 - for simplifiers infrastructure) 2022-12-04 03:53:31 -08:00
Nikolaj Bjorner
cf7bba6288 use ast_manager as an attribute 2022-12-04 03:53:30 -08:00
Nikolaj Bjorner
eceeb295fc fix #6457 2022-11-24 14:41:50 +07:00
Nikolaj Bjorner
9845c33236 add shortcuts in rewriter, eliminate redundancies in dependent_expr tactic 2022-11-15 09:13:13 -08:00
Nikolaj Bjorner
3a4b8e2334 add rewrite rules to bv-rewriter 2022-11-08 12:20:51 -08:00
Nikolaj Bjorner
fe1b4bf5ce disable ternary, fixes to propagation, make bv_rewrites for multiplier n-ary 2022-10-26 23:44:38 -07:00
Nikolaj Bjorner
5352a0106d fix #6426 2022-10-26 12:20:55 -07:00
Nikolaj Bjorner
c62c5e9d23 add opportunistic, missing, bv rewrites
- x >> x logical = 0
- ~x = -1 -x
- x * (y << z) = (x * y) << z
2022-10-25 10:29:48 -07:00
Nikolaj Bjorner
ab9aee189b perf #6100 2022-06-21 13:49:52 -07:00
Nikolaj Bjorner
6abea2de2c fix nightly, fix regression identified by Nuno
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2022-05-28 18:03:15 -07:00
Nikolaj Bjorner
8d980ea704 remove internal configuration
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2022-05-28 12:13:18 -07:00
Clemens Eisenhofer
0b20a4ebf4
Added rewriting distinct with bitvectors to false if bit-size is too low (#5956)
* Fixed problem with registering bitvector functions

* Added rewriting distinct with bitvectors to false if bit-size is too low

* Removed debug output

* Incorporated Nikolaj's comments

* Simplifications
2022-04-09 21:46:21 +02:00
Nikolaj Bjorner
431c3af409 fix #5929 - add parameter bv_le2extract to allow disabling the disassembly to extract 2022-03-27 18:23:41 -10:00
Nikolaj Bjorner
913b90f7aa fix #5802
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2022-01-30 10:42:34 -08:00
Nikolaj Bjorner
2551631957 mul overflow #5797 2022-01-29 09:15:38 -08:00
Nikolaj Bjorner
5e81c1220c #5797 probably still wrong wrt underflow. 2022-01-27 12:48:15 -08:00
Nikolaj Bjorner
4da930b490 #5794
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2022-01-27 10:50:48 -08:00
Nikolaj Bjorner
461e71017d fix #5792 again
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2022-01-26 15:54:44 -08:00
Nikolaj Bjorner
20f9814939 fix #5789
fix incorrect constant folding
2022-01-24 09:42:14 +01:00
Nikolaj Bjorner
87aec8819f fix #5687
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-12-01 10:08:29 -08:00
Nikolaj Bjorner
c083aa82ee add debug information in user-propagate #5687
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2021-11-29 08:59:53 -08:00
Nikolaj Bjorner
4a6083836a call it data instead of c_ptr for approaching C++11 std::vector convention. 2021-04-13 18:17:35 -07:00