<?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:An interesting problem on DPCPP in Intel® oneAPI DPC++/C++ Compiler</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1311651#M1530</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. If you need any additional information, please submit a new question as this thread will no longer be monitored.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
    <pubDate>Thu, 02 Sep 2021 06:28:24 GMT</pubDate>
    <dc:creator>ShanmukhS_Intel</dc:creator>
    <dc:date>2021-09-02T06:28:24Z</dc:date>
    <item>
      <title>An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307341#M1492</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;kernelfunc_1(sycl::queue&amp;amp;Q, int *ptr1,int*ptr2) {&lt;/P&gt;
&lt;P&gt;image im3(ptr1, image_channel_order::rgba, image_channel_type::unsigned_int32, range{ M,N,L });&lt;BR /&gt;&lt;BR /&gt;try&lt;BR /&gt;{&lt;BR /&gt;auto ev3 = Q.submit([&amp;amp;](handler &amp;amp;h) {&lt;BR /&gt;&lt;BR /&gt;auto out = sycl::stream(1024, 1024, h);&lt;BR /&gt;accessor&amp;lt;int4, 2, access::mode::write, access::target::image_array&amp;gt; acs3_w(im3, h);&lt;BR /&gt;im3.set_final_data(ptr1);&lt;BR /&gt;h.parallel_for(nd_range{ range{ M ,N,L}, range{ 1,1,1 } }, [=](nd_item&amp;lt;3&amp;gt; it) {&lt;BR /&gt;int idx = it.get_global_linear_id();&lt;BR /&gt;if (idx == 0) {&lt;BR /&gt;for (int k = 0; k &amp;lt; L; k++) {&lt;BR /&gt;out &amp;lt;&amp;lt; "layer:" &amp;lt;&amp;lt; k &amp;lt;&amp;lt; ":" &amp;lt;&amp;lt; sycl::endl;&lt;BR /&gt;for (int i = 0; i &amp;lt; M; i++) {&lt;BR /&gt;for (int j = 0; j &amp;lt; N; j++)&lt;BR /&gt;{&lt;BR /&gt;if (i == 0 &amp;amp;&amp;amp; j == 0 &amp;amp;&amp;amp; k == 0) continue;&lt;BR /&gt;acs3_w[k].write(int2(i, j), int4(1, 2, 3, 4));&lt;BR /&gt;}&lt;BR /&gt;out &amp;lt;&amp;lt; sycl::endl;&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;}&lt;/P&gt;
&lt;P&gt;});&lt;BR /&gt;}&lt;BR /&gt;);&lt;BR /&gt;return ev3;&lt;BR /&gt;}&lt;BR /&gt;catch (const std::exception&amp;amp; e)&lt;BR /&gt;{&lt;BR /&gt;std::cout &amp;lt;&amp;lt; "An exception is caught for vector add.\n" &amp;lt;&amp;lt; e.what();&lt;BR /&gt;std::terminate();&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;auto kernelfunc_2(sycl::queue&amp;amp;Q, int *ptr1, int*ptr2) {&lt;BR /&gt;Q.wait();&lt;BR /&gt;buffer ptr(ptr1, range{ N*M*L*C });&lt;BR /&gt;ptr.set_final_data(ptr2);&lt;/P&gt;
&lt;P&gt;try&lt;BR /&gt;{&lt;BR /&gt;auto ev2 = Q.submit([&amp;amp;](handler &amp;amp;h) {&lt;BR /&gt;ptr.set_final_data(ptr2);&lt;BR /&gt;accessor acs(ptr, h);&lt;BR /&gt;auto out = sycl::stream(1024, 1024, h);&lt;BR /&gt;h.parallel_for(nd_range{ range{ M ,N,L}, range{ 1,1,1 } }, [=](nd_item&amp;lt;3&amp;gt; it) {&lt;/P&gt;
&lt;P&gt;int idx = it.get_global_linear_id();&lt;BR /&gt;if (idx == 0) {&lt;BR /&gt;for (int k = 0; k &amp;lt; L; k++) {&lt;BR /&gt;acs[0] = 999;&lt;BR /&gt;}&lt;BR /&gt;}&lt;BR /&gt;});&lt;BR /&gt;}&lt;BR /&gt;);&lt;BR /&gt;return ev2;&lt;BR /&gt;}&lt;BR /&gt;catch (const std::exception&amp;amp; e)&lt;BR /&gt;{&lt;BR /&gt;std::cout &amp;lt;&amp;lt; "An exception is caught for vector add.\n" &amp;lt;&amp;lt; e.what();&lt;BR /&gt;std::terminate();&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;int main(){&lt;/P&gt;
&lt;P&gt;kernelfunc_1(Q, host_array3_2,host_array3_2);&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;kernelfunc_2(Q, shared_array3_2, shared_array3_2);&lt;/P&gt;
&lt;P&gt;---------------------v1---------------------------------------------&lt;/P&gt;
&lt;P&gt;kernelfunc_1(Q, host_array3_2,shared_array3_2);&lt;/P&gt;
&lt;P&gt;kernelfunc_2(Q, shared_array3_2, shared_array3_2);&lt;/P&gt;
&lt;P&gt;----------------------v2--------------------------------------------&lt;/P&gt;
&lt;P&gt;The V1 can produce the correct result. Obviously, there is no relationship between the two functions.&lt;/P&gt;
&lt;P&gt;However, the V2 REALLY confuses me a lot, as you can see in the&amp;nbsp;kernelfunc_1, I&amp;nbsp; didn't use the shared_array3_2, why the v2 will get stuck like this:&amp;nbsp;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screenshot 2021-08-17 121435.png" style="width: 999px;"&gt;&lt;img src="https://community.intel.com/t5/image/serverpage/image-id/18860iE89960A810A8299F/image-size/large?v=v2&amp;amp;px=999&amp;amp;whitelist-exif-data=Orientation%2CResolution%2COriginalDefaultFinalSize%2CCopyright" role="button" title="Screenshot 2021-08-17 121435.png" alt="Screenshot 2021-08-17 121435.png" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;Screenshot 2021-08-17 121435.png&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;&lt;STRONG class="sub_section_element_selectors"&gt;my programming environment :&lt;/STRONG&gt;&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;VS2017&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;one API DPC++ Compiler&amp;nbsp; (2021.3.0)&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;windows 10.&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;can anybody tell me why?&lt;/P&gt;
&lt;P class="sub_section_element_selectors"&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;}&lt;/P&gt;</description>
      <pubDate>Tue, 17 Aug 2021 04:24:02 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307341#M1492</guid>
      <dc:creator>shenuo</dc:creator>
      <dc:date>2021-08-17T04:24:02Z</dc:date>
    </item>
    <item>
      <title>Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307437#M1493</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thanks for reaching out to us.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;We have tried executing your code in "Intel oneAPI command prompt for Intel 64 for Visual Studio 2019" and in Visual Studio 2019 (release mode).&lt;/P&gt;&lt;P&gt;We see that the code compiles fine with smooth exit under our system environment.&lt;/P&gt;&lt;P&gt;&lt;B&gt;Our system environment :&lt;/B&gt;&lt;/P&gt;&lt;P&gt;VS2019-16.9.0&lt;/P&gt;&lt;P&gt;one API DPC++ Compiler (2021.3.0)&lt;/P&gt;&lt;P&gt;windows 10.&lt;/P&gt;&lt;P&gt;We'd like to request you to provide the Visual Studio version being used.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Tue, 17 Aug 2021 11:26:38 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307437#M1493</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2021-08-17T11:26:38Z</dc:date>
    </item>
    <item>
      <title>Re: Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307621#M1496</link>
      <description>&lt;P&gt;Glad to see your reply!&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;You remind me that this problem may lay in the hardware environment. So I move my code to another PC(desktop), under the same software environment(VS2017(10.0.17763.0),&amp;nbsp;&lt;SPAN&gt;one API DPC++ Compiler (2021.3.0), windows 10.&lt;/SPAN&gt;), it works fine. I can tell you my laptop is core i7-10610U CPU with Graphics UHD620(driver version 27.20.100.9320)（my desktop is&amp;nbsp; i7-8700 &amp;amp;UHD 630(30.0.100.9684) )&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 01:27:43 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307621#M1496</guid>
      <dc:creator>shenuo</dc:creator>
      <dc:date>2021-08-18T01:27:43Z</dc:date>
    </item>
    <item>
      <title>Re: An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307760#M1498</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;&amp;gt;&amp;gt;You remind me that this problem may lay in the hardware environment.&lt;/P&gt;
&lt;P&gt;Below is the link for oneAPI Base Toolkit System Requirements.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://software.intel.com/content/www/us/en/develop/articles/intel-oneapi-base-toolkit-system-requirements.html" target="_blank" rel="noopener"&gt;https://software.intel.com/content/www/us/en/develop/articles/intel-oneapi-base-toolkit-system-requirements.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In addition, Below is the link for list of versions of Visual Studio supported for latest oneAPI 2021.3&lt;/P&gt;
&lt;P&gt;&lt;A href="https://software.intel.com/content/www/us/en/develop/articles/intel-compilers-compatibility-with-microsoft-visual-studio-and-xcode.html" target="_blank" rel="noopener"&gt;https://software.intel.com/content/www/us/en/develop/articles/intel-compilers-compatibility-with-microsoft-visual-studio-and-xcode.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regards,&lt;/P&gt;
&lt;P&gt;Shanmukh.SS&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Aug 2021 11:18:59 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1307760#M1498</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2021-08-18T11:18:59Z</dc:date>
    </item>
    <item>
      <title>Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309653#M1511</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Reminder:&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Has the information provided helped? Could you please confirm whether we could close this thread from our end.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 25 Aug 2021 05:42:49 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309653#M1511</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2021-08-25T05:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309891#M1518</link>
      <description>&lt;P&gt;Yes , It really helps, and thank you, but I don't know how to mark it as acceptable.&lt;/P&gt;</description>
      <pubDate>Thu, 26 Aug 2021 00:43:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309891#M1518</guid>
      <dc:creator>shenuo</dc:creator>
      <dc:date>2021-08-26T00:43:48Z</dc:date>
    </item>
    <item>
      <title>Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309990#M1519</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Thank you for the confirmation. To mark it as accepted, You can find "Accept as solution" option under our reply.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 26 Aug 2021 10:26:10 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1309990#M1519</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2021-08-26T10:26:10Z</dc:date>
    </item>
    <item>
      <title>Re:An interesting problem on DPCPP</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1311651#M1530</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. If you need any additional information, please submit a new question as this thread will no longer be monitored.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Shanmukh.SS&lt;/P&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 02 Sep 2021 06:28:24 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/An-interesting-problem-on-DPCPP/m-p/1311651#M1530</guid>
      <dc:creator>ShanmukhS_Intel</dc:creator>
      <dc:date>2021-09-02T06:28:24Z</dc:date>
    </item>
  </channel>
</rss>

