Cantera / enhancements

Repository for proposed and ongoing enhancements to Cantera
11 stars 5 forks source link

Use BLAS/LAPACK by default if installed #144

Closed ischoegl closed 2 years ago

ischoegl commented 2 years ago

Abstract

While many 'system'-installed packages are detected and used by default (e.g. Eigen, fmt, sundials, yaml-cpp), the same is not true for BLAS and LAPACK. Instead, it does require the blas_lapack_libs flag (as expected, there currently is no system_blas_lapack option).

While there are some issues related to incompatible versions packaged with MATLAB, it would make sense to use BLAS and LAPACK by default otherwise (instead of Eigen's linear algebra support). Based on communication with @speth there are couple of caveats to consider:

[...] there are a number of special cases that you would want handle. One is that one of the best BLAS/LAPACK implementations to link to would be the MKL if it’s present. The other is that if you’re trying to autodetect, you probably want to try figuring out if it’s a version that uses an 8-byte index type or not (which is the Matlab issue).