From: Jakub Jelinek Date: Wed, 21 May 2008 08:48:21 +0000 (+0000) Subject: * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h X-Git-Tag: upstream/2.30~14193 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5e6f34c2a01533c0b64e0b8c44c29a434613187d;p=external%2Fglibc.git * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h (CALL_ERRNO_LOCATION): Define. (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h (CALL_ERRNO_LOCATION): Define. (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S (__brk): Use HIDDEN_JUMPTARGET for __errno_location call in libc.so. 2008-05-21 Jakub Jelinek * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h (CALL_ERRNO_LOCATION): Define. (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h (CALL_ERRNO_LOCATION): Define. (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S (__brk): Use HIDDEN_JUMPTARGET for __errno_location call in libc.so. --- diff --git a/ChangeLog b/ChangeLog index bb9b90b..abf2caa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,14 @@ +2008-05-21 Jakub Jelinek + + * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h + (CALL_ERRNO_LOCATION): Define. + (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. + * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h + (CALL_ERRNO_LOCATION): Define. + (__SYSCALL_STRING, __CLONE_SYSCALL_STRING): Use it. + * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S (__brk): Use + HIDDEN_JUMPTARGET for __errno_location call in libc.so. + 2008-05-20 Ulrich Drepper * include/inline-hashtab.h (higher_prime_number): Fix type of mid diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h b/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h index c808a97..1f674c1 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h +++ b/sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h @@ -1,4 +1,5 @@ -/* Copyright (C) 1997, 2002, 2003, 2004, 2006 Free Software Foundation, Inc. +/* Copyright (C) 1997, 2002, 2003, 2004, 2006, 2008 + Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Miguel de Icaza , January 1997. @@ -89,6 +90,13 @@ ENTRY(name); \ #else /* __ASSEMBLER__ */ +#if defined SHARED && defined DO_VERSIONING && defined PIC \ + && !defined NO_HIDDEN && !defined NOT_IN_libc +# define CALL_ERRNO_LOCATION "call __GI___errno_location;" +#else +# define CALL_ERRNO_LOCATION "call __errno_location;" +#endif + #define __SYSCALL_STRING \ "ta 0x10;" \ "bcs 2f;" \ @@ -97,7 +105,7 @@ ENTRY(name); \ ".subsection 2;" \ "2:" \ "save %%sp, -192, %%sp;" \ - "call __errno_location;" \ + CALL_ERRNO_LOCATION \ " nop;" \ "st %%i0,[%%o0];" \ "ba 1b;" \ @@ -113,7 +121,7 @@ ENTRY(name); \ ".subsection 2;" \ "2:" \ "save %%sp, -192, %%sp;" \ - "call __errno_location;" \ + CALL_ERRNO_LOCATION \ " nop;" \ "st %%i0, [%%o0];" \ "ba 1b;" \ diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S b/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S index 134ce78..ccc5589 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/brk.S @@ -1,4 +1,4 @@ -/* Copyright (C) 1997 Free Software Foundation, Inc. +/* Copyright (C) 1997, 2008 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Richard Henderson , 1997. @@ -86,7 +86,11 @@ ENTRY (__brk) #endif st %o0, [%g1] #else +#ifndef NOT_IN_libc + call HIDDEN_JUMPTARGET(__errno_location) +#else call __errno_location +#endif mov %o0,%l1 st %l1, [%o0] #endif diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h b/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h index f156f92..6bb0613 100644 --- a/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h +++ b/sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1997, 2000, 2002, 2003, 2004, 2006 +/* Copyright (C) 1997, 2000, 2002, 2003, 2004, 2006, 2008 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Richard Henderson , 1997. @@ -106,12 +106,19 @@ ENTRY(name); \ #else /* __ASSEMBLER__ */ +#if defined SHARED && defined DO_VERSIONING && defined PIC \ + && !defined NO_HIDDEN && !defined NOT_IN_libc +# define CALL_ERRNO_LOCATION "call __GI___errno_location;" +#else +# define CALL_ERRNO_LOCATION "call __errno_location;" +#endif + #define __SYSCALL_STRING \ "ta 0x6d;" \ "bcc,pt %%xcc, 1f;" \ " nop;" \ "save %%sp, -192, %%sp;" \ - "call __errno_location;" \ + CALL_ERRNO_LOCATION \ " nop;" \ "st %%i0,[%%o0];" \ "restore %%g0, -1, %%o0;" \ @@ -122,7 +129,7 @@ ENTRY(name); \ "bcc,pt %%xcc, 1f;" \ " sub %%o1, 1, %%o1;" \ "save %%sp, -192, %%sp;" \ - "call __errno_location;" \ + CALL_ERRNO_LOCATION \ " mov -1, %%i1;" \ "st %%i0,[%%o0];" \ "restore %%g0, -1, %%o0;" \