Skip to content

We should generalize CMake for BLAS/LAPACK use #158

@mathomp4

Description

@mathomp4

In the LDAS, namely landpert, we have:

if (NOT CMAKE_Fortran_COMPILER_ID MATCHES "NAG")
   target_compile_definitions(${this} PRIVATE MKL_AVAILABLE)
endif ()

This should be better generalized. In the future, we might move to, say, Flang for Fortran and there is no MKL interface to Flang like there is for GNU.

Also, in landassim code we have:

! use intel mkl lapack when available
#ifdef MKL_AVAILABLE
#include "lapack.f90"
#endif


module enkf_general
  
#ifdef MKL_AVAILABLE
  use lapack95, only: getrf, getrs
#endif

This isn't even dependent on MKL, just LAPACK (though I guess, LAPACK95). This should also be cleaned up.

I think this shouldn't be too hard, but I'll need to try things out. I'm guessing we can go off of BLA_VENDOR but I'm not sure.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions