[PATCH] D14596: [SROA] Choose more profitable type in findCommonType

Chandler Carruth via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 18 13:52:22 PST 2016


chandlerc added a comment.

I think the biggest question left is the potential quadratic behavior:

In http://reviews.llvm.org/D14596#349033, @Carrot wrote:

> In http://reviews.llvm.org/D14596#347537, @majnemer wrote:
>
> > I think this can be N**2 if there is a big tree of phi nodes with bitcasts at different levels of the tree.  It might make sense to limit the total amount of work we are willing to do this combine.
> >
> > How many items of work does the worklist typically process before firing?
>
>
> In the regression testing there are 1.01 PHI nodes added to the worklist in average, the maximum is 3.


I think you should look at a substantially larger test than regression testing. For example, collecting the stats across a bootstrap of Clang itself at least?


http://reviews.llvm.org/D14596





More information about the llvm-commits mailing list