<?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 Kernel doesn't finish building on CPU in OpenCL* for CPU</title>
    <link>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1196550#M6807</link>
    <description>&lt;P&gt;The following kernel runs fine on my GPU (GTX 1060) and my iGPU on my i5-6500&lt;/P&gt;
&lt;P&gt;But if I run this on my CPU, it doesn't go past the clBuildProgram function&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't get any error, the&amp;nbsp;clBuildProgram executes forever&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;__kernel void multiply(__global int* res, __global int* b, __global int* p, __global int* r,  __global int* q, const int count, const int am, const int bn)
{
    int l, j, k;
    
    int i = get_global_id(0);

    //printf("\n\n%d", i);

    {
        for(j = 0; j &amp;lt; am;)
        {
            l = 0;
            for (int k = 0; k &amp;lt; count; k++)
            {
                *(res + j * bn + i) += p[k] * *(b + r[k] * bn + i);

                if (k == (q[l + 1] - 1))
                {
                    j++;
                    l++;
                }
            }
        }
    }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was able to recreate this error on a different PC as well&lt;/P&gt;
&lt;P&gt;Why is this happening and how can I fix this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sat, 01 Aug 2020 09:00:43 GMT</pubDate>
    <dc:creator>Vishvas</dc:creator>
    <dc:date>2020-08-01T09:00:43Z</dc:date>
    <item>
      <title>Kernel doesn't finish building on CPU</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1196550#M6807</link>
      <description>&lt;P&gt;The following kernel runs fine on my GPU (GTX 1060) and my iGPU on my i5-6500&lt;/P&gt;
&lt;P&gt;But if I run this on my CPU, it doesn't go past the clBuildProgram function&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't get any error, the&amp;nbsp;clBuildProgram executes forever&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="cpp"&gt;__kernel void multiply(__global int* res, __global int* b, __global int* p, __global int* r,  __global int* q, const int count, const int am, const int bn)
{
    int l, j, k;
    
    int i = get_global_id(0);

    //printf("\n\n%d", i);

    {
        for(j = 0; j &amp;lt; am;)
        {
            l = 0;
            for (int k = 0; k &amp;lt; count; k++)
            {
                *(res + j * bn + i) += p[k] * *(b + r[k] * bn + i);

                if (k == (q[l + 1] - 1))
                {
                    j++;
                    l++;
                }
            }
        }
    }
}&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I was able to recreate this error on a different PC as well&lt;/P&gt;
&lt;P&gt;Why is this happening and how can I fix this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 01 Aug 2020 09:00:43 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1196550#M6807</guid>
      <dc:creator>Vishvas</dc:creator>
      <dc:date>2020-08-01T09:00:43Z</dc:date>
    </item>
    <item>
      <title>Re: Kernel doesn't finish building on CPU</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1198356#M6814</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Condition, in theory, can be triggered rarely, and it depends on "q", and what's there.&lt;/P&gt;
&lt;P&gt;Can you send your host_code, where you run this kernel?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best regards,&lt;/P&gt;
&lt;P&gt;Sergey&lt;/P&gt;</description>
      <pubDate>Fri, 07 Aug 2020 14:36:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1198356#M6814</guid>
      <dc:creator>Sergey_I_Intel1</dc:creator>
      <dc:date>2020-08-07T14:36:00Z</dc:date>
    </item>
    <item>
      <title>Re: Kernel doesn't finish building on CPU</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1198559#M6815</link>
      <description>&lt;P&gt;I've attached the host code&lt;/P&gt;
&lt;P&gt;One thing I noticed is that if I uncomment the print statement in my kernel, then the code runs without any issues&lt;/P&gt;
&lt;P&gt;The&amp;nbsp;clBuildProgram function is in line 305&lt;/P&gt;</description>
      <pubDate>Sat, 08 Aug 2020 07:03:42 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/Kernel-doesn-t-finish-building-on-CPU/m-p/1198559#M6815</guid>
      <dc:creator>Vishvas</dc:creator>
      <dc:date>2020-08-08T07:03:42Z</dc:date>
    </item>
  </channel>
</rss>

