[PATCH] D29519: Add PredicateInfo utility and printing pass

Davide Italiano via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 6 19:19:21 PST 2017


On Mon, Feb 6, 2017 at 7:18 PM, Daniel Berlin <dberlin at dberlin.org> wrote:
>>
>>
>> ================
>> Comment at: lib/Transforms/Utils/PredicateInfo.cpp:65-73
>> +struct ValueDFS {
>> +  int DFSIn = 0;
>> +  int DFSOut = 0;
>> +  unsigned int LocalNum = LN_Middle;
>> +  PredicateBase *PInfo = nullptr;
>> +  // Only one of Def or Use will be set.
>> +  Value *Def = nullptr;
>> ----------------
>> We have this similar pattern in many places now: `NewGVN`, `SSAUpdater`,
>> `MemSSA` and now here. Too bad we can't actually share more.
>>
>
> FWIW, i'm going to merge most of these and template out the part they don't
> share
>
> I have a patch to NewGVN to template it, and then started figuring out how
> to merge them all.
>
>

That sounds great, thanks.

--
Davide


More information about the llvm-commits mailing list