28 lines
517 B
Plaintext
28 lines
517 B
Plaintext
test run
|
|
target x86_64
|
|
; AArch64 Does not have these libcalls
|
|
target s390x
|
|
target riscv64
|
|
|
|
|
|
function %libcall_ceilf32(f32) -> f32 {
|
|
fn0 = %CeilF32(f32) -> f32
|
|
|
|
block0(v0: f32):
|
|
v1 = call fn0(v0)
|
|
return v1
|
|
}
|
|
; run: %libcall_ceilf32(0x0.5) == 0x1.0
|
|
|
|
|
|
function %libcall_indirect_ceilf32(f32) -> f32 {
|
|
fn0 = %CeilF32(f32) -> f32
|
|
; sig0 = (f32) -> f32
|
|
|
|
block0(v0: f32):
|
|
v1 = func_addr.i64 fn0
|
|
v2 = call_indirect.i64 sig0, v1(v0)
|
|
return v2
|
|
}
|
|
; run: %libcall_indirect_ceilf32(0x0.5) == 0x1.0
|