[llvm-branch-commits] [llvm] ExpandFp: Require RuntimeLibcallsInfo analysis (PR #165197)
Saleem Abdulrasool via llvm-branch-commits
llvm-branch-commits at lists.llvm.org
Mon Oct 27 05:29:51 PDT 2025
================
@@ -1126,13 +1130,23 @@ PreservedAnalyses ExpandFpPass::run(Function &F, FunctionAnalysisManager &FAM) {
AssumptionCache *AC = nullptr;
if (OptLevel != CodeGenOptLevel::None)
AC = &FAM.getResult<AssumptionAnalysis>(F);
+
+ auto &MAMProxy = FAM.getResult<ModuleAnalysisManagerFunctionProxy>(F);
+ const RTLIB::RuntimeLibcallsInfo *Libcalls =
+ MAMProxy.getCachedResult<RuntimeLibraryAnalysis>(*F.getParent());
+ if (!Libcalls) {
+ F.getContext().emitError("'runtime-libcall-info' analysis required");
----------------
compnerd wrote:
Is this pattern widely used? Should this just be an `assert` instead?
https://github.com/llvm/llvm-project/pull/165197
More information about the llvm-branch-commits
mailing list