October report of the Perl 6 Development Grant of Jonathan Worthington
Fri, 02-Nov-2018 by
Matthias Bloch
edit post
Jonathan writes:
My performance work in October focused for the most part on escape analysis and scalar replacement.
This work remains in a branch, however it has now reached the milestone of performing its first couple of real-world optimizations, eliminating short-lived boxes and wrapper objects across inline boundaries. I also started with some long-planned work on more aggressive optimization of lexical variables, such that they are stored as "locals" where Rakudo can see they will never be accessed from outside of the current scope. This allows for slightly cheaper access, but more significantly much easier analysis in the specializer. This will later combine with the escape analysis work to eliminate many short-lived `Scalar` containers, which will in turn reduce the number of guards and allocations. I expect to merge both this work and the initial partial escape analysis and scalar replacement work in November.
On the reliability side of things, I tracked down a couple of problems relating to parametric types and precompilation. When we have a type like `Array[Int]`, many modules may declare it, but we need to ensure that - no matter which modules we load - we only end up with one instance of this type, so that they will match and be considered equal. This was, in some cases, not happening. Now it is.
10:08 Continue work on escape analysis and scalar replacement
3:34 Develop more aggressive lexical to local lowering
optimizations in the Rakudo optimizer (this will help all
backends, not just MoarVM)
4:28 Debug and fix problems involving parametric types and
precompilation
Total: 18:10
Total time spent on current grant period: 126:01
Total time remaining on current grant period: 73:59
Category:
(none)
Comments (0)