This is an archive of the discontinued LLVM Phabricator instance.

LoadStoreVectorizer: Fix crashes on sub-byte types
ClosedPublic

Authored by arsenm on Jun 16 2016, 8:24 PM.

Details

Diff Detail

Event Timeline

arsenm updated this revision to Diff 61061.Jun 16 2016, 8:24 PM
arsenm retitled this revision from to LoadStoreVectorizer: Fix crashes on sub-byte types.
arsenm updated this object.
arsenm added reviewers: jlebar, escha.
arsenm added a subscriber: llvm-commits.
jlebar accepted this revision.Jun 17 2016, 8:49 AM
jlebar edited edge metadata.
jlebar added inline comments.
lib/Transforms/Vectorize/LoadStoreVectorizer.cpp
471

Just checking, there are sub-byte types, but size >= 8 implies size % 8 == 0?

test/Transforms/LoadStoreVectorizer/AMDGPU/weird-type-accesses.ll
2

Maybe this deserves a more specific comment? Like, "Checks that we don't merge loads/stores of types smaller than one byte, or vectors with elements smaller than one byte."?

This revision is now accepted and ready to land.Jun 17 2016, 8:49 AM
arsenm closed this revision.Jun 30 2016, 5:44 PM

r274306

lib/Transforms/Vectorize/LoadStoreVectorizer.cpp
471

I think the % 8 is taken care of by the weird type alloc size check, so this might be redundant and could use simplification