Don't insert a useless cast

llvm-svn: 1527
diff --git a/llvm/lib/Transforms/Scalar/LowerAllocations.cpp b/llvm/lib/Transforms/Scalar/LowerAllocations.cpp
index 041d89f..0d26e2a 100644
--- a/llvm/lib/Transforms/Scalar/LowerAllocations.cpp
+++ b/llvm/lib/Transforms/Scalar/LowerAllocations.cpp
@@ -165,8 +165,7 @@
         MallocInst *MallocI = new MallocInst(PtrSByte, CI->getOperand(1),
                                              CI->getName());
         CI->setName("");
-        BI = BIL.insert(BI, MallocI)+1;
-        ReplaceInstWithInst(BIL, BI, new CastInst(MallocI, PtrSByte));
+        ReplaceInstWithInst(BIL, BI, MallocI);
         Changed = true;
         continue;  // Skip the ++BI
       } else if (CI->getCalledValue() == FreeMeth) { // Replace call to free?