[PATCH] D46422: [LCSSA] Iteratively remove unused PHI nodes in formLCSSAForInstructions

Matt Davis via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri May 4 08:19:34 PDT 2018


mattd added a comment.

Thanks! This LGTM.  Just one suggestion.



================
Comment at: lib/Transforms/Utils/LCSSA.cpp:217
 
-    // Keep track of PHI nodes that we want to remove because they did not have
-    // any uses rewritten. If the new PHI is used, store it so that we can
-    // try to propagate dbg.value intrinsics to it.
+    // Keep track of PHI nodes that we createe, so that we can remove them again
+    // if they did not have any uses rewritten.
----------------
bjope wrote:
> /createe/create/
Just a suggestion.  Since we don't need this container until later, around line 232, can we move this declaration there, and add the unused PHIs at that point?


Repository:
  rL LLVM

https://reviews.llvm.org/D46422





More information about the llvm-commits mailing list