CVarBucketsResize
function · cvar · primitive
- Address
0x63ec40· 317 bytes, up to0x63ed7c- Signature
void __thiscall (void *this, uint32_t count)- Meaning
- Sets the bucket count, rounding the capacity up and making new buckets empty
- Confidence
- verified, proof two
- Finding
- cvar/containers#growth
Finding: Growth in cvar: containers
The first insertion makes four buckets with mask 3. Before each later insertion the table calls
0x63e9f0 with the bucket index; it returns 1 when it grew. The call lowers the chain counter by 3 (to 0 if it is below 4),
adds 1 for each object it walks in that bucket, and grows when an increment takes it past 13 (an empty bucket never grows), unless the mask is already 0x1fff. Growth
unlinks every object into a temporary list in bucket order, resizes the vector to twice the buckets, empties all of
them with link offset 4, sets the mask to the new count minus one, and links each object at the end of
its new bucket.
The derivation is in the doc.
Callers 1
- CVarTableRehash cvar
Callees 3
- CVarLinkUnlink cvar
- CVarLinkBackSlot cvar
- CVarBucketsRealloc cvar
Calls and jumps by a bare address, from tables/calls.tsv.