From: Jakub Jelinek <jakub@redhat.com>
To: Ulrich Drepper <drepper@redhat.com>
Cc: Glibc hackers <libc-hacker@sources.redhat.com>
Subject: [PATCH] Some more fdim* fixes
Date: Mon, 27 Sep 2004 23:28:00 -0000 [thread overview]
Message-ID: <20040927232813.GS30497@sunsite.ms.mff.cuni.cz> (raw)
Hi!
In addition to this sysdeps/i386/fpu/s_fdim*.S will need changing, but
I'm too tired now.
2004-09-28 Jakub Jelinek <jakub@redhat.com>
* sysdeps/alpha/fpu/bits/mathinline.h (__fdimf, __fdim, fdimf, fdim):
Handle +inf/+inf.
* sysdeps/powerpc/fpu/bits/mathinline.h (fdim, fdimf): Likewise.
* sysdeps/sparc/fpu/bits/mathinline.h (fdim, fdimf): Likewise.
--- libc/sysdeps/alpha/fpu/bits/mathinline.h.jj 2004-09-14 00:32:56.000000000 +0200
+++ libc/sysdeps/alpha/fpu/bits/mathinline.h 2004-09-28 01:13:07.758804136 +0200
@@ -149,25 +149,25 @@ __MATH_INLINE double __NTH (floor (doubl
__MATH_INLINE float
__NTH (__fdimf (float __x, float __y))
{
- return __x < __y ? 0.0f : __x - __y;
+ return __x <= __y ? 0.0f : __x - __y;
}
__MATH_INLINE float
__NTH (fdimf (float __x, float __y))
{
- return __x < __y ? 0.0f : __x - __y;
+ return __x <= __y ? 0.0f : __x - __y;
}
__MATH_INLINE double
__NTH (__fdim (double __x, double __y))
{
- return __x < __y ? 0.0 : __x - __y;
+ return __x <= __y ? 0.0 : __x - __y;
}
__MATH_INLINE double
__NTH (fdim (double __x, double __y))
{
- return __x < __y ? 0.0 : __x - __y;
+ return __x <= __y ? 0.0 : __x - __y;
}
/* Test for negative number. Used in the signbit() macro. */
--- libc/sysdeps/powerpc/fpu/bits/mathinline.h.jj 2004-09-14 00:33:00.000000000 +0200
+++ libc/sysdeps/powerpc/fpu/bits/mathinline.h 2004-09-28 01:13:45.405114561 +0200
@@ -109,14 +109,14 @@ __MATH_INLINE double fdim (double __x, d
__MATH_INLINE double
__NTH (fdim (double __x, double __y))
{
- return __x < __y ? 0 : __x - __y;
+ return __x <= __y ? 0 : __x - __y;
}
__MATH_INLINE float fdimf (float __x, float __y) __THROW;
__MATH_INLINE float
__NTH (fdimf (float __x, float __y))
{
- return __x < __y ? 0 : __x - __y;
+ return __x <= __y ? 0 : __x - __y;
}
#endif /* __USE_ISOC99 */
--- libc/sysdeps/sparc/fpu/bits/mathinline.h.jj 2004-08-04 14:42:26.000000000 +0200
+++ libc/sysdeps/sparc/fpu/bits/mathinline.h 2004-09-28 01:14:31.346950890 +0200
@@ -223,14 +223,14 @@ __MATH_INLINE double fdim (double __x, d
__MATH_INLINE double
fdim (double __x, double __y) __THROW
{
- return __x < __y ? 0 : __x - __y;
+ return __x <= __y ? 0 : __x - __y;
}
__MATH_INLINE float fdimf (float __x, float __y) __THROW;
__MATH_INLINE float
fdimf (float __x, float __y) __THROW
{
- return __x < __y ? 0 : __x - __y;
+ return __x <= __y ? 0 : __x - __y;
}
# endif /* !__NO_MATH_INLINES */
Jakub
reply other threads:[~2004-09-27 23:28 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20040927232813.GS30497@sunsite.ms.mff.cuni.cz \
--to=jakub@redhat.com \
--cc=drepper@redhat.com \
--cc=libc-hacker@sources.redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).