[PATCH] D39267: [GISel]: Change Legalization from top down to bottom up + DCE

Vedant Kumar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 6 17:54:48 PST 2017


vsk added inline comments.


================
Comment at: include/llvm/CodeGen/GlobalISel/GISelWorkList.h:32
+  GISelWorkList(GISelWorkList &&) = default;
+  GISelWorkList &operator=(GISelWorkList &&) = default;
+
----------------
Do you mean to delete the copy methods as well?


================
Comment at: include/llvm/CodeGen/GlobalISel/GISelWorkList.h:41
+  void insert(MachineInstr *I) {
+    if (WorklistMap.insert(std::make_pair(I, Worklist.size())).second) {
+      Worklist.push_back(I);
----------------
Use WorklistMap.try_emplace?


================
Comment at: include/llvm/CodeGen/GlobalISel/GISelWorkList.h:46
+
+  // Remove - remove I from the worklist if it exists.
+  void remove(MachineInstr *I) {
----------------
Use '///' for Doxygen support?


https://reviews.llvm.org/D39267





More information about the llvm-commits mailing list