* sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep.h [ASSEMBLER]:

Define PTR_DEMANGLE2.
	* sysdeps/powerpc/powerpc32/setjmp-common.S [PTR_MANGLE]: Also
	mangle r1.
	* sysdeps/powerpc/powerpc32/__longjmp-common.S [PTR_DEMANGLE]: Also
	demangle r1.
	* sysdeps/powerpc/powerpc32/fpu/setjmp-common.S [PTR_MANGLE]: Mangle
	r0 and r1.
	* sysdeps/powerpc/powerpc32/fpu/__longjmp-common.S [PTR_DEMANGLE]:
	Demangle r0 and r1.
This commit is contained in:
Ulrich Drepper 2005-12-29 22:03:36 +00:00
parent 8a422e9efd
commit 4e54d7e476
7 changed files with 40 additions and 1 deletions

View File

@ -1,5 +1,16 @@
2005-12-29 Ulrich Drepper <drepper@redhat.com>
* sysdeps/unix/sysv/linux/powerpc/powerpc32/sysdep.h [ASSEMBLER]:
Define PTR_DEMANGLE2.
* sysdeps/powerpc/powerpc32/setjmp-common.S [PTR_MANGLE]: Also
mangle r1.
* sysdeps/powerpc/powerpc32/__longjmp-common.S [PTR_DEMANGLE]: Also
demangle r1.
* sysdeps/powerpc/powerpc32/fpu/setjmp-common.S [PTR_MANGLE]: Mangle
r0 and r1.
* sysdeps/powerpc/powerpc32/fpu/__longjmp-common.S [PTR_DEMANGLE]:
Demangle r0 and r1.
* sysdeps/powerpc/powerpc64/setjmp-common.S [PTR_MANGLE]: Also
mangle r1.
* sysdeps/powerpc/powerpc64/__longjmp-common.S [PTR_DEMANGLE]: Also

View File

@ -43,6 +43,7 @@ ENTRY (BP_SYM (__longjmp))
lwz r20,((JB_GPRS+6)*4)(r3)
#ifdef PTR_DEMANGLE
PTR_DEMANGLE (r0, r25)
PTR_DEMANGLE2 (r1, r25)
#endif
mtlr r0
lwz r21,((JB_GPRS+7)*4)(r3)

View File

@ -1,5 +1,5 @@
/* longjmp for PowerPC.
Copyright (C) 1995-99, 2000, 2003, 2004 Free Software Foundation, Inc.
Copyright (C) 1995-99, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@ -128,6 +128,10 @@ L(no_vmx):
lfd fp19,((JB_FPRS+5*2)*4)(r3)
lwz r20,((JB_GPRS+6)*4)(r3)
lfd fp20,((JB_FPRS+6*2)*4)(r3)
#ifdef PTR_DEMANGLE
PTR_DEMANGLE (r0, r25)
PTR_DEMANGLE2 (r1, r25)
#endif
mtlr r0
lwz r21,((JB_GPRS+7)*4)(r3)
lfd fp21,((JB_FPRS+7*2)*4)(r3)

View File

@ -32,10 +32,19 @@
ENTRY (BP_SYM (__sigsetjmp))
CHECK_BOUNDS_BOTH_WIDE_LIT (r3, r8, r9, JB_SIZE)
#ifdef PTR_MANGLE
mr r5,r1
PTR_MANGLE(r5, r10)
stw r5,(JB_GPR1*4)(3)
#else
stw r1,(JB_GPR1*4)(3)
#endif
mflr r0
stw r14,((JB_GPRS+0)*4)(3)
stfd fp14,((JB_FPRS+0*2)*4)(3)
#ifdef PTR_MANGLE
PTR_MANGLE (r0, r10)
#endif
stw r0,(JB_LR*4)(3)
stw r15,((JB_GPRS+1)*4)(3)
stfd fp15,((JB_FPRS+1*2)*4)(3)

View File

@ -33,7 +33,13 @@
ENTRY (BP_SYM (__sigsetjmp))
CHECK_BOUNDS_BOTH_WIDE_LIT (r3, r8, r9, JB_SIZE)
#ifdef PTR_MANGLE
mr r5,r1
PTR_MANGLE(r5, r10)
stw r5,(JB_GPR1*4)(3)
#else
stw r1,(JB_GPR1*4)(3)
#endif
mflr r0
stw r14,((JB_GPRS+0)*4)(3)
#ifdef PTR_MANGLE

View File

@ -46,7 +46,13 @@ ENTRY (BP_SYM (__sigsetjmp))
.hidden JUMPTARGET(GLUE(__sigsetjmp,_ent))
JUMPTARGET(GLUE(__sigsetjmp,_ent)):
CHECK_BOUNDS_BOTH_WIDE_LIT (r3, r8, r9, JB_SIZE)
#ifdef PTR_MANGLE
mr r5, r1
PTR_MANGLE (r5, r10)
std r5,(JB_GPR1*8)(3)
#else
std r1,(JB_GPR1*8)(3)
#endif
mflr r0
#if defined SHARED && !defined IS_IN_rtld
ld r5,40(r1) /* Retrieve the callers TOC. */

View File

@ -181,6 +181,8 @@
lwz tmpreg,POINTER_GUARD(r2); \
xor reg,tmpreg,reg
# define PTR_DEMANGLE(reg, tmpreg) PTR_MANGLE (reg, tmpreg)
# define PTR_DEMANGLE2(reg, tmpreg) \
xor reg,tmpreg,reg
# else
# define PTR_MANGLE(var) \
(var) = (__typeof (var)) ((uintptr_t) (var) ^ THREAD_GET_POINTER_GUARD ())