[SLP] Add test case showing a bug when dealing with padded types
authorBjorn Pettersson <bjorn.a.pettersson@ericsson.com>
Tue, 12 Jan 2021 15:28:16 +0000 (16:28 +0100)
committerBjorn Pettersson <bjorn.a.pettersson@ericsson.com>
Tue, 12 Jan 2021 15:35:33 +0000 (16:35 +0100)
commitdd07d60ec33969ae4f1e37500bb852563e142dfb
treed090da4bc8d145ebdb5c4957c6162174cd9afaa9
parent2f7ec77e3cdb9d874e0b6a73d3d7a6fe02c0125d
[SLP] Add test case showing a bug when dealing with padded types

We shouldn't vectorize stores of non-packed types (i.e. types that
has padding between consecutive variables in a scalar layout,
but being packed in a vector layout).

The problem was detected as a miscompile in a downstream test case.

This is a pre-commit of a test case for the fix in D94446.
llvm/test/Transforms/SLPVectorizer/X86/bad_types.ll