public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k
@ 2012-02-24 16:13 carlos at systemhalted dot org
  2012-02-24 16:13 ` [Bug ports/13742] " carlos at systemhalted dot org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: carlos at systemhalted dot org @ 2012-02-24 16:13 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=13742

             Bug #: 13742
           Summary: Use of fsincos is incorrect for large input on m68k
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ports
        AssignedTo: unassigned@sourceware.org
        ReportedBy: carlos@systemhalted.org
                CC: carlos@systemhalted.org, roland@gnu.org,
                    schwab@linux-m68k.org
    Classification: Unclassified
            Target: m68k-linux-gnu


This bug:
http://sourceware.org/bugzilla/show_bug.cgi?id=13658

Raises the question of the accuracy of hardware fsincos instructions for large
inputs.

It would appear that this bug, present on x86 and x86_64, would also effect
m68k since it uses a fsincos instruction with limited accuracy at high input
values.

A quick grep shows:
sysdeps/m68k/m680x0/fpu/s_csin.c:      __asm ("fsincos%.x %2,%1:%0" : "=f"
(sin_rx), "=f" (cos_rx)
sysdeps/m68k/m680x0/fpu/bits/mathinline.h:  __asm ("fsincos%.x %2,%1:%0"       
                                        \
sysdeps/m68k/m680x0/fpu/k_sin.c:  __asm__ __volatile__ ("fsincosx %2,%0:%1" :
"=f" (cos_x), "=f" (sin_x)
sysdeps/m68k/m680x0/fpu/k_sin.c:  __asm__ __volatile__ ("fsincosx %2,%0:%1" :
"=f" (cos_y), "=f" (sin_y)
sysdeps/m68k/m680x0/fpu/s_ccosh.c:      __asm ("fsincos%.x %2,%1:%0" : "=f"
(sin_ix), "=f" (cos_ix)
sysdeps/m68k/m680x0/fpu/s_csinh.c:      __asm ("fsincos%.x %2,%1:%0" : "=f"
(sin_ix), "=f" (cos_ix)
sysdeps/m68k/m680x0/fpu/k_cos.c:  __asm__ __volatile__ ("fsincosx %2,%0:%1" :
"=f" (cos_x), "=f" (sin_x)
sysdeps/m68k/m680x0/fpu/k_cos.c:  __asm__ __volatile__ ("fsincosx %2,%0:%1" :
"=f" (cos_y), "=f" (sin_y)
sysdeps/m68k/m680x0/fpu/s_cexp.c:         __asm ("fsincos%.x %2,%1:%0" : "=f"
(sin_ix), "=f" (cos_ix)

A quick inspection does not show any input argument reduction.

The M68000PM/AD REV.1 states loss of accuracy if the input is > 10^20.

Therefore it seems to me that the m68k port also suffers the same problems as
x86 and x86_64.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug ports/13742] Use of fsincos is incorrect for large input on m68k
  2012-02-24 16:13 [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k carlos at systemhalted dot org
@ 2012-02-24 16:13 ` carlos at systemhalted dot org
  2012-04-05  9:28 ` aj at suse dot de
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: carlos at systemhalted dot org @ 2012-02-24 16:13 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=13742

Carlos O'Donell <carlos at systemhalted dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |UNCONFIRMED
     Ever Confirmed|1                           |0

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug ports/13742] Use of fsincos is incorrect for large input on m68k
  2012-02-24 16:13 [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k carlos at systemhalted dot org
  2012-02-24 16:13 ` [Bug ports/13742] " carlos at systemhalted dot org
@ 2012-04-05  9:28 ` aj at suse dot de
  2014-02-11  0:31 ` [Bug math/13742] [m68k] " jsm28 at gcc dot gnu.org
  2014-06-26 15:15 ` fweimer at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: aj at suse dot de @ 2012-04-05  9:28 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=13742

Andreas Jaeger <aj at suse dot de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at sourceware    |schwab@linux-m68k.org
                   |dot org                     |

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug math/13742] [m68k] Use of fsincos is incorrect for large input on m68k
  2012-02-24 16:13 [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k carlos at systemhalted dot org
  2012-02-24 16:13 ` [Bug ports/13742] " carlos at systemhalted dot org
  2012-04-05  9:28 ` aj at suse dot de
@ 2014-02-11  0:31 ` jsm28 at gcc dot gnu.org
  2014-06-26 15:15 ` fweimer at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: jsm28 at gcc dot gnu.org @ 2014-02-11  0:31 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=13742

Joseph Myers <jsm28 at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|ports                       |math
               Host|                            |m68k-*-*
            Summary|Use of fsincos is incorrect |[m68k] Use of fsincos is
                   |for large input on m68k     |incorrect for large input
                   |                            |on m68k

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Bug math/13742] [m68k] Use of fsincos is incorrect for large input on m68k
  2012-02-24 16:13 [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k carlos at systemhalted dot org
                   ` (2 preceding siblings ...)
  2014-02-11  0:31 ` [Bug math/13742] [m68k] " jsm28 at gcc dot gnu.org
@ 2014-06-26 15:15 ` fweimer at redhat dot com
  3 siblings, 0 replies; 5+ messages in thread
From: fweimer at redhat dot com @ 2014-06-26 15:15 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=13742

Florian Weimer <fweimer at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
              Flags|                            |security-

-- 
You are receiving this mail because:
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2014-06-26 15:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-02-24 16:13 [Bug ports/13742] New: Use of fsincos is incorrect for large input on m68k carlos at systemhalted dot org
2012-02-24 16:13 ` [Bug ports/13742] " carlos at systemhalted dot org
2012-04-05  9:28 ` aj at suse dot de
2014-02-11  0:31 ` [Bug math/13742] [m68k] " jsm28 at gcc dot gnu.org
2014-06-26 15:15 ` fweimer at redhat dot com

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).