[PATCH] D78326: [PredicateInfo] Factor out PredicateInfoBuilder (NFC)

Nikita Popov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sat Apr 18 07:33:05 PDT 2020


nikic marked an inline comment as done.
nikic added inline comments.


================
Comment at: lib/Transforms/Utils/PredicateInfo.cpp:493
   // as assume statements.
-  SmallVector<Value *, 8> OpsToRename;
   for (auto DTN : depth_first(DT.getRootNode())) {
----------------
fhahn wrote:
> I think it would be slightly better to keep passing OpsToRename to various places, as it makes things a bit more explicit; that's the main list op operations to rename.
Hm, why do you think that OpsToRename should be handled differently than other state like ValueInfo?

In fact, now that I look a bit more closely at this, I think there's some duplication going on here, in that the values stored in OpsToRename should be the same as the keys of ValueInfoNums. I guess this is stored separate to preserve order?


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

https://reviews.llvm.org/D78326





More information about the llvm-commits mailing list