[PATCH] D59139: [CodeGenPrepare] Fix ModifiedDT flag in optimizeSelectInst

Rong Xu via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 8 10:11:47 PST 2019


xur marked 2 inline comments as done.
xur added inline comments.


================
Comment at: lib/CodeGen/CodeGenPrepare.cpp:295
     /// True if CFG is modified in any way.
-    bool ModifiedDT;
+    bool DTModified;
 
----------------
tejohnson wrote:
> I'd either remove this completely, since it isn't used, or migrate to using this instead of passing around a flag parameter.
I think remove this field is better. The existing uses of this field will be kept in a ref parameter.


================
Comment at: lib/CodeGen/CodeGenPrepare.cpp:7254
     // available to CodeGenPrepare.
-    ModifiedDT = true;
+    DTModified = true;
 
----------------
tejohnson wrote:
> I think this should still set ModifiedDT so that the caller handles it appropriately (see callsite in optimizeBlock).
> 
> The comment doesn't make sense to me...might be stale?
We can remove all this.


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

https://reviews.llvm.org/D59139





More information about the llvm-commits mailing list