Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re^4: Compiling Regular Expressions

by diotalevi (Canon)
on Feb 19, 2003 at 14:32 UTC ( #236640=note: print w/replies, xml ) Need Help??

in reply to Re: Re: Re: Compiling Regular Expressions
in thread Compiling Regular Expressions

A reading of _Mastering Regular Expressions_ leaves me with the impression that sometimes study() speeds things up but other times it just slows things down. So its actual behaviour on performance is likely dependant on your data, your regexes (which is also another sort of data) and then how often each data+regex combination is used. The way M_R_E leaves things, I'm not even sure you can arrive at any sort of truth by using benchmarks. Or... you can arrive at a local definition of truth only by testing your specific data + your specific regexes together.

The general idea is that a generalized benchmark for study() is invalid.

Seeking Green geeks in Minnesota

Replies are listed 'Best First'.
Re^5: Compiling Regular Expressions
by hv (Parson) on Feb 19, 2003 at 14:43 UTC

    It should also be noted that study() is not as well tested in perl as it ought to be, and as a result changes to the regexp engine over the years have managed to introduce various problems that cause study() not to gain as much speed as it should, and in some cases even give the wrong answer.

    In particular, I don't think study() knows anything about Unicode (though I haven't checked).

    The plan is that 5.10.0 should involve a big cleanup of the regexp engine, so this may improve in the future.


Log In?

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

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (1)
As of 2022-01-29 02:33 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (74 votes). Check out past polls.