Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^12: Modernizing the Postmodern Language?

by syphilis (Archbishop)
on Jul 07, 2020 at 03:01 UTC ( [id://11118989]=note: print w/replies, xml ) Need Help??


in reply to Re^11: Modernizing the Postmodern Language?
in thread Modernizing the Postmodern Language?

I can't remember right now if Perl optimizes this in recent releases.

I don't think so - and same goes for raku, apparently.
On Ubuntu-20.04 (perl-5.32.0):
$ perl -le '$x = time;for (1..1000000000) {}; print time - $x;' 51
On Windows7 (perl-5.32.0):
C:\>perl -le "$x = time;for (1..1000000000) {}; print time - $x;" 13
The Windows box is about twice as fast as the Ubuntu box, so I'm not sure why the difference in this case is a factor of 4.

Anyway, thankfully perl has XS/Inline::C at hand to enable sane and efficient handling for cases such as these.

Cheers,
Rob

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11118989]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chilling in the Monastery: (2)
As of 2024-04-26 07:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found