setjmp.h 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. /* Define the machine-dependent type `jmp_buf'. MIPS version.
  2. Copyright (C) 1992,93,95,97,2000 Free Software Foundation, Inc.
  3. This file is part of the GNU C Library.
  4. The GNU C Library is free software; you can redistribute it and/or
  5. modify it under the terms of the GNU Lesser General Public
  6. License as published by the Free Software Foundation; either
  7. version 2.1 of the License, or (at your option) any later version.
  8. The GNU C Library is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  11. Lesser General Public License for more details.
  12. You should have received a copy of the GNU Lesser General Public
  13. License along with the GNU C Library; if not, see
  14. <http://www.gnu.org/licenses/>. */
  15. #ifndef _BITS_SETJMP_H
  16. #define _BITS_SETJMP_H 1
  17. #if !defined _SETJMP_H && !defined _PTHREAD_H
  18. # error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
  19. #endif
  20. #include <sgidefs.h>
  21. #if _MIPS_SIM == _MIPS_SIM_ABI32
  22. #define __ptr_size void *
  23. #else
  24. #define __ptr_size long long
  25. #endif
  26. typedef struct
  27. {
  28. /* Program counter. */
  29. __ptr_size __pc;
  30. /* Stack pointer. */
  31. __ptr_size __sp;
  32. /* Callee-saved registers s0 through s7. */
  33. #if _MIPS_SIM == _MIPS_SIM_ABI32
  34. int __regs[8];
  35. #else
  36. long long __regs[8];
  37. #endif
  38. /* The frame pointer. */
  39. __ptr_size __fp;
  40. /* The global pointer. */
  41. __ptr_size __gp;
  42. /* Floating point status register. */
  43. int __fpc_csr;
  44. /* Callee-saved floating point registers. */
  45. #if _MIPS_SIM == _MIPS_SIM_ABI64
  46. double __fpregs[8];
  47. #else /* N32 || O32 */
  48. double __fpregs[6];
  49. #endif /* N32 || O32 */
  50. } __jmp_buf[1];
  51. #endif /* bits/setjmp.h */