[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

glibc-ports update for hppa.



Team,

I've pushed out 9 commits for glibc-ports that help bring hppa closer
to building directly from upstream source.

These commits have been a part of the debian patch set for a long time
now and are very stable.

Thank you for your patience.

Cheers,
Carlos.

---------- Forwarded message ----------
From:  <carlos@sourceware.org>
Date: Fri, Oct 21, 2011 at 11:53 AM
Subject: Community source repository for glibc add-on ports branch,
master, updated. glibc-2.14-35-g8cb8321
To: glibc-cvs@sourceware.org


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Community source repository for glibc add-on ports".

The branch, master has been updated
      via  8cb8321faf2edcf36d5061e8fc4c8fec4b23fd39 (commit)
      via  f84ed6825441096273a893b66a769e37ef68f2f3 (commit)
      via  25f991b858ffc104a5b6720ae229cee4e88c976f (commit)
      via  9dd87de7ff43261dc83c74cc561ae392a405663f (commit)
      via  930046be6fedf95d9fce6548bf58ad5e33023d67 (commit)
      via  5ce24e77ed89f2a6c11175e3798050246dfd9c04 (commit)
      via  2ab0965cb022dfdbd397eb88f96447393b4118b7 (commit)
      via  451398f8b87c2a7c6bed7d6650a6cfbca43f9189 (commit)
      via  ab653f4dbe37d6244057f3f2ab33078357b6d708 (commit)
     from  db6a567d0ddd816b1134651ddb66b66dbea2f40d (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=8cb8321faf2edcf36d5061e8fc4c8fec4b23fd39

commit 8cb8321faf2edcf36d5061e8fc4c8fec4b23fd39
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Fri Oct 21 10:08:04 2011 -0400

   Update cancellable assembly system call wrappers.

   This patch updates sysdep-cancel.h to include the
   new no-cancel wrapper and provides CFI directives
   for all of the assembly. The CFI directives should
   allow unwinding information to be generated.

   Signed-off-by: Carlos O'Donell <carlos@sytemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index b83f4f0..564ca0f 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,24 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h: Update copyright
+       year.
+       (PSEUDO): Define __*_nocancel version. Add CFI directives to
__*_nocancel
+       and normal version.
+       (PUSHARGS_1): Add CFI directive.
+       (PUSHARGS_2): Likewise.
+       (PUSHARGS_3): Likewise.
+       (PUSHARGS_4): Likewise.
+       (PUSHARGS_5): Likewise.
+       (PUSHARGS_6): Likewise.
+       (POPARGS_1): Likewise.
+       (POPARGS_2): Likewise.
+       (POPARGS_3): Likewise.
+       (POPARGS_4): Likewise.
+       (POPARGS_5): Likewise.
+       (POPARGS_6): Likewise.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c: Remove.
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h: Remove.
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h: Remove.
diff --git a/sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h
b/sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h
index 6cffa76..d704345 100644
--- a/sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h
+++ b/sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2005 Free Software Foundation, Inc.
+/* Copyright (C) 2005, 2011 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
@@ -61,11 +61,53 @@

 # undef PSEUDO
 # define PSEUDO(name, syscall_name, args)                              \
+       ENTRY (__##syscall_name##_nocancel)                             \
+       DOARGS_##args                                   ASM_LINE_SEP    \
+       stwm TREG, 64(%sp)                              ASM_LINE_SEP    \
+       .cfi_offset TREG, 0                             ASM_LINE_SEP    \
+       .cfi_adjust_cfa_offset 64                       ASM_LINE_SEP    \
+       stw %sp, -4(%sp)                                ASM_LINE_SEP    \
+       .cfi_offset 30, -4                              ASM_LINE_SEP    \
+       stw %r19, -32(%sp)                              ASM_LINE_SEP    \
+       .cfi_offset 19, -32                             ASM_LINE_SEP    \
+       /* Save r19 */                                  ASM_LINE_SEP    \
+       SAVE_PIC(TREG)                                  ASM_LINE_SEP    \
+       /* Do syscall, delay loads # */                 ASM_LINE_SEP    \
+       ble  0x100(%sr2,%r0)                            ASM_LINE_SEP    \
+       ldi SYS_ify (syscall_name), %r20 /* delay */    ASM_LINE_SEP    \
+       ldi NO_ERROR,%r1                                ASM_LINE_SEP    \
+       cmpb,>>=,n %r1,%ret0,L(pre_nc_end)              ASM_LINE_SEP    \
+       /* Restore r19 from TREG */                     ASM_LINE_SEP    \
+       LOAD_PIC(TREG) /* delay */                      ASM_LINE_SEP    \
+       SYSCALL_ERROR_HANDLER                           ASM_LINE_SEP    \
+       /* Use TREG for temp storage */                 ASM_LINE_SEP    \
+       copy %ret0, TREG /* delay */                    ASM_LINE_SEP    \
+       /* OPTIMIZE: Don't reload r19 */                ASM_LINE_SEP    \
+       /* do a -1*syscall_ret0 */                      ASM_LINE_SEP    \
+       sub %r0, TREG, TREG                             ASM_LINE_SEP    \
+       /* Store into errno location */                 ASM_LINE_SEP    \
+       stw TREG, 0(%sr0,%ret0)                         ASM_LINE_SEP    \
+       /* return -1 as error */                        ASM_LINE_SEP    \
+       ldi -1, %ret0                                   ASM_LINE_SEP    \
+L(pre_nc_end):                                         ASM_LINE_SEP    \
+       /* No need to LOAD_PIC */                       ASM_LINE_SEP    \
+       /* Undo frame */                                ASM_LINE_SEP    \
+       ldwm -64(%sp),TREG                              ASM_LINE_SEP    \
+       .cfi_adjust_cfa_offset -64                      ASM_LINE_SEP    \
+       /* Restore rp before exit */                    ASM_LINE_SEP    \
+       ldw -20(%sp), %rp                               ASM_LINE_SEP    \
+       .cfi_restore 2                                  ASM_LINE_SEP    \
+       ret                                             ASM_LINE_SEP    \
+       END(__##syscall_name##_nocancel)                ASM_LINE_SEP    \
+       /**********************************************/ASM_LINE_SEP    \
       ENTRY (name)                                                    \
       DOARGS_##args                                   ASM_LINE_SEP    \
       stwm TREG, 64(%sp)                              ASM_LINE_SEP    \
+       .cfi_adjust_cfa_offset 64                       ASM_LINE_SEP    \
       stw %sp, -4(%sp)                                ASM_LINE_SEP    \
+       .cfi_offset 30, -4                              ASM_LINE_SEP    \
       stw %r19, -32(%sp)                              ASM_LINE_SEP    \
+       .cfi_offset 19, -32                             ASM_LINE_SEP    \
       /* Done setting up frame, continue... */        ASM_LINE_SEP    \
       SINGLE_THREAD_P                                 ASM_LINE_SEP    \
       cmpib,<>,n 0,%ret0,L(pseudo_cancel)             ASM_LINE_SEP    \
@@ -128,26 +170,40 @@ L(pre_end):
         ASM_LINE_SEP    \
       /* No need to LOAD_PIC */                       ASM_LINE_SEP    \
       /* Undo frame */                                ASM_LINE_SEP    \
       ldwm -64(%sp),TREG                              ASM_LINE_SEP    \
+       .cfi_adjust_cfa_offset -64                      ASM_LINE_SEP    \
       /* Restore rp before exit */                    ASM_LINE_SEP    \
-       ldw -20(%sp), %rp                               ASM_LINE_SEP
+       ldw -20(%sp), %rp                               ASM_LINE_SEP    \
+       .cfi_restore 2                                  ASM_LINE_SEP

 /* Save arguments into our frame */
 # define PUSHARGS_0    /* nothing to do */
-# define PUSHARGS_1    PUSHARGS_0 stw %r26, -36(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_2    PUSHARGS_1 stw %r25, -40(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_3    PUSHARGS_2 stw %r24, -44(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_4    PUSHARGS_3 stw %r23, -48(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_5    PUSHARGS_4 stw %r22, -52(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_6    PUSHARGS_5 stw %r21, -56(%sr0,%sp)      ASM_LINE_SEP
+# define PUSHARGS_1    PUSHARGS_0 stw %r26, -36(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 26, -36                     ASM_LINE_SEP
+# define PUSHARGS_2    PUSHARGS_1 stw %r25, -40(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 25, -40                     ASM_LINE_SEP
+# define PUSHARGS_3    PUSHARGS_2 stw %r24, -44(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 24, -44                     ASM_LINE_SEP
+# define PUSHARGS_4    PUSHARGS_3 stw %r23, -48(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 23, -48                     ASM_LINE_SEP
+# define PUSHARGS_5    PUSHARGS_4 stw %r22, -52(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 22, -52                     ASM_LINE_SEP
+# define PUSHARGS_6    PUSHARGS_5 stw %r21, -56(%sr0,%sp)
ASM_LINE_SEP    \
+                       .cfi_offset 21, -56                     ASM_LINE_SEP

 /* Bring them back from the stack */
 # define POPARGS_0     /* nothing to do */
-# define POPARGS_1     POPARGS_0 ldw -36(%sr0,%sp), %r26       ASM_LINE_SEP
-# define POPARGS_2     POPARGS_1 ldw -40(%sr0,%sp), %r25       ASM_LINE_SEP
-# define POPARGS_3     POPARGS_2 ldw -44(%sr0,%sp), %r24       ASM_LINE_SEP
-# define POPARGS_4     POPARGS_3 ldw -48(%sr0,%sp), %r23       ASM_LINE_SEP
-# define POPARGS_5     POPARGS_4 ldw -52(%sr0,%sp), %r22       ASM_LINE_SEP
-# define POPARGS_6     POPARGS_5 ldw -56(%sr0,%sp), %r21       ASM_LINE_SEP
+# define POPARGS_1     POPARGS_0 ldw -36(%sr0,%sp), %r26
ASM_LINE_SEP    \
+                       .cfi_restore 26                         ASM_LINE_SEP
+# define POPARGS_2     POPARGS_1 ldw -40(%sr0,%sp), %r25
ASM_LINE_SEP    \
+                       .cfi_restore 25                         ASM_LINE_SEP
+# define POPARGS_3     POPARGS_2 ldw -44(%sr0,%sp), %r24
ASM_LINE_SEP    \
+                       .cfi_restore 24                         ASM_LINE_SEP
+# define POPARGS_4     POPARGS_3 ldw -48(%sr0,%sp), %r23
ASM_LINE_SEP    \
+                       .cfi_restore 23                         ASM_LINE_SEP
+# define POPARGS_5     POPARGS_4 ldw -52(%sr0,%sp), %r22
ASM_LINE_SEP    \
+                       .cfi_restore 22                         ASM_LINE_SEP
+# define POPARGS_6     POPARGS_5 ldw -56(%sr0,%sp), %r21
ASM_LINE_SEP    \
+                       .cfi_restore 21                         ASM_LINE_SEP

 # ifdef IS_IN_libpthread
 #  ifdef PIC

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=f84ed6825441096273a893b66a769e37ef68f2f3

commit f84ed6825441096273a893b66a769e37ef68f2f3
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 15:09:24 2011 -0400

   Update ChangeLog.hppa.

   Add missing entries to ChangeLog.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 01e7d1a..b83f4f0 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -6,6 +6,9 @@
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h: Remove.
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c: Remove.
       * sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h: Remove.
+       * sysdeps/hppa/linuxthreads/pspinlock.c: Remove.
+       * sysdeps/hppa/linuxthreads/pt-machine.h: Remove.
+       * sysdeps/hppa/linuxthreads/tls.h: Remove.

 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>


http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=25f991b858ffc104a5b6720ae229cee4e88c976f

commit 25f991b858ffc104a5b6720ae229cee4e88c976f
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:49:52 2011 -0400

   Remove hppa linuxthreads support.

   We now require NPTL and TLS to build glibc therefore
   the hppa linuxthreads support is no longer needed.
   Debian has already transitioned to NPTL support and
   we will continue to work out NPTL issues.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 2038513..01e7d1a 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,14 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c: Remove.
+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h: Remove.
+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h: Remove.
+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h: Remove.
+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c: Remove.
+       * sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h: Remove.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/hppa/stackinfo.h: Update copyright year.
       Include elf.h and define DEFAULT_STACK_PERMS.

diff --git a/sysdeps/hppa/linuxthreads/pspinlock.c
b/sysdeps/hppa/linuxthreads/pspinlock.c
deleted file mode 100644
index e5a5545..0000000
--- a/sysdeps/hppa/linuxthreads/pspinlock.c
+++ /dev/null
@@ -1,82 +0,0 @@
-/* POSIX spinlock implementation.  hppa version.
-   Copyright (C) 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; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#include <errno.h>
-#include <pthread.h>
-#include "internals.h"
-
-int
-__pthread_spin_lock (pthread_spinlock_t *lock)
-{
-  volatile unsigned int *addr = __ldcw_align (lock);
-
-  while (__ldcw (addr) == 0)
-    while (*addr == 0) ;
-
-  return 0;
-}
-weak_alias (__pthread_spin_lock, pthread_spin_lock)
-
-
-int
-__pthread_spin_trylock (pthread_spinlock_t *lock)
-{
-  volatile unsigned int *a = __ldcw_align (lock);
-
-  return __ldcw (a) ? 0 : EBUSY;
-}
-weak_alias (__pthread_spin_trylock, pthread_spin_trylock)
-
-
-int
-__pthread_spin_unlock (pthread_spinlock_t *lock)
-{
-  volatile unsigned int *a = __ldcw_align (lock);
-  int tmp = 1;
-  /* This should be a memory barrier to newer compilers */
-  __asm__ __volatile__ ("stw,ma %1,0(%0)"
-                        : : "r" (a), "r" (tmp) : "memory");
-  return 0;
-}
-weak_alias (__pthread_spin_unlock, pthread_spin_unlock)
-
-
-int
-__pthread_spin_init (pthread_spinlock_t *lock, int pshared)
-{
-  /* We can ignore the `pshared' parameter.  Since we are busy-waiting
-     all processes which can access the memory location `lock' points
-     to can use the spinlock.  */
-  volatile unsigned int *a = __ldcw_align (lock);
-  int tmp = 1;
-  /* This should be a memory barrier to newer compilers */
-  __asm__ __volatile__ ("stw,ma %1,0(%0)"
-                        : : "r" (a), "r" (tmp) : "memory");
-  return 0;
-}
-weak_alias (__pthread_spin_init, pthread_spin_init)
-
-
-int
-__pthread_spin_destroy (pthread_spinlock_t *lock)
-{
-  /* Nothing to do.  */
-  return 0;
-}
-weak_alias (__pthread_spin_destroy, pthread_spin_destroy)
diff --git a/sysdeps/hppa/linuxthreads/pt-machine.h
b/sysdeps/hppa/linuxthreads/pt-machine.h
deleted file mode 100644
index f35523f..0000000
--- a/sysdeps/hppa/linuxthreads/pt-machine.h
+++ /dev/null
@@ -1,134 +0,0 @@
-/* Machine-dependent pthreads configuration and inline functions.
-   hppa version.
-   Copyright (C) 2000, 2002, 2003 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Richard Henderson <rth@tamu.edu>.
-
-   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; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-#ifndef _PT_MACHINE_H
-#define _PT_MACHINE_H   1
-
-#include <sys/types.h>
-#include <bits/initspin.h>
-
-#ifndef PT_EI
-# define PT_EI extern inline __attribute__ ((always_inline))
-#endif
-
-extern inline long int testandset (__atomic_lock_t *spinlock);
-extern inline int __compare_and_swap (long int *p, long int oldval,
long int newval);
-extern inline int lock_held (__atomic_lock_t *spinlock);
-extern inline int __load_and_clear (__atomic_lock_t *spinlock);
-
-/* Get some notion of the current stack.  Need not be exactly the top
-   of the stack, just something somewhere in the current frame.  */
-#define CURRENT_STACK_FRAME  stack_pointer
-register char * stack_pointer __asm__ ("%r30");
-
-/* Get/Set thread-specific pointer.  We have to call into the kernel to
- * modify it, but we can read it in user mode.  */
-#ifndef THREAD_SELF
-#define THREAD_SELF __get_cr27()
-#endif
-
-#ifndef SET_THREAD_SELF
-#define SET_THREAD_SELF(descr) __set_cr27(descr)
-#endif
-/* Use this to determine type */
-struct _pthread_descr_struct *__thread_self;
-
-static inline struct _pthread_descr_struct * __get_cr27(void)
-{
-  long cr27;
-  asm ("mfctl %%cr27, %0" : "=r" (cr27) : );
-  return (struct _pthread_descr_struct *) cr27;
-}
-
-#ifndef INIT_THREAD_SELF
-#define INIT_THREAD_SELF(descr, nr) __set_cr27(descr)
-#endif
-
-static inline void __set_cr27(struct _pthread_descr_struct * cr27)
-{
-  asm ( "ble   0xe0(%%sr2, %%r0)\n\t"
-       "copy   %0, %%r26"
-       : : "r" (cr27) : "r26" );
-}
-
-/* We want the OS to assign stack addresses.  */
-#define FLOATING_STACKS        1
-#define ARCH_STACK_MAX_SIZE    8*1024*1024
-
-/* The hppa only has one atomic read and modify memory operation,
-   load and clear, so hppa spinlocks must use zero to signify that
-   someone is holding the lock.  The address used for the ldcw
-   semaphore must be 16-byte aligned.  */
-#define __ldcw(a) \
-({                                                                     \
-  unsigned int __ret;                                                  \
-  __asm__ __volatile__("ldcw 0(%1),%0"                                 \
-                      : "=r" (__ret) : "r" (a) : "memory");            \
-  __ret;                                                               \
-})
-
-/* Strongly ordered lock reset */
-#define __lock_reset(lock_addr, tmp) \
-({
         \
-       __asm__ __volatile__ ("stw,ma %1,0(%0)"
         \
-                               : : "r" (lock_addr), "r" (tmp) :
"memory");     \
-})
-
-/* Because malloc only guarantees 8-byte alignment for malloc'd data,
-   and GCC only guarantees 8-byte alignment for stack locals, we can't
-   be assured of 16-byte alignment for atomic lock data even if we
-   specify "__attribute ((aligned(16)))" in the type declaration.  So,
-   we use a struct containing an array of four ints for the atomic lock
-   type and dynamically select the 16-byte aligned int from the array
-   for the semaphore.  */
-#define __PA_LDCW_ALIGNMENT 16
-#define __ldcw_align(a) ({ \
-  volatile unsigned int __ret = (unsigned int) a;                      \
-  if ((__ret & ~(__PA_LDCW_ALIGNMENT - 1)) < (unsigned int) a)         \
-    __ret = (__ret & ~(__PA_LDCW_ALIGNMENT - 1)) + __PA_LDCW_ALIGNMENT; \
-  (unsigned int *) __ret;                                              \
-})
-
-/* Spinlock implementation; required.  */
-PT_EI int
-__load_and_clear (__atomic_lock_t *spinlock)
-{
-  volatile unsigned int *a = __ldcw_align (spinlock);
-
-  return __ldcw (a);
-}
-
-/* Emulate testandset */
-PT_EI long int
-testandset (__atomic_lock_t *spinlock)
-{
-  return (__load_and_clear(spinlock) == 0);
-}
-
-PT_EI int
-lock_held (__atomic_lock_t *spinlock)
-{
-  volatile unsigned int *a = __ldcw_align (spinlock);
-
-  return *a == 0;
-}
-
-#endif /* pt-machine.h */
diff --git a/sysdeps/hppa/linuxthreads/tls.h b/sysdeps/hppa/linuxthreads/tls.h
deleted file mode 100644
index 3d33a18..0000000
--- a/sysdeps/hppa/linuxthreads/tls.h
+++ /dev/null
@@ -1,163 +0,0 @@
-/* Definition for thread-local data handling.  linuxthreads/hppa version.
-   Copyright (C) 2005 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, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#ifndef _TLS_H
-#define _TLS_H
-
-#ifndef __ASSEMBLER__
-# include <pt-machine.h>
-# include <stdbool.h>
-# include <stddef.h>
-
-/* Type for the dtv.  */
-typedef union dtv
-{
-  size_t counter;
-  struct
-  {
-    void *val;
-    bool is_static;
-  } pointer;
-} dtv_t;
-
-#else /* __ASSEMBLER__ */
-# include <tcb-offsets.h>
-#endif /* __ASSEMBLER__ */
-
-
-#if defined HAVE_TLS_SUPPORT
-
-/* Signal that TLS support is available.  */
-# define USE_TLS       1
-
-# ifndef __ASSEMBLER__
-
-typedef struct
-{
-  dtv_t *dtv;
-  void *private;
-} tcbhead_t;
-
-/* Include some syscall information for other headers */
-#  include <sysdep.h>
-
-/* This is the size of the initial TCB.  */
-#  define TLS_INIT_TCB_SIZE sizeof (tcbhead_t)
-
-/* Alignment requirements for the initial TCB.  */
-#  define TLS_INIT_TCB_ALIGN __alignof__ (tcbhead_t)
-
-/* This is the size of the TCB.  */
-#  define TLS_TCB_SIZE sizeof (tcbhead_t)
-
-/* This is the size we need before TCB.  */
-#  define TLS_PRE_TCB_SIZE sizeof (struct _pthread_descr_struct)
-
-/* Alignment requirements for the TCB.  */
-#  define TLS_TCB_ALIGN __alignof__ (struct _pthread_descr_struct)
-
-/* The TLS blocks start right after the TCB.  */
-#  define TLS_DTV_AT_TP        1
-
-/* Return the thread descriptor for the current thread.  */
-#  undef THREAD_SELF
-#  define THREAD_SELF                          \
-  ({ struct _pthread_descr_struct *__self;     \
-       __self = __get_cr27();                  \
-       __self - 1;                             \
-   })
-
-#  undef INIT_THREAD_SELF
-#  define INIT_THREAD_SELF(descr, nr)                          \
-  ({ struct _pthread_descr_struct *__self = (void *)descr;     \
-       __set_cr27(__self + 1);                                 \
-       0;                                                      \
-   })
-
-/* Access to data in the thread descriptor is easy.  */
-#define THREAD_GETMEM(descr, member) \
-  ((void) sizeof (descr), THREAD_SELF->member)
-#define THREAD_GETMEM_NC(descr, member) \
-  ((void) sizeof (descr), THREAD_SELF->member)
-#define THREAD_SETMEM(descr, member, value) \
-  ((void) sizeof (descr), THREAD_SELF->member = (value))
-#define THREAD_SETMEM_NC(descr, member, value) \
-  ((void) sizeof (descr), THREAD_SELF->member = (value))
-
-/* Install the dtv pointer.  The pointer passed is to the element with
-   index -1 which contain the length.  */
-#  define INSTALL_DTV(tcbp, dtvp) \
-  ((tcbhead_t *) (tcbp))->dtv = dtvp + 1
-
-/* Install new dtv for current thread.  */
-#  define INSTALL_NEW_DTV(dtv) \
-  ({ tcbhead_t *__tcbp = (tcbhead_t *)__get_cr27();    \
-       __tcbp->dtv = dtv;                              \
-   })
-
-/* Return dtv of given thread descriptor.  */
-#  define GET_DTV(tcbp) \
-  (((tcbhead_t *) (tcbp))->dtv)
-
-/* Code to initially initialize the thread pointer.  This might need
-   special attention since 'errno' is not yet available and if the
-   operation can cause a failure 'errno' must not be touched.  */
-#  define TLS_INIT_TP(tcbp, secondcall) \
-  ({ __set_cr27(tcbp); 0; })
-
-/* Return the address of the dtv for the current thread.  */
-#  define THREAD_DTV()                                         \
-  ({ tcbhead_t *__tcbp = (tcbhead_t *)__get_cr27();    \
-       __tcbp->dtv;                                    \
-   })
-
-# define TLS_MULTIPLE_THREADS_IN_TCB 1
-
-/* Get the thread descriptor definition.  This must be after the
-   the definition of THREAD_SELF for TLS.  */
-#  include <linuxthreads/descr.h>
-
-# endif /* __ASSEMBLER__ */
-
-#else
-
-# ifndef __ASSEMBLER__
-
-typedef struct
-{
-  void *tcb;
-  dtv_t *dtv;
-  void *self;
-  int multiple_threads;
-} tcbhead_t;
-
-/* Get the thread descriptor definition.  */
-#  include <linuxthreads/descr.h>
-
-#  define NONTLS_INIT_TP \
-  do {
         \
-    static const tcbhead_t nontls_init_tp = { .multiple_threads = 0 }; \
-    INIT_THREAD_SELF(&nontls_init_tp, 0);                              \
-  } while (0)
-
-# endif /* __ASSEMBLER__ */
-
-#endif /* HAVE_TLS_SUPPORT */
-
-#endif /* tls.h */
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c
deleted file mode 100644
index 0d6da82..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c
+++ /dev/null
@@ -1,33 +0,0 @@
-#include <shlib-compat.h>
-
-#define aio_cancel64 XXX
-#include <aio.h>
-#undef aio_cancel64
-#include <errno.h>
-
-extern __typeof (aio_cancel) __new_aio_cancel;
-extern __typeof (aio_cancel) __old_aio_cancel;
-
-#define aio_cancel     __new_aio_cancel
-
-#include <sysdeps/pthread/aio_cancel.c>
-
-#undef aio_cancel
-strong_alias (__new_aio_cancel, __new_aio_cancel64);
-versioned_symbol (librt, __new_aio_cancel, aio_cancel, GLIBC_2_3);
-versioned_symbol (librt, __new_aio_cancel64, aio_cancel64, GLIBC_2_3);
-
-#if SHLIB_COMPAT (librt, GLIBC_2_1, GLIBC_2_3)
-
-#undef ECANCELED
-#define aio_cancel     __old_aio_cancel
-#define ECANCELED      125
-
-#include <sysdeps/pthread/aio_cancel.c>
-
-#undef aio_cancel
-strong_alias (__old_aio_cancel, __old_aio_cancel64);
-compat_symbol (librt, __old_aio_cancel, aio_cancel, GLIBC_2_1);
-compat_symbol (librt, __old_aio_cancel64, aio_cancel64, GLIBC_2_1);
-
-#endif
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h
deleted file mode 100644
index ff0ec20..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h
+++ /dev/null
@@ -1,41 +0,0 @@
-/* PA-RISC specific definitions for spinlock initializers.
-   Copyright (C) 2000, 2001 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; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/* Initial value of a spinlock.  PA-RISC only implements atomic load
-   and clear so this must be non-zero. */
-#define __LT_SPINLOCK_INIT ((__atomic_lock_t) { { 1, 1, 1, 1 } })
-
-/* Initialize global spinlocks without cast, generally macro wrapped */
-#define __LT_SPINLOCK_ALT_INIT { { 1, 1, 1, 1 } }
-
-/* Macros for lock initializers, not using the above definition.
-   The above definition is not used in the case that static initializers
-   use this value. */
-#define __LOCK_ALT_INITIALIZER { __LT_SPINLOCK_ALT_INIT, 0 }
-
-/* Used to initialize _pthread_fastlock's in non-static case */
-#define __LOCK_INITIALIZER ((struct _pthread_fastlock){
__LT_SPINLOCK_INIT, 0 })
-
-/* Used in pthread_atomic initialization */
-#define __ATOMIC_INITIALIZER { 0, __LT_SPINLOCK_ALT_INIT }
-
-/* Tell the rest of the code that the initializer is non-zero without
-   explaining it's internal structure */
-#define __LT_INITIALIZER_NOT_ZERO
-
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h
deleted file mode 100644
index 7173718..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h
+++ /dev/null
@@ -1,159 +0,0 @@
-/* Linuxthreads - a simple clone()-based implementation of Posix        */
-/* threads for Linux.                                                   */
-/* Copyright (C) 1996 Xavier Leroy (Xavier.Leroy@inria.fr)              */
-/*                                                                      */
-/* This program is free software; you can redistribute it and/or        */
-/* modify it under the terms of the GNU Library General Public License  */
-/* as published by the Free Software Foundation; either version 2       */
-/* of the License, or (at your option) any later version.               */
-/*                                                                      */
-/* This program 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 Library General Public License for more details.                 */
-
-#if !defined _BITS_TYPES_H && !defined _PTHREAD_H
-# error "Never include <bits/pthreadtypes.h> directly; use
<sys/types.h> instead."
-#endif
-
-#ifndef _BITS_PTHREADTYPES_H
-#define _BITS_PTHREADTYPES_H   1
-
-#define __need_schedparam
-#include <bits/sched.h>
-
-/* We need 128-bit alignment for the ldcw semaphore.  At most, we are
-   assured of 64-bit alignment for stack locals and malloc'd data.  Thus,
-   we use a struct with four ints for the atomic lock type.  The locking
-   code will figure out which of the four to use for the ldcw semaphore.  */
-typedef volatile struct {
-  int lock[4];
-} __attribute__ ((aligned(16))) __atomic_lock_t;
-
-/* Fast locks (not abstract because mutexes and conditions aren't abstract). */
-struct _pthread_fastlock
-{
-  __atomic_lock_t __spinlock;  /* Used by compare_and_swap emulation.  Also,
-                                  adaptive SMP lock stores spin count here. */
-  long int __status;           /* "Free" or "taken" or head of waiting list */
-};
-
-#ifndef _PTHREAD_DESCR_DEFINED
-/* Thread descriptors */
-typedef struct _pthread_descr_struct *_pthread_descr;
-# define _PTHREAD_DESCR_DEFINED
-#endif
-
-
-/* Attributes for threads.  */
-typedef struct __pthread_attr_s
-{
-  int __detachstate;
-  int __schedpolicy;
-  struct __sched_param __schedparam;
-  int __inheritsched;
-  int __scope;
-  size_t __guardsize;
-  int __stackaddr_set;
-  void *__stackaddr;
-  size_t __stacksize;
-} pthread_attr_t;
-
-
-/* Conditions (not abstract because of PTHREAD_COND_INITIALIZER */
-
-#ifdef __GLIBC_HAVE_LONG_LONG
-__extension__ typedef long long __pthread_cond_align_t;
-#else
-typedef long __pthread_cond_align_t;
-#endif
-
-typedef struct
-{
-  struct _pthread_fastlock __c_lock; /* Protect against concurrent access */
-  _pthread_descr __c_waiting;        /* Threads waiting on this condition */
-  char __padding[48 - sizeof (struct _pthread_fastlock)
-                - sizeof (_pthread_descr) - sizeof (__pthread_cond_align_t)];
-  __pthread_cond_align_t __align;
-} pthread_cond_t;
-
-
-/* Attribute for conditionally variables.  */
-typedef struct
-{
-  int __dummy;
-} pthread_condattr_t;
-
-/* Keys for thread-specific data */
-typedef unsigned int pthread_key_t;
-
-
-/* Mutexes (not abstract because of PTHREAD_MUTEX_INITIALIZER).  */
-/* (The layout is unnatural to maintain binary compatibility
-    with earlier releases of LinuxThreads.) */
-typedef struct
-{
-  int __m_reserved;               /* Reserved for future use */
-  int __m_count;                  /* Depth of recursive locking */
-  _pthread_descr __m_owner;       /* Owner thread (if recursive or errcheck) */
-  int __m_kind;                   /* Mutex kind: fast, recursive or errcheck */
-  struct _pthread_fastlock __m_lock; /* Underlying fast lock */
-} pthread_mutex_t;
-
-
-/* Attribute for mutex.  */
-typedef struct
-{
-  int __mutexkind;
-} pthread_mutexattr_t;
-
-
-/* Once-only execution */
-typedef int pthread_once_t;
-
-#if defined __USE_UNIX98 || defined __USE_XOPEN2K
-/* Read-write locks.  */
-typedef struct _pthread_rwlock_t
-{
-  struct _pthread_fastlock __rw_lock; /* Lock to guarantee mutual exclusion */
-  int __rw_readers;                   /* Number of readers */
-  _pthread_descr __rw_writer;         /* Identity of writer, or NULL if none */
-  _pthread_descr __rw_read_waiting;   /* Threads waiting for reading */
-  _pthread_descr __rw_write_waiting;  /* Threads waiting for writing */
-  int __rw_kind;                      /* Reader/Writer preference selection */
-  int __rw_pshared;                   /* Shared between processes or not */
-} pthread_rwlock_t;
-
-
-/* Attribute for read-write locks.  */
-typedef struct
-{
-  int __lockkind;
-  int __pshared;
-} pthread_rwlockattr_t;
-#endif
-
-#ifdef __USE_XOPEN2K
-/* POSIX spinlock data type.  */
-typedef __atomic_lock_t pthread_spinlock_t;
-
-/* POSIX barrier. */
-typedef struct {
-  struct _pthread_fastlock __ba_lock; /* Lock to guarantee mutual exclusion */
-  int __ba_required;                  /* Threads needed for completion */
-  int __ba_present;                   /* Threads waiting */
-  _pthread_descr __ba_waiting;        /* Queue of waiting threads */
-} pthread_barrier_t;
-
-/* barrier attribute */
-typedef struct {
-  int __pshared;
-} pthread_barrierattr_t;
-
-#endif
-
-
-/* Thread identifiers */
-typedef unsigned long int pthread_t;
-
-#endif /* bits/pthreadtypes.h */
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h
deleted file mode 100644
index 5dc6e6f..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h
+++ /dev/null
@@ -1,73 +0,0 @@
-/* HP-PARISC macro definitions for mutexes, thread-specific data
-   and parameters for malloc.
-   Copyright (C) 2003 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Carlos O'Donell <carlos@baldric.uwo.ca>, 2003.
-
-   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, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#ifndef _MALLOC_MACHINE_H
-#define _MALLOC_MACHINE_H
-
-#undef thread_atfork_static
-
-#include <atomic.h>
-#include <bits/libc-lock.h>
-
-__libc_lock_define (typedef, mutex_t)
-
-/* Since our lock structure does not tolerate being initialized to
zero, we must
-   modify the standard function calls made by malloc */
-#  define mutex_init(m)                \
-       __libc_maybe_call (__pthread_mutex_init, (m, NULL), \
-               (((m)->__m_lock.__spinlock =
__LT_SPINLOCK_INIT),(*(int *)(m))) )
-#  define mutex_lock(m)                \
-       __libc_maybe_call (__pthread_mutex_lock, (m), \
-                       (__load_and_clear(&((m)->__m_lock.__spinlock)), 0))
-#  define mutex_trylock(m)     \
-       __libc_maybe_call (__pthread_mutex_trylock, (m), \
-                       (*(int *)(m) ? 1 :
(__load_and_clear(&((m)->__m_lock.__spinlock)), 0)))
-#  define mutex_unlock(m)      \
-       __libc_maybe_call (__pthread_mutex_unlock, (m), \
-                       (((m)->__m_lock.__spinlock =
__LT_SPINLOCK_INIT), (*(int *)(m))) )
-
-/* This is defined by newer gcc version unique for each module.  */
-extern void *__dso_handle __attribute__ ((__weak__));
-
-#include <fork.h>
-
-#ifdef SHARED
-# define thread_atfork(prepare, parent, child) \
-   __register_atfork (prepare, parent, child, __dso_handle)
-#else
-# define thread_atfork(prepare, parent, child) \
-   __register_atfork (prepare, parent, child,                                \
-                     &__dso_handle == NULL ? NULL : __dso_handle)
-#endif
-
-/* thread specific data for glibc */
-
-#include <bits/libc-tsd.h>
-
-typedef int tsd_key_t[1];      /* no key data structure, libc magic does it */
-__libc_tsd_define (static, void *, MALLOC)     /* declaration/common
definition */
-#define tsd_key_create(key, destr)     ((void) (key))
-#define tsd_setspecific(key, data)     __libc_tsd_set (void *, MALLOC, (data))
-#define tsd_getspecific(key, vptr)     ((vptr) = __libc_tsd_get (void
*, MALLOC))
-
-#include <sysdeps/generic/malloc-machine.h>
-
-#endif /* !defined(_MALLOC_MACHINE_H) */
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c
deleted file mode 100644
index 27f850c..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c
+++ /dev/null
@@ -1,109 +0,0 @@
-/* Special .init and .fini section support for HPPA.  Linuxthreads version.
-   Copyright (C) 2001, 2003 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.
-
-   In addition to the permissions in the GNU Lesser General Public
-   License, the Free Software Foundation gives you unlimited
-   permission to link the compiled version of this file with other
-   programs, and to distribute those programs without any restriction
-   coming from the use of this file.  (The Lesser General Public
-   License restrictions do apply in other respects; for example, they
-   cover modification of the file, and distribution when not linked
-   into another program.)
-
-   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; see the file COPYING.LIB.  If not,
-   write to the Free Software Foundation, 59 Temple Place - Suite 330,
-   Boston, MA 02111-1307, USA.  */
-
-/* This file is compiled into assembly code which is then munged by a sed
-   script into two files: crti.s and crtn.s.
-
-   * crti.s puts a function prologue at the beginning of the
-   .init and .fini sections and defines global symbols for
-   those addresses, so they can be called as functions.
-
-   * crtn.s puts the corresponding function epilogues
-   in the .init and .fini sections. */
-
-/* If we use the standard C version, the linkage table pointer won't
-   be properly preserved due to the splitting up of function prologues
-   and epilogues.  Therefore we write these in assembly to make sure
-   they do the right thing.  */
-
-__asm__ (
-"#include \"defs.h\"\n"
-"\n"
-"/*@HEADER_ENDS*/\n"
-"\n"
-"/*@_init_PROLOG_BEGINS*/\n"
-"      .section .init\n"
-"      .align 4\n"
-"      .globl _init\n"
-"      .type _init,@function\n"
-"_init:\n"
-"      stw     %rp,-20(%sp)\n"
-"      stwm    %r4,64(%sp)\n"
-"      stw     %r19,-32(%sp)\n"
-"      bl      __pthread_initialize_minimal,%rp\n"
-"      copy    %r19,%r4        /* delay slot */\n"
-"      copy    %r4,%r19\n"
-"/*@_init_PROLOG_ENDS*/\n"
-"\n"
-"/*@_init_EPILOG_BEGINS*/\n"
-"/* Here is the tail end of _init.  */\n"
-"      .section .init\n"
-"      ldw     -84(%sp),%rp\n"
-"      copy    %r4,%r19\n"
-"      bv      %r0(%rp)\n"
-"_end_init:\n"
-"      ldwm    -64(%sp),%r4\n"
-"\n"
-"/* Our very own unwind info, because the assembler can't handle\n"
-"   functions split into two or more pieces.  */\n"
-"      .section .PARISC.unwind,\"a\",@progbits\n"
-"      .extern _init\n"
-"      .word   _init, _end_init\n"
-"      .byte   0x08, 0x01, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08\n"
-"\n"
-"/*@_init_EPILOG_ENDS*/\n"
-"\n"
-"/*@_fini_PROLOG_BEGINS*/\n"
-"      .section .fini\n"
-"      .align 4\n"
-"      .globl _fini\n"
-"      .type _fini,@function\n"
-"_fini:\n"
-"      stw     %rp,-20(%sp)\n"
-"      stwm    %r4,64(%sp)\n"
-"      stw     %r19,-32(%sp)\n"
-"      copy    %r19,%r4\n"
-"/*@_fini_PROLOG_ENDS*/\n"
-"\n"
-"/*@_fini_EPILOG_BEGINS*/\n"
-"      .section .fini\n"
-"      ldw     -84(%sp),%rp\n"
-"      copy    %r4,%r19\n"
-"      bv      %r0(%rp)\n"
-"_end_fini:\n"
-"      ldwm    -64(%sp),%r4\n"
-"\n"
-"      .section .PARISC.unwind,\"a\",@progbits\n"
-"      .extern _fini\n"
-"      .word   _fini, _end_fini\n"
-"      .byte   0x08, 0x01, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08\n"
-"\n"
-"/*@_fini_EPILOG_ENDS*/\n"
-"\n"
-"/*@TRAILER_BEGINS*/\n"
-);
diff --git a/sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h
b/sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h
deleted file mode 100644
index 51d6cf3..0000000
--- a/sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h
+++ /dev/null
@@ -1,242 +0,0 @@
-/* cancellable system calls for Linux/HPPA.
-   Copyright (C) 2003 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-   Contributed by Carlos O'Donell <carlos@baldric.uwo.ca>, 2003.
-
-   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, write to the Free
-   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
-   02111-1307 USA.  */
-
-#include <sysdep.h>
-#include <tls.h>
-#ifndef __ASSEMBLER__
-# include <linuxthreads/internals.h>
-#endif
-
-#if !defined NOT_IN_libc || defined IS_IN_libpthread || defined IS_IN_librt
-
-# ifndef NO_ERROR
-#  define NO_ERROR -0x1000
-# endif
-
-/* The syscall cancellation mechanism requires userspace
-   assistance, the following code does roughly this:
-
-       do arguments (read arg5 and arg6 to registers)
-       setup frame
-
-       check if there are threads, yes jump to pseudo_cancel
-
-       unthreaded:
-               syscall
-               check syscall return (jump to pre_end)
-               set errno
-               set return to -1
-               (jump to pre_end)
-
-       pseudo_cancel:
-               cenable
-               syscall
-               cdisable
-               check syscall return (jump to pre_end)
-               set errno
-               set return to -1
-
-       pre_end
-               restore stack
-
-       It is expected that 'ret' and 'END' macros will
-       append an 'undo arguments' and 'return' to the
-       this PSEUDO macro. */
-
-# undef PSEUDO
-# define PSEUDO(name, syscall_name, args)                              \
-       ENTRY (name)                                                    \
-       DOARGS_##args                                   ASM_LINE_SEP    \
-       copy TREG, %r1                                  ASM_LINE_SEP    \
-       copy %sp, TREG                                  ASM_LINE_SEP    \
-       stwm %r1, 64(%sp)                               ASM_LINE_SEP    \
-       stw %rp, -20(%sp)                               ASM_LINE_SEP    \
-       stw TREG, -4(%sp)                               ASM_LINE_SEP    \
-       /* Done setting up frame, continue... */        ASM_LINE_SEP    \
-       SINGLE_THREAD_P                                 ASM_LINE_SEP    \
-       cmpib,<>,n 0,%ret0,L(pseudo_cancel)             ASM_LINE_SEP    \
-L(unthreaded):                                         ASM_LINE_SEP    \
-       /* Save r19 */                                  ASM_LINE_SEP    \
-       SAVE_PIC(TREG)                                  ASM_LINE_SEP    \
-       /* Do syscall, delay loads # */                 ASM_LINE_SEP    \
-       ble  0x100(%sr2,%r0)                            ASM_LINE_SEP    \
-       ldi SYS_ify (syscall_name), %r20 /* delay */    ASM_LINE_SEP    \
-       ldi NO_ERROR,%r1                                ASM_LINE_SEP    \
-       cmpb,>>=,n %r1,%ret0,L(pre_end)                 ASM_LINE_SEP    \
-       /* Restore r19 from TREG */                     ASM_LINE_SEP    \
-       LOAD_PIC(TREG) /* delay */                      ASM_LINE_SEP    \
-       SYSCALL_ERROR_HANDLER                           ASM_LINE_SEP    \
-       /* Use TREG for temp storage */                 ASM_LINE_SEP    \
-       copy %ret0, TREG /* delay */                    ASM_LINE_SEP    \
-       /* OPTIMIZE: Don't reload r19 */                ASM_LINE_SEP    \
-       /* do a -1*syscall_ret0 */                      ASM_LINE_SEP    \
-       sub %r0, TREG, TREG                             ASM_LINE_SEP    \
-       /* Store into errno location */                 ASM_LINE_SEP    \
-       stw TREG, 0(%sr0,%ret0)                         ASM_LINE_SEP    \
-       b L(pre_end)                                    ASM_LINE_SEP    \
-       /* return -1 as error */                        ASM_LINE_SEP    \
-       ldo -1(%r0), %ret0 /* delay */                  ASM_LINE_SEP    \
-L(pseudo_cancel):                                      ASM_LINE_SEP    \
-       PUSHARGS_##args /* Save args */                 ASM_LINE_SEP    \
-       /* Save r19 into TREG */                        ASM_LINE_SEP    \
-       CENABLE /* FUNC CALL */                         ASM_LINE_SEP    \
-       SAVE_PIC(TREG) /* delay */                      ASM_LINE_SEP    \
-       /* restore syscall args */                      ASM_LINE_SEP    \
-       POPARGS_##args                                  ASM_LINE_SEP    \
-       /* save mask from cenable (use stub rp slot) */ ASM_LINE_SEP    \
-       stw %ret0, -24(%sp)                             ASM_LINE_SEP    \
-       /* ... SYSCALL ... */                           ASM_LINE_SEP    \
-       ble 0x100(%sr2,%r0)                             ASM_LINE_SEP    \
-       ldi SYS_ify (syscall_name), %r20 /* delay */    ASM_LINE_SEP    \
-       /* ............... */                           ASM_LINE_SEP    \
-       LOAD_PIC(TREG)                                  ASM_LINE_SEP    \
-       /* pass mask as arg0 to cdisable */             ASM_LINE_SEP    \
-       ldw -24(%sp), %r26                              ASM_LINE_SEP    \
-       CDISABLE                                        ASM_LINE_SEP    \
-       stw %ret0, -24(%sp) /* delay */                 ASM_LINE_SEP    \
-       /* Restore syscall return */                    ASM_LINE_SEP    \
-       ldw -24(%sp), %ret0                             ASM_LINE_SEP    \
-       /* compare error */                             ASM_LINE_SEP    \
-       ldi NO_ERROR,%r1                                ASM_LINE_SEP    \
-       /* branch if no error */                        ASM_LINE_SEP    \
-       cmpb,>>=,n %r1,%ret0,L(pre_end)                 ASM_LINE_SEP    \
-       LOAD_PIC(TREG)  /* cond. nullify */             ASM_LINE_SEP    \
-       copy %ret0, TREG /* save syscall return */      ASM_LINE_SEP    \
-       SYSCALL_ERROR_HANDLER                           ASM_LINE_SEP    \
-       /* make syscall res value positive */           ASM_LINE_SEP    \
-       sub %r0, TREG, TREG     /* delay */             ASM_LINE_SEP    \
-       /* No need to LOAD_PIC */                       ASM_LINE_SEP    \
-       /* store into errno location */                 ASM_LINE_SEP    \
-       stw TREG, 0(%sr0,%ret0)                         ASM_LINE_SEP    \
-       /* return -1 */                                 ASM_LINE_SEP    \
-       ldo -1(%r0), %ret0                              ASM_LINE_SEP    \
-L(pre_end):                                            ASM_LINE_SEP    \
-       /* Restore rp before exit */                    ASM_LINE_SEP    \
-       ldw -84(%sr0,%sp), %rp                          ASM_LINE_SEP    \
-       /* Undo frame */                                ASM_LINE_SEP    \
-       ldwm -64(%sp),TREG                              ASM_LINE_SEP    \
-       /* No need to LOAD_PIC */                       ASM_LINE_SEP
-
-/* Save arguments into our frame */
-# define PUSHARGS_0    /* nothing to do */
-# define PUSHARGS_1    PUSHARGS_0 stw %r26, -36(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_2    PUSHARGS_1 stw %r25, -40(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_3    PUSHARGS_2 stw %r24, -44(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_4    PUSHARGS_3 stw %r23, -48(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_5    PUSHARGS_4 stw %r22, -52(%sr0,%sp)      ASM_LINE_SEP
-# define PUSHARGS_6    PUSHARGS_5 stw %r21, -56(%sr0,%sp)      ASM_LINE_SEP
-
-/* Bring them back from the stack */
-# define POPARGS_0     /* nothing to do */
-# define POPARGS_1     POPARGS_0 ldw -36(%sr0,%sp), %r26       ASM_LINE_SEP
-# define POPARGS_2     POPARGS_1 ldw -40(%sr0,%sp), %r25       ASM_LINE_SEP
-# define POPARGS_3     POPARGS_2 ldw -44(%sr0,%sp), %r24       ASM_LINE_SEP
-# define POPARGS_4     POPARGS_3 ldw -48(%sr0,%sp), %r23       ASM_LINE_SEP
-# define POPARGS_5     POPARGS_4 ldw -52(%sr0,%sp), %r22       ASM_LINE_SEP
-# define POPARGS_6     POPARGS_5 ldw -56(%sr0,%sp), %r21       ASM_LINE_SEP
-
-# ifdef IS_IN_libpthread
-#  ifdef PIC
-#   define CENABLE .import __pthread_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __pthread_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE .import __pthread_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __pthread_disable_asynccancel,%r2 ASM_LINE_SEP
-#  else
-#   define CENABLE .import __pthread_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __pthread_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE .import __pthread_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __pthread_disable_asynccancel,%r2 ASM_LINE_SEP
-#  endif
-# elif !defined NOT_IN_libc
-#  ifdef PIC
-#   define CENABLE .import __libc_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __libc_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE    .import __libc_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __libc_disable_asynccancel,%r2 ASM_LINE_SEP
-#  else
-#   define CENABLE .import __libc_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __libc_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE    .import __libc_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __libc_disable_asynccancel,%r2 ASM_LINE_SEP
-#  endif
-# else
-#  ifdef PIC
-#   define CENABLE .import __librt_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __librt_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE .import __librt_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __librt_disable_asynccancel,%r2 ASM_LINE_SEP
-#  else
-#   define CENABLE .import __librt_enable_asynccancel,code ASM_LINE_SEP \
-                       bl __librt_enable_asynccancel,%r2 ASM_LINE_SEP
-#   define CDISABLE .import __librt_disable_asynccancel,code ASM_LINE_SEP \
-                       bl __librt_disable_asynccancel,%r2 ASM_LINE_SEP
-#  endif
-# endif
-
-/* p_header.multiple_threads is +12 from the pthread_descr struct start,
-   We could have called __get_cr27() but we really want less overhead */
-# define MULTIPLE_THREADS_OFFSET 0xC
-
-/* cr27 has been initialized to 0x0 by kernel */
-# define NO_THREAD_CR27 0x0
-
-# ifdef IS_IN_libpthread
-#  define __local_multiple_threads __pthread_multiple_threads
-# elif !defined NOT_IN_libc
-#  define __local_multiple_threads __libc_multiple_threads
-# else
-#  define __local_multiple_threads __librt_multiple_threads
-# endif
-
-# ifndef __ASSEMBLER__
-#  if !defined NOT_IN_libc || defined IS_IN_libpthread
-extern int __local_multiple_threads attribute_hidden;
-#  else
-extern int __local_multiple_threads;
-#  endif
-#  define SINGLE_THREAD_P __builtin_expect (__local_multiple_threads == 0, 1)
-# else
-/* This ALT version requires newer kernel support */
-#  define SINGLE_THREAD_P_MFCTL
         \
