[llvm-commits] [llvm] r123141 - /llvm/trunk/lib/Target/README.txt
Chris Lattner
sabre at nondot.org
Sun Jan 9 15:42:22 PST 2011
Author: lattner
Date: Sun Jan 9 17:42:22 2011
New Revision: 123141
URL: http://llvm.org/viewvc/llvm-project?rev=123141&view=rev
Log:
xref a PR #
Modified:
llvm/trunk/lib/Target/README.txt
Modified: llvm/trunk/lib/Target/README.txt
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/README.txt?rev=123141&r1=123140&r2=123141&view=diff
==============================================================================
--- llvm/trunk/lib/Target/README.txt (original)
+++ llvm/trunk/lib/Target/README.txt Sun Jan 9 17:42:22 2011
@@ -2109,33 +2109,13 @@
//===---------------------------------------------------------------------===//
-clang -03 currently compiles this code
+clang -03 doesn't optimize this:
void f1(int* begin, int* end) {
std::fill(begin, end, 0);
}
-into
-
-define void @_Z2f1PiS_(i32* %begin, i32* %end) nounwind {
-entry:
- %cmp7.i.i = icmp eq i32* %begin, %end
- br i1 %cmp7.i.i, label %_ZSt4fillIPiiEvT_S1_RKT0_.exit, label %for.body.i.i
-
-for.body.i.i: ; preds = %entry, %for.body.i.i
- %indvar.i.i = phi i64 [ %tmp, %for.body.i.i ], [ 0, %entry ]
- %tmp = add i64 %indvar.i.i, 1
- %ptrincdec.i.i = getelementptr i32* %begin, i64 %tmp
- %__first.addr.08.i.i = getelementptr i32* %begin, i64 %indvar.i.i
- store i32 0, i32* %__first.addr.08.i.i, align 4, !tbaa !0
- %cmp.i.i = icmp eq i32* %ptrincdec.i.i, %end
- br i1 %cmp.i.i, label %_ZSt4fillIPiiEvT_S1_RKT0_.exit, label %for.body.i.i
-
-_ZSt4fillIPiiEvT_S1_RKT0_.exit: ; preds = %for.body.i.i, %entry
- ret void
-}
-
-It should compile it to a memset.
+int a memset. This is PR8942.
//===---------------------------------------------------------------------===//
More information about the llvm-commits
mailing list