September 2018 Archives

My grant work in August focused on improving the performance of a number of very commonly used constructs in Perl 6 programs, of note array and hash access, box/unbox operations (which take place inside many of the builtins), and various common operations on Int (the default integer type in Perl 6, which is arbitrary precision). My work also uncovered a problem that could be best addressed with a small language design tweak, and I wrote up a proposal on that (which has since gained broad acceptable, and will be implemented for Perl 6.d).

I also made various improvements to the optimization infrastructure. Most notably, I made it possible to track what is known about the value coming into a guard vs. its state after the guard (guards are the things that ensure a speculative optimization still applies, and deoptimize if not). This most usefully allows for elimination of guards (for example, when program anlaysis - perhaps after inlining - proves a property that was guarded, then we can remove the guard). However, this change also means we properly deal with facts before/after the guard point; earlier we'd not tracked this precisely in a few cases and so had to forego optimization opportunities. Now we can take them.

I also improved GC behavior a bit, making values assigned into long-lived aggregates get promoted sooner and making the optimizer thread join in with GC in a more timely manner.

Finally, there was a range of other smaller optimizations, as well as a good amount of bug hunting/fixing.

1:12    Decrease GC latency during specialization, 
        so that we won't block it so long while optimizing longer frames
13:25   Lots of speedups to hash and array access and storage, 
        giving some notable benchmark wins
5:19    Refactor guards so we can track facts before/after, 
        allowing for redundant guard elimination
1:47    Pass on facts from return types when inlining, 
        allowing further guard elimination
0:23    Generate less decont instructions when compiling calls
0:25    Tweak code-gen for calls to put callee lookup closer to call when possible, 
        shortening lifetime of it
1:11    Research and write up proposal for changing the default scoping of $_ in v6.d
7:42    Improve performance of common box/unbox operations, including to a Perl 6 Int
8:15    Improvement of addition, subtraction, and multiplication of Perl 6 Int, 
        removing indirections and improving JIT for the non-bigint case
9:38    Implement a spesh plugin for return type checks, 
        reducing code size and allowing some speedups
0:25    Fix a DEPRECATED crash when a backtrace misses some frames
0:58    Track down and fix a SEGV when a debug type name was set from 
        multiple threads
1:02    Fix a segfault in basic block elimination's annotation movement
1:10    Improve GC handling of programs placing objects into long-lived aggregates
6:23    Fix various deoptimization bugs
0:58    Correct how log guards are handled at a PHI to avoid incorrect deletions 
        of guards that were depended on beyond the PHI
1:02    Optimize takedispatcher into an nqp::null on inlining where possible
2:32    Investigate a module regression due to serialization and repossession 
        related changes; fix it
3:42    More aggressive optimization of inlines and better size handling
1:52    Assorted small optimizations in Rakudo and with hllize elimination
8:32    Other assorted debugging, fixing, and testing

Work in the latter part of July, falling under the current round of the grant, focused mostly on hunting down and fixing bugs. A memory leak bug involving the thread pool scheduler was fixed; it was only problematic in some programs so far, but would have become far more noticeable with the new 6.d await semantics. Others fixes addressed regressions arising from recent optimization work, although in most cases the cause was more aggressive optimizations uncovering existing issues.

Last but not least, I started work on an important new optimization: partial escape analysis. This will, when working, enable us to elimiante many GC allocations and perform better analysis.

3:23    Fix a thread pool memory leak due to continuation 
        mis-handling
1:06    Re-instate Proxy return handling bug for the sake 
        of the module ecosystem
2:41    Complete first-class frame reference refactors to 
        make them better handle inlining
3:48    Hunt down a deoptimization bug; fix it by correcting 
        uninlining instruction motion
1:00    Fix return handlers of void calls
2:04    Fix a couple of GC rooting/barrier issues
5:03    Start design and implementation exploration for 
        partial escape analysis

This is a monthly report by Dave Mitchell on his grant under Perl 5 Core Maintenance Fund. We thank the TPF sponsors to make this grant possible.

I didn't spend all that many hours during August on perl work.

I spent most of my time looking at a bug related to restoring of captures
within regex repeats. During the course of that, I took the opportunity to
simplify and cleanup some of the code in S_regmatch() which deals with
captures, and in particular, make it consistently use macros which produce
debugging output when opening or closing or restoring capture indices.

SUMMARY:
     18:03 RT #133352 Ancient Regex Regression
      1:30 RT #133429 Time-HiRes/t/itimer.t: intermittent failures
      1:36 RT #133441 no assignment to "my" variable  
    ------
     21:09 TOTAL (HH::MM)  


 254.7 weeks
