[PATCH] [If Converter] Convert recursion to iteration

Matthias Braun matze at braunis.de
Wed Jun 24 13:00:13 PDT 2015


LGTM with small nitpicks below:


================
Comment at: lib/CodeGen/IfConversion.cpp:772
@@ +771,3 @@
+
+    // This flag is true if MBB's successors have been analyzed.
+    bool SuccsAnalyzed;
----------------
Use ///

================
Comment at: lib/CodeGen/IfConversion.cpp:780
@@ +779,3 @@
+  while (!BBStack.empty()) {
+    auto BB = BBStack.back().MBB;
+    BBInfo &BBI = BBAnalysis[BB->getNumber()];
----------------
- Adding a BBState &State = BBStack.back(); would avoid three repeated BBStack.back() calls later.

- "MachineBasicBlock *" instead of "auto" is friendlier for the reader.

http://reviews.llvm.org/D10587

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list