-       mfctl %cr27, %ret0
ASM_LINE_SEP    \
-       cmpib,= NO_THREAD_CR27,%ret0,L(stp)
ASM_LINE_SEP    \
-       nop
ASM_LINE_SEP    \
-       ldw MULTIPLE_THREADS_OFFSET(%sr0,%ret0),%ret0
ASM_LINE_SEP    \
-L(stp):
 ASM_LINE_SEP
-#  ifdef PIC
-/* Slower version uses GOT to get value of __local_multiple_threads */
-#   define SINGLE_THREAD_P
         \
-       addil LT%__local_multiple_threads, %r19
ASM_LINE_SEP    \
-       ldw RT%__local_multiple_threads(%sr0,%r1), %ret0
ASM_LINE_SEP    \
-       ldw 0(%sr0,%ret0), %ret0                                ASM_LINE_SEP
-#  else
-/* Slow non-pic version using DP */
-#   define SINGLE_THREAD_P
                 \
-       addil LR%__local_multiple_threads-$global$,%r27
 ASM_LINE_SEP    \
-       ldw RR%__local_multiple_threads-$global$(%sr0,%r1),%ret0
 ASM_LINE_SEP
-#  endif
-# endif
-#elif !defined __ASSEMBLER__
-
-/* This code should never be used but we define it anyhow.  */
-# define SINGLE_THREAD_P (1)
-
-#endif
-/* !defined NOT_IN_libc || defined IS_IN_libpthread */

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=9dd87de7ff43261dc83c74cc561ae392a405663f

