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

Re: Is it File::Map issue, or another 'helpful' Perl regex optimization? (neither)

by Anonymous Monk
on Mar 18, 2017 at 00:04 UTC ( [id://1185092]=note: print w/replies, xml ) Need Help??


in reply to Is it File::Map issue, or another 'helpful' Perl regex optimization?

Hi

Its neither,

That is to say, you can't tell what it is, or what its supposed to be

Consider https://metacpan.org/source/LEONT/File-Map-0.64/examples/fastsearch.pl, it uses https://metacpan.org/pod/File::Map#*-advise-$lvalue,-$advice

  • Comment on Re: Is it File::Map issue, or another 'helpful' Perl regex optimization? (neither)

Replies are listed 'Best First'.
Re^2: Is it File::Map issue, or another 'helpful' Perl regex optimization? (neither)
by vr (Curate) on Mar 18, 2017 at 00:15 UTC

    Adding advise( $s, 'sequential' ); made no difference :( - I mean, in terms of consumed memory.

      :)

      the module seems vague on claims and evidence, but ,

      I just did some testing, and I get these numbers just loading a 51mb file I create

      You'll need memusage-workingset-virtualmemory.pl to run it yourself

      So, when you map, seems to signal to the OS this is how big the memory usage is going to go (WVM field), and then the working set slowly increases up to the size of the file as the regular expression advances through the whole file "line" by line

      Is this faster than something else? More memory efficien? I dunno

      I'm beginning to suspect this is how File::Map is supposed to work

        Thank you, I'll digest this for a while

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (5)
As of 2024-04-23 22:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found