summary refs log tree commit diff
path: root/sysdeps/powerpc/fpu
diff options
context:
space:
mode:
authorGeoff Keating <geoffk@cygnus.com>2000-06-12 07:13:22 +0000
committerGeoff Keating <geoffk@cygnus.com>2000-06-12 07:13:22 +0000
commitb62990918e160fba3af6443dfc07f475bf0c3fc0 (patch)
treeb1a9d68547661bba5a3d439998a30a1edb47a48c /sysdeps/powerpc/fpu
parent2b72ebac3fdf9991e797f788b8bf636b9fcb2c7b (diff)
downloadglibc-b62990918e160fba3af6443dfc07f475bf0c3fc0.tar.gz
glibc-b62990918e160fba3af6443dfc07f475bf0c3fc0.tar.xz
glibc-b62990918e160fba3af6443dfc07f475bf0c3fc0.zip
* sysdeps/powerpc/dl-machine.c: Include dl-machine.h after the other header files. Mention about 128-byte cache line sizes. (__elf_machine_fixup_plt): Make types match elf_machine_fixup_plt. * sysdeps/powerpc/dl-machine.h (elf_machine_fixup_plt): Update for current calling sequence. * sysdeps/powerpc/dl-start.S (_dl_start_user): Close comment.
* sysdeps/powerpc/fpu/s_rint.c: Handle rounding to -0 correctly.
* sysdeps/powerpc/fpu/s_rintf.c: Likewise.

* sysdeps/unix/sysv/linux/powerpc/syscalls.list: Add getrlimit
and setrlimit syscalls for backwards compatibility.
2000-04-11  Geoff Keating  <geoffk@cygnus.com>

	* sysdeps/powerpc/dl-machine.c: Include dl-machine.h after the
	other header files.  Mention about 128-byte cache line sizes.
	(__elf_machine_fixup_plt): Make types match elf_machine_fixup_plt.
	* sysdeps/powerpc/dl-machine.h (elf_machine_fixup_plt): Update
	for current calling sequence.
	* sysdeps/powerpc/dl-start.S (_dl_start_user): Close comment.

	* sysdeps/powerpc/fpu/s_rint.c: Handle rounding to -0 correctly.
	* sysdeps/powerpc/fpu/s_rintf.c: Likewise.

	* sysdeps/unix/sysv/linux/powerpc/syscalls.list: Add getrlimit
	and setrlimit syscalls for backwards compatibility.
Diffstat (limited to 'sysdeps/powerpc/fpu')
-rw-r--r--sysdeps/powerpc/fpu/s_rint.c6
-rw-r--r--sysdeps/powerpc/fpu/s_rintf.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/sysdeps/powerpc/fpu/s_rint.c b/sysdeps/powerpc/fpu/s_rint.c
index a475875a97..204381e402 100644
--- a/sysdeps/powerpc/fpu/s_rint.c
+++ b/sysdeps/powerpc/fpu/s_rint.c
@@ -1,5 +1,5 @@
 /* Round a 64-bit floating point value to the nearest integer.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 2000 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
@@ -33,8 +33,8 @@ __rint (double x)
 	}
       else if (x < 0.0)
 	{
-	  x -= TWO52;
-	  x += TWO52;
+	  x = TWO52 - x;
+	  x = -(x - TWO52);
 	}
     }
 
diff --git a/sysdeps/powerpc/fpu/s_rintf.c b/sysdeps/powerpc/fpu/s_rintf.c
index dde40bb3e5..12c6b55976 100644
--- a/sysdeps/powerpc/fpu/s_rintf.c
+++ b/sysdeps/powerpc/fpu/s_rintf.c
@@ -1,5 +1,5 @@
 /* Round a 32-bit floating point value to the nearest integer.
-   Copyright (C) 1997 Free Software Foundation, Inc.
+   Copyright (C) 1997, 2000 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
@@ -33,8 +33,8 @@ __rintf (float x)
 	}
       else if (x < 0.0)
 	{
-	  x -= TWO23;
-	  x += TWO23;
+	  x = TWO23 - x;
+	  x = -(x - TWO23);
 	}
     }