================
@@ -4700,7 +4700,8 @@ void Sema::AddModeAttr(Decl *D, const AttributeCommonInfo 
&CI,
 
   if (NewElemTy.isNull()) {
     // Only emit diagnostic on host for 128-bit mode attribute
-    if (!(DestWidth == 128 && getLangOpts().CUDAIsDevice))
+    if (!(DestWidth == 128 &&
+          (getLangOpts().CUDAIsDevice || getLangOpts().SYCLIsDevice)))
----------------
npmiller wrote:

Side-note `CUDAIsDevice || SYCLIsDevice` seems like a pretty common pattern and 
I believe HIP also uses `CUDAIsDevice`, it could be good to refactor in the 
future this to have a common "device compilation" option if possible.

https://github.com/llvm/llvm-project/pull/128513
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to