[PATCH] D153756: [TableGen][GlobalISel] Add Generic MatchTableExecutor Emitter

Pierre van Houtryve via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 4 02:59:55 PDT 2023


Pierre-vh added inline comments.


================
Comment at: llvm/utils/TableGen/GlobalISelEmitter.cpp:2272
+     << "  MachineFunction &MF = *I.getParent()->getParent();\n"
+     << "  MachineRegisterInfo &MRI = MF.getRegInfo();\n"
+     << "  const PredicateBitset AvailableFeatures = "
----------------
arsenm wrote:
> setupMF already does this but for some reason is just repeated by every target, should just move that to the base class
I tried putting MRI into the base class, but then it needs to be a pointer, which means all combines that use MRI (and there are lot of them, I checked) need to take that into account and use */->, I think it doesn't really give us anything to move MRI to the base
For the combiners I can just remove it because all combiners need MRI already


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D153756/new/

https://reviews.llvm.org/D153756



More information about the llvm-commits mailing list