commit 9dd87de7ff43261dc83c74cc561ae392a405663f
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:42:56 2011 -0400

   Define DEFAULT_STACK_PERMS.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 14abdee..2038513 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,10 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/hppa/stackinfo.h: Update copyright year.
+       Include elf.h and define DEFAULT_STACK_PERMS.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/unix/sysv/linux/hppa/bits/fcntl.h: Synchronize
       with canonical fcntl.h.

diff --git a/sysdeps/hppa/stackinfo.h b/sysdeps/hppa/stackinfo.h
index 318de71..44929c4 100644
--- a/sysdeps/hppa/stackinfo.h
+++ b/sysdeps/hppa/stackinfo.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1999, 2011 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
@@ -22,6 +22,12 @@
 #ifndef _STACKINFO_H
 #define _STACKINFO_H   1

+#include <elf.h>
+
+/* Default to an executable stack.  PF_X can be overridden if PT_GNU_STACK is
+ * present, but it is presumed absent.  */
+#define DEFAULT_STACK_PERMS (PF_R|PF_W|PF_X)
+
 /* On PA the stack grows up.  */
 #define _STACK_GROWS_UP        1


http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=930046be6fedf95d9fce6548bf58ad5e33023d67

commit 930046be6fedf95d9fce6548bf58ad5e33023d67
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:37:02 2011 -0400

   Syncrhonize fcntl.h with canonical source.

   Update fcntl.h to match canonical i386 fcntl.h, but
   update constants to match hppa linux kernel values.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 41a779e..14abdee 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,10 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/unix/sysv/linux/hppa/bits/fcntl.h: Synchronize
