[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commits] r18620 - in /fsf/trunk/ports: ./ sysdeps/arm/bits/ sysdeps/hppa/ sysdeps/hppa/hppa1.1/ sysdeps/unix/sysv/linux/arm/ sysdeps/...
- To: commits@xxxxxxxxxx
- Subject: [Commits] r18620 - in /fsf/trunk/ports: ./ sysdeps/arm/bits/ sysdeps/hppa/ sysdeps/hppa/hppa1.1/ sysdeps/unix/sysv/linux/arm/ sysdeps/...
- From: eglibc@xxxxxxxxxx
- Date: Sun, 20 May 2012 00:01:54 -0000
Author: eglibc
Date: Sun May 20 00:01:54 2012
New Revision: 18620
Log:
Import glibc-ports-mainline for 2012-05-20
Added:
fsf/trunk/ports/sysdeps/hppa/add_n.S
fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.S
fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.S
fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.S
fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.S
fsf/trunk/ports/sysdeps/hppa/lshift.S
fsf/trunk/ports/sysdeps/hppa/rshift.S
fsf/trunk/ports/sysdeps/hppa/sub_n.S
fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.S
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/ftruncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/truncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/ftruncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/truncate64.c
Removed:
fsf/trunk/ports/sysdeps/arm/bits/huge_val.h
fsf/trunk/ports/sysdeps/arm/bits/string.h
fsf/trunk/ports/sysdeps/hppa/add_n.s
fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.s
fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.s
fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.s
fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.s
fsf/trunk/ports/sysdeps/hppa/libgcc_s.h
fsf/trunk/ports/sysdeps/hppa/lshift.s
fsf/trunk/ports/sysdeps/hppa/rshift.s
fsf/trunk/ports/sysdeps/hppa/sub_n.s
fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.s
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/ftruncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/truncate64.c
Modified:
fsf/trunk/ports/ChangeLog.arm
fsf/trunk/ports/ChangeLog.hppa
fsf/trunk/ports/ChangeLog.mips
fsf/trunk/ports/sysdeps/arm/bits/endian.h
fsf/trunk/ports/sysdeps/hppa/shlib-versions
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/ftruncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/mmap.S
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/posix_fadvise64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/readahead.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigaction.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigrestorer.S
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sysdep.h
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/truncate64.c
fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/vfork.S
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/syscalls.list
Modified: fsf/trunk/ports/ChangeLog.arm
==============================================================================
--- fsf/trunk/ports/ChangeLog.arm (original)
+++ fsf/trunk/ports/ChangeLog.arm Sun May 20 00:01:54 2012
@@ -1,3 +1,49 @@
+2012-05-19 Joseph Myers <joseph@xxxxxxxxxxxxxxxx>
+
+ * sysdeps/arm/bits/endian.h (__FLOAT_WORD_ORDER): Remove
+ definitions.
+ * sysdeps/arm/bits/huge_val.h: Remove file.
+ * sysdeps/arm/bits/string.h: Remove file.
+ * sysdeps/unix/sysv/linux/arm/readahead.c [__NR_readahead]: Make
+ code unconditional.
+ [!__NR_readahead]: Remove conditional code.
+ * sysdeps/unix/sysv/linux/arm/sigaction.c [__NR_rt_sigreturn]:
+ Make code unconditional.
+ [!__NR_rt_sigreturn]: Remove conditional code.
+ * sysdeps/unix/sysv/linux/arm/sigrestorer.S [__NR_rt_sigreturn]:
+ Make code unconditional.
+ * sysdeps/unix/sysv/linux/arm/sysdep.h [__NR_SYSCALL_BASE != 0]:
+ Remove conditional #error.
+ (__NR_stime): Remove #undef.
+ (__NR_alarm): Likewise.
+ (SWI_BASE): Remove.
+
+ * sysdeps/unix/sysv/linux/arm/ftruncate64.c (kernel-features.h):
+ Don't include.
+ [__NR_ftruncate64]: Make code unconditional.
+ [!__NR_ftruncate64]: Remove conditional code.
+ [!__ASSUME_TRUNCATE64_SYSCALL]: Likewise.
+ * sysdeps/unix/sysv/linux/arm/mmap.S (kernel-features.h): Don't
+ include.
+ [__ASSUME_MMAP2_SYSCALL]:
+ Make code unconditional.
+ [!__ASSUME_MMAP2_SYSCALL]: Remove conditional code.
+ * sysdeps/unix/sysv/linux/arm/posix_fadvise64.c
+ (kernel-features.h): Don't include.
+ [__NR_arm_fadvise64_64]: Make code unconditional.
+ [!__ASSUME_FADVISE64_64_SYSCALL]: Remove conditional code.
+ * sysdeps/unix/sysv/linux/arm/truncate64.c (kernel-features.h):
+ Don't include.
+ [__NR_truncate64]: Make code unconditional.
+ [!__NR_truncate64]: Remove conditional code.
+ [!__ASSUME_TRUNCATE64_SYSCALL]: Likewise.
+ * sysdeps/unix/sysv/linux/arm/vfork.S (kernel-features.h): Don't
+ include.
+ [__NR_vfork]: Make code unconditional.
+ [__ASSUME_VFORK_SYSCALL]: Likewise.
+ [!__ASSUME_VFORK_SYSCALL]: Remove conditional code.
+ [!__NR_vfork]: Likewise.
+
2012-05-16 Joseph Myers <joseph@xxxxxxxxxxxxxxxx>
* sysdeps/unix/sysv/linux/arm/kernel-features.h
Modified: fsf/trunk/ports/ChangeLog.hppa
==============================================================================
--- fsf/trunk/ports/ChangeLog.hppa (original)
+++ fsf/trunk/ports/ChangeLog.hppa Sun May 20 00:01:54 2012
@@ -1,3 +1,29 @@
+2012-05-19 Carlos O'Donell <carlos@xxxxxxxxxxxxxxxx>
+
+ * sysdeps/hppa/add_n.s: Rename this...
+ * sysdeps/hppa/add_n.S: ... to this.
+ * sysdeps/hppa/hppa1.1/addmul_1.s: Rename this...
+ * sysdeps/hppa/hppa1.1/addmul_1.S: ... to this.
+ * sysdeps/hppa/hppa1.1/mul_1.s: Rename this...
+ * sysdeps/hppa/hppa1.1/mul_1.S ... to this.
+ * sysdeps/hppa/hppa1.1/submul_1.s: Rename this...
+ * sysdeps/hppa/hppa1.1/submul_1.S: ... to this.
+ * sysdeps/hppa/hppa1.1/udiv_qrnnd.s: Rname this...
+ * sysdeps/hppa/hppa1.1/udiv_qrnnd.S: ... to this.
+ * sysdeps/hppa/lshift.s: Rename this...
+ * sysdeps/hppa/lshift.S: ... to this.
+ * sysdeps/hppa/rshift.s: Rename this...
+ * sysdeps/hppa/rshift.S: ... to this.
+ * sysdeps/hppa/sub_n.s: Rename this...
+ * sysdeps/hppa/sub_n.S: ... to this.
+ * sysdeps/hppa/udiv_qrnnd.s: Rename this...
+ * sysdeps/hppa/udiv_qrnnd.S: ... to this.
+
+2012-05-17 Siddhesh Poyarekar <siddhesh@xxxxxxxxxx>
+
+ * sysdeps/hppa/libgcc_s.h: Remove.
+ * sysdeps/hppa/shlib-versions: Add libgcc_s.
+
2012-04-17 Carlos O'Donell <carlos@xxxxxxxxxxxxxxxx>
* sysdeps/hppa/dl-irel.h: New file.
Modified: fsf/trunk/ports/ChangeLog.mips
==============================================================================
--- fsf/trunk/ports/ChangeLog.mips (original)
+++ fsf/trunk/ports/ChangeLog.mips Sun May 20 00:01:54 2012
@@ -1,3 +1,28 @@
+2012-05-19 Joseph Myers <joseph@xxxxxxxxxxxxxxxx>
+
+ * sysdeps/unix/sysv/linux/mips/ftruncate64.c: Move to ...
+ * sysdeps/unix/sysv/linux/mips/mips32/ftruncate64.c: ... here.
+ (kernel-features.h): Don't include.
+ [__NR_ftruncate64]: Make code unconditional.
+ [!__NR_ftruncate64]: Remove conditional code.
+ [!__ASSUME_TRUNCATE64_SYSCALL]: Likewise.
+ * sysdeps/unix/sysv/linux/mips/truncate64.c: Move to ...
+ * sysdeps/unix/sysv/linux/mips/mips32/truncate64.c: ... here.
+ (kernel-features.h): Don't include.
+ [__NR_truncate64]: Make code unconditional.
+ [!__NR_truncate64]: Remove conditional code.
+ [!__ASSUME_TRUNCATE64_SYSCALL]: Likewise.
+ * sysdeps/unix/sysv/linux/mips/mips64/syscalls.list (ftruncate):
+ Add syscall.
+ (truncate): Likewise.
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
+ (ftruncate): Remove syscall.
+ (truncate): Likewise.
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c: Move to ...
+ * sysdeps/unix/sysv/linux/mips/mips64/ftruncate64.c: ... here.
+ * sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c: Move to ...
+ * sysdeps/unix/sysv/linux/mips/mips64/truncate64.c: ... here.
+
2012-05-16 Joseph Myers <joseph@xxxxxxxxxxxxxxxx>
* sysdeps/unix/sysv/linux/mips/bits/stat.h (struct stat)
Modified: fsf/trunk/ports/sysdeps/arm/bits/endian.h
==============================================================================
--- fsf/trunk/ports/sysdeps/arm/bits/endian.h (original)
+++ fsf/trunk/ports/sysdeps/arm/bits/endian.h Sun May 20 00:01:54 2012
@@ -8,12 +8,3 @@
#else
#define __BYTE_ORDER __LITTLE_ENDIAN
#endif
-
-/* FPA floating point units are always big-endian, irrespective of the
- CPU endianness. VFP floating point units use the same endianness
- as the rest of the system. */
-#ifdef __VFP_FP__
-#define __FLOAT_WORD_ORDER __BYTE_ORDER
-#else
-#define __FLOAT_WORD_ORDER __BIG_ENDIAN
-#endif
Removed: fsf/trunk/ports/sysdeps/arm/bits/huge_val.h
==============================================================================
--- fsf/trunk/ports/sysdeps/arm/bits/huge_val.h (original)
+++ fsf/trunk/ports/sysdeps/arm/bits/huge_val.h (removed)
@@ -1,54 +1,0 @@
-/* `HUGE_VAL' constant for IEEE 754 machines (where it is infinity).
- Used by <stdlib.h> and <math.h> functions for overflow.
- Copyright (C) 1992, 1995, 1996, 1997, 1999, 2000, 2004
- 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#ifndef _MATH_H
-# error "Never use <bits/huge_val.h> directly; include <math.h> instead."
-#endif
-
-/* IEEE positive infinity (-HUGE_VAL is negative infinity). */
-
-#if __GNUC_PREREQ(3,3)
-# define HUGE_VAL (__builtin_huge_val())
-#elif __GNUC_PREREQ(2,96)
-# define HUGE_VAL (__extension__ 0x1.0p2047)
-#elif defined __GNUC__
-
-# define HUGE_VAL \
- (__extension__ \
- ((union { unsigned __l __attribute__((__mode__(__DI__))); double __d; }) \
- { __l: 0x7ff0000000000000ULL }).__d)
-
-#else /* not GCC */
-
-# include <endian.h>
-
-typedef union { unsigned char __c[8]; double __d; } __huge_val_t;
-
-# if __BYTE_ORDER == __BIG_ENDIAN
-# define __HUGE_VAL_bytes { 0x7f, 0xf0, 0, 0, 0, 0, 0, 0 }
-# endif
-# if __BYTE_ORDER == __LITTLE_ENDIAN
-# define __HUGE_VAL_bytes { 0, 0, 0, 0, 0, 0, 0xf0, 0x7f }
-# endif
-
-static __huge_val_t __huge_val = { __HUGE_VAL_bytes };
-# define HUGE_VAL (__huge_val.__d)
-
-#endif /* GCC. */
Removed: fsf/trunk/ports/sysdeps/arm/bits/string.h
==============================================================================
--- fsf/trunk/ports/sysdeps/arm/bits/string.h (original)
+++ fsf/trunk/ports/sysdeps/arm/bits/string.h (removed)
@@ -1,30 +1,0 @@
-/* Optimized, inlined string functions. ARM version.
- Copyright (C) 1998, 1999, 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#ifndef _STRING_H
-# error "Never use <bits/string.h> directly; include <string.h> instead."
-#endif
-
-/* We must defeat the generic optimized versions of these functions in
- <bits/string2.h> since they don't work on the ARM. This is because
- the games they play with the __STRING2_COPY_ARR# structures fail
- when structs are always 32-bit aligned.
- XXX Should provide suitably optimal replacements. */
-#define _HAVE_STRING_ARCH_strcpy 1
-#define _HAVE_STRING_ARCH_stpcpy 1
-#define _HAVE_STRING_ARCH_mempcpy 1
Added: fsf/trunk/ports/sysdeps/hppa/add_n.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/add_n.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/add_n.S Sun May 20 00:01:54 2012
@@ -1,0 +1,57 @@
+;! HP-PA __mpn_add_n -- Add two limb vectors of the same length > 0 and store
+;! sum in a third limb vector.
+
+;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr gr26
+;! s1_ptr gr25
+;! s2_ptr gr24
+;! size gr23
+
+;! One might want to unroll this as for other processors, but it turns
+;! out that the data cache contention after a store makes such
+;! unrolling useless. We can't come under 5 cycles/limb anyway.
+
+ .text
+ .export __mpn_add_n
+__mpn_add_n:
+ .proc
+ .callinfo frame=0,no_calls
+ .entry
+
+ ldws,ma 4(%r25),%r21
+ ldws,ma 4(%r24),%r20
+
+ addib,= -1,%r23,L$end ;! check for (SIZE == 1)
+ add %r21,%r20,%r28 ;! add first limbs ignoring cy
+
+L$loop: ldws,ma 4(%r25),%r21
+ ldws,ma 4(%r24),%r20
+ stws,ma %r28,4(%r26)
+ addib,<> -1,%r23,L$loop
+ addc %r21,%r20,%r28
+
+L$end: stws %r28,0(%r26)
+ bv 0(%r2)
+ addc %r0,%r0,%r28
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/add_n.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/add_n.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/add_n.s (removed)
@@ -1,57 +1,0 @@
-;! HP-PA __mpn_add_n -- Add two limb vectors of the same length > 0 and store
-;! sum in a third limb vector.
-
-;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr gr26
-;! s1_ptr gr25
-;! s2_ptr gr24
-;! size gr23
-
-;! One might want to unroll this as for other processors, but it turns
-;! out that the data cache contention after a store makes such
-;! unrolling useless. We can't come under 5 cycles/limb anyway.
-
- .text
- .export __mpn_add_n
-__mpn_add_n:
- .proc
- .callinfo frame=0,no_calls
- .entry
-
- ldws,ma 4(%r25),%r21
- ldws,ma 4(%r24),%r20
-
- addib,= -1,%r23,L$end ;! check for (SIZE == 1)
- add %r21,%r20,%r28 ;! add first limbs ignoring cy
-
-L$loop: ldws,ma 4(%r25),%r21
- ldws,ma 4(%r24),%r20
- stws,ma %r28,4(%r26)
- addib,<> -1,%r23,L$loop
- addc %r21,%r20,%r28
-
-L$end: stws %r28,0(%r26)
- bv 0(%r2)
- addc %r0,%r0,%r28
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.S Sun May 20 00:01:54 2012
@@ -1,0 +1,103 @@
+;! HP-PA-1.1 __mpn_addmul_1 -- Multiply a limb vector with a limb and
+;! add the result to a second limb vector.
+
+;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr r26
+;! s1_ptr r25
+;! size r24
+;! s2_limb r23
+
+;! This runs at 11 cycles/limb on a PA7000. With the used instructions, it
+;! can not become faster due to data cache contention after a store. On the
+;! PA7100 it runs at 10 cycles/limb, and that can not be improved either,
+;! since only the xmpyu does not need the integer pipeline, so the only
+;! dual-issue we will get are addc+xmpyu. Unrolling could gain a cycle/limb
+;! on the PA7100.
+
+;! There are some ideas described in mul_1.s that applies to this code too.
+
+ .text
+ .export __mpn_addmul_1
+__mpn_addmul_1:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+
+ ldo 64(%r30),%r30
+ fldws,ma 4(%r25),%fr5
+ stw %r23,-16(%r30) ;! move s2_limb ...
+ addib,= -1,%r24,L$just_one_limb
+ fldws -16(%r30),%fr4 ;! ... into fr4
+ add %r0,%r0,%r0 ;! clear carry
+ xmpyu %fr4,%fr5,%fr6
+ fldws,ma 4(%r25),%fr7
+ fstds %fr6,-16(%r30)
+ xmpyu %fr4,%fr7,%fr8
+ ldw -12(%r30),%r20 ;! least significant limb in product
+ ldw -16(%r30),%r28
+
+ fstds %fr8,-16(%r30)
+ addib,= -1,%r24,L$end
+ ldw -12(%r30),%r1
+
+;! Main loop
+L$loop:
+ ldws 0(%r26),%r29
+ fldws,ma 4(%r25),%fr5
+ add %r29,%r20,%r20
+ stws,ma %r20,4(%r26)
+ addc %r28,%r1,%r20
+ xmpyu %fr4,%fr5,%fr6
+ ldw -16(%r30),%r28
+ fstds %fr6,-16(%r30)
+ addc %r0,%r28,%r28
+ addib,<> -1,%r24,L$loop
+ ldw -12(%r30),%r1
+
+L$end:
+ ldw 0(%r26),%r29
+ add %r29,%r20,%r20
+ stws,ma %r20,4(%r26)
+ addc %r28,%r1,%r20
+ ldw -16(%r30),%r28
+ ldws 0(%r26),%r29
+ addc %r0,%r28,%r28
+ add %r29,%r20,%r20
+ stws,ma %r20,4(%r26)
+ addc %r0,%r28,%r28
+ bv 0(%r2)
+ ldo -64(%r30),%r30
+
+L$just_one_limb:
+ xmpyu %fr4,%fr5,%fr6
+ ldw 0(%r26),%r29
+ fstds %fr6,-16(%r30)
+ ldw -12(%r30),%r1
+ ldw -16(%r30),%r28
+ add %r29,%r1,%r20
+ stw %r20,0(%r26)
+ addc %r0,%r28,%r28
+ bv 0(%r2)
+ ldo -64(%r30),%r30
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/addmul_1.s (removed)
@@ -1,103 +1,0 @@
-;! HP-PA-1.1 __mpn_addmul_1 -- Multiply a limb vector with a limb and
-;! add the result to a second limb vector.
-
-;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr r26
-;! s1_ptr r25
-;! size r24
-;! s2_limb r23
-
-;! This runs at 11 cycles/limb on a PA7000. With the used instructions, it
-;! can not become faster due to data cache contention after a store. On the
-;! PA7100 it runs at 10 cycles/limb, and that can not be improved either,
-;! since only the xmpyu does not need the integer pipeline, so the only
-;! dual-issue we will get are addc+xmpyu. Unrolling could gain a cycle/limb
-;! on the PA7100.
-
-;! There are some ideas described in mul_1.s that applies to this code too.
-
- .text
- .export __mpn_addmul_1
-__mpn_addmul_1:
- .proc
- .callinfo frame=64,no_calls
- .entry
-
- ldo 64(%r30),%r30
- fldws,ma 4(%r25),%fr5
- stw %r23,-16(%r30) ;! move s2_limb ...
- addib,= -1,%r24,L$just_one_limb
- fldws -16(%r30),%fr4 ;! ... into fr4
- add %r0,%r0,%r0 ;! clear carry
- xmpyu %fr4,%fr5,%fr6
- fldws,ma 4(%r25),%fr7
- fstds %fr6,-16(%r30)
- xmpyu %fr4,%fr7,%fr8
- ldw -12(%r30),%r20 ;! least significant limb in product
- ldw -16(%r30),%r28
-
- fstds %fr8,-16(%r30)
- addib,= -1,%r24,L$end
- ldw -12(%r30),%r1
-
-;! Main loop
-L$loop:
- ldws 0(%r26),%r29
- fldws,ma 4(%r25),%fr5
- add %r29,%r20,%r20
- stws,ma %r20,4(%r26)
- addc %r28,%r1,%r20
- xmpyu %fr4,%fr5,%fr6
- ldw -16(%r30),%r28
- fstds %fr6,-16(%r30)
- addc %r0,%r28,%r28
- addib,<> -1,%r24,L$loop
- ldw -12(%r30),%r1
-
-L$end:
- ldw 0(%r26),%r29
- add %r29,%r20,%r20
- stws,ma %r20,4(%r26)
- addc %r28,%r1,%r20
- ldw -16(%r30),%r28
- ldws 0(%r26),%r29
- addc %r0,%r28,%r28
- add %r29,%r20,%r20
- stws,ma %r20,4(%r26)
- addc %r0,%r28,%r28
- bv 0(%r2)
- ldo -64(%r30),%r30
-
-L$just_one_limb:
- xmpyu %fr4,%fr5,%fr6
- ldw 0(%r26),%r29
- fstds %fr6,-16(%r30)
- ldw -12(%r30),%r1
- ldw -16(%r30),%r28
- add %r29,%r1,%r20
- stw %r20,0(%r26)
- addc %r0,%r28,%r28
- bv 0(%r2)
- ldo -64(%r30),%r30
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.S Sun May 20 00:01:54 2012
@@ -1,0 +1,99 @@
+;! HP-PA-1.1 __mpn_mul_1 -- Multiply a limb vector with a limb and store
+;! the result in a second limb vector.
+
+;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr r26
+;! s1_ptr r25
+;! size r24
+;! s2_limb r23
+
+;! This runs at 9 cycles/limb on a PA7000. With the used instructions, it can
+;! not become faster due to data cache contention after a store. On the
+;! PA7100 it runs at 7 cycles/limb, and that can not be improved either, since
+;! only the xmpyu does not need the integer pipeline, so the only dual-issue
+;! we will get are addc+xmpyu. Unrolling would not help either CPU.
+
+;! We could use fldds to read two limbs at a time from the S1 array, and that
+;! could bring down the times to 8.5 and 6.5 cycles/limb for the PA7000 and
+;! PA7100, respectively. We don't do that since it does not seem worth the
+;! (alignment) troubles...
+
+;! At least the PA7100 is rumored to be able to deal with cache-misses
+;! without stalling instruction issue. If this is true, and the cache is
+;! actually also lockup-free, we should use a deeper software pipeline, and
+;! load from S1 very early; (The loads and stores to -12(sp) will surely be
+;! in the cache.)
+
+ .text
+ .export __mpn_mul_1
+__mpn_mul_1:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+
+ ldo 64(%r30),%r30
+ fldws,ma 4(%r25),%fr5
+ stw %r23,-16(%r30) ;! move s2_limb ...
+ addib,= -1,%r24,L$just_one_limb
+ fldws -16(%r30),%fr4 ;! ... into fr4
+ add %r0,%r0,%r0 ;! clear carry
+ xmpyu %fr4,%fr5,%fr6
+ fldws,ma 4(%r25),%fr7
+ fstds %fr6,-16(%r30)
+ xmpyu %fr4,%fr7,%fr8
+ ldw -12(%r30),%r20 ;! least significant limb in product
+ ldw -16(%r30),%r28
+
+ fstds %fr8,-16(%r30)
+ addib,= -1,%r24,L$end
+ ldw -12(%r30),%r1
+
+;! Main loop
+L$loop:
+ fldws,ma 4(%r25),%fr5
+ stws,ma %r20,4(%r26)
+ addc %r28,%r1,%r20
+ xmpyu %fr4,%fr5,%fr6
+ ldw -16(%r30),%r28
+ fstds %fr6,-16(%r30)
+ addib,<> -1,%r24,L$loop
+ ldw -12(%r30),%r1
+
+L$end:
+ stws,ma %r20,4(%r26)
+ addc %r28,%r1,%r20
+ ldw -16(%r30),%r28
+ stws,ma %r20,4(%r26)
+ addc %r0,%r28,%r28
+ bv 0(%r2)
+ ldo -64(%r30),%r30
+
+L$just_one_limb:
+ xmpyu %fr4,%fr5,%fr6
+ fstds %fr6,-16(%r30)
+ ldw -16(%r30),%r28
+ ldo -64(%r30),%r30
+ bv 0(%r2)
+ fstws %fr6R,0(%r26)
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/mul_1.s (removed)
@@ -1,99 +1,0 @@
-;! HP-PA-1.1 __mpn_mul_1 -- Multiply a limb vector with a limb and store
-;! the result in a second limb vector.
-
-;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr r26
-;! s1_ptr r25
-;! size r24
-;! s2_limb r23
-
-;! This runs at 9 cycles/limb on a PA7000. With the used instructions, it can
-;! not become faster due to data cache contention after a store. On the
-;! PA7100 it runs at 7 cycles/limb, and that can not be improved either, since
-;! only the xmpyu does not need the integer pipeline, so the only dual-issue
-;! we will get are addc+xmpyu. Unrolling would not help either CPU.
-
-;! We could use fldds to read two limbs at a time from the S1 array, and that
-;! could bring down the times to 8.5 and 6.5 cycles/limb for the PA7000 and
-;! PA7100, respectively. We don't do that since it does not seem worth the
-;! (alignment) troubles...
-
-;! At least the PA7100 is rumored to be able to deal with cache-misses
-;! without stalling instruction issue. If this is true, and the cache is
-;! actually also lockup-free, we should use a deeper software pipeline, and
-;! load from S1 very early; (The loads and stores to -12(sp) will surely be
-;! in the cache.)
-
- .text
- .export __mpn_mul_1
-__mpn_mul_1:
- .proc
- .callinfo frame=64,no_calls
- .entry
-
- ldo 64(%r30),%r30
- fldws,ma 4(%r25),%fr5
- stw %r23,-16(%r30) ;! move s2_limb ...
- addib,= -1,%r24,L$just_one_limb
- fldws -16(%r30),%fr4 ;! ... into fr4
- add %r0,%r0,%r0 ;! clear carry
- xmpyu %fr4,%fr5,%fr6
- fldws,ma 4(%r25),%fr7
- fstds %fr6,-16(%r30)
- xmpyu %fr4,%fr7,%fr8
- ldw -12(%r30),%r20 ;! least significant limb in product
- ldw -16(%r30),%r28
-
- fstds %fr8,-16(%r30)
- addib,= -1,%r24,L$end
- ldw -12(%r30),%r1
-
-;! Main loop
-L$loop:
- fldws,ma 4(%r25),%fr5
- stws,ma %r20,4(%r26)
- addc %r28,%r1,%r20
- xmpyu %fr4,%fr5,%fr6
- ldw -16(%r30),%r28
- fstds %fr6,-16(%r30)
- addib,<> -1,%r24,L$loop
- ldw -12(%r30),%r1
-
-L$end:
- stws,ma %r20,4(%r26)
- addc %r28,%r1,%r20
- ldw -16(%r30),%r28
- stws,ma %r20,4(%r26)
- addc %r0,%r28,%r28
- bv 0(%r2)
- ldo -64(%r30),%r30
-
-L$just_one_limb:
- xmpyu %fr4,%fr5,%fr6
- fstds %fr6,-16(%r30)
- ldw -16(%r30),%r28
- ldo -64(%r30),%r30
- bv 0(%r2)
- fstws %fr6R,0(%r26)
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.S Sun May 20 00:01:54 2012
@@ -1,0 +1,112 @@
+;! HP-PA-1.1 __mpn_submul_1 -- Multiply a limb vector with a limb and
+;! subtract the result from a second limb vector.
+
+;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr r26
+;! s1_ptr r25
+;! size r24
+;! s2_limb r23
+
+;! This runs at 12 cycles/limb on a PA7000. With the used instructions, it
+;! can not become faster due to data cache contention after a store. On the
+;! PA7100 it runs at 11 cycles/limb, and that can not be improved either,
+;! since only the xmpyu does not need the integer pipeline, so the only
+;! dual-issue we will get are addc+xmpyu. Unrolling could gain a cycle/limb
+;! on the PA7100.
+
+;! There are some ideas described in mul_1.s that applies to this code too.
+
+;! It seems possible to make this run as fast as __mpn_addmul_1, if we use
+;! sub,>>= %r29,%r20,%r22
+;! addi 1,%r28,%r28
+;! but that requires reworking the hairy software pipeline...
+
+ .text
+ .export __mpn_submul_1
+__mpn_submul_1:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+
+ ldo 64(%r30),%r30
+ fldws,ma 4(%r25),%fr5
+ stw %r23,-16(%r30) ;! move s2_limb ...
+ addib,= -1,%r24,L$just_one_limb
+ fldws -16(%r30),%fr4 ;! ... into fr4
+ add %r0,%r0,%r0 ;! clear carry
+ xmpyu %fr4,%fr5,%fr6
+ fldws,ma 4(%r25),%fr7
+ fstds %fr6,-16(%r30)
+ xmpyu %fr4,%fr7,%fr8
+ ldw -12(%r30),%r20 ;! least significant limb in product
+ ldw -16(%r30),%r28
+
+ fstds %fr8,-16(%r30)
+ addib,= -1,%r24,L$end
+ ldw -12(%r30),%r1
+
+;! Main loop
+L$loop:
+ ldws 0(%r26),%r29
+ fldws,ma 4(%r25),%fr5
+ sub %r29,%r20,%r22
+ add %r22,%r20,%r0
+ stws,ma %r22,4(%r26)
+ addc %r28,%r1,%r20
+ xmpyu %fr4,%fr5,%fr6
+ ldw -16(%r30),%r28
+ fstds %fr6,-16(%r30)
+ addc %r0,%r28,%r28
+ addib,<> -1,%r24,L$loop
+ ldw -12(%r30),%r1
+
+L$end:
+ ldw 0(%r26),%r29
+ sub %r29,%r20,%r22
+ add %r22,%r20,%r0
+ stws,ma %r22,4(%r26)
+ addc %r28,%r1,%r20
+ ldw -16(%r30),%r28
+ ldws 0(%r26),%r29
+ addc %r0,%r28,%r28
+ sub %r29,%r20,%r22
+ add %r22,%r20,%r0
+ stws,ma %r22,4(%r26)
+ addc %r0,%r28,%r28
+ bv 0(%r2)
+ ldo -64(%r30),%r30
+
+L$just_one_limb:
+ xmpyu %fr4,%fr5,%fr6
+ ldw 0(%r26),%r29
+ fstds %fr6,-16(%r30)
+ ldw -12(%r30),%r1
+ ldw -16(%r30),%r28
+ sub %r29,%r1,%r22
+ add %r22,%r1,%r0
+ stw %r22,0(%r26)
+ addc %r0,%r28,%r28
+ bv 0(%r2)
+ ldo -64(%r30),%r30
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/submul_1.s (removed)
@@ -1,112 +1,0 @@
-;! HP-PA-1.1 __mpn_submul_1 -- Multiply a limb vector with a limb and
-;! subtract the result from a second limb vector.
-
-;! Copyright (C) 1992, 1993, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr r26
-;! s1_ptr r25
-;! size r24
-;! s2_limb r23
-
-;! This runs at 12 cycles/limb on a PA7000. With the used instructions, it
-;! can not become faster due to data cache contention after a store. On the
-;! PA7100 it runs at 11 cycles/limb, and that can not be improved either,
-;! since only the xmpyu does not need the integer pipeline, so the only
-;! dual-issue we will get are addc+xmpyu. Unrolling could gain a cycle/limb
-;! on the PA7100.
-
-;! There are some ideas described in mul_1.s that applies to this code too.
-
-;! It seems possible to make this run as fast as __mpn_addmul_1, if we use
-;! sub,>>= %r29,%r20,%r22
-;! addi 1,%r28,%r28
-;! but that requires reworking the hairy software pipeline...
-
- .text
- .export __mpn_submul_1
-__mpn_submul_1:
- .proc
- .callinfo frame=64,no_calls
- .entry
-
- ldo 64(%r30),%r30
- fldws,ma 4(%r25),%fr5
- stw %r23,-16(%r30) ;! move s2_limb ...
- addib,= -1,%r24,L$just_one_limb
- fldws -16(%r30),%fr4 ;! ... into fr4
- add %r0,%r0,%r0 ;! clear carry
- xmpyu %fr4,%fr5,%fr6
- fldws,ma 4(%r25),%fr7
- fstds %fr6,-16(%r30)
- xmpyu %fr4,%fr7,%fr8
- ldw -12(%r30),%r20 ;! least significant limb in product
- ldw -16(%r30),%r28
-
- fstds %fr8,-16(%r30)
- addib,= -1,%r24,L$end
- ldw -12(%r30),%r1
-
-;! Main loop
-L$loop:
- ldws 0(%r26),%r29
- fldws,ma 4(%r25),%fr5
- sub %r29,%r20,%r22
- add %r22,%r20,%r0
- stws,ma %r22,4(%r26)
- addc %r28,%r1,%r20
- xmpyu %fr4,%fr5,%fr6
- ldw -16(%r30),%r28
- fstds %fr6,-16(%r30)
- addc %r0,%r28,%r28
- addib,<> -1,%r24,L$loop
- ldw -12(%r30),%r1
-
-L$end:
- ldw 0(%r26),%r29
- sub %r29,%r20,%r22
- add %r22,%r20,%r0
- stws,ma %r22,4(%r26)
- addc %r28,%r1,%r20
- ldw -16(%r30),%r28
- ldws 0(%r26),%r29
- addc %r0,%r28,%r28
- sub %r29,%r20,%r22
- add %r22,%r20,%r0
- stws,ma %r22,4(%r26)
- addc %r0,%r28,%r28
- bv 0(%r2)
- ldo -64(%r30),%r30
-
-L$just_one_limb:
- xmpyu %fr4,%fr5,%fr6
- ldw 0(%r26),%r29
- fstds %fr6,-16(%r30)
- ldw -12(%r30),%r1
- ldw -16(%r30),%r28
- sub %r29,%r1,%r22
- add %r22,%r1,%r0
- stw %r22,0(%r26)
- addc %r0,%r28,%r28
- bv 0(%r2)
- ldo -64(%r30),%r30
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.S Sun May 20 00:01:54 2012
@@ -1,0 +1,77 @@
+;! HP-PA __udiv_qrnnd division support, used from longlong.h.
+;! This version runs fast on PA 7000 and later.
+
+;! Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! rem_ptr gr26
+;! n1 gr25
+;! n0 gr24
+;! d gr23
+
+ .text
+L$0000:
+ .word 0x43f00000
+ .word 0x0
+ .export __udiv_qrnnd
+__udiv_qrnnd:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+ ldo 64(%r30),%r30
+
+ stws %r25,-16(%r30) ;! n_hi
+ stws %r24,-12(%r30) ;! n_lo
+ b,l L$0,%r1
+ ldo L$0000-L$0(%r1),%r1
+L$0:
+ fldds -16(%r30),%fr5
+ stws %r23,-12(%r30)
+ comib,<= 0,%r25,L$1
+ fcnvxf,dbl,dbl %fr5,%fr5
+ fldds 0(%r1),%fr4
+ fadd,dbl %fr4,%fr5,%fr5
+L$1:
+ fcpy,sgl %fr0,%fr6L
+ fldws -12(%r30),%fr6R
+ fcnvxf,dbl,dbl %fr6,%fr4
+
+ fdiv,dbl %fr5,%fr4,%fr5
+
+ fcnvfx,dbl,dbl %fr5,%fr4
+ fstws %fr4R,-16(%r30)
+ xmpyu %fr4R,%fr6R,%fr6
+ ldws -16(%r30),%r28
+ fstds %fr6,-16(%r30)
+ ldws -12(%r30),%r21
+ ldws -16(%r30),%r20
+ sub %r24,%r21,%r22
+ subb %r25,%r20,%r1
+ comib,= 0,%r1,L$2
+ ldo -64(%r30),%r30
+
+ add %r22,%r23,%r22
+ ldo -1(%r28),%r28
+L$2:
+ bv 0(%r2)
+ stws %r22,0(%r26)
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/hppa1.1/udiv_qrnnd.s (removed)
@@ -1,77 +1,0 @@
-;! HP-PA __udiv_qrnnd division support, used from longlong.h.
-;! This version runs fast on PA 7000 and later.
-
-;! Copyright (C) 1993, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! rem_ptr gr26
-;! n1 gr25
-;! n0 gr24
-;! d gr23
-
- .text
-L$0000:
- .word 0x43f00000
- .word 0x0
- .export __udiv_qrnnd
-__udiv_qrnnd:
- .proc
- .callinfo frame=64,no_calls
- .entry
- ldo 64(%r30),%r30
-
- stws %r25,-16(%r30) ;! n_hi
- stws %r24,-12(%r30) ;! n_lo
- b,l L$0,%r1
- ldo L$0000-L$0(%r1),%r1
-L$0:
- fldds -16(%r30),%fr5
- stws %r23,-12(%r30)
- comib,<= 0,%r25,L$1
- fcnvxf,dbl,dbl %fr5,%fr5
- fldds 0(%r1),%fr4
- fadd,dbl %fr4,%fr5,%fr5
-L$1:
- fcpy,sgl %fr0,%fr6L
- fldws -12(%r30),%fr6R
- fcnvxf,dbl,dbl %fr6,%fr4
-
- fdiv,dbl %fr5,%fr4,%fr5
-
- fcnvfx,dbl,dbl %fr5,%fr4
- fstws %fr4R,-16(%r30)
- xmpyu %fr4R,%fr6R,%fr6
- ldws -16(%r30),%r28
- fstds %fr6,-16(%r30)
- ldws -12(%r30),%r21
- ldws -16(%r30),%r20
- sub %r24,%r21,%r22
- subb %r25,%r20,%r1
- comib,= 0,%r1,L$2
- ldo -64(%r30),%r30
-
- add %r22,%r23,%r22
- ldo -1(%r28),%r28
-L$2:
- bv 0(%r2)
- stws %r22,0(%r26)
-
- .exit
- .procend
Removed: fsf/trunk/ports/sysdeps/hppa/libgcc_s.h
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/libgcc_s.h (original)
+++ fsf/trunk/ports/sysdeps/hppa/libgcc_s.h (removed)
@@ -1,2 +1,0 @@
-/* Name of libgcc_s library provided by gcc. */
-#define LIBGCC_S_SO "libgcc_s.so.4"
Added: fsf/trunk/ports/sysdeps/hppa/lshift.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/lshift.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/lshift.S Sun May 20 00:01:54 2012
@@ -1,0 +1,65 @@
+;! HP-PA __mpn_lshift --
+
+;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr gr26
+;! s_ptr gr25
+;! size gr24
+;! cnt gr23
+
+ .text
+ .export __mpn_lshift
+__mpn_lshift:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+
+ sh2add %r24,%r25,%r25
+ sh2add %r24,%r26,%r26
+ ldws,mb -4(%r25),%r22
+ subi 32,%r23,%r1
+ mtsar %r1
+ addib,= -1,%r24,L$0004
+ vshd %r0,%r22,%r28 ;! compute carry out limb
+ ldws,mb -4(%r25),%r29
+ addib,= -1,%r24,L$0002
+ vshd %r22,%r29,%r20
+
+L$loop: ldws,mb -4(%r25),%r22
+ stws,mb %r20,-4(%r26)
+ addib,= -1,%r24,L$0003
+ vshd %r29,%r22,%r20
+ ldws,mb -4(%r25),%r29
+ stws,mb %r20,-4(%r26)
+ addib,<> -1,%r24,L$loop
+ vshd %r22,%r29,%r20
+
+L$0002: stws,mb %r20,-4(%r26)
+ vshd %r29,%r0,%r20
+ bv 0(%r2)
+ stw %r20,-4(%r26)
+L$0003: stws,mb %r20,-4(%r26)
+L$0004: vshd %r22,%r0,%r20
+ bv 0(%r2)
+ stw %r20,-4(%r26)
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/lshift.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/lshift.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/lshift.s (removed)
@@ -1,65 +1,0 @@
-;! HP-PA __mpn_lshift --
-
-;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr gr26
-;! s_ptr gr25
-;! size gr24
-;! cnt gr23
-
- .text
- .export __mpn_lshift
-__mpn_lshift:
- .proc
- .callinfo frame=64,no_calls
- .entry
-
- sh2add %r24,%r25,%r25
- sh2add %r24,%r26,%r26
- ldws,mb -4(%r25),%r22
- subi 32,%r23,%r1
- mtsar %r1
- addib,= -1,%r24,L$0004
- vshd %r0,%r22,%r28 ;! compute carry out limb
- ldws,mb -4(%r25),%r29
- addib,= -1,%r24,L$0002
- vshd %r22,%r29,%r20
-
-L$loop: ldws,mb -4(%r25),%r22
- stws,mb %r20,-4(%r26)
- addib,= -1,%r24,L$0003
- vshd %r29,%r22,%r20
- ldws,mb -4(%r25),%r29
- stws,mb %r20,-4(%r26)
- addib,<> -1,%r24,L$loop
- vshd %r22,%r29,%r20
-
-L$0002: stws,mb %r20,-4(%r26)
- vshd %r29,%r0,%r20
- bv 0(%r2)
- stw %r20,-4(%r26)
-L$0003: stws,mb %r20,-4(%r26)
-L$0004: vshd %r22,%r0,%r20
- bv 0(%r2)
- stw %r20,-4(%r26)
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/rshift.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/rshift.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/rshift.S Sun May 20 00:01:54 2012
@@ -1,0 +1,62 @@
+;! HP-PA __mpn_rshift --
+
+;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr gr26
+;! s_ptr gr25
+;! size gr24
+;! cnt gr23
+
+ .text
+ .export __mpn_rshift
+__mpn_rshift:
+ .proc
+ .callinfo frame=64,no_calls
+ .entry
+
+ ldws,ma 4(%r25),%r22
+ mtsar %r23
+ addib,= -1,%r24,L$0004
+ vshd %r22,%r0,%r28 ;! compute carry out limb
+ ldws,ma 4(%r25),%r29
+ addib,= -1,%r24,L$0002
+ vshd %r29,%r22,%r20
+
+L$loop: ldws,ma 4(%r25),%r22
+ stws,ma %r20,4(%r26)
+ addib,= -1,%r24,L$0003
+ vshd %r22,%r29,%r20
+ ldws,ma 4(%r25),%r29
+ stws,ma %r20,4(%r26)
+ addib,<> -1,%r24,L$loop
+ vshd %r29,%r22,%r20
+
+L$0002: stws,ma %r20,4(%r26)
+ vshd %r0,%r29,%r20
+ bv 0(%r2)
+ stw %r20,0(%r26)
+L$0003: stws,ma %r20,4(%r26)
+L$0004: vshd %r0,%r22,%r20
+ bv 0(%r2)
+ stw %r20,0(%r26)
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/rshift.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/rshift.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/rshift.s (removed)
@@ -1,62 +1,0 @@
-;! HP-PA __mpn_rshift --
-
-;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr gr26
-;! s_ptr gr25
-;! size gr24
-;! cnt gr23
-
- .text
- .export __mpn_rshift
-__mpn_rshift:
- .proc
- .callinfo frame=64,no_calls
- .entry
-
- ldws,ma 4(%r25),%r22
- mtsar %r23
- addib,= -1,%r24,L$0004
- vshd %r22,%r0,%r28 ;! compute carry out limb
- ldws,ma 4(%r25),%r29
- addib,= -1,%r24,L$0002
- vshd %r29,%r22,%r20
-
-L$loop: ldws,ma 4(%r25),%r22
- stws,ma %r20,4(%r26)
- addib,= -1,%r24,L$0003
- vshd %r22,%r29,%r20
- ldws,ma 4(%r25),%r29
- stws,ma %r20,4(%r26)
- addib,<> -1,%r24,L$loop
- vshd %r29,%r22,%r20
-
-L$0002: stws,ma %r20,4(%r26)
- vshd %r0,%r29,%r20
- bv 0(%r2)
- stw %r20,0(%r26)
-L$0003: stws,ma %r20,4(%r26)
-L$0004: vshd %r0,%r22,%r20
- bv 0(%r2)
- stw %r20,0(%r26)
-
- .exit
- .procend
Modified: fsf/trunk/ports/sysdeps/hppa/shlib-versions
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/shlib-versions (original)
+++ fsf/trunk/ports/sysdeps/hppa/shlib-versions Sun May 20 00:01:54 2012
@@ -5,3 +5,5 @@
hppa.*-.*-.* ld=ld.so.1 GLIBC_2.2
hppa-.*-.* libBrokenLocale=1 GLIBC_2.2
+
+hppa.*-.*-.* libgcc_s=4
Added: fsf/trunk/ports/sysdeps/hppa/sub_n.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/sub_n.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/sub_n.S Sun May 20 00:01:54 2012
@@ -1,0 +1,58 @@
+;! HP-PA __mpn_sub_n -- Subtract two limb vectors of the same length > 0 and
+;! store difference in a third limb vector.
+
+;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! res_ptr gr26
+;! s1_ptr gr25
+;! s2_ptr gr24
+;! size gr23
+
+;! One might want to unroll this as for other processors, but it turns
+;! out that the data cache contention after a store makes such
+;! unrolling useless. We can't come under 5 cycles/limb anyway.
+
+ .text
+ .export __mpn_sub_n
+__mpn_sub_n:
+ .proc
+ .callinfo frame=0,no_calls
+ .entry
+
+ ldws,ma 4(%r25),%r21
+ ldws,ma 4(%r24),%r20
+
+ addib,= -1,%r23,L$end ;! check for (SIZE == 1)
+ sub %r21,%r20,%r28 ;! subtract first limbs ignoring cy
+
+L$loop: ldws,ma 4(%r25),%r21
+ ldws,ma 4(%r24),%r20
+ stws,ma %r28,4(%r26)
+ addib,<> -1,%r23,L$loop
+ subb %r21,%r20,%r28
+
+L$end: stws %r28,0(%r26)
+ addc %r0,%r0,%r28
+ bv 0(%r2)
+ subi 1,%r28,%r28
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/sub_n.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/sub_n.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/sub_n.s (removed)
@@ -1,58 +1,0 @@
-;! HP-PA __mpn_sub_n -- Subtract two limb vectors of the same length > 0 and
-;! store difference in a third limb vector.
-
-;! Copyright (C) 1992, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! res_ptr gr26
-;! s1_ptr gr25
-;! s2_ptr gr24
-;! size gr23
-
-;! One might want to unroll this as for other processors, but it turns
-;! out that the data cache contention after a store makes such
-;! unrolling useless. We can't come under 5 cycles/limb anyway.
-
- .text
- .export __mpn_sub_n
-__mpn_sub_n:
- .proc
- .callinfo frame=0,no_calls
- .entry
-
- ldws,ma 4(%r25),%r21
- ldws,ma 4(%r24),%r20
-
- addib,= -1,%r23,L$end ;! check for (SIZE == 1)
- sub %r21,%r20,%r28 ;! subtract first limbs ignoring cy
-
-L$loop: ldws,ma 4(%r25),%r21
- ldws,ma 4(%r24),%r20
- stws,ma %r28,4(%r26)
- addib,<> -1,%r23,L$loop
- subb %r21,%r20,%r28
-
-L$end: stws %r28,0(%r26)
- addc %r0,%r0,%r28
- bv 0(%r2)
- subi 1,%r28,%r28
-
- .exit
- .procend
Added: fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.S
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.S (added)
+++ fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.S Sun May 20 00:01:54 2012
@@ -1,0 +1,285 @@
+;! HP-PA __udiv_qrnnd division support, used from longlong.h.
+;! This version runs fast on pre-PA7000 CPUs.
+
+;! Copyright (C) 1993, 1994 Free Software Foundation, Inc.
+
+;! This file is part of the GNU MP Library.
+
+;! The GNU MP Library is free software; you can redistribute it and/or modify
+;! it under the terms of the GNU Lesser General Public License as published by
+;! the Free Software Foundation; either version 2.1 of the License, or (at your
+;! option) any later version.
+
+;! The GNU MP Library is distributed in the hope that it will be useful, but
+;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+;! License for more details.
+
+;! You should have received a copy of the GNU Lesser General Public License
+;! along with the GNU MP Library. If not, see
+;! <http://www.gnu.org/licenses/>.
+
+
+;! INPUT PARAMETERS
+;! rem_ptr gr26
+;! n1 gr25
+;! n0 gr24
+;! d gr23
+
+;! The code size is a bit excessive. We could merge the last two ds;addc
+;! sequences by simply moving the "bb,< Odd" instruction down. The only
+;! trouble is the FFFFFFFF code that would need some hacking.
+
+ .text
+ .export __udiv_qrnnd
+__udiv_qrnnd:
+ .proc
+ .callinfo frame=0,no_calls
+ .entry
+
+ comb,< %r23,%r0,L$largedivisor
+ sub %r0,%r23,%r1 ;! clear cy as side-effect
+ ds %r0,%r1,%r0
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r23,%r25
+ addc %r24,%r24,%r28
+ ds %r25,%r23,%r25
+ comclr,>= %r25,%r0,%r0
+ addl %r25,%r23,%r25
+ stws %r25,0(%r26)
+ bv 0(%r2)
+ addc %r28,%r28,%r28
+
+L$largedivisor:
+ extru %r24,31,1,%r20 ;! r20 = n0 & 1
+ bb,< %r23,31,L$odd
+ extru %r23,30,31,%r22 ;! r22 = d >> 1
+ shd %r25,%r24,1,%r24 ;! r24 = new n0
+ extru %r25,30,31,%r25 ;! r25 = new n1
+ sub %r0,%r22,%r21
+ ds %r0,%r21,%r0
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ comclr,>= %r25,%r0,%r0
+ addl %r25,%r22,%r25
+ sh1addl %r25,%r20,%r25
+ stws %r25,0(%r26)
+ bv 0(%r2)
+ addc %r24,%r24,%r28
+
+L$odd: addib,sv,n 1,%r22,L$FF.. ;! r22 = (d / 2 + 1)
+ shd %r25,%r24,1,%r24 ;! r24 = new n0
+ extru %r25,30,31,%r25 ;! r25 = new n1
+ sub %r0,%r22,%r21
+ ds %r0,%r21,%r0
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r24
+ ds %r25,%r22,%r25
+ addc %r24,%r24,%r28
+ comclr,>= %r25,%r0,%r0
+ addl %r25,%r22,%r25
+ sh1addl %r25,%r20,%r25
+;! We have computed (n1,,n0) / (d + 1), q' = r28, r' = r25
+ add,nuv %r28,%r25,%r25
+ addl %r25,%r1,%r25
+ addc %r0,%r28,%r28
+ sub,<< %r25,%r23,%r0
+ addl %r25,%r1,%r25
+ stws %r25,0(%r26)
+ bv 0(%r2)
+ addc %r0,%r28,%r28
+
+;! This is just a special case of the code above.
+;! We come here when d == 0xFFFFFFFF
+L$FF..: add,uv %r25,%r24,%r24
+ sub,<< %r24,%r23,%r0
+ ldo 1(%r24),%r24
+ stws %r24,0(%r26)
+ bv 0(%r2)
+ addc %r0,%r25,%r28
+
+ .exit
+ .procend
Removed: fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.s
==============================================================================
--- fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.s (original)
+++ fsf/trunk/ports/sysdeps/hppa/udiv_qrnnd.s (removed)
@@ -1,285 +1,0 @@
-;! HP-PA __udiv_qrnnd division support, used from longlong.h.
-;! This version runs fast on pre-PA7000 CPUs.
-
-;! Copyright (C) 1993, 1994 Free Software Foundation, Inc.
-
-;! This file is part of the GNU MP Library.
-
-;! The GNU MP Library is free software; you can redistribute it and/or modify
-;! it under the terms of the GNU Lesser General Public License as published by
-;! the Free Software Foundation; either version 2.1 of the License, or (at your
-;! option) any later version.
-
-;! The GNU MP Library is distributed in the hope that it will be useful, but
-;! WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
-;! or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
-;! License for more details.
-
-;! You should have received a copy of the GNU Lesser General Public License
-;! along with the GNU MP Library. If not, see
-;! <http://www.gnu.org/licenses/>.
-
-
-;! INPUT PARAMETERS
-;! rem_ptr gr26
-;! n1 gr25
-;! n0 gr24
-;! d gr23
-
-;! The code size is a bit excessive. We could merge the last two ds;addc
-;! sequences by simply moving the "bb,< Odd" instruction down. The only
-;! trouble is the FFFFFFFF code that would need some hacking.
-
- .text
- .export __udiv_qrnnd
-__udiv_qrnnd:
- .proc
- .callinfo frame=0,no_calls
- .entry
-
- comb,< %r23,%r0,L$largedivisor
- sub %r0,%r23,%r1 ;! clear cy as side-effect
- ds %r0,%r1,%r0
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r24
- ds %r25,%r23,%r25
- addc %r24,%r24,%r28
- ds %r25,%r23,%r25
- comclr,>= %r25,%r0,%r0
- addl %r25,%r23,%r25
- stws %r25,0(%r26)
- bv 0(%r2)
- addc %r28,%r28,%r28
-
-L$largedivisor:
- extru %r24,31,1,%r20 ;! r20 = n0 & 1
- bb,< %r23,31,L$odd
- extru %r23,30,31,%r22 ;! r22 = d >> 1
- shd %r25,%r24,1,%r24 ;! r24 = new n0
- extru %r25,30,31,%r25 ;! r25 = new n1
- sub %r0,%r22,%r21
- ds %r0,%r21,%r0
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- comclr,>= %r25,%r0,%r0
- addl %r25,%r22,%r25
- sh1addl %r25,%r20,%r25
- stws %r25,0(%r26)
- bv 0(%r2)
- addc %r24,%r24,%r28
-
-L$odd: addib,sv,n 1,%r22,L$FF.. ;! r22 = (d / 2 + 1)
- shd %r25,%r24,1,%r24 ;! r24 = new n0
- extru %r25,30,31,%r25 ;! r25 = new n1
- sub %r0,%r22,%r21
- ds %r0,%r21,%r0
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r24
- ds %r25,%r22,%r25
- addc %r24,%r24,%r28
- comclr,>= %r25,%r0,%r0
- addl %r25,%r22,%r25
- sh1addl %r25,%r20,%r25
-;! We have computed (n1,,n0) / (d + 1), q' = r28, r' = r25
- add,nuv %r28,%r25,%r25
- addl %r25,%r1,%r25
- addc %r0,%r28,%r28
- sub,<< %r25,%r23,%r0
- addl %r25,%r1,%r25
- stws %r25,0(%r26)
- bv 0(%r2)
- addc %r0,%r28,%r28
-
-;! This is just a special case of the code above.
-;! We come here when d == 0xFFFFFFFF
-L$FF..: add,uv %r25,%r24,%r24
- sub,<< %r24,%r23,%r0
- ldo 1(%r24),%r24
- stws %r24,0(%r26)
- bv 0(%r2)
- addc %r0,%r25,%r28
-
- .exit
- .procend
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/ftruncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/ftruncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/ftruncate64.c Sun May 20 00:01:54 2012
@@ -1,5 +1,4 @@
-/* Copyright (C) 1997,1998,1999,2000,2001,2003, 2005
- Free Software Foundation, Inc.
+/* Copyright (C) 1997-2012 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
@@ -24,53 +23,14 @@
#include <sysdep.h>
#include <sys/syscall.h>
-#include "kernel-features.h"
-
-#ifdef __NR_ftruncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls. */
-extern int __have_no_truncate64;
-#endif
-
-
/* Truncate the file FD refers to to LENGTH bytes. */
int
__ftruncate64 (int fd, off64_t length)
{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (! __have_no_truncate64)
-#endif
- {
- unsigned int low = length & 0xffffffff;
- unsigned int high = length >> 32;
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- int saved_errno = errno;
-#endif
- int result = INLINE_SYSCALL (ftruncate64, 4, fd, 0,
- __LONG_LONG_PAIR (high, low));
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (result != -1 || errno != ENOSYS)
-#endif
- return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- __set_errno (saved_errno);
- __have_no_truncate64 = 1;
-#endif
- }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if ((off_t) length != length)
- {
- __set_errno (EINVAL);
- return -1;
- }
- return __ftruncate (fd, (off_t) length);
-#endif
+ unsigned int low = length & 0xffffffff;
+ unsigned int high = length >> 32;
+ int result = INLINE_SYSCALL (ftruncate64, 4, fd, 0,
+ __LONG_LONG_PAIR (high, low));
+ return result;
}
weak_alias (__ftruncate64, ftruncate64)
-
-#else
-/* Use the generic implementation. */
-# include <misc/ftruncate64.c>
-#endif
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/mmap.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/mmap.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/mmap.S Sun May 20 00:01:54 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2000, 2003, 2005, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1998-2012 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
@@ -16,20 +16,12 @@
<http://www.gnu.org/licenses/>. */
#include <sysdep.h>
-#include <kernel-features.h>
#define EINVAL 22
.text
ENTRY (__mmap)
-# ifdef __ASSUME_MMAP2_SYSCALL
- /* This code is actually a couple of cycles slower than the
- sys_mmap version below, so it might seem like a loss. But the
- code path inside the kernel is sufficiently much shorter to
- make it a net gain to use mmap2 when it's known to be
- available. */
-
/* shuffle args */
str r5, [sp, #-4]!
cfi_adjust_cfa_offset (4)
@@ -66,38 +58,6 @@
.Linval:
mov r0, #-EINVAL
b 2b
-# else
- /* Because we can only get five args through the syscall interface, and
- mmap() takes six, we need to build a parameter block and pass its
- address instead. The 386 port does a similar trick. */
-
- /* This code previously moved sp into ip and stored the args using
- stmdb ip!, {a1-a4}. It did not modify sp, so the stack never had
- to be restored after the syscall completed. It saved an
- instruction and meant no stack cleanup work was required.
-
- This will not work in the case of a mmap call being interrupted
- by a signal. If the signal handler uses any stack the arguments
- to mmap will be trashed. The results of a restart of mmap are
- then unpredictable. */
-
- /* store args on the stack */
- stmdb sp!, {a1-a4}
- cfi_adjust_cfa_offset (16)
-
- /* do the syscall */
- mov a1, sp
- DO_CALL (mmap, 0)
-
- /* pop args off the stack. */
- add sp, sp, #16
- cfi_adjust_cfa_offset (-16)
-
- cmn r0, $4096
- RETINSTR(cc, lr)
- b PLTJMP(syscall_error);
-#endif
-
PSEUDO_END (__mmap)
weak_alias (__mmap, mmap)
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/posix_fadvise64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/posix_fadvise64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/posix_fadvise64.c Sun May 20 00:01:54 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2003-2012 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
@@ -18,7 +18,6 @@
#include <errno.h>
#include <fcntl.h>
#include <sysdep.h>
-#include <kernel-features.h>
int __posix_fadvise64_l64 (int fd, off64_t offset, off64_t len, int advise);
int __posix_fadvise64_l32 (int fd, off64_t offset, size_t len, int advise);
@@ -29,34 +28,13 @@
int
__posix_fadvise64_l64 (int fd, off64_t offset, off64_t len, int advise)
{
-#ifdef __NR_arm_fadvise64_64
INTERNAL_SYSCALL_DECL (err);
int ret = INTERNAL_SYSCALL (arm_fadvise64_64, err, 6, fd, advise,
__LONG_LONG_PAIR ((long)(offset >> 32), (long)offset),
__LONG_LONG_PAIR ((long)(len >> 32), (long)len));
if (!INTERNAL_SYSCALL_ERROR_P (ret, err))
return 0;
-# ifndef __ASSUME_FADVISE64_64_SYSCALL
- if (INTERNAL_SYSCALL_ERRNO (ret, err) != ENOSYS)
-# endif
- return INTERNAL_SYSCALL_ERRNO (ret, err);
-#endif
-#ifndef __ASSUME_FADVISE64_64_SYSCALL
-# ifdef __NR_fadvise64
- if (len != (off_t) len)
- return EOVERFLOW;
-
- INTERNAL_SYSCALL_DECL (err2);
- int ret2 = INTERNAL_SYSCALL (fadvise64, err2, 6, fd, 0,
- __LONG_LONG_PAIR ((long)(offset >> 32), (long)offset),
- (off_t) len, advise);
- if (!INTERNAL_SYSCALL_ERROR_P (ret2, err2))
- return 0;
- return INTERNAL_SYSCALL_ERRNO (ret2, err2);
-# else
- return ENOSYS;
-# endif
-#endif
+ return INTERNAL_SYSCALL_ERRNO (ret, err);
}
#include <shlib-compat.h>
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/readahead.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/readahead.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/readahead.c Sun May 20 00:01:54 2012
@@ -1,5 +1,5 @@
/* Provide kernel hint to read ahead.
- Copyright (C) 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+ Copyright (C) 2002-2012 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
@@ -25,8 +25,6 @@
#include <sys/syscall.h>
-#ifdef __NR_readahead
-
ssize_t
__readahead (int fd, off64_t offset, size_t count)
{
@@ -35,16 +33,5 @@
(off_t) (offset & 0xffffffff)),
count);
}
-#else
-ssize_t
-__readahead (int fd, off64_t offset, size_t count)
-{
- __set_errno (ENOSYS);
- return -1;
-}
-stub_warning (readahead)
-
-# include <stub-tag.h>
-#endif
weak_alias (__readahead, readahead)
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigaction.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigaction.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigaction.c Sun May 20 00:01:54 2012
@@ -48,14 +48,9 @@
#endif
/* When RT signals are in use we need to use a different return stub. */
-#ifdef __NR_rt_sigreturn
#define choose_restorer(flags) \
(flags & SA_SIGINFO) ? __default_rt_sa_restorer \
: __default_sa_restorer
-#else
-#define choose_restorer(flags) \
- __default_sa_restorer
-#endif
/* If ACT is not NULL, change the action for SIG to *ACT.
If OACT is not NULL, put the old action for SIG in *OACT. */
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigrestorer.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigrestorer.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sigrestorer.S Sun May 20 00:01:54 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999, 2005, 2009, 2010 Free Software Foundation, Inc.
+/* Copyright (C) 1999-2012 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
@@ -88,8 +88,6 @@
END(__default_sa_restorer_v2)
#undef OFFSET
-#ifdef __NR_rt_sigreturn
-
#ifndef __ASSUME_SIGFRAME_V2
#define OFFSET 168
.fnstart
@@ -117,5 +115,3 @@
.fnend
END(__default_rt_sa_restorer_v2)
#undef OFFSET
-
-#endif /* __NR_rt_sigreturn */
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sysdep.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sysdep.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/sysdep.h Sun May 20 00:01:54 2012
@@ -27,16 +27,6 @@
#include <dl-sysdep.h>
#include <tls.h>
-
-#if __NR_SYSCALL_BASE != 0
-# error Kernel headers are too old
-#endif
-
-/* Don't use stime, even if the kernel headers define it. We have
- settimeofday, and some EABI kernels have removed stime. Similarly
- use setitimer to implement alarm. */
-#undef __NR_stime
-#undef __NR_alarm
/* In order to get __set_errno() definition in INLINE_SYSCALL. */
#ifndef __ASSEMBLER__
@@ -48,7 +38,6 @@
of the kernel. But these symbols do not follow the SYS_* syntax
so we have to redefine the `SYS_ify' macro here. */
#undef SYS_ify
-#define SWI_BASE (0x900000)
#define SYS_ify(syscall_name) (__NR_##syscall_name)
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/truncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/truncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/truncate64.c Sun May 20 00:01:54 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997-2000, 2003, 2004, 2005 Free Software Foundation, Inc.
+/* Copyright (C) 1997-2012 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
@@ -24,51 +24,13 @@
#include <sys/syscall.h>
#include <bp-checks.h>
-#include "kernel-features.h"
-
-#ifdef __NR_truncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls. */
-int __have_no_truncate64;
-#endif
-
/* Truncate the file FD refers to to LENGTH bytes. */
int
truncate64 (const char *path, off64_t length)
{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (! __have_no_truncate64)
-#endif
- {
- unsigned int low = length & 0xffffffff;
- unsigned int high = length >> 32;
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- int saved_errno = errno;
-#endif
- int result = INLINE_SYSCALL (truncate64, 4, CHECK_STRING (path), 0,
- __LONG_LONG_PAIR (high, low));
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (result != -1 || errno != ENOSYS)
-#endif
- return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- __set_errno (saved_errno);
- __have_no_truncate64 = 1;
-#endif
- }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if ((off_t) length != length)
- {
- __set_errno (EINVAL);
- return -1;
- }
- return __truncate (path, (off_t) length);
-#endif
+ unsigned int low = length & 0xffffffff;
+ unsigned int high = length >> 32;
+ int result = INLINE_SYSCALL (truncate64, 4, CHECK_STRING (path), 0,
+ __LONG_LONG_PAIR (high, low));
+ return result;
}
-
-#else
-/* Use the generic implementation. */
-# include <misc/truncate64.c>
-#endif
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/vfork.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/vfork.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/arm/vfork.S Sun May 20 00:01:54 2012
@@ -19,7 +19,6 @@
#include <sysdep.h>
#define _ERRNO_H 1
#include <bits/errno.h>
-#include <kernel-features.h>
/* Clone the calling process, but without copying the whole address space.
The calling process is suspended until the new process exits or is
@@ -27,8 +26,6 @@
and the process ID of the new process to the old process. */
ENTRY (__vfork)
-
-#ifdef __NR_vfork
#ifdef SAVE_PID
SAVE_PID
#endif
@@ -56,25 +53,7 @@
cmn a1, #4096
RETINSTR(cc, lr)
-# ifdef __ASSUME_VFORK_SYSCALL
b PLTJMP(SYSCALL_ERROR)
-# else
- /* Check if vfork syscall is known at all. */
- cmn a1, #ENOSYS
- bne PLTJMP(SYSCALL_ERROR)
-# endif
-#endif
-
-#ifndef __ASSUME_VFORK_SYSCALL
- /* If we don't have vfork, fork is close enough. */
- DO_CALL (fork, 0)
- cmn a1, #4096
- RETINSTR(cc, lr)
- b PLTJMP(SYSCALL_ERROR)
-#elif !defined __NR_vfork
-# error "__NR_vfork not available and __ASSUME_VFORK_SYSCALL defined"
-#endif
-
PSEUDO_END (__vfork)
libc_hidden_def (__vfork)
Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/ftruncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/ftruncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/ftruncate64.c (removed)
@@ -1,75 +1,0 @@
-/* Copyright (C) 1997,1998,1999,2000,2001,2002,2003,2005,2006
- 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sys/types.h>
-#include <errno.h>
-#include <endian.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-
-#include <kernel-features.h>
-
-#ifdef __NR_ftruncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls. */
-extern int __have_no_truncate64;
-#endif
-
-/* Truncate the file FD refers to to LENGTH bytes. */
-int
-__ftruncate64 (int fd, off64_t length)
-{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (! __have_no_truncate64)
-#endif
- {
- unsigned int low = length & 0xffffffff;
- unsigned int high = length >> 32;
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- int saved_errno = errno;
-#endif
- int result = INLINE_SYSCALL (ftruncate64, 4, fd, 0,
- __LONG_LONG_PAIR (high, low));
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (result != -1 || errno != ENOSYS)
-#endif
- return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- __set_errno (saved_errno);
- __have_no_truncate64 = 1;
-#endif
- }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if ((off_t) length != length)
- {
- __set_errno (EINVAL);
- return -1;
- }
- return __ftruncate (fd, (off_t) length);
-#endif
-}
-weak_alias (__ftruncate64, ftruncate64)
-
-#else
-/* Use the generic implementation. */
-# include <misc/ftruncate64.c>
-#endif
Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/ftruncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/ftruncate64.c (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/ftruncate64.c Sun May 20 00:01:54 2012
@@ -1,0 +1,36 @@
+/* Copyright (C) 1997-2012 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library. If not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <sys/types.h>
+#include <errno.h>
+#include <endian.h>
+#include <unistd.h>
+
+#include <sysdep.h>
+#include <sys/syscall.h>
+
+/* Truncate the file FD refers to to LENGTH bytes. */
+int
+__ftruncate64 (int fd, off64_t length)
+{
+ unsigned int low = length & 0xffffffff;
+ unsigned int high = length >> 32;
+ int result = INLINE_SYSCALL (ftruncate64, 4, fd, 0,
+ __LONG_LONG_PAIR (high, low));
+ return result;
+}
+weak_alias (__ftruncate64, ftruncate64)
Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/truncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/truncate64.c (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips32/truncate64.c Sun May 20 00:01:54 2012
@@ -1,0 +1,36 @@
+/* Copyright (C) 1997-2012 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library. If not, see
+ <http://www.gnu.org/licenses/>. */
+
+#include <sys/types.h>
+#include <endian.h>
+#include <errno.h>
+#include <unistd.h>
+
+#include <sysdep.h>
+#include <sys/syscall.h>
+#include <bp-checks.h>
+
+/* Truncate the file FD refers to to LENGTH bytes. */
+int
+truncate64 (const char *path, off64_t length)
+{
+ unsigned int low = length & 0xffffffff;
+ unsigned int high = length >> 32;
+ int result = INLINE_SYSCALL (truncate64, 4, CHECK_STRING (path), 0,
+ __LONG_LONG_PAIR (high, low));
+ return result;
+}
Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/ftruncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/ftruncate64.c (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/ftruncate64.c Sun May 20 00:01:54 2012
@@ -1,0 +1,1 @@
+/* Empty. */
Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/ftruncate64.c (removed)
@@ -1,1 +1,0 @@
-/* Empty. */
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list Sun May 20 00:01:54 2012
@@ -2,8 +2,6 @@
readahead - readahead i:iii __readahead readahead
sync_file_range - sync_file_range Ci:iiii sync_file_range
-ftruncate - ftruncate i:ii __ftruncate ftruncate ftruncate64 __ftruncate64
-truncate - truncate i:si truncate truncate64
prlimit64 EXTRA prlimit64 i:iipp prlimit64
Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/n32/truncate64.c (removed)
@@ -1,1 +1,0 @@
-/* Empty. */
Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/syscalls.list
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/syscalls.list (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/syscalls.list Sun May 20 00:01:54 2012
@@ -1,6 +1,9 @@
# File name Caller Syscall name Args Strong name Weak names
lseek - lseek Ci:iii __libc_lseek __lseek lseek __llseek llseek __libc_lseek64 __lseek64 lseek64
+
+ftruncate - ftruncate i:ii __ftruncate ftruncate ftruncate64 __ftruncate64
+truncate - truncate i:si truncate truncate64
# Semaphore and shm system calls. msgctl, shmctl, and semctl have C
# wrappers (to set __IPC_64).
Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/truncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/truncate64.c (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/mips64/truncate64.c Sun May 20 00:01:54 2012
@@ -1,0 +1,1 @@
+/* Empty. */
Removed: fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/truncate64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/truncate64.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/mips/truncate64.c (removed)
@@ -1,75 +1,0 @@
-/* Copyright (C) 1997,1998,1999,2000,2002,2003,2005,2006
- 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
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- The GNU C Library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library. If not, see
- <http://www.gnu.org/licenses/>. */
-
-#include <sys/types.h>
-#include <endian.h>
-#include <errno.h>
-#include <unistd.h>
-
-#include <sysdep.h>
-#include <sys/syscall.h>
-#include <bp-checks.h>
-
-#include <kernel-features.h>
-
-#ifdef __NR_truncate64
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
-/* The variable is shared between all wrappers around *truncate64 calls. */
-int __have_no_truncate64;
-#endif
-
-/* Truncate the file FD refers to to LENGTH bytes. */
-int
-truncate64 (const char *path, off64_t length)
-{
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (! __have_no_truncate64)
-#endif
- {
- unsigned int low = length & 0xffffffff;
- unsigned int high = length >> 32;
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- int saved_errno = errno;
-#endif
- int result = INLINE_SYSCALL (truncate64, 4, CHECK_STRING (path), 0,
- __LONG_LONG_PAIR (high, low));
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if (result != -1 || errno != ENOSYS)
-#endif
- return result;
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- __set_errno (saved_errno);
- __have_no_truncate64 = 1;
-#endif
- }
-
-#ifndef __ASSUME_TRUNCATE64_SYSCALL
- if ((off_t) length != length)
- {
- __set_errno (EINVAL);
- return -1;
- }
- return truncate (path, (off_t) length);
-#endif
-}
-
-#else
-/* Use the generic implementation. */
-# include <misc/truncate64.c>
-#endif
_______________________________________________
Commits mailing list
Commits@xxxxxxxxxx
http://eglibc.org/cgi-bin/mailman/listinfo/commits