[R-SIG-Mac] intel compilers
Prof Brian Ripley
ripley at stats.ox.ac.uk
Sun Mar 16 08:10:11 CET 2008
On Sat, 15 Mar 2008, Kasper Daniel Hansen wrote:
> Do anyone have experience using the intel compilers and the MLK
> library with R? If so, what is the speedup approximately (I know this
> depends heavily on what task you are doing, but I am just looking for
> some general impressions).
The results will also depend on the CPU and the version of the Intel
compilers, but generally differences between compilers are a few percent,
and fast math libraries even less. One exception is an accelerated BLAS
on some intensive matrix algebra tasks, especially where multiple CPUs or
cores are available 'for free'.
I've not tried on MacOS, because the experience on Linux has not been
good. i386 Intel compilers have consistently generated wrong code at high
optimization levels (to the point that 'make check' fails) and whereas
x86_64 versions work correctly, they seem rarely to generate code as fast
as gcc. As an accelerated BLAS, MKL seems uncompetitive with ATLAS or
Goto (especially on dual core chips).
The chip also matters, and recent experience on an Intel Core 2 Duo has
been better than in the past on Xeons. But my home PC has a very simlar
Core 2 Duo to my iMac, and that's the main basis for the previous para.
I remember a couple of reports from Jan de Leeuw of incorrect results on
early Intel Macs, which were traced to use of Intel i386 compilers.
Gcc/gfortran does a good job, especially if you turn the optimization
levels up -- using -O3 gains ca 10% on x86_64 Linux. I've also got
SunStudio compilers there and on Solaris, and despite their excellent
reputation the speed gains are small (although they are very useful in
detecting standard-violating code).
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-SIG-Mac
mailing list