Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.

link line advisor for pardiso solver

eddywu
Beginner
510 Views

Hi,

I'm trying to compile code that uses the pardiso solver.  The machine I'm using is a linux machine. I'm using an autoconfig file to compile the code. I used the link line advisor to specify flags needed for my autoconfig and set the environment variables needed. 

The autoconfig file is below:

#!/bin/sh
../configure \
CXXFLAGS="-O3 -fopenmp -std=c++11" \
ARCHDIR="$HOME/XyceLibs/Parallel" \
CPPFLAGS="-DMKL_ILP64 -m64 -fPIC -I$MKLROOT/include" \
LDFLAGS="-m64 ${MKLROOT}/lib/libmkl_scalapack_ilp64.a -Wl,--start-group ${MKLROOT}/lib/libmkl_intel_ilp64.a ${MKLROOT}/lib/libmkl_intel_thread.a ${MKLROOT}/lib/libmkl_core.a ${MKLROOT}/lib/libmkl_blacs_openmpi_ilp64.a -Wl,--end-group -liomp5 -lpthread -lm -ldl" \
--enable-mpi \
CXX=mpicxx \
CC=mpicc \
F77=mpif77 \
--enable-stokhos \
--enable-amesos2 \
--prefix=$HOME/XyceInstall/Parallel \

 

when I try to compile this code, I get the error attached.  I believe I don't have the correct flags set for my autoconfig file. The config log is also attached. I'm wondering if I could get some advice on how to resolve my issue. 

The code I'm trying to compile is Xyce using trilinos with third party math functions. 

0 Kudos
2 Replies
Fengrui
Moderator
475 Views

Could you try linking to oneMKL dynamically?

0 Kudos
eddywu
Beginner
418 Views

Hi @Fengrui ,

Thanks for the reply. Yes that helped it build. I now have the code built, but now I'm experiencing an issue with segmentation faults when trying to run my application. 

These are the error messages I get. 

[imagica-thinkstation:500114] *** Process received signal ***
[imagica-thinkstation:500114] Signal: Segmentation fault (11)
[imagica-thinkstation:500114] Signal code: Address not mapped (1)
[imagica-thinkstation:500114] Failing at address: 0x55d84b4439a8
[imagica-thinkstation:500114] [ 0] /lib/x86_64-linux-gnu/libc.so.6(+0x42520)[0x7f2d54842520]
[imagica-thinkstation:500114] [ 1] /opt/intel/oneapi/mkl/2024.0/lib/libmkl_avx2.so.2(mkl_blas_avx2_xidamax_nonan+0xa9)[0x7f2d494503c9]
[imagica-thinkstation:500114] [ 2] /opt/intel/oneapi/mkl/2024.0/lib/libmkl_avx2.so.2(mkl_blas_avx2_xidamax+0x40)[0x7f2d497122d0]
[imagica-thinkstation:500114] [ 3] /opt/intel/oneapi/mkl/2024.0/lib/libmkl_intel_thread.so.2(mkl_blas_idamax+0x3ee)[0x7f2d5a0552ee]
[imagica-thinkstation:500114] [ 4] /opt/intel/oneapi/mkl/2024.0/lib/libmkl_intel_ilp64.so.2(idamax+0xa6)[0x7f2d5c6bf8f6]
[imagica-thinkstation:500114] [ 5] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x2635fb2)[0x55a84a0d9fb2]
[imagica-thinkstation:500114] [ 6] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x26a8dcb)[0x55a84a14cdcb]
[imagica-thinkstation:500114] [ 7] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x9faa27)[0x55a84849ea27]
[imagica-thinkstation:500114] [ 8] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x9e045b)[0x55a84848445b]
[imagica-thinkstation:500114] [ 9] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x9e54e8)[0x55a8484894e8]
[imagica-thinkstation:500114] [10] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x9eefb2)[0x55a848492fb2]
[imagica-thinkstation:500114] [11] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x9ef3a8)[0x55a8484933a8]
[imagica-thinkstation:500114] [12] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x8e36bf)[0x55a8483876bf]
[imagica-thinkstation:500114] [13] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x8e6304)[0x55a84838a304]
[imagica-thinkstation:500114] [14] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x3b627d)[0x55a847e5a27d]
[imagica-thinkstation:500114] [15] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x3c1098)[0x55a847e65098]
[imagica-thinkstation:500114] [16] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x39b054)[0x55a847e3f054]
[imagica-thinkstation:500114] [17] /lib/x86_64-linux-gnu/libc.so.6(+0x29d90)[0x7f2d54829d90]
[imagica-thinkstation:500114] [18] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80)[0x7f2d54829e40]
[imagica-thinkstation:500114] [19] /home/imagica/XyceInstall/Parallel/bin/Xyce(+0x3af465)[0x55a847e53465]
[imagica-thinkstation:500114] *** End of error message ***

 

The autoconfig file I use to compile without error is below:

#!/bin/sh
../configure \
CXXFLAGS="-O3 -fopenmp -std=c++11" \
ARCHDIR="$HOME/XyceLibs/Parallel" \
CPPFLAGS="-DMKL_ILP64 -m64 -fPIC -I$MKLROOT/include" \
LDFLAGS=" -m64 -L${MKLROOT}/lib -lmkl_scalapack_ilp64 -Wl,--no-as-needed -lmkl_intel_ilp64 -lmkl_intel_thread -lmkl_core -lmkl_blacs_intelmpi_ilp64 -liomp5 -lpthread -lm -ldl" \
--enable-mpi \
CXX=mpicxx \
CC=mpicc \
F77=mpif77 \
--enable-stokhos \
--enable-amesos2 \
--prefix=$HOME/XyceInstall/Parallel \

0 Kudos
Reply