Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: Optimizing perl code performance

by QM (Parson)
on Aug 17, 2015 at 09:33 UTC ( #1138861=note: print w/replies, xml ) Need Help??


in reply to Re: Optimizing perl code performance
in thread Optimizing perl code performance

I'm wondering if a regExp would be faster than split.
split takes a regex, so an optimized regex similar to the split could only be marginally better, and potentially much worse, especially for simple cases like this.

Likewise chomp is very simple, and is probably zillions of times faster than IO.

Profile, then fiddle. Lather, rinse, repeat.

-QM
--
Quantum Mechanics: The dreams stuff is made of

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (3)
As of 2020-12-05 09:45 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How often do you use taint mode?





    Results (63 votes). Check out past polls.

    Notices?