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

Re^3: Design advice: Classic boss/worker program memory consumption

by moritz (Cardinal)
on May 21, 2014 at 05:47 UTC ( #1086904=note: print w/ replies, xml ) Need Help??


in reply to Re^2: Design advice: Classic boss/worker program memory consumption
in thread Design advice: Classic boss/worker program memory consumption

You also lose all that efficiency when you start to read a lot of data structures in perl, because reading data ca n increase the reference counters, thus a write actually happens in the background, causing the operating system to copy the pages.

So, don't assume stuff is memory unfriendly. Measure it. In your context, where it matters.

Also, starting a new perl interpreter takes about 0.017s "cold" on my machine, and 0.002s when cached. Compared to a 1 minute run time of a worker thread, that's like 0.03% (cold) or 0.003% (warm) - nothing to worry about.


Comment on Re^3: Design advice: Classic boss/worker program memory consumption

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (13)
As of 2015-07-06 12:07 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 (73 votes), past polls