summary refs log tree commit diff
path: root/sysdeps/powerpc/fpu/e_hypot.c
diff options
context:
space:
mode:
authorAdhemerval Zanella <azanella@linux.vnet.ibm.com>2013-05-17 08:12:16 -0500
committerAdhemerval Zanella <azanella@linux.vnet.ibm.com>2013-05-17 08:15:59 -0500
commit13d3b41a36c4f28d171a144f8a9baad3a8835981 (patch)
tree2e4498103760e4ac92de2c5e06e5b64c7ac29c7a /sysdeps/powerpc/fpu/e_hypot.c
parent2848b105856e49d98f3c5026b6d8d790f9723c0c (diff)
downloadglibc-13d3b41a36c4f28d171a144f8a9baad3a8835981.tar.gz
glibc-13d3b41a36c4f28d171a144f8a9baad3a8835981.tar.xz
glibc-13d3b41a36c4f28d171a144f8a9baad3a8835981.zip
PowerPC: fix hypot/hypotf check for -INF
Diffstat (limited to 'sysdeps/powerpc/fpu/e_hypot.c')
-rw-r--r--sysdeps/powerpc/fpu/e_hypot.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sysdeps/powerpc/fpu/e_hypot.c b/sysdeps/powerpc/fpu/e_hypot.c
index 53419337ff..8cf5b02d92 100644
--- a/sysdeps/powerpc/fpu/e_hypot.c
+++ b/sysdeps/powerpc/fpu/e_hypot.c
@@ -54,13 +54,13 @@ static const double pdnum   = 2.225073858507201e-308;
    ieee_double_shape_type gh_u2;                                  \
    gh_u1.value = (d1);                                            \
    gh_u2.value = (d2);                                            \
-   (i1) = gh_u1.parts.msw;                                        \
-   (i2) = gh_u2.parts.msw;                                        \
+   (i1) = gh_u1.parts.msw & 0x7fffffff;                           \
+   (i2) = gh_u2.parts.msw & 0x7fffffff;                           \
  } while (0)
 
 # define TEST_INF_NAN(x, y)                                      \
  do {                                                            \
-   int32_t hx, hy;                                               \
+   uint32_t hx, hy;                                              \
    GET_TW0_HIGH_WORD(x, y, hx, hy);                              \
    if (hy > hx) {                                                \
      uint32_t ht = hx; hx = hy; hy = ht;                         \