This is the mail archive of the libc-hacker@sourceware.cygnus.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [PATCH] Fix i386 bits/mathinline.h with -ansi -pedantic


Jakub Jelinek <jakub@redhat.com> writes:

> +++ libc/sysdeps/i386/fpu/bits/mathinline.h	Mon May 22 16:28:00 2000
> @@ -367,7 +367,8 @@ __sincosl (long double __x, long double 
>      ("fscale			# 2^int(x * log2(e))\n\t"		      \
>       : "=t" (__temp) : "0" (1.0), "u" (__exponent));			      \
>    __temp -= 1.0;							      \
> -  return __temp + __value ?: __x
> +  __temp += __value;							      \
> +  return __temp ? __temp : __x
>  __inline_mathcodeNP_ (long double, __expm1l, __x, __expm1_code)

Your change is not preserving the semantics.  Once you corrected this
make sure the generated code is the same.  There is no reason at all
to make the generated worse code.

-- 
---------------.      drepper at gnu.org  ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Red Hat          `--' drepper at redhat.com   `------------------------

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]