Ensure that NormalizedBuildVector returns a BUILD_VECTOR with operands of the
same type. This fixes an assertion failure in VerifySDNode.
Details
Diff Detail
- Repository
- rL LLVM
- Build Status
Buildable 21057 Build 21057: arc lint + arc unit
Event Timeline
lib/Target/AArch64/AArch64ISelLowering.cpp | ||
---|---|---|
6900 | Doesn't look like you're testing this; add a test for this? | |
test/CodeGen/AArch64/arm64-build-vector.ll | ||
43 | Nit: perhaps move some of these explanations to the implementation in NormalizeBuildVector? But definitely a brief explanation of the test would be good. |
lib/Target/AArch64/AArch64ISelLowering.cpp | ||
---|---|---|
6900 | Actually the test is exercising this path; widening adds i16 UNDEF nodes to a vector, but when normalizing the vector, they were left alone and not promoted. The next block is in fact a preemptive fix, for which I couldn't construct a test case. However, zero-extending a 16-bit or smaller operand in an integer BUILD_VECTOR to 32 bits seems pretty safe to me, and is consistent with what we already do for constant operands in this function. | |
test/CodeGen/AArch64/arm64-build-vector.ll | ||
43 | OK, will do. |
Doesn't look like you're testing this; add a test for this?