private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && (reprobe_cnt >= reprobe_limit(len) || // More expensive check: see if the table is > 1/2 full. _slots.estimate_get() >= (len>>1)); }
private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && // More expensive check: see if the table is > 1/4 full. _slots.estimate_get() >= reprobe_limit(len); }
private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && (reprobe_cnt >= reprobe_limit(len) || // More expensive check: see if the table is > 1/2 full. _slots.estimate_get() >= (len>>1)); }
if( newsz <= oldlen && // New table would shrink or hold steady? tm <= topmap._last_resize_milli+10000 && // Recent resize (less than 1 sec ago) (q=_slots.estimate_get()) >= (sz<<1) ) // 1/2 of keys are dead? newsz = oldlen<<1; // Double the existing size
private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && (reprobe_cnt >= reprobe_limit(len) || // More expensive check: see if the table is > 1/2 full. _slots.estimate_get() >= (len>>1)); }
private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && // More expensive check: see if the table is > 1/4 full. _slots.estimate_get() >= reprobe_limit(len); }
private final boolean tableFull( int reprobe_cnt, int len ) { return // Do the cheap check first: we allow some number of reprobes always reprobe_cnt >= REPROBE_LIMIT && (reprobe_cnt >= reprobe_limit(len) || // More expensive check: see if the table is > 1/2 full. _slots.estimate_get() >= (len>>1)); }
if( newsz <= oldlen && // New table would shrink or hold steady? tm <= topmap._last_resize_milli+10000 && // Recent resize (less than 1 sec ago) (q=_slots.estimate_get()) >= (sz<<1) ) // 1/2 of keys are dead? newsz = oldlen<<1; // Double the existing size