Package: lapack Version: 3.2.1-8 Severity: normal Hi and thanks for maintaining LAPACK in Debian!
I am trying to see how much performance I may gain with ATLAS as a LAPACK replacement (I will also test the CPU-optimized libatlas-core2sse3-dev later on). I am trying to follow instructions included in http://sylvestre.ledru.info/blog/sylvestre/2010/04/06/update_of_the_linear_algebra_libraries_i However, it seems that I am doing something wrong, since, after changing the alternatives, I am no longer able to compile (link, to be precise) my applications. Let's describe the problem. I have just upgraded the following packages [INSTALL, DEPENDENCIES] libatlas-dev [REMOVE, DEPENDENCIES] libatlas-headers [UPGRADE] libatlas-base-dev 3.6.0-24 -> 3.8.3-27 [UPGRADE] libatlas3gf-base 3.6.0-24 -> 3.8.3-27 since they have recently migrated to testing. They automatically set the following alternatives: # update-alternatives --config libblas.so.3gf There are 2 choices for the alternative libblas.so.3gf (providing /usr/lib/libblas.so.3gf). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/atlas-base/atlas/libblas.so.3gf 35 auto mode 1 /usr/lib/atlas-base/atlas/libblas.so.3gf 35 manual mode 2 /usr/lib/libblas/libblas.so.3gf 10 manual mode Press enter to keep the current choice[*], or type selection number: # update-alternatives --config liblapack.so.3gf There are 2 choices for the alternative liblapack.so.3gf (providing /usr/lib/liblapack.so.3gf). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/atlas-base/atlas/liblapack.so.3gf 35 auto mode 1 /usr/lib/atlas-base/atlas/liblapack.so.3gf 35 manual mode 2 /usr/lib/lapack/liblapack.so.3gf 10 manual mode Press enter to keep the current choice[*], or type selection number: With these settings, I can compile (and link) programs that use LAPACK: $ gfortran -march=native -O3 -mcmodel=large -msse -mfpmath=sse -pipe -o test_0 test.f -llapack $ ldd test_0 linux-vdso.so.1 => (0x00007ffff29ff000) liblapack.so.3gf => /usr/lib/liblapack.so.3gf (0x00007ff0eebe5000) libgfortran.so.3 => /usr/lib/libgfortran.so.3 (0x00007ff0ee8f9000) libm.so.6 => /lib/libm.so.6 (0x00007ff0ee676000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00007ff0ee460000) libc.so.6 => /lib/libc.so.6 (0x00007ff0ee0ff000) libblas.so.3gf => /usr/lib/libblas.so.3gf (0x00007ff0edbde000) libpthread.so.0 => /lib/libpthread.so.0 (0x00007ff0ed9c2000) /lib64/ld-linux-x86-64.so.2 (0x00007ff0ef811000) After changing the alternatives to the reference BLAS/LAPACK implementations # update-alternatives --config libblas.so.3gf There are 2 choices for the alternative libblas.so.3gf (providing /usr/lib/libblas.so.3gf). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/atlas-base/atlas/libblas.so.3gf 35 auto mode 1 /usr/lib/atlas-base/atlas/libblas.so.3gf 35 manual mode 2 /usr/lib/libblas/libblas.so.3gf 10 manual mode Press enter to keep the current choice[*], or type selection number: 2 update-alternatives: using /usr/lib/libblas/libblas.so.3gf to provide /usr/lib/libblas.so.3gf (libblas.so.3gf) in manual mode. # update-alternatives --config liblapack.so.3gf There are 2 choices for the alternative liblapack.so.3gf (providing /usr/lib/liblapack.so.3gf). Selection Path Priority Status ------------------------------------------------------------ * 0 /usr/lib/atlas-base/atlas/liblapack.so.3gf 35 auto mode 1 /usr/lib/atlas-base/atlas/liblapack.so.3gf 35 manual mode 2 /usr/lib/lapack/liblapack.so.3gf 10 manual mode Press enter to keep the current choice[*], or type selection number: 2 update-alternatives: using /usr/lib/lapack/liblapack.so.3gf to provide /usr/lib/liblapack.so.3gf (liblapack.so.3gf) in manual mode. I am no longer able to compile and link the same program: $ gfortran -march=native -O3 -mcmodel=large -msse -mfpmath=sse -pipe -o test_1 test.f -llapack /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_chemv' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_dptsyrk' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_sspr2' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_cmoveConj' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_cgbmv' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_sspmv' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_cpttrsm' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_cscal' /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_ctbmv' [...] /usr/lib/gcc/x86_64-linux-gnu/4.4.5/../../../../lib/liblapack.so: undefined reference to `ATL_dpttrmm' collect2: ld returned 1 exit status What am I failing to understand? Is an 'lddconfig' needed, by chance? I couldn't find documentation about the BLAS/LAPACK alternatives system implemented in Debian packages. Where is it explained? Please help, thanks for your time. -- System Information: Debian Release: squeeze/sid APT prefers testing APT policy: (800, 'testing'), (500, 'unstable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-5-amd64 (SMP w/4 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages liblapack-dev depends on: ii libatlas-base-dev [libblas-3g 3.8.3-27 Automatically Tuned Linear Algebra ii libblas-dev [libblas-3gf.so] 1.2-7 Basic Linear Algebra Subroutines 3 ii liblapack3gf 3.2.1-8 library of linear algebra routines liblapack-dev recommends no packages. liblapack-dev suggests no packages. -- no debconf information -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

