help-octave
[Top][All Lists]
Advanced

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

Re: octave vs. matlab speed


From: Alexander Barth
Subject: Re: octave vs. matlab speed
Date: Fri, 11 Aug 2006 15:20:14 -0400
User-agent: Thunderbird 1.5.0.2 (X11/20060501)

Peter Cloetens wrote:
> Hi,
> Thanks for this interesting observation.
> Is it somewhere described how to activate/install Atlas versions of the Blas/
> Lapack libraries?
> I use centralised computer resources, so I'm not familiar with this.
> But on our redhate4 system Atlas seems not installed:
> 
> newcronus1:~ % rpm -q gcc
> gcc-3.4.4-2
> newcronus1:~ % rpm -q blas
> blas-3.0-25.1
> blas-3.0-25.1
> newcronus1:~ % rpm -q lapack
> lapack-3.0-25.1
> lapack-3.0-25.1
> newcronus1:~ % rpm -q atlas
> package atlas is not installed
> 
> Thanks,
> Peter
> 
Hi Peter,

The tests I posted are on Fedora Core 5 which provides (an excellent) octave 
package using ATLAS
(kudos to Quentin). On SuSE things are not that simple. Here are some notes on 
how I installed
octave with atlas on SuSE (AMD 64-bit) which might be useful for you as well, 
if you plan to compile
ATLAS and Octave from source.

Compile ATLAS

make
# go through the configuration process accepting the defaults (except when it 
wants to stop after
detecting that you are not using gcc 2.9)
# change the makefile make.Linux_<ARCH> and add -fPIC to the compiler options
make install arch=Linux_<ARCH>
# drink a cup of coffee....

Compile Octave

./configure --enable-shared --enable-dl --disable-static 
--prefix=<PREFIX>/octave-2.9.7-atlas
CFLAGS=-O3 CXXFLAGS=-O3 FFLAGS=-O3 F77=gfortran 
LDFLAGS="-L<ATLAS_DIR>/lib/Linux_<ARCH> -lg2c"

Note that I needed to link against the g2c library since ATLAS is compiled with 
g77. Otherwise I get
error messages in config.log like:

.../libf77blas.a(xerbla.o): In function `xerbla_':
xerbla.f:(.text+0x18): undefined reference to `s_wsfe'
xerbla.f:(.text+0x2f): undefined reference to `do_fio'
xerbla.f:(.text+0x46): undefined reference to `do_fio'
xerbla.f:(.text+0x50): undefined reference to `e_wsfe'
xerbla.f:(.text+0x64): undefined reference to `s_stop'

If the configure script detects ATLAS it should give something like:
[...]
checking for ATL_xerbla in -latlas... yes
checking for sgemm_ in -lf77blas... yes
checking for cblas_dgemm in -lcblas... yes


On the atlas website (http://sourceforge.net/projects/math-atlas) you will find 
precompiled
binaries. However, they didn't work for me since they aren't compiled with 
-fPIC.

Cheers
Alex



reply via email to

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