~ubuntu-branches/ubuntu/quantal/llvm-3.1/quantal

« back to all changes in this revision

Viewing changes to test/CodeGen/X86/fast-isel-ret-ext.ll

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2012-03-29 19:09:51 UTC
  • Revision ID: package-import@ubuntu.com-20120329190951-aq83ivog4cg8bxun
Tags: upstream-3.1~svn153643
ImportĀ upstreamĀ versionĀ 3.1~svn153643

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
; RUN: llc < %s  -O0 -fast-isel-abort -mtriple i686-apple-darwin10 | FileCheck %s
 
2
; RUN: llc < %s  -O0 -fast-isel-abort -mtriple x86_64-apple-darwin10 | FileCheck %s
 
3
 
 
4
define zeroext i8 @test1(i32 %y) nounwind {
 
5
  %conv = trunc i32 %y to i8
 
6
  ret i8 %conv
 
7
  ; CHECK: test1:
 
8
  ; CHECK: movzbl {{.*}}, %eax
 
9
}
 
10
 
 
11
define signext i8 @test2(i32 %y) nounwind {
 
12
  %conv = trunc i32 %y to i8
 
13
  ret i8 %conv
 
14
  ; CHECK: test2:
 
15
  ; CHECK: movsbl {{.*}}, %eax
 
16
}
 
17
 
 
18
define zeroext i16 @test3(i32 %y) nounwind {
 
19
  %conv = trunc i32 %y to i16
 
20
  ret i16 %conv
 
21
  ; CHECK: test3:
 
22
  ; CHECK: movzwl {{.*}}, %eax
 
23
}
 
24
 
 
25
define signext i16 @test4(i32 %y) nounwind {
 
26
  %conv = trunc i32 %y to i16
 
27
  ret i16 %conv
 
28
  ; CHECK: test4:
 
29
  ; CHECK: movswl {{.*}}, %eax
 
30
}
 
31
 
 
32
define zeroext i1 @test5(i32 %y) nounwind {
 
33
  %conv = trunc i32 %y to i1
 
34
  ret i1 %conv
 
35
  ; CHECK: test5:
 
36
  ; CHECK: andb $1
 
37
  ; CHECK: movzbl {{.*}}, %eax
 
38
}