3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-08-11 08:18:51 +00:00
z3/src/model
Can Cebeci ff87fb227e
Prevent special treatment of non-recursive siblings (#9903)
Addressing the following:
```
`https://zenodo.org/records/16740866/files/UFDT.tar.zst?download=1` — ERRORS `4` (signal-11:4)
  - Error queries: `non-incremental/UFDT/20170428-Barrett/cdt-cade2015/data/distro/process/x2015_09_10_16_46_28_479_1049550.smt_in.smt2`, `non-incremental/UFDT/20170428-Barrett/cdt-cade2015/data/distro/process/x2015_09_10_16_46_29_792_1051661.smt_in.smt2`, `non-incremental/UFDT/20170428-Barrett/cdt-cade2015/data/distro/process/x2015_09_10_16_46_24_262_1043633.smt_in.smt2`, `non-incremental/UFDT/20170428-Barrett/cdt-cade2015/data/distro/process/x2015_09_10_16_46_25_595_1045744.smt_in.smt2`
```

These segfault due to infinite recursion in
`datatype_factory::get_fresh_value` (through the call in line 222).

Splitting
```
(declare-datatypes ((Nibble$ 0)(Char$ 0)(Char_list$ 0)) (((nibble0$) (nibble1$) (nibble2$) (nibble3$) (nibble4$) (nibble5$) (nibble6$) (nibble7$) (nibble8$) (nibble9$) (nibbleA$) (nibbleB$) (nibbleC$) (nibbleD$) (nibbleE$) (nibbleF$))
((char$ (selectf$ Nibble$) (selectg$ Nibble$)))
((nil$) (cons$ (hd$ Char$) (tl$ Char_list$)))
))
```
into
```
(declare-datatypes ((Nibble$ 0)(Char$ 0)) (((nibble0$) (nibble1$) (nibble2$) (nibble3$) (nibble4$) (nibble5$) (nibble6$) (nibble7$) (nibble8$) (nibble9$) (nibbleA$) (nibbleB$) (nibbleC$) (nibbleD$) (nibbleE$) (nibbleF$))
((char$ (selectf$ Nibble$) (selectg$ Nibble$)))
))
(declare-datatypes ((Char_list$ 0)) (
((nil$) (cons$ (hd$ Char$) (tl$ Char_list$)))
))
```
turns them into timeouts

---------

Co-authored-by: Can Cebeci <t-cancebeci@microsoft.com>
Co-authored-by: Nikolaj Bjorner <nbjorner@microsoft.com>
2026-06-19 10:08:30 -06:00
..
array_factory.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
array_factory.h
char_factory.h
CMakeLists.txt
datatype_factory.cpp Prevent special treatment of non-recursive siblings (#9903) 2026-06-19 10:08:30 -06:00
datatype_factory.h
finite_set_factory.cpp
finite_set_factory.h
fpa_factory.h Fix unused parameter warnings in empty override functions by omitting parameter names (#8174) 2026-02-18 20:57:11 -08:00
func_interp.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
func_interp.h Fix instance of "flexible array member". (#9883) 2026-06-16 16:09:18 -06:00
model.cpp
model.h
model2expr.cpp
model2expr.h Remove redundant default constructors when they're the only constructor (#8461) 2026-02-18 20:58:01 -08:00
model_core.cpp disable test in tptp, move to native lambdas 2026-06-02 10:38:51 -07:00
model_core.h Update model_core.h 2026-06-01 19:47:40 -07:00
model_evaluator.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
model_evaluator.h
model_evaluator_params.pyg
model_implicant.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
model_implicant.h
model_macro_solver.cpp
model_macro_solver.h
model_params.pyg
model_pp.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
model_pp.h
model_smt2_pp.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
model_smt2_pp.h
model_v2_pp.cpp Standardize for-loop increments to prefix form (++i) (#8199) 2026-02-18 20:57:29 -08:00
model_v2_pp.h
numeral_factory.cpp
numeral_factory.h
seq_factory.h
struct_factory.cpp
struct_factory.h
value_factory.cpp
value_factory.h Fix unused parameter warnings in empty override functions by omitting parameter names (#8174) 2026-02-18 20:57:11 -08:00