Skip to content

Commit 10464db

Browse files
committed
Updating.
1 parent 6410b77 commit 10464db

File tree

2 files changed

+4
-328
lines changed

2 files changed

+4
-328
lines changed

dependencies/xor_singleheader/include/binaryfusefilter.h

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,9 @@ static inline uint32_t binary_fuse8_calculate_segment_length(uint32_t arity,
113113
// These parameters are very sensitive. Replacing 'floor' by 'round' can
114114
// substantially affect the construction time.
115115
if (arity == 3) {
116-
return ((uint32_t)2) << (int)(floor(0.831 * log((double)(size)) + 0.75 +
117-
0.5));
116+
return ((uint32_t)1) << (int)(floor(log((double)(size)) / log(3.33) + 2.25));
118117
} else if (arity == 4) {
119-
return ((uint32_t)1) << (int)(floor(0.936 * log((double)(size)) - 1 + 0.5));
118+
return ((uint32_t)1) << (int)(floor(log((double)(size)) / log(2.91) - 0.5));
120119
} else {
121120
return 65536;
122121
}
@@ -132,9 +131,9 @@ double binary_fuse8_max(double a, double b) {
132131
static inline double binary_fuse8_calculate_size_factor(uint32_t arity,
133132
uint32_t size) {
134133
if (arity == 3) {
135-
return binary_fuse8_max(1.125, 0.125 + log((double)1000000) / log((double)size));
134+
return binary_fuse8_max(1.125, 0.875 + 0.25 * log(1000000.0) / log((double)size));
136135
} else if (arity == 4) {
137-
return binary_fuse8_max(1.075, 0.77 + 4.06 / log((double)size));
136+
return binary_fuse8_max(1.075, 0.77 + 0.305 * log(600000.0) / log((double)size));
138137
} else {
139138
return 2.0;
140139
}

dependencies/xor_singleheader/include/fusefilter.h

Lines changed: 0 additions & 323 deletions
This file was deleted.

0 commit comments

Comments
 (0)