+       with canonical fcntl.h.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/hppa/fpu/fegetenv.c: Add hidden alias.
       * sysdeps/hppa/fpu/feupdateenv.c: Likewise.
       * sysdeps/hppa/fpu/ftestexcept.c: Likewise.
diff --git a/sysdeps/unix/sysv/linux/hppa/bits/fcntl.h
b/sysdeps/unix/sysv/linux/hppa/bits/fcntl.h
index a2c6482..8f42111 100644
--- a/sysdeps/unix/sysv/linux/hppa/bits/fcntl.h
+++ b/sysdeps/unix/sysv/linux/hppa/bits/fcntl.h
@@ -1,5 +1,5 @@
-/* O_*, F_*, FD_* bit values for Linux/HPPA.
-   Copyright (C) 1995,1996,1997,1998,1999,2000,2002,2004
+/* O_*, F_*, FD_* bit values for Linux.
+   Copyright (C) 1995-1999, 2000, 2002, 2004, 2010, 2011
   Free Software Foundation, Inc.
   This file is part of the GNU C Library.

@@ -29,7 +29,7 @@


 /* open/fcntl - O_SYNC is only implemented on blocks devices and on files
-   located on an ext2 file system */
+   located on a few file systems.  */
 #define O_ACCMODE         0003
 #define O_RDONLY            00
 #define O_WRONLY            01
