Pardiso interface fails to compile on Windows with the following error:
[build] src\Solvers\PardisoInterface.h:40:17: error: cannot initialize a parameter of type 'const long long *' with an rvalue of type 'int *'
[build] 40 | pt, &maxfct, &mnum, &type, &phase, &n, a, ia, ja, perm, &nrhs, iparm, &msglvl, b, x, &error);
[build] | ^~~~~~~
[build] src\Solvers\PardisoInterface.h:193:55: note: in instantiation of member function 'Eigen::internal::pardiso_run_selector<int>::run' requested here
[build] 193 | internal::pardiso_run_selector<StorageIndex>::run(m_pt,
[build] | ^
[build] src\Solvers\PardisoInterface.h:135:7: note: in instantiation of member function 'Eigen::PardisoImpl<Eigen::PardisoLDLT<Eigen::SparseMatrix<double, 1>>>::pardisoRelease' requested here
[build] 135 | pardisoRelease();
[build] | ^
[build] src\Solvers\PardisoInterface.h:679:9: note: in instantiation of member function 'Eigen::PardisoImpl<Eigen::PardisoLDLT<Eigen::SparseMatrix<double, 1>>>::~PardisoImpl' requested here
[build] 679 | class PardisoLDLT : public PardisoImpl<PardisoLDLT<MatrixType, Options>> {
[build] | ^
[build] C:/Program Files (x86)/Intel/oneAPI/mkl/latest/include\mkl_pardiso.h:33:52: note: passing argument to parameter 'maxfct' here
[build] 33 | void pardiso( _MKL_DSS_HANDLE_t pt, const MKL_INT *maxfct, const MKL_INT *mnum,
[build] | ^
[build] 4 warnings and 1 error generated.
MKL Versions attempted:
2023.1.0
2024.1
Compilers attempted:
Clang 17
Clang 18
Investigations
The internal type MKL_INT is probably being set to long long int rather than int, causing the arguments to ::pardiso to be const long long int * rather than const int *. Seems to be triggered by the MKL_ILP64 preprocessor definition.
Summary
Pardiso interface fails to compile on Windows with the following error:
MKL Versions attempted:
Compilers attempted:
Investigations
The internal type
MKL_INT
is probably being set tolong long int
rather thanint
, causing the arguments to::pardiso
to beconst long long int *
rather thanconst int *
. Seems to be triggered by theMKL_ILP64
preprocessor definition.