[PATCH] D28934: Write a new SSAUpdater

Davide Italiano via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 24 16:13:25 PST 2017


davide added inline comments.


================
Comment at: lib/Transforms/Utils/SSAUpdaterNew.cpp:197
+  SmallPtrSet<Value *, 8> InComponent;
+  DenseMap<Value *, unsigned int> Root;
+  SmallPtrSet<Value *, 8> PHISet;
----------------
This seems to be more `PhiToDFSNum` than `Root`, unless I'm missing something.


================
Comment at: lib/Transforms/Utils/SSAUpdaterNew.cpp:205-207
+    for (auto Phi : Phis)
+      if (Root.lookup(Phi) == 0)
+        FindSCC(Phi);
----------------
Also, if we special case DFSNum == 0, probably adding a comment would help the reader (or using `const int` or a macro).


https://reviews.llvm.org/D28934





More information about the llvm-commits mailing list