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

[Commits] r17069 - in /fsf/trunk/ports: ./ sysdeps/alpha/ sysdeps/alpha/elf/ sysdeps/alpha/nptl/ sysdeps/alpha/nptl/elf/ sysdeps/unix/...



Author: eglibc
Date: Fri Feb 10 00:08:46 2012
New Revision: 17069

Log:
Import glibc-ports-mainline for 2012-02-10

Added:
    fsf/trunk/ports/sysdeps/alpha/elf/crti.S
    fsf/trunk/ports/sysdeps/alpha/elf/crtn.S
    fsf/trunk/ports/sysdeps/alpha/ldsodefs.h
    fsf/trunk/ports/sysdeps/alpha/tls-macros.h
    fsf/trunk/ports/sysdeps/alpha/tst-audit.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/dl-fxstatat64.c
Removed:
    fsf/trunk/ports/sysdeps/alpha/elf/initfini.c
    fsf/trunk/ports/sysdeps/alpha/nptl/elf/
Modified:
    fsf/trunk/ports/ChangeLog.alpha
    fsf/trunk/ports/sysdeps/alpha/dl-tls.h
    fsf/trunk/ports/sysdeps/alpha/elf/configure
    fsf/trunk/ports/sysdeps/alpha/elf/configure.in
    fsf/trunk/ports/sysdeps/alpha/nptl/tls.h
    fsf/trunk/ports/sysdeps/alpha/preconfigure
    fsf/trunk/ports/sysdeps/unix/alpha/sysdep.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/stat.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/fxstatat.c
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getitimer.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getrusage.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/gettimeofday.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/kernel-features.h
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/select.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/setitimer.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/settimeofday.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/utimes.S
    fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/wait4.S

Modified: fsf/trunk/ports/ChangeLog.alpha
==============================================================================
--- fsf/trunk/ports/ChangeLog.alpha (original)
+++ fsf/trunk/ports/ChangeLog.alpha Fri Feb 10 00:08:46 2012
@@ -1,3 +1,44 @@
+2012-02-09  Richard Henderson  <rth@xxxxxxxxxxx>
+
+	* sysdeps/alpha/preconfigure (libc_cv_gcc_unwind_find_fde): New.
+	(libc_commonpagesize, libc_relro_required): New.
+
+2012-02-08  Richard Henderson  <rth@xxxxxxxxxxx>
+
+	* sysdeps/alpha/ldsodefs.h: New file.
+	* sysdeps/alpha/tst-audit.h: New file.
+	* sysdeps/alpha/tls-macros.h: New file.
+
+	* sysdeps/unix/sysv/linux/alpha/getitimer.S: Don't check HAVE_ELF.
+	* sysdeps/unix/sysv/linux/alpha/getrusage.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/gettimeofday.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/select.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/setitimer.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/settimeofday.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/utimes.S: Likewise.
+	* sysdeps/unix/sysv/linux/alpha/wait4.S: Likewise.
+
+	* sysdeps/alpha/elf/crti.S, sysdeps/alpha/elf/crtn.S: New files...
+	* sysdeps/alpha/elf/initfini.c: ... split from here.  Remove file.
+	* sysdeps/alpha/nptl/elf/pt-initfini.c: Remove file.
+
+	* sysdeps/unix/alpha/sysdep.h (INTERNAL_SYSCALL_DECL): Mark unused.
+
+	* sysdeps/unix/sysv/linux/alpha/bits/stat.h (_STAT_VER_LINUX): New.
+
+	* sysdeps/alpha/dl-tls.h (TLS_DTV_UNALLOCATED): New.
+
+	* sysdeps/unix/sysv/linux/alpha/configure.in: New file.
+	* sysdeps/unix/sysv/linux/alpha/configure: Build.
+	* sysdeps/unix/sysv/linux/alpha/kernel-features.h: Protect from
+	multiple includes.  Disable statfs64 entirely.
+
+	* sysdeps/alpha/nptl/tls.h: Don't test HAVE_TLS_SUPPORT.
+	* sysdeps/unix/alpha/sysdep.h: Don't test HAVE___THREAD.
+	* sysdeps/alpha/elf/configure.in (libc_cv_alpha_tls): Error out if
+	the test fails.  Don't set HAVE_TLS_SUPPORT.
+	* sysdeps/alpha/elf/configure: Rebuild.
+
 2012-01-07  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
 
 	* sysdeps/alpha/backtrace.c: Use x86_64 version of backtrace.c.

Modified: fsf/trunk/ports/sysdeps/alpha/dl-tls.h
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/dl-tls.h (original)
+++ fsf/trunk/ports/sysdeps/alpha/dl-tls.h Fri Feb 10 00:08:46 2012
@@ -25,5 +25,7 @@
   unsigned long int ti_offset;
 } tls_index;
 
+extern void *__tls_get_addr (tls_index *ti);
 
-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)

