[PATCH] D30790: [LVI] Add an LVI printer pass to capture test LVI cache after transformations

Daniel Berlin via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 10 10:41:58 PST 2017


dberlin added inline comments.


================
Comment at: include/llvm/Analysis/LazyValueInfo.h:102
+  /// Print the \LazyValueInfoCache.
+  void printCache(const DataLayout &DL, raw_ostream &OS);
+
----------------
anna wrote:
> dberlin wrote:
> > What's the reason for datalayout?
> > It's always gettable from any instruction, etc.
> > 
> We need it here for getting the `LazyValueInfoImpl` within this function. I don't think we have any other way for getting the datalayout.
> 
> see: `getImpl(PImpl, AC, &DL, DT).printCache(OS);`
Oh, yeah, this is just silly.
It looks like LazyValueInfo doesn't have DL, but all the impl's require it.
This looks like it was just the simplest conversion possible.

I would just add it to the class LazyValueInfo interface, since everything else is there.




https://reviews.llvm.org/D30790





More information about the llvm-commits mailing list