help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NaN slowdown with some processors


From: Olli Saarela
Subject: Re: NaN slowdown with some processors
Date: Wed, 04 Jun 2008 13:55:41 +0300
User-agent: Thunderbird 2.0.0.14 (Windows/20080421)

I'm planning to buy a new desktop machine, and since my computations utilize NaN values heavily, I'd like to know whether Intel Core 2 processors suffer from the same slowdown with NaN values as Pentium. For details, see http://www.cygnus-software.com/papers/x86andinfinity.html

Thank you all, the data you have provided has clarified the issue. In addition to the replies posted to the list, I got some mail showing 100x slowdown with Core 2 / Debian / Octave 3.0.1. It looks like there still is a NaN related slowdown in Core 2 when the computation isn't carried out using SSE2/3.

If I have understood correctly, gcc can be forced to generate SSEn instructions, which avoids this performance degradation completely. There also seems to be a number of Linux installations of Octave out there that would benefit from such compile options.

The situation is slightly different with MSVC. The documentation on MSDN says

  The optimizer will choose when and how to make use of the SSE and SSE2
  instructions when /arch is specified. SSE and SSE2 instructions will
  be used for some scalar floating-point computations, when it is
  determined that it is faster to use the SSE/SSE2 instructions and
  registers rather than the x87 floating-point register stack. As a
  result, your code will actually use a mixture of both x87 and SSE/SSE2
  for floating-point computations.

This might explain the NaN-related slowdown on Windows machines with Intel processors. Drawing (extrapolating) conclusions from the posted figures, MSVC2008&SSE3 seem to do a much better job in this respect than MSVC2005&SSE2, even though some performance degradation still remains.

Thank you all once again!
  Olli



reply via email to

[Prev in Thread] Current Thread [Next in Thread]