BLAS & LAPACK for Windows

BLAS and LAPACK from Netlib are the de facto libraries for linear algebra. For those interested in using BLAS and LAPACK on Windows platform, I have compiled them in 32bit and 64bit libraries by Intel® Fortran Compiler XE 13.1 and Visual Studio 2010.

I use LAPACK version 3.2.1, and the original patched makefiles can be downloaded from David Svoboda’s website. The source codes of LAPACK and BLAS packages are available from Netlib.

The 32 bit BLAS and LAPACK libraries downloading:

The 64 bit BLAS and LAPACK libraries downloading:

The modified Windows makefile can be downloaded from here:

Thanks David Svoboda for the original LAPACK Windows version.

Thanks Conrad Sanderson for the "/QaxSSSE3" suggestion, and the wonderful Armadillo C++ linear algebra library!

Updated with "/QaxCORE-AVX2", thanks Huijuan Li and Sigurður Freyr Hafstein for the tip!

The 32 bit BLAS and LAPACK libraries with "/QaxCORE-AVX2" downloading:
o debug version
o release version

The 64 bit BLAS and LAPACK libraries with "/QaxCORE-AVX2" downloading:
o debug version
o release version

评论

Unknown说…
Hello Yili,

thank you very much for your BLAS/LAPACK libraries! I use them with Armadillo and they work pretty well.

I have compared the speed to the optimized BLAS/LAPACK version of ACML from AMD. Your package is up to 40% faster than ACML, which confuses me a bit. How you reach a performance, which is a lot better than an-already-optimized library?

I thought you have just compiled the netlib, which is pretty slow, as far as I had read in the internet.

And what does the "/QaxCORE-AVX2" option mean? Does it mean, that your LAPACK/BLAS lib is using multiple Cores?

I would appreciate, if you could help me out of my confusion!

Greetings from Berlin, Germany!
Niclas
Unknown说…
Hi Niclas,
I think one factor is that I use Intel Fortran Compiler to compile them, and another factor is that I use compiler option "/QaxCORE-AVX2" which can generate Intel Advanced Vector Extensions 2 (Intel® AVX2), Intel® AVX, SSE4.2, SSE4.1, SSSE3, SSE3, SSE2, and SSE instructions for Intel® processors.
You may reference it here: http://software.intel.com/sites/products/documentation/hpc/composerxe/en-us/2011Update/fortran/lin/copts/common_content/options_ref_new_opts.htm
Unknown说…
Hello Yili,

I'am having some problems using the precompiled libraries in dev c++ (windows 7). I have given the libraries to my compiler (projects options > parameters > linker > add library or object) and also placed the .lib files in C:/Program Files (x86)/Dev-Cpp/MinGW64/lib and the .dll files in C:/Program Files (x86)/Dev-Cpp/MinGW64/bin. Yet when I compile c++ stops working/crashes when it has to calculate a determinant, inverse or diagonalise a matrix. After debugging I get the following backtrace:

dsyevd_()
arma::lapack::syevd(jobz = 0x22f95f "VÐü\"", uplo = 0x22f95e "UVÐü\"", n = 0x22f958, a = 0x6e4a40, lda = 0x22f958, w = 0x22fc50, work = 0x6e4b40, lwork = 0x22f954, iwork = 0x6e5080, liwork = 0x22f950, info = 0x22f94c) C:/Libraries cpp/include/include/armadillo_bits/lapack_wrapper.hpp 161
arma::auxlib::eig_sym_dc >(eigval = ..., eigvec = ..., X = ...) C:/Libraries cpp/include/include/armadillo_bits/auxlib_meat.hpp 1274
arma::eig_sym >(eigval = ..., eigvec = ..., X = ..., method = 0x49405c "dc", junk = 0x0) C:/Libraries cpp/include/include/armadillo_bits/fn_eig_sym.hpp 103
main() test diagonalization.cpp 16

The code I used is from the documentation of armadillo:

#include
#include
#include
#include
using namespace std;
using namespace arma;


int main(){
mat A = randu(5,5);
mat B = A.t()*A; // generate a symmetric matrix
B.print("B:");
vec eigval;
mat eigvec;
cout << 42;
eig_sym(eigval, eigvec, B);
}

It seems that I still have some linking errors using the precompiled libraries. But since I am inexperienced with these I have no idea what to do. Do I have to compile the libraries first or use/adapt the cmake files? And how do I do this?
Unknown说…
Hello Yili,

Could you share the VS Project with me?

I cannot get rid of Intel Fortran Redistributable Library dependency.
Unknown说…
Get more secret keys from: Findkeyhome.com.
david burney说…
Guys need windows 10 product key that i suggest you go site goodkeyhome.com to got. 100% genuine it to provide.
david burney说…
If someone need MWindows 10 Home Key,you can go to softkeyhome.co.uk to got. My key got here. it's genuine and cost me a little money.

此博客中的热门博文

从特征描述符到深度学习:计算机视觉发展20年

One note for building Caffe RC3 on Ubuntu 14.04