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

Re^4: Using functional programming to reduce the pain of parallel-execution programming (with threads, forks, or name your poison)

by tphyahoo (Vicar)
on Oct 25, 2006 at 16:12 UTC ( #580616=note: print w/replies, xml ) Need Help??


in reply to Re^3: Using functional programming to reduce the pain of parallel-execution programming (with threads, forks, or name your poison)
in thread Using functional programming to reduce the pain of parallel-execution programming (with threads, forks, or name your poison)

>> Therefore if you really don't want to convert function >> calls then I'd use something like Parallel::ForkManager >> and build my own solution.

I did this at Using DBM::Deep and Parallel::ForkManager for a generalized parallel hashmap function builder (followup to "reducing pain of parallelization with FP")

The difficulty was getting my mapped result set back into a hashref that I could return at the end of the function, after all my child processes finished. I wound up "re agglomerating" my hash by storing the results of each function call on the hard drive with DBM::Deep.

I wound up needing to use a separate DBM::Deep file for each element of the hash, as I was unable to do this with a single DBM::Deep file, although I attempted to take advantage of locking support.

I wonder if there are other ways, including perhaps your previous suggestion to use ipc open3, perhaps bypassing having to store stuff on the hard drive completely. to be continued...

  • Comment on Re^4: Using functional programming to reduce the pain of parallel-execution programming (with threads, forks, or name your poison)
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://580616]
help
Chatterbox?
[Lady_Aleena]: Discipuluis, I don't know if I want to fight with File::Find. File::Find and I are not friends.
[Discipulus]: 4 day Bach is too muche even for me
[Discipulus]: LA you know who is paco?
[Lady_Aleena]: Disc, nope.
[Discipulus]: ahi ahi ahi!!
[Lady_Aleena]: paco is a little over 2 years before my time.
[Discipulus]: you can try tachyon's iterative approach Re: Win32 Recursive Directory Listing
[Lady_Aleena]: I'm on Linux/
[beech]: isn't 2 year about standard recovery time for that kind of surgery?
[Discipulus]: if you hate FIle::Find

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (13)
As of 2017-04-23 20:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I'm a fool:











    Results (432 votes). Check out past polls.