@@ -46,13 +46,15 @@
 #define O_ASYNC                 020000
 #define O_BLKSEEK      00000100 /* HPUX only */

-#ifdef __USE_GNU
-# define O_DIRECT      000040000 /* Direct disk access.  */
+#ifdef __USE_XOPEN2K8
 # define O_DIRECTORY   000010000 /* Must be a directory.  */
 # define O_NOFOLLOW    000000200 /* Do not follow links.  */
-# define O_NOATIME     004000000 /* Do not set atime.  */
 # define O_CLOEXEC     010000000 /* Set close_on_exec.  */
 #endif
+#ifdef __USE_GNU
+# define O_DIRECT       040000 /* Direct disk access.  */
+# define O_NOATIME     004000000 /* Do not set atime.  */
+#endif

 /* For now Linux has synchronisity options for data and read operations.
   We define the symbols here but let them do the same as O_SYNC since
@@ -85,7 +87,7 @@
 #define F_SETLK64      9       /* Set record locking info (non-blocking).  */
 #define F_SETLKW64     10      /* Set record locking info (blocking).  */

-#if defined __USE_BSD || defined __USE_UNIX98
+#if defined __USE_BSD || defined __USE_UNIX98 || defined __USE_XOPEN2K8
 # define F_GETOWN      11      /* Get owner of socket (receiver of SIGIO).  */
 # define F_SETOWN      12      /* Set owner of socket (receiver of SIGIO).  */
 #endif
