<?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: Missing implicit include paths with clang-tidy in Intel® oneAPI DPC++/C++ Compiler</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753592#M4777</link>
    <description>&lt;P&gt;Thanks for the workarounds but I believe it is not a valid solution for this problem &lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt; The path to&amp;nbsp;`/opt/intel/oneapi/compiler/2026.0/bin/compiler/../../opt/compiler/include` is not visible anywhere, especially not in compile_commands.json, because it is an internal, implicit, path of ICX. Consequently it also makes no sense to explicitly pass it in the arguments of Intel's clang-tidy.&lt;/P&gt;&lt;P&gt;Since Intel provides a version of clang-tidy alongside ICX it is expected that they work together, otherwise what's the point of providing clang-tidy at all?&lt;/P&gt;</description>
    <pubDate>Fri, 10 Jul 2026 14:01:41 GMT</pubDate>
    <dc:creator>julien-j</dc:creator>
    <dc:date>2026-07-10T14:01:41Z</dc:date>
    <item>
      <title>Missing implicit include paths with clang-tidy</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1749159#M4760</link>
      <description>&lt;P&gt;Hello, I believe there is an issue in the way clang-tidy, as provided by oneAPI, handles implicit include paths.&lt;/P&gt;&lt;P&gt;Given this file:&lt;/P&gt;&lt;LI-CODE lang="cpp"&gt;// test.cpp
#include &amp;lt;omp.h&amp;gt;&lt;/LI-CODE&gt;&lt;P&gt;A run of `icpx -c test.cpp` passes without issues, but a run of `/opt/intel/oneapi/compiler/latest/bin/compiler/clang-tidy --checks=* test.cpp` fails with the following error:&lt;/P&gt;&lt;PRE&gt;Error while processing test.cpp.&lt;BR /&gt;test.cpp:1:10: error: 'omp.h' file not found [clang-diagnostic-error]&lt;BR /&gt;1 | #include &amp;lt;omp.h&amp;gt;&lt;BR /&gt;| ^~~~~~~&lt;BR /&gt;Found compiler error(s).&lt;/PRE&gt;&lt;P&gt;I tried with various combinations of -fiopenmp and -fopenmp for the same result.&lt;/P&gt;&lt;P&gt;If we check default include paths with `icpx -x c++ -v -c /dev/null`:&lt;/P&gt;&lt;PRE&gt;#include &amp;lt;...&amp;gt; search starts here:&lt;BR /&gt;/opt/intel/oneapi/dev-utilities/2026.0/include&lt;BR /&gt;/opt/intel/oneapi/umf/1.1/include&lt;BR /&gt;/opt/intel/oneapi/tbb/2023.0/env/../include&lt;BR /&gt;/opt/intel/oneapi/dpl/2022.12/include&lt;BR /&gt;/opt/intel/oneapi/compiler/2026.0/bin/compiler/../../opt/compiler/include&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/c++/15&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/x86_64-linux-gnu/c++/15&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/c++/15/backward&lt;BR /&gt;/opt/intel/oneapi/compiler/2026.0/lib/clang/22/include&lt;BR /&gt;/usr/local/include&lt;BR /&gt;/usr/include/x86_64-linux-gnu&lt;BR /&gt;/usr/include&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;And compare with those of clang-tidy with `clang-tidy /dev/null -- -x c++ -v -c /dev/null`:&lt;/P&gt;&lt;PRE&gt;#include &amp;lt;...&amp;gt; search starts here:&lt;BR /&gt;/opt/intel/oneapi/dev-utilities/2026.0/include&lt;BR /&gt;/opt/intel/oneapi/umf/1.1/include&lt;BR /&gt;/opt/intel/oneapi/tbb/2023.0/env/../include&lt;BR /&gt;/opt/intel/oneapi/dpl/2022.12/include&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/c++/15&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/x86_64-linux-gnu/c++/15&lt;BR /&gt;/usr/lib/gcc/x86_64-linux-gnu/15/../../../../include/c++/15/backward&lt;BR /&gt;/usr/lib/llvm-20/lib/clang/20/include&lt;BR /&gt;/usr/local/include&lt;BR /&gt;/usr/include/x86_64-linux-gnu&lt;BR /&gt;/usr/include&lt;/PRE&gt;&lt;P&gt;We can see that the path `/opt/intel/oneapi/compiler/2026.0/bin/compiler/../../opt/compiler/include`, which contains omp.h, is missing from the latter.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 27 May 2026 06:34:18 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1749159#M4760</guid>
      <dc:creator>julien-j</dc:creator>
      <dc:date>2026-05-27T06:34:18Z</dc:date>
    </item>
    <item>
      <title>Re: Missing implicit include paths with clang-tidy</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753503#M4774</link>
      <description>&lt;P&gt;Thank you for reporting this issue. This behavior is expected as&amp;nbsp;clang-tidy is a separate binary that doesn't inherit the Intel compiler driver's enhanced header search paths (including opt/compiler/include where omp.h resides).&lt;/P&gt;
