From jamatos at fc.up.pt  Fri Sep 23 20:24:29 2005
From: jamatos at fc.up.pt (=?UTF-8?B?Sm9zw6k=?= Matos)
Date: Fri, 23 Sep 2005 19:24:29 +0100
Subject: [Rd] looks in liblapack.a not liblapack.so
References: <mailman.9.1126951201.11292.r-devel@r-project.org>
	<20050917221902.GA10806@stat.umn.edu>
	<1127119440.3624.5.camel@seurat>
	<x23bo15c13.fsf@turmalin.kubism.ku.dk>
	<1127144443.18426.14.camel@seurat> <dgpari$a96$1@sea.gmane.org>
	<x2mzm5lbtx.fsf@turmalin.kubism.ku.dk>
	<Pine.LNX.4.61.0509221013230.14847@gannet.stats>
	<x2aci5l004.fsf@turmalin.kubism.ku.dk>
Message-ID: <dh1h8u$dvg$1@sea.gmane.org>

Peter Dalgaard wrote:
> Prof Brian Ripley wrote:
>> BTW, I don't understand how a Linux distro can supply ATLAS tuned to
>> my CPU/FPU.  Dr Goto has had about ten versions of his optimized BLAS
>> covering just a small subset of i686 CPUs.  So although a distro's
>> ATLAS may be better than a generic BLAS, it seems that it is likely to
>> be suboptimal, and perhaps disastrous (I've seen that with mobile
>> Pentium chips using ATLAS tuned on desktop machines).  So the
>> recommendation must remain to tune ATLAS on your specific hardware.
> 
> I don't think an RPM is restricted to contain only one version of the
> binaries, so in principle, the post-installer could adapt the
> installed version to your hardware, if it could narrow the choice down
> to a dozen versions or so. It's not easy though, since not only the
> CPU/FPU types factor in, but also cache sizes and memory speeds.

  Peter is right here. We can have rpms for i386, i486, i586, i686,
athlon, ...

  One example of this kind of package is the kernel, but most applications
the optimizations does not matter. The few packages shipped in Fedora Core
who follow this scheme (and just for few subarchitecture, not for all) are:

- kernel related
- glibc
- openssl

  The other possibility (orthogonal with the previous) is to ship the
libraries optimized for different cpu features, like gmp (GNU arbitrary
precision library) does:

$ rpm -ql gmp-4.1.4-6.i386
/usr/lib/libgmp.so.3
/usr/lib/libgmp.so.3.3.3
/usr/lib/libgmpxx.so.3
/usr/lib/libgmpxx.so.3.0.5
/usr/lib/libmp.so.3
/usr/lib/libmp.so.3.1.7
/usr/lib/sse2/libgmp.so.3
/usr/lib/sse2/libgmp.so.3.3.3
/usr/lib/sse2/libgmpxx.so.3
/usr/lib/sse2/libgmpxx.so.3.0.5
/usr/lib/sse2/libmp.so.3
/usr/lib/sse2/libmp.so.3.1.7

and for 64 bits:
$ rpm -ql gmp-4.1.4-6.x86_64
/usr/lib64/libgmp.so.3
/usr/lib64/libgmp.so.3.3.3
/usr/lib64/libgmpxx.so.3
/usr/lib64/libgmpxx.so.3.0.5
/usr/lib64/libmp.so.3
/usr/lib64/libmp.so.3.1.7

  As I have told above usually this only applies to very few packages where
performance is really important. Clearly this description fits to
atlas. :-)

-- 
Jos? Ab?lio



[Rd] looks in liblapack.a not liblapack.so
=?UTF-8?B?Sm9zw6k=?= Matos