1 /* Copyright (C) 1997-2024 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, see
16 <https://www.gnu.org/licenses/>. */
18 /* Don't rely on this, the interface is currently messed up and may need to
19 be broken to be fixed. */
20 #ifndef _SYS_UCONTEXT_H
21 #define _SYS_UCONTEXT_H 1
25 #include <bits/types/sigset_t.h>
26 #include <bits/types/stack_t.h>
30 # define __ctx(fld) fld
32 # define __ctx(fld) __ ## fld
36 /* Type for general register. */
37 typedef unsigned long int greg_t
;
39 /* Number of general registers. */
43 /* Container for all general registers. */
44 typedef struct gregset
52 /* Container for all FPU registers. */
59 /* Context to describe whole processor state. */
62 unsigned long int __ctx(sc_flags
);
63 unsigned long int __ctx(sc_gr
)[32];
64 unsigned long long int __ctx(sc_fr
)[32];
65 unsigned long int __ctx(sc_iasq
)[2];
66 unsigned long int __ctx(sc_iaoq
)[2];
67 unsigned long int __ctx(sc_sar
);
70 /* Userlevel context. */
71 typedef struct ucontext_t
73 unsigned long int __ctx(uc_flags
);
74 struct ucontext_t
*uc_link
;
76 mcontext_t uc_mcontext
;
82 #endif /* sys/ucontext.h */