diff -uNr glibc-2.3-20040205-2105/ChangeLog glibc-2.3.3-lfs/ChangeLog --- glibc-2.3-20040205-2105/ChangeLog 2004-02-06 08:00:13.000000000 +1100 +++ glibc-2.3.3-lfs/ChangeLog 2004-02-10 00:19:18.000000000 +1100 @@ -98,13 +98,6 @@ (_dl_main): Don't set GL(_dl_loaded)->l_relro_{addr,size} here. Call _dl_protect_relro for libraries if prelinking. -2004-01-23 Richard Henderson - - * Versions.def (libm): Replace GLIBC_2.3.3 with GLIBC_2.3.4. - * sysdeps/alpha/fpu/Versions (libm): Likewise. - * sysdeps/alpha/fpu/cfloat-compat.h (cfloat_versions): Likewise. - * sysdeps/alpha/fpu/s_clog10f.c (clog10f): Likewise. - 2004-01-22 Andreas Jaeger * sysdeps/ieee754/dbl-64/e_pow.c (log2): Rename to my_log2 to @@ -190,10 +183,6 @@ * sysdeps/generic/segfault.c: Likewise. Include ldsodefs.h. * sysdeps/generic/backtrace.c: Likewise. -2004-01-15 Ulrich Drepper - - * Versions.def: Add GLIBC_2.3.4. - 2004-01-15 Richard Henderson * sysdeps/unix/alpha/sysdep.h: Revert last change. @@ -226,65 +215,6 @@ (_symbol_version): Use C_SYMBOL_DOT_NAME to create '.'ed symbols. (_default_symbol_version): Use C_SYMBOL_DOT_NAME to create '.'ed symbols. - * sysdeps/powerpc/Makefile: Add rtld-global-offsets.sym to - gen-as-const-headers. - * sysdeps/powerpc/elf/rtld-global-offsets.sym: New file. - * sysdeps/powerpc/sysdep.h: Define v# symbols for vector registers. - Define PPC_FEATURE_* masks for Aux Vector AT_HWCAP. - * sysdeps/unix/sysv/linux/kernel-features.h - (__ASSUME_SWAPCONTEXT_SYSCALL): Define for PPC and 2.6.0 kernels. - * sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h [!__WORDSIZE == 32]: - Declare mcontext_t inline and include altivec state for 64-bit. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions: Add GLIBC_2.3.4 - versions for setcontext, getcontext, and swapcontext. - - * sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions: Add GLIBC_2.3.4 - versions for setcontext, getcontext, swapcontext, and makecontext. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S - (__getcontext): Upgrade to save Altivec regs and version GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4)] (__novec_getcontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S - (__makecontext): Use parm save area instead of compiler_dw to hold - context pointer. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S - (__setcontext): Upgrade to restore Altivec regs and version - GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4)] (__novec_setcontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S - (__swapcontext): Upgrade to swap Altivec regs and version GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4)] (__novec_swapcontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc64/ucontext_i.h - (SIGCONTEXT_V_REGS_PTR, SIGCONTEXT_V_RESERVE): Defined. - -2004-01-12 Steven Munroe - - * sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions: Add GLIBC_2.3.4 - versions for setcontext, getcontext, swapcontext, and makecontext. - * sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S - (__getcontext): Upgrade to save Altivec regs and version GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)] (__novec_getcontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S - (__makecontext): Upgrade to align for Altivec regs and version - GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)] (__novec_makecontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S - (__setcontext): Upgrade to restore Altivec regs and version - GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)] (__novec_setcontext): - Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S - (__swapcontext): Upgrade to swap Altivec regs and version GLIBC_2_3_4. - [SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4)] - (__novec_swapcontext): Compatible with GLIBC_2.3.3 release. - * sysdeps/unix/sysv/linux/powerpc/powerpc32/ucontext_i.h: - (_UC_VSCR, _UC_VRSAVE): Define. - (_FRAME_BACKCHAIN, _FRAME_LR_SAVE,_FRAME_PARM_SAVE1,_FRAME_PARM_SAVE2, - _FRAME_PARM_SAVE3, _FRAME_PARM_SAVE4): Defined. 2004-01-15 Ulrich Drepper @@ -479,23 +409,6 @@ 2004-01-13 Richard Henderson - * Versions.def (libm): Add GLIBC_2.3.3. - * sysdeps/alpha/fpu/Versions: Add __c1_c*f and c*f to GLIBC_2.3.3. - * sysdeps/alpha/fpu/cabsf.c, sysdeps/alpha/fpu/cargf.c, - sysdeps/alpha/fpu/cfloat-compat.h, sysdeps/alpha/fpu/cimagf.c, - sysdeps/alpha/fpu/conjf.c, sysdeps/alpha/fpu/crealf.c, - sysdeps/alpha/fpu/s_cacosf.c, sysdeps/alpha/fpu/s_cacoshf.c, - sysdeps/alpha/fpu/s_casinf.c, sysdeps/alpha/fpu/s_casinhf.c, - sysdeps/alpha/fpu/s_catanf.c, sysdeps/alpha/fpu/s_catanhf.c, - sysdeps/alpha/fpu/s_ccosf.c, sysdeps/alpha/fpu/s_ccoshf.c, - sysdeps/alpha/fpu/s_cexpf.c, sysdeps/alpha/fpu/s_clog10f.c, - sysdeps/alpha/fpu/s_clogf.c, sysdeps/alpha/fpu/s_cpowf.c, - sysdeps/alpha/fpu/s_cprojf.c, sysdeps/alpha/fpu/s_csinf.c, - sysdeps/alpha/fpu/s_csinhf.c, sysdeps/alpha/fpu/s_csqrtf.c, - sysdeps/alpha/fpu/s_ctanf.c, sysdeps/alpha/fpu/s_ctanhf.c: New files. - * sysdeps/alpha/fpu/bits/mathdef.h: Rename complex float - functions for gcc 3.3. - * sysdeps/generic/s_cacosf.c, sysdeps/generic/s_cacoshf.c, sysdeps/generic/s_casinf.c, sysdeps/generic/s_casinhf.c, sysdeps/generic/s_catanf.c, sysdeps/generic/s_catanhf.c, diff -uNr glibc-2.3-20040205-2105/Versions.def glibc-2.3.3-lfs/Versions.def --- glibc-2.3-20040205-2105/Versions.def 2004-01-24 08:08:08.000000000 +1100 +++ glibc-2.3.3-lfs/Versions.def 2004-01-13 20:08:02.000000000 +1100 @@ -19,7 +19,6 @@ GLIBC_2.3.1 GLIBC_2.3.2 GLIBC_2.3.3 - GLIBC_2.3.4 %ifdef USE_IN_LIBIO HURD_CTHREADS_0.3 %endif @@ -41,7 +40,7 @@ GLIBC_2.1 GLIBC_2.2 GLIBC_2.2.3 - GLIBC_2.3.4 + GLIBC_2.3.3 } libnsl { GLIBC_2.0 diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/Versions glibc-2.3.3-lfs/sysdeps/alpha/fpu/Versions --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/Versions 2004-01-24 08:08:08.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/Versions 1998-07-03 08:33:14.000000000 +1000 @@ -4,20 +4,3 @@ __ieee_get_fp_control; __ieee_set_fp_control; } } -libm { - GLIBC_2.3.4 { - # functions implementing old complex float abi - __c1_cabsf; __c1_cacosf; __c1_cacoshf; __c1_cargf; __c1_casinf; - __c1_casinhf; __c1_catanf; __c1_catanhf; __c1_ccosf; __c1_ccoshf; - __c1_cexpf; __c1_cimagf; __c1_clog10f; __c1_clogf; __c1_conjf; - __c1_cpowf; __c1_cprojf; __c1_crealf; __c1_csinf; __c1_csinhf; - __c1_csqrtf; __c1_ctanf; __c1_ctanhf; - - # functions implementing new complex float abi - cabsf; cacosf; cacoshf; cargf; casinf; - casinhf; catanf; catanhf; ccosf; ccoshf; - cexpf; cimagf; clog10f; clogf; conjf; - cpowf; cprojf; crealf; csinf; csinhf; - csqrtf; ctanf; ctanhf; - } -} diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/bits/mathdef.h glibc-2.3.3-lfs/sysdeps/alpha/fpu/bits/mathdef.h --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/bits/mathdef.h 2004-01-13 20:15:58.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/bits/mathdef.h 2003-04-09 17:39:17.000000000 +1000 @@ -61,34 +61,10 @@ # define FP_ILOGB0 (-2147483647) # define FP_ILOGBNAN (2147483647) -#endif /* ISO C99 && MATH_H */ +#endif /* ISO C99 */ #ifndef __NO_LONG_DOUBLE_MATH /* Signal that we do not really have a `long double'. The disables the declaration of all the `long double' function variants. */ # define __NO_LONG_DOUBLE_MATH 1 #endif - -#if defined _COMPLEX_H && !defined _COMPLEX_H_MATHDEF -# define _COMPLEX_H_MATHDEF 1 -# if defined(__GNUC__) && !__GNUC_PREREQ(3,4) - -/* Due to an ABI change, we need to remap the complex float symbols. */ -# define _Mdouble_ float -# define __MATHCALL(function, args) \ - __MATHDECL (_Complex float, function, args) -# define __MATHDECL(type, function, args) \ - __MATHDECL_1(type, function##f, args, __c1_##function##f); \ - __MATHDECL_1(type, __##function##f, args, __c1_##function##f) -# define __MATHDECL_1(type, function, args, alias) \ - extern type function args __asm__(#alias) __THROW - -# include - -# undef _Mdouble_ -# undef __MATHCALL -# undef __MATHDECL -# undef __MATHDECL_1 - -# endif /* GNUC before 3.4 */ -#endif /* COMPLEX_H */ diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cabsf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/cabsf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cabsf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/cabsf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,42 +0,0 @@ -/* Return the complex absolute value of float complex value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cabsf __cabsf_not_defined -#define cabsf cabsf_not_defined - -#include -#include -#include "cfloat-compat.h" - -#undef __cabsf -#undef cabsf - -float -__c1_cabsf (c1_cfloat_decl (z)) -{ - return __hypotf (c1_cfloat_real (z), c1_cfloat_imag (z)); -} - -float -__c2_cabsf (c2_cfloat_decl (z)) -{ - return __hypotf (c2_cfloat_real (z), c2_cfloat_imag (z)); -} - -cfloat_versions (cabsf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cargf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/cargf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cargf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/cargf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,42 +0,0 @@ -/* Compute argument of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cargf __cargf_not_defined -#define cargf cargf_not_defined - -#include -#include -#include "cfloat-compat.h" - -#undef __cargf -#undef cargf - -float -__c1_cargf (c1_cfloat_decl (x)) -{ - return __atan2f (c1_cfloat_imag (x), c1_cfloat_real (x)); -} - -float -__c2_cargf (c2_cfloat_decl (x)) -{ - return __atan2f (c2_cfloat_imag (x), c2_cfloat_real (x)); -} - -cfloat_versions (cargf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cfloat-compat.h glibc-2.3.3-lfs/sysdeps/alpha/fpu/cfloat-compat.h --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cfloat-compat.h 2004-01-24 08:08:08.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/cfloat-compat.h 1970-01-01 10:00:00.000000000 +1000 @@ -1,74 +0,0 @@ -/* Compatibility macros for old and new Alpha complex float ABI. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -/* The behaviour of complex float changed between GCC 3.3 and 3.4. - - In 3.3 and before (below, complex version 1, or "c1"), complex float - values were packed into one floating point register. - - In 3.4 and later (below, complex version 2, or "c2"), GCC changed to - follow the official Tru64 ABI, which passes the components of a complex - as separate parameters. */ - -#if __GNUC_PREREQ(3,4) - typedef union { double d; _Complex float cf; } c1_compat; -# define c1_cfloat_decl(x) double x -# define c1_cfloat_real(x) __real__ c1_cfloat_value (x) -# define c1_cfloat_imag(x) __imag__ c1_cfloat_value (x) -# define c1_cfloat_value(x) (((c1_compat *)(void *)&x)->cf) -# define c1_cfloat_rettype double -# define c1_cfloat_return(x) ({ c1_compat _; _.cf = (x); _.d; }) -# define c2_cfloat_decl(x) _Complex float x -# define c2_cfloat_real(x) __real__ x -# define c2_cfloat_imag(x) __imag__ x -# define c2_cfloat_value(x) x -# define c2_cfloat_rettype _Complex float -# define c2_cfloat_return(x) x -#else -# define c1_cfloat_decl(x) _Complex float x -# define c1_cfloat_real(x) __real__ x -# define c1_cfloat_imag(x) __imag__ x -# define c1_cfloat_value(x) x -# define c1_cfloat_rettype _Complex float -# define c1_cfloat_return(x) x -# define c2_cfloat_decl(x) float x ## r, float x ## i -# define c2_cfloat_real(x) x ## r -# define c2_cfloat_imag(x) x ## i -# define c2_cfloat_value(x) \ - ({ _Complex float _; __real__ _ = x##r; __imag__ _ = x##i; _; }) -# define c2_cfloat_rettype double _Complex -# define c2_cfloat_return(x) x -#endif - -/* Get the proper symbol versions defined for each function. */ - -#include - -#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_3_4) -#define cfloat_versions_compat(func) \ - compat_symbol (libm, __c1_##func, func, GLIBC_2_1) -#else -#define cfloat_versions_compat(func) -#endif - -#define cfloat_versions(func) \ - cfloat_versions_compat(func); \ - versioned_symbol (libm, __c2_##func, func, GLIBC_2_3_4); \ - extern typeof(__c2_##func) __##func attribute_hidden; \ - strong_alias (__c2_##func, __##func) diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cimagf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/cimagf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/cimagf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/cimagf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,41 +0,0 @@ -/* Return imaginary part of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cimagf __cimagf_not_defined -#define cimagf cimagf_not_defined - -#include -#include "cfloat-compat.h" - -#undef __cimagf -#undef cimagf - -float -__c1_cimagf (c1_cfloat_decl (z)) -{ - return c1_cfloat_imag (z); -} - -float -__c2_cimagf (c2_cfloat_decl (z)) -{ - return c2_cfloat_imag (z); -} - -cfloat_versions (cimagf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/conjf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/conjf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/conjf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/conjf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,43 +0,0 @@ -/* Return complex conjugate of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __conjf __conjf_not_defined -#define conjf conjf_not_defined - -#include -#include "cfloat-compat.h" - -#undef __conjf -#undef conjf - -c1_cfloat_rettype -__c1_conjf (c1_cfloat_decl (z)) -{ - _Complex float r = ~ c1_cfloat_value (z); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_conjf (c2_cfloat_decl (z)) -{ - _Complex float r = ~ c2_cfloat_value (z); - return c2_cfloat_return (r); -} - -cfloat_versions (conjf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/crealf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/crealf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/crealf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/crealf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,41 +0,0 @@ -/* Return real part of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __crealf __crealf_not_defined -#define crealf crealf_not_defined - -#include -#include "cfloat-compat.h" - -#undef __crealf -#undef crealf - -float -__c1_crealf (c1_cfloat_decl (z)) -{ - return c1_cfloat_real (z); -} - -float -__c2_crealf (c2_cfloat_decl (z)) -{ - return c2_cfloat_real (z); -} - -cfloat_versions (crealf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cacosf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cacosf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cacosf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cacosf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc cosine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cacosf __cacosf_not_defined -#define cacosf cacosf_not_defined - -#include -#include - -#undef __cacosf -#undef cacosf -#define __cacosf internal_cacosf - -static _Complex float internal_cacosf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __cacosf - -c1_cfloat_rettype -__c1_cacosf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_cacosf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_cacosf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_cacosf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (cacosf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cacoshf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cacoshf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cacoshf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cacoshf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc hyperbole cosine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cacoshf __cacoshf_not_defined -#define cacoshf cacoshf_not_defined - -#include -#include - -#undef __cacoshf -#undef cacoshf -#define __cacoshf internal_cacoshf - -static _Complex float internal_cacoshf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __cacoshf - -c1_cfloat_rettype -__c1_cacoshf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_cacoshf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_cacoshf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_cacoshf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (cacoshf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_casinf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_casinf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_casinf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_casinf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc sine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __casinf __casinf_not_defined -#define casinf casinf_not_defined - -#include -#include - -#undef __casinf -#undef casinf -#define __casinf internal_casinf - -static _Complex float internal_casinf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __casinf - -c1_cfloat_rettype -__c1_casinf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_casinf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_casinf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_casinf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (casinf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_casinhf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_casinhf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_casinhf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_casinhf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc hyperbole sine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __casinhf __casinhf_not_defined -#define casinhf casinhf_not_defined - -#include -#include - -#undef __casinhf -#undef casinhf -#define __casinhf internal_casinhf - -static _Complex float internal_casinhf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __casinhf - -c1_cfloat_rettype -__c1_casinhf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_casinhf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_casinhf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_casinhf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (casinhf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_catanf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_catanf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_catanf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_catanf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc tangent of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __catanf __catanf_not_defined -#define catanf catanf_not_defined - -#include -#include - -#undef __catanf -#undef catanf -#define __catanf internal_catanf - -static _Complex float internal_catanf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __catanf - -c1_cfloat_rettype -__c1_catanf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_catanf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_catanf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_catanf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (catanf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_catanhf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_catanhf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_catanhf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_catanhf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return arc hyperbole tangent of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __catanhf __catanhf_not_defined -#define catanhf catanhf_not_defined - -#include -#include - -#undef __catanhf -#undef catanhf -#define __catanhf internal_catanhf - -static _Complex float internal_catanhf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __catanhf - -c1_cfloat_rettype -__c1_catanhf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_catanhf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_catanhf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_catanhf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (catanhf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ccosf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ccosf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ccosf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ccosf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return cosine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __ccosf __ccosf_not_defined -#define ccosf ccosf_not_defined - -#include -#include - -#undef __ccosf -#undef ccosf -#define __ccosf internal_ccosf - -static _Complex float internal_ccosf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __ccosf - -c1_cfloat_rettype -__c1_ccosf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_ccosf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_ccosf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_ccosf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (ccosf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ccoshf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ccoshf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ccoshf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ccoshf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return hyperbole cosine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __ccoshf __ccoshf_not_defined -#define ccoshf ccoshf_not_defined - -#include -#include - -#undef __ccoshf -#undef ccoshf -#define __ccoshf internal_ccoshf - -static _Complex float internal_ccoshf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __ccoshf - -c1_cfloat_rettype -__c1_ccoshf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_ccoshf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_ccoshf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_ccoshf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (ccoshf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cexpf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cexpf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cexpf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cexpf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return exponent of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cexpf __cexpf_not_defined -#define cexpf cexpf_not_defined - -#include -#include - -#undef __cexpf -#undef cexpf -#define __cexpf internal_cexpf - -static _Complex float internal_cexpf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __cexpf - -c1_cfloat_rettype -__c1_cexpf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_cexpf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_cexpf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_cexpf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (cexpf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_clog10f.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_clog10f.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_clog10f.c 2004-01-24 08:08:08.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_clog10f.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,61 +0,0 @@ -/* Return base 10 logarithm of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __clog10f __clog10f_not_defined -#define clog10f clog10f_not_defined - -#include -#include - -#undef __clog10f -#undef clog10f -#define __clog10f internal_clog10f - -static _Complex float internal_clog10f (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __clog10f - -c1_cfloat_rettype -__c1_clog10f (c1_cfloat_decl (x)) -{ - _Complex float r = internal_clog10f (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_clog10f (c2_cfloat_decl (x)) -{ - _Complex float r = internal_clog10f (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -/* Ug. __clog10f was exported from GLIBC_2.1. This is the only - complex function whose double-underscore symbol was exported, - so we get to handle that specially. */ -#if SHLIB_COMPAT (libm, GLIBC_2_1, GLIBC_2_3_4) -strong_alias (__c1_clog10f, __c1_clog10f_2); -compat_symbol (libm, __c1_clog10f, clog10f, GLIBC_2_1); -compat_symbol (libm, __c1_clog10f_2, __clog10f, GLIBC_2_1); -#endif -versioned_symbol (libm, __c2_clog10f, clog10f, GLIBC_2_3_4); -extern typeof(__c2_clog10f) __clog10f attribute_hidden; -strong_alias (__c2_clog10f, __clog10f) diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_clogf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_clogf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_clogf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_clogf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return natural logarithm of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __clogf __clogf_not_defined -#define clogf clogf_not_defined - -#include -#include - -#undef __clogf -#undef clogf -#define __clogf internal_clogf - -static _Complex float internal_clogf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __clogf - -c1_cfloat_rettype -__c1_clogf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_clogf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_clogf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_clogf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (clogf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cpowf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cpowf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cpowf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cpowf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return power of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cpowf __cpowf_not_defined -#define cpowf cpowf_not_defined - -#include -#include - -#undef __cpowf -#undef cpowf -#define __cpowf internal_cpowf - -static _Complex float internal_cpowf (_Complex float x, _Complex float c); - -#include -#include "cfloat-compat.h" - -#undef __cpowf - -c1_cfloat_rettype -__c1_cpowf (c1_cfloat_decl (x), c1_cfloat_decl (c)) -{ - _Complex float r = internal_cpowf (c1_cfloat_value (x), c1_cfloat_value (c)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_cpowf (c2_cfloat_decl (x), c2_cfloat_decl (c)) -{ - _Complex float r = internal_cpowf (c2_cfloat_value (x), c2_cfloat_value (c)); - return c2_cfloat_return (r); -} - -cfloat_versions (cpowf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cprojf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cprojf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_cprojf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_cprojf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return projection of complex float value to Riemann sphere. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __cprojf __cprojf_not_defined -#define cprojf cprojf_not_defined - -#include -#include - -#undef __cprojf -#undef cprojf -#define __cprojf internal_cprojf - -static _Complex float internal_cprojf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __cprojf - -c1_cfloat_rettype -__c1_cprojf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_cprojf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_cprojf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_cprojf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (cprojf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csinf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csinf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csinf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csinf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return sine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __csinf __csinf_not_defined -#define csinf csinf_not_defined - -#include -#include - -#undef __csinf -#undef csinf -#define __csinf internal_csinf - -static _Complex float internal_csinf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __csinf - -c1_cfloat_rettype -__c1_csinf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_csinf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_csinf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_csinf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (csinf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csinhf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csinhf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csinhf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csinhf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return hyperbole sine of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __csinhf __csinhf_not_defined -#define csinhf csinhf_not_defined - -#include -#include - -#undef __csinhf -#undef csinhf -#define __csinhf internal_csinhf - -static _Complex float internal_csinhf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __csinhf - -c1_cfloat_rettype -__c1_csinhf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_csinhf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_csinhf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_csinhf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (csinhf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csqrtf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csqrtf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_csqrtf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_csqrtf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return square root of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __csqrtf __csinhf_not_defined -#define csqrtf csqrtf_not_defined - -#include -#include - -#undef __csqrtf -#undef csqrtf -#define __csqrtf internal_csqrtf - -static _Complex float internal_csqrtf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __csqrtf - -c1_cfloat_rettype -__c1_csqrtf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_csqrtf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_csqrtf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_csqrtf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (csqrtf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ctanf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ctanf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ctanf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ctanf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return tangent of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __ctanf __ctanf_not_defined -#define ctanf ctanf_not_defined - -#include -#include - -#undef __ctanf -#undef ctanf -#define __ctanf internal_ctanf - -static _Complex float internal_ctanf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __ctanf - -c1_cfloat_rettype -__c1_ctanf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_ctanf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_ctanf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_ctanf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (ctanf); diff -uNr glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ctanhf.c glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ctanhf.c --- glibc-2.3-20040205-2105/sysdeps/alpha/fpu/s_ctanhf.c 2004-01-13 20:08:04.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/alpha/fpu/s_ctanhf.c 1970-01-01 10:00:00.000000000 +1000 @@ -1,51 +0,0 @@ -/* Return hyperbole tangent of complex float value. - Copyright (C) 2004 Free Software Foundation, Inc. - This file is part of the GNU C Library. - - The GNU C Library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - The GNU C Library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with the GNU C Library; if not, write to the Free - Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA - 02111-1307 USA. */ - -#define __ctanhf __ctanhf_not_defined -#define ctanhf ctanhf_not_defined - -#include -#include - -#undef __ctanhf -#undef ctanhf -#define __ctanhf internal_ctanhf - -static _Complex float internal_ctanhf (_Complex float x); - -#include -#include "cfloat-compat.h" - -#undef __ctanhf - -c1_cfloat_rettype -__c1_ctanhf (c1_cfloat_decl (x)) -{ - _Complex float r = internal_ctanhf (c1_cfloat_value (x)); - return c1_cfloat_return (r); -} - -c2_cfloat_rettype -__c2_ctanhf (c2_cfloat_decl (x)) -{ - _Complex float r = internal_ctanhf (c2_cfloat_value (x)); - return c2_cfloat_return (r); -} - -cfloat_versions (ctanhf); diff -uNr glibc-2.3-20040205-2105/sysdeps/powerpc/Makefile glibc-2.3.3-lfs/sysdeps/powerpc/Makefile --- glibc-2.3-20040205-2105/sysdeps/powerpc/Makefile 2004-01-16 15:42:35.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/powerpc/Makefile 2002-09-05 19:50:08.000000000 +1000 @@ -17,8 +17,3 @@ # extra shared linker files to link only into dl-allobjs.so sysdep-rtld-routines += dl-machine endif - -ifeq ($(subdir),csu) -# get offset to rtld_global._dl_hwcap -gen-as-const-headers += rtld-global-offsets.sym -endif diff -uNr glibc-2.3-20040205-2105/sysdeps/powerpc/elf/rtld-global-offsets.sym glibc-2.3.3-lfs/sysdeps/powerpc/elf/rtld-global-offsets.sym --- glibc-2.3-20040205-2105/sysdeps/powerpc/elf/rtld-global-offsets.sym 2004-01-16 15:43:46.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/powerpc/elf/rtld-global-offsets.sym 1970-01-01 10:00:00.000000000 +1000 @@ -1,7 +0,0 @@ -#define SHARED 1 - -#include - -#define rtdl_global_offsetof(mem) offsetof (struct rtld_global, mem) - -RTLD_GLOBAL_DL_HWCAP_OFFSET rtdl_global_offsetof (_dl_hwcap) diff -uNr glibc-2.3-20040205-2105/sysdeps/powerpc/sysdep.h glibc-2.3.3-lfs/sysdeps/powerpc/sysdep.h --- glibc-2.3-20040205-2105/sysdeps/powerpc/sysdep.h 2004-01-16 15:43:07.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/powerpc/sysdep.h 2002-09-21 09:44:55.000000000 +1000 @@ -100,42 +100,6 @@ #define cr6 6 #define cr7 7 -/* Vector registers. */ -#define v0 0 -#define v1 1 -#define v2 2 -#define v3 3 -#define v4 4 -#define v5 5 -#define v6 6 -#define v7 7 -#define v8 8 -#define v9 9 -#define v10 10 -#define v11 11 -#define v12 12 -#define v13 13 -#define v14 14 -#define v15 15 -#define v16 16 -#define v17 17 -#define v18 18 -#define v19 19 -#define v20 20 -#define v21 21 -#define v22 22 -#define v23 23 -#define v24 24 -#define v25 25 -#define v26 26 -#define v27 27 -#define v28 28 -#define v29 29 -#define v30 30 -#define v31 31 - -#define VRSAVE 256 - #ifdef __ELF__ @@ -147,18 +111,5 @@ #endif /* __ELF__ */ -/* - * Powerpc Feature masks for the Aux Vector Hardware Capabilities (AT_HWCAP). - * This entry is copied to _dl_hwcap or rtld_global._dl_hwcap during startup. - * The following must match the kernels linux/asm/cputable.h. - */ -#define PPC_FEATURE_32 0x80000000 /* 32-bit mode. */ -#define PPC_FEATURE_64 0x40000000 /* 64-bit mode. */ -#define PPC_FEATURE_601_INSTR 0x20000000 /* 601 chip, Old POWER ISA. */ -#define PPC_FEATURE_HAS_ALTIVEC 0x10000000 /* SIMD/Vector Unit. */ -#define PPC_FEATURE_HAS_FPU 0x08000000 /* Floating Point Unit. */ -#define PPC_FEATURE_HAS_MMU 0x04000000 /* Memory Management Unit. */ -#define PPC_FEATURE_HAS_4xxMAC 0x02000000 /* 4xx Multiply Accumulator. */ -#define PPC_FEATURE_UNIFIED_CACHE 0x01000000 /* Unified I/D cache. */ #endif /* __ASSEMBLER__ */ diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions 2004-01-16 15:45:46.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/Versions 2003-09-24 13:20:36.000000000 +1000 @@ -24,7 +24,4 @@ posix_fadvise64; posix_fallocate64; setcontext; getcontext; swapcontext; makecontext; } - GLIBC_2.3.4 { - setcontext; getcontext; swapcontext; makecontext; - } } diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S 2004-01-16 15:46:49.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S 2003-09-24 13:21:29.000000000 +1000 @@ -1,5 +1,5 @@ /* Save current context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,7 +18,6 @@ 02111-1307 USA. */ #include -#include #include #define __ASSEMBLY__ @@ -26,231 +25,6 @@ #include "ucontext_i.h" ENTRY(__getcontext) - stw r3,_FRAME_PARM_SAVE1(r1) - addi r3,r3,_UC_REG_SPACE+12 - clrrwi r3,r3,4 - stw r0,_UC_GREGS+(PT_R0*4)(r3) - mflr r0 - stw r1,_UC_GREGS+(PT_R1*4)(r3) - stwu r1,-16(r1) - stw r0,_UC_GREGS+(PT_LNK*4)(r3) - stw r0,_UC_GREGS+(PT_NIP*4)(r3) - stw r0,_FRAME_LR_SAVE+16(r1) - stw r2,_UC_GREGS+(PT_R2*4)(r3) - stw r4,_UC_GREGS+(PT_R4*4)(r3) - stw r5,_UC_GREGS+(PT_R5*4)(r3) - stw r6,_UC_GREGS+(PT_R6*4)(r3) - stw r7,_UC_GREGS+(PT_R7*4)(r3) - stw r8,_UC_GREGS+(PT_R8*4)(r3) - stw r9,_UC_GREGS+(PT_R9*4)(r3) - stw r10,_UC_GREGS+(PT_R10*4)(r3) - stw r11,_UC_GREGS+(PT_R11*4)(r3) - stw r12,_UC_GREGS+(PT_R12*4)(r3) - stw r13,_UC_GREGS+(PT_R13*4)(r3) - stw r14,_UC_GREGS+(PT_R14*4)(r3) - stw r15,_UC_GREGS+(PT_R15*4)(r3) - stw r16,_UC_GREGS+(PT_R16*4)(r3) - stw r17,_UC_GREGS+(PT_R17*4)(r3) - stw r18,_UC_GREGS+(PT_R18*4)(r3) - stw r19,_UC_GREGS+(PT_R19*4)(r3) - stw r20,_UC_GREGS+(PT_R20*4)(r3) - stw r21,_UC_GREGS+(PT_R21*4)(r3) - stw r22,_UC_GREGS+(PT_R22*4)(r3) - stw r23,_UC_GREGS+(PT_R23*4)(r3) - stw r24,_UC_GREGS+(PT_R24*4)(r3) - stw r25,_UC_GREGS+(PT_R25*4)(r3) - stw r26,_UC_GREGS+(PT_R26*4)(r3) - stw r27,_UC_GREGS+(PT_R27*4)(r3) - stw r28,_UC_GREGS+(PT_R28*4)(r3) - stw r29,_UC_GREGS+(PT_R29*4)(r3) - stw r30,_UC_GREGS+(PT_R30*4)(r3) - stw r31,_UC_GREGS+(PT_R31*4)(r3) - mfctr r0 - stw r0,_UC_GREGS+(PT_CTR*4)(r3) - mfxer r0 - stw r0,_UC_GREGS+(PT_XER*4)(r3) - mfcr r0 - stw r0,_UC_GREGS+(PT_CCR*4)(r3) - - /* Set the return value of getcontext to "success". R3 is the only - register whose value is not preserved in the saved context. */ - li r0,0 - stw r0,_UC_GREGS+(PT_R3*4)(r3) - - /* Zero fill fields that can't be set in user state. */ - stw r0,_UC_GREGS+(PT_MSR*4)(r3) - stw r0,_UC_GREGS+(PT_MQ*4)(r3) - - /* Save the floating-point registers */ - stfd fp0,_UC_FREGS+(0*8)(r3) - stfd fp1,_UC_FREGS+(1*8)(r3) - stfd fp2,_UC_FREGS+(2*8)(r3) - stfd fp3,_UC_FREGS+(3*8)(r3) - stfd fp4,_UC_FREGS+(4*8)(r3) - stfd fp5,_UC_FREGS+(5*8)(r3) - stfd fp6,_UC_FREGS+(6*8)(r3) - stfd fp7,_UC_FREGS+(7*8)(r3) - stfd fp8,_UC_FREGS+(8*8)(r3) - stfd fp9,_UC_FREGS+(9*8)(r3) - stfd fp10,_UC_FREGS+(10*8)(r3) - stfd fp11,_UC_FREGS+(11*8)(r3) - stfd fp12,_UC_FREGS+(12*8)(r3) - stfd fp13,_UC_FREGS+(13*8)(r3) - stfd fp14,_UC_FREGS+(14*8)(r3) - stfd fp15,_UC_FREGS+(15*8)(r3) - stfd fp16,_UC_FREGS+(16*8)(r3) - stfd fp17,_UC_FREGS+(17*8)(r3) - stfd fp18,_UC_FREGS+(18*8)(r3) - stfd fp19,_UC_FREGS+(19*8)(r3) - stfd fp20,_UC_FREGS+(20*8)(r3) - stfd fp21,_UC_FREGS+(21*8)(r3) - stfd fp22,_UC_FREGS+(22*8)(r3) - stfd fp23,_UC_FREGS+(23*8)(r3) - stfd fp24,_UC_FREGS+(24*8)(r3) - stfd fp25,_UC_FREGS+(25*8)(r3) - stfd fp26,_UC_FREGS+(26*8)(r3) - stfd fp27,_UC_FREGS+(27*8)(r3) - stfd fp28,_UC_FREGS+(28*8)(r3) - stfd fp29,_UC_FREGS+(29*8)(r3) - mffs fp0 - stfd fp30,_UC_FREGS+(30*8)(r3) - stfd fp31,_UC_FREGS+(31*8)(r3) - stfd fp0,_UC_FREGS+(32*8)(r3) - -#ifdef PIC - mflr r8 - bl _GLOBAL_OFFSET_TABLE_@local-4 - mflr r7 -#ifdef SHARED - lwz r7,_rtld_global@got(r7) - mtlr r8 - lwz r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7) -#else - lwz r7,_dl_hwcap@got(r7) - mtlr r8 - lwz r7,0(r7) -#endif -#else - lis r7,_dl_hwcap@ha - lwz r7,_dl_hwcap@l(r7) -#endif - andis. r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(no_vec) - - la r10,(_UC_VREGS)(r3) - la r9,(_UC_VREGS+16)(r3) - - stvx v0,0,r10 - stvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v2,0,r10 - stvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v4,0,r10 - stvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v6,0,r10 - stvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v8,0,r10 - stvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v12,0,r10 - stvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v14,0,r10 - stvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v16,0,r10 - stvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v18,0,r10 - stvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - stvx v20,0,r10 - stvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v22,0,r10 - stvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v24,0,r10 - stvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v26,0,r10 - stvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v28,0,r10 - stvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v30,0,r10 - stvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mfvscr v0 - mfspr r0,VRSAVE - stvx v0,0,r10 - sync - stw r0,0(r10) - -L(no_vec): -/* Restore ucontext (parm1) from stack. */ - lwz r12,_FRAME_PARM_SAVE1+16(r1) - li r4,0 - stw r3,_UC_REGS_PTR(r12) - addi r5,r12,_UC_SIGMASK - li r3,SIG_BLOCK - bl JUMPTARGET(sigprocmask) - - lwz r0,_FRAME_LR_SAVE+16(r1) - addi r1,r1,16 - mtlr r0 - blr -PSEUDO_END(__getcontext) - -versioned_symbol (libc, __getcontext, getcontext, GLIBC_2_3_4) - -#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) - -ENTRY(__novec_getcontext) /* * Since we are not attempting to save the altivec registers, * there is no need to get the register storage space @@ -345,7 +119,7 @@ stfd fp30,_UC_FREGS+(30*8)(r3) stfd fp31,_UC_FREGS+(31*8)(r3) stfd fp0,_UC_FREGS+(32*8)(r3) - + addi r5,r3,_UC_SIGMASK - _UC_REG_SPACE li r4,0 li r3,SIG_BLOCK @@ -355,11 +129,9 @@ addi r1,r1,16 mtlr r0 blr -PSEUDO_END(__novec_getcontext) - -compat_symbol (libc, __novec_getcontext, getcontext, GLIBC_2_3_3) +PSEUDO_END(__getcontext) -#endif +versioned_symbol (libc, __getcontext, getcontext, GLIBC_2_3_3) #if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_3_3) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S 2004-01-16 15:47:50.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/makecontext.S 2003-09-24 13:21:29.000000000 +1000 @@ -1,5 +1,5 @@ /* Set up a context to call a function. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 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 @@ -26,8 +26,7 @@ ENTRY(__makecontext) /* Set up the first 7 args to the function in its registers */ - addi r11,r3,_UC_REG_SPACE+12 - clrrwi r11,r11,4 + addi r11,r3,_UC_REG_SPACE stw r11,_UC_REGS_PTR(r3) stw r6,_UC_GREGS+(PT_R3*4)(r11) stw r7,_UC_GREGS+(PT_R4*4)(r11) @@ -107,94 +106,7 @@ END(__makecontext) -versioned_symbol (libc, __makecontext, makecontext, GLIBC_2_3_4) - -#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) - -ENTRY(__novec_makecontext) - /* Set up the first 7 args to the function in its registers */ - addi r11,r3,_UC_REG_SPACE - stw r11,_UC_REGS_PTR(r3) - stw r6,_UC_GREGS+(PT_R3*4)(r11) - stw r7,_UC_GREGS+(PT_R4*4)(r11) - stw r8,_UC_GREGS+(PT_R5*4)(r11) - stw r9,_UC_GREGS+(PT_R6*4)(r11) - stw r10,_UC_GREGS+(PT_R7*4)(r11) - lwz r8,8(r1) - lwz r9,12(r1) - stw r8,_UC_GREGS+(PT_R8*4)(r11) - stw r9,_UC_GREGS+(PT_R9*4)(r11) - - /* Set the NIP to the start of the function */ - stw r4,_UC_GREGS+(PT_NIP*4)(r11) - - /* Set the function's r31 to ucp->uc_link for the exitcode below. */ - lwz r7,_UC_LINK(r3) - stw r7,_UC_GREGS+(PT_R31*4)(r11) - - /* Set the function's LR to point to the exitcode below. */ -#ifdef PIC - mflr r0 - bl 1f -1: mflr r6 - addi r6,r6,L(novec_exitcode)-1b - mtlr r0 -#else - lis r6,L(novec_exitcode)@ha - addi r6,r6,L(novec_exitcode)@l -#endif - stw r6,_UC_GREGS+(PT_LNK*4)(r11) - - /* - * Set up the stack frame for the function. - * If we have more than 5 args to the function (8 args to makecontext), - * there will be some arguments on the stack which have to end up - * in registers. If there are more than 8 args to the function, - * we have to copy (argc - 8) args from our stack to the functions' - * stack (and allow space for them in the frame). - */ - lwz r4,_UC_STACK_SP(r3) - lwz r8,_UC_STACK_SIZE(r3) - add r4,r4,r8 - rlwinm r4,r4,0,0,27 /* round down to 16-byte boundary */ - addi r7,r4,-16 /* stack frame for fn's caller */ - cmpwi r5,8 - blt 2f /* less than 8 args is easy */ - lwz r10,16(r1) - stw r10,_UC_GREGS+(PT_R10*4)(r11) - beq 2f /* if exactly 8 args */ - subi r9,r5,3 - subi r5,r5,8 - rlwinm r9,r9,2,0,27 - subf r7,r9,r4 - mtctr r5 /* copy the 9th and following args */ - addi r6,r1,16 - addi r8,r7,4 -3: lwzu r10,4(r6) - stwu r10,4(r8) - bdnz 3b -2: stw r7,_UC_GREGS+(PT_R1*4)(r11) - li r6,0 - stw r6,0(r7) - - blr - -/* - * If the function returns, it comes here. We put ucp->uc_link in - * r31, which is a callee-saved register. We have to continue with - * the context that r31 points to, or exit if it is 0. - */ -L(novec_exitcode): - mr. r3,r31 - beq 4f - bl JUMPTARGET(__novec_setcontext) -4: bl HIDDEN_JUMPTARGET(exit) - b 4b - -END(__makecontext) - -compat_symbol (libc, __novec_makecontext, makecontext, GLIBC_2_3_3) -#endif +versioned_symbol (libc, __makecontext, makecontext, GLIBC_2_3_3) #if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_3_3) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S 2004-01-16 15:48:29.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/setcontext.S 2003-09-24 13:21:29.000000000 +1000 @@ -1,5 +1,5 @@ /* Jump to a new context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,7 +18,6 @@ 02111-1307 USA. */ #include -#include #include #define __ASSEMBLY__ @@ -54,122 +53,7 @@ bl JUMPTARGET(sigprocmask) cmpwi r3,0 bne L(error_exit) - -#ifdef PIC - mflr r8 - bl _GLOBAL_OFFSET_TABLE_@local-4 - mflr r7 -#ifdef SHARED - lwz r7,_rtld_global@got(r7) - mtlr r8 - lwz r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7) -#else - lwz r7,_dl_hwcap@got(r7) - mtlr r8 - lwz r7,0(r7) -#endif -#else - lis r7,_dl_hwcap@ha - lwz r7,_dl_hwcap@l(r7) -#endif - andis. r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16) - la r10,(_UC_VREGS)(r31) - beq L(has_no_vec) - - lwz r0,(32*16)(r10) - li r9,(32*16) - cmpwi r0,0 - mtspr VRSAVE,r0 - beq L(has_no_vec) - - lvx v19,r9,r10 - la r9,(16)(r10) - - lvx v0,0,r10 - lvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mtvscr v19 - lvx v2,0,r10 - lvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v4,0,r10 - lvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v6,0,r10 - lvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v8,0,r10 - lvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v12,0,r10 - lvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v14,0,r10 - lvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v16,0,r10 - lvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v18,0,r10 - lvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - lvx v20,0,r10 - lvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v22,0,r10 - lvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v24,0,r10 - lvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v26,0,r10 - lvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v28,0,r10 - lvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v30,0,r10 - lvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - lvx v10,0,r10 - lvx v11,0,r9 - -L(has_no_vec): /* Restore the floating-point registers */ lfd fp31,_UC_FREGS+(32*8)(r31) lfd fp0,_UC_FREGS+(0*8)(r31) @@ -263,138 +147,9 @@ PSEUDO_END (__setcontext) -versioned_symbol (libc, __setcontext, setcontext, GLIBC_2_3_4) - -#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) - -ENTRY(__novec_setcontext) - mflr r0 - stwu r1,-16(r1) - stw r0,20(r1) - stw r31,12(r1) - lwz r31,_UC_REGS_PTR(r3) - - /* - * If this ucontext refers to the point where we were interrupted - * by a signal, we have to use the rt_sigreturn system call to - * return to the context so we get both LR and CTR restored. - * - * Otherwise, the context we are restoring is either just after - * a procedure call (getcontext/swapcontext) or at the beginning - * of a procedure call (makecontext), so we don't need to restore - * r0, xer, ctr. We don't restore r2 since it will be used as - * the TLS pointer. - */ - lwz r0,_UC_GREGS+(PT_MSR*4)(r31) - cmpwi r0,0 - bne L(novec_do_sigret) - - /* Restore the signal mask */ - li r5,0 - addi r4,r3,_UC_SIGMASK - li r3,SIG_SETMASK - bl JUMPTARGET(sigprocmask) - cmpwi r3,0 - bne L(novec_error_exit) - - /* Restore the floating-point registers */ - lfd fp31,_UC_FREGS+(32*8)(r31) - lfd fp0,_UC_FREGS+(0*8)(r31) - mtfsf 0xff,fp31 - lfd fp1,_UC_FREGS+(1*8)(r31) - lfd fp2,_UC_FREGS+(2*8)(r31) - lfd fp3,_UC_FREGS+(3*8)(r31) - lfd fp4,_UC_FREGS+(4*8)(r31) - lfd fp5,_UC_FREGS+(5*8)(r31) - lfd fp6,_UC_FREGS+(6*8)(r31) - lfd fp7,_UC_FREGS+(7*8)(r31) - lfd fp8,_UC_FREGS+(8*8)(r31) - lfd fp9,_UC_FREGS+(9*8)(r31) - lfd fp10,_UC_FREGS+(10*8)(r31) - lfd fp11,_UC_FREGS+(11*8)(r31) - lfd fp12,_UC_FREGS+(12*8)(r31) - lfd fp13,_UC_FREGS+(13*8)(r31) - lfd fp14,_UC_FREGS+(14*8)(r31) - lfd fp15,_UC_FREGS+(15*8)(r31) - lfd fp16,_UC_FREGS+(16*8)(r31) - lfd fp17,_UC_FREGS+(17*8)(r31) - lfd fp18,_UC_FREGS+(18*8)(r31) - lfd fp19,_UC_FREGS+(19*8)(r31) - lfd fp20,_UC_FREGS+(20*8)(r31) - lfd fp21,_UC_FREGS+(21*8)(r31) - lfd fp22,_UC_FREGS+(22*8)(r31) - lfd fp23,_UC_FREGS+(23*8)(r31) - lfd fp24,_UC_FREGS+(24*8)(r31) - lfd fp25,_UC_FREGS+(25*8)(r31) - lfd fp26,_UC_FREGS+(26*8)(r31) - lfd fp27,_UC_FREGS+(27*8)(r31) - lfd fp28,_UC_FREGS+(28*8)(r31) - lfd fp29,_UC_FREGS+(29*8)(r31) - lfd fp30,_UC_FREGS+(30*8)(r31) - lfd fp31,_UC_FREGS+(31*8)(r31) - - /* Restore LR and CCR, and set CTR to the NIP value */ - lwz r3,_UC_GREGS+(PT_LNK*4)(r31) - lwz r4,_UC_GREGS+(PT_NIP*4)(r31) - lwz r5,_UC_GREGS+(PT_CCR*4)(r31) - mtlr r3 - mtctr r4 - mtcr r5 - - /* Restore the general registers */ - lwz r1,_UC_GREGS+(PT_R1*4)(r31) - lwz r3,_UC_GREGS+(PT_R3*4)(r31) - lwz r4,_UC_GREGS+(PT_R4*4)(r31) - lwz r5,_UC_GREGS+(PT_R5*4)(r31) - lwz r6,_UC_GREGS+(PT_R6*4)(r31) - lwz r7,_UC_GREGS+(PT_R7*4)(r31) - lwz r8,_UC_GREGS+(PT_R8*4)(r31) - lwz r9,_UC_GREGS+(PT_R9*4)(r31) - lwz r10,_UC_GREGS+(PT_R10*4)(r31) - lwz r11,_UC_GREGS+(PT_R11*4)(r31) - lwz r12,_UC_GREGS+(PT_R12*4)(r31) - lwz r13,_UC_GREGS+(PT_R13*4)(r31) - lwz r14,_UC_GREGS+(PT_R14*4)(r31) - lwz r15,_UC_GREGS+(PT_R15*4)(r31) - lwz r16,_UC_GREGS+(PT_R16*4)(r31) - lwz r17,_UC_GREGS+(PT_R17*4)(r31) - lwz r18,_UC_GREGS+(PT_R18*4)(r31) - lwz r19,_UC_GREGS+(PT_R19*4)(r31) - lwz r20,_UC_GREGS+(PT_R20*4)(r31) - lwz r21,_UC_GREGS+(PT_R21*4)(r31) - lwz r22,_UC_GREGS+(PT_R22*4)(r31) - lwz r23,_UC_GREGS+(PT_R23*4)(r31) - lwz r24,_UC_GREGS+(PT_R24*4)(r31) - lwz r25,_UC_GREGS+(PT_R25*4)(r31) - lwz r26,_UC_GREGS+(PT_R26*4)(r31) - lwz r27,_UC_GREGS+(PT_R27*4)(r31) - lwz r28,_UC_GREGS+(PT_R28*4)(r31) - lwz r29,_UC_GREGS+(PT_R29*4)(r31) - lwz r30,_UC_GREGS+(PT_R30*4)(r31) - lwz r31,_UC_GREGS+(PT_R31*4)(r31) - - bctr - -L(novec_error_exit): - lwz r31,12(r1) - lwz r0,20(r1) - addi r1,r1,16 - mtlr r0 - blr - -L(novec_do_sigret): - addi r1,r3,-0xd0 - li r0,SYS_ify(rt_sigreturn) - sc - /* NOTREACHED */ - -PSEUDO_END (__setcontext) - -compat_symbol (libc, __novec_setcontext, setcontext, GLIBC_2_3_3) - -#endif +versioned_symbol (libc, __setcontext, setcontext, GLIBC_2_3_3) -#if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_3_3) +#if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_3_3) #define _ERRNO_H 1 #include @@ -404,6 +159,6 @@ b JUMPTARGET(__syscall_error) END (__setcontext_stub) -compat_symbol (libc, __setcontext_stub, setcontext, GLIBC_2_1) +compat_symbol (libc, __setcontext_stub, setcontext, GLIBC_2_0) #endif diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S 2004-01-16 15:49:11.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/swapcontext.S 2003-09-24 13:21:29.000000000 +1000 @@ -1,5 +1,5 @@ /* Save current context and jump to a new context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,7 +18,6 @@ 02111-1307 USA. */ #include -#include #include #define __ASSEMBLY__ @@ -27,454 +26,6 @@ ENTRY(__swapcontext) /* Save the current context */ - stw r3,_FRAME_PARM_SAVE1(r1) - addi r3,r3,_UC_REG_SPACE+12 - clrrwi r3,r3,4 - stw r0,_UC_GREGS+(PT_R0*4)(r3) - stw r1,_UC_GREGS+(PT_R1*4)(r3) - mflr r0 - stwu r1,-16(r1) - stw r0,20(r1) - stw r31,12(r1) - stw r31,_UC_GREGS+(PT_R31*4)(r3) - mr r31,r4 /* new context pointer */ - stw r0,_UC_GREGS+(PT_LNK*4)(r3) - stw r0,_UC_GREGS+(PT_NIP*4)(r3) - stw r2,_UC_GREGS+(PT_R2*4)(r3) - stw r4,_UC_GREGS+(PT_R4*4)(r3) - stw r5,_UC_GREGS+(PT_R5*4)(r3) - stw r6,_UC_GREGS+(PT_R6*4)(r3) - stw r7,_UC_GREGS+(PT_R7*4)(r3) - stw r8,_UC_GREGS+(PT_R8*4)(r3) - stw r9,_UC_GREGS+(PT_R9*4)(r3) - stw r10,_UC_GREGS+(PT_R10*4)(r3) - stw r11,_UC_GREGS+(PT_R11*4)(r3) - stw r12,_UC_GREGS+(PT_R12*4)(r3) - stw r13,_UC_GREGS+(PT_R13*4)(r3) - stw r14,_UC_GREGS+(PT_R14*4)(r3) - stw r15,_UC_GREGS+(PT_R15*4)(r3) - stw r16,_UC_GREGS+(PT_R16*4)(r3) - stw r17,_UC_GREGS+(PT_R17*4)(r3) - stw r18,_UC_GREGS+(PT_R18*4)(r3) - stw r19,_UC_GREGS+(PT_R19*4)(r3) - stw r20,_UC_GREGS+(PT_R20*4)(r3) - stw r21,_UC_GREGS+(PT_R21*4)(r3) - stw r22,_UC_GREGS+(PT_R22*4)(r3) - stw r23,_UC_GREGS+(PT_R23*4)(r3) - stw r24,_UC_GREGS+(PT_R24*4)(r3) - stw r25,_UC_GREGS+(PT_R25*4)(r3) - stw r26,_UC_GREGS+(PT_R26*4)(r3) - stw r27,_UC_GREGS+(PT_R27*4)(r3) - stw r28,_UC_GREGS+(PT_R28*4)(r3) - stw r29,_UC_GREGS+(PT_R29*4)(r3) - stw r30,_UC_GREGS+(PT_R30*4)(r3) - mfctr r0 - stw r0,_UC_GREGS+(PT_CTR*4)(r3) - mfxer r0 - stw r0,_UC_GREGS+(PT_XER*4)(r3) - mfcr r0 - stw r0,_UC_GREGS+(PT_CCR*4)(r3) - - /* Set the return value of swapcontext to "success". R3 is the only - register whose value is not preserved in the saved context. */ - li r0,0 - stw r0,_UC_GREGS+(PT_R3*4)(r3) - - /* Zero fill fields that can't be set in user state. */ - stw r0,_UC_GREGS+(PT_MSR*4)(r3) - stw r0,_UC_GREGS+(PT_MQ*4)(r3) - - /* Save the floating-point registers */ - stfd fp0,_UC_FREGS+(0*8)(r3) - stfd fp1,_UC_FREGS+(1*8)(r3) - stfd fp2,_UC_FREGS+(2*8)(r3) - stfd fp3,_UC_FREGS+(3*8)(r3) - stfd fp4,_UC_FREGS+(4*8)(r3) - stfd fp5,_UC_FREGS+(5*8)(r3) - stfd fp6,_UC_FREGS+(6*8)(r3) - stfd fp7,_UC_FREGS+(7*8)(r3) - stfd fp8,_UC_FREGS+(8*8)(r3) - stfd fp9,_UC_FREGS+(9*8)(r3) - stfd fp10,_UC_FREGS+(10*8)(r3) - stfd fp11,_UC_FREGS+(11*8)(r3) - stfd fp12,_UC_FREGS+(12*8)(r3) - stfd fp13,_UC_FREGS+(13*8)(r3) - stfd fp14,_UC_FREGS+(14*8)(r3) - stfd fp15,_UC_FREGS+(15*8)(r3) - stfd fp16,_UC_FREGS+(16*8)(r3) - stfd fp17,_UC_FREGS+(17*8)(r3) - stfd fp18,_UC_FREGS+(18*8)(r3) - stfd fp19,_UC_FREGS+(19*8)(r3) - stfd fp20,_UC_FREGS+(20*8)(r3) - stfd fp21,_UC_FREGS+(21*8)(r3) - stfd fp22,_UC_FREGS+(22*8)(r3) - stfd fp23,_UC_FREGS+(23*8)(r3) - stfd fp24,_UC_FREGS+(24*8)(r3) - stfd fp25,_UC_FREGS+(25*8)(r3) - stfd fp26,_UC_FREGS+(26*8)(r3) - stfd fp27,_UC_FREGS+(27*8)(r3) - stfd fp28,_UC_FREGS+(28*8)(r3) - stfd fp29,_UC_FREGS+(29*8)(r3) - mffs fp0 - stfd fp30,_UC_FREGS+(30*8)(r3) - stfd fp31,_UC_FREGS+(31*8)(r3) - stfd fp0,_UC_FREGS+(32*8)(r3) -#ifdef PIC - mflr r8 - bl _GLOBAL_OFFSET_TABLE_@local-4 - mflr r7 -#ifdef SHARED - lwz r7,_rtld_global@got(r7) - mtlr r8 - lwz r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7) -#else - lwz r7,_dl_hwcap@got(r7) - mtlr r8 - lwz r7,0(r7) -#endif -#else - lis r7,_dl_hwcap@ha - lwz r7,_dl_hwcap@l(r7) -#endif - andis. r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(no_vec) - - la r10,(_UC_VREGS)(r3) - la r9,(_UC_VREGS+16)(r3) - - stvx v0,0,r10 - stvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v2,0,r10 - stvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v4,0,r10 - stvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v6,0,r10 - stvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v8,0,r10 - stvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v12,0,r10 - stvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v14,0,r10 - stvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v16,0,r10 - stvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v18,0,r10 - stvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - stvx v20,0,r10 - stvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v22,0,r10 - stvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v24,0,r10 - stvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v26,0,r10 - stvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v28,0,r10 - stvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v30,0,r10 - stvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mfvscr v0 - mfspr r0,VRSAVE - stvx v0,0,r10 - sync - stw r0,0(r10) - -L(no_vec): -/* Restore ucontext (parm1) from stack. */ - lwz r12,_FRAME_PARM_SAVE1+16(r1) - li r4,0 - stw r3,_UC_REGS_PTR(r12) - addi r5,r12,_UC_SIGMASK - li r3,SIG_SETMASK - bl JUMPTARGET(sigprocmask) - cmpwi r3,0 - bne L(error_exit) - - /* - * If the new ucontext refers to the point where we were interrupted - * by a signal, we have to use the rt_sigreturn system call to - * return to the context so we get both LR and CTR restored. - * - * Otherwise, the context we are restoring is either just after - * a procedure call (getcontext/swapcontext) or at the beginning - * of a procedure call (makecontext), so we don't need to restore - * r0, xer, ctr. We don't restore r2 since it will be used as - * the TLS pointer. - */ - mr r4,r31 - lwz r31,_UC_REGS_PTR(r31) - lwz r0,_UC_GREGS+(PT_MSR*4)(r31) - cmpwi r0,0 - bne L(do_sigret) - -#ifdef PIC - mflr r8 - bl _GLOBAL_OFFSET_TABLE_@local-4 - mflr r7 -#ifdef SHARED - lwz r7,_rtld_global@got(r7) - mtlr r8 - lwz r7,RTLD_GLOBAL_DL_HWCAP_OFFSET(r7) -#else - lwz r7,_dl_hwcap@got(r7) - mtlr r8 - lwz r7,0(r7) -#endif -#else - lis r7,_dl_hwcap@ha - lwz r7,_dl_hwcap@l(r7) -#endif - andis. r7,r7,(PPC_FEATURE_HAS_ALTIVEC >> 16) - la r10,(_UC_VREGS)(r31) - beq L(has_no_vec) - - lwz r0,(32*16)(r10) - li r9,(32*16) - cmpwi r0,0 - mtspr VRSAVE,r0 - beq L(has_no_vec) - - lvx v19,r9,r10 - la r9,(16)(r10) - - lvx v0,0,r10 - lvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mtvscr v19 - lvx v2,0,r10 - lvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v4,0,r10 - lvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v6,0,r10 - lvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v8,0,r10 - lvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v12,0,r10 - lvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v14,0,r10 - lvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v16,0,r10 - lvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v18,0,r10 - lvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - lvx v20,0,r10 - lvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v22,0,r10 - lvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v24,0,r10 - lvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v26,0,r10 - lvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v28,0,r10 - lvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v30,0,r10 - lvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - -L(has_no_vec): - /* Restore the floating-point registers */ - lfd fp31,_UC_FREGS+(32*8)(r31) - lfd fp0,_UC_FREGS+(0*8)(r31) - mtfsf 0xff,fp31 - lfd fp1,_UC_FREGS+(1*8)(r31) - lfd fp2,_UC_FREGS+(2*8)(r31) - lfd fp3,_UC_FREGS+(3*8)(r31) - lfd fp4,_UC_FREGS+(4*8)(r31) - lfd fp5,_UC_FREGS+(5*8)(r31) - lfd fp6,_UC_FREGS+(6*8)(r31) - lfd fp7,_UC_FREGS+(7*8)(r31) - lfd fp8,_UC_FREGS+(8*8)(r31) - lfd fp9,_UC_FREGS+(9*8)(r31) - lfd fp10,_UC_FREGS+(10*8)(r31) - lfd fp11,_UC_FREGS+(11*8)(r31) - lfd fp12,_UC_FREGS+(12*8)(r31) - lfd fp13,_UC_FREGS+(13*8)(r31) - lfd fp14,_UC_FREGS+(14*8)(r31) - lfd fp15,_UC_FREGS+(15*8)(r31) - lfd fp16,_UC_FREGS+(16*8)(r31) - lfd fp17,_UC_FREGS+(17*8)(r31) - lfd fp18,_UC_FREGS+(18*8)(r31) - lfd fp19,_UC_FREGS+(19*8)(r31) - lfd fp20,_UC_FREGS+(20*8)(r31) - lfd fp21,_UC_FREGS+(21*8)(r31) - lfd fp22,_UC_FREGS+(22*8)(r31) - lfd fp23,_UC_FREGS+(23*8)(r31) - lfd fp24,_UC_FREGS+(24*8)(r31) - lfd fp25,_UC_FREGS+(25*8)(r31) - lfd fp26,_UC_FREGS+(26*8)(r31) - lfd fp27,_UC_FREGS+(27*8)(r31) - lfd fp28,_UC_FREGS+(28*8)(r31) - lfd fp29,_UC_FREGS+(29*8)(r31) - lfd fp30,_UC_FREGS+(30*8)(r31) - lfd fp31,_UC_FREGS+(31*8)(r31) - - /* Restore LR and CCR, and set CTR to the NIP value */ - lwz r3,_UC_GREGS+(PT_LNK*4)(r31) - lwz r4,_UC_GREGS+(PT_NIP*4)(r31) - lwz r5,_UC_GREGS+(PT_CCR*4)(r31) - mtlr r3 - mtctr r4 - mtcr r5 - - /* Restore the general registers */ - lwz r1,_UC_GREGS+(PT_R1*4)(r31) - lwz r3,_UC_GREGS+(PT_R3*4)(r31) - lwz r4,_UC_GREGS+(PT_R4*4)(r31) - lwz r5,_UC_GREGS+(PT_R5*4)(r31) - lwz r6,_UC_GREGS+(PT_R6*4)(r31) - lwz r7,_UC_GREGS+(PT_R7*4)(r31) - lwz r8,_UC_GREGS+(PT_R8*4)(r31) - lwz r9,_UC_GREGS+(PT_R9*4)(r31) - lwz r10,_UC_GREGS+(PT_R10*4)(r31) - lwz r11,_UC_GREGS+(PT_R11*4)(r31) - lwz r12,_UC_GREGS+(PT_R12*4)(r31) - lwz r13,_UC_GREGS+(PT_R13*4)(r31) - lwz r14,_UC_GREGS+(PT_R14*4)(r31) - lwz r15,_UC_GREGS+(PT_R15*4)(r31) - lwz r16,_UC_GREGS+(PT_R16*4)(r31) - lwz r17,_UC_GREGS+(PT_R17*4)(r31) - lwz r18,_UC_GREGS+(PT_R18*4)(r31) - lwz r19,_UC_GREGS+(PT_R19*4)(r31) - lwz r20,_UC_GREGS+(PT_R20*4)(r31) - lwz r21,_UC_GREGS+(PT_R21*4)(r31) - lwz r22,_UC_GREGS+(PT_R22*4)(r31) - lwz r23,_UC_GREGS+(PT_R23*4)(r31) - lwz r24,_UC_GREGS+(PT_R24*4)(r31) - lwz r25,_UC_GREGS+(PT_R25*4)(r31) - lwz r26,_UC_GREGS+(PT_R26*4)(r31) - lwz r27,_UC_GREGS+(PT_R27*4)(r31) - lwz r28,_UC_GREGS+(PT_R28*4)(r31) - lwz r29,_UC_GREGS+(PT_R29*4)(r31) - lwz r30,_UC_GREGS+(PT_R30*4)(r31) - lwz r31,_UC_GREGS+(PT_R31*4)(r31) - - bctr - -L(error_exit): - lwz r31,12(r1) - lwz r0,20(r1) - addi r1,r1,16 - mtlr r0 - blr - -L(do_sigret): - addi r1,r4,-0xd0 - li r0,SYS_ify(rt_sigreturn) - sc - /* NOTREACHED */ - -PSEUDO_END(__swapcontext) - -versioned_symbol (libc, __swapcontext, swapcontext, GLIBC_2_3_4) - -#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) - -ENTRY(__novec_swapcontext) - /* Save the current context */ addi r3,r3,_UC_REG_SPACE stw r3,_UC_REGS_PTR - _UC_REG_SPACE(r3) stw r0,_UC_GREGS+(PT_R0*4)(r3) @@ -669,24 +220,22 @@ bctr -L(novec_error_exit): +L(error_exit): lwz r31,12(r1) lwz r0,20(r1) addi r1,r1,16 mtlr r0 blr -L(novec_do_sigret): +L(do_sigret): addi r1,r4,-0xd0 li r0,SYS_ify(rt_sigreturn) sc /* NOTREACHED */ -PSEUDO_END(__novec_swapcontext) - -compat_symbol (libc, __novec_swapcontext, swapcontext, GLIBC_2_3_3) +PSEUDO_END(__swapcontext) -#endif +versioned_symbol (libc, __swapcontext, swapcontext, GLIBC_2_3_3) #if SHLIB_COMPAT (libc, GLIBC_2_1, GLIBC_2_3_3) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/ucontext_i.h glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/ucontext_i.h --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc32/ucontext_i.h 2004-01-16 15:49:35.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc32/ucontext_i.h 2003-09-24 13:21:12.000000000 +1000 @@ -21,13 +21,6 @@ #define SIG_BLOCK 0 #define SIG_SETMASK 2 -#define _FRAME_BACKCHAIN 0 -#define _FRAME_LR_SAVE 4 -#define _FRAME_PARM_SAVE1 8 -#define _FRAME_PARM_SAVE2 12 -#define _FRAME_PARM_SAVE3 16 -#define _FRAME_PARM_SAVE4 20 - #define _UC_LINK 4 #define _UC_STACK_SP 8 #define _UC_STACK_SIZE 16 @@ -39,5 +32,3 @@ #define _UC_GREGS 0 #define _UC_FREGS 192 #define _UC_VREGS 464 -#define _UC_VSCR 976 -#define _UC_VRSAVE 980 diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions 2004-01-16 15:45:45.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/Versions 2002-10-02 18:33:48.000000000 +1000 @@ -14,9 +14,4 @@ # s* scandir64; } - GLIBC_2.3.4 { - getcontext; - setcontext; - swapcontext; - } } diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S 2004-01-16 15:46:48.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/getcontext.S 2003-02-04 08:13:00.000000000 +1100 @@ -1,5 +1,5 @@ /* Save current context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,8 +18,6 @@ 02111-1307 USA. */ #include -#include -#include #include "kernel-features.h" #define __ASSEMBLY__ @@ -27,144 +25,6 @@ #include #include "ucontext_i.h" - -#if SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4) -ENTRY(__novec_getcontext) -#ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL - std r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3) - std r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r3) - mflr r0 - std r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r3) - std r0,FRAME_LR_SAVE(r1) - std r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r3) - stdu r1,-128(r1) - std r4,(SIGCONTEXT_GP_REGS+(PT_R4*8))(r3) - std r5,(SIGCONTEXT_GP_REGS+(PT_R5*8))(r3) - std r6,(SIGCONTEXT_GP_REGS+(PT_R6*8))(r3) - std r7,(SIGCONTEXT_GP_REGS+(PT_R7*8))(r3) - std r8,(SIGCONTEXT_GP_REGS+(PT_R8*8))(r3) - std r9,(SIGCONTEXT_GP_REGS+(PT_R9*8))(r3) - std r10,(SIGCONTEXT_GP_REGS+(PT_R10*8))(r3) - std r11,(SIGCONTEXT_GP_REGS+(PT_R11*8))(r3) - std r12,(SIGCONTEXT_GP_REGS+(PT_R12*8))(r3) - std r13,(SIGCONTEXT_GP_REGS+(PT_R13*8))(r3) - std r14,(SIGCONTEXT_GP_REGS+(PT_R14*8))(r3) - std r15,(SIGCONTEXT_GP_REGS+(PT_R15*8))(r3) - std r16,(SIGCONTEXT_GP_REGS+(PT_R16*8))(r3) - std r17,(SIGCONTEXT_GP_REGS+(PT_R17*8))(r3) - std r18,(SIGCONTEXT_GP_REGS+(PT_R18*8))(r3) - std r19,(SIGCONTEXT_GP_REGS+(PT_R19*8))(r3) - std r20,(SIGCONTEXT_GP_REGS+(PT_R20*8))(r3) - std r21,(SIGCONTEXT_GP_REGS+(PT_R21*8))(r3) - std r22,(SIGCONTEXT_GP_REGS+(PT_R22*8))(r3) - std r23,(SIGCONTEXT_GP_REGS+(PT_R23*8))(r3) - std r24,(SIGCONTEXT_GP_REGS+(PT_R24*8))(r3) - std r25,(SIGCONTEXT_GP_REGS+(PT_R25*8))(r3) - std r26,(SIGCONTEXT_GP_REGS+(PT_R26*8))(r3) - std r27,(SIGCONTEXT_GP_REGS+(PT_R27*8))(r3) - std r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r3) - std r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r3) - std r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r3) - std r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r3) - mfctr r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_CTR*8))(r3) - mfxer r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3) - mfcr r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3) - - /* Set the return value of swapcontext to "success". R3 is the only - register whose value is not preserved in the saved context. */ - li r0,0 - std r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3) - - /* Zero fill fields that can't be set in user state or are unused. */ - std r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(34*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_SOFTE*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(40*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(41*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(42*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3) - - /* Set the PT_REGS pointer to the address of sigcontext's gp_regs - field. Struct pt_regs and elf_gregset_t are the same thing. - We kept the regs field for backwards compatibility with - libraries built before we extended sigcontext. */ - addi r0,r3,SIGCONTEXT_GP_REGS - std r0,SIGCONTEXT_PT_REGS(r3) - - stfd fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3) - stfd fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3) - stfd fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3) - stfd fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r3) - stfd fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r3) - stfd fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r3) - stfd fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r3) - stfd fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r3) - stfd fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r3) - stfd fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r3) - stfd fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r3) - stfd fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r3) - stfd fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r3) - stfd fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r3) - stfd fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r3) - stfd fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r3) - stfd fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r3) - stfd fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r3) - stfd fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r3) - stfd fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r3) - stfd fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r3) - stfd fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r3) - stfd fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r3) - stfd fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r3) - stfd fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r3) - stfd fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r3) - stfd fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r3) - stfd fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r3) - stfd fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r3) - stfd fp29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r3) - mffs fp0 - stfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3) - stfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3) - stfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3) - - addi r5,r3,UCONTEXT_SIGMASK - li r4,0 - li r3,SIG_BLOCK - bl JUMPTARGET(sigprocmask) - nop -#else - /* If the kernel is not at least 2.4.21 then generate a ENOSYS stub. */ - mflr r0 - std r0,FRAME_LR_SAVE(r1) - stdu r1,-128(r1) - li r3,ENOSYS - bl JUMPTARGET(__syscall_error) - nop - li r3,-1 -#endif - - ld r0,128+FRAME_LR_SAVE(r1) - addi r1,r1,128 - mtlr r0 - blr -PSEUDO_END(__novec_getcontext) - -compat_symbol (libc, __novec_getcontext, getcontext, GLIBC_2_3) - -#endif - - .section ".toc","aw" -.LC__dl_hwcap: -#ifdef SHARED - .tc _rtld_global[TC],_rtld_global -#else - .tc _dl_hwcap[TC],_dl_hwcap -#endif - .section ".text" - ENTRY(__getcontext) #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL std r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3) @@ -265,120 +125,7 @@ stfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3) stfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3) stfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3) - - ld r5,.LC__dl_hwcap@toc(r2) - li r10,0 -#ifdef SHARED -/* Load _rtld-global._dl_hwcap. */ - ld r5,RTLD_GLOBAL_DL_HWCAP_OFFSET(r5) -#else - ld r5,0(r5) /* Load extern _dl_hwcap. */ -#endif - andis. r5,r5,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(has_no_vec) - - la r10,(SIGCONTEXT_V_RESERVE+8)(r3) - la r9,(SIGCONTEXT_V_RESERVE+24)(r3) - clrrdi r10,r10,4 - clrrdi r9,r9,4 - - stvx v0,0,r10 - stvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v2,0,r10 - stvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v4,0,r10 - stvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v6,0,r10 - stvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v8,0,r10 - stvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v12,0,r10 - stvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v14,0,r10 - stvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v16,0,r10 - stvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v18,0,r10 - stvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - stvx v20,0,r10 - stvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v22,0,r10 - stvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v24,0,r10 - stvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v26,0,r10 - stvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v28,0,r10 - stvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v30,0,r10 - stvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mfvscr v0 - mfspr r0,VRSAVE - stvx v0,0,r10 - stw r0,0(9) - -L(has_no_vec): -/* - Store either a NULL or a quadword aligned pointer to the Vector register - array into *v_regs. -*/ - std r10,(SIGCONTEXT_V_REGS_PTR)(r3) - + addi r5,r3,UCONTEXT_SIGMASK li r4,0 li r3,SIG_BLOCK @@ -401,5 +148,4 @@ blr PSEUDO_END(__getcontext) -versioned_symbol (libc, __getcontext, getcontext, GLIBC_2_3_4) - +weak_alias(__getcontext, getcontext) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S 2004-01-16 15:47:30.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/makecontext.S 2003-02-04 08:13:00.000000000 +1100 @@ -1,5 +1,5 @@ /* Create new context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 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 @@ -54,8 +54,8 @@ add r7,r7,r0 clrrdi r7,r7,4 li r0,0 - stdu r0,-64(r7) - std r3,FRAME_PARM1_SAVE(r7) /* Store context in dummy parm1. */ + stdu r0,-48(r7) + std r3,24(r7) mflr r0 std r2,FRAME_TOC_SAVE(r7) /* Store the TOC pointer for later. */ std r0,FRAME_LR_SAVE(r7) @@ -135,7 +135,7 @@ L(exitcode): /* Recover the ucontext and TOC from the dummy frame. */ ld r1,FRAME_BACKCHAIN(r1) /* Unstack the parameter save area frame. */ - ld r3,FRAME_PARM1_SAVE(r1) + ld r3,FRAME_COMPILER_DW(r1) ld r2,FRAME_TOC_SAVE(r1) ld r3,UCONTEXT_LINK(r3) /* Load the resume context. */ cmpdi r3,0 diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S 2004-01-16 15:48:28.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/setcontext.S 2003-02-04 08:13:00.000000000 +1100 @@ -1,5 +1,5 @@ /* Switch to context. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,8 +18,6 @@ 02111-1307 USA. */ #include -#include -#include #include "kernel-features.h" #define __ASSEMBLY__ @@ -27,171 +25,6 @@ #include "ucontext_i.h" #include -#if SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4) -ENTRY(__novec_setcontext) -#ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL - mflr r0 - std r31,-8(1) - std r0,FRAME_LR_SAVE(r1) - stdu r1,-128(r1) - mr r31,r3 - -/* - * If this ucontext refers to the point where we were interrupted - * by a signal, we have to use the rt_sigreturn system call to - * return to the context so we get both LR and CTR restored. - * - * Otherwise, the context we are restoring is either just after - * a procedure call (getcontext/swapcontext) or at the beginning - * of a procedure call (makecontext), so we don't need to restore - * msr and ctr. We don't restore r13 since it will be used as - * the TLS pointer. */ - lwz r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r31) - cmpdi r0,0 - bne L(nv_do_sigret) - - li r5,0 - addi r4,r3,UCONTEXT_SIGMASK - li r3,SIG_SETMASK - bl JUMPTARGET(sigprocmask) - nop - cmpdi r3,0 - bne L(nv_error_exit) - - lfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31) - lfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31) - lfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r31) - mtfsf 0xff,fp0 - lfd fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31) - lfd fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31) - lfd fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31) - lfd fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r31) - lfd fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31) - lfd fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r31) - lfd fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31) - lfd fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r31) - lfd fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31) - lfd fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r31) - lfd fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31) - lfd fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r31) - lfd fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31) - lfd fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r31) - lfd fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31) - lfd fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r31) - lfd fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31) - lfd fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r31) - lfd fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31) - lfd fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r31) - lfd fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31) - lfd fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r31) - lfd fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31) - lfd fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r31) - lfd fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31) - lfd fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r31) - lfd fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31) - lfd fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r31) - lfd fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31) - lfd fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r31) - - ld r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31) - ld r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r31) - mtlr r0 - ld r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r31) - ld r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r31) - ld r3,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r31) - mtxer r0 - ld r4,(SIGCONTEXT_GP_REGS+(PT_R4*8))(r31) - ld r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r31) - ld r5,(SIGCONTEXT_GP_REGS+(PT_R5*8))(r31) - mfcr r0 - ld r6,(SIGCONTEXT_GP_REGS+(PT_R6*8))(r31) - ld r7,(SIGCONTEXT_GP_REGS+(PT_R7*8))(r31) - ld r8,(SIGCONTEXT_GP_REGS+(PT_R8*8))(r31) - ld r9,(SIGCONTEXT_GP_REGS+(PT_R9*8))(r31) - ld r10,(SIGCONTEXT_GP_REGS+(PT_R10*8))(r31) - ld r11,(SIGCONTEXT_GP_REGS+(PT_R11*8))(r31) - ld r12,(SIGCONTEXT_GP_REGS+(PT_R12*8))(r31) - /* Don't reload the thread ID or TLS pointer (r13). */ - ld r14,(SIGCONTEXT_GP_REGS+(PT_R14*8))(r31) - ld r15,(SIGCONTEXT_GP_REGS+(PT_R15*8))(r31) - ld r16,(SIGCONTEXT_GP_REGS+(PT_R16*8))(r31) - ld r17,(SIGCONTEXT_GP_REGS+(PT_R17*8))(r31) - ld r18,(SIGCONTEXT_GP_REGS+(PT_R18*8))(r31) - ld r19,(SIGCONTEXT_GP_REGS+(PT_R19*8))(r31) - ld r20,(SIGCONTEXT_GP_REGS+(PT_R20*8))(r31) - ld r21,(SIGCONTEXT_GP_REGS+(PT_R21*8))(r31) - ld r22,(SIGCONTEXT_GP_REGS+(PT_R22*8))(r31) - ld r23,(SIGCONTEXT_GP_REGS+(PT_R23*8))(r31) - ld r24,(SIGCONTEXT_GP_REGS+(PT_R24*8))(r31) - ld r25,(SIGCONTEXT_GP_REGS+(PT_R25*8))(r31) - ld r26,(SIGCONTEXT_GP_REGS+(PT_R26*8))(r31) - ld r27,(SIGCONTEXT_GP_REGS+(PT_R27*8))(r31) - ld r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r31) - ld r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r31) - ld r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r31) - - /* Now we branch to the "Next Instruction Pointer" from the saved - context. With the powerpc64 instruction set there is no good way to - do this (from user state) without clobbering either the LR or CTR. - The makecontext and swapcontext functions depend on the callers - LR being preserved so we use the CTR. */ - ld r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r31) - mtctr r0 - ld r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r31) - ld r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r31) - bctr - -L(nv_error_exit): - ld r0,128+FRAME_LR_SAVE(r1) - addi r1,r1,128 - mtlr r0 - ld r31,-8(r1) - blr - - /* At this point we assume that the ucontext was created by a - rt_signal and we should use rt_sigreturn to restore the original - state. As of the 2.4.21 kernel the ucontext is the first thing - (offset 0) in the rt_signal frame and rt_sigreturn expects the - ucontext address in R1. Normally the rt-signal trampoline handles - this by popping dummy frame before the rt_signal syscall. In our - case the stack may not be in its original (signal handler return with - R1 pointing at the dummy frame) state. We do have the ucontext - address in R3, so simply copy R3 to R1 before the syscall. */ -L(nv_do_sigret): - mr r1,r3, - li r0,SYS_ify(rt_sigreturn) - sc - /* No return. */ -#else - /* If the kernel is not at least 2.4.21 then generate a ENOSYS stub. */ - mflr r0 - std r0,FRAME_LR_SAVE(r1) - stdu r1,-128(r1) - li r3,ENOSYS - bl JUMPTARGET(__syscall_error) - nop - li r3,-1 - ld r0,128+FRAME_LR_SAVE(r1) - addi r1,r1,128 - mtlr r0 - blr -#endif - -PSEUDO_END(__novec_setcontext) - -compat_symbol (libc, __novec_setcontext, setcontext, GLIBC_2_3) - -#endif - - .section ".toc","aw" -.LC__dl_hwcap: -#ifdef SHARED - .tc _rtld_global[TC],_rtld_global -#else - .tc _dl_hwcap[TC],_dl_hwcap -#endif - .section ".text" - ENTRY(__setcontext) #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL mflr r0 @@ -221,117 +54,7 @@ nop cmpdi r3,0 bne L(error_exit) - - ld r5,.LC__dl_hwcap@toc(r2) - ld r10,(SIGCONTEXT_V_REGS_PTR)(r31) -#ifdef SHARED -/* Load _rtld-global._dl_hwcap. */ - ld r5,RTLD_GLOBAL_DL_HWCAP_OFFSET(r5) -#else - ld r5,0(r5) /* Load extern _dl_hwcap. */ -#endif - andis. r5,r5,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(has_no_vec) - - cmpdi r10,0 - beq L(has_no_vec) - lwz r0,(33*16)(r10) - - li r9,(16*32) - mtspr VRSAVE,r0 - cmpwi r0,0 - beq L(has_no_vec) - - lvx v19,r9,r10 - la r9,(16)(r10) - - lvx v0,0,r10 - lvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mtvscr v19 - lvx v2,0,r10 - lvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v4,0,r10 - lvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v6,0,r10 - lvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v8,0,r10 - lvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v12,0,r10 - lvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v14,0,r10 - lvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v16,0,r10 - lvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v18,0,r10 - lvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - lvx v20,0,r10 - lvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v22,0,r10 - lvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v24,0,r10 - lvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v26,0,r10 - lvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v28,0,r10 - lvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v30,0,r10 - lvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - -L(has_no_vec): + lfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31) lfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31) lfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r31) @@ -453,4 +176,4 @@ PSEUDO_END(__setcontext) -versioned_symbol (libc, __setcontext, setcontext, GLIBC_2_3_4) +weak_alias(__setcontext, setcontext) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S 2004-01-16 15:49:11.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/swapcontext.S 2003-02-04 08:13:00.000000000 +1100 @@ -1,5 +1,5 @@ /* Save current context and install the given one. - Copyright (C) 2002, 2004 Free Software Foundation, Inc. + Copyright (C) 2002 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -18,8 +18,6 @@ 02111-1307 USA. */ #include -#include -#include #include "kernel-features.h" #define __ASSEMBLY__ @@ -27,266 +25,6 @@ #include "ucontext_i.h" #include -#if SHLIB_COMPAT (libc, GLIBC_2_3, GLIBC_2_3_4) -ENTRY(__novec_swapcontext) -#ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL - std r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3) - std r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r3) - mflr r0 - std r31,-8(1) - std r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r3) - std r0,FRAME_LR_SAVE(r1) - std r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r3) - stdu r1,-128(r1) - std r4,(SIGCONTEXT_GP_REGS+(PT_R4*8))(r3) - std r5,(SIGCONTEXT_GP_REGS+(PT_R5*8))(r3) - std r6,(SIGCONTEXT_GP_REGS+(PT_R6*8))(r3) - std r7,(SIGCONTEXT_GP_REGS+(PT_R7*8))(r3) - std r8,(SIGCONTEXT_GP_REGS+(PT_R8*8))(r3) - std r9,(SIGCONTEXT_GP_REGS+(PT_R9*8))(r3) - std r10,(SIGCONTEXT_GP_REGS+(PT_R10*8))(r3) - std r11,(SIGCONTEXT_GP_REGS+(PT_R11*8))(r3) - std r12,(SIGCONTEXT_GP_REGS+(PT_R12*8))(r3) - std r13,(SIGCONTEXT_GP_REGS+(PT_R13*8))(r3) - std r14,(SIGCONTEXT_GP_REGS+(PT_R14*8))(r3) - std r15,(SIGCONTEXT_GP_REGS+(PT_R15*8))(r3) - std r16,(SIGCONTEXT_GP_REGS+(PT_R16*8))(r3) - std r17,(SIGCONTEXT_GP_REGS+(PT_R17*8))(r3) - std r18,(SIGCONTEXT_GP_REGS+(PT_R18*8))(r3) - std r19,(SIGCONTEXT_GP_REGS+(PT_R19*8))(r3) - std r20,(SIGCONTEXT_GP_REGS+(PT_R20*8))(r3) - std r21,(SIGCONTEXT_GP_REGS+(PT_R21*8))(r3) - std r22,(SIGCONTEXT_GP_REGS+(PT_R22*8))(r3) - std r23,(SIGCONTEXT_GP_REGS+(PT_R23*8))(r3) - std r24,(SIGCONTEXT_GP_REGS+(PT_R24*8))(r3) - std r25,(SIGCONTEXT_GP_REGS+(PT_R25*8))(r3) - std r26,(SIGCONTEXT_GP_REGS+(PT_R26*8))(r3) - std r27,(SIGCONTEXT_GP_REGS+(PT_R27*8))(r3) - std r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r3) - std r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r3) - std r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r3) - std r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r3) - mfctr r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_CTR*8))(r3) - mfxer r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r3) - mfcr r0 - std r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r3) - - /* Set the return value of swapcontext to "success". R3 is the only - register whose value is not preserved in the saved context. */ - li r0,0 - std r0,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r3) - - /* Zero fill fields that can't be set in user state or are unused. */ - std r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(34*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_SOFTE*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(40*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(41*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(42*8))(r3) - std r0,(SIGCONTEXT_GP_REGS+(PT_RESULT*8))(r3) - - /* Set the PT_REGS pointer to the address of sigcontext gp_regs - field. Struct pt_regs and elf_gregset_t are the same thing. - We kept the regs field for backwards compatibility with - libraries built before we extended sigcontext. */ - addi r0,r3,SIGCONTEXT_GP_REGS - std r0,SIGCONTEXT_PT_REGS(r3) - - stfd fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r3) - stfd fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r3) - stfd fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r3) - stfd fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r3) - stfd fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r3) - stfd fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r3) - stfd fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r3) - stfd fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r3) - stfd fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r3) - stfd fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r3) - stfd fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r3) - stfd fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r3) - stfd fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r3) - stfd fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r3) - stfd fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r3) - stfd fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r3) - stfd fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r3) - stfd fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r3) - stfd fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r3) - stfd fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r3) - stfd fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r3) - stfd fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r3) - stfd fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r3) - stfd fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r3) - stfd fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r3) - stfd fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r3) - stfd fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r3) - stfd fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r3) - stfd fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r3) - stfd fp29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r3) - mffs fp0 - stfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3) - stfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3) - stfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3) - - mr r31,r4 - addi r5,r3,UCONTEXT_SIGMASK - addi r4,r4,UCONTEXT_SIGMASK - li r3,SIG_SETMASK - bl JUMPTARGET(sigprocmask) - nop - cmpdi r3,0 - bne L(nv_error_exit) - -/* - * If this new ucontext refers to the point where we were interrupted - * by a signal, we have to use the rt_sigreturn system call to - * return to the context so we get both LR and CTR restored. - * - * Otherwise, the context we are restoring is either just after - * a procedure call (getcontext/swapcontext) or at the beginning - * of a procedure call (makecontext), so we don't need to restore - * msr and ctr. We don't restore r13 since it will be used as - * the TLS pointer. */ - lwz r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r31) - cmpdi r0,0 - bne L(nv_do_sigret) - - lfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31) - lfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31) - lfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r31) - mtfsf 0xff,fp0 - lfd fp29,(SIGCONTEXT_FP_REGS+(PT_R29*8))(r31) - lfd fp28,(SIGCONTEXT_FP_REGS+(PT_R28*8))(r31) - lfd fp27,(SIGCONTEXT_FP_REGS+(PT_R27*8))(r31) - lfd fp26,(SIGCONTEXT_FP_REGS+(PT_R26*8))(r31) - lfd fp25,(SIGCONTEXT_FP_REGS+(PT_R25*8))(r31) - lfd fp24,(SIGCONTEXT_FP_REGS+(PT_R24*8))(r31) - lfd fp23,(SIGCONTEXT_FP_REGS+(PT_R23*8))(r31) - lfd fp22,(SIGCONTEXT_FP_REGS+(PT_R22*8))(r31) - lfd fp21,(SIGCONTEXT_FP_REGS+(PT_R21*8))(r31) - lfd fp20,(SIGCONTEXT_FP_REGS+(PT_R20*8))(r31) - lfd fp19,(SIGCONTEXT_FP_REGS+(PT_R19*8))(r31) - lfd fp18,(SIGCONTEXT_FP_REGS+(PT_R18*8))(r31) - lfd fp17,(SIGCONTEXT_FP_REGS+(PT_R17*8))(r31) - lfd fp16,(SIGCONTEXT_FP_REGS+(PT_R16*8))(r31) - lfd fp15,(SIGCONTEXT_FP_REGS+(PT_R15*8))(r31) - lfd fp14,(SIGCONTEXT_FP_REGS+(PT_R14*8))(r31) - lfd fp13,(SIGCONTEXT_FP_REGS+(PT_R13*8))(r31) - lfd fp12,(SIGCONTEXT_FP_REGS+(PT_R12*8))(r31) - lfd fp11,(SIGCONTEXT_FP_REGS+(PT_R11*8))(r31) - lfd fp10,(SIGCONTEXT_FP_REGS+(PT_R10*8))(r31) - lfd fp9,(SIGCONTEXT_FP_REGS+(PT_R9*8))(r31) - lfd fp8,(SIGCONTEXT_FP_REGS+(PT_R8*8))(r31) - lfd fp7,(SIGCONTEXT_FP_REGS+(PT_R7*8))(r31) - lfd fp6,(SIGCONTEXT_FP_REGS+(PT_R6*8))(r31) - lfd fp5,(SIGCONTEXT_FP_REGS+(PT_R5*8))(r31) - lfd fp4,(SIGCONTEXT_FP_REGS+(PT_R4*8))(r31) - lfd fp3,(SIGCONTEXT_FP_REGS+(PT_R3*8))(r31) - lfd fp2,(SIGCONTEXT_FP_REGS+(PT_R2*8))(r31) - lfd fp1,(SIGCONTEXT_FP_REGS+(PT_R1*8))(r31) - lfd fp0,(SIGCONTEXT_FP_REGS+(PT_R0*8))(r31) - - ld r0,(SIGCONTEXT_GP_REGS+(PT_LNK*8))(r31) - ld r1,(SIGCONTEXT_GP_REGS+(PT_R1*8))(r31) - mtlr r0 - ld r2,(SIGCONTEXT_GP_REGS+(PT_R2*8))(r31) - ld r0,(SIGCONTEXT_GP_REGS+(PT_XER*8))(r31) - ld r3,(SIGCONTEXT_GP_REGS+(PT_R3*8))(r31) - mtxer r0 - ld r4,(SIGCONTEXT_GP_REGS+(PT_R4*8))(r31) - ld r0,(SIGCONTEXT_GP_REGS+(PT_CCR*8))(r31) - ld r5,(SIGCONTEXT_GP_REGS+(PT_R5*8))(r31) - mfcr r0 - ld r6,(SIGCONTEXT_GP_REGS+(PT_R6*8))(r31) - ld r7,(SIGCONTEXT_GP_REGS+(PT_R7*8))(r31) - ld r8,(SIGCONTEXT_GP_REGS+(PT_R8*8))(r31) - ld r9,(SIGCONTEXT_GP_REGS+(PT_R9*8))(r31) - ld r10,(SIGCONTEXT_GP_REGS+(PT_R10*8))(r31) - ld r11,(SIGCONTEXT_GP_REGS+(PT_R11*8))(r31) - ld r12,(SIGCONTEXT_GP_REGS+(PT_R12*8))(r31) - /* Don't reload the thread ID or TLS pointer (r13). */ - ld r14,(SIGCONTEXT_GP_REGS+(PT_R14*8))(r31) - ld r15,(SIGCONTEXT_GP_REGS+(PT_R15*8))(r31) - ld r16,(SIGCONTEXT_GP_REGS+(PT_R16*8))(r31) - ld r17,(SIGCONTEXT_GP_REGS+(PT_R17*8))(r31) - ld r18,(SIGCONTEXT_GP_REGS+(PT_R18*8))(r31) - ld r19,(SIGCONTEXT_GP_REGS+(PT_R19*8))(r31) - ld r20,(SIGCONTEXT_GP_REGS+(PT_R20*8))(r31) - ld r21,(SIGCONTEXT_GP_REGS+(PT_R21*8))(r31) - ld r22,(SIGCONTEXT_GP_REGS+(PT_R22*8))(r31) - ld r23,(SIGCONTEXT_GP_REGS+(PT_R23*8))(r31) - ld r24,(SIGCONTEXT_GP_REGS+(PT_R24*8))(r31) - ld r25,(SIGCONTEXT_GP_REGS+(PT_R25*8))(r31) - ld r26,(SIGCONTEXT_GP_REGS+(PT_R26*8))(r31) - ld r27,(SIGCONTEXT_GP_REGS+(PT_R27*8))(r31) - ld r28,(SIGCONTEXT_GP_REGS+(PT_R28*8))(r31) - ld r29,(SIGCONTEXT_GP_REGS+(PT_R29*8))(r31) - ld r30,(SIGCONTEXT_GP_REGS+(PT_R30*8))(r31) - - /* Now we branch to the "Next Instruction Pointer" from the saved - context. With the powerpc64 instruction set there is no good way to - do this (from user state) without clobbering either the LR or CTR. - The makecontext and swapcontext functions depend on the callers - LR being preserved so we use the CTR. */ - ld r0,(SIGCONTEXT_GP_REGS+(PT_NIP*8))(r31) - mtctr r0 - ld r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r31) - ld r31,(SIGCONTEXT_GP_REGS+(PT_R31*8))(r31) - bctr - -L(nv_error_exit): - ld r0,128+FRAME_LR_SAVE(r1) - addi r1,r1,128 - mtlr r0 - ld r31,-8(r1) - blr - - /* At this point we assume that the ucontext was created by a - rt_signal and we should use rt_sigreturn to restore the original - state. As of the 2.4.21 kernel the ucontext is the first thing - (offset 0) in the rt_signal frame and rt_sigreturn expects the - ucontext address in R1. Normally the rt-signal trampoline handles - this by popping dummy frame before the rt_signal syscall. In our - case the stack may not be in its original (signal handler return with - R1 pointing at the dummy frame) state. We do have the ucontext - address in R3, so simply copy R3 to R1 before the syscall. */ -L(nv_do_sigret): - mr r1,r3, - li r0,SYS_ify(rt_sigreturn) - sc - /* No return. */ -#else - /* If the kernel is not at least 2.4.21 then generate a ENOSYS stub. */ - mflr r0 - std r0,FRAME_LR_SAVE(r1) - stdu r1,-128(r1) - li r3,ENOSYS - bl JUMPTARGET(__syscall_error) - nop - li r3,-1 - ld r0,128+FRAME_LR_SAVE(r1) - addi r1,r1,128 - mtlr r0 - blr -#endif - -PSEUDO_END(__novec_swapcontext) - -compat_symbol (libc, __novec_swapcontext, swapcontext, GLIBC_2_3) - -#endif - - .section ".toc","aw" -.LC__dl_hwcap: -#ifdef SHARED - .tc _rtld_global[TC],_rtld_global -#else - .tc _dl_hwcap[TC],_dl_hwcap -#endif - .section ".text" - ENTRY(__swapcontext) #ifdef __ASSUME_NEW_RT_SIGRETURN_SYSCALL std r0,(SIGCONTEXT_GP_REGS+(PT_R0*8))(r3) @@ -388,119 +126,6 @@ stfd fp30,(SIGCONTEXT_FP_REGS+(PT_R30*8))(r3) stfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r3) stfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r3) - - ld r8,.LC__dl_hwcap@toc(r2) - li r10,0 -#ifdef SHARED -/* Load _rtld-global._dl_hwcap. */ - ld r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8) -#else - ld r8,0(r8) /* Load extern _dl_hwcap. */ -#endif - andis. r8,r8,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(has_no_vec) - - la r10,(SIGCONTEXT_V_RESERVE+8)(r3) - la r9,(SIGCONTEXT_V_RESERVE+24)(r3) - clrrdi r10,r10,4 - clrrdi r9,r9,4 - - stvx v0,0,r10 - stvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v2,0,r10 - stvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v4,0,r10 - stvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v6,0,r10 - stvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v8,0,r10 - stvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v12,0,r10 - stvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v14,0,r10 - stvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v16,0,r10 - stvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v18,0,r10 - stvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - stvx v20,0,r10 - stvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v22,0,r10 - stvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v24,0,r10 - stvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v26,0,r10 - stvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v28,0,r10 - stvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v30,0,r10 - stvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - stvx v10,0,r10 - stvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mfvscr v0 - mfspr r0,VRSAVE - stvx v0,0,r10 - stw r0,0(9) - -L(has_no_vec): -/* - Store either a NULL or a quadword aligned pointer to the Vector register - array into *v_regs. -*/ - std r10,(SIGCONTEXT_V_REGS_PTR)(r3) mr r31,r4 addi r5,r3,UCONTEXT_SIGMASK @@ -524,117 +149,6 @@ lwz r0,(SIGCONTEXT_GP_REGS+(PT_MSR*8))(r31) cmpdi r0,0 bne L(do_sigret) - - ld r8,.LC__dl_hwcap@toc(r2) - ld r10,(SIGCONTEXT_V_REGS_PTR)(r31) -#ifdef SHARED -/* Load _rtld-global._dl_hwcap. */ - ld r8,RTLD_GLOBAL_DL_HWCAP_OFFSET(r8) -#else - ld r8,0(r8) /* Load extern _dl_hwcap. */ -#endif - andis. r8,r8,(PPC_FEATURE_HAS_ALTIVEC >> 16) - beq L(has_no_vec2) - - cmpdi r10,0 - beq L(has_no_vec2) - lwz r0,(33*16)(r10) - - li r9,(16*32) - mtspr VRSAVE,r0 - cmpwi r0,0 - beq L(has_no_vec2) - - lvx v19,r9,r10 - la r9,(16)(r10) - - lvx v0,0,r10 - lvx v1,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - mtvscr v19 - lvx v2,0,r10 - lvx v3,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v4,0,r10 - lvx v5,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v6,0,r10 - lvx v7,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v8,0,r10 - lvx v9,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v12,0,r10 - lvx v13,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v14,0,r10 - lvx v15,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v16,0,r10 - lvx v17,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v18,0,r10 - lvx v11,0,r9 - addi r19,r10,32 - addi r9,r9,32 - - lvx v20,0,r10 - lvx v21,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v22,0,r10 - lvx v23,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v24,0,r10 - lvx v25,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v26,0,r10 - lvx v27,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v28,0,r10 - lvx v29,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v30,0,r10 - lvx v31,0,r9 - addi r10,r10,32 - addi r9,r9,32 - - lvx v10,0,r10 - lvx v11,0,r9 - addi r10,r10,32 - addi r9,r9,32 - -L(has_no_vec2): lfd fp0,(SIGCONTEXT_FP_REGS+(32*8))(r31) lfd fp31,(SIGCONTEXT_FP_REGS+(PT_R31*8))(r31) @@ -757,4 +271,4 @@ PSEUDO_END(__swapcontext) -versioned_symbol (libc, __swapcontext, swapcontext, GLIBC_2_3_4) +weak_alias(__swapcontext, swapcontext) diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/ucontext_i.h glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/ucontext_i.h --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/powerpc64/ucontext_i.h 2004-01-16 15:49:59.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/powerpc64/ucontext_i.h 2003-01-17 14:26:27.000000000 +1100 @@ -56,5 +56,3 @@ #define SIGCONTEXT_PT_REGS 224 #define SIGCONTEXT_GP_REGS 232 #define SIGCONTEXT_FP_REGS 616 -#define SIGCONTEXT_V_REGS_PTR 880 -#define SIGCONTEXT_V_RESERVE 888 diff -uNr glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h --- glibc-2.3-20040205-2105/sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h 2004-01-16 15:44:35.000000000 +1100 +++ glibc-2.3.3-lfs/sysdeps/unix/sysv/linux/powerpc/sys/ucontext.h 2003-12-18 10:11:15.000000000 +1100 @@ -1,4 +1,4 @@ -/* Copyright (C) 1998, 1999, 2002, 2004 Free Software Foundation, Inc. +/* Copyright (C) 1998, 1999, 2002 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 @@ -29,7 +29,7 @@ #if __WORDSIZE == 32 /* Number of general registers. */ -# define NGREG 48 +#define NGREG 48 /* Container for all general registers. */ typedef unsigned long gregset_t[NGREG]; @@ -62,74 +62,8 @@ #else -/* For 64-bit kernels with Altivec support, a machine context is exactly - * a sigcontext. For older kernel (without Altivec) the sigcontext matches - * the mcontext upto but not including the v_regs field. For kernels that - * don't AT_HWCAP or return AT_HWCAP without PPC_FEATURE_HAS_ALTIVEC the - * v_regs field may not exit and should not be referenced. The v_regd field - * can be refernced safely only after verifying that PPC_FEATURE_HAS_ALTIVEC - * is set in AT_HWCAP. */ - -# include - -/* Number of general registers. */ -# define NGREG 48 /* includes r0-r31, nip, msr, lr, etc. */ -# define NFPREG 33 /* includes fp0-fp31 &fpscr. */ -# define NVRREG 34 /* includes v0-v31, vscr, & vrsave in split vectors */ - -typedef unsigned long gregset_t[NGREG]; -typedef double fpregset_t[NFPREG]; - -/* Container for Altivec/VMX Vector Status and Control Register. Only 32-bits - but can only be copied to/from a 128-bit vector register. So we allocated - a whole quadword speedup save/restore. */ -typedef struct _libc_vscr -{ - unsigned int __pad[3]; - unsigned int vscr_word; -} vscr_t; - -/* Container for Altivec/VMX registers and status. - Must to be aligned on a 16-byte boundary. */ -typedef struct _libc_vrstate -{ - unsigned int vrregs[32][4]; - vscr_t vscr; - unsigned int vrsave; - unsigned int __pad[3]; -} vrregset_t __attribute__((__aligned__(16))); - -typedef struct { - unsigned long __unused[4]; - int signal; - int __pad0; - unsigned long handler; - unsigned long oldmask; - struct pt_regs *regs; - gregset_t gp_regs; - fpregset_t fp_regs; -/* - * To maintain compatibility with current implementations the sigcontext is - * extended by appending a pointer (v_regs) to a quadword type (elf_vrreg_t) - * followed by an unstructured (vmx_reserve) field of 69 doublewords. This - * allows the array of vector registers to be quadword aligned independent of - * the alignment of the containing sigcontext or ucontext. It is the - * responsibility of the code setting the sigcontext to set this pointer to - * either NULL (if this processor does not support the VMX feature) or the - * address of the first quadword within the allocated (vmx_reserve) area. - * - * The pointer (v_regs) of vector type (elf_vrreg_t) is essentually - * an array of 34 quadword entries. The entries with - * indexes 0-31 contain the corresponding vector registers. The entry with - * index 32 contains the vscr as the last word (offset 12) within the - * quadword. This allows the vscr to be stored as either a quadword (since - * it must be copied via a vector register to/from storage) or as a word. - * The entry with index 33 contains the vrsave as the first word (offset 0) - * within the quadword. - */ - vrregset_t *v_regs; - long vmx_reserve[NVRREG+NVRREG+1]; -} mcontext_t; +/* For 64-bit, a machine context is exactly a sigcontext. */ +typedef struct sigcontext mcontext_t; #endif