[PATCH] [LoopAccesses] Cache the result of canVectorizeMemory

Adam Nemet anemet at apple.com
Tue Feb 17 11:08:00 PST 2015

In http://reviews.llvm.org/D7682#124591, @anemet wrote:

> In http://reviews.llvm.org/D7682#124581, @hfinkel wrote:
> > Why not do the analysis in the constructor, and remove the implicit ordering dependency between calling analyzeLoop and calling the other accessor functions?
> I think that should work, let me give it a try.

OK, I know now why we can't do it in *this* patch.  LAI is constructed when LVLegality is constructed so we would effectively move running canVectorizeMemory much earlier than before.

On the other hand I can do this after we have the LAA-LAI separation later in http://reviews.llvm.org/D7684 (where the pass is actually created).  There, LAI is only created from LVLegality::canVectorizeMem so there is no functional change.  Are you OK with that?



More information about the llvm-commits mailing list