<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: MKL PARDISO crashes when run in parallel in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1354042#M32656</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you for sharing the information and posting on Intel Communities.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;gt;&amp;gt;&lt;EM&gt;Actually, I have just sorted this out. In my case, the pattern of A is fixed, i.e., both 'ia' and 'ja' are fixed.&amp;nbsp;So I store them as public data such that they can be fetched by each thread during the computation.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Glad to know that your issue is resolved. Could you please let us know if we could close this thread at our end.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Shanmukh.SS&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 08 Mar 2022 10:47:48 GMT</pubDate>
    <dc:creator>ShanmukhS_Intel</dc:creator>
    <dc:date>2022-03-08T10:47:48Z</dc:date>
    <item>
      <title>MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353725#M32653</link>
      <description>&lt;P&gt;Hi, I'm developing code based on matlab, and this code is accelerated with mex function.&lt;/P&gt;
&lt;P&gt;In the mex function, I have multiple linear system, Ax = b, to be solved, with A the sparse matrix stored in CSC format.&amp;nbsp; Of course, I know MKL PARDISO can run in parallel by directly setting variable MKL_DOMAIN_PARDISO.&amp;nbsp; However,&amp;nbsp; in my case, since multiple linear systems are to be solved, I want to set the thread for all MKL part to be one, while the assembly of the sparse matrix A and the call of MKL PARDISO run in parallel.&lt;/P&gt;
&lt;P&gt;Since this code is a little complex, I just show the sketch here,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;mkl_set_num_threads(thread);&lt;/P&gt;
&lt;P&gt;#pragma omp parallel for num_threads(THREADS)&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;for(&amp;nbsp; int i=0; i&amp;lt;Ele2d;i++)&lt;/P&gt;
&lt;P&gt;{&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; Stage one: Assemble&amp;nbsp;the sparse matrix A&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; Stage two: Call MKL PARDISO to solve this linear system follow the example provided in file&amp;nbsp;pardiso_unsym.c in the example folder.&lt;/P&gt;
&lt;P&gt;}&lt;/P&gt;
&lt;P&gt;This program can run in serial mode, while crashes in parallel mode.&amp;nbsp; The stack trace is as follows,&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 921px;"&gt;&lt;img src="https://community.intel.com/t5/image/serverpage/image-id/25920i193522781B016005/image-size/large/is-moderation-mode/true?v=v2&amp;amp;px=999&amp;amp;whitelist-exif-data=Orientation%2CResolution%2COriginalDefaultFinalSize%2CCopyright" role="button" title="Capture.PNG" alt="Capture.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;And the compile commands are as follows,&lt;/P&gt;
&lt;P&gt;thread = 6;&lt;BR /&gt;mex('-v',['COMPFLAGS=$COMPFLAGS /openmp -DTHREADS=', num2str(thread)], ['LDFLAGS=$LDFLAGS /openmp'], '-largeArrayDims',...&lt;BR /&gt;'-ID:\Software\Intel\Install\mkl\2022.0.0\include', '-ID:\PhdResearch\NdgMath', '-LD:\Software\Intel\Install\mkl\2022.0.0\lib\intel64',...&lt;BR /&gt;'-lmkl_intel_lp64_dll.lib', '-lmkl_core_dll.lib', '-lmkl_intel_thread_dll.lib', ...&lt;BR /&gt;'mxSparseVersionUpdateImplicitRHS.c','D:\PhdResearch\NdgMath\NdgMemory.c','mxImplicitVerticalEddyViscosity.c')&lt;/P&gt;
&lt;P&gt;What may cause this? Thanks in advance&lt;/P&gt;</description>
      <pubDate>Sat, 22 Jan 2022 16:37:16 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353725#M32653</guid>
      <dc:creator>Rylan1</dc:creator>
      <dc:date>2022-01-22T16:37:16Z</dc:date>
    </item>
    <item>
      <title>Re: MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353726#M32654</link>
      <description>&lt;P&gt;&lt;SPAN&gt;There is a mistake in the post, I set the global thread for MKL part to be one, i.e.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;mkl_set_num_threads(1);&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 22 Jan 2022 16:42:58 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353726#M32654</guid>
      <dc:creator>Rylan1</dc:creator>
      <dc:date>2022-01-22T16:42:58Z</dc:date>
    </item>
    <item>
      <title>Re: MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353800#M32655</link>
      <description>&lt;P&gt;Acctually, I have just sorted this out.&lt;/P&gt;
&lt;P&gt;In my case, the pattern of A is fixed, i.e., both 'ia' and 'ja' are fixed.&amp;nbsp; So I store them as public data such that they can be fetched by each thread during the computation.&lt;/P&gt;
&lt;P&gt;Tests indicate that this is not doable, and I have to set both 'ia' and 'ja' for each thread independently.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 23 Jan 2022 07:30:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1353800#M32655</guid>
      <dc:creator>Rylan1</dc:creator>
      <dc:date>2022-01-23T07:30:20Z</dc:date>
    </item>
    <item>
      <title>Re: MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1354042#M32656</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you for sharing the information and posting on Intel Communities.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;gt;&amp;gt;&lt;EM&gt;Actually, I have just sorted this out. In my case, the pattern of A is fixed, i.e., both 'ia' and 'ja' are fixed.&amp;nbsp;So I store them as public data such that they can be fetched by each thread during the computation.&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Glad to know that your issue is resolved. Could you please let us know if we could close this thread at our end.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Shanmukh.SS&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 08 Mar 2022 10:47:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1354042#M32656</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2022-03-08T10:47:48Z</dc:date>
    </item>
    <item>
      <title>Re: Re:MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1354051#M32658</link>
      <description>&lt;P&gt;yes, just close this thread.&lt;/P&gt;</description>
      <pubDate>Mon, 24 Jan 2022 12:03:05 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1354051#M32658</guid>
      <dc:creator>Rylan1</dc:creator>
      <dc:date>2022-01-24T12:03:05Z</dc:date>
    </item>
    <item>
      <title>Re:MKL PARDISO crashes when run in parallel</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1355014#M32668</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Glad to know that your issue is resolved. Thanks for sharing the solution with us. If you need any additional information, please post a new question as this thread will no longer be monitored by Intel.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 27 Jan 2022 06:06:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-PARDISO-crashes-when-run-in-parallel/m-p/1355014#M32668</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2022-01-27T06:06:39Z</dc:date>
    </item>
  </channel>
</rss>