@@ -101,6 +103,10 @@
 # define F_SETLEASE    1024    /* Set a lease.  */
 # define F_GETLEASE    1025    /* Enquire what lease is active.  */
 # define F_NOTIFY      1026    /* Request notfications on a directory.  */
+# define F_SETPIPE_SZ  1031    /* Set pipe page size array.  */
+# define F_GETPIPE_SZ  1032    /* Set pipe page size array.  */
+#endif
+#ifdef __USE_XOPEN2K8
 # define F_DUPFD_CLOEXEC 1030  /* Duplicate file descriptor with
                                  close-on-exit set.  */
 #endif
@@ -227,6 +233,19 @@ struct f_owner_ex
                                          we splice from/to).  */
 # define SPLICE_F_MORE         4       /* Expect more data.  */
 # define SPLICE_F_GIFT         8       /* Pages passed in are a gift.  */
+
+
+/* File handle structure.  */
+struct file_handle
+{
+  unsigned int handle_bytes;
+  int handle_type;
+  /* File identifier.  */
+  unsigned char f_handle[0];
+};
+
+/* Maximum handle size (for now).  */
+# define MAX_HANDLE_SZ 128
 #endif

 __BEGIN_DECLS
@@ -243,20 +262,32 @@ extern int sync_file_range (int __fd, __off64_t
__offset, __off64_t __count,
                           unsigned int __flags);


