Skip to content

Commit f9cd820

Browse files
committed
Update CaDiCaL from 1.4.1 to 1.5.3
Maintenance update to the latest release, no notable performance differences expected or observed. Also patch out the comparison of `this` against `NULL`, which we reported upstream as arminbiere/cadical#54. Fixes: #7725
1 parent d5e13f1 commit f9cd820

File tree

3 files changed

+22
-11
lines changed

3 files changed

+22
-11
lines changed

scripts/cadical-1.4.1-patch renamed to scripts/cadical-1.5.3-patch

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,3 +32,14 @@ index 9e8a16b..3d5721a 100644
3232
cubes.cubes.push_back(std::vector<int>());
3333
return cubes;
3434
}
35+
diff -urN cadical-rel-1.5.3/src/solver.cpp cadical-rel-1.5.3.patched/src/solver.cpp
36+
--- cadical-rel-1.5.3/src/solver.cpp 2023-02-13 09:11:26.000000000 +0000
37+
+++ cadical-rel-1.5.3.patched/src/solver.cpp 2023-05-29 09:42:55.871965742 +0000
38+
@@ -258,7 +258,6 @@
39+
40+
#define TRACE(...) \
41+
do { \
42+
- if ((this == 0)) break; \
43+
if ((internal == 0)) break; \
44+
LOG_API_CALL_BEGIN (__VA_ARGS__); \
45+
if (!trace_api_file) break; \

src/Makefile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -174,17 +174,17 @@ glucose-download:
174174
@(cd ../glucose-syrup; patch -p1 < ../scripts/glucose-syrup-patch)
175175
@$(RM) $(glucose_rev).tar.gz
176176

177-
cadical_release = rel-1.4.1
177+
cadical_release = rel-1.5.3
178178
cadical-download:
179179
@echo "Downloading CaDiCaL $(cadical_release)"
180180
@$(DOWNLOADER) https://github.com/arminbiere/cadical/archive/$(cadical_release).tar.gz
181181
@$(TAR) xfz $(cadical_release).tar.gz
182182
@rm -Rf ../cadical
183183
@mv cadical-$(cadical_release) ../cadical
184-
@(cd ../cadical; patch -p1 < ../scripts/cadical-1.4.1-patch)
184+
@(cd ../cadical; patch -p1 < ../scripts/cadical-1.5.3-patch)
185185
@(cd ../cadical && ./configure)
186-
# Need to rename VERSION so that it isn't picked up by `#include<version>` on
187-
# macOS which is case insensitive
186+
# Need to rename VERSION so that it isn't picked up by `#include<version>` on
187+
# macOS which is case insensitive
188188
@(cd ../cadical && mv VERSION VERSION.txt)
189189
@$(RM) $(cadical_release).tar.gz
190190

src/solvers/CMakeLists.txt

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -110,11 +110,11 @@ foreach(SOLVER ${sat_impl})
110110
message(STATUS "Building solvers with cadical")
111111

112112
download_project(PROJ cadical
113-
URL https://github.com/arminbiere/cadical/archive/rel-1.4.1.tar.gz
114-
PATCH_COMMAND patch -p1 -i ${CBMC_SOURCE_DIR}/../scripts/cadical-1.4.1-patch
113+
URL https://github.com/arminbiere/cadical/archive/rel-1.5.3.tar.gz
114+
PATCH_COMMAND patch -p1 -i ${CBMC_SOURCE_DIR}/../scripts/cadical-1.5.3-patch
115115
COMMAND cmake -E copy ${CBMC_SOURCE_DIR}/../scripts/cadical_CMakeLists.txt CMakeLists.txt
116116
COMMAND ./configure
117-
URL_MD5 b44874501a175106424f4bd5de29aa59
117+
URL_MD5 265b1a715000ed3c5b6de36ddd1278a0
118118
)
119119

120120
add_subdirectory(${cadical_SOURCE_DIR} ${cadical_BINARY_DIR})
@@ -133,10 +133,10 @@ foreach(SOLVER ${sat_impl})
133133
message(STATUS "Building with IPASIR solver linking against: CaDiCaL")
134134

135135
download_project(PROJ cadical
136-
URL https://github.com/arminbiere/cadical/archive/rel-1.4.1.tar.gz
137-
PATCH_COMMAND true
138-
COMMAND CXX=${CMAKE_CXX_COMPILER} ./configure -O3 -s CXXFLAGS=-std=c++14
139-
URL_MD5 b44874501a175106424f4bd5de29aa59
136+
URL https://github.com/arminbiere/cadical/archive/rel-1.5.3.tar.gz
137+
PATCH_COMMAND patch -p1 -i ${CBMC_SOURCE_DIR}/../scripts/cadical-1.5.3-patch
138+
COMMAND ./configure
139+
URL_MD5 265b1a715000ed3c5b6de36ddd1278a0
140140
)
141141

142142
message(STATUS "Building CaDiCaL")

0 commit comments

Comments
 (0)