summaryrefslogtreecommitdiff
path: root/sysdeps/aarch64/fpu/exp2_advsimd.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/aarch64/fpu/exp2_advsimd.c')
-rw-r--r--sysdeps/aarch64/fpu/exp2_advsimd.c31
1 files changed, 1 insertions, 30 deletions
diff --git a/sysdeps/aarch64/fpu/exp2_advsimd.c b/sysdeps/aarch64/fpu/exp2_advsimd.c
index 71affe8f5c..a7c1222c5e 100644
--- a/sysdeps/aarch64/fpu/exp2_advsimd.c
+++ b/sysdeps/aarch64/fpu/exp2_advsimd.c
@@ -47,19 +47,6 @@ lookup_sbits (uint64x2_t i)
__v_exp_data[i[1] & IndexMask] };
}
-#if WANT_SIMD_EXCEPT
-
-# define Thres 0x2080000000000000 /* asuint64(512.0) - TinyBound. */
-
-/* Call scalar exp2 as a fallback. */
-static float64x2_t VPCS_ATTR NOINLINE
-special_case (float64x2_t x, float64x2_t y, uint64x2_t is_special)
-{
- return v_call_f64 (exp2, x, y, is_special);
-}
-
-#else
-
# define SpecialOffset 0x6000000000000000 /* 0x1p513. */
/* SpecialBias1 + SpecialBias1 = asuint(1.0). */
# define SpecialBias1 0x7000000000000000 /* 0x1p769. */
@@ -80,8 +67,6 @@ special_case (float64x2_t s, float64x2_t y, float64x2_t n,
return vbslq_f64 (cmp, r1, r0);
}
-#endif
-
/* Fast vector implementation of exp2.
Maximum measured error is 1.65 ulp.
_ZGVnN2v_exp2(-0x1.4c264ab5b559bp-6) got 0x1.f8db0d4df721fp-1
@@ -90,17 +75,7 @@ VPCS_ATTR
float64x2_t V_NAME_D1 (exp2) (float64x2_t x)
{
const struct data *d = ptr_barrier (&data);
- uint64x2_t cmp;
-#if WANT_SIMD_EXCEPT
- uint64x2_t ia = vreinterpretq_u64_f64 (vabsq_f64 (x));
- cmp = vcgeq_u64 (vsubq_u64 (ia, v_u64 (TinyBound)), v_u64 (Thres));
- /* Mask special lanes and retain a copy of x for passing to special-case
- handler. */
- float64x2_t xc = x;
- x = v_zerofy_f64 (x, cmp);
-#else
- cmp = vcagtq_f64 (x, d->scale_big_bound);
-#endif
+ uint64x2_t cmp = vcagtq_f64 (x, d->scale_big_bound);
/* n = round(x/N). */
float64x2_t z = vaddq_f64 (d->shift, x);
@@ -121,10 +96,6 @@ float64x2_t V_NAME_D1 (exp2) (float64x2_t x)
y = vmulq_f64 (r, y);
if (__glibc_unlikely (v_any_u64 (cmp)))
-#if !WANT_SIMD_EXCEPT
return special_case (s, y, n, d);
-#else
- return special_case (xc, vfmaq_f64 (s, s, y), cmp);
-#endif
return vfmaq_f64 (s, s, y);
}