* Implemented [sig]{set,long}jmp() for PPC. No idea, if it is any good,

but it compiles at least. :-)
* Pulled the architecture specific part out of <posix/setjmp.h> into
  <posix/arch/<arch>/arch_setjmp.h>.
* Moved setjmp_save_sigs.c from the x86 specific implementation into a
  "generic" sibling directory, since it is reusable (and actually used
  by the PPC implementation).
* Added generic/longjmp_return.c containing a function __longjmp_return,
  which is invoked at the end of siglongjmp(), resetting the signal mask
  and validating the return value. It is used by the PPC implementation,
  and should also be used by the x86 implementation, but I'll leave that
  to someone who's motivated enough to also test it. :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15479 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2005-12-10 22:56:52 +00:00
parent 62b965a65f
commit fe14a904a8
11 changed files with 223 additions and 8 deletions
+10
View File
@@ -0,0 +1,10 @@
/*
* Copyright 2005, Haiku, Inc.
* Distributed under the terms of the MIT License.
*/
#ifndef _ARCH_SETJMP_H_
#define _ARCH_SETJMP_H_
typedef int __jmp_buf[23];
#endif /* _ARCH_SETJMP_H_ */
+10
View File
@@ -0,0 +1,10 @@
/*
* Copyright 2005, Haiku, Inc.
* Distributed under the terms of the MIT License.
*/
#ifndef _ARCH_SETJMP_H_
#define _ARCH_SETJMP_H_
typedef int __jmp_buf[6];
#endif /* _ARCH_SETJMP_H_ */
+8 -3
View File
@@ -5,12 +5,17 @@
#ifndef _SETJMP_H_
#define _SETJMP_H_
#include <signal.h>
// include architecture specific definitions
#ifdef __INTEL__
#include <arch/x86/arch_setjmp.h>
#elif __POWERPC__
#include <arch/ppc/arch_setjmp.h>
#endif
typedef struct __jmp_buf {
int regs[6]; /* saved registers, stack & program pointer */
typedef struct __jmp_buf_tag {
__jmp_buf regs; /* saved registers, stack & program pointer */
int mask_was_saved;
sigset_t saved_mask;
} jmp_buf[1];