Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: Forking Multiple Regex's on a Single String

by tilly (Archbishop)
on Aug 19, 2006 at 23:09 UTC ( [id://568402]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Forking Multiple Regex's on a Single String
in thread Forking Multiple Regex's on a Single String

My understanding is that it kind of works, but fork is very heavyweight on Windows. And is implemented using threading, which may reduce how much the scheduler will want to schedule it on multiple CPUs. Therefore I wouldn't expect the same performance benefits from fork under Windows that I would on Unix, Linux, or OS X.

Then again, as always, this is dated information from someone who doesn't use Windows. This may have changed, improved, etc. But if it has, I am not aware of it.

  • Comment on Re^3: Forking Multiple Regex's on a Single String

Replies are listed 'Best First'.
Re^4: Forking Multiple Regex's on a Single String
by GrandFather (Saint) on Aug 19, 2006 at 23:17 UTC

    I don't know how the module may be implemented on Windows. However I do know that Windows is happy to allocate threads for the same process to different CPUs. There are other issues with fork under Windows that may incure a startup cost per fork, but shouldn't make much difference during the subsequent execution of the forked process.


    DWIM is Perl's answer to Gödel
      It is good to know that Windows will allocate threads for the same process to different CPUs.

      As for the other issues, since the strategy that I was suggesting involved lots of forks, that startup cost is relevant.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (5)
As of 2024-04-19 02:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found