This was originally reported on PerlMonks: https://www.perlmonks.org/index.pl?node_id=11153747
A performance regression introduced in Perl 5.28 causes this script to execute ~20x-40x slower on Windows:
use strict;
use warnings;
use feature 'say';
use Time::HiRes 'time';
my $x = 'a' x 1e6;
my $y = 'b' . $x;
my $t = time;
$x =~ s/./$&-/g;
say time - $t;
$t = time;
$y =~ s/./$&-/g;
say time - $t;
say $^V;
Here are the results:
12.7103209495544
0.850119113922119
v5.32.1
12.7171239852905
0.765337944030762
v5.28.2
0.345196962356567
0.314804077148438
v5.26.3
I can confirm the issue is still present in blead.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4