<?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 Unexpected runtime issue when migrating from Intel C++ Compiler 2025.0.1.28 to 2025.3.0.326 in Intel® oneAPI DPC++/C++ Compiler</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Unexpected-runtime-issue-when-migrating-from-Intel-C-Compiler/m-p/1731487#M4647</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I am working on an application that was previously compiled with Intel C++ Compiler 2025.0.1.28. The application includes the following function, which is intended to return 1 if the input string is empty and 0 otherwise. With version 2025.0.1.28, the function behaved as expected.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; int ParserCheckZeroLengthString(char* pStr)&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;// check if this is a zero-length string&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (NULL== pStr || pStr[0]=='\0')&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return 1;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return 0;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; }&lt;/P&gt;&lt;P&gt;After upgrading to Intel C++ Compiler 2025.3.0.326, the build completes successfully, but at runtime the function incorrectly returns 0 instead of 1 when the string is empty.&lt;/P&gt;&lt;P&gt;We are suspecting this issue may be related to compiler optimisations.&lt;/P&gt;&lt;P&gt;To address this, we attempted to disable or reduce optimisation using the following CMake flags, but they had no effect: Function continued to return 0 for empty parameter string.&lt;/P&gt;&lt;P&gt;////Disable optimisation&lt;/P&gt;&lt;P&gt;-DCMAKE_CXX_FLAGS_RELEASE="/Od /DNDEBUG"&lt;BR /&gt;-DCMAKE_C_FLAGS_RELEASE="/Od&amp;nbsp; /DNDEBUG"&lt;/P&gt;&lt;P&gt;and&amp;nbsp;&lt;BR /&gt;////Reduce optimisation level&lt;BR /&gt;-DCMAKE_CXX_FLAGS_RELEASE="/O2 /Ob2&amp;nbsp;/DNDEBUG"&lt;BR /&gt;-DCMAKE_C_FLAGS_RELEASE="/O2&amp;nbsp; /Ob2/DNDEBUG"&lt;/P&gt;&lt;P&gt;Question:&lt;BR /&gt;How can we compile the existing code base with Intel C++ Compiler 2025.3.0.326 while preserving the same runtime behaviour as with version 2025.0.1.28?&lt;/P&gt;</description>
    <pubDate>Fri, 26 Dec 2025 08:14:26 GMT</pubDate>
    <dc:creator>Nilesh_Shinde</dc:creator>
    <dc:date>2025-12-26T08:14:26Z</dc:date>
    <item>
      <title>Unexpected runtime issue when migrating from Intel C++ Compiler 2025.0.1.28 to 2025.3.0.326</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Unexpected-runtime-issue-when-migrating-from-Intel-C-Compiler/m-p/1731487#M4647</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;I am working on an application that was previously compiled with Intel C++ Compiler 2025.0.1.28. The application includes the following function, which is intended to return 1 if the input string is empty and 0 otherwise. With version 2025.0.1.28, the function behaved as expected.&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; int ParserCheckZeroLengthString(char* pStr)&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;// check if this is a zero-length string&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (NULL== pStr || pStr[0]=='\0')&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return 1;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return 0;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; }&lt;/P&gt;&lt;P&gt;After upgrading to Intel C++ Compiler 2025.3.0.326, the build completes successfully, but at runtime the function incorrectly returns 0 instead of 1 when the string is empty.&lt;/P&gt;&lt;P&gt;We are suspecting this issue may be related to compiler optimisations.&lt;/P&gt;&lt;P&gt;To address this, we attempted to disable or reduce optimisation using the following CMake flags, but they had no effect: Function continued to return 0 for empty parameter string.&lt;/P&gt;&lt;P&gt;////Disable optimisation&lt;/P&gt;&lt;P&gt;-DCMAKE_CXX_FLAGS_RELEASE="/Od /DNDEBUG"&lt;BR /&gt;-DCMAKE_C_FLAGS_RELEASE="/Od&amp;nbsp; /DNDEBUG"&lt;/P&gt;&lt;P&gt;and&amp;nbsp;&lt;BR /&gt;////Reduce optimisation level&lt;BR /&gt;-DCMAKE_CXX_FLAGS_RELEASE="/O2 /Ob2&amp;nbsp;/DNDEBUG"&lt;BR /&gt;-DCMAKE_C_FLAGS_RELEASE="/O2&amp;nbsp; /Ob2/DNDEBUG"&lt;/P&gt;&lt;P&gt;Question:&lt;BR /&gt;How can we compile the existing code base with Intel C++ Compiler 2025.3.0.326 while preserving the same runtime behaviour as with version 2025.0.1.28?&lt;/P&gt;</description>
      <pubDate>Fri, 26 Dec 2025 08:14:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Unexpected-runtime-issue-when-migrating-from-Intel-C-Compiler/m-p/1731487#M4647</guid>
      <dc:creator>Nilesh_Shinde</dc:creator>
      <dc:date>2025-12-26T08:14:26Z</dc:date>
    </item>
    <item>
      <title>Re: Unexpected runtime issue when migrating from Intel C++ Compiler 2025.0.1.28 to 2025.3.0.326</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Unexpected-runtime-issue-when-migrating-from-Intel-C-Compiler/m-p/1731490#M4648</link>
      <description>&lt;P&gt;Adding printf("returning 1"); just before 'return 1;' statement in&amp;nbsp;&lt;SPAN&gt;ParserCheckZeroLengthString&lt;/SPAN&gt; function, code starts behaving correctly again. How to diagnose or fix this issue.?&lt;/P&gt;</description>
      <pubDate>Fri, 26 Dec 2025 08:30:01 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Unexpected-runtime-issue-when-migrating-from-Intel-C-Compiler/m-p/1731490#M4648</guid>
      <dc:creator>Nilesh_Shinde</dc:creator>
      <dc:date>2025-12-26T08:30:01Z</dc:date>
    </item>
  </channel>
</rss>

