[LLVMdev] MachineLoopInfo Analysis Not Done
Chris Lattner
sabre at nondot.org
Thu Dec 6 19:30:09 PST 2007
On Dec 6, 2007, at 5:56 PM, Bill Wendling wrote:
> I'm trying to create the Machine LICM pass and I have this defined:
>
> But when I go to use it:
>
> bool MachineLICM::runOnMachineFunction(MachineFunction &MF) {
> ...
> // Get our Loop information...
> LI = &getAnalysis<MachineLoopInfo>();
> ...
> for (MachineLoopInfo::iterator
> I = LI->begin(), E = LI->end(); I != E; ++I) {
> ...
>
> it doesn't execute the loop. In fact, the analysis is never ran. How
> do I force it to be run?
Maybe this is because it has runOnFunction disabled?:
class MachineLoopInfo : public MachineFunctionPass {
...
bool runOnFunction(Function& F) { return false; }
-Chris
More information about the llvm-dev
mailing list