From bdbd93b5efefcade9d161cb6b21a1845f5e1fc8d Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Wed, 28 Dec 2005 05:41:36 +0000 Subject: [PATCH] 2005-12-27 Roland McGrath * sysdeps/alpha/bits/setjmp.h (_JMPBUF_UNWINDS): Take third argument DEMANGLE, and pass SP value through it. * sysdeps/hppa/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/i386/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/m68k/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/mips/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/powerpc/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/s390/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/sh/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/sparc/sparc32/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * sysdeps/unix/sysv/linux/ia64/bits/setjmp.h: Likewise. * sysdeps/unix/sysv/linux/sparc/bits/setjmp.h: Likewise. * sysdeps/x86_64/bits/setjmp.h (_JMPBUF_UNWINDS): Likewise. * hurd/sigunwind.c (_hurdsig_longjmp_from_handler): Pass inline demangler function to _JMPBUF_UNWINDS. * sysdeps/mach/hurd/jmp-unwind.c (demangle_ptr): New function. (_longjmp_unwind): Pass it to _JMPBUF_UNWINDS. --- sysdeps/alpha/bits/setjmp.h | 6 +++--- sysdeps/hppa/bits/setjmp.h | 7 ++++--- sysdeps/m68k/bits/setjmp.h | 6 +++--- sysdeps/mips/bits/setjmp.h | 4 ++-- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/sysdeps/alpha/bits/setjmp.h b/sysdeps/alpha/bits/setjmp.h index c603a35554..71b7738c37 100644 --- a/sysdeps/alpha/bits/setjmp.h +++ b/sysdeps/alpha/bits/setjmp.h @@ -1,5 +1,5 @@ /* Define the machine-dependent type `jmp_buf'. Alpha version. - Copyright (C) 1992, 1997, 2003 Free Software Foundation, Inc. + Copyright (C) 1992, 1997, 2003, 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 @@ -80,8 +80,8 @@ typedef long int __jmp_buf[17]; /* Test if longjmp to JMPBUF would unwind the frame containing a local variable at ADDRESS. */ -#define _JMPBUF_UNWINDS(_jmpbuf, _address) \ - ((void *)(_address) < (void *)((_jmpbuf)[JB_SP])) +#define _JMPBUF_UNWINDS(_jmpbuf, _address, _demangle) \ + ((void *)(_address) < (void *) _demangle ((_jmpbuf)[JB_SP])) #endif #endif /* bits/setjmp.h */ diff --git a/sysdeps/hppa/bits/setjmp.h b/sysdeps/hppa/bits/setjmp.h index 4395b8f562..07ea01eb97 100644 --- a/sysdeps/hppa/bits/setjmp.h +++ b/sysdeps/hppa/bits/setjmp.h @@ -1,4 +1,4 @@ -/* Copyright (C) 2000 Free Software Foundation, Inc. +/* Copyright (C) 2000, 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 @@ -39,7 +39,8 @@ typedef double __jmp_buf[21]; /* Test if longjmp to JMPBUF would unwind the frame containing a local variable at ADDRESS. */ -#define _JMPBUF_UNWINDS(_jmpbuf, _address) \ - ((void *)(_address) > (void *)(((unsigned long *) _jmpbuf)[JB_SP])) +#define _JMPBUF_UNWINDS(_jmpbuf, _address, _demangle) \ + ((void *) (_address) > \ + (void *) _demangle ((((unsigned long *) _jmpbuf)[JB_SP]))) #endif /* bits/setjmp.h */ diff --git a/sysdeps/m68k/bits/setjmp.h b/sysdeps/m68k/bits/setjmp.h index 193eec3509..612582af26 100644 --- a/sysdeps/m68k/bits/setjmp.h +++ b/sysdeps/m68k/bits/setjmp.h @@ -1,4 +1,4 @@ -/* Copyright (C) 1997, 1998 Free Software Foundation, Inc. +/* Copyright (C) 1997, 1998, 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 @@ -44,7 +44,7 @@ typedef struct /* Test if longjmp to JMPBUF would unwind the frame containing a local variable at ADDRESS. */ -#define _JMPBUF_UNWINDS(jmpbuf, address) \ - ((void *) (address) < (void *) (jmpbuf)->__sp) +#define _JMPBUF_UNWINDS(jmpbuf, address, demangle) \ + ((void *) (address) < (void *) demangle ((jmpbuf)->__sp)) #endif /* bits/setjmp.h */ diff --git a/sysdeps/mips/bits/setjmp.h b/sysdeps/mips/bits/setjmp.h index 74caae8cba..5f7c82b864 100644 --- a/sysdeps/mips/bits/setjmp.h +++ b/sysdeps/mips/bits/setjmp.h @@ -80,7 +80,7 @@ typedef struct /* Test if longjmp to JMPBUF would unwind the frame containing a local variable at ADDRESS. */ -#define _JMPBUF_UNWINDS(jmpbuf, address) \ - ((void *) (address) < (void *) (jmpbuf)[0].__sp) +#define _JMPBUF_UNWINDS(jmpbuf, address, demangle) \ + ((void *) (address) < (void *) demangle ((jmpbuf)[0].__sp)) #endif /* _MIPS_BITS_SETJMP_H */