summaryrefslogtreecommitdiff
path: root/sysdeps/powerpc/fpu/math_private.h
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 15:58:23 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2018-12-27 15:58:23 +0000
commit25ead03a3712d57df2208fe82f3d316eb8faeaf6 (patch)
treeeb6ebccbeffba879a7cf9cbaa29daeeb73d8e049 /sysdeps/powerpc/fpu/math_private.h
parentbf9f3c5bced2d3a5fb782b5a7de1008d8ca1425c (diff)
parent963c37d5c0eb62b38f8764b23931c0dcdd497a13 (diff)
Merge commit 'refs/top-bases/t/faccessat' into t/faccessat
Diffstat (limited to 'sysdeps/powerpc/fpu/math_private.h')
-rw-r--r--sysdeps/powerpc/fpu/math_private.h33
1 files changed, 7 insertions, 26 deletions
diff --git a/sysdeps/powerpc/fpu/math_private.h b/sysdeps/powerpc/fpu/math_private.h
index d90327c4af..e642d6c823 100644
--- a/sysdeps/powerpc/fpu/math_private.h
+++ b/sysdeps/powerpc/fpu/math_private.h
@@ -1,5 +1,5 @@
/* Private inline math functions for powerpc.
- Copyright (C) 2006-2016 Free Software Foundation, Inc.
+ Copyright (C) 2006-2018 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -23,38 +23,19 @@
#include <ldsodefs.h>
#include <dl-procinfo.h>
#include <fenv_private.h>
+
#include_next <math_private.h>
-extern double __slow_ieee754_sqrt (double);
-extern __always_inline double
-__ieee754_sqrt (double __x)
+#if defined _ARCH_PWR9 && __HAVE_DISTINCT_FLOAT128
+extern __always_inline _Float128
+__ieee754_sqrtf128 (_Float128 __x)
{
- double __z;
-
-#ifdef _ARCH_PPCSQ
- asm ("fsqrt %0,%1" : "=f" (__z) : "f" (__x));
-#else
- __z = __slow_ieee754_sqrt(__x);
-#endif
-
+ _Float128 __z;
+ asm ("xssqrtqp %0,%1" : "=v" (__z) : "v" (__x));
return __z;
}
-
-extern float __slow_ieee754_sqrtf (float);
-extern __always_inline float
-__ieee754_sqrtf (float __x)
-{
- float __z;
-
-#ifdef _ARCH_PPCSQ
- asm ("fsqrts %0,%1" : "=f" (__z) : "f" (__x));
-#else
- __z = __slow_ieee754_sqrtf(__x);
#endif
- return __z;
-}
-
#if defined _ARCH_PWR5X
# ifndef __round