summaryrefslogtreecommitdiffstats
path: root/llvm/lib/VMCore/ConstantFolding.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2006-12-01 05:55:25 +0000
committerChris Lattner <sabre@nondot.org>2006-12-01 05:55:25 +0000
commitd1d5693149be24c389fc573b6cdda529311ca6a9 (patch)
tree57106d5f8c1bbf5901008d5c2cc9b4723fdee4ae /llvm/lib/VMCore/ConstantFolding.cpp
parent5145977cd8e5a21d5ad45e04fbf44dc60e8bc108 (diff)
downloadbcm5719-llvm-d1d5693149be24c389fc573b6cdda529311ca6a9.tar.gz
bcm5719-llvm-d1d5693149be24c389fc573b6cdda529311ca6a9.zip
Fix a typo introduced by the cast patch that horribly broke a lot of vector
code. Testcase here: Transforms/ConstProp/2006-11-30-vector-cast.ll llvm-svn: 32062
Diffstat (limited to 'llvm/lib/VMCore/ConstantFolding.cpp')
-rw-r--r--llvm/lib/VMCore/ConstantFolding.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/VMCore/ConstantFolding.cpp b/llvm/lib/VMCore/ConstantFolding.cpp
index a428e74bc66..79f0f577420 100644
--- a/llvm/lib/VMCore/ConstantFolding.cpp
+++ b/llvm/lib/VMCore/ConstantFolding.cpp
@@ -743,7 +743,7 @@ static Constant *CastConstantPacked(ConstantPacked *CP,
(SrcEltTy->isFloatingPoint() && DstEltTy->isFloatingPoint())) {
for (unsigned i = 0; i != SrcNumElts; ++i)
Result.push_back(
- ConstantExpr::getCast(Instruction::BitCast, CP->getOperand(1),
+ ConstantExpr::getCast(Instruction::BitCast, CP->getOperand(i),
DstEltTy));
return ConstantPacked::get(Result);
}
OpenPOWER on IntegriCloud