-/* Splice address range into a pipe.  */
+/* Splice address range into a pipe.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
 extern ssize_t vmsplice (int __fdout, const struct iovec *__iov,
                        size_t __count, unsigned int __flags);

-/* Splice two files together.  */
+/* Splice two files together.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
 extern ssize_t splice (int __fdin, __off64_t *__offin, int __fdout,
                      __off64_t *__offout, size_t __len,
                      unsigned int __flags);

-/* In-kernel implementation of tee for pipe buffers.  */
+/* In-kernel implementation of tee for pipe buffers.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
 extern ssize_t tee (int __fdin, int __fdout, size_t __len,
                   unsigned int __flags);

-/* Reserve storage for the data of the file associated with FD.  */
+/* Reserve storage for the data of the file associated with FD.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
 # ifndef __USE_FILE_OFFSET64
 extern int fallocate (int __fd, int __mode, __off_t __offset, __off_t __len);
 # else
@@ -273,6 +304,19 @@ extern int fallocate64 (int __fd, int __mode,
__off64_t __offset,
                       __off64_t __len);
 # endif

+
+/* Map file name to file handle.  */
+extern int name_to_handle_at (int __dfd, const char *__name,
+                             struct file_handle *__handle, int *__mnt_id,
+                             int __flags) __THROW;
+
+/* Open file using the file handle.
+
+   This function is a possible cancellation point and therefore not
+   marked with __THROW.  */
+extern int open_by_handle_at (int __mountdirfd, struct file_handle *__handle,
+                             int __flags);
+
 #endif

 __END_DECLS

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=5ce24e77ed89f2a6c11175e3798050246dfd9c04

commit 5ce24e77ed89f2a6c11175e3798050246dfd9c04
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:30:56 2011 -0400

   Add hidden aliases for fenv.h functions.

   Add hidden aliases for fegetenv, feupdateenv, and
   ftestexcept. This avoids libc needing to go through
   the PLT for these functions.

   Signed-off-by: Carlos O'Donell <carlos@codesourcery.com>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 91ddf8d..41a779e 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,11 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/hppa/fpu/fegetenv.c: Add hidden alias.
+       * sysdeps/hppa/fpu/feupdateenv.c: Likewise.
+       * sysdeps/hppa/fpu/ftestexcept.c: Likewise.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/hppa/dl-tls.h: Update copyright year.
       Define TLS_DTV_UNALLOCATED.

diff --git a/sysdeps/hppa/fpu/fegetenv.c b/sysdeps/hppa/fpu/fegetenv.c
index fcf5d2d..aab3431 100644
--- a/sysdeps/hppa/fpu/fegetenv.c
+++ b/sysdeps/hppa/fpu/fegetenv.c
@@ -1,5 +1,5 @@
 /* Store current floating-point environment.
-   Copyright (C) 2000 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2011 Free Software Foundation, Inc.
   This file is part of the GNU C Library.
   Contributed by David Huggins-Daines <dhd@debian.org>, 2000

@@ -33,3 +33,4 @@ fegetenv (fenv_t *envp)
  memcpy(envp, buf, sizeof (*envp));
  return 0;
 }
+libm_hidden_def (fegetenv)
diff --git a/sysdeps/hppa/fpu/feupdateenv.c b/sysdeps/hppa/fpu/feupdateenv.c
index 1714006..6e1d5d4 100644
--- a/sysdeps/hppa/fpu/feupdateenv.c
+++ b/sysdeps/hppa/fpu/feupdateenv.c
@@ -1,5 +1,5 @@
 /* Install given floating-point environment and raise exceptions.
-   Copyright (C) 2000 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2011 Free Software Foundation, Inc.
   This file is part of the GNU C Library.
   Contributed by David Huggins-Daines <dhd@debian.org>, 2000

@@ -38,3 +38,4 @@ feupdateenv (const fenv_t *envp)
  /* Success.  */
  return 0;
 }
+libm_hidden_def (feupdateenv)
diff --git a/sysdeps/hppa/fpu/ftestexcept.c b/sysdeps/hppa/fpu/ftestexcept.c
index ac6d4b2..c031ffe 100644
--- a/sysdeps/hppa/fpu/ftestexcept.c
+++ b/sysdeps/hppa/fpu/ftestexcept.c
@@ -1,5 +1,5 @@
 /* Test exception in current environment.
-   Copyright (C) 2000 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2011 Free Software Foundation, Inc.
   This file is part of the GNU C Library.
   Contributed by David Huggins-Daines <dhd@debian.org>, 2000

@@ -32,3 +32,4 @@ fetestexcept (int excepts)

  return (s.sw[0] >> 27) & excepts & FE_ALL_EXCEPT;
 }
+libm_hidden_def (fetestexcept)

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=2ab0965cb022dfdbd397eb88f96447393b4118b7

commit 2ab0965cb022dfdbd397eb88f96447393b4118b7
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:21:00 2011 -0400

   Define TLS_DTV_UNALLOCATED for hppa.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index 3913e61..91ddf8d 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,10 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/hppa/dl-tls.h: Update copyright year.
+       Define TLS_DTV_UNALLOCATED.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/hppa/elf/configure.in: Always test for TLS support
       and error out if missing.
       * sysdeps/hppa/elf/configure: Regenerate.
diff --git a/sysdeps/hppa/dl-tls.h b/sysdeps/hppa/dl-tls.h
index 1bc9aae..91c3d44 100644
--- a/sysdeps/hppa/dl-tls.h
+++ b/sysdeps/hppa/dl-tls.h
@@ -1,5 +1,5 @@
 /* Thread-local storage handling in the ELF dynamic linker.  hppa version.
-   Copyright (C) 2003 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2011 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
@@ -27,3 +27,6 @@ typedef struct


 extern void *__tls_get_addr (tls_index *ti);
+
+/* Value used for dtv entries for which the allocation is delayed.  */
+#define TLS_DTV_UNALLOCATED    ((void *) -1l)

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=451398f8b87c2a7c6bed7d6650a6cfbca43f9189

commit 451398f8b87c2a7c6bed7d6650a6cfbca43f9189
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 14:15:51 2011 -0400

   Always test for TLS support.

   Always test for TLS support on hppa and raise
   an error if the TLS support is missing.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index e37a630..3913e61 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,5 +1,12 @@
 2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>

+       * sysdeps/hppa/elf/configure.in: Always test for TLS support
+       and error out if missing.
+       * sysdeps/hppa/elf/configure: Regenerate.
+       * sysdeps/hppa/configure: Regenerate.
+
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
       * sysdeps/hppa/nptl/tls.h: Update copyright year.
       Remove HAVE_TLS_SUPPORT check.

diff --git a/sysdeps/hppa/configure b/sysdeps/hppa/configure
index b50ec17..aafc420 100644
--- a/sysdeps/hppa/configure
+++ b/sysdeps/hppa/configure
@@ -1,19 +1,101 @@
+
+# as_fn_set_status STATUS
+# -----------------------
+# Set $? to STATUS, without forking.
+as_fn_set_status ()
+{
+  return $1
+} # as_fn_set_status
+
+# as_fn_exit STATUS
+# -----------------
+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
+as_fn_exit ()
+{
+  set +e
+  as_fn_set_status $1
+  exit $1
+} # as_fn_exit
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+   test "X`expr 00001 : '.*\(...\)'`" = X001; then
+  as_expr=expr
+else
+  as_expr=false
+fi
+
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
+  as_basename=basename
+else
+  as_basename=false
+fi
+
+as_me=`$as_basename -- "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+        X"$0" : 'X\(//\)$' \| \
+        X"$0" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X/"$0" |
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+           s//\1/
+           q
+         }
+         /^X\/\(\/\/\)$/{
+           s//\1/
+           q
+         }
+         /^X\/\(\/\).*/{
+           s//\1/
+           q
+         }
+         s/.*/./; q'`
+
+
+  as_lineno_1=$LINENO as_lineno_1a=$LINENO
+  as_lineno_2=$LINENO as_lineno_2a=$LINENO
+  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
+  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
+  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
+  sed -n '
+    p
+    /[$]LINENO/=
+  ' <$as_myself |
+    sed '
+      s/[$]LINENO.*/&-/
+      t lineno
+      b
+      :lineno
+      N
+      :loop
+      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
+      t loop
+      s/-\n.*//
+    ' >$as_me.lineno &&
+  chmod +x "$as_me.lineno" ||
+    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun
with a POSIX shell" >&2; as_fn_exit 1; }
+
+  # Don't try to exec as it changes $[0], causing all sort of problems
+  # (the dirname of $[0] is not the place where we might find the
+  # original and so on.  Autoconf is especially sensitive to this).
+  . "./$as_me.lineno"
+  # Exit status is that of the last command.
+  exit
+}
+
 # This file is generated from configure.in by Autoconf.  DO NOT EDIT!

-{ echo "$as_me:$LINENO: checking for assembler line separator" >&5
-echo $ECHO_N "checking for assembler line separator... $ECHO_C" >&6; }
-if test "${libc_cv_asm_line_sep+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for assembler line
separator" >&5
+$as_echo_n "checking for assembler line separator... " >&6; }
+if test "${libc_cv_asm_line_sep+set}" = set; then :
+  $as_echo_n "(cached) " >&6
 else
  cat > conftest.s <<EOF
 nop ; is_old_puffin
 EOF
 if { ac_try='${CC-cc} -c $ASFLAGS conftest.s 1>&5'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
  (eval $ac_try) 2>&5
  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; }; then
  libc_cv_asm_line_sep='!'
 else
  if test -z "$enable_hacker_mode"; then
@@ -25,8 +107,8 @@ else
 fi
 rm -f conftest*
 fi
-{ echo "$as_me:$LINENO: result: $libc_cv_asm_line_sep" >&5
-echo "${ECHO_T}$libc_cv_asm_line_sep" >&6; }
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_asm_line_sep" >&5
+$as_echo "$libc_cv_asm_line_sep" >&6; }
 cat >>confdefs.h <<_ACEOF
 #define ASM_LINE_SEP $libc_cv_asm_line_sep
 _ACEOF
