ABataev added inline comments.

================
Comment at: clang/lib/Sema/SemaOpenMP.cpp:2704
+                VariantFD->getMostRecentDecl());
+        if (!DevTy || *DevTy == OMPDeclareTargetDeclAttr::DT_Host)
+          HasHostFunctionVariant = true;
----------------
doru1004 wrote:
> ABataev wrote:
> > Isuppose it must be `DevTy && *DevTy == OMPDeclareTargetDeclAttr::DT_Host`, 
> > no?
> Correct me if I'm wrong but if there's no device type associated with the 
> function then it is a host function? For the second part of the condition, if 
> there exists a DevTy associated with the function then it has to be DT_Host.
Ah, I missed it. Can we have just declare variant without device type? Can you 
add a test for this case?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D140155/new/

https://reviews.llvm.org/D140155

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to