Mercurial > hg > CbC > CbC_llvm
comparison test/CodeGen/X86/fast-isel-ret-ext.ll @ 0:95c75e76d11b LLVM3.4
LLVM 3.4
author | Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 12 Dec 2013 13:56:28 +0900 |
parents | |
children | afa8332a0e37 |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:95c75e76d11b |
---|---|
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-LABEL: 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-LABEL: 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-LABEL: 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-LABEL: test4: | |
29 ; CHECK: {{(movswl.%.x, %eax|cwtl)}} | |
30 } | |
31 | |
32 define zeroext i1 @test5(i32 %y) nounwind { | |
33 %conv = trunc i32 %y to i1 | |
34 ret i1 %conv | |
35 ; CHECK-LABEL: test5: | |
36 ; CHECK: andb $1 | |
37 ; CHECK: movzbl {{.*}}, %eax | |
38 } |