Remove code without too much effects

Some of the AVX-specific code is not giving enough speed-up to
justify the extra code.
This commit is contained in:
Ulrich Drepper 2011-10-28 16:55:01 -04:00
parent 0c92d8a87a
commit a5b81e1fb7
16 changed files with 28 additions and 113 deletions

View File

@ -1,3 +1,26 @@
2011-10-28 Ulrich Drepper <drepper@gmail.com>
* sysdeps/x86_64/fpu/multiarch/Makefile: Don't build brandred-avx.c,
doasin-avx.c, dosincos-avx.c, e_asin-avx.c, mpatan-avx.c,
mpatan2-avx.c, mpsqrt-avx.c, mptan-avx.c, sincos32-avx.c.
* sysdeps/x86_64/fpu/multiarch/e_asin.c: There are no _avx variants
anymore.
* sysdeps/x86_64/fpu/multiarch/e_atan2-avx.c: Don't redirect __mpatan2.
* sysdeps/x86_64/fpu/multiarch/s_atan-avx.c: Don't redirect __mpatan.
* sysdeps/x86_64/fpu/multiarch/s_sin-avx.c: Don't redirect __branred,
__docos, __dubsin, __mpcos, __mpcos1, __mpsin, __mpsin1.
* sysdeps/x86_64/fpu/multiarch/s_tan-avx.c: Don't redirect __branred,
__mpranred, __mptan.
* sysdeps/x86_64/fpu/multiarch/brandred-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/doasin-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/dosincos-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/e_asin-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/mpatan-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/mpatan2-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/mpsqrt-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/mptan-avx.c: Removed.
* sysdeps/x86_64/fpu/multiarch/sincos32-avx.c: Removed.
2011-10-28 Andreas Schwab <schwab@redhat.com> 2011-10-28 Andreas Schwab <schwab@redhat.com>
* sysdeps/i386/i686/multiarch/strnlen-c.c (libc_hidden_def): Only * sysdeps/i386/i686/multiarch/strnlen-c.c (libc_hidden_def): Only

View File

@ -36,29 +36,18 @@ endif
ifeq ($(config-cflags-avx),yes) ifeq ($(config-cflags-avx),yes)
libm-sysdep_routines += e_exp-avx e_log-avx s_atan-avx \ libm-sysdep_routines += e_exp-avx e_log-avx s_atan-avx \
e_asin-avx e_atan2-avx s_sin-avx s_tan-avx \ e_atan2-avx s_sin-avx s_tan-avx \
mplog-avx mpa-avx slowexp-avx \ mplog-avx mpa-avx slowexp-avx \
sincos32-avx doasin-avx dosincos-avx \ mpexp-avx
brandred-avx mpexp-avx \
mpatan2-avx mpatan-avx mpsqrt-avx mptan-avx
CFLAGS-brandred-avx.c = -mavx
CFLAGS-doasin-avx.c = -mavx
CFLAGS-dosincos-avx.c = -mavx
CFLAGS-e_asin-avx.c = -mavx
CFLAGS-e_atan2-avx.c = -mavx CFLAGS-e_atan2-avx.c = -mavx
CFLAGS-e_exp-avx.c = -mavx CFLAGS-e_exp-avx.c = -mavx
CFLAGS-e_log-avx.c = -mavx CFLAGS-e_log-avx.c = -mavx
CFLAGS-mpa-avx.c = -mavx CFLAGS-mpa-avx.c = -mavx
CFLAGS-mpatan-avx.c = -mavx
CFLAGS-mpatan2-avx.c = -mavx
CFLAGS-mpexp-avx.c = -mavx CFLAGS-mpexp-avx.c = -mavx
CFLAGS-mplog-avx.c = -mavx CFLAGS-mplog-avx.c = -mavx
CFLAGS-mpsqrt-avx.c = -mavx
CFLAGS-mptan-avx.c = -mavx
CFLAGS-s_atan-avx.c = -mavx CFLAGS-s_atan-avx.c = -mavx
CFLAGS-s_sin-avx.c = -mavx CFLAGS-s_sin-avx.c = -mavx
CFLAGS-sincos32-avx.c = -mavx
CFLAGS-slowexp-avx.c = -mavx CFLAGS-slowexp-avx.c = -mavx
CFLAGS-s_tan-avx.c = -mavx CFLAGS-s_tan-avx.c = -mavx
endif endif

View File

@ -1,4 +0,0 @@
#define __branred __branred_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/branred.c>

View File

@ -1,4 +0,0 @@
#define __doasin __doasin_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/doasin.c>

View File

@ -1,6 +0,0 @@
#define __docos __docos_avx
#define __dubcos __dubcos_avx
#define __dubsin __dubsin_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/dosincos.c>

View File

@ -1,11 +0,0 @@
#define __ieee754_acos __ieee754_acos_avx
#define __ieee754_asin __ieee754_asin_avx
#define __cos32 __cos32_avx
#define __doasin __doasin_avx
#define __docos __docos_avx
#define __dubcos __dubcos_avx
#define __dubsin __dubsin_avx
#define __sin32 __sin32_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/e_asin.c>

View File

