[vsipl++] ATLAS undefines

Jules Bergmann jules at codesourcery.com
Wed May 31 20:36:15 UTC 2006


Assem,

Thanks for posting this.

It looks like we're trying to use the CBLAS bindings for 
CLAPACK/SRC/BLAS.  Unfortunately, looking at the source, it is a Fortran 
API, with a few variances (the complex dot-product Fortran functions 
have been converted to C "subroutines" that return the result by 
reference).  I suspect if you tried to build other tests you would see 
linker errors for functions like cblas_trsm, etc.

For this, we should take an approach similar to how we handled ACML:

  - Have configure define VSIP_IMPL_USE_CBLAS = 4 when using
    CLAPACK/SRC/BLAS

  - In lapack.hpp, when VSIP_IMPL_USE_CBLAS == 4,
     - wrap the dot-product functions to have a CBLAS interface and
       define VSIP_IMPL_USE_CBLAS_DOT = 1.

       This should be done in a separate header file, similar to
       acml_cblas.hpp.

     - Use Fotran API for other BLAS functions
       (VSIP_IMPL_USE_CBLAS_OTHER = 0).

Does that sound OK?

				-- Jules

Assem Salama wrote:
> Everyone,
>  As per Jule's request, this is the output of make when trying to 
> compile convolution.cpp in the tests dir. The BLAS that I got with 
> CLAPACK has functions similar to these but without the cblas prepended 
> and without _sub.
> 
> Thanks,
> Assem Salama
> 
> 
> ------------------------------------------------------------------------
> 
> g++ -g -O2 -I../src -I/drive2/assem/work/checkout/vpp/tests/../src -I/include/atlas -I/include/fftw3  -I/drive2/assem/work/checkout/vpp/vendor/atlas/include -I/drive2/assem/work/build/vpp_temp2/vendor/fftw/include  -o convolution.exe convolution.o -L/lib/atlas -L/lib/fftw3  -L/drive2/assem/work/build/vpp_temp2/vendor/atlas/lib -L/drive2/assem/work/build/vpp_temp2/vendor/fftw/lib -L/drive2/assem/work/build/vpp_temp2/vendor/clapack -L/drive2/assem/work/build/vpp_temp2/lib -L../src/vsip -lvsip -llapack -lF77 -lcblas  -lfftw3f -lfftw3 -lfftw3l   || rm -f convolution.exe
> convolution.o: In function `dot':
> /drive2/assem/work/checkout/vpp/tests/../src/vsip/impl/lapack.hpp:180: undefined reference to `cblas_ddot'
> /drive2/assem/work/checkout/vpp/tests/../src/vsip/impl/lapack.hpp:217: undefined reference to `cblas_zdotu_sub'
> /drive2/assem/work/checkout/vpp/tests/../src/vsip/impl/lapack.hpp:179: undefined reference to `cblas_sdot'
> /drive2/assem/work/checkout/vpp/tests/../src/vsip/impl/lapack.hpp:216: undefined reference to `cblas_cdotu_sub'
> collect2: ld returned 1 exit status


-- 
Jules Bergmann
CodeSourcery
jules at codesourcery.com
(650) 331-3385 x705



More information about the vsipl++ mailing list