[llvm-commits] [llvm] r108112 - /llvm/trunk/test/Transforms/InstCombine/load3.ll

Chris Lattner sabre at nondot.org
Sun Jul 11 17:21:10 PDT 2010


Author: lattner
Date: Sun Jul 11 19:21:10 2010
New Revision: 108112

URL: http://llvm.org/viewvc/llvm-project?rev=108112&view=rev
Log:
convert to filechecconvert to filecheckk

Modified:
    llvm/trunk/test/Transforms/InstCombine/load3.ll

Modified: llvm/trunk/test/Transforms/InstCombine/load3.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/InstCombine/load3.ll?rev=108112&r1=108111&r2=108112&view=diff
==============================================================================
--- llvm/trunk/test/Transforms/InstCombine/load3.ll (original)
+++ llvm/trunk/test/Transforms/InstCombine/load3.ll Sun Jul 11 19:21:10 2010
@@ -1,14 +1,14 @@
-; RUN: opt < %s -instcombine -S | grep load | count 1
+; RUN: opt < %s -instcombine -S | FileCheck %s
 
 ; Instcombine should be able to do trivial CSE of loads.
 
-declare void @use(double %n)
-define void @bar(double* %p) {
-  %t0 = getelementptr double* %p, i32 1
-  %y = load double* %t0
-  %t1 = getelementptr double* %p, i32 1
-  %x = load double* %t1
-  call void @use(double %x)
-  call void @use(double %y)
-  ret void
+define i32 @test1(i32* %p) {
+  %t0 = getelementptr i32* %p, i32 1
+  %y = load i32* %t0
+  %t1 = getelementptr i32* %p, i32 1
+  %x = load i32* %t1
+  %a = sub i32 %y, %x
+  ret i32 %a
+; CHECK: @test1
+; CHECK: ret i32 0
 }





More information about the llvm-commits mailing list