With Benjamin's recent amazing patches, we should be able to do even better things :)
authorChris Lattner <sabre@nondot.org>
Thu, 6 Jan 2011 22:25:00 +0000 (22:25 +0000)
committerChris Lattner <sabre@nondot.org>
Thu, 6 Jan 2011 22:25:00 +0000 (22:25 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122978 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/README.txt

index bedc893fbb10cb4f3d02f479361af38baf24172b..d13ea736a107840cb8fb0c71f7ab0145a20e718a 100644 (file)
@@ -2073,3 +2073,16 @@ The icmp should fold to false. This CSE opportunity is only available
 after GVN and InstCombine have run.
 
 //===---------------------------------------------------------------------===//
+
+memcpyopt should turn this:
+
+define i8* @test10(i32 %x) {
+  %alloc = call noalias i8* @malloc(i32 %x) nounwind
+  call void @llvm.memset.p0i8.i32(i8* %alloc, i8 0, i32 %x, i32 1, i1 false)
+  ret i8* %alloc
+}
+
+into a call to calloc.  We should make sure that we analyze calloc as
+aggressively as malloc though.
+
+//===---------------------------------------------------------------------===//