[PATCH] D29519: Add PredicateInfo utility and printing pass
Daniel Berlin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Feb 3 16:49:40 PST 2017
dberlin added inline comments.
================
Comment at: lib/Transforms/Utils/PredicateInfo.cpp:433
+void PredicateInfo::renameUses(SmallPtrSetImpl<Value *> &OpsToRename) {
+ ValueDFS_Compare A(OBBMap);
+ // Compute liveness, and rename in O(uses) per Op.
----------------
Prazek wrote:
> This looks like a single usage of the OBBMap inside PredicateInfo.
> Shouldn't it be just created inside ValueDFS_Compare?
>
No.
1. This way it is shared between all the use renaming regardless of whether we share the comparator or not (we happen to now). It's unlikely someone will notice that moving this inside the loop will cause it to create orderedbasicblocks all the time.
2. We are going to use it in a followup.
https://reviews.llvm.org/D29519
More information about the llvm-commits
mailing list