1 #if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
2 || defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
4 #if defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
5 # define MINSIGSTKSZ 2048
9 /* gregs[0] holds the program counter. */
11 #if defined(_GNU_SOURCE) || defined(_BSD_SOURCE)
12 typedef unsigned long greg_t;
13 typedef unsigned long gregset_t[32];
15 struct __riscv_f_ext_state {
20 struct __riscv_d_ext_state {
21 unsigned long long f[32];
25 struct __riscv_q_ext_state {
26 unsigned long long f[64] __attribute__((aligned(16)));
28 unsigned int reserved[3];
31 union __riscv_fp_state {
32 struct __riscv_f_ext_state f;
33 struct __riscv_d_ext_state d;
34 struct __riscv_q_ext_state q;
37 typedef union __riscv_fp_state fpregset_t;
39 typedef struct sigcontext {
46 unsigned long gregs[32];
47 unsigned long long fpregs[66];
57 typedef struct __ucontext
59 unsigned long uc_flags;
60 struct __ucontext *uc_link;
63 mcontext_t uc_mcontext;
66 #define SA_NOCLDSTOP 1
67 #define SA_NOCLDWAIT 2
69 #define SA_ONSTACK 0x08000000
70 #define SA_RESTART 0x10000000
71 #define SA_NODEFER 0x40000000
72 #define SA_RESETHAND 0x80000000
73 #define SA_RESTORER 0x04000000
83 #define SIGIOT SIGABRT
107 #define SIGPOLL SIGIO
110 #define SIGUNUSED SIGSYS