From 1272e304b6367c7dd94d25acf88b2843adabb93a Mon Sep 17 00:00:00 2001 From: Sebastiano Tronto Date: Sat, 5 Oct 2024 23:00:08 +0200 Subject: Fix rare data race I had some misconception about how _Atomic and const worked. This means the previous commit (expected distribution) could be incorrect. --- src/solvers/h48/solve.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/solvers/h48/solve.h') diff --git a/src/solvers/h48/solve.h b/src/solvers/h48/solve.h index 3948b15..c6fe8b7 100644 --- a/src/solvers/h48/solve.h +++ b/src/solvers/h48/solve.h @@ -8,8 +8,8 @@ typedef struct { int64_t maxsolutions; uint8_t h; uint8_t k; - const uint32_t *cocsepdata; - const uint8_t *h48data; + _Atomic const uint32_t *cocsepdata; + _Atomic const uint8_t *h48data; char **nextsol; uint8_t nissbranch; int8_t npremoves; -- cgit v1.3