================ @@ -353,6 +353,23 @@ llvm::Value *CGHLSLRuntime::emitInputSemantic(IRBuilder<> &B, return nullptr; } +void CGHLSLRuntime::emitFunctionProlog(const FunctionDecl *FD, + llvm::Function *Fn) { + if (!FD || !Fn) + return; + + if (FD->hasAttr<HLSLShaderAttr>()) { + emitEntryFunction(FD, Fn); + } else { + // HLSL functions declared in the current translation unit without + // body have external linkage by default. + if (!FD->isDefined()) + Fn->setLinkage(GlobalValue::ExternalLinkage); + + // FIXME: also set external linkage on exported functions ---------------- hekota wrote:
I have mentioned them in the PR description. https://github.com/llvm/llvm-project/pull/95331 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits