HomePhabricator

[AArch64] Fix SelectionDAG infinite loop for v1i64 SCALAR_TO_VECTOR

Description

[AArch64] Fix SelectionDAG infinite loop for v1i64 SCALAR_TO_VECTOR

A consequence of r347274 is that SCALAR_TO_VECTOR can be converted into
BUILD_VECTOR by SimplifyDemandedBits, but LowerBUILD_VECTOR can turn
BUILD_VECTOR into SCALAR_TO_VECTOR so we get an infinite loop.

Fix this by making LowerBUILD_VECTOR not do this transformation for those
vectors that would get transformed back, i.e. BUILD_VECTOR of a single-element
constant vector. Doing that means we get a DUP, which we then need to recognise
in ISel as a copy.

Details

Committed
john.brawnNov 22 2018, 3:45 AM
Parents
rL347455: [ELF] - Make SymbolTable::addDefined return Defined.
Branches
Unknown
Tags
Unknown