Re: [eigen] Using eigen shared library as a dynamic replacement for libblas

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


Hi,

There is already a BLAS API built on top of Eigen. To build it, get the source of Eigen, then:
$ mkdir build
$ cd build
$ cmake -DCMAKE_BUILD_TYPE=Release path/to/eigen_source
$ cd blas
$ make

This will produce both a static and a dynamic library.

If your CPU support AVX, then get the devel branch, and enable AVX with:

$ cmake -DCMAKE_BUILD_TYPE=Release path/to/eigen_source -DEIGEN_TEST_AVX=ON

Same for FMA:

$ cmake -DCMAKE_BUILD_TYPE=Release path/to/eigen_source -DEIGEN_TEST_AVX=ON -DEIGEN_TEST_FMA=ON

cheers,
gael


On Fri, Apr 3, 2015 at 10:12 PM, Илья Палачев <iliyapalachev@xxxxxxxxx> wrote:
Hi,

I have an application that uses BLAS API and its performance bottleneck is in BLAS.
Is it possible to use Eigen as a replacement for libblas?

Can I for example build Eigen as a shared library and just make symbolic link /usr/lib/libblas.so -> /path/to/libeigen.so ?

Or the only way is to re-write my app so that to use Eigen API?

--
Best regards,
Ilya Palachev





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/