mirror of
https://github.com/dart-lang/sdk
synced 2024-09-19 20:51:50 +00:00
f0941f7c7d
Summary: Previously, we would create a wrapper function in the flowgraph around converted closures, which would forward all the closure's arguments and unpack the context argument before calling the real closure function. Now, we perform the unpacking at the top of the real function to avoid having any wrapper function. Previously, captured parameters would still be appear live to the GC even if they're updated, because after they are copied into the context, all updates to them are done there. Now, as in regular closures, we zero-out the parameter variable after copying it's value into the context, avoiding potential memory leaks. Test Plan: Ran the closure conversion test suite. Ran benchmarks on Golem -- all statistically significant regressions are gone. BUG= R=dmitryas@google.com, regis@google.com Review-Url: https://codereview.chromium.org/3008923002 . |
||
---|---|---|
.. | ||
closures | ||
closures_initializers | ||
closures_type_vars | ||
interpreter | ||
reify | ||
.gitignore |