================
@@ -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
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to