- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hello,
i meet a problem in using pardiso. i tested the example:pardiso_sym.c.
1. if i test it alone, it run successfully.
2. if i copy it to my project and test as a function, it failed.
error msg:
*** Error in PARDISO ( insufficient_memory) error_num= 3
*** Error in PARDISO memory allocation: BEFORE_SYMBOLIC_FACTORIZATION, allocation of -3734628 bytes failed
total memory wanted here: -3734487 kbyte
environment:
1. ubuntu20.04
2. mkl version: 2022.0.2
3. set(MKL_INTERFACE lp64)
4. my app link with openblas
5. gcc 11
thank you for your suggestions.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Something went wrong in the course of converting the code in the stand-alone version of the Pardiso-sym example into a function that is a part of some larger code. It is next to impossible to tell what the error was without seeing the code after conversion.
A symptom of what went wrong is that the reported sizes of arrays that failed allocation are negative. Check whether there is inconsistent usage of 32-bit and 64-bit integers among the arguments to Pardiso, and check the argument lists.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Could you show how do you compile and link this case, please?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I took your example and added only main() to define the entry point.
Linking explicitly against the mkl's static libs like as follow ( see MKL_Linker Adviser) :
icl MKLROOT\include MKLROOT\mkl_intel_lp64.lib ..\intel64\mkl_intel_sequential.lib ..\intel64\mkl_core.lib
I see everything works as expected:
=== PARDISO: solving a symmetric indefinite system ===
1-based array indexing is turned ON
PARDISO double precision computation is turned ON
METIS algorithm at reorder step is turned ON
Scaling is turned ON
....................................................
....................................................
Summary: ( reordering phase )
================
Solve completed ...
The solution of the system is:
x [0] = -0.041860
x [1] = -0.003413
x [2] = 0.117250
x [3] = -0.112640
x [4] = 0.024172
x [5] = -0.107633
x [6] = 0.198720
x [7] = 0.190383
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
all codes are same except the function name.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
My project has other codes which use pardiso. it works well in windows, but reported the error in linux.
Then i tested pardiso_sym. it run successfully alone, but failed in my project.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you for your reply.
I did not convert code. All of them have same code except function name;
In my project, i invoke PardisoTest as following code:
void LargeAreaAnalyzer::benchmark()
{
PardisoTest();
}
i have other codes using pardiso, it works well in windows, but failed in linux;
Then i test pardiso_sym, it also failed in my project, but worked well in alone mode.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
if the standalone case works as expected, then you have to check how you pass all parameters to the mkl pardiso into your project.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I strongly suspect that the issue is in the interface being linked and compilation line.
Can you provide full compilation and link line in case you're running the code in your project?
Just making something reasonable up: CMake might link ilp64 by default and hence add smth like -DMKL_ILP64, while then when you set interface to lp64, it only corrects the interface library being linked but keeps the compilation flag which leads to integer size mismatch between the code in the project and the interface layer.
Best,
Kirill
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I think i set the correct interface:
set(MKL_INTERFACE lp64)
find_package(MKL REQUIRED)
if i use static mkl library, it run successfully.
set(MKL_INTERFACE lp64)
set(MKL_LINK static)
find_package(MKL REQUIRED)
if i design as following, it can also run suceefully:
My program struction:
I suspect that it could be effected by other library, maybe openblas?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The " Error in PARDISO ( reordering_phase) error_num= -180" problem indicates
wrongly using the CSR format by applying column indexes not in increasing order per row.
We recommend enabling the matrix checker (iparm[27]=1) which is disabled by default and always checking the error status returned by MKL Pardiso. In such cases, MKL Pardiso has to return -3 error.
The -180 problem is not documented and we will add it into one of the future releases.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
if i both link gomp and iomp, it will produce the error.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The issue has not been reproduced on our end and it is closing. We will no longer respond to this thread. If you require additional assistance from Intel, please start a new thread. Any further interaction in this thread will be considered community only.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page