Boost logo

Ublas :

Subject: Re: [ublas] [bindings][blas] Included CBLAS support
From: Thomas Klimpel (Thomas.Klimpel_at_[hidden])
Date: 2010-01-05 18:14:20

Hello Rutger,

Rutger ter Borg wrote:
> If you're able to help testing and/or have suggestions, please let me know.

I should be able to help... (I'm sorry that I haven't found time earlier.)
I updated the old regression tests to work with the automatically generated version of the bindings from 14. October 2009. This also means that the updated regression tests don't work with the new traits system yet. However, I hope it won't be too difficult to update them to the new traits system now (and perhaps we will find and fix some bugs of the new traits system on the way).

I also updated the bjam files of the regression tests a bit. It should now be possible to run the regression tests by getting the source tree from (or, setting the environment BOOST_ROOT to the root directory of a recent boost source tree, and typing "bjam" inside the "numeric_bindings/libs/numeric/bindings/lapack/test" directory (or inside the "numeric_bindings/libs/numeric/bindings" directory to run all regression tests). The regression tests will probably fail with linker errors, because the path or name of the blas and lapack libraries won't be right. This can be fixed by editing the file "numeric_bindings/libs/numeric/bindings/numeric-bindings.jam" and adding the correct BLAS_PATH =...and LAPACK_PATH =... statements to the top of the file, and eventually also the correct BLAS_LIB =... and LAPACK_LIB =...

However, this will probably only work when blas/lapack were compiled with gfortran. But typing "bjam numbind=xxx" where "xxx" can currently be "user", "gfortran", "g77", "clapack-gcc", "clapack-msvc", "acml-gcc", "acml-msvc", "mkl-gcc" or "mkl-msvc" might help a bit here. These options still assume 32-bit integers in fortran, even on 64-bit systems. This makes sense, because the default for gfortran is to compile with 32-bit integers. To compile with 64-bit integers, the option -fdefault-integer-8 can be used. To link against a fortran library compiled with these options, the lines with <define>BIND_FORTRAN_INTEGER_8 in numeric-bindings.jam should be activated.

> To unify the interface, the character arguments to BLAS calls are translated
> to cblas enums, matrix orientation is assumed to be column major by default.
> IMHO, this makes the ATLAS bindings obsolete.

For the moment, I just checked that the ATLAS, umfpack and mumps regression tests pass again for me. So I haven't updated the 36 ATLAS regression tests to the automatically generated version of the bindings. Having automatically generated ATLAS bindings would certainly be nice, and the cblas part is definitively the bulk of them.

I removed the reference to the amos regression tests, because I think we agree to drop support for amos. I also assume that we agree to drop support for MSVC 6.0 & 7.0, i.e. the macro BOOST_NUMERIC_BINDINGS_POOR_MANS_TRAITS and the associated macros BOOST_NUMERIC_BINDINGS_NO_STRUCTURE_CHECK and BOOST_NUMERIC_BINDINGS_NO_TYPE_CHECK.