================
@@ -207,3 +239,14 @@ void WebAssemblyExceptionInfo::print(raw_ostream &OS,
const Module *) const {
for (auto &WE : TopLevelExceptions)
WE->print(OS);
}
+
+bool WebAssemblyExceptionInfo::invalidate(
+ MachineFunction &MF, const PreservedAnalyses &PA,
+ MachineFunctionAnalysisManager::Invalidator &) {
+ // Check whether the analysis, all analyses on machine functions, or the
+ // machine function's CFG have been preserved.
+ auto PAC = PA.getChecker<MachineBlockFrequencyAnalysis>();
+ return !PAC.preserved() &&
+ !PAC.preservedSet<AllAnalysesOn<MachineFunction>>() &&
+ !PAC.preservedSet<CFGAnalyses>();
----------------
boomanaiden154 wrote:
We're saying that we only invalidate the analysis if the analysis itself is not
marked as preserved (`!PAC.preserved()`), all MachineFunction analyses are not
marked as preserved, and the pass author does not mark CFGAnalyses as preserved.
https://github.com/llvm/llvm-project/pull/210246
_______________________________________________
llvm-branch-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits