[PATCH] D17341: LegalizeDAG: Use correct ptr type when expanding unaligned load/store

Ahmed Bougacha via llvm-commits llvm-commits at lists.llvm.org
Mon Feb 29 11:43:13 PST 2016


ab accepted this revision.
ab added a reviewer: ab.
ab added a comment.
This revision is now accepted and ready to land.

LGTM.

In http://reviews.llvm.org/D17341#359946, @arsenm wrote:

> In http://reviews.llvm.org/D17341#354906, @ab wrote:
>
> > If I understand correctly, ExpandUnalignedStore was correct and the changes are NFC, but ExpandUnalignedLoad wasn't, right?
> >
> > If so, LGTM.
> >
> > Otherwise I'm not sure I understand why TLI.getPointerTy(DL, AS) isn't sufficient.
>
>
> No, both have the same problem.


I had a closer look; I see that in ExpandUnalignedStore, there's a problem when StackPtrVT and PtrVT are different.

> I think it's cleaner to get the existing type rather than re-figuring it out from the address space.


Agreed.


http://reviews.llvm.org/D17341





More information about the llvm-commits mailing list