[llvm-commits] CVS: llvm/lib/Transforms/Scalar/InstructionCombining.cpp
Chris Lattner
lattner at cs.uiuc.edu
Tue Sep 28 20:16:38 PDT 2004
Changes in directory llvm/lib/Transforms/Scalar:
InstructionCombining.cpp updated: 1.256 -> 1.257
---
Log message:
Hrm, really, all tests passed without this, but it is scary to think how...
---
Diffs of the changes: (+2 -2)
Index: llvm/lib/Transforms/Scalar/InstructionCombining.cpp
diff -u llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.256 llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.257
--- llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.256 Tue Sep 28 22:09:18 2004
+++ llvm/lib/Transforms/Scalar/InstructionCombining.cpp Tue Sep 28 22:16:24 2004
@@ -1766,9 +1766,9 @@
case Instruction::Cast: { // (setcc (cast X to larger), CI)
const Type *SrcTy = LHSI->getOperand(0)->getType();
if (SrcTy->isIntegral() && LHSI->getType()->isIntegral()) {
- unsigned SrcBits = SrcTy->getPrimitiveSize();
+ unsigned SrcBits = SrcTy->getPrimitiveSize()*8;
if (SrcTy == Type::BoolTy) SrcBits = 1;
- unsigned DestBits = LHSI->getType()->getPrimitiveSize();
+ unsigned DestBits = LHSI->getType()->getPrimitiveSize()*8;
if (LHSI->getType() == Type::BoolTy) DestBits = 1;
if (SrcBits < DestBits) {
// Check to see if the comparison is always true or false.
More information about the llvm-commits
mailing list