Skip to content
Prev 1853 / 2152 Next

Why pure computation time in parallel is longer than the serial version?

On Sun, 23 Feb 2014, Xuening Zhu wrote:

            
Your alternatives are mclapply(2 cores) with the fast BLAS running 
sequentially on each core (fastest), fast BLAS running in parallel on 2 
cores, and mclapply(2 cores) with standard BLAS running sequentially on 
each core.

For your problem and on your hardware (the size of the level 2 cache 
affected the size of problem chunks tuned/fast BLAS can compute in 
parallel before unified cache), mclapply (forking the process) and 
sequential (single core) fast BLAS are best. For cache see:

http://en.wikipedia.org/wiki/CPU_cache#Multi-level_caches

It looks as though "modern" processors with unified cache may not be great 
for numerical work unless the L3 unified cache is relatively large, but 
I'm just speculating, maybe someone knows?

You could change the size of the problem and see if your conclusions 
change. Read up on the difference between forking and starting new 
processes (it's among other things about memory). These things do vary 
from hardware to hardware and task to task.

Hope this helps,

Roger

  
    

Thread (19 messages)

Wesley Goi Why pure computation time in parallel is longer thanthe serial version? Feb 17 Xuening Zhu Why pure computation time in parallel is longer thanthe serial version? Feb 17 wesley goi Why pure computation time in parallel is longer thanthe serial version? Feb 17 Roger Bivand Why pure computation time in parallel is longer than the serial version? Feb 18 wesley goi Why pure computation time in parallel is longer than the serial version? Feb 18 Xuening Zhu Why pure computation time in parallel is longer than the serial version? Feb 22 Claudia Beleites Why pure computation time in parallel is longer than the serial version? Feb 22 Xuening Zhu Why pure computation time in parallel is longer than the serial version? Feb 22 Roger Bivand Why pure computation time in parallel is longer than the serial version? Feb 22 Xuening Zhu Why pure computation time in parallel is longer than the serial version? Feb 22 Roger Bivand Why pure computation time in parallel is longer than the serial version? Feb 23 Ei-ji Nakama Why pure computation time in parallel is longer than the serial version? Feb 23 Ei-ji Nakama Why pure computation time in parallel is longer than the serial version? Feb 23 Simon Urbanek Why pure computation time in parallel is longer than the serial version? Feb 25 Jim Gattiker Why pure computation time in parallel is longer than the serial version? Feb 25 George Ostrouchov Why pure computation time in parallel is longer than the serial version? Feb 25 Norm Matloff Why pure computation time in parallel is longer than the serial version? Feb 25 Jim Gattiker Why pure computation time in parallel is longer than the serial version? Feb 26 George Ostrouchov Why pure computation time in parallel is longer than the serial version? Feb 26