@ -1,29 +1,18 @@
#if defined HAVE_FMA4_SUPPORT || defined HAVE_AVX_SUPPORT #ifdef HAVE_FMA4_SUPPORT
# include <init-arch.h> # include <init-arch.h>
# include <math_private.h> # include <math_private.h>
extern double __ieee754_acos_sse2 (double); extern double __ieee754_acos_sse2 (double);
extern double __ieee754_asin_sse2 (double); extern double __ieee754_asin_sse2 (double);
extern double __ieee754_acos_avx (double);
extern double __ieee754_asin_avx (double);
# ifdef HAVE_FMA4_SUPPORT
extern double __ieee754_acos_fma4 (double); extern double __ieee754_acos_fma4 (double);
extern double __ieee754_asin_fma4 (double); extern double __ieee754_asin_fma4 (double);
# else
# undef HAS_FMA4
# define HAS_FMA4 0
# define __ieee754_acos_fma4 ((void *) 0)
# define __ieee754_asin_fma4 ((void *) 0)
# endif
libm_ifunc (__ieee754_acos, libm_ifunc (__ieee754_acos,
HAS_FMA4 ? __ieee754_acos_fma4 HAS_FMA4 ? __ieee754_acos_fma4 : __ieee754_acos_sse2);
: (HAS_AVX ? __ieee754_acos_avx : __ieee754_acos_sse2));
strong_alias (__ieee754_acos, __acos_finite) strong_alias (__ieee754_acos, __acos_finite)
libm_ifunc (__ieee754_asin, libm_ifunc (__ieee754_asin,
HAS_FMA4 ? __ieee754_asin_fma4 HAS_FMA4 ? __ieee754_asin_fma4 : __ieee754_asin_sse2);
: (HAS_AVX ? __ieee754_asin_avx : __ieee754_asin_sse2));
strong_alias (__ieee754_asin, __asin_finite) strong_alias (__ieee754_asin, __asin_finite)
# define __ieee754_acos __ieee754_acos_sse2 # define __ieee754_acos __ieee754_acos_sse2

View File

@ -2,7 +2,6 @@
#define __add __add_avx #define __add __add_avx
#define __dbl_mp __dbl_mp_avx #define __dbl_mp __dbl_mp_avx
#define __dvd __dvd_avx #define __dvd __dvd_avx
#define __mpatan2 __mpatan2_avx
#define __mul __mul_avx #define __mul __mul_avx
#define __sub __sub_avx #define __sub __sub_avx
#define SECTION __attribute__ ((section (".text.avx"))) #define SECTION __attribute__ ((section (".text.avx")))

View File

@ -1,10 +0,0 @@
#define __mpatan __mpatan_avx
#define __add __add_avx
#define __dvd __dvd_avx
#define __mpsqrt __mpsqrt_avx
#define __mul __mul_avx
#define __sub __sub_avx
#define AVOID_MPATAN_H 1
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/mpatan.c>

View File

@ -1,9 +0,0 @@
#define __mpatan2 __mpatan2_avx
#define __add __add_avx
#define __dvd __dvd_avx
#define __mpatan __mpatan_avx
#define __mpsqrt __mpsqrt_avx
#define __mul __mul_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/mpatan2.c>

View File

@ -1,8 +0,0 @@
#define __mpsqrt __mpsqrt_avx
#define __dbl_mp __dbl_mp_avx
#define __mul __mul_avx
#define __sub __sub_avx
#define AVOID_MPSQRT_H 1
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/mpsqrt.c>

View File

@ -1,7 +0,0 @@
#define __mptan __mptan_avx
#define __c32 __c32_avx
#define __dvd __dvd_avx
#define __mpranred __mpranred_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/mptan.c>

View File

@ -1,7 +1,6 @@
#define atan __atan_avx #define atan __atan_avx
#define __add __add_avx #define __add __add_avx
#define __dbl_mp __dbl_mp_avx #define __dbl_mp __dbl_mp_avx
#define __mpatan __mpatan_avx
#define __mul __mul_avx #define __mul __mul_avx
#define __sub __sub_avx #define __sub __sub_avx
#define SECTION __attribute__ ((section (".text.avx"))) #define SECTION __attribute__ ((section (".text.avx")))

View File

@ -1,12 +1,5 @@
#define __cos __cos_avx #define __cos __cos_avx
#define __sin __sin_avx #define __sin __sin_avx
#define __branred __branred_avx
#define __docos __docos_avx
#define __dubsin __dubsin_avx
#define __mpcos __mpcos_avx
#define __mpcos1 __mpcos1_avx
#define __mpsin __mpsin_avx
#define __mpsin1 __mpsin1_avx
#define SECTION __attribute__ ((section (".text.avx"))) #define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/s_sin.c> #include <sysdeps/ieee754/dbl-64/s_sin.c>

View File

@ -1,8 +1,5 @@
#define tan __tan_avx #define tan __tan_avx
#define __branred __branred_avx
#define __dbl_mp __dbl_mp_avx #define __dbl_mp __dbl_mp_avx
#define __mpranred __mpranred_avx
#define __mptan __mptan_avx
#define __sub __sub_avx #define __sub __sub_avx
#define SECTION __attribute__ ((section (".text.avx"))) #define SECTION __attribute__ ((section (".text.avx")))

View File

@ -1,15 +0,0 @@
#define __cos32 __cos32_avx
#define __sin32 __sin32_avx
#define __c32 __c32_avx
#define __mpsin __mpsin_avx
#define __mpsin1 __mpsin1_avx
#define __mpcos __mpcos_avx
#define __mpcos1 __mpcos1_avx
#define __mpranred __mpranred_avx
#define __add __add_avx
#define __dbl_mp __dbl_mp_avx
#define __mul __mul_avx
#define __sub __sub_avx
#define SECTION __attribute__ ((section (".text.avx")))
#include <sysdeps/ieee754/dbl-64/sincos32.c>