| 1 |
; RUN: opt < %s -O3 | llc > %t |
| 2 |
; ModuleID = 'ld3.c' |
| 3 |
target datalayout = "E-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f128:64:128" |
| 4 |
target triple = "powerpc-unknown-linux-gnu" |
| 5 |
|
| 6 |
define ppc_fp128 @plus(ppc_fp128 %x, ppc_fp128 %y) { |
| 7 |
entry: |
| 8 |
%x_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 9 |
%y_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 10 |
%retval = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 11 |
%tmp = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 12 |
%"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] |
| 13 |
store ppc_fp128 %x, ptr %x_addr |
| 14 |
store ppc_fp128 %y, ptr %y_addr |
| 15 |
%tmp1 = load ppc_fp128, ptr %x_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 16 |
%tmp2 = load ppc_fp128, ptr %y_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 17 |
%tmp3 = fadd ppc_fp128 %tmp1, %tmp2 ; <ppc_fp128> [#uses=1] |
| 18 |
store ppc_fp128 %tmp3, ptr %tmp, align 16 |
| 19 |
%tmp4 = load ppc_fp128, ptr %tmp, align 16 ; <ppc_fp128> [#uses=1] |
| 20 |
store ppc_fp128 %tmp4, ptr %retval, align 16 |
| 21 |
br label %return |
| 22 |
|
| 23 |
return: ; preds = %entry |
| 24 |
%retval5 = load ppc_fp128, ptr %retval ; <ppc_fp128> [#uses=1] |
| 25 |
ret ppc_fp128 %retval5 |
| 26 |
} |
| 27 |
|
| 28 |
define ppc_fp128 @minus(ppc_fp128 %x, ppc_fp128 %y) { |
| 29 |
entry: |
| 30 |
%x_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 31 |
%y_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 32 |
%retval = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 33 |
%tmp = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 34 |
%"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] |
| 35 |
store ppc_fp128 %x, ptr %x_addr |
| 36 |
store ppc_fp128 %y, ptr %y_addr |
| 37 |
%tmp1 = load ppc_fp128, ptr %x_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 38 |
%tmp2 = load ppc_fp128, ptr %y_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 39 |
%tmp3 = fsub ppc_fp128 %tmp1, %tmp2 ; <ppc_fp128> [#uses=1] |
| 40 |
store ppc_fp128 %tmp3, ptr %tmp, align 16 |
| 41 |
%tmp4 = load ppc_fp128, ptr %tmp, align 16 ; <ppc_fp128> [#uses=1] |
| 42 |
store ppc_fp128 %tmp4, ptr %retval, align 16 |
| 43 |
br label %return |
| 44 |
|
| 45 |
return: ; preds = %entry |
| 46 |
%retval5 = load ppc_fp128, ptr %retval ; <ppc_fp128> [#uses=1] |
| 47 |
ret ppc_fp128 %retval5 |
| 48 |
} |
| 49 |
|
| 50 |
define ppc_fp128 @times(ppc_fp128 %x, ppc_fp128 %y) { |
| 51 |
entry: |
| 52 |
%x_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 53 |
%y_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 54 |
%retval = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 55 |
%tmp = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 56 |
%"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] |
| 57 |
store ppc_fp128 %x, ptr %x_addr |
| 58 |
store ppc_fp128 %y, ptr %y_addr |
| 59 |
%tmp1 = load ppc_fp128, ptr %x_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 60 |
%tmp2 = load ppc_fp128, ptr %y_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 61 |
%tmp3 = fmul ppc_fp128 %tmp1, %tmp2 ; <ppc_fp128> [#uses=1] |
| 62 |
store ppc_fp128 %tmp3, ptr %tmp, align 16 |
| 63 |
%tmp4 = load ppc_fp128, ptr %tmp, align 16 ; <ppc_fp128> [#uses=1] |
| 64 |
store ppc_fp128 %tmp4, ptr %retval, align 16 |
| 65 |
br label %return |
| 66 |
|
| 67 |
return: ; preds = %entry |
| 68 |
%retval5 = load ppc_fp128, ptr %retval ; <ppc_fp128> [#uses=1] |
| 69 |
ret ppc_fp128 %retval5 |
| 70 |
} |
| 71 |
|
| 72 |
define ppc_fp128 @divide(ppc_fp128 %x, ppc_fp128 %y) { |
| 73 |
entry: |
| 74 |
%x_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 75 |
%y_addr = alloca ppc_fp128 ; <ptr> [#uses=2] |
| 76 |
%retval = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 77 |
%tmp = alloca ppc_fp128, align 16 ; <ptr> [#uses=2] |
| 78 |
%"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] |
| 79 |
store ppc_fp128 %x, ptr %x_addr |
| 80 |
store ppc_fp128 %y, ptr %y_addr |
| 81 |
%tmp1 = load ppc_fp128, ptr %x_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 82 |
%tmp2 = load ppc_fp128, ptr %y_addr, align 16 ; <ppc_fp128> [#uses=1] |
| 83 |
%tmp3 = fdiv ppc_fp128 %tmp1, %tmp2 ; <ppc_fp128> [#uses=1] |
| 84 |
store ppc_fp128 %tmp3, ptr %tmp, align 16 |
| 85 |
%tmp4 = load ppc_fp128, ptr %tmp, align 16 ; <ppc_fp128> [#uses=1] |
| 86 |
store ppc_fp128 %tmp4, ptr %retval, align 16 |
| 87 |
br label %return |
| 88 |
|
| 89 |
return: ; preds = %entry |
| 90 |
%retval5 = load ppc_fp128, ptr %retval ; <ppc_fp128> [#uses=1] |
| 91 |
ret ppc_fp128 %retval5 |
| 92 |
} |