diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 13:54:38 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 13:54:38 +0000 |
commit | 8c1ab65c0f548d20b7f177bdb736daaf603340e1 (patch) | |
tree | df55b7e75bf43f2bf500845b105afe3ac3a5157e /libc-top-half/musl/arch/i386/bits/user.h | |
parent | Initial commit. (diff) | |
download | wasi-libc-upstream/0.0_git20221206.8b7148f.tar.xz wasi-libc-upstream/0.0_git20221206.8b7148f.zip |
Adding upstream version 0.0~git20221206.8b7148f.upstream/0.0_git20221206.8b7148f
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'libc-top-half/musl/arch/i386/bits/user.h')
-rw-r--r-- | libc-top-half/musl/arch/i386/bits/user.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/libc-top-half/musl/arch/i386/bits/user.h b/libc-top-half/musl/arch/i386/bits/user.h new file mode 100644 index 0000000..33fea98 --- /dev/null +++ b/libc-top-half/musl/arch/i386/bits/user.h @@ -0,0 +1,44 @@ +#undef __WORDSIZE +#define __WORDSIZE 32 + +typedef struct user_fpregs_struct { + long cwd, swd, twd, fip, fcs, foo, fos, st_space[20]; +} elf_fpregset_t; + +typedef struct user_fpxregs_struct { + unsigned short cwd, swd, twd, fop; + long fip, fcs, foo, fos, mxcsr, reserved; + long st_space[32], xmm_space[32], padding[56]; +} elf_fpxregset_t; + +struct user_regs_struct { + long ebx, ecx, edx, esi, edi, ebp, eax, xds, xes, xfs, xgs; + long orig_eax, eip, xcs, eflags, esp, xss; +}; + +#define ELF_NGREG 17 +typedef unsigned long elf_greg_t, elf_gregset_t[ELF_NGREG]; + +struct user { + struct user_regs_struct regs; + int u_fpvalid; + struct user_fpregs_struct i387; + unsigned long u_tsize; + unsigned long u_dsize; + unsigned long u_ssize; + unsigned long start_code; + unsigned long start_stack; + long signal; + int reserved; + struct user_regs_struct *u_ar0; + struct user_fpregs_struct *u_fpstate; + unsigned long magic; + char u_comm[32]; + int u_debugreg[8]; +}; + +#define PAGE_MASK (~(PAGESIZE-1)) +#define NBPG PAGESIZE +#define UPAGES 1 +#define HOST_TEXT_START_ADDR (u.start_code) +#define HOST_STACK_END_ADDR (u.start_stack + u.u_ssize * NBPG) |