1 /* Copyright (C) 2002 Free Software Foundation, Inc.
2 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.
9 The GNU C Library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Lesser General Public License for more details.
14 You should have received a copy of the GNU Lesser General Public
15 License along with the GNU C Library; if not, write to the Free
16 Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
19 #ifndef _BITS_SIGCONTEXT_H
20 #define _BITS_SIGCONTEXT_H 1
22 #if !defined _SIGNAL_H && !defined _SYS_UCONTEXT_H
23 # error "Never use <bits/sigcontext.h> directly; include <signal.h> instead."
26 #include <bits/wordsize.h>
30 unsigned short significand
[4];
31 unsigned short exponent
;
36 unsigned short significand
[4];
37 unsigned short exponent
;
38 unsigned short padding
[3];
43 __uint32_t element
[4];
52 /* Regular FPU environment. */
61 unsigned short status
;
64 /* FXSR FPU environment. */
65 __uint32_t _fxsr_env
[6];
68 struct _fpxreg _fxsr_st
[8];
69 struct _xmmreg _xmm
[8];
70 __uint32_t padding
[56];
73 #ifndef sigcontext_struct
74 /* Kernel headers before 2.1.1 define a struct sigcontext_struct, but
75 we need sigcontext. Some packages have come to rely on
76 sigcontext_struct being defined on 32-bit x86, so define this for
78 # define sigcontext_struct sigcontext
83 unsigned short gs
, __gsh
;
84 unsigned short fs
, __fsh
;
85 unsigned short es
, __esh
;
86 unsigned short ds
, __dsh
;
98 unsigned short cs
, __csh
;
100 unsigned long esp_at_signal
;
101 unsigned short ss
, __ssh
;
102 struct _fpstate
* fpstate
;
103 unsigned long oldmask
;
107 #else /* __WORDSIZE == 64 */
111 /* FPU environment matching the 64-bit FXSAVE layout. */
119 __uint32_t mxcr_mask
;
120 struct _fpxreg _st
[8];
121 struct _xmmreg _xmm
[16];
122 __uint32_t padding
[24];
144 unsigned long eflags
;
148 unsigned short __pad0
;
150 unsigned long trapno
;
151 unsigned long oldmask
;
153 struct _fpstate
* fpstate
;
154 unsigned long __reserved1
[8];
157 #endif /* __WORDSIZE == 64 */
159 #endif /* _BITS_SIGCONTEXT_H */