[PATCH] D23356: [DAG] Fix incorrect alignment of ext load.

Nirav Dave via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 1 06:53:25 PDT 2016

niravd added a comment.

In the SplitVecOp_EXTRACT_VECTOR_ELT(N) in LegalizeVectorTypes, there is a call to DAG.getExtLoad where the optional Alignment argument is omitted and defaulted to 0. 
This appears to be the only call in llvm of such that triggers that code path and all other similar alignment checks appear correct.

In terms of a test, it's not clear to me how to expose the issue with alignment from an element of a decomposed vector in the current upstream without inspecting intermediate state via debug. The easiest way would be to fold this into https://reviews.llvm.org/D14834. I'd prefer to make this a separate commit as it is an obvious and separable mistake. Perhaps we could add this test for now, and then delete it as redundant with https://reviews.llvm.org/D14834.

In https://reviews.llvm.org/D23356#527851, @arsenm wrote:

> In https://reviews.llvm.org/D23356#523047, @niravd wrote:
> > The 0 alignment load is coming from the splitting of the extract_vector_elt.
> >
> > In https://reviews.llvm.org/D23356#511344, @arsenm wrote:
> >
> > > Where is the call site passing 0 alignment?
> >
> Could you be more specific?


More information about the llvm-commits mailing list