[PATCH] D113150: Lift VLIWResourceModel, VLIWMachineScheduler, and ConvergingVLIWScheduler into CodeGen/VLIWMachineScheduler

Matthias Braun via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 3 16:56:38 PDT 2021


MatzeB added inline comments.


================
Comment at: llvm/include/llvm/CodeGen/VLIWMachineScheduler.h:34-41
+  const TargetInstrInfo *TII;
+
+  /// ResourcesModel - Represents VLIW state.
+  /// Not limited to VLIW targets per se, but assumes definition of resource
+  /// model by a target.
+  DFAPacketizer *ResourcesModel;
+
----------------
JamesNagurne wrote:
> Added a TargetInstrInfo so that targets have access to it in overrides
Consider using references instead of pointers for things that cannot change and cannot be `nullptr`.


================
Comment at: llvm/include/llvm/CodeGen/VLIWMachineScheduler.h:45
+  /// internal to the MI scheduler at the time.
+  std::vector<SUnit *> Packet;
+
----------------
Isn't `SmallVector<>` typically the better choice over `std::vector`?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D113150



More information about the llvm-commits mailing list