Revisit default vector sizes in CompilationState
Categories
(Core :: JavaScript Engine, task, P2)
Tracking
()
Tracking | Status | |
---|---|---|
firefox88 | --- | fixed |
People
(Reporter: tcampbell, Assigned: tcampbell)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
The vectors in js::frontend::CompilationState
currently have no default capacity. Since we always copy to LifoAlloc at the end, and the state is on stack, it is a good opportunity to use default capacities.
We should be able to dump stats at the end of each compilation (probably biased by delazification). Then we can look at distribution of those stats and pick some thresholds.
Assignee | ||
Comment 1•4 years ago
|
||
This stencil is stack allocated, so reserving a small number of inline vector
elements can avoid allocations in most cases. The chosen values favour
delazifcation scenarios which are by far the most common source of stencil.
Every compilation has at least one scope+script and 80% of delazifications
only have one of each. GCThings are more distributed, but 8 covers 75% of
cases over some very large scripts on common websites. These reservations add
approximately 80 bytes to the stack frame.
Updated•4 years ago
|
Comment 3•4 years ago
|
||
bugherder |
Description
•