Hahnfeld added inline comments.
================ Comment at: clang/lib/CodeGen/CodeGenModule.cpp:6450 llvm::raw_ostream &OS) const { - OS << ".static." << getContext().getCUIDHash(); + OS << "__static__" << getContext().getCUIDHash(); } ---------------- tra wrote: > I would expect NVPTXAssignValidGlobalNames.cpp to deal with this ptx quirk. > I'm fine with the underscores, but it would be good we're not just covering > up an issue somewhere else. > `NVPTXAssignValidGlobalNames` checks `hasLocalLinkage`, which the `static` variables here are not (see discussion in D85223). I think the reason is that we don't want variable and function names to differ between host and device, and this might even be important here for maintaining proper connection for `cudaMemcpy`s and so on. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D108456/new/ https://reviews.llvm.org/D108456 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits