You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running operator folding on MovieSwiftUI takes as long as parsing. That really shouldn’t be the case. Running with Instruments shows that we spend the majority of time in memory-related operations.
The first steps to take would be:
Add an arena parameter to all the syntax node initializers
Add an arena parameter to SyntaxRewriter
Construct all nodes in SyntaxRewriter and operator folding in that arena
Investigate where else SyntaxRewriter is causing memory allocations and try to eliminate them
Attached is a WIP diff where I started to eliminate some of the memory allocations by SyntaxRewriter but I stopped once I realized that we’d need to modify the initializers of all syntax nodes.
Running operator folding on MovieSwiftUI takes as long as parsing. That really shouldn’t be the case. Running with Instruments shows that we spend the majority of time in memory-related operations.
The first steps to take would be:
arena
parameter to all the syntax node initializersarena
parameter toSyntaxRewriter
SyntaxRewriter
and operator folding in that arenaSyntaxRewriter
is causing memory allocations and try to eliminate themAttached is a WIP diff where I started to eliminate some of the memory allocations by
SyntaxRewriter
but I stopped once I realized that we’d need to modify the initializers of all syntax nodes.reduce-arena-memory-allocations.txt
The text was updated successfully, but these errors were encountered: