malaigo has asked for the wisdom of the Perl Monks concerning the following question:
I have Perl on a Apple M1 Max Mac laptop (2021) and a Core i9 Mac laptop (2018). I assumed Perl compiled for arm64 would run much faster than Perl for x86_64.
With regex, it doesn't seem to be the case. The one-liner I used was time perl -e '$n = shift; $na = "a" x $n; print $na =~ /(a?){$n}a{$n}/' X where X ranges over 5,10,15,20,24,30 etc.
Results graphed at sandiway.arizona.edu/temp/538/perl%20comparison.png
EDIT: direct link
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Perl regex speed
by jwkrahn (Abbot) on Oct 25, 2022 at 08:08 UTC | |
by malaigo (Novice) on Oct 25, 2022 at 21:47 UTC | |
|
Re: Perl regex speed
by cavac (Prior) on Oct 25, 2022 at 08:01 UTC | |
by malaigo (Novice) on Oct 25, 2022 at 21:49 UTC | |
by cavac (Prior) on Oct 27, 2022 at 10:19 UTC | |
|
Re: Perl regex speed
by dave_the_m (Monsignor) on Oct 25, 2022 at 17:51 UTC | |
by malaigo (Novice) on Oct 25, 2022 at 21:51 UTC | |
by dave_the_m (Monsignor) on Oct 26, 2022 at 08:29 UTC | |
by malaigo (Novice) on Oct 27, 2022 at 03:07 UTC | |
by Anonymous Monk on Oct 27, 2022 at 06:42 UTC | |
| |
|