hliao added inline comments.

================
Comment at: clang/lib/CodeGen/CodeGenModule.cpp:4441
       if (Linkage != llvm::GlobalValue::InternalLinkage &&
-          (D->hasAttr<CUDADeviceAttr>() || D->hasAttr<CUDAConstantAttr>()))
+          (D->hasAttr<CUDADeviceAttr>() || D->hasAttr<CUDAConstantAttr>() ||
+           D->getType()->isCUDADeviceBuiltinSurfaceType() ||
----------------
yaxunl wrote:
> we need also do this with variables with HIPManagedAttr and add a test for 
> that
those managed var seems already being marked 'externally_initalized' in 
lib/CodeGen/CGCUDANV.cpp. Do you have missing places to mark them?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D107718

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

Reply via email to