[Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Dusan Kolar
Dear all, I've thought the following three (dummy) programs would run some of their parts in parallel (on dual core) if compiled with option threaded (smp). The truth is that only the first one exploits multicore CPU. Why? Moreover, using RTS option -sstderr makes runtime not to evaluate

Re: [Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Bulat Ziganshin
Hello Dusan, Tuesday, March 25, 2008, 3:47:50 PM, you wrote: (smp). The truth is that only the first one exploits multicore CPU. Why? +RTS -N2 -- Best regards, Bulatmailto:[EMAIL PROTECTED] ___ Haskell-Cafe mailing

Re: [Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Roberto Zunino
Dusan Kolar wrote: Dear all, I've thought the following three (dummy) programs would run some of their parts in parallel (on dual core) if compiled with option threaded (smp). The truth is that only the first one exploits multicore CPU. Why? h1 - forkIO $ putMVar v1 $ fibs (n-1)

Re: [Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Dusan Kolar
I did use that option. :-) Dusan Bulat Ziganshin wrote: Hello Dusan, Tuesday, March 25, 2008, 3:47:50 PM, you wrote: (smp). The truth is that only the first one exploits multicore CPU. Why? +RTS -N2 ___ Haskell-Cafe mailing list

Re: [Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Dusan Kolar
Yes, that's is. Thanks. My fault - missing wood seeing trees. ;-) Best regards, Dusan Roberto Zunino wrote: Dusan Kolar wrote: Dear all, I've thought the following three (dummy) programs would run some of their parts in parallel (on dual core) if compiled with option threaded (smp). The

Re: [Haskell-cafe] True parallelism missing :-(

2008-03-25 Thread Don Stewart
To avoid this in future, you can use the strict-concurrency package on hackage, which has some stricter container types, with their strategies. MVars and Chans are the main examples of where a stricter strategy is sometimes useful. kolar: Yes, that's is. Thanks. My fault - missing wood seeing