Bug 15632 - MIPS sqrt implementations not being used
Summary: MIPS sqrt implementations not being used
Status: RESOLVED FIXED
Alias: None
Product: glibc
Classification: Unclassified
Component: ports (show other bugs)
Version: 2.17
: P2 normal
Target Milestone: 2.19
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-14 21:05 UTC by Joseph Myers
Modified: 2014-06-13 15:04 UTC (History)
3 users (show)

See Also:
Host: mips*-linux*
Target:
Build:
Last reconfirmed:
fweimer: security-


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Myers 2013-06-14 21:05:57 UTC
The sysdeps directory ordering for mips*-linux* is such that the MIPS sqrt implementations in ports/sysdeps/mips/fpu/ don't get used because the flt-32 and dbl-64 directories come first.  For n32 I see:

ports/sysdeps/unix/sysv/linux/mips/mips64/n32/nptl ports/sysdeps/unix/sysv/linux/mips/mips64/n32 ports/sysdeps/unix/sysv/linux/mips/mips64/nptl ports/sysdeps/unix/sysv/linux/mips/mips64 ports/sysdeps/unix/sysv/linux/mips/nptl ports/sysdeps/unix/sysv/linux/mips nptl/sysdeps/unix/sysv/linux nptl/sysdeps/pthread sysdeps/pthread ports/sysdeps/unix/sysv/linux sysdeps/unix/sysv/linux sysdeps/gnu sysdeps/unix/inet nptl/sysdeps/unix/sysv ports/sysdeps/unix/sysv sysdeps/unix/sysv ports/sysdeps/unix/mips/mips64/n32 ports/sysdeps/unix/mips/mips64 ports/sysdeps/unix/mips nptl/sysdeps/unix ports/sysdeps/unix sysdeps/unix sysdeps/posix ports/sysdeps/mips/mips64/n32 ports/sysdeps/mips/ieee754 sysdeps/ieee754/ldbl-128 ports/sysdeps/mips/mips64/soft-fp ports/sysdeps/mips/mips64 sysdeps/ieee754/flt-32 sysdeps/ieee754/dbl-64 ports/sysdeps/mips sysdeps/wordsize-32 ports/sysdeps/mips/fpu ports/sysdeps/mips/nptl sysdeps/ieee754 sysdeps/generic

For o32 I see:

ports/sysdeps/unix/sysv/linux/mips/mips32/nptl ports/sysdeps/unix/sysv/linux/mips/mips32 ports/sysdeps/unix/sysv/linux/mips/nptl ports/sysdeps/unix/sysv/linux/mips nptl/sysdeps/unix/sysv/linux nptl/sysdeps/pthread sysdeps/pthread ports/sysdeps/unix/sysv/linux sysdeps/unix/sysv/linux sysdeps/gnu sysdeps/unix/inet nptl/sysdeps/unix/sysv ports/sysdeps/unix/sysv sysdeps/unix/sysv ports/sysdeps/unix/mips/mips32 ports/sysdeps/unix/mips nptl/sysdeps/unix ports/sysdeps/unix sysdeps/unix sysdeps/posix ports/sysdeps/mips/mips32/fpu ports/sysdeps/mips/mips32 ports/sysdeps/mips/ieee754 ports/sysdeps/mips sysdeps/ieee754/flt-32 sysdeps/ieee754/dbl-64 sysdeps/wordsize-32 ports/sysdeps/mips/fpu ports/sysdeps/mips/nptl sysdeps/ieee754 sysdeps/generic

For n64 I see:

ports/sysdeps/unix/sysv/linux/mips/mips64/n64/nptl ports/sysdeps/unix/sysv/linux/mips/mips64/n64 ports/sysdeps/unix/sysv/linux/mips/mips64/nptl ports/sysdeps/unix/sysv/linux/mips/mips64 ports/sysdeps/unix/sysv/linux/mips/nptl ports/sysdeps/unix/sysv/linux/mips nptl/sysdeps/unix/sysv/linux nptl/sysdeps/pthread sysdeps/pthread ports/sysdeps/unix/sysv/linux sysdeps/unix/sysv/linux sysdeps/gnu sysdeps/unix/inet nptl/sysdeps/unix/sysv ports/sysdeps/unix/sysv sysdeps/unix/sysv ports/sysdeps/unix/mips/mips64/n64 ports/sysdeps/unix/mips/mips64 ports/sysdeps/unix/mips nptl/sysdeps/unix ports/sysdeps/unix sysdeps/unix sysdeps/posix ports/sysdeps/mips/mips64/n64 ports/sysdeps/mips/ieee754 sysdeps/ieee754/ldbl-128 ports/sysdeps/mips/mips64/soft-fp ports/sysdeps/mips/mips64 sysdeps/ieee754/flt-32 sysdeps/ieee754/dbl-64 ports/sysdeps/mips sysdeps/wordsize-64 ports/sysdeps/mips/fpu ports/sysdeps/mips/nptl sysdeps/ieee754 sysdeps/generic

The simple fix probably is wrapping these files in more specific directories such as mips/mips32/fpu that come early enough in the sysdeps ordering; I don't know if there's a better approach.
Comment 1 sje@gcc.gnu.org 2013-10-03 20:07:33 UTC
This bug has been fixed for 2.19 with this patch that is now checked in:

https://sourceware.org/ml/libc-ports/2013-10/msg00005.html

The NEWS file was also updated to include this bug number in the fixed list.