Skip to content
Prev 1849 / 2152 Next

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

Hi Xuening,

2 physical vs 2 physical * 2 logical threads: See e.g. here:  http://unix.stackexchange.com/a/88290

You say you have 2 *physical* cores. That's the number you want to use for the parallel execution. Logical cores are just 2 (or more) threads running on the same physical core. IIRC, this can speed up things mainly if the 2 threads run very different operations.

I think this does not help the BLAS because there you have massive amounts of the *same* operations and they can easily be parallelized. Instead, you get overhead and maybe caching/scheduling "conflicts". 

I think if you want to profit from the 2 phys * 2 log. thread architecture, you'd need to optimize compilation to be aware of this. But even then I'd not expect too much here: 2 threads on the physical cores probably don't leave much space for other calculations to be done "meanwhile". 

All in all, I think it is just the same behaviour you see when scheduling more threads than cores in general (e.g. on a machine that has 1 logical core per physical core).

HTH,

Claudia




--
Claudia Beleites, Chemist
Spectroscopy/Imaging
Leibniz Institute of Photonic Technology
Albert-Einstein-Str. 9
07745 Jena
Germany

email: claudia.beleites at ipht-jena.de
phone: +49 3641 206-133
fax:   +49 2641 206-399

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