================ @@ -3006,6 +3006,10 @@ static LValue EmitFunctionDeclLValue(CodeGenFunction &CGF, const Expr *E, GlobalDecl GD) { const FunctionDecl *FD = cast<FunctionDecl>(GD.getDecl()); llvm::Constant *V = CGF.CGM.getFunctionPointer(GD); + if (E->getType()->isCFIUncheckedCalleeFunctionType()) { + if (auto *GV = dyn_cast<llvm::GlobalValue>(V)) + V = llvm::NoCFIValue::get(GV); + } CharUnits Alignment = CGF.getContext().getDeclAlign(FD); return CGF.MakeAddrLValue(V, E->getType(), Alignment, ---------------- PiJoules wrote:
Done https://github.com/llvm/llvm-project/pull/135836 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits