<?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 Parallelism seems not working in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379824#M33077</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks for the confirmation.&lt;/P&gt;&lt;P&gt;As the issue is resolved we are closing this thread. Please post a new question if you need any additional assistance from Intel as this thread will no longer be monitored.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Have a Great Day!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vidya.&lt;/P&gt;&lt;BR /&gt;</description>
    <pubDate>Tue, 26 Apr 2022 15:55:42 GMT</pubDate>
    <dc:creator>VidyalathaB_Intel</dc:creator>
    <dc:date>2022-04-26T15:55:42Z</dc:date>
    <item>
      <title>MKL Parallelism seems not working</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379222#M33064</link>
      <description>&lt;P&gt;I have two same computers and ran the same code that used FFT functions of intel MKL in those PCs. However, the calculation speeds were about five times different. To find the reason, I took some tests, and those results were as follows.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1) I took some hardware tests, and they indicated hardware performance was comparable.&lt;/P&gt;
&lt;P&gt;2) I ran another code that did not use MKL, the calculation speeds were comparable.&lt;/P&gt;
&lt;P&gt;3) I monitored CPU usage, and the time using all cores seemed different. (slower was shorter)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Therefore, I am suspecting that the MKL is not parallelized in the slower PC.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I checked the max thread number of MKL (i.e., using mkl_get_max_threads) and confirmed that it was 16 in both PCs, that have 16 cores and 32 threads. Also, I reinstalled the one API package and saw that the difference in the calculation time became smaller by about two times. However, after some tests, the difference became about five times different again.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have no idea how I can confirm if this is the case and how I can fix this issue. Could anyone give me any advice?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If it is helpful, I will reinstall the OS (Ubuntu).&lt;/P&gt;</description>
      <pubDate>Sat, 23 Apr 2022 04:11:37 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379222#M33064</guid>
      <dc:creator>Tosh</dc:creator>
      <dc:date>2022-04-23T04:11:37Z</dc:date>
    </item>
    <item>
      <title>Re: MKL Parallelism seems not working</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379437#M33066</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for reaching out to us.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To proceed further in this case and to address it accordingly we request you to provide us with the following details.&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;MKL Version being used&lt;/LI&gt;
&lt;LI&gt;Timings that you are getting on both the computers&lt;/LI&gt;
&lt;LI&gt;Respective CPU models of the machines&lt;/LI&gt;
&lt;LI&gt;The command you are using to run the code so that we can understand which threading layer interface you are using (OpenMP/tbb)&lt;/LI&gt;
&lt;LI&gt;Sample reproducer to reproduce the issue from our end&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;Additionally, you can also check it from the output of verbose which gives you the execution timings of FFT calls in your code.&lt;/P&gt;
&lt;P&gt;Before running your code on both systems, please set the below environment variable as&lt;/P&gt;
&lt;P&gt;export MKL_VERBOSE=1&lt;/P&gt;
&lt;P&gt;For more details regarding the verbose environment variable please refer to the following link&lt;/P&gt;
&lt;P&gt;&lt;A href="https://www.intel.com/content/www/us/en/develop/documentation/onemkl-linux-developer-guide/top/managing-output/using-onemkl-verbose-mode.html" target="_blank" rel="noopener"&gt;https://www.intel.com/content/www/us/en/develop/documentation/onemkl-linux-developer-guide/top/managing-output/using-onemkl-verbose-mode.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please get back to us with the above information so that it will help us better in understanding the issue.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Vidya.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 06:50:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379437#M33066</guid>
      <dc:creator>VidyalathaB_Intel</dc:creator>
      <dc:date>2022-04-25T06:50:07Z</dc:date>
    </item>
    <item>
      <title>Re: MKL Parallelism seems not working</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379613#M33072</link>
      <description>&lt;P&gt;Hi Vidya,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you for your response. I appreciate it.&lt;BR /&gt;Actually, I found the reason of the speed difference.&lt;BR /&gt;If I compiled the code with an option '-check all,' the calculation speed suddenly decreased. &lt;BR /&gt;The calculation time was 6 sec without the option, but 1min 9sec with the option.&lt;BR /&gt;According to the results of Verbose mode, the timing of FFT is similar between those PCs.&lt;BR /&gt;The additional information are as follows.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;MKL Version being used&lt;/STRONG&gt;:&lt;/P&gt;
