<?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 Hi Simen, in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-s-FFTW-wrappers-block-FFTW-on-linux-at-least/m-p/1152783#M27280</link>
    <description>&lt;P&gt;Hi Simen,&lt;BR /&gt;
	&lt;BR /&gt;
	​Thank you a lot for report the issue here and R,&amp;nbsp; also share your experience for workaround the problem.&lt;/P&gt;

&lt;P&gt;For your questions,&amp;nbsp;&lt;BR /&gt;
	would it be possible to ship MKL's fftw-wrappers separate from the working parts of MKL so that it would be possible to avoid the poor fftw masquerade?&lt;BR /&gt;
	​Yes,&amp;nbsp;&amp;nbsp;I can understand&amp;nbsp;two FFTW&amp;nbsp;could be problem.&amp;nbsp; and&amp;nbsp;&amp;nbsp;it is possible to separate the MKL Blas , MKL FFT etc .&lt;BR /&gt;
	The tool is&amp;nbsp;to &lt;STRONG&gt;use the MKL custom DLL&lt;/STRONG&gt;,&amp;nbsp; which&amp;nbsp;is supposed&amp;nbsp;for that purpose.&lt;BR /&gt;
	&lt;A href="https://software.intel.com/en-us/mkl-linux-developer-guide-building-custom-shared-objects" target="_blank"&gt;https://software.intel.com/en-us/mkl-linux-developer-guide-building-custom-shared-objects&lt;/A&gt;&lt;BR /&gt;
	​for example, under Linux:&lt;BR /&gt;
	&amp;gt;cp -r /opt/intel/compilers_and_libraries_2018/linux/mkl/tools/builder .&lt;BR /&gt;
	​&amp;gt;cd builder&lt;/P&gt;

&lt;P&gt;&amp;gt;make libintel64 parallel=gnu export=blas_example_list name=libRblas&lt;BR /&gt;
	Which will build one&amp;nbsp;Rblas&amp;nbsp;library based on&amp;nbsp;selected BLAS&amp;nbsp;API. Thus no MKL FFTW inference is mixed.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;
	&lt;BR /&gt;
	​I will consider to add it in our publish articles and notify R if possible.&lt;/P&gt;

&lt;P&gt;&lt;A href="https://software.intel.com/en-us/articles/using-intel-mkl-with-r​" target="_blank"&gt;https://software.intel.com/en-us/articles/using-intel-mkl-with-r​&lt;/A&gt;&lt;BR /&gt;
	&lt;BR /&gt;
	Best Regards,&lt;BR /&gt;
	​Ying&lt;/P&gt;</description>
    <pubDate>Mon, 09 Jul 2018 01:48:01 GMT</pubDate>
    <dc:creator>Ying_H_Intel</dc:creator>
    <dc:date>2018-07-09T01:48:01Z</dc:date>
    <item>
      <title>MKL's FFTW wrappers block FFTW on linux (at least)</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-s-FFTW-wrappers-block-FFTW-on-linux-at-least/m-p/1152782#M27279</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;This problem popped up downstream in R (&lt;A href="https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17443"&gt;https://bugs.r-project.org/bugzilla/show_bug.cgi?id=17443&lt;/A&gt;) when it is linked with MKL on Linux (I don't know about Windows/OSX). R is a an extensible program, one may write dlls/shared libraries in C which is linked into R at runtime. Now, here is a problem. MKL contains wrappers for fftw, some of them do not work, for instance multidimensional r2r transforms, or strided r2r transforms (which can easily be utilized to make multidimensional ones).&amp;nbsp; I make a shared library for R which uses these parts of fftw3:&lt;/P&gt;

&lt;P&gt;# gcc -shared -o foo.so foo.c -lfftw3&lt;/P&gt;