Modified: fsf/trunk/ports/sysdeps/alpha/elf/configure
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/elf/configure (original)
+++ fsf/trunk/ports/sysdeps/alpha/elf/configure Fri Feb 10 00:08:46 2012
@@ -1,12 +1,92 @@
+
+# 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/alpha/elf.
 
-if test "$usetls" != no; then
-# Check for support of thread-local storage handling in assembler and
-# linker.
-{ $as_echo "$as_me:$LINENO: checking for Alpha TLS support" >&5
+# Check for support of thread-local storage handling in assembler and linker.
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for Alpha TLS support" >&5
 $as_echo_n "checking for Alpha TLS support... " >&6; }
-if test "${libc_cv_alpha_tls+set}" = set; then
+if ${libc_cv_alpha_tls+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.s <<\EOF
@@ -44,30 +124,26 @@
 	lda	$16, n($31)			!tprel
 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=$?
-  $as_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_alpha_tls=yes
 else
   libc_cv_alpha_tls=no
 fi
 rm -f conftest*
 fi
-{ $as_echo "$as_me:$LINENO: result: $libc_cv_alpha_tls" >&5
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_alpha_tls" >&5
 $as_echo "$libc_cv_alpha_tls" >&6; }
-if test $libc_cv_alpha_tls = yes; then
-  cat >>confdefs.h <<\_ACEOF
-#define HAVE_TLS_SUPPORT 1
-_ACEOF
-
-fi
+if test $libc_cv_alpha_tls = no; then
+  as_fn_error $? "the assembler must support TLS" "$LINENO" 5
 fi
 
-{ $as_echo "$as_me:$LINENO: checking for GP relative module local relocs" >&5
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GP relative module local relocs" >&5
 $as_echo_n "checking for GP relative module local relocs... " >&6; }
-if test "${libc_cv_alpha_hidden_gprel+set}" = set; then
+if ${libc_cv_alpha_hidden_gprel+:} false; then :
   $as_echo_n "(cached) " >&6
 else
   cat > conftest.c <<\EOF
@@ -78,11 +154,11 @@
 
 libc_cv_alpha_hidden_gprel=no
 if { ac_try='${CC-cc} -S $CFLAGS -O2 -fpic conftest.c 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=$?
-  $as_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
   if grep -q 'bar.*!gprel' conftest.s \
      && grep -q 'baz.*!gprel' conftest.s \
      && ! grep -q 'bar.*!literal' conftest.s \
@@ -92,11 +168,9 @@
 fi
 rm -f conftest*
 fi
-{ $as_echo "$as_me:$LINENO: result: $libc_cv_alpha_hidden_gprel" >&5
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_alpha_hidden_gprel" >&5
 $as_echo "$libc_cv_alpha_hidden_gprel" >&6; }
 if test $libc_cv_alpha_hidden_gprel = yes; then
-  cat >>confdefs.h <<\_ACEOF
-#define PI_STATIC_AND_HIDDEN 1
-_ACEOF
+  $as_echo "#define PI_STATIC_AND_HIDDEN 1" >>confdefs.h
 
 fi

Modified: fsf/trunk/ports/sysdeps/alpha/elf/configure.in
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/elf/configure.in (original)
+++ fsf/trunk/ports/sysdeps/alpha/elf/configure.in Fri Feb 10 00:08:46 2012
@@ -1,9 +1,7 @@
 GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
 # Local configure fragment for sysdeps/alpha/elf.
 
-if test "$usetls" != no; then
-# Check for support of thread-local storage handling in assembler and
-# linker.
+# Check for support of thread-local storage handling in assembler and linker.
 AC_CACHE_CHECK(for Alpha TLS support, libc_cv_alpha_tls, [dnl
 cat > conftest.s <<\EOF
 	.section ".tdata", "awT", @progbits
@@ -46,9 +44,8 @@
   libc_cv_alpha_tls=no
 fi
 rm -f conftest*])
-if test $libc_cv_alpha_tls = yes; then
-  AC_DEFINE(HAVE_TLS_SUPPORT)
-fi
+if test $libc_cv_alpha_tls = no; then
+  AC_MSG_ERROR([the assembler must support TLS])
 fi
 
 AC_CACHE_CHECK(for GP relative module local relocs, libc_cv_alpha_hidden_gprel, [dnl

Added: fsf/trunk/ports/sysdeps/alpha/elf/crti.S
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/elf/crti.S (added)
+++ fsf/trunk/ports/sysdeps/alpha/elf/crti.S Fri Feb 10 00:08:46 2012
@@ -1,0 +1,100 @@
+/* Special .init and .fini section support for Alpha.
+   Copyright (C) 2001, 2002, 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
+   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 GNU 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.)
+
+   Note that people who make modified versions of this file are not
+   obligated to grant this special exception for their modified
+   versions; it is their choice whether to do so. The GNU Lesser
+   General Public License gives permission to release a modified
+   version without this exception; this exception also makes it
+   possible to release a modified version which carries forward this
+   exception.
+
+   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.  */
+
+/* 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.  The symbols _init and _fini are
+   magic and cause the linker to emit DT_INIT and DT_FINI.
+
+   This differs from what would be generated for ordinary code in that
+   we save and restore the GP within the function.  In order for linker
+   relaxation to work, the value in the GP register on exit from a function
+   must be valid for the function entry point.  Normally, a function is
+   contained within one object file and this is not an issue, provided
+   that the function reloads the gp after making any function calls.
+   However, _init and _fini are constructed from pieces of many object
+   files, all of which may have different GP values.  So we must reload
+   the GP value from crti.o in crtn.o.  */
+
+#include <libc-symbols.h>
+#include <sysdep.h>
+
+#ifndef PREINIT_FUNCTION
+# define PREINIT_FUNCTION __gmon_start__
+#endif
+
+#ifndef PREINIT_FUNCTION_WEAK
+# define PREINIT_FUNCTION_WEAK 1
+#endif
+
+#if PREINIT_FUNCTION_WEAK
+        weak_extern (PREINIT_FUNCTION)
+#else
+        .hidden PREINIT_FUNCTION
+#endif
+
+	.section .init, "ax", @progbits
+	.globl	_init
+	.type	_init, @function
+	.usepv	_init, std
+_init:
+	ldgp	$29, 0($27)
+	subq	$30, 16, $30
+#if PREINIT_FUNCTION_WEAK
+	lda	$27, PREINIT_FUNCTION
+#endif
+	stq	$26, 0($30)
+	stq	$29, 8($30)
+#if PREINIT_FUNCTION_WEAK
+	beq	$27, 1f
+	jsr	$26, ($27), PREINIT_FUNCTION
+	ldq	$29, 8($30)
+1:
+#else
+	bsr	$26, PREINIT_FUNCTION !samegp
+#endif
+	.p2align 3
+
+	.section .fini, "ax", @progbits
+	.globl	_fini
+	.type	_fini,@function
+	.usepv	_fini,std
+_fini:
+	ldgp	$29, 0($27)
+	subq	$30, 16, $30
+	stq	$26, 0($30)
+	stq	$29, 8($30)
+	.p2align 3

Added: fsf/trunk/ports/sysdeps/alpha/elf/crtn.S
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/elf/crtn.S (added)
+++ fsf/trunk/ports/sysdeps/alpha/elf/crtn.S Fri Feb 10 00:08:46 2012
@@ -1,0 +1,50 @@
+/* Special .init and .fini section support for Alpha.
+   Copyright (C) 2001, 2002, 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
+   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 GNU 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.)
+
+   Note that people who make modified versions of this file are not
+   obligated to grant this special exception for their modified
+   versions; it is their choice whether to do so. The GNU Lesser
+   General Public License gives permission to release a modified
+   version without this exception; this exception also makes it
+   possible to release a modified version which carries forward this
+   exception.
+
+   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.  */
+
+/* crtn.S puts function epilogues in the .init and .fini sections
+   corresponding to the prologues in crti.S. */
+
+	.section .init, "ax", @progbits
+	ldq	$26, 0($30)
+	ldq	$29, 8($30)
+	addq	$30, 16, $30
+	ret
+
+	.section .fini, "ax", @progbits
+	ldq	$26, 0($30)
+	ldq	$29, 8($30)
+	addq	$30, 16, $30
+	ret

Removed: fsf/trunk/ports/sysdeps/alpha/elf/initfini.c
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/elf/initfini.c (original)
+++ fsf/trunk/ports/sysdeps/alpha/elf/initfini.c (removed)
@@ -1,110 +1,0 @@
-/* Special .init and .fini section support for Alpha.
-   Copyright (C) 2001, 2002, 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 GNU 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.)
-
-   Note that people who make modified versions of this file are not
-   obligated to grant this special exception for their modified
-   versions; it is their choice whether to do so. The GNU Lesser
-   General Public License gives permission to release a modified
-   version without this exception; this exception also makes it
-   possible to release a modified version which carries forward this
-   exception.
-
-   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.  */
-
-/* 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.
-
-   This differs from what would be generated by the generic code in that
-   we save and restore the GP within the function.  In order for linker
-   relaxation to work, the value in the GP register on exit from a function
-   must be valid for the function entry point.  Normally, a function is
-   contained within one object file and this is not an issue, provided
-   that the function reloads the gp after making any function calls.
-   However, _init and _fini are constructed from pieces of many object
-   files, all of which may have different GP values.  So we must reload
-   the GP value from crti.o in crtn.o.  */
-
-__asm__ ("						\n\
-#include \"defs.h\"					\n\
-							\n\
-/*@HEADER_ENDS*/					\n\
-							\n\
-/*@_init_PROLOG_BEGINS*/				\n\
-	.section .init, \"ax\", @progbits		\n\
-	.globl	_init					\n\
-	.type	_init, @function			\n\
-	.usepv	_init, std				\n\
-_init:							\n\
-	ldgp	$29, 0($27)				\n\
-	subq	$30, 16, $30				\n\
-	lda	$27, __gmon_start__			\n\
-	stq	$26, 0($30)				\n\
-	stq	$29, 8($30)				\n\
-	beq	$27, 1f					\n\
-	jsr	$26, ($27), __gmon_start__		\n\
-	ldq	$29, 8($30)				\n\
-	.align 3					\n\
-1:							\n\
-/*@_init_PROLOG_ENDS*/					\n\
-							\n\
-/*@_init_EPILOG_BEGINS*/				\n\
-	.section .init, \"ax\", @progbits		\n\
-	ldq	$26, 0($30)				\n\
-	ldq	$29, 8($30)				\n\
-	addq	$30, 16, $30				\n\
-	ret						\n\
-/*@_init_EPILOG_ENDS*/					\n\
-							\n\
-/*@_fini_PROLOG_BEGINS*/				\n\
-	.section .fini, \"ax\", @progbits		\n\
-	.globl	_fini					\n\
-	.type	_fini,@function				\n\
-	.usepv	_fini,std				\n\
-_fini:							\n\
-	ldgp	$29, 0($27)				\n\
-	subq	$30, 16, $30				\n\
-	stq	$26, 0($30)				\n\
-	stq	$29, 8($30)				\n\
-	.align 3					\n\
-/*@_fini_PROLOG_ENDS*/					\n\
-							\n\
-/*@_fini_EPILOG_BEGINS*/				\n\
-	.section .fini, \"ax\", @progbits		\n\
-	ldq	$26, 0($30)				\n\
-	ldq	$29, 8($30)				\n\
-	addq	$30, 16, $30				\n\
-	ret						\n\
-/*@_fini_EPILOG_ENDS*/					\n\
-							\n\
-/*@TRAILER_BEGINS*/					\n\
-");

Added: fsf/trunk/ports/sysdeps/alpha/ldsodefs.h
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/ldsodefs.h (added)
+++ fsf/trunk/ports/sysdeps/alpha/ldsodefs.h Fri Feb 10 00:08:46 2012
@@ -1,0 +1,43 @@
+/* Run-time dynamic linker data structures for loaded ELF shared objects.
+   Copyright (C) 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, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#ifndef __LDSODEFS_H
+
+#include <elf.h>
+
+struct La_alpha_regs;
+struct La_alpha_retval;
+
+#define ARCH_PLTENTER_MEMBERS						\
+    Elf64_Addr (*alpha_gnu_pltenter) (Elf64_Sym *, unsigned int,	\
+				     uintptr_t *, uintptr_t *,		\
+				     const struct La_alpha_regs *,	\
+				     unsigned int *, const char *name,  \
+				     long int *framesizep);
+
+#define ARCH_PLTEXIT_MEMBERS						\
+    unsigned int (*alpha_gnu_pltexit) (Elf64_Sym *, unsigned int,	\
+				      uintptr_t *, uintptr_t *,		\
+				      const struct La_alpha_regs *,	\
+				      struct La_alpha_retval *,		\
+				      const char *);
+
+#include_next <ldsodefs.h>
+
+#endif

Modified: fsf/trunk/ports/sysdeps/alpha/nptl/tls.h
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/nptl/tls.h (original)
+++ fsf/trunk/ports/sysdeps/alpha/nptl/tls.h Fri Feb 10 00:08:46 2012
@@ -1,5 +1,5 @@
 /* Definition for thread-local data handling.  NPTL/Alpha version.
-   Copyright (C) 2003, 2005, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2005, 2006, 2007, 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
@@ -37,18 +37,6 @@
     bool is_static;
   } pointer;
 } dtv_t;
-
-#else /* __ASSEMBLER__ */
-# include <tcb-offsets.h>
-#endif /* __ASSEMBLER__ */
-
-
-/* We require TLS support in the tools.  */
-#ifndef HAVE_TLS_SUPPORT
-# error "TLS support is required."
-#endif
-
-#ifndef __ASSEMBLER__
 
 /* Get system call information.  */
 # include <sysdep.h>
@@ -144,6 +132,8 @@
 #define THREAD_GSCOPE_WAIT() \
   GL(dl_wait_lookup_done) ()
 
+#else /* __ASSEMBLER__ */
+# include <tcb-offsets.h>
 #endif /* __ASSEMBLER__ */
 
 #endif	/* tls.h */

Modified: fsf/trunk/ports/sysdeps/alpha/preconfigure
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/preconfigure (original)
+++ fsf/trunk/ports/sysdeps/alpha/preconfigure Fri Feb 10 00:08:46 2012
@@ -1,3 +1,10 @@
 case "$machine" in
 alpha*)		base_machine=alpha machine=alpha/$machine ;;
 esac
+
+# We did historically export the unwinder from glibc.
+libc_cv_gcc_unwind_find_fde=yes
+
+# Parameters to allow auto-detection of -z relro.
+libc_commonpagesize=0x2000
+libc_relro_required=yes

Added: fsf/trunk/ports/sysdeps/alpha/tls-macros.h
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/tls-macros.h (added)
+++ fsf/trunk/ports/sysdeps/alpha/tls-macros.h Fri Feb 10 00:08:46 2012
@@ -1,0 +1,25 @@
+/* Macros to support TLS testing in times of missing compiler support.  */
+
+extern void *__tls_get_addr (void *);
+
+# define TLS_GD(x)						\
+  ({ void *__result;						\
+     asm ("lda %0, " #x "($gp) !tlsgd" : "=r" (__result));	\
+     __tls_get_addr (__result); })
+
+# define TLS_LD(x)						\
+  ({ void *__result;						\
+     asm ("lda %0, " #x "($gp) !tlsldm" : "=r" (__result));	\
+     __result = __tls_get_addr (__result);			\
+     asm ("lda %0, " #x "(%0) !dtprel" : "+r" (__result));	\
+     __result; })
+
+# define TLS_IE(x)						\
+  ({ long ofs;							\
+     asm ("ldq %0, " #x "($gp) !gottprel" : "=r"(ofs));		\
+     __builtin_thread_pointer () + ofs; })
+
+# define TLS_LE(x)						\
+  ({ void *__result = __builtin_thread_pointer ();		\
+     asm ("lda %0, " #x "(%0) !tprel" : "+r" (__result));	\
+     __result; })

Added: fsf/trunk/ports/sysdeps/alpha/tst-audit.h
==============================================================================
--- fsf/trunk/ports/sysdeps/alpha/tst-audit.h (added)
+++ fsf/trunk/ports/sysdeps/alpha/tst-audit.h Fri Feb 10 00:08:46 2012
@@ -1,0 +1,24 @@
+/* Definitions for testing PLT entry/exit auditing.  Alpha version.
+   Copyright (C) 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, write to the Free
+   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+   02111-1307 USA.  */
+
+#define pltenter la_alpha_gnu_pltenter
+#define pltexit la_alpha_gnu_pltexit
+#define La_regs La_alpha_regs
+#define La_retval La_alpha_retval

Modified: fsf/trunk/ports/sysdeps/unix/alpha/sysdep.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/alpha/sysdep.h (original)
+++ fsf/trunk/ports/sysdeps/unix/alpha/sysdep.h Fri Feb 10 00:08:46 2012
@@ -190,7 +190,9 @@
 	_sc_ret;					\
 })
 
-#define INTERNAL_SYSCALL_DECL(err)		long int err
+#define INTERNAL_SYSCALL_DECL(err) \
+	long int err __attribute__((unused))
+
 /* Make sure and "use" the variable that we're not returning,
    in order to suppress unused variable warnings.  */
 #define INTERNAL_SYSCALL_ERROR_P(val, err)	((void)val, err)
@@ -200,39 +202,19 @@
 	"$1", "$2", "$3", "$4", "$5", "$6", "$7", "$8",	\
 	"$22", "$23", "$24", "$25", "$27", "$28", "memory"
 
-/* If TLS is in use, we have a conflict between the PAL_rduniq primitive,
-   as modeled within GCC, and explicit use of the R0 register.  If we use
-   the register via the asm, the scheduler may place the PAL_rduniq insn
-   before we've copied the data from R0 into _sc_ret.  If this happens
-   we'll get a reload abort, since R0 is live at the same time it is
-   needed for the PAL_rduniq.
-
-   Solve this by using the "v" constraint instead of an asm for the syscall
-   output.  We don't do this unconditionally to allow compilation with
-   older compilers.  */
-
-#ifdef HAVE___THREAD
-#define inline_syscall_r0_asm
-#define inline_syscall_r0_out_constraint	"=v"
-#else
-#define inline_syscall_r0_asm			__asm__("$0")
-#define inline_syscall_r0_out_constraint	"=r"
-#endif
-
 /* It is moderately important optimization-wise to limit the lifetime
    of the hard-register variables as much as possible.  Thus we copy
    in/out as close to the asm as possible.  */
 
 #define inline_syscall0(name, args...)				\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_19 __asm__("$19");			\
 								\
 	_sc_0 = name;						\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2"				\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19)					\
+	   : "=v"(_sc_0), "=r"(_sc_19)				\
 	   : "0"(_sc_0)						\
 	   : inline_syscall_clobbers,				\
 	     "$16", "$17", "$18", "$20", "$21");		\
@@ -241,7 +223,7 @@
 
 #define inline_syscall1(name,arg1)				\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_19 __asm__("$19");			\
 	register long _tmp_16 = (long) (arg1);			\
@@ -250,8 +232,7 @@
 	_sc_16 = _tmp_16;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3"				\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16)				\
+	   : "=v"(_sc_0), "=r"(_sc_19), "=r"(_sc_16)		\
 	   : "0"(_sc_0), "2"(_sc_16)				\
 	   : inline_syscall_clobbers,				\
 	     "$17", "$18", "$20", "$21");			\
@@ -260,7 +241,7 @@
 
 #define inline_syscall2(name,arg1,arg2)				\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_17 __asm__("$17");			\
 	register long _sc_19 __asm__("$19");			\
@@ -272,8 +253,8 @@
 	_sc_17 = _tmp_17;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3 %4"			\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16), "=r"(_sc_17)		\
+	   : "=v"(_sc_0), "=r"(_sc_19),				\
+	     "=r"(_sc_16), "=r"(_sc_17)				\
 	   : "0"(_sc_0), "2"(_sc_16), "3"(_sc_17)		\
 	   : inline_syscall_clobbers,				\
 	     "$18", "$20", "$21");				\
@@ -282,7 +263,7 @@
 
 #define inline_syscall3(name,arg1,arg2,arg3)			\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_17 __asm__("$17");			\
 	register long _sc_18 __asm__("$18");			\
@@ -297,9 +278,8 @@
 	_sc_18 = _tmp_18;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3 %4 %5"			\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16), "=r"(_sc_17),		\
-	     "=r"(_sc_18)					\
+	   : "=v"(_sc_0), "=r"(_sc_19), "=r"(_sc_16),		\
+	     "=r"(_sc_17), "=r"(_sc_18)				\
 	   : "0"(_sc_0), "2"(_sc_16), "3"(_sc_17),		\
 	     "4"(_sc_18)					\
 	   : inline_syscall_clobbers, "$20", "$21");		\
@@ -308,7 +288,7 @@
 
 #define inline_syscall4(name,arg1,arg2,arg3,arg4)		\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_17 __asm__("$17");			\
 	register long _sc_18 __asm__("$18");			\
@@ -325,9 +305,8 @@
 	_sc_19 = _tmp_19;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3 %4 %5 %6"			\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16), "=r"(_sc_17),		\
-	     "=r"(_sc_18)					\
+	   : "=v"(_sc_0), "=r"(_sc_19), "=r"(_sc_16),		\
+	     "=r"(_sc_17), "=r"(_sc_18)				\
 	   : "0"(_sc_0), "2"(_sc_16), "3"(_sc_17),		\
 	     "4"(_sc_18), "1"(_sc_19)				\
 	   : inline_syscall_clobbers, "$20", "$21");		\
@@ -336,7 +315,7 @@
 
 #define inline_syscall5(name,arg1,arg2,arg3,arg4,arg5)		\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_17 __asm__("$17");			\
 	register long _sc_18 __asm__("$18");			\
@@ -356,9 +335,8 @@
 	_sc_20 = _tmp_20;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3 %4 %5 %6 %7"		\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16), "=r"(_sc_17),		\
-	     "=r"(_sc_18), "=r"(_sc_20)				\
+	   : "=v"(_sc_0), "=r"(_sc_19), "=r"(_sc_16),		\
+	     "=r"(_sc_17), "=r"(_sc_18), "=r"(_sc_20)		\
 	   : "0"(_sc_0), "2"(_sc_16), "3"(_sc_17),		\
 	     "4"(_sc_18), "1"(_sc_19), "5"(_sc_20)		\
 	   : inline_syscall_clobbers, "$21");			\
@@ -367,7 +345,7 @@
 
 #define inline_syscall6(name,arg1,arg2,arg3,arg4,arg5,arg6)	\
 {								\
-	register long _sc_0 inline_syscall_r0_asm;		\
+	register long _sc_0;					\
 	register long _sc_16 __asm__("$16");			\
 	register long _sc_17 __asm__("$17");			\
 	register long _sc_18 __asm__("$18");			\
@@ -390,9 +368,9 @@
 	_sc_21 = _tmp_21;					\
 	__asm__ __volatile__					\
 	  ("callsys # %0 %1 <= %2 %3 %4 %5 %6 %7 %8"		\
-	   : inline_syscall_r0_out_constraint (_sc_0),		\
-	     "=r"(_sc_19), "=r"(_sc_16), "=r"(_sc_17),		\
-	     "=r"(_sc_18), "=r"(_sc_20), "=r"(_sc_21)		\
+	   : "=v"(_sc_0), "=r"(_sc_19), "=r"(_sc_16),		\
+	     "=r"(_sc_17), "=r"(_sc_18), "=r"(_sc_20),		\
+	     "=r"(_sc_21)					\
 	   : "0"(_sc_0), "2"(_sc_16), "3"(_sc_17), "4"(_sc_18),	\
 	     "1"(_sc_19), "5"(_sc_20), "6"(_sc_21)		\
 	   : inline_syscall_clobbers);				\

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/stat.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/stat.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/bits/stat.h Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996,1997,1998,1999,2000,2001,2004,2010
+/* Copyright (C) 1996,1997,1998,1999,2000,2001,2004,2010,2012
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -30,7 +30,8 @@
 #define _STAT_VER_GLIBC2_1	2
 #define _STAT_VER_KERNEL64	3
 #define _STAT_VER_GLIBC2_3_4	3
-#define _STAT_VER		_STAT_VER_GLIBC2_3_4
+#define _STAT_VER_LINUX		3
+#define _STAT_VER		_STAT_VER_LINUX
 
 /* Versions of the `xmknod' interface.  */
 #define _MKNOD_VER_LINUX	0

Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure Fri Feb 10 00:08:46 2012
@@ -1,0 +1,8 @@
+# This file is generated from configure.in by Autoconf.  DO NOT EDIT!
+ # Local configure fragment for sysdeps/unix/sysv/linux/alpha
+
+# There are several bits that no longer compile cleanly without
+# realtime signal support (ver 2.2.0).  Given that we also now
+# require TLS (ver 2.6.0), it seems pointless to fix them.
+# ??? Surely this should now be the generic default.
+arch_minimum_kernel=2.6.0

Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/configure.in Fri Feb 10 00:08:46 2012
@@ -1,0 +1,8 @@
+GLIBC_PROVIDES dnl See aclocal.m4 in the top level source directory.
+# Local configure fragment for sysdeps/unix/sysv/linux/alpha
+
+# There are several bits that no longer compile cleanly without
+# realtime signal support (ver 2.2.0).  Given that we also now
+# require TLS (ver 2.6.0), it seems pointless to fix them.
+# ??? Surely this should now be the generic default.
+arch_minimum_kernel=2.6.0

Added: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/dl-fxstatat64.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/dl-fxstatat64.c (added)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/dl-fxstatat64.c Fri Feb 10 00:08:46 2012
@@ -1,0 +1,9 @@
+/* In this implementation we do not really care whether the call fails
+   because of missing kernel support since we do not even call the
+   function in this case.  */
+/* For Alpha, in <kernel-features.h> we redefine the default definition of
+   when __ASSUME_ATFCTS is present.  The hack must wait until after that.  */
+#include <kernel-features.h>
+#undef __ASSUME_ATFCTS
+#define __ASSUME_ATFCTS 1
+#include "fxstatat.c"

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/fxstatat.c
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/fxstatat.c (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/fxstatat.c Fri Feb 10 00:08:46 2012
@@ -30,11 +30,44 @@
 
 #undef __fxstatat64
 
+#ifdef __ASSUME_ATFCTS
+# define __have_atfcts 1
+#endif
+#ifdef __ASSUME_STAT64_SYSCALL
+# define __libc_missing_axp_stat64 0
+#endif
 
 /* Get information about the file NAME in BUF.  */
 int
 __fxstatat (int vers, int fd, const char *file, struct stat *st, int flag)
 {
+  INTERNAL_SYSCALL_DECL (err);
+  int result, errno_out;
+
+  /* ??? The __fxstatat entry point is new enough that it must be using
+     vers == _STAT_VER_KERNEL64.  For the benefit of dl-fxstatat64.c, we
+     cannot actually check this, lest the compiler not optimize the rest
+     of the function away.  */
+
+#ifdef __NR_fstatat64
+  if (__have_atfcts >= 0)
+    {
+      result = INTERNAL_SYSCALL (fstatat64, err, 4, fd, file, st, flag);
+      if (__builtin_expect (!INTERNAL_SYSCALL_ERROR_P (result, err), 1))
+	return result;
+      errno_out = INTERNAL_SYSCALL_ERRNO (result, err);
+#ifndef __ASSUME_ATFCTS
+      if (errno_out == ENOSYS)
+	__have_atfcts = -1;
+      else
+#endif
+	{
+	  __set_errno (errno_out);
+	  return -1;
+	}
+    }
+#endif /* __NR_fstatat64 */
+
   if (flag & ~AT_SYMLINK_NOFOLLOW)
     {
       __set_errno (EINVAL);
@@ -67,12 +100,8 @@
       file = buf;
     }
 
-  INTERNAL_SYSCALL_DECL (err);
-  int result, errno_out;
-  struct kernel_stat kst;
-
-#if __ASSUME_STAT64_SYSCALL > 0
-  if (vers == _STAT_VER_KERNEL64)
+#ifdef __NR_stat64
+  if (!__libc_missing_axp_stat64)
     {
       if (flag & AT_SYMLINK_NOFOLLOW)
 	result = INTERNAL_SYSCALL (lstat64, err, 2, file, st);
@@ -82,24 +111,16 @@
       if (__builtin_expect (!INTERNAL_SYSCALL_ERROR_P (result, err), 1))
 	return result;
       errno_out = INTERNAL_SYSCALL_ERRNO (result, err);
-      goto fail;
+# if __ASSUME_STAT64_SYSCALL == 0
+      if (errno_out == ENOSYS)
+	__libc_missing_axp_stat64 = 1;
+      else
+# endif
+	goto fail;
     }
-#elif defined __NR_stat64
-  if (vers == _STAT_VER_KERNEL64 && !__libc_missing_axp_stat64)
-    {
-      if (flag & AT_SYMLINK_NOFOLLOW)
-	result = INTERNAL_SYSCALL (lstat64, err, 2, file, st);
-      else
-	result = INTERNAL_SYSCALL (stat64, err, 2, file, st);
+#endif /* __NR_stat64 */
 
-      if (__builtin_expect (!INTERNAL_SYSCALL_ERROR_P (result, err), 1))
-	return result;
-      errno_out = INTERNAL_SYSCALL_ERRNO (result, err);
-      if (errno_out != ENOSYS)
-	goto fail;
-      __libc_missing_axp_stat64 = 1;
-    }
-#endif
+  struct kernel_stat kst;
 
   if (flag & AT_SYMLINK_NOFOLLOW)
     result = INTERNAL_SYSCALL (lstat, err, 2, file, &kst);

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getitimer.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getitimer.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getitimer.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define GETITIMER	__getitimer_tv64
 #else
 #define GETITIMER	getitimer
@@ -108,6 +108,6 @@
 END(GETITIMER)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__getitimer_tv64, getitimer, GLIBC_2.1)
 #endif

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getrusage.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getrusage.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/getrusage.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define GETRUSAGE	__getrusage_tv64
 #else
 #define GETRUSAGE	__getrusage
@@ -140,7 +140,7 @@
 END(GETRUSAGE)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 strong_alias(__getrusage_tv64, ____getrusage_tv64)
 default_symbol_version (____getrusage_tv64, __getrusage, GLIBC_2.1)
 default_symbol_version (__getrusage_tv64, getrusage, GLIBC_2.1)

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/gettimeofday.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/gettimeofday.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/gettimeofday.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2002, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2002, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define GETTIMEOFDAY	__gettimeofday_tv64
 #else
 #define GETTIMEOFDAY	__gettimeofday
@@ -106,7 +106,7 @@
 END(GETTIMEOFDAY)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__gettimeofday_tv64, __gettimeofday, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/kernel-features.h
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/kernel-features.h (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/kernel-features.h Fri Feb 10 00:08:46 2012
@@ -17,6 +17,9 @@
    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 _KERNEL_FEATURES_H
+#define _KERNEL_FEATURES_H 1
 
 /* alpha switched to a 64-bit timeval sometime before 2.2.0.  */
 #if __LINUX_KERNEL_VERSION >= 131584
@@ -96,3 +99,9 @@
 #if __LINUX_KERNEL_VERSION < 0x020621
 # undef __ASSUME_FALLOCATE
 #endif
+
+/* There never has been support for fstat64.  */
+#undef __ASSUME_STATFS64
+#define __ASSUME_STATFS64 0
+
+#endif /* _KERNEL_FEATURES_H */

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/select.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/select.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/select.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998,2002,2003,2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998,2002,2003,2006,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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define SELECT	__select_tv64
 #else
 #define SELECT	__select
@@ -224,7 +224,7 @@
 END(SELECT)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__select_tv64, __select, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/setitimer.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/setitimer.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/setitimer.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define SETITIMER	__setitimer_tv64
 #else
 #define SETITIMER	__setitimer
@@ -124,7 +124,7 @@
 END(SETITIMER)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__setitimer_tv64, __setitimer, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/settimeofday.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/settimeofday.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/settimeofday.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define SETTIMEOFDAY	__settimeofday_tv64
 #else
 #define SETTIMEOFDAY	__settimeofday
@@ -105,7 +105,7 @@
 END(SETTIMEOFDAY)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__settimeofday_tv64, __settimeofday, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/utimes.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/utimes.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/utimes.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define UTIMES	__utimes_tv64
 #else
 #define UTIMES	__utimes
@@ -110,7 +110,7 @@
 END(UTIMES)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__utimes_tv64, __utimes, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

Modified: fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/wait4.S
==============================================================================
--- fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/wait4.S (original)
+++ fsf/trunk/ports/sysdeps/unix/sysv/linux/alpha/wait4.S Fri Feb 10 00:08:46 2012
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 2003, 2006 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 2003, 2006, 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
@@ -23,7 +23,7 @@
 
 .text
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 #define WAIT4	__wait4_tv64
 #else
 #define WAIT4	__wait4
@@ -143,7 +143,7 @@
 END(WAIT4)
 #endif /* __ASSUME_TIMEVAL64 */
 
-#if defined HAVE_ELF && defined PIC && defined DO_VERSIONING
+#if defined PIC && defined DO_VERSIONING
 default_symbol_version (__wait4_tv64, __wait4, GLIBC_2.1)
 
 /* It seems to me to be a misfeature of the assembler that we can only

_______________________________________________
Commits mailing list
Commits@xxxxxxxxxx
http://eglibc.org/cgi-bin/mailman/listinfo/commits