&lt;P&gt;Major version: 2022&lt;BR /&gt;Minor version: 0&lt;BR /&gt;Update version: 0&lt;BR /&gt;Product status: Product&lt;BR /&gt;Build: 20211112&lt;BR /&gt;Platform: Intel(R) 64 architecture&lt;BR /&gt;Processor optimization: Intel(R) Advanced Vector Extensions 512 (Intel(R) AVX-512) with support of Intel(R) Deep Learning Boost (Intel(R) DL Boost)&lt;/P&gt;
&lt;P&gt;================================================================&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Timings that you are getting on both the computers:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;I ran the attached test code and the timings are as follows:&lt;/P&gt;
&lt;P&gt;(PC1)&lt;/P&gt;
&lt;P&gt;Running Time: 1min 7sec, CPU Time: 237.7 sec&lt;/P&gt;
&lt;P&gt;(PC2)&lt;/P&gt;
&lt;P&gt;Running time: 1min 9sec, CPU Time: 238.2 sec&lt;/P&gt;
&lt;P&gt;================================================================&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Respective CPU models of the machines:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Intel(R) Core(TM) i9-10980XE CPU @ 3.00GHz&lt;/P&gt;
&lt;P&gt;================================================================&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;The command you are using to run the code so that we can understand which threading layer interface you are using (OpenMP/tbb)&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;I used&lt;/P&gt;
&lt;P&gt;'ifort -qopenmp -qmkl -traceback -check all test.f90'&lt;/P&gt;
&lt;P&gt;to compile the code and&lt;/P&gt;
&lt;P&gt;'./a.out &amp;amp;&amp;gt; out.txt &amp;amp;'&lt;/P&gt;
&lt;P&gt;to run the code.&lt;/P&gt;
&lt;P&gt;================================================================&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;Sample reproducer to reproduce the issue from our end:&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;I attached a sample code 'sample.f90'.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 20:41:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379613#M33072</guid>
      <dc:creator>Tosh</dc:creator>
      <dc:date>2022-04-25T20:41:27Z</dc:date>
    </item>
    <item>
      <title>Re:MKL Parallelism seems not working</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379776#M33075</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;gt;&amp;gt;&lt;I&gt;I found the reason of the speed difference.&lt;/I&gt;&lt;/P&gt;&lt;P&gt;Glad to know that and thanks for sharing the information with us.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&amp;gt;&amp;gt;&lt;I&gt;If I compiled the code with an option '-check all,' the calculation speed suddenly decreased.&lt;/I&gt;&lt;/P&gt;&lt;P&gt;Yes, you are right. I've tested it from my side and could see the difference with and without -check all option.&lt;/P&gt;&lt;P&gt;By including the -check all option it disables optimization and overrides any optimization level set by option O.&lt;/P&gt;&lt;P&gt;Reference Link: &lt;A href="https://www.intel.com/content/www/us/en/develop/documentation/fortran-compiler-oneapi-dev-guide-and-reference/top/compiler-reference/compiler-options/compiler-option-details/language-options/check.html" target="_blank"&gt;https://www.intel.com/content/www/us/en/develop/documentation/fortran-compiler-oneapi-dev-guide-and-reference/top/compiler-reference/compiler-options/compiler-option-details/language-options/check.html&lt;/A&gt;&lt;/P&gt;&lt;P&gt;So this might be the reason behind the decreased speed.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;As the issue is resolved, could you please confirm if we can close this thread from our end?&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vidya.&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 26 Apr 2022 10:45:54 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379776#M33075</guid>
      <dc:creator>VidyalathaB_Intel</dc:creator>
      <dc:date>2022-04-26T10:45:54Z</dc:date>
    </item>
    <item>
      <title>Re:MKL Parallelism seems not working</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379824#M33077</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks for the confirmation.&lt;/P&gt;&lt;P&gt;As the issue is resolved we are closing this thread. Please post a new question if you need any additional assistance from Intel as this thread will no longer be monitored.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Have a Great Day!&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vidya.&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 26 Apr 2022 15:55:42 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-Parallelism-seems-not-working/m-p/1379824#M33077</guid>
      <dc:creator>VidyalathaB_Intel</dc:creator>
      <dc:date>2022-04-26T15:55:42Z</dc:date>
    </item>
  </channel>
</rss>

