Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29253 Discussions

OpenMP: Same process on one processor is faster then on two processors

Reinaldo_Garcia
Beginner
379 Views
We are running code written with OpenMP on a desktop i7 920, 2.66 Ghz processor. We just set up a Dual Xeon 2.53GHz Quad Core server running server 2008 64-bit. The desktop is running Windows 7 64-bit. Running the exact same executable on the server, it takes a minute longer to run than on the desktop. We tested again but this time turning off the second processor on the server, and it runs faster than with two processors enabled.
This table shows the tests we ran.

Computer Speed Processors Threads Runtime

Desktop (i7) 2.66 Ghz 1 8 3 minutes 40 seconds

Server (Dual Xeon) 2.53 Ghz 2 16 5 minutes 53 seconds

Server (Single Xeon) 2.53 Ghz 1 8 4 minutes 18 seconds

Any ideas on why this may be happening or any suggestions would be welcome.

Regards,

R.
0 Kudos
1 Reply
jimdempseyatthecove
Honored Contributor III
379 Views
My guess is your working data fits nicely into one L3 cache and the work (data)performed on one thread on one of the processors is passed off to a thread in one of the other processors. (IOW requires additional memory fetch).

Without seeing the actual code it is hard to guess as to the specific cause.

Try setting environment variable

KMP_AFFINITY=compact

Jim Dempsey
0 Kudos
Reply