&lt;P&gt;Everything seems fine. I start R, it is linked with MKL to have a nice optimized, parallel BLAS, say -lmkl_rt, and loads symbols from there. When I from R load (dlopen) my foo.so, the fftw-references in there are resolved to MKL which is already loaded in R, and they do not work. There is no easy way for my foo.so to get hold of the real fftw3-routines. A workaround is a little bit cumbersome, I can either link R with parts of MKL static (like -Bstatic,-lmkl_gf_lp64,-Bdynamic -lmkl_gnu_threads ...), or link my foo.so with a static libfftw3.a, or preload R with LD_PRELOAD=libfftw3.so.&lt;/P&gt;

&lt;P&gt;My question is, would it be possible to ship MKL's fftw-wrappers separate from the working parts of MKL so that it would be possible to avoid the poor fftw masquerade?&lt;/P&gt;</description>
      <pubDate>Sat, 07 Jul 2018 21:25:35 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-s-FFTW-wrappers-block-FFTW-on-linux-at-least/m-p/1152782#M27279</guid>
      <dc:creator>Gaure__Simen</dc:creator>
      <dc:date>2018-07-07T21:25:35Z</dc:date>
    </item>
    <item>
      <title>Hi Simen,</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-s-FFTW-wrappers-block-FFTW-on-linux-at-least/m-p/1152783#M27280</link>
      <description>&lt;P&gt;Hi Simen,&lt;BR /&gt;
	&lt;BR /&gt;
	​Thank you a lot for report the issue here and R,&amp;nbsp; also share your experience for workaround the problem.&lt;/P&gt;

&lt;P&gt;For your questions,&amp;nbsp;&lt;BR /&gt;
	would it be possible to ship MKL's fftw-wrappers separate from the working parts of MKL so that it would be possible to avoid the poor fftw masquerade?&lt;BR /&gt;
	​Yes,&amp;nbsp;&amp;nbsp;I can understand&amp;nbsp;two FFTW&amp;nbsp;could be problem.&amp;nbsp; and&amp;nbsp;&amp;nbsp;it is possible to separate the MKL Blas , MKL FFT etc .&lt;BR /&gt;
	The tool is&amp;nbsp;to &lt;STRONG&gt;use the MKL custom DLL&lt;/STRONG&gt;,&amp;nbsp; which&amp;nbsp;is supposed&amp;nbsp;for that purpose.&lt;BR /&gt;
	&lt;A href="https://software.intel.com/en-us/mkl-linux-developer-guide-building-custom-shared-objects" target="_blank"&gt;https://software.intel.com/en-us/mkl-linux-developer-guide-building-custom-shared-objects&lt;/A&gt;&lt;BR /&gt;
	​for example, under Linux:&lt;BR /&gt;
	&amp;gt;cp -r /opt/intel/compilers_and_libraries_2018/linux/mkl/tools/builder .&lt;BR /&gt;
	​&amp;gt;cd builder&lt;/P&gt;

&lt;P&gt;&amp;gt;make libintel64 parallel=gnu export=blas_example_list name=libRblas&lt;BR /&gt;
	Which will build one&amp;nbsp;Rblas&amp;nbsp;library based on&amp;nbsp;selected BLAS&amp;nbsp;API. Thus no MKL FFTW inference is mixed.&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR /&gt;
	&lt;BR /&gt;
	​I will consider to add it in our publish articles and notify R if possible.&lt;/P&gt;

&lt;P&gt;&lt;A href="https://software.intel.com/en-us/articles/using-intel-mkl-with-r​" target="_blank"&gt;https://software.intel.com/en-us/articles/using-intel-mkl-with-r​&lt;/A&gt;&lt;BR /&gt;
	&lt;BR /&gt;
	Best Regards,&lt;BR /&gt;
	​Ying&lt;/P&gt;</description>
      <pubDate>Mon, 09 Jul 2018 01:48:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/MKL-s-FFTW-wrappers-block-FFTW-on-linux-at-least/m-p/1152783#M27280</guid>
      <dc:creator>Ying_H_Intel</dc:creator>
      <dc:date>2018-07-09T01:48:01Z</dc:date>
    </item>
  </channel>
</rss>

