[PATCH] D128393: [RISCV] Add macrofusion infrastructure and one example usage.

Philip Reames via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 23 08:10:31 PDT 2022


reames added inline comments.


================
Comment at: llvm/lib/Target/RISCV/RISCVTargetMachine.cpp:147
+  createMachineScheduler(MachineSchedContext *C) const override {
+    ScheduleDAGMILive *DAG = createGenericSchedLive(C);
+    const RISCVSubtarget &ST = C->MF->getSubtarget<RISCVSubtarget>();
----------------
craig.topper wrote:
> reames wrote:
> > I think you want this to be returned only if macro enabled.  Or at least, unconditionally enabling a machine scheduler seems like it should be a separate change.
> I don't think this changed anything. If this function returns nullptr, the caller ends up calling createGenericSchedLive anyway. But I'll change it.
You are correct.  I'd looked only at the method being overriden, and not the eventual caller.  Think I still prefer the new version, but only minorly.  


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D128393



More information about the llvm-commits mailing list