We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
f128
1 parent 34db533 commit 7871c81Copy full SHA for 7871c81
README.md
@@ -249,7 +249,7 @@ These builtins are needed to support `f16` and `f128`, which are in the process
249
- [ ] floatsitf.c
250
- [ ] floatunditf.c
251
- [ ] floatunsitf.c
252
-- [ ] multf3.c
+- [x] multf3.c
253
- [ ] powitf2.c
254
- [ ] ppc/fixtfdi.c
255
- [ ] ppc/fixunstfdi.c
build.rs
@@ -479,7 +479,6 @@ mod c {
479
("__floatsitf", "floatsitf.c"),
480
("__floatunditf", "floatunditf.c"),
481
("__floatunsitf", "floatunsitf.c"),
482
- ("__multf3", "multf3.c"),
483
("__divtf3", "divtf3.c"),
484
("__powitf2", "powitf2.c"),
485
("__fe_getround", "fp_mode.c"),
@@ -504,7 +503,6 @@ mod c {
504
503
("__fixunstfsi", "fixunstfsi.c"),
505
506
507
- ("__divtf3", "divtf3.c"),
508
]);
509
}
510
@@ -517,7 +515,6 @@ mod c {
517
515
518
516
519
520
521
522
523
src/float/mul.rs
@@ -199,6 +199,11 @@ intrinsics! {
199
mul(a, b)
200
201
202
+ #[cfg(not(feature = "no-f16-f128"))]
203
+ pub extern "C" fn __multf3(a: f128, b: f128) -> f128 {
204
+ mul(a, b)
205
+ }
206
+
207
#[cfg(target_arch = "arm")]
208
pub extern "C" fn __mulsf3vfp(a: f32, b: f32) -> f32 {
209
a * b
testcrate/tests/mul.rs
@@ -1,4 +1,6 @@
1
#![allow(unused_macros)]
2
+#![feature(f128)]
3
+#![feature(f16)]
4
5
use core::ops::Mul;
6
use testcrate::*;
@@ -114,6 +116,18 @@ fn float_mul() {
114
116
f32, __mulsf3, Single, all();
115
117
f64, __muldf3, Double, all();
118
);
119
120
121
+ {
122
+ use compiler_builtins::float::mul::__multf3;
123
124
+ float_mul!(
125
+ f128, __multf3, Quad,
126
+ // FIXME(llvm): there is a bug in LLVM rt.
127
+ // See <https://github.com/llvm/llvm-project/issues/91840>.
128
+ not(any(feature = "no-sys-f128", all(target_arch = "aarch64", target_os = "linux")));
129
+ );
130
131
132
133
0 commit comments