Skip to content

Commit 9865d7c

Browse files
authored
ARM: Add missing test coverage for windows frexp libcalls (#146690)
fp128 case crashes, so left off. Also didn't just add to the other frexp test, since update_llc_test_checks seems to just ignore this case for some reason, and the other windows tests are also separated into this subdirectory.
1 parent 5a8e60e commit 9865d7c

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
; RUN: llc -mtriple thumbv7--windows-itanium < %s | FileCheck %s
2+
3+
; CHECK-LABEL: test_frexp_f16_i32:
4+
; CHECK: bl __gnu_h2f_ieee
5+
; CHECK: vcvt.f64.f32 d0, s0
6+
; CHECK: bl frexp
7+
; CHECK: vcvt.f32.f64 s0, d0
8+
; CHECK: bl __gnu_f2h_ieee
9+
define { half, i32 } @test_frexp_f16_i32(half %a) {
10+
%result = call { half, i32 } @llvm.frexp.f16.i32(half %a)
11+
ret { half, i32 } %result
12+
}
13+
14+
; CHECK-LABEL: test_frexp_f32_i32:
15+
; CHECK: vcvt.f64.f32
16+
; CHECK: bl frexp
17+
; CHECK: vcvt.f32.f64 s0, d0
18+
define { float, i32 } @test_frexp_f32_i32(float %a) {
19+
%result = call { float, i32 } @llvm.frexp.f32.i32(float %a)
20+
ret { float, i32 } %result
21+
}
22+
23+
; CHECK-LABEL: test_frexp_f64_i32:
24+
; CHECK: bl frexp
25+
define { double, i32 } @test_frexp_f64_i32(double %a) {
26+
%result = call { double, i32 } @llvm.frexp.f64.i32(double %a)
27+
ret { double, i32 } %result
28+
}

0 commit comments

Comments
 (0)