comparison test/CodeGen/PowerPC/fp-int-fp.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 1172e4bd9c6f
comparison
equal deleted inserted replaced
-1:000000000000 0:95c75e76d11b
1 ; RUN: llc < %s -march=ppc32 -mcpu=g5 | not grep r1
2
3 define double @test1(double %X) {
4 %Y = fptosi double %X to i64 ; <i64> [#uses=1]
5 %Z = sitofp i64 %Y to double ; <double> [#uses=1]
6 ret double %Z
7 }
8
9 define float @test2(double %X) {
10 %Y = fptosi double %X to i64 ; <i64> [#uses=1]
11 %Z = sitofp i64 %Y to float ; <float> [#uses=1]
12 ret float %Z
13 }
14
15 define double @test3(float %X) {
16 %Y = fptosi float %X to i64 ; <i64> [#uses=1]
17 %Z = sitofp i64 %Y to double ; <double> [#uses=1]
18 ret double %Z
19 }
20
21 define float @test4(float %X) {
22 %Y = fptosi float %X to i64 ; <i64> [#uses=1]
23 %Z = sitofp i64 %Y to float ; <float> [#uses=1]
24 ret float %Z
25 }
26
27