diff options
| author | Duncan Sands <baldrick@free.fr> | 2009-11-20 13:19:51 +0000 |
|---|---|---|
| committer | Duncan Sands <baldrick@free.fr> | 2009-11-20 13:19:51 +0000 |
| commit | 9e26aac773ef56ce4087cad17c071be16b5f2a13 (patch) | |
| tree | 680e3e0ba6b151fd68a85122e5bacbea722047ba /llvm/lib/Transforms | |
| parent | df5280df051489c7a7a9b463fa81c712000bba7a (diff) | |
| download | bcm5719-llvm-9e26aac773ef56ce4087cad17c071be16b5f2a13.tar.gz bcm5719-llvm-9e26aac773ef56ce4087cad17c071be16b5f2a13.zip | |
Fix PR5563, an expensive checks failure when running on
tests/Transforms/InstCombine/shufflemask-undef.ll. If
anyone cares, the use of 2*e here (and the equivalent
all over the place in instcombine) seems wrong, though
harmless: it should really be twice the length of the
input vector. I think shufflevector used to require
that the mask have the same length as the input, but I
don't think that's true any more. I don't care enough
about vectors to do anything about this...
llvm-svn: 89456
Diffstat (limited to 'llvm/lib/Transforms')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/InstructionCombining.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp index 1c48366e89f..6f74902e1b4 100644 --- a/llvm/lib/Transforms/Scalar/InstructionCombining.cpp +++ b/llvm/lib/Transforms/Scalar/InstructionCombining.cpp @@ -12920,7 +12920,7 @@ Instruction *InstCombiner::visitShuffleVectorInst(ShuffleVectorInst &SVI) { if (LHSMask.size() == Mask.size()) { std::vector<unsigned> NewMask; for (unsigned i = 0, e = Mask.size(); i != e; ++i) - if (Mask[i] >= 2*e) + if (Mask[i] >= e) NewMask.push_back(2*e); else NewMask.push_back(LHSMask[Mask[i]]); |

