Open nbp opened 4 years ago
One note, is that the allocated blocks are the bump-allocator blocks which are allocated when a new block is needed.
This reports might be an artifact of the first block allocation being caused by the allocation of an IdentifierExpression
and not really accounting for the fact that IdentifierExpression
represents that many allocations.
This could be verified by replacing the bump allocator implementation by an ordinary allocation.
When testing the parsers without the bytecode emitter using
smoosh_tools bench
, Valgrind DHat tool reports that:One idea would be to not allocate an
IdentifierExpression
but either reuse theIdentifier
as-is or annotate it with a flag to validate that this is anIdentifierExpression
.