mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-30 08:40:07 +00:00
bc4e8f9b49
Continuing the preparation for additional _FloatN / _FloatNx function aliases, this patch makes i386 libm function implementations use libm_alias_double to define function aliases. Tested with build-many-glibcs.py for all its i386 configurations that installed stripped shared libraries are unchanged by the patch, as well as running the full glibc testsuite for i686. * sysdeps/i386/fpu/s_asinh.S: Include <libm-alias-double.h>. (asinh): Define using libm_alias_double. * sysdeps/i386/fpu/s_atan.S: Include <libm-alias-double.h>. (atan): Define using libm_alias_double. * sysdeps/i386/fpu/s_cbrt.S: Include <libm-alias-double.h>. (cbrt): Define using libm_alias_double. * sysdeps/i386/fpu/s_ceil.S: Include <libm-alias-double.h>. (ceil): Define using libm_alias_double. * sysdeps/i386/fpu/s_copysign.S: Include <libm-alias-double.h>. (copysign): Define using libm_alias_double. * sysdeps/i386/fpu/s_expm1.S: Include <libm-alias-double.h>. (expm1): Define using libm_alias_double. * sysdeps/i386/fpu/s_fabs.S: Include <libm-alias-double.h>. (fabs): Define using libm_alias_double. * sysdeps/i386/fpu/s_fdim.c: Include <libm-alias-double.h>. (fdim): Define using libm_alias_double. * sysdeps/i386/fpu/s_floor.S: Include <libm-alias-double.h>. (floor): Define using libm_alias_double. * sysdeps/i386/fpu/s_fmax.S: Include <libm-alias-double.h>. (fmax): Define using libm_alias_double. * sysdeps/i386/fpu/s_fmin.S: Include <libm-alias-double.h>. (fmin): Define using libm_alias_double. * sysdeps/i386/fpu/s_frexp.S: Include <libm-alias-double.h>. (frexp): Define using libm_alias_double. * sysdeps/i386/fpu/s_llrint.S: Include <libm-alias-double.h>. (llrint): Define using libm_alias_double. * sysdeps/i386/fpu/s_logb.S: Include <libm-alias-double.h>. (logb): Define using libm_alias_double. * sysdeps/i386/fpu/s_lrint.S: Include <libm-alias-double.h>. (lrint): Define using libm_alias_double. * sysdeps/i386/fpu/s_nearbyint.S: Include <libm-alias-double.h>. (nearbyint): Define using libm_alias_double. * sysdeps/i386/fpu/s_remquo.S: Include <libm-alias-double.h>. (remquo): Define using libm_alias_double. * sysdeps/i386/fpu/s_rint.S: Include <libm-alias-double.h>. (rint): Define using libm_alias_double. * sysdeps/i386/fpu/s_trunc.S: Include <libm-alias-double.h>. (trunc): Define using libm_alias_double. * sysdeps/i386/i686/fpu/s_fmax.S: Include <libm-alias-double.h>. (fmax): Define using libm_alias_double. * sysdeps/i386/i686/fpu/s_fmin.S: Include <libm-alias-double.h>. (fmin): Define using libm_alias_double. * sysdeps/i386/i686/multiarch/s_fma.c: Include <libm-alias-double.h>. (fma): Define using libm_alias_double.
47 lines
827 B
ArmAsm
47 lines
827 B
ArmAsm
/*
|
|
* Written by Ulrich Drepper <drepper@cygnus.com>.
|
|
* Based on e_remainder by J.T. Conklin <jtc@netbsd.org>.
|
|
* Public domain.
|
|
*/
|
|
|
|
#include <machine/asm.h>
|
|
#include <libm-alias-double.h>
|
|
|
|
#define PARMS 4 /* no space for saved regs */
|
|
#define DVDND PARMS
|
|
#define DVSOR DVDND+8
|
|
#define QUOP DVSOR+8
|
|
|
|
.text
|
|
ENTRY (__remquo)
|
|
|
|
fldl DVSOR(%esp)
|
|
fldl DVDND(%esp)
|
|
1: fprem1
|
|
fstsw %ax
|
|
sahf
|
|
jp 1b
|
|
fstp %st(1)
|
|
/* Compute the congruent of the quotient. */
|
|
movl %eax, %ecx
|
|
shrl $8, %eax
|
|
shrl $12, %ecx
|
|
andl $4, %ecx
|
|
andl $3, %eax
|
|
orl %eax, %ecx
|
|
leal (%ecx,%ecx,2),%ecx
|
|
movl $0xef2a60, %eax
|
|
shrl %cl, %eax
|
|
andl $7, %eax
|
|
movl QUOP(%esp), %ecx
|
|
movl DVDND+4(%esp), %edx
|
|
xorl DVSOR+4(%esp), %edx
|
|
testl $0x80000000, %edx
|
|
jz 1f
|
|
negl %eax
|
|
1: movl %eax, (%ecx)
|
|
|
|
ret
|
|
END (__remquo)
|
|
libm_alias_double (__remquo, remquo)
|