diff --git a/sysdeps/hppa/elf/configure b/sysdeps/hppa/elf/configure
old mode 100644
new mode 100755
index ba69990..4df64a8
--- a/sysdeps/hppa/elf/configure
+++ b/sysdeps/hppa/elf/configure
@@ -1,13 +1,94 @@
+
+# as_fn_set_status STATUS
+# -----------------------
+# Set $? to STATUS, without forking.
+as_fn_set_status ()
+{
+  return $1
+} # as_fn_set_status
+
+# as_fn_exit STATUS
+# -----------------
+# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
+as_fn_exit ()
+{
+  set +e
+  as_fn_set_status $1
+  exit $1
+} # as_fn_exit
+if expr a : '\(a\)' >/dev/null 2>&1 &&
+   test "X`expr 00001 : '.*\(...\)'`" = X001; then
+  as_expr=expr
+else
+  as_expr=false
+fi
+
+if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
+  as_basename=basename
+else
+  as_basename=false
+fi
+
+as_me=`$as_basename -- "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+        X"$0" : 'X\(//\)$' \| \
+        X"$0" : 'X\(/\)' \| . 2>/dev/null ||
+$as_echo X/"$0" |
+    sed '/^.*\/\([^/][^/]*\)\/*$/{
+           s//\1/
+           q
+         }
+         /^X\/\(\/\/\)$/{
+           s//\1/
+           q
+         }
+         /^X\/\(\/\).*/{
+           s//\1/
+           q
+         }
+         s/.*/./; q'`
+
+
+  as_lineno_1=$LINENO as_lineno_1a=$LINENO
+  as_lineno_2=$LINENO as_lineno_2a=$LINENO
+  eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
+  test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
+  # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
+  sed -n '
+    p
+    /[$]LINENO/=
+  ' <$as_myself |
+    sed '
+      s/[$]LINENO.*/&-/
+      t lineno
+      b
+      :lineno
+      N
+      :loop
+      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
+      t loop
+      s/-\n.*//
+    ' >$as_me.lineno &&
+  chmod +x "$as_me.lineno" ||
+    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun
with a POSIX shell" >&2; as_fn_exit 1; }
+
+  # Don't try to exec as it changes $[0], causing all sort of problems
+  # (the dirname of $[0] is not the place where we might find the
+  # original and so on.  Autoconf is especially sensitive to this).
+  . "./$as_me.lineno"
+  # Exit status is that of the last command.
+  exit
+}
+
 # This file is generated from configure.in by Autoconf.  DO NOT EDIT!
 # Local configure fragment for sysdeps/hppa/elf.

-if test "$usetls" != no; then
 # Check for support of thread-local storage handling in assembler and
 # linker.
-{ echo "$as_me:$LINENO: checking for hppa TLS support" >&5
-echo $ECHO_N "checking for hppa TLS support... $ECHO_C" >&6; }
-if test "${libc_cv_hppa_tls+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hppa TLS support" >&5
+$as_echo_n "checking for hppa TLS support... " >&6; }
+if test "${libc_cv_hppa_tls+set}" = set; then :
+  $as_echo_n "(cached) " >&6
 else
  cat > conftest.s <<\EOF
 ; Setup tls data
@@ -41,23 +122,19 @@ test3:
 ; Done all the TLS tests.
 EOF
 if { ac_try='${CC-cc} -c $CFLAGS conftest.s 1>&5'
-  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+  { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
  (eval $ac_try) 2>&5
  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
+  test $ac_status = 0; }; }; then
  libc_cv_hppa_tls=yes
 else
  libc_cv_hppa_tls=no
 fi
 rm -f conftest*
 fi
-{ echo "$as_me:$LINENO: result: $libc_cv_hppa_tls" >&5
-echo "${ECHO_T}$libc_cv_hppa_tls" >&6; }
-if test $libc_cv_hppa_tls = yes; then
-  cat >>confdefs.h <<\_ACEOF
-#define HAVE_TLS_SUPPORT 1
-_ACEOF
-
-fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_hppa_tls" >&5
+$as_echo "$libc_cv_hppa_tls" >&6; }
+if test $libc_cv_hppa_tls = no; then
+  as_fn_error $? "the assembler must support TLS" "$LINENO" 5
 fi
diff --git a/sysdeps/hppa/elf/configure.in b/sysdeps/hppa/elf/configure.in
index 1b70a5b..e31c880 100644
--- a/sysdeps/hppa/elf/configure.in
+++ b/sysdeps/hppa/elf/configure.in
@@ -1,7 +1,6 @@
 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
 # Local configure fragment for sysdeps/hppa/elf.

-if test "$usetls" != no; then
 # Check for support of thread-local storage handling in assembler and
 # linker.
 AC_CACHE_CHECK(for hppa TLS support, libc_cv_hppa_tls, [dnl
@@ -43,7 +42,6 @@ else
  libc_cv_hppa_tls=no
 fi
 rm -f conftest*])
-if test $libc_cv_hppa_tls = yes; then
-  AC_DEFINE(HAVE_TLS_SUPPORT)
-fi
+if test $libc_cv_hppa_tls = no; then
+  AC_MSG_ERROR([the assembler must support TLS])
 fi

http://sources.redhat.com/git/gitweb.cgi?p=glibc-ports.git;a=commitdiff;h=ab653f4dbe37d6244057f3f2ab33078357b6d708

commit ab653f4dbe37d6244057f3f2ab33078357b6d708
Author: Carlos O'Donell <carlos@systemhalted.org>
Date:   Thu Oct 20 11:42:02 2011 -0400

   Remove check for HAVE_TLS_SUPPORT

   TLS support is now required, remove checks.

   Signed-off-by: Carlos O'Donell <carlos@systemhalted.org>

diff --git a/ChangeLog.hppa b/ChangeLog.hppa
index f19c693..e37a630 100644
--- a/ChangeLog.hppa
+++ b/ChangeLog.hppa
@@ -1,4 +1,9 @@
-2011-10-17  Guy Martin <gmsoft@tuxicoman.be>
+2011-10-20  Carlos O'Donell  <carlos@systemhalted.org>
+
+       * sysdeps/hppa/nptl/tls.h: Update copyright year.
+       Remove HAVE_TLS_SUPPORT check.
+
+2011-10-17  Guy Martin  <gmsoft@tuxicoman.be>

       * sysdeps/unix/sysv/linux/hppa/sys/epoll.h
       Fix EPOLL_CLOEXEC and EPOLL_NONBLOCK to match kernel definition.
diff --git a/sysdeps/hppa/nptl/tls.h b/sysdeps/hppa/nptl/tls.h
index 389cbb9..8af7504 100644
--- a/sysdeps/hppa/nptl/tls.h
+++ b/sysdeps/hppa/nptl/tls.h
@@ -1,5 +1,5 @@
 /* Definition for thread-local data handling.  NPTL/hppa version.
-   Copyright (C) 2005, 2007, 2010 Free Software Foundation, Inc.
+   Copyright (C) 2005, 2007, 2010, 2011 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
@@ -42,12 +42,6 @@ typedef union dtv
 # include <tcb-offsets.h>
 #endif /* __ASSEMBLER__ */

-
-/* We require TLS support in the tools.  */
-#ifndef HAVE_TLS_SUPPORT
-# error "TLS support is required."
-#endif
-
 /* Signal that TLS support is available.  */
 #define USE_TLS        1


-----------------------------------------------------------------------

Summary of changes:
 ChangeLog.hppa                                     |   66 ++++++-
 sysdeps/hppa/configure                             |  100 ++++++++-
 sysdeps/hppa/dl-tls.h                              |    5 +-
 sysdeps/hppa/elf/configure                         |  109 ++++++++--
 sysdeps/hppa/elf/configure.in                      |    6 +-
 sysdeps/hppa/fpu/fegetenv.c                        |    3 +-
 sysdeps/hppa/fpu/feupdateenv.c                     |    3 +-
 sysdeps/hppa/fpu/ftestexcept.c                     |    3 +-
 sysdeps/hppa/linuxthreads/pspinlock.c              |   82 -------
 sysdeps/hppa/linuxthreads/pt-machine.h             |  134 -----------
 sysdeps/hppa/linuxthreads/tls.h                    |  163 -------------
 sysdeps/hppa/nptl/tls.h                            |    8 +-
 sysdeps/hppa/stackinfo.h                           |    8 +-
 sysdeps/unix/sysv/linux/hppa/bits/fcntl.h          |   66 +++++-
 .../unix/sysv/linux/hppa/linuxthreads/aio_cancel.c |   33 ---
 .../sysv/linux/hppa/linuxthreads/bits/initspin.h   |   41 ----
 .../linux/hppa/linuxthreads/bits/pthreadtypes.h    |  159 -------------
 .../sysv/linux/hppa/linuxthreads/malloc-machine.h  |   73 ------
 .../sysv/linux/hppa/linuxthreads/pt-initfini.c     |  109 ---------
 .../sysv/linux/hppa/linuxthreads/sysdep-cancel.h   |  242 --------------------
 sysdeps/unix/sysv/linux/hppa/nptl/sysdep-cancel.h  |   84 ++++++--
 21 files changed, 394 insertions(+), 1103 deletions(-)
 mode change 100644 => 100755 sysdeps/hppa/elf/configure
 delete mode 100644 sysdeps/hppa/linuxthreads/pspinlock.c
 delete mode 100644 sysdeps/hppa/linuxthreads/pt-machine.h
 delete mode 100644 sysdeps/hppa/linuxthreads/tls.h
 delete mode 100644 sysdeps/unix/sysv/linux/hppa/linuxthreads/aio_cancel.c
 delete mode 100644 sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/initspin.h
 delete mode 100644
sysdeps/unix/sysv/linux/hppa/linuxthreads/bits/pthreadtypes.h
 delete mode 100644 sysdeps/unix/sysv/linux/hppa/linuxthreads/malloc-machine.h
 delete mode 100644 sysdeps/unix/sysv/linux/hppa/linuxthreads/pt-initfini.c
 delete mode 100644 sysdeps/unix/sysv/linux/hppa/linuxthreads/sysdep-cancel.h


hooks/post-receive
--
Community source repository for glibc add-on ports


Reply to: