[clang] [clang] Check validity of SYCL device target (PR #172366)
via cfe-commits
cfe-commits at lists.llvm.org
Wed Apr 29 08:01:53 PDT 2026
================
@@ -118,6 +118,12 @@ bool CompilerInstance::createTarget() {
if (!hasTarget())
return false;
+ if (getLangOpts().SYCLIsDevice && !getTarget().isValidSYCLDeviceTarget()) {
----------------
elizabethandrews wrote:
This causes all test passing a`spir` triple to fail since `isGPU()` checks for `spirv`. I could modify `isGPU()` to include `spir` but I am not sure if that is functionally correct. Would you know?
https://github.com/llvm/llvm-project/pull/172366
More information about the cfe-commits
mailing list