3151.4 total hours
  12.4 average hours per week

There are 315 hours left on the grant

Call for Grant Proposals (September 2018 Round)

The Grants Committee is accepting grant proposals all the time. We evaluate them every two months and another evaluation period is upon us.

The first public release! Code is now hosted in GitHub. Please see the instructions on how to install and run.

The release features a renewed "Routines" tab. Please read Timo's blog post to know how it compares to the previous profiler: The first public release!.

Maintaining Perl 5 (Tony Cook): August 2018 Grant Report

This is a monthly report by Tony Cook on his grant under Perl 5 Core Maintenance Fund. We thank the TPF sponsors to make this grant possible.

Approximately 44 tickets were reviewed, and 4 patches were applied.

[Hours]         [Activity]
  1.23          #p5p discussion with khw on shared hash problem
  4.73          #132158 testing, debugging, work on a fix, more testing
                #132158 consider other fixes, testing, comment with
                patches
  1.60          #132655 (sec) work on test code, produce a fix and a
                patch, comment with patch
  0.72          #132683 re-check patch, test and apply to blead
  0.35          #133002 review, make public, merge into 132609
  1.71          #133204 (sec) research, comment
                #133204 (sec) comment
  0.30          #133250 (sec) review, comment
  0.37          #133292 review and briefly comment
  1.87          #133314 work on test code
                #133314 more testing, apply to blead
  8.73          #133326 debugging, work on fixes
                #133326 more work on fixes, testing
                #133326 debugging, clean up, testing
                #133326 polish, commit message, comment with patch
                #133326 re-test, apply to blead
  0.40          #133331 (sec) review, ask for more information
                #133331 (sec) briefly comment
  2.45          #133334 (sec) debugging
                #133334 (sec) debugging
                #133334 (sec) comment
  0.05          #133335 (sec) brief testing and comment
  0.95          #133345 (sec) testing, comment
  0.95          #133376 review patch, test build, testing, apply to blead
  0.07          #133406 (sec) comment and close
  0.55          #133417 review patches, original discussion, comment about
                the commit messages
                #133417 review, research and comment
  2.29          #133422 review ticket, look over code
                #133422 work on a fix
                #133422 more work on fix, testing
  0.38          #133423 (sec) private IRC discussion with khw
  0.30          #133431 review and briefly comment
  0.55          apm821xx cross build thread, research, comment
  0.47          Briefly review khw’s khw-core branch
  0.95          hacking on feature.h thread, review code, testing, comment
  2.07          reply sawyer email on unicode filenames on Win32
  1.88          review maint-votes, add some commits, cherry pick/test two
                commits
  0.37          review security issues, make 133345 public
  0.77          review security queue
  1.53          security queue review/clean up
  0.33          security ticket round up
  1.17          utf8_readline: consider optimizations
  1.38          utf8_readline: croak tests, add another test and find a
                bug
  1.45          utf8_readline: debug/fix surrogate bug, more tests
  2.98          utf8_readline: debugging, fix short handling bug, more
                testing, find surrogate handling issue, debugging, croak
                on surrogate bug
  1.87          utf8_readline: debugging, possible fix, testing
  1.72          utf8_readline: debugging, testing, debug a test failure
                and consider possible fixes
  1.87          utf8_readline: more optimizing non-mutating stream
  2.45          utf8_readline: more optimizing, building/testing + #p5p
                discussion of tainted \p{} property names with khw
  2.08          utf8_readline: more tests
  1.27          utf8_readline: polish, testing
  0.58          utf8_readline: rebase, testing, review
  1.83          utf8_readline: simplify some code based (oldish)
                discussions with khw, testing
  1.90          utf8_readline: work on fix for optimized code consuming
                input incorrectly
  1.53          utf8_readline: work on optimizing non-mutating stream
  2.63          utf8_readline: write more tests,clean up some of the
                polish
======
 65.63 hours total

July 2018 Grant Votes

The Grants Committee has concluded the voting of the July 2018 round. My apologies for the delay.

There was one proposal this round, which was not approved.

About TPF

The Perl Foundation - supporting the Perl community since 2000. Find out more at www.perlfoundation.org.

About this Archive

This page is an archive of entries from September 2018 listed from newest to oldest.

August 2018 is the previous archive.

October 2018 is the next archive.

Find recent content on the main index or look in the archives to find all content.

Pages

OpenID accepted here Learn more about OpenID
Powered by Movable Type 6.2.2