Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

performance penalty using case insensitivity

by filmo (Scribe)
on Aug 21, 2001 at 21:25 UTC ( [id://106653]=perlquestion: print w/replies, xml ) Need Help??

filmo has asked for the wisdom of the Perl Monks concerning the following question:

I was reading 'Mastering Regular Expression' and it stated that using 'i' for case insensitivity paid a large performance penalty. Is that still the case with the most recent versions of Perl? (the book was written in 1997)

Replies are listed 'Best First'.
Re: performance penalty using case insensitivity
by mirod (Canon) on Aug 21, 2001 at 22:08 UTC

    The performance penalty is still there. It is even more important in recent versions of perl as it prevents most optimisation from being performed. So by using it you loose a lot of the work that has been done to speed-up common regexps.

    Which does not mean that it is a problem in most cases. When in doubdt use Benchmark!

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (5)
As of 2024-03-28 19:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found