I was encountering spurious errors "Merging non compatible filters" in _qf_multi_merge with key_bits = 64 and quotient = 20 bits. I traced it to a 64-bit overflow, as qf->metadata->range is 128-bit. The following change fixes it and it still passes the ctest --verbose unit test suite.
diff --git a/src/gqf.cpp b/src/gqf.cpp
index 606a5e9..3ef9c81 100644
--- a/src/gqf.cpp
+++ b/src/gqf.cpp
@@ -2808,7 +2808,7 @@ void _qf_multi_merge(QF *qf_arr[],int nqf, QF *qfr,
))
{
int i;
- uint64_t range=qf_arr[0]->metadata->range;
+ __uint128_t range=qf_arr[0]->metadata->range;
for (i=1; i<nqf; i++) {
if(qf_arr[i]->metadata->range!=range)
{