[llvm-branch-commits] [clang] [clang][CodeGen] Create .inline builtin clones in EmitGlobalFunctionDefinition (PR #234415)
Vitaly Buka via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Wed Oct 21 20:10:54 PDT 2026
================
@@ -2446,7 +2446,9 @@ void CodeGenModule::setDLLImportDLLExport(llvm::GlobalValue *GV,
void CodeGenModule::setDLLImportDLLExport(llvm::GlobalValue *GV,
const NamedDecl *D) const {
- if (D && D->isExternallyVisible()) {
+ // Local-linkage globals (e.g. `.inline` builtin clones) cannot carry a DLL
+ // storage class.
+ if (D && D->isExternallyVisible() && !GV->hasLocalLinkage()) {
----------------
vitalybuka wrote:
Actually I spotted this corner case triggering assert, but I am not sure what I am doing here. :)
https://github.com/llvm/llvm-project/pull/234415
More information about the llvm-branch-commits
mailing list