split buckets above 2^20 bytes when possible
This commit is contained in:
parent
1bd9467a2d
commit
9fd80e3193
@ -41,6 +41,8 @@ FORCE_INLINE void BN(splitTo)(EmptyValue* c, i64 from, i64 to, bool notEqual) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
static NOINLINE void* BN(allocateMore)(i64 bucket, u8 type, i64 from, i64 to) {
|
static NOINLINE void* BN(allocateMore)(i64 bucket, u8 type, i64 from, i64 to) {
|
||||||
|
if (from >= ALSZ) from = ALSZ;
|
||||||
|
if (from < (bucket&63)) from = bucket&63;
|
||||||
u64 sz = BSZ(from);
|
u64 sz = BSZ(from);
|
||||||
CHECK_INTERRUPT;
|
CHECK_INTERRUPT;
|
||||||
|
|
||||||
@ -100,7 +102,7 @@ NOINLINE void* BN(allocS)(i64 bucket, u8 type) {
|
|||||||
i64 from = to;
|
i64 from = to;
|
||||||
EmptyValue* c;
|
EmptyValue* c;
|
||||||
while (true) {
|
while (true) {
|
||||||
if (from >= ALSZ) return BN(allocateMore)(bucket, type, from, to);
|
if (from >= 63) return BN(allocateMore)(bucket, type, from, to);
|
||||||
from++;
|
from++;
|
||||||
if (buckets[from]) {
|
if (buckets[from]) {
|
||||||
c = buckets[from];
|
c = buckets[from];
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user