<?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 Robert, in OpenCL* for CPU</title>
    <link>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077034#M4573</link>
    <description>&lt;P&gt;Hi Robert,&lt;/P&gt;

&lt;P&gt;I thought the whole point of not setting "&lt;SPAN style="color: rgb(0, 0, 0); font-family: 'courier new', monospace; font-size: 16px; line-height: normal;"&gt;CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE"&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.008px; line-height: 21.68px;"&gt;&amp;nbsp;was to make sure enqueued calls were running in order.&lt;BR /&gt;
	I will try waiting for events and see if it solves my problem. Calling clFinish() is not an option as I'm trying to make CPU and GPU execution overlap as much as possible. Instead I am polling on events before sending my next batch of work to the GPU.&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 26 Nov 2015 07:10:51 GMT</pubDate>
    <dc:creator>Kaj_W_</dc:creator>
    <dc:date>2015-11-26T07:10:51Z</dc:date>
    <item>
      <title>clEnqueueWriteBuffer does not finish before Kernel</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077032#M4571</link>
      <description>&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Hi,&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;in my program I am doing several&amp;nbsp;&lt;/P&gt;

&lt;P&gt;clEnqueueWriteBuffer(queue, pDeviceMem, CL_FALSE, 0, mySize, pMyObject, 0, nullptr, nullptr);&lt;/P&gt;

&lt;P&gt;before a kernel launch, and expect these operations to finish before the kernel starts.&lt;/P&gt;

&lt;P&gt;I am running an In-order queue. However about 50% of the kernel launches don't get the values that should have been entered by&amp;nbsp;&lt;SPAN style="font-size: 13.008px; line-height: 21.68px;"&gt;clEnqueueWriteBuffer.&amp;nbsp;&lt;BR /&gt;
	If I set the "blocking flag" to CL_TRUE, the behaviour is as expected. Also on NVidia HW the behaviour is OK when running non-blocking buffer writes.&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 13.008px; line-height: 21.68px;"&gt;My system is running Windows 7, and Intel HD4600 with the latest driver..&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 13.008px; line-height: 21.68px;"&gt;Have you got any hints? Do I need to use a certain type of memory (Pinned, mappep/unmapped etc.) or should non-blocking operations work on CL memory created without the USE_HOST_MEMORY?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Nov 2015 14:35:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077032#M4571</guid>
      <dc:creator>Kaj_W_</dc:creator>
      <dc:date>2015-11-20T14:35:20Z</dc:date>
    </item>
    <item>
      <title>Hi Kaj,</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077033#M4572</link>
      <description>&lt;P&gt;Hi Kaj,&lt;/P&gt;

&lt;P&gt;You can get an event from each of the non-blocking clEnqueueWriteBuffer call and then wait for those events to complete prior to launching the kernel. Another option would be to call clFinish. See this discussion &lt;A href="https://community.amd.com/thread/159601"&gt;https://community.amd.com/thread/159601&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;Otherwise, you are asking for trouble, since non-blocking calls are not guaranteed to finish when you launch your kernel: you just lucked out with NVidia runtime.&lt;/P&gt;</description>
      <pubDate>Wed, 25 Nov 2015 19:43:47 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077033#M4572</guid>
      <dc:creator>Robert_I_Intel</dc:creator>
      <dc:date>2015-11-25T19:43:47Z</dc:date>
    </item>
    <item>
      <title>Hi Robert,</title>
      <link>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077034#M4573</link>
      <description>&lt;P&gt;Hi Robert,&lt;/P&gt;

&lt;P&gt;I thought the whole point of not setting "&lt;SPAN style="color: rgb(0, 0, 0); font-family: 'courier new', monospace; font-size: 16px; line-height: normal;"&gt;CL_QUEUE_OUT_OF_ORDER_EXEC_MODE_ENABLE"&lt;/SPAN&gt;&lt;SPAN style="font-size: 13.008px; line-height: 21.68px;"&gt;&amp;nbsp;was to make sure enqueued calls were running in order.&lt;BR /&gt;
	I will try waiting for events and see if it solves my problem. Calling clFinish() is not an option as I'm trying to make CPU and GPU execution overlap as much as possible. Instead I am polling on events before sending my next batch of work to the GPU.&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 26 Nov 2015 07:10:51 GMT</pubDate>
      <guid>https://community.intel.com/t5/OpenCL-for-CPU/clEnqueueWriteBuffer-does-not-finish-before-Kernel/m-p/1077034#M4573</guid>
      <dc:creator>Kaj_W_</dc:creator>
      <dc:date>2015-11-26T07:10:51Z</dc:date>
    </item>
  </channel>
</rss>

