I am trying to access functions analyses (in particular DependenceInfo) inside a loop pass. As per the documentation on the new pass manager says, I used : const auto &FAM = LAM.getResult<FunctionAnalysisManagerLoopProxy>(L, AR).getManager();
But FunctionAnalysisManagerLoopProxy is defined as a typedef to a class which does not have a getManager member, whereas FunctionAnalysisManagerCGSCCProxy used in the documentation have it.
Should I conclude it is not possible to access these analyses ? Should I made my pass a function pass instead of a loop pass ?
According to the comments for OuterAnalysisManagerProxy, the underlying class for FunctionAnalysisManagerLoopProxy, you cannot get the full AnalysisManager interface (e.g. getResult). Instead, you only have APIs that have constant behavior. More specifically, APIs that don’t potentially trigger an analysis, like getCachedResult.
I am not sure to understand the concept behind the invalidate function, it look likes it can be used to check if the analysis could be invalidated, but also invalidate it somehow ? Which means I don’t
understand the assertion. Also, I don’t understand why would the analyses ever be invalid since I run them just before the loop pass.