kavitha-natarajan added inline comments.
================ Comment at: clang/lib/CodeGen/CGDebugInfo.cpp:3921 + return cast<llvm::DINode>(GVE); + return dyn_cast_or_null<llvm::DINode>(N); + } ---------------- aprantl wrote: > When would we enter a nullptr into the cache? In this change, only llvm::DIImportedEntity entries are pushed to ImportedDeclCache. So it will never return nullptr. It is only a guard to not to fall into the case of no definition in case of non llvm::DIImportedEntity in the cache (undesired and to be handled by the caller). ================ Comment at: clang/lib/CodeGen/CodeGenModule.cpp:1502 +const GlobalDecl CodeGenModule::getMangledNameDecl(StringRef Name) { + auto it = MangledDeclNames.begin(); + while (it != MangledDeclNames.end()) { ---------------- aprantl wrote: > std::find()? MangledDeclNames is a llvm::MapVector implementation, so can't use std::find(). The key for MangledDeclNames MapVector is GlobalDecl and StringRef is the value. llvm::Mapvector::find() is search by key. Here we are doing search by value. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D120989/new/ https://reviews.llvm.org/D120989 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits