<?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 here are my code and matrix  in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181184#M29338</link>
    <description>&lt;P&gt;here are my code and matrix&amp;nbsp;&lt;/P&gt;

&lt;P&gt;thanks for your help ~&lt;/P&gt;</description>
    <pubDate>Thu, 06 Sep 2018 00:05:20 GMT</pubDate>
    <dc:creator>Li__Yishui</dc:creator>
    <dc:date>2018-09-06T00:05:20Z</dc:date>
    <item>
      <title>mkl_dcsrbsr gives segmentation fault</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181182#M29336</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;when I use mkl_dcsrbsr to convert a large CSR matrix into BSR, it will give me segmentation fault. But it run correctly, when the matrix size is small.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;here is my code(my icc version is 15.0.1)&lt;/P&gt;

&lt;DIV&gt;//m is the dimension of CSR matrix and nnz is the number of non zero element in this matrix&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;double *acsr;&lt;BR /&gt;
	&amp;nbsp;acsr = (double *)mkl_malloc(*nnz*sizeof(double), 64);//data in csr&lt;BR /&gt;
	&amp;nbsp;int *ja, *ia;&lt;BR /&gt;
	&amp;nbsp;ja = (int *)mkl_malloc(*nnz*sizeof(int), 64);//column in csr&lt;BR /&gt;
	&amp;nbsp;ia = (int *)mkl_malloc((*m + 1)*sizeof(int), 64);//row in csr&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;//read the CSR matrix&lt;/DIV&gt;

&lt;DIV&gt;int *mblk,*ldabsr;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;mblk = (int *)mkl_malloc(sizeof(int), 64);&lt;BR /&gt;
	&amp;nbsp;ldabsr = (int *)mkl_malloc(sizeof(int), 64);&lt;BR /&gt;
	&amp;nbsp;&lt;BR /&gt;
	&amp;nbsp;*mblk = 4; *ldabsr = 16;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;double *absr;&lt;BR /&gt;
	&amp;nbsp;absr = (double*)mkl_malloc(((*nnz)*(*mblk)*(*mblk))*sizeof(double *), 64);//data in bsr&lt;BR /&gt;
	&lt;BR /&gt;
	&amp;nbsp;int *jab, *iab;&lt;BR /&gt;
	&amp;nbsp;int ld = (*m) / (*mblk) + 1;&lt;BR /&gt;
	&amp;nbsp;jab = (int *)mkl_malloc(ld*ld*sizeof(int), 64);//column in bsr&lt;BR /&gt;
	&amp;nbsp;iab = (int *)mkl_malloc((*m+1)*sizeof(int),64);&lt;BR /&gt;
	&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;int *job;&lt;BR /&gt;
	&amp;nbsp;job = (int *)mkl_malloc(6 * sizeof(int), 64);&lt;BR /&gt;
	&amp;nbsp;job[0] = 0; job[1] = 0; job[2] = 0; job[5] = 3;&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;int *info; info = (int *)mkl_malloc(sizeof(int), 64);&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;mkl_dcsrbsr(job, m, mblk, ldabsr, acsr, ja, ia, absr, jab, iab, info);&lt;/DIV&gt;

&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="display: inline !important; float: none; background-color: transparent; color: rgb(83, 87, 94); font-family: &amp;quot;Arial&amp;quot;,&amp;quot;宋体&amp;quot;,&amp;quot;Tahoma&amp;quot;,&amp;quot;Helvetica&amp;quot;,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px;"&gt;I want to know what's wrong with my code or this function cannot convert big matrix?&lt;/SPAN&gt;&lt;/DIV&gt;

&lt;DIV&gt;&lt;SPAN style="display: inline !important; float: none; background-color: transparent; color: rgb(83, 87, 94); font-family: &amp;quot;Arial&amp;quot;,&amp;quot;宋体&amp;quot;,&amp;quot;Tahoma&amp;quot;,&amp;quot;Helvetica&amp;quot;,sans-serif; font-size: 13px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px;"&gt;thank you ~ :)&lt;/SPAN&gt;&lt;/DIV&gt;</description>
      <pubDate>Wed, 05 Sep 2018 14:50:51 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181182#M29336</guid>
      <dc:creator>Li__Yishui</dc:creator>
      <dc:date>2018-09-05T14:50:51Z</dc:date>
    </item>
    <item>
      <title>Please provide complete test</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181183#M29337</link>
      <description>&lt;P&gt;Please provide complete test source codes that can be compiled and run, along with matrix data files, for (i) a case where the run is correct, and (ii) a case where the program crashes.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Sep 2018 22:41:40 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181183#M29337</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2018-09-05T22:41:40Z</dc:date>
    </item>
    <item>
      <title>here are my code and matrix </title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181184#M29338</link>
      <description>&lt;P&gt;here are my code and matrix&amp;nbsp;&lt;/P&gt;

&lt;P&gt;thanks for your help ~&lt;/P&gt;</description>
      <pubDate>Thu, 06 Sep 2018 00:05:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/mkl-dcsrbsr-gives-segmentation-fault/m-p/1181184#M29338</guid>
      <dc:creator>Li__Yishui</dc:creator>
      <dc:date>2018-09-06T00:05:20Z</dc:date>
    </item>
  </channel>
</rss>

