[llvm-commits] [llvm] r86345 - in /llvm/trunk/test/CodeGen/X86: cmp0.ll cmp1.ll
Chris Lattner
sabre at nondot.org
Fri Nov 6 22:19:20 PST 2009
Author: lattner
Date: Sat Nov 7 00:19:20 2009
New Revision: 86345
URL: http://llvm.org/viewvc/llvm-project?rev=86345&view=rev
Log:
merge cmp1 into cmp0 and filecheckize.
Removed:
llvm/trunk/test/CodeGen/X86/cmp1.ll
Modified:
llvm/trunk/test/CodeGen/X86/cmp0.ll
Modified: llvm/trunk/test/CodeGen/X86/cmp0.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmp0.ll?rev=86345&r1=86344&r2=86345&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmp0.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmp0.ll Sat Nov 7 00:19:20 2009
@@ -1,7 +1,24 @@
-; RUN: llc < %s -march=x86-64 | grep -v cmp
+; RUN: llc < %s -march=x86-64 | FileCheck %s
-define i64 @foo(i64 %x) {
+define i64 @test0(i64 %x) nounwind {
%t = icmp eq i64 %x, 0
%r = zext i1 %t to i64
ret i64 %r
+; CHECK: test0:
+; CHECK: testq %rdi, %rdi
+; CHECK: sete %al
+; CHECK: movzbl %al, %eax
+; CHECK: ret
}
+
+define i64 @test1(i64 %x) nounwind {
+ %t = icmp slt i64 %x, 1
+ %r = zext i1 %t to i64
+ ret i64 %r
+; CHECK: test1:
+; CHECK: testq %rdi, %rdi
+; CHECK: setle %al
+; CHECK: movzbl %al, %eax
+; CHECK: ret
+}
+
Removed: llvm/trunk/test/CodeGen/X86/cmp1.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/cmp1.ll?rev=86344&view=auto
==============================================================================
--- llvm/trunk/test/CodeGen/X86/cmp1.ll (original)
+++ llvm/trunk/test/CodeGen/X86/cmp1.ll (removed)
@@ -1,7 +0,0 @@
-; RUN: llc < %s -march=x86-64 | grep -v cmp
-
-define i64 @foo(i64 %x) {
- %t = icmp slt i64 %x, 1
- %r = zext i1 %t to i64
- ret i64 %r
-}
More information about the llvm-commits
mailing list