OSDN Git Service

[AArch64] Fix a silent codegen fault in BUILD_VECTOR lowering.
authorJames Molloy <james.molloy@arm.com>
Fri, 17 Oct 2014 17:06:31 +0000 (17:06 +0000)
committerJames Molloy <james.molloy@arm.com>
Fri, 17 Oct 2014 17:06:31 +0000 (17:06 +0000)
commit7023b851872f637a45d1698e5a8881aa46b21de5
tree3821afc2295306771a8c0c42fba0dde1cd024c9c
parentad8eef5a90b0a85b20586e80e6e11a7aa134390c
[AArch64] Fix a silent codegen fault in BUILD_VECTOR lowering.

We should be talking about the number of source elements, not the number of destination elements, given we know at this point that the source and dest element numbers are not the same.

While we're at it, avoid writing to std::vector::end()...

Bug found with random testing and a lot of coffee.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220051 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/AArch64/AArch64ISelLowering.cpp
test/CodeGen/AArch64/aarch64-wide-shuffle.ll [new file with mode: 0644]