Skip to content
This repository was archived by the owner on Mar 31, 2025. It is now read-only.

Commit d662ff1

Browse files
committed
Fix float build on aarch64 and loongarch64
1 parent 0c28e62 commit d662ff1

15 files changed

+57
-1
lines changed

divxc3.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
#include "int_lib.h"
1818
#include "int_math.h"
1919

20+
#if HAS_80_BIT_LONG_DOUBLE == 1
21+
2022
// Returns: the quotient of (a + ib) / (c + id)
2123

2224
COMPILER_RT_ABI Lcomplex __divxc3(xf_float __a, xf_float __b, xf_float __c,
@@ -57,3 +59,5 @@ COMPILER_RT_ABI Lcomplex __divxc3(xf_float __a, xf_float __b, xf_float __c,
5759
#endif
5860

5961
#endif
62+
63+
#endif

fixunsxfdi.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
#include "int_lib.h"
1818

19+
#if HAS_80_BIT_LONG_DOUBLE == 1
20+
1921
// Returns: convert a to a unsigned long long, rounding toward zero.
2022
// Negative values all become zero.
2123

@@ -49,6 +51,8 @@ COMPILER_RT_ABI du_int __fixunsxfdi(xf_float a) {
4951
#pragma warning(pop)
5052
#endif
5153

54+
#endif
55+
5256
#endif //!_ARCH_PPC
5357

5458
#endif

fixunsxfsi.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
#include "int_lib.h"
1818

19+
#if HAS_80_BIT_LONG_DOUBLE == 1
20+
1921
// Returns: convert a to a unsigned int, rounding toward zero.
2022
// Negative values all become zero.
2123

@@ -49,6 +51,8 @@ COMPILER_RT_ABI su_int __fixunsxfsi(xf_float a) {
4951
#pragma warning(pop)
5052
#endif
5153

54+
#endif
55+
5256
#endif // !_ARCH_PPC
5357

5458
#endif

fixunsxfti.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414

1515
#include "int_lib.h"
1616

17+
#if HAS_80_BIT_LONG_DOUBLE == 1
18+
1719
#ifdef CRT_HAS_128BIT
1820

1921
// Returns: convert a to a unsigned long long, rounding toward zero.
@@ -46,3 +48,5 @@ COMPILER_RT_ABI tu_int __fixunsxfti(xf_float a) {
4648
#endif // CRT_HAS_128BIT
4749

4850
#endif
51+
52+
#endif

fixxfdi.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
#include "int_lib.h"
1818

19+
#if HAS_80_BIT_LONG_DOUBLE == 1
20+
1921
// Returns: convert a to a signed long long, rounding toward zero.
2022

2123
// Assumption: long double is an intel 80 bit floating point type padded with 6
@@ -53,6 +55,8 @@ COMPILER_RT_ABI di_int __fixxfdi(xf_float a) {
5355
#pragma warning(pop)
5456
#endif
5557

58+
#endif
59+
5660
#endif // !_ARCH_PPC
5761

5862
#endif

fixxfti.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414

1515
#include "int_lib.h"
1616

17+
#if HAS_80_BIT_LONG_DOUBLE == 1
18+
1719
#ifdef CRT_HAS_128BIT
1820

1921
// Returns: convert a to a signed long long, rounding toward zero.
@@ -48,3 +50,5 @@ COMPILER_RT_ABI ti_int __fixxfti(xf_float a) {
4850
#endif // CRT_HAS_128BIT
4951

5052
#endif
53+
54+
#endif

floatdixf.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
#include "int_lib.h"
1818

19+
#if HAS_80_BIT_LONG_DOUBLE == 1
20+
1921
// Returns: convert a to a long double, rounding toward even.
2022

2123
// Assumption: long double is a IEEE 80 bit floating point type padded to 128
@@ -40,6 +42,8 @@ COMPILER_RT_ABI xf_float __floatdixf(di_int a) {
4042
return fb.f;
4143
}
4244

45+
#endif
46+
4347
#endif // !_ARCH_PPC
4448

4549
#endif

floattixf.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414

1515
#include "int_lib.h"
1616

17+
#if HAS_80_BIT_LONG_DOUBLE == 1
18+
1719
#ifdef CRT_HAS_128BIT
1820

1921
// Returns: convert a to a long double, rounding toward even.
@@ -75,3 +77,5 @@ COMPILER_RT_ABI xf_float __floattixf(ti_int a) {
7577
#endif // CRT_HAS_128BIT
7678

7779
#endif
80+
81+
#endif

floatundixf.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616

1717
#include "int_lib.h"
1818

19+
#if HAS_80_BIT_LONG_DOUBLE == 1
20+
1921
// Returns: convert a to a long double, rounding toward even.
2022

2123
// Assumption: long double is a IEEE 80 bit floating point type padded to 128
@@ -36,6 +38,8 @@ COMPILER_RT_ABI xf_float __floatundixf(du_int a) {
3638
return fb.f;
3739
}
3840

41+
#endif
42+
3943
#endif // _ARCH_PPC
4044

4145
#endif

floatuntixf.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414

1515
#include "int_lib.h"
1616

17+
#if HAS_80_BIT_LONG_DOUBLE == 1
18+
1719
#ifdef CRT_HAS_128BIT
1820

1921
// Returns: convert a to a long double, rounding toward even.
@@ -72,3 +74,5 @@ COMPILER_RT_ABI xf_float __floatuntixf(tu_int a) {
7274
#endif
7375

7476
#endif
77+
78+
#endif

0 commit comments

Comments
 (0)