Add compiler detection for Intel oneAPI DPC++/C++ Compiler.#9850
Add compiler detection for Intel oneAPI DPC++/C++ Compiler.#9850vinsonlee wants to merge 1 commit intomesonbuild:masterfrom
Conversation
Reported-by: Marcus Seyfarth <[email protected]> Suggested-by: Harry van Haaren <[email protected]> Tested-by: Vinson Lee <[email protected]> Tested-by: Marcus Seyfarth <[email protected]> Signed-off-by: Vinson Lee <[email protected]>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #9850 +/- ##
==========================================
- Coverage 67.80% 67.80% -0.01%
==========================================
Files 400 400
Lines 85522 85522
Branches 18825 18825
==========================================
- Hits 57987 57986 -1
- Misses 23035 23036 +1
Partials 4500 4500 ☔ View full report in Codecov by Sentry. |
|
Just a note that this PR is the output of the longer discussion on issue #8113, and the code-change workings is described in #8113 (comment). Merging this PR will enable Meson to correctly detect and use the OneAPI compiler. |
|
As this is new functionality it should have a release note snippet. |
|
Isn't this going to result in using th eIntel compiler with an Id as clang? Even if it uses clang under the hood, there are still some differences right, enough to justify having at least a unique name like "oneAPI" or "Intel DPC" or something (just not |
|
I think a new ID is called for (CMake gives it |
|
That's... interesting. And means that the implementation in Meson needs to override the optimization levels as well, so that we add -fp-mode=precise to the arguments by default |
This is what gh-10909 does. So that probably supercedes this PR. |
|
It adds a new class, but doesn't override anything such as the ID. It is the right approach, just not all the way there. :) |
|
Just noting that this hasn't been touched in 2 years, and it'd be really nice to have! |
|
@aaronsuydam #10909 implements this, and has been landed for almost 2 years. The only think I see here that we don't have upstream is the note about the |
|
@dcbaker ah ok great. There's nothing in the web docs about this having been implemented (that I saw), what's the meson.build option I need to use? Haven't been able to get it to work. |
|
@aaronsuydam there isn't a meson.build option. It is supporting a new compiler and compilers are defined in the toolchain ("machine") file or inferred by setting the environment variables CC and CXX. The meson docs include a reference table listing supported compilers alongside the ID return values for checking inside meson.build "which compiler is this build directory + toolchain configured to use".
It's also mentioned in the release notes for meson 0.64.0 |
Reported-by: Marcus Seyfarth [email protected]
Suggested-by: Harry van Haaren [email protected]
Tested-by: Vinson Lee [email protected]
Tested-by: Marcus Seyfarth [email protected]
Signed-off-by: Vinson Lee [email protected]