Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/arch/aarch64/softfloat delete __{ge, lt, gt, le, eq, ne, ...



details:   https://anonhg.NetBSD.org/src/rev/0881e4b8546d
branches:  trunk
changeset: 364914:0881e4b8546d
user:      ryo <ryo%NetBSD.org@localhost>
date:      Mon Aug 27 16:46:13 2018 +0000

description:
delete __{ge,lt,gt,le,eq,ne,unordt}tf2.
these should not be defined in libc.

pointed out by joerg@. thanks.

diffstat:

 lib/libc/arch/aarch64/softfloat/qp.c |  89 +-----------------------------------
 1 files changed, 1 insertions(+), 88 deletions(-)

diffs (114 lines):

diff -r b74c96e46072 -r 0881e4b8546d lib/libc/arch/aarch64/softfloat/qp.c
--- a/lib/libc/arch/aarch64/softfloat/qp.c      Mon Aug 27 16:30:51 2018 +0000
+++ b/lib/libc/arch/aarch64/softfloat/qp.c      Mon Aug 27 16:46:13 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: qp.c,v 1.2 2018/08/11 10:06:40 ryo Exp $ */
+/* $NetBSD: qp.c,v 1.3 2018/08/27 16:46:13 ryo Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -47,14 +47,6 @@
 long double __negtf2(long double);
 long double __subtf3(long double, long double);
 
-int __libc_getf2(long double, long double);
-int __libc_lttf2(long double, long double);
-int __libc_gttf2(long double, long double);
-int __libc_letf2(long double, long double);
-int __libc_eqtf2(long double, long double);
-int __libc_netf2(long double, long double);
-int __libc_unordtf2(long double, long double);
-
 double __trunctfdf2(long double);
 float __trunctfsf2(long double);
 
@@ -182,70 +174,6 @@
 }
 #endif
 
-#ifdef __weak_alias
-__weak_alias(__eqtf2, __libc_eqtf2)
-__weak_alias(__getf2, __libc_getf2)
-__weak_alias(__gttf2, __libc_gttf2)
-__weak_alias(__letf2, __libc_letf2)
-__weak_alias(__lttf2, __libc_lttf2)
-__weak_alias(__netf2, __libc_netf2)
-__weak_alias(__unordtf2, __libc_unordtf2)
-#endif
-
-int
-__libc_eqtf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return float128_eq(a.ldblu_f128, b.ldblu_f128);
-}
-
-int
-__libc_getf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return float128_le(b.ldblu_f128, a.ldblu_f128);
-}
-
-int
-__libc_gttf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return float128_lt(b.ldblu_f128, a.ldblu_f128);
-}
-
-int
-__libc_letf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return float128_le(a.ldblu_f128, b.ldblu_f128);
-}
-
-int
-__libc_lttf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return float128_lt(a.ldblu_f128, b.ldblu_f128);
-}
-
-int
-__libc_netf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       return !float128_eq(a.ldblu_f128, b.ldblu_f128);
-}
-
 float
 __trunctfsf2(long double ld_a)
 {
@@ -371,18 +299,3 @@
 
        return c.ldblu_ld;
 }
-
-int
-__libc_unordtf2(long double ld_a, long double ld_b)
-{
-       const union sf_ieee_ldbl_u a = { .ldblu_ld = ld_a };
-       const union sf_ieee_ldbl_u b = { .ldblu_ld = ld_b };
-
-       /*
-        * The comparison is unordered if either input is a NaN.
-        * Test for this by comparing each operand with itself.
-        * We must perform both comparisons to correctly check for
-        * signalling NaNs.
-        */
-       return 1 ^ (float128_eq(a.ldblu_f128, a.ldblu_f128) & float128_eq(b.ldblu_f128, b.ldblu_f128));
-}



Home | Main Index | Thread Index | Old Index