From f96c3625c2cc9c580882b4914b293d9e64099022 Mon Sep 17 00:00:00 2001
From: Devang Patel
bool ModuleLevelPass::runOnModule(Module &M) { ... - DominatorTree &DT = getAnalysis<DominatorTree>(Function &F); + DominatorTree &DT = getAnalysis<DominatorTree>(Func); ... }
Currently it is illegal for a ModulePass -to require a FunctionPass. This is because -there is only one instance of the FunctionPass object ever created, thus nowhere -to store information for all of the functions in the program at the same time. -Although this has come up a couple of times before, this has always been worked -around by factoring one big complicated pass into a global and an -interprocedural part, both of which are distinct. In the future, it would be -nice to have this though.
- -Note that it is no problem for a FunctionPass to require the results of a ModulePass, only the other way around.
- -