[GlobalISel][RFC] Thoughts on MachineModulePass

Hi all,

I am interested in this as I want to perform Call Graph analysis at the Machine IR level. Has there been any updates on this?

Thanks and Best Regards

You can insert module passes into the machine pipeline as of r279602 (and some followups I don't remember right now fixing some bugs).

You basically write a ModulePass, query the MachineModuleInfo analysis and can then get the machine function for every IR function by calling MMI.getOrCreateMachineFunction(). The MachineOutliner is using this if you want to see an examples.

- Matthias