1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_UCONTEXT_H_
6 #define SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_UCONTEXT_H_
8 // We do something compatible with glibc. Hopefully, at some point Android will
9 // provide that for us, and __BIONIC_HAVE_UCONTEXT_T should be defined.
11 // http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-AMD64/LSB-Core-AMD64/libc-ddefs.html#AEN5668
13 #if !defined(__BIONIC_HAVE_UCONTEXT_T)
14 #include <asm/sigcontext.h>
17 unsigned short significand
[4];
18 unsigned short exponent
;
19 unsigned short padding
[3];
26 struct _libc_fpstate
{
35 struct _libc_fpxreg _st
[8];
36 struct _libc_xmmreg _xmm
[16];
40 typedef uint64_t greg_t
;
44 struct _libc_fpstate
* fpregs
;
45 unsigned long __reserved1
[8];
75 typedef struct ucontext
{
76 unsigned long uc_flags
;
77 struct ucontext
* uc_link
;
79 mcontext_t uc_mcontext
;
81 struct _libc_fpstate __fpregs_mem
;
85 #include <sys/ucontext.h>
86 #endif // __BIONIC_HAVE_UCONTEXT_T
88 #endif // SANDBOX_LINUX_SYSTEM_HEADERS_X86_64_LINUX_UCONTEXT_H_