Perl 5.28 boolean check become fast

Perl 5.28 boolean check become fast.


This branch contains about 50 commits, which collectively optimise various aspects of perl's behaviour when detailing with boolean values or ops that are called in boolean context.

various boolean-related optimisations - perl.git


Bencmark is very good!


   36 @  96.55% ..  99.99%
  245 @ 100.00% .. 100.99%
   28 @ 101.00% .. 109.99%
    7 @ 110.00% .. 119.99%
   10 @ 120.00% .. 129.99%
   29 @ 130.00% .. 199.99%
    4 @ 200.00% .. 299.99%
    1 @ 314.29%

so about 10% of tests became marginally slower - usually due to one extra
conditional in an op to test for a private BOOL flag or ReANY(); about 70%
of tests were almost unaffected, while 20% of tests showed improvement,
most with considerable improvement, and a few with spectacular improvement.
(The 314% is for an empty @lexical tested in boolean context).
various boolean-related optimisations - perl.git

Leave a comment

About Yuki Kimoto

user-pic I'm Perl Programmer. I LOVE Perl. I want to contribute Perl community and Perl users.