[llvm-commits] CVS: llvm/lib/Transforms/Scalar/InstructionCombining.cpp

Chris Lattner lattner at cs.uiuc.edu
Wed Jun 15 18:52:20 PDT 2005



Changes in directory llvm/lib/Transforms/Scalar:

InstructionCombining.cpp updated: 1.349 -> 1.350
---
Log message:

Fix a bug in my previous patch.  Do not get the shift amount type (which
is always ubyte, get the type being shifted).  This unbreaks espresso


---
Diffs of the changes:  (+1 -1)

 InstructionCombining.cpp |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)


Index: llvm/lib/Transforms/Scalar/InstructionCombining.cpp
diff -u llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.349 llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.350
--- llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.349	Wed Jun 15 15:53:31 2005
+++ llvm/lib/Transforms/Scalar/InstructionCombining.cpp	Wed Jun 15 20:52:07 2005
@@ -2614,7 +2614,7 @@
             // Check that the shift amount is in range.  If not, don't perform
             // undefined shifts.  When the shift is visited it will be
             // simplified.
-            unsigned TypeBits = ShAmt->getType()->getPrimitiveSizeInBits();
+            unsigned TypeBits = CI->getType()->getPrimitiveSizeInBits();
             if (ShAmt->getValue() >= TypeBits)
               break;
 






More information about the llvm-commits mailing list