[PATCH] D75817: [NVPTX] Fix instruction selection for addresses in case of addrspacecasts

Artem Belevich via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 10 09:12:27 PDT 2020


tra added a comment.

In D75817#1913351 <https://reviews.llvm.org/D75817#1913351>, @thomasfaingnaert wrote:

> I did some more testing, and it appears that that the `InstCombine` pass (`opt -instcombine`) is responsible for this.
>  Maybe it would be better to ensure `InstCombine` doesn't reorder instead of fixing this in instruction selection as I do now?
>  I'm not sure if that would influence other backends that rely on this reordering, though.


It is possible that reordering is OK for some combination of address spaces on some platforms, but I doubt it's universal, which suggests that InstCombine should not be doing that.
I may be missing something here. It may be worth asking on llvm-dev@ whether InstCombine does the right thing regarding such GEP/ASC reordering.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D75817/new/

https://reviews.llvm.org/D75817





More information about the llvm-commits mailing list