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

Answer: How to efficiently return the set of REGEX expressions matching 1 line of input?

( #38152=categorized answer: print w/ replies, xml ) Need Help??

Q&A > regular expressions > How to efficiently return the set of REGEX expressions matching 1 line of input? contributed by Anonymous Monk

You missed the point. What is the fastest way to test 100's of regex expressions against every line in a file? Here is what I've come up with:
# map REGEXs over line 72.328 user, 0.108 sys, 1:24.18 real, 86.0% cpu 0k text, 0k data+stack, 0k avg, 0k max 36 in, 3 out, 0 faults, 325 reclaims, 0 swaps # eval preformed REGEXs over line 196.128 user, 0.093 sys, 3:47.98 real, 86.0% cpu 0k text, 0k data+stack, 0k avg, 0k max 43 in, 3 out, 0 faults, 358 reclaims, 0 swaps # eval over preconstructed function 1.742 user, 0.030 sys, 0:02.00 real, 88.5% cpu 0k text, 0k data+stack, 0k avg, 0k max 19 in, 1 out, 0 faults, 329 reclaims, 0 swaps

Comment on Answer: How to efficiently return the set of REGEX expressions matching 1 line of input?
Download Code
Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2015-07-05 14:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (67 votes), past polls