Skip to content

Commit

Permalink
Tweak the GC trigger for the cht
Browse files Browse the repository at this point in the history
Relates to #79.
  • Loading branch information
tatsuya6502 committed Feb 2, 2022
1 parent f9e0e53 commit 57b2aa5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/cht/map/bucket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ impl RehashOp {
let tbc = tombstone_count.load(Ordering::Relaxed) as f64;
let len = len.load(Ordering::Relaxed) as f64;

if tbc / real_cap >= 0.1 {
if tbc >= 25_000.0 || tbc / real_cap >= 0.1 {
if len - tbc < quarter_cap && quarter_cap as usize >= BUCKET_ARRAY_DEFAULT_LENGTH {
return Self::Shrink;
} else {
Expand Down

0 comments on commit 57b2aa5

Please sign in to comment.