After seven years without a release, Gecode now has two in quick succession: Gecode 6.3.0 on 7 July 2026, and Gecode 6.4.0 on 15 July.
The split is deliberate.
Version 6.3.0 collects the work that accumulated on the old release branch since Gecode 6.2.0.
Version 6.4.0 moves active development onto main, makes CMake the standard build system, and switches releases to source-only.
If you are starting a project or upgrading an existing one, go straight to 6.4.0. Below, I have grouped the changes by what they mean in practice for users and developers.
Building and using Gecode is more conventional
The change you notice first in 6.4.0 is how Gecode builds and installs. CMake support existed before, but it now handles the full native build and is the intended way to compile Gecode:
cmake -S . -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel
cmake --build build --target check
cmake --install build --prefix /path/to/install
Installing Gecode now writes a CMake package config, so downstream CMake projects no longer need a custom FindGecode.cmake or hand-assembled include and library paths:
find_package(Gecode CONFIG REQUIRED)
add_executable(my-model main.cpp)
target_link_libraries(my-model PRIVATE Gecode::gecode)
Linking Gecode::gecode is the simplest default, though projects that want a narrower dependency can still request individual components such as driver, flatzinc, or gist.
The package also exports Gecode_VERSION, removing the need to inspect generated headers just to check the solver version, and it records both transitive dependencies and which optional components were built.
That helps most when MPFR, Qt, or Gist are involved; Qt 6 is now preferred, while Qt 5.15 and later remain supported.
The build requires CMake 3.21 or newer and a C++17-capable compiler. Autotools still works in 6.4.0, but it is slated for removal in a later release.
On the maintenance side, the code-generation scripts have moved from Perl to Python run through uv, which makes their environment much easier to reproduce.
Normal CMake builds use the generated files shipped in the source release and do not need these scripts.
MiniZinc and FlatZinc have caught up
A large share of 6.3.0 consists of bringing Gecode’s MiniZinc integration up to date:
- support for the standard
sliding_amongandregular_setconstraints; - the full
cumulativesscheduling constraint, along with optional activities forcumulativeanddisjunctive; - solver configuration and library files installed where MiniZinc expects to find them;
- value, domain, and bounds propagation annotations;
- better FlatZinc error messages, including MiniZinc constraint names when available; and
- the experimental
on_restartinterface for restart-based meta-search.1
Several smaller fixes also bring FlatZinc closer to standard MiniZinc semantics.
Array arguments are now unshared where needed for constraints such as inverse, division, modulo, arg_min, arg_max, and tables, and element constraints can keep index offsets instead of introducing transformed arrays.
Zero-duration tasks, empty sets, integer powers, and Boolean tables now match the expected MiniZinc behaviour as well.
Gecode 6.4.0 adds support for MiniZinc’s experimental black-box propagator interface.2 Through it, a FlatZinc model can hook up a custom value or bounds propagator implemented in a shared library or a persistent subprocess. Each call returns both the propagation result and the dependencies that tell the solver when to wake the propagator again, which lets you test a specialised propagation idea directly from MiniZinc without first writing a native C++ propagator inside Gecode. The interface may still evolve, but it is already a handy way to experiment.
New propagation choices
Gecode 6.4.0 introduces selectable support representations for extensional integer constraints.3
Table constraints vary widely in shape, and a representation that fits a small dense table can waste a lot of memory on a large sparse one.
A TupleSet can now use dense, sparse, or compressed-dense supports—or leave the choice to Gecode—and the table propagator follows that selection.
Library users can pick a representation explicitly, while FlatZinc tables and examples that build large tuple sets use automatic selection.
Bin-packing propagation has also gained lower bounds based on dual-feasible functions.4 They catch infeasible packing states earlier than the previous propagation alone, and this stronger propagation level is now the default.
Correctness and stability work
The correctness and stability fixes in 6.4.0 are less visible, but they are the part I value most in a solver release.
Two integer propagator bugs addressed real corner cases, and both now have regression tests.
Domain-level global cardinality propagation could lose solutions by counting assigned variables twice and holding on to stale conflict information, while the sorted constraint could fail to terminate when a matching component had no compatible interval.
Floating-point propagation received a similar pass. Interval medians no longer overflow near large bounds, a bug that could stall search completely.5 Multiplication, power, and nth-root propagators now contract intervals directly, avoiding several tight-bound and even-root corner cases.
Running search and cloning under sanitizers and deterministic fault injection turned up deeper issues: races and lifetime bugs in parallel search, undefined behaviour during branch-and-bound recomputation, and incomplete cleanup when an allocation fails while cloning a space or building MiniModel expressions. Failed cloning is now transactional, restoring the source space and releasing the partial clone instead of leaving forwarding links or actor lists broken.6 Ordinary examples almost never hit these paths, so having repeatable sanitizer and fault-injection builds is what makes it practical to keep regressions out.
Parts of this cleanup started back on the 6.3.0 branch, where platform-specific threading gave way to standard C++ threads, statistics counters were widened for long searches, the test suite gained parallel execution, and a solution-queue leak in parallel search was fixed.7 Version 6.4.0 builds on that with current Windows, macOS, and Linux CI coverage.
Compatibility changes to check
Three changes are worth checking before upgrading an existing build:
- Releases are source-only; there are no prebuilt Windows installers or macOS disk images for 6.4.0.
- The old
qecodeandquacodecontrib modules have been removed from the repository and release archive, so projects relying on them need to stay on an older release or maintain them separately. - The public
GECODE_FLATZINC_VERSIONmacro is gone. It described a fixed FlatZinc language version, whereas current MiniZinc integration is capability-based; useGECODE_VERSIONfor the Gecode release and the installed MiniZinc solver metadata for FlatZinc capabilities.
Static Windows clients that still spell the macro GIST_STATIC_LIBS continue to work, though GECODE_STATIC_LIBS remains the preferred name.
Getting the release
Gecode 6.4.0 is available from the Gecode download page, the GitHub release, or directly from the release-6.4.0 tag.
For the full list of changes, see the 6.4.0 and 6.3.0 changelog. The reference documentation and Modeling and Programming with Gecode have also been rebuilt for the release.
-
The Gecode implementation of
on_restartwas contributed by Jip J. Dekker. The interface builds on Solver-Independent Large Neighbourhood Search. ↩ -
The Gecode implementation was contributed by Jip J. Dekker. The interface is described in Defining Propagators in MiniZinc, by Jip J. Dekker, Peter J. Stuckey, Guido Tack, Huu Quang Tran, and Markus Wagner. ↩
-
Thanks to Helmut Simonis for discovering the problem with sparse domains while working on Modeling the Inglenook Shunting Puzzle, co-authored with Luis Quesada. The Inglenook model prompted the sparse
TupleSetrepresentation and automatic representation selection described here. ↩ -
The dual-feasible-function propagation was contributed by Fabio Tardivo. It is based on the lower-bound portfolio described in CP for Bin Packing with Multi-Core and GPUs, by Fabio Tardivo, Laurent Michel, and Enrico Pontelli. ↩
-
Pierre Talbot reported the unbounded-float case in issue #164 that exposed the overflow in the interval-median calculation. ↩
-
Kris Coester and Alexander Shepil from SAP contributed the original exception-safety and allocation-failure work in PR #211. SAP has described how it uses Gecode for advanced variant configuration. ↩
-
Alexis LG contributed the fix for the parallel-search solution-queue leak reported in issue #156. ↩