diff options
author | Alan Wu <XrXr@users.noreply.github.com> | 2024-06-11 16:34:08 -0400 |
---|---|---|
committer | Alan Wu <XrXr@users.noreply.github.com> | 2024-06-13 13:00:46 -0400 |
commit | ffd895156f230e684bed36e0b3c724071ad31993 (patch) | |
tree | 6a7d3201d32ba542fe7a20aeb65993a92aede888 /test/prism/snapshots/range_begin_open_inclusive.txt | |
parent | 28d1685ebb44b3249e2bc6b859fa17cdaa5e5ef0 (diff) |
Calls to defer_compilation() leave behind a stub and a `struct Block`
that we retain. If the block is empty, it only exits to hold the
`struct Branch` that the stub needs.
This patch transplants the branch out of the empty block into the newly
generated block when the defer_compilation() stub is hit, and deletes
the empty block to save memory.
To assist the transplantation, `Block::outgoing` is now a
`MutableBranchList`, and `Branch::Block` now in a `Cell`. These types
don't incur a size cost.
On the `lobsters` benchmark, `yjit_alloc_size` is roughly 98% of what
it was before the change.
Co-authored-by: Kevin Menard <kevin.menard@shopify.com>
Co-authored-by: Randy Stauner <randy@r4s6.net>
Co-authored-by: Maxime Chevalier-Boisvert <maxime.chevalierboisvert@shopify.com>
Diffstat (limited to 'test/prism/snapshots/range_begin_open_inclusive.txt')
0 files changed, 0 insertions, 0 deletions