Changes in directory llvm/lib/Transforms/Scalar:

InstructionCombining.cpp updated: 1.460 -> 1.461
---
Log message:

vector casts of casts are eliminable.  Transform this:

        %tmp = cast <4 x uint> %tmp to <4 x int>                ; <<4 x int>> 
[#uses=1]
        %tmp = cast <4 x int> %tmp to <4 x float>               ; <<4 x float>> 
[#uses=1]

into:

        %tmp = cast <4 x uint> %tmp to <4 x float>              ; <<4 x float>> 
[#uses=1]



---
Diffs of the changes:  (+4 -0)

 InstructionCombining.cpp |    4 ++++
 1 files changed, 4 insertions(+)


Index: llvm/lib/Transforms/Scalar/InstructionCombining.cpp
diff -u llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.460 
llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.461
--- llvm/lib/Transforms/Scalar/InstructionCombining.cpp:1.460   Sat Apr  1 
23:37:12 2006
+++ llvm/lib/Transforms/Scalar/InstructionCombining.cpp Sat Apr  1 23:43:13 2006
@@ -4539,6 +4539,10 @@
       SrcTy->getPrimitiveSize() < MidTy->getPrimitiveSize())
     return true;
   
+  // Packed type conversions don't modify bits.
+  if (isa<PackedType>(SrcTy) && isa<PackedType>(MidTy) 
&&isa<PackedType>(DstTy))
+    return true;
+  
   return false;
 }
 



_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to