[PATCH] D105714: WIP/RFC: Generic MachineInstr convenience wrappers.

Jessica Paquette via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jul 9 10:26:03 PDT 2021


paquette added inline comments.


================
Comment at: llvm/include/llvm/CodeGen/GlobalISel/GenericInstWrapper.h:42
+  /// Get the definition register of the loaded value.
+  Register getLoadReg() const { return Inst->getOperand(0).getReg(); }
+  /// Get the source register of the pointer value.
----------------
I feel like "load reg" isn't really descriptive.

Maybe `getDstReg()` would be better? That would also make it easy to share terminology with other wrappers.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105714



More information about the llvm-commits mailing list