[PATCH] D65600: Relax load store vectorizer pointer strip checks
Stanislav Mekhanoshin via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 1 13:56:39 PDT 2019
rampitec added inline comments.
================
Comment at: lib/Transforms/Vectorize/LoadStoreVectorizer.cpp:347-348
- if (PtrA->getType()->getPointerAddressSpace() != PtrAS ||
- PtrB->getType()->getPointerAddressSpace() != PtrAS)
+ if (DL.getTypeStoreSizeInBits(PtrA->getType()) != PtrBitWidth ||
+ DL.getTypeStoreSizeInBits(PtrB->getType()) != PtrBitWidth)
return false;
----------------
tra wrote:
> If we were to use addrspacecast(1) instead of 5 in the example below, we'd proceed with the checks.
> If we can deal with non-generic address spaces in principle, why can't we deal with address spaces that differ in pointer size? I'd assume that logic that determines consecutiveness should work the same.
>
> I guess one way to handle mismatched address spaces would be to normalize the pointer to the common address space (generic?) and then run the checks for the consecutiveness.
>
>
In the meanwhile I am working on the followup patch to handle pointer size differences in graceful way. That requires more code and time and time though.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65600/new/
https://reviews.llvm.org/D65600
More information about the llvm-commits
mailing list