&lt;P&gt;At this time, we don't have plans to modify our clang-tidy to automatically detect Intel-specific paths. However, if&lt;BR /&gt;we receive additional reports from other customers, we can consider this as a feature request for a future release.&lt;/P&gt;
&lt;P&gt;In the meantime, here are two recommended workarounds:&lt;/P&gt;
&lt;P&gt;Option 1: Use a Compilation Database (Recommended)&lt;/P&gt;
&lt;P&gt;Generate compile_commands.json from your build system, which captures the actual compiler flags:&lt;/P&gt;
&lt;P&gt;# With CMake:&lt;BR /&gt;cmake -DCMAKE_CXX_COMPILER=icpx -DCMAKE_EXPORT_COMPILE_COMMANDS=ON ..&lt;/P&gt;
&lt;P&gt;# Then run clang-tidy normally:&lt;BR /&gt;clang-tidy --checks=* test.cpp&lt;/P&gt;
&lt;P&gt;clang-tidy will automatically use the include paths from the compilation database.&lt;/P&gt;
&lt;P&gt;Option 2: Explicitly Add Intel Include Paths&lt;/P&gt;
&lt;P&gt;For standalone files, pass Intel's include paths directly:&lt;/P&gt;
&lt;P&gt;clang-tidy --checks=* test.cpp -- \&lt;BR /&gt;-I/opt/intel/oneapi/compiler/latest/opt/compiler/include \&lt;BR /&gt;-I/opt/intel/oneapi/compiler/latest/lib/clang/22/include&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 09 Jul 2026 17:31:21 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753503#M4774</guid>
      <dc:creator>Sravani_K_Intel</dc:creator>
      <dc:date>2026-07-09T17:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: Missing implicit include paths with clang-tidy</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753592#M4777</link>
      <description>&lt;P&gt;Thanks for the workarounds but I believe it is not a valid solution for this problem &lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt; The path to&amp;nbsp;`/opt/intel/oneapi/compiler/2026.0/bin/compiler/../../opt/compiler/include` is not visible anywhere, especially not in compile_commands.json, because it is an internal, implicit, path of ICX. Consequently it also makes no sense to explicitly pass it in the arguments of Intel's clang-tidy.&lt;/P&gt;&lt;P&gt;Since Intel provides a version of clang-tidy alongside ICX it is expected that they work together, otherwise what's the point of providing clang-tidy at all?&lt;/P&gt;</description>
      <pubDate>Fri, 10 Jul 2026 14:01:41 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753592#M4777</guid>
      <dc:creator>julien-j</dc:creator>
      <dc:date>2026-07-10T14:01:41Z</dc:date>
    </item>
    <item>
      <title>Re: Missing implicit include paths with clang-tidy</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753643#M4782</link>
      <description>&lt;P&gt;It is reasonable to expect Intel's clang-tidy to work seamlessly with ICX-compiled code without requiring manual configuration of implicit include paths. The core issue is that clang-tidy doesn't automatically query ICX for its implicit include paths (like the path to `omp.h`), and these paths don't appear in compilation databases because they're internal to the compiler driver. I raised a request to implement this.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 10 Jul 2026 20:57:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-DPC-C-Compiler/Missing-implicit-include-paths-with-clang-tidy/m-p/1753643#M4782</guid>
      <dc:creator>Sravani_K_Intel</dc:creator>
      <dc:date>2026-07-10T20:57:48Z</dc:date>
    </item>
  </channel>
</rss>

