Jakub's Recommendations for ia32 Support

Jakub Jelinek jakub at redhat.com
Wed Feb 4 07:29:18 UTC 2009


On Wed, Feb 04, 2009 at 01:56:16AM +0100, Dominik 'Rathann' Mierzejewski wrote:
> On Wednesday, 04 February 2009 at 01:34, Callum Lerwick wrote:
> > On Tue, 2009-02-03 at 19:53 +0100, Dominik 'Rathann' Mierzejewski wrote:
> > > >  i686 to i686 w/ SSE2 would be a performance win, but that is
> > > > clearly not an option for Fedora.
> > > 
> > > SSE2-optimized libraries can be built and installed into /usr/lib/sse2.
> > > Our ld.so already supports that.
> > 
> > Why does SSE2 get this treatment, and not SSE? I've found SSE much more
> > useful, and more common. SSE2 pretty much means P4 only on i386, Athlons
> > didn't get SSE2 until the Athlon 64 and those should be running x86-64
> > anyway. Whereas there's a lot of Pentium 3s and Athlon XPs with SSE out
> > there.
> 
> I was wondering about the same thing. There's little to no documentation
> on this subject so I had to dig into glibc sources to see how it works.
> Apparently, glibc distinguishes some "features" for CPUs and those that
> are "major" can have separate directories with optimized libraries.
> In Fedora, "major" features are "i686" and "sse2". Whereas in Debian,
> it's just "cmov", apparently.
> 
> Can anyone shed more light here? Jakub?

glibc only has limited subset of the hwcaps marked as important, because
it is very costly for LD_LIBRARY_PATH and RPATH/RUNPATH (each added
important hwcap doubles the number of searches).

The reason sse2 is important and sse is not is that sse2 covers both float
and double and vectors thereof, so 1) -mfpmath=sse is possible (this means
end of the unpredictable FP behaviors you get with ix87 stack, where
everything depends on how long is the compiler being able to keep stuff
in the ix87 stack and doesn't have to spill into memory) 2) -O3 can actually
vectorize code using both float and doubles.

	Jakub




More information about the fedora-devel-list mailing list