[PATCH] D87538: [VectorCombine] Don't vectorize scalar load under asan/tsan
Vitaly Buka via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Sep 11 15:58:47 PDT 2020
vitalybuka added inline comments.
================
Comment at: llvm/lib/Transforms/Vectorize/VectorCombine.cpp:147
// use an identity shuffle to shrink/grow the vector.
if (Ty != MinVecTy) {
unsigned OutputNumElts = Ty->getNumElements();
----------------
Shouldn't we disable only this case?
================
Comment at: llvm/lib/Transforms/Vectorize/VectorCombine.cpp:152
Mask[i] = i;
VecLd = Builder.CreateShuffleVector(VecLd, UndefValue::get(MinVecTy), Mask);
}
----------------
If we have the mask maybe we can use it for proper check on Asan side?
================
Comment at: llvm/lib/Transforms/Vectorize/VectorCombine.cpp:693
+ // concurrently modified.
+ bool CanWiden = !F.hasFnAttribute(Attribute::SanitizeAddress) &&
+ !F.hasFnAttribute(Attribute::SanitizeThread);
----------------
It should apply to SanitizeHWAddress and SanitizeMemTag as well
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D87538/new/
https://reviews.llvm.org/D87538
More information about the llvm-commits
mailing list