multi-arch glibc headers
This commit is contained in:
11
libc/include/i386-linux-gnu/bits/a.out.h
Normal file
11
libc/include/i386-linux-gnu/bits/a.out.h
Normal file
@@ -0,0 +1,11 @@
|
||||
#ifndef __A_OUT_GNU_H__
|
||||
# error "Never use <bits/a.out.h> directly; include <a.out.h> instead."
|
||||
#endif
|
||||
|
||||
#ifdef __x86_64__
|
||||
|
||||
/* Signal to users of this header that this architecture really doesn't
|
||||
support a.out binary format. */
|
||||
#define __NO_A_OUT_SUPPORT 1
|
||||
|
||||
#endif
|
||||
7
libc/include/i386-linux-gnu/bits/endian.h
Normal file
7
libc/include/i386-linux-gnu/bits/endian.h
Normal file
@@ -0,0 +1,7 @@
|
||||
/* i386/x86_64 are little-endian. */
|
||||
|
||||
#ifndef _ENDIAN_H
|
||||
# error "Never use <bits/endian.h> directly; include <endian.h> instead."
|
||||
#endif
|
||||
|
||||
#define __BYTE_ORDER __LITTLE_ENDIAN
|
||||
105
libc/include/i386-linux-gnu/bits/environments.h
Normal file
105
libc/include/i386-linux-gnu/bits/environments.h
Normal file
@@ -0,0 +1,105 @@
|
||||
/* Copyright (C) 1999-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _UNISTD_H
|
||||
# error "Never include this file directly. Use <unistd.h> instead"
|
||||
#endif
|
||||
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
/* This header should define the following symbols under the described
|
||||
situations. A value `1' means that the model is always supported,
|
||||
`-1' means it is never supported. Undefined means it cannot be
|
||||
statically decided.
|
||||
|
||||
_POSIX_V7_ILP32_OFF32 32bit int, long, pointers, and off_t type
|
||||
_POSIX_V7_ILP32_OFFBIG 32bit int, long, and pointers and larger off_t type
|
||||
|
||||
_POSIX_V7_LP64_OFF32 64bit long and pointers and 32bit off_t type
|
||||
_POSIX_V7_LPBIG_OFFBIG 64bit long and pointers and large off_t type
|
||||
|
||||
The macros _POSIX_V6_ILP32_OFF32, _POSIX_V6_ILP32_OFFBIG,
|
||||
_POSIX_V6_LP64_OFF32, _POSIX_V6_LPBIG_OFFBIG, _XBS5_ILP32_OFF32,
|
||||
_XBS5_ILP32_OFFBIG, _XBS5_LP64_OFF32, and _XBS5_LPBIG_OFFBIG were
|
||||
used in previous versions of the Unix standard and are available
|
||||
only for compatibility.
|
||||
*/
|
||||
|
||||
#if __WORDSIZE == 64
|
||||
|
||||
/* Environments with 32-bit wide pointers are optionally provided.
|
||||
Therefore following macros aren't defined:
|
||||
# undef _POSIX_V7_ILP32_OFF32
|
||||
# undef _POSIX_V7_ILP32_OFFBIG
|
||||
# undef _POSIX_V6_ILP32_OFF32
|
||||
# undef _POSIX_V6_ILP32_OFFBIG
|
||||
# undef _XBS5_ILP32_OFF32
|
||||
# undef _XBS5_ILP32_OFFBIG
|
||||
and users need to check at runtime. */
|
||||
|
||||
/* We also have no use (for now) for an environment with bigger pointers
|
||||
and offsets. */
|
||||
# define _POSIX_V7_LPBIG_OFFBIG -1
|
||||
# define _POSIX_V6_LPBIG_OFFBIG -1
|
||||
# define _XBS5_LPBIG_OFFBIG -1
|
||||
|
||||
/* By default we have 64-bit wide `long int', pointers and `off_t'. */
|
||||
# define _POSIX_V7_LP64_OFF64 1
|
||||
# define _POSIX_V6_LP64_OFF64 1
|
||||
# define _XBS5_LP64_OFF64 1
|
||||
|
||||
#else /* __WORDSIZE == 32 */
|
||||
|
||||
/* We have 32-bit wide `int', `long int' and pointers and all platforms
|
||||
support LFS. -mx32 has 64-bit wide `off_t'. */
|
||||
# define _POSIX_V7_ILP32_OFFBIG 1
|
||||
# define _POSIX_V6_ILP32_OFFBIG 1
|
||||
# define _XBS5_ILP32_OFFBIG 1
|
||||
|
||||
# ifndef __x86_64__
|
||||
/* -m32 has 32-bit wide `off_t'. */
|
||||
# define _POSIX_V7_ILP32_OFF32 1
|
||||
# define _POSIX_V6_ILP32_OFF32 1
|
||||
# define _XBS5_ILP32_OFF32 1
|
||||
# endif
|
||||
|
||||
/* We optionally provide an environment with the above size but an 64-bit
|
||||
side `off_t'. Therefore we don't define _POSIX_V7_ILP32_OFFBIG. */
|
||||
|
||||
/* Environments with 64-bit wide pointers can be provided,
|
||||
so these macros aren't defined:
|
||||
# undef _POSIX_V7_LP64_OFF64
|
||||
# undef _POSIX_V7_LPBIG_OFFBIG
|
||||
# undef _POSIX_V6_LP64_OFF64
|
||||
# undef _POSIX_V6_LPBIG_OFFBIG
|
||||
# undef _XBS5_LP64_OFF64
|
||||
# undef _XBS5_LPBIG_OFFBIG
|
||||
and sysconf tests for it at runtime. */
|
||||
|
||||
#endif /* __WORDSIZE == 32 */
|
||||
|
||||
#define __ILP32_OFF32_CFLAGS "-m32"
|
||||
#define __ILP32_OFF32_LDFLAGS "-m32"
|
||||
#if defined __x86_64__ && defined __ILP32__
|
||||
# define __ILP32_OFFBIG_CFLAGS "-mx32"
|
||||
# define __ILP32_OFFBIG_LDFLAGS "-mx32"
|
||||
#else
|
||||
# define __ILP32_OFFBIG_CFLAGS "-m32 -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
|
||||
# define __ILP32_OFFBIG_LDFLAGS "-m32"
|
||||
#endif
|
||||
#define __LP64_OFF64_CFLAGS "-m64"
|
||||
#define __LP64_OFF64_LDFLAGS "-m64"
|
||||
29
libc/include/i386-linux-gnu/bits/epoll.h
Normal file
29
libc/include/i386-linux-gnu/bits/epoll.h
Normal file
@@ -0,0 +1,29 @@
|
||||
/* Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_EPOLL_H
|
||||
# error "Never use <bits/epoll.h> directly; include <sys/epoll.h> instead."
|
||||
#endif
|
||||
|
||||
/* Flags to be passed to epoll_create1. */
|
||||
enum
|
||||
{
|
||||
EPOLL_CLOEXEC = 02000000
|
||||
#define EPOLL_CLOEXEC EPOLL_CLOEXEC
|
||||
};
|
||||
|
||||
#define __EPOLL_PACKED __attribute__ ((__packed__))
|
||||
61
libc/include/i386-linux-gnu/bits/fcntl.h
Normal file
61
libc/include/i386-linux-gnu/bits/fcntl.h
Normal file
@@ -0,0 +1,61 @@
|
||||
/* O_*, F_*, FD_* bit values for Linux/x86.
|
||||
Copyright (C) 2001-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _FCNTL_H
|
||||
# error "Never use <bits/fcntl.h> directly; include <fcntl.h> instead."
|
||||
#endif
|
||||
|
||||
#ifdef __x86_64__
|
||||
# define __O_LARGEFILE 0
|
||||
#endif
|
||||
|
||||
#ifdef __x86_64__
|
||||
/* Not necessary, we always have 64-bit offsets. */
|
||||
# define F_GETLK64 5 /* Get record locking info. */
|
||||
# define F_SETLK64 6 /* Set record locking info (non-blocking). */
|
||||
# define F_SETLKW64 7 /* Set record locking info (blocking). */
|
||||
#endif
|
||||
|
||||
|
||||
struct flock
|
||||
{
|
||||
short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
|
||||
short int l_whence; /* Where `l_start' is relative to (like `lseek'). */
|
||||
#ifndef __USE_FILE_OFFSET64
|
||||
__off_t l_start; /* Offset where the lock begins. */
|
||||
__off_t l_len; /* Size of the locked area; zero means until EOF. */
|
||||
#else
|
||||
__off64_t l_start; /* Offset where the lock begins. */
|
||||
__off64_t l_len; /* Size of the locked area; zero means until EOF. */
|
||||
#endif
|
||||
__pid_t l_pid; /* Process holding the lock. */
|
||||
};
|
||||
|
||||
#ifdef __USE_LARGEFILE64
|
||||
struct flock64
|
||||
{
|
||||
short int l_type; /* Type of lock: F_RDLCK, F_WRLCK, or F_UNLCK. */
|
||||
short int l_whence; /* Where `l_start' is relative to (like `lseek'). */
|
||||
__off64_t l_start; /* Offset where the lock begins. */
|
||||
__off64_t l_len; /* Size of the locked area; zero means until EOF. */
|
||||
__pid_t l_pid; /* Process holding the lock. */
|
||||
};
|
||||
#endif
|
||||
|
||||
/* Include generic Linux declarations. */
|
||||
#include <bits/fcntl-linux.h>
|
||||
170
libc/include/i386-linux-gnu/bits/fenv.h
Normal file
170
libc/include/i386-linux-gnu/bits/fenv.h
Normal file
@@ -0,0 +1,170 @@
|
||||
/* Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _FENV_H
|
||||
# error "Never use <bits/fenv.h> directly; include <fenv.h> instead."
|
||||
#endif
|
||||
|
||||
/* Define bits representing the exception. We use the bit positions
|
||||
of the appropriate bits in the FPU control word. */
|
||||
enum
|
||||
{
|
||||
FE_INVALID =
|
||||
#define FE_INVALID 0x01
|
||||
FE_INVALID,
|
||||
__FE_DENORM = 0x02,
|
||||
FE_DIVBYZERO =
|
||||
#define FE_DIVBYZERO 0x04
|
||||
FE_DIVBYZERO,
|
||||
FE_OVERFLOW =
|
||||
#define FE_OVERFLOW 0x08
|
||||
FE_OVERFLOW,
|
||||
FE_UNDERFLOW =
|
||||
#define FE_UNDERFLOW 0x10
|
||||
FE_UNDERFLOW,
|
||||
FE_INEXACT =
|
||||
#define FE_INEXACT 0x20
|
||||
FE_INEXACT
|
||||
};
|
||||
|
||||
#define FE_ALL_EXCEPT \
|
||||
(FE_INEXACT | FE_DIVBYZERO | FE_UNDERFLOW | FE_OVERFLOW | FE_INVALID)
|
||||
|
||||
/* The ix87 FPU supports all of the four defined rounding modes. We
|
||||
use again the bit positions in the FPU control word as the values
|
||||
for the appropriate macros. */
|
||||
enum
|
||||
{
|
||||
FE_TONEAREST =
|
||||
#define FE_TONEAREST 0
|
||||
FE_TONEAREST,
|
||||
FE_DOWNWARD =
|
||||
#define FE_DOWNWARD 0x400
|
||||
FE_DOWNWARD,
|
||||
FE_UPWARD =
|
||||
#define FE_UPWARD 0x800
|
||||
FE_UPWARD,
|
||||
FE_TOWARDZERO =
|
||||
#define FE_TOWARDZERO 0xc00
|
||||
FE_TOWARDZERO
|
||||
};
|
||||
|
||||
|
||||
/* Type representing exception flags. */
|
||||
typedef unsigned short int fexcept_t;
|
||||
|
||||
|
||||
/* Type representing floating-point environment. This structure
|
||||
corresponds to the layout of the block written by the `fstenv'
|
||||
instruction and has additional fields for the contents of the MXCSR
|
||||
register as written by the `stmxcsr' instruction. */
|
||||
typedef struct
|
||||
{
|
||||
unsigned short int __control_word;
|
||||
unsigned short int __glibc_reserved1;
|
||||
unsigned short int __status_word;
|
||||
unsigned short int __glibc_reserved2;
|
||||
unsigned short int __tags;
|
||||
unsigned short int __glibc_reserved3;
|
||||
unsigned int __eip;
|
||||
unsigned short int __cs_selector;
|
||||
unsigned int __opcode:11;
|
||||
unsigned int __glibc_reserved4:5;
|
||||
unsigned int __data_offset;
|
||||
unsigned short int __data_selector;
|
||||
unsigned short int __glibc_reserved5;
|
||||
#ifdef __x86_64__
|
||||
unsigned int __mxcsr;
|
||||
#endif
|
||||
}
|
||||
fenv_t;
|
||||
|
||||
/* If the default argument is used we use this value. */
|
||||
#define FE_DFL_ENV ((const fenv_t *) -1)
|
||||
|
||||
#ifdef __USE_GNU
|
||||
/* Floating-point environment where none of the exception is masked. */
|
||||
# define FE_NOMASK_ENV ((const fenv_t *) -2)
|
||||
#endif
|
||||
|
||||
#if __GLIBC_USE (IEC_60559_BFP_EXT)
|
||||
/* Type representing floating-point control modes. */
|
||||
typedef struct
|
||||
{
|
||||
unsigned short int __control_word;
|
||||
unsigned short int __glibc_reserved;
|
||||
unsigned int __mxcsr;
|
||||
}
|
||||
femode_t;
|
||||
|
||||
/* Default floating-point control modes. */
|
||||
# define FE_DFL_MODE ((const femode_t *) -1L)
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef __USE_EXTERN_INLINES
|
||||
__BEGIN_DECLS
|
||||
|
||||
/* Optimized versions. */
|
||||
#ifndef _LIBC
|
||||
extern int __REDIRECT_NTH (__feraiseexcept_renamed, (int), feraiseexcept);
|
||||
#endif
|
||||
__extern_always_inline void
|
||||
__NTH (__feraiseexcept_invalid_divbyzero (int __excepts))
|
||||
{
|
||||
if ((FE_INVALID & __excepts) != 0)
|
||||
{
|
||||
/* One example of an invalid operation is 0.0 / 0.0. */
|
||||
float __f = 0.0;
|
||||
|
||||
# ifdef __SSE_MATH__
|
||||
__asm__ __volatile__ ("divss %0, %0 " : : "x" (__f));
|
||||
# else
|
||||
__asm__ __volatile__ ("fdiv %%st, %%st(0); fwait"
|
||||
: "=t" (__f) : "0" (__f));
|
||||
# endif
|
||||
(void) &__f;
|
||||
}
|
||||
if ((FE_DIVBYZERO & __excepts) != 0)
|
||||
{
|
||||
float __f = 1.0;
|
||||
float __g = 0.0;
|
||||
|
||||
# ifdef __SSE_MATH__
|
||||
__asm__ __volatile__ ("divss %1, %0" : : "x" (__f), "x" (__g));
|
||||
# else
|
||||
__asm__ __volatile__ ("fdivp %%st, %%st(1); fwait"
|
||||
: "=t" (__f) : "0" (__f), "u" (__g) : "st(1)");
|
||||
# endif
|
||||
(void) &__f;
|
||||
}
|
||||
}
|
||||
__extern_inline int
|
||||
__NTH (feraiseexcept (int __excepts))
|
||||
{
|
||||
if (__builtin_constant_p (__excepts)
|
||||
&& (__excepts & ~(FE_INVALID | FE_DIVBYZERO)) == 0)
|
||||
{
|
||||
__feraiseexcept_invalid_divbyzero (__excepts);
|
||||
return 0;
|
||||
}
|
||||
|
||||
return __feraiseexcept_renamed (__excepts);
|
||||
}
|
||||
|
||||
__END_DECLS
|
||||
#endif
|
||||
121
libc/include/i386-linux-gnu/bits/floatn.h
Normal file
121
libc/include/i386-linux-gnu/bits/floatn.h
Normal file
@@ -0,0 +1,121 @@
|
||||
/* Macros to control TS 18661-3 glibc features on x86.
|
||||
Copyright (C) 2017-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _BITS_FLOATN_H
|
||||
#define _BITS_FLOATN_H
|
||||
|
||||
#include <features.h>
|
||||
|
||||
/* Defined to 1 if the current compiler invocation provides a
|
||||
floating-point type with the IEEE 754 binary128 format, and this
|
||||
glibc includes corresponding *f128 interfaces for it. The required
|
||||
libgcc support was added some time after the basic compiler
|
||||
support, for x86_64 and x86. */
|
||||
#if (defined __x86_64__ \
|
||||
? __GNUC_PREREQ (4, 3) \
|
||||
: (defined __GNU__ ? __GNUC_PREREQ (4, 5) : __GNUC_PREREQ (4, 4)))
|
||||
# define __HAVE_FLOAT128 1
|
||||
#else
|
||||
# define __HAVE_FLOAT128 0
|
||||
#endif
|
||||
|
||||
/* Defined to 1 if __HAVE_FLOAT128 is 1 and the type is ABI-distinct
|
||||
from the default float, double and long double types in this glibc. */
|
||||
#if __HAVE_FLOAT128
|
||||
# define __HAVE_DISTINCT_FLOAT128 1
|
||||
#else
|
||||
# define __HAVE_DISTINCT_FLOAT128 0
|
||||
#endif
|
||||
|
||||
/* Defined to 1 if the current compiler invocation provides a
|
||||
floating-point type with the right format for _Float64x, and this
|
||||
glibc includes corresponding *f64x interfaces for it. */
|
||||
#define __HAVE_FLOAT64X 1
|
||||
|
||||
/* Defined to 1 if __HAVE_FLOAT64X is 1 and _Float64x has the format
|
||||
of long double. Otherwise, if __HAVE_FLOAT64X is 1, _Float64x has
|
||||
the format of _Float128, which must be different from that of long
|
||||
double. */
|
||||
#define __HAVE_FLOAT64X_LONG_DOUBLE 1
|
||||
|
||||
#ifndef __ASSEMBLER__
|
||||
|
||||
/* Defined to concatenate the literal suffix to be used with _Float128
|
||||
types, if __HAVE_FLOAT128 is 1. */
|
||||
# if __HAVE_FLOAT128
|
||||
# if !__GNUC_PREREQ (7, 0) || defined __cplusplus
|
||||
/* The literal suffix f128 exists only since GCC 7.0. */
|
||||
# define __f128(x) x##q
|
||||
# else
|
||||
# define __f128(x) x##f128
|
||||
# endif
|
||||
# endif
|
||||
|
||||
/* Defined to a complex binary128 type if __HAVE_FLOAT128 is 1. */
|
||||
# if __HAVE_FLOAT128
|
||||
# if !__GNUC_PREREQ (7, 0) || defined __cplusplus
|
||||
/* Add a typedef for older GCC compilers which don't natively support
|
||||
_Complex _Float128. */
|
||||
typedef _Complex float __cfloat128 __attribute__ ((__mode__ (__TC__)));
|
||||
# define __CFLOAT128 __cfloat128
|
||||
# else
|
||||
# define __CFLOAT128 _Complex _Float128
|
||||
# endif
|
||||
# endif
|
||||
|
||||
/* The remaining of this file provides support for older compilers. */
|
||||
# if __HAVE_FLOAT128
|
||||
|
||||
/* The type _Float128 exists only since GCC 7.0. */
|
||||
# if !__GNUC_PREREQ (7, 0) || defined __cplusplus
|
||||
typedef __float128 _Float128;
|
||||
# endif
|
||||
|
||||
/* __builtin_huge_valf128 doesn't exist before GCC 7.0. */
|
||||
# if !__GNUC_PREREQ (7, 0)
|
||||
# define __builtin_huge_valf128() ((_Float128) __builtin_huge_val ())
|
||||
# endif
|
||||
|
||||
/* Older GCC has only a subset of built-in functions for _Float128 on
|
||||
x86, and __builtin_infq is not usable in static initializers.
|
||||
Converting a narrower sNaN to _Float128 produces a quiet NaN, so
|
||||
attempts to use _Float128 sNaNs will not work properly with older
|
||||
compilers. */
|
||||
# if !__GNUC_PREREQ (7, 0)
|
||||
# define __builtin_copysignf128 __builtin_copysignq
|
||||
# define __builtin_fabsf128 __builtin_fabsq
|
||||
# define __builtin_inff128() ((_Float128) __builtin_inf ())
|
||||
# define __builtin_nanf128(x) ((_Float128) __builtin_nan (x))
|
||||
# define __builtin_nansf128(x) ((_Float128) __builtin_nans (x))
|
||||
# endif
|
||||
|
||||
/* In math/math.h, __MATH_TG will expand signbit to __builtin_signbit*,
|
||||
e.g.: __builtin_signbitf128, before GCC 6. However, there has never
|
||||
been a __builtin_signbitf128 in GCC and the type-generic builtin is
|
||||
only available since GCC 6. */
|
||||
# if !__GNUC_PREREQ (6, 0)
|
||||
# define __builtin_signbitf128 __signbitf128
|
||||
# endif
|
||||
|
||||
# endif
|
||||
|
||||
#endif /* !__ASSEMBLER__. */
|
||||
|
||||
#include <bits/floatn-common.h>
|
||||
|
||||
#endif /* _BITS_FLOATN_H */
|
||||
33
libc/include/i386-linux-gnu/bits/flt-eval-method.h
Normal file
33
libc/include/i386-linux-gnu/bits/flt-eval-method.h
Normal file
@@ -0,0 +1,33 @@
|
||||
/* Define __GLIBC_FLT_EVAL_METHOD. x86 version.
|
||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _MATH_H
|
||||
# error "Never use <bits/flt-eval-method.h> directly; include <math.h> instead."
|
||||
#endif
|
||||
|
||||
#ifdef __FLT_EVAL_METHOD__
|
||||
# if __FLT_EVAL_METHOD__ == -1
|
||||
# define __GLIBC_FLT_EVAL_METHOD 2
|
||||
# else
|
||||
# define __GLIBC_FLT_EVAL_METHOD __FLT_EVAL_METHOD__
|
||||
# endif
|
||||
#elif defined __x86_64__
|
||||
# define __GLIBC_FLT_EVAL_METHOD 0
|
||||
#else
|
||||
# define __GLIBC_FLT_EVAL_METHOD 2
|
||||
#endif
|
||||
24
libc/include/i386-linux-gnu/bits/fp-logb.h
Normal file
24
libc/include/i386-linux-gnu/bits/fp-logb.h
Normal file
@@ -0,0 +1,24 @@
|
||||
/* Define __FP_LOGB0_IS_MIN and __FP_LOGBNAN_IS_MIN. x86 version.
|
||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _MATH_H
|
||||
# error "Never use <bits/fp-logb.h> directly; include <math.h> instead."
|
||||
#endif
|
||||
|
||||
#define __FP_LOGB0_IS_MIN 1
|
||||
#define __FP_LOGBNAN_IS_MIN 1
|
||||
37
libc/include/i386-linux-gnu/bits/indirect-return.h
Normal file
37
libc/include/i386-linux-gnu/bits/indirect-return.h
Normal file
@@ -0,0 +1,37 @@
|
||||
/* Definition of __INDIRECT_RETURN. x86 version.
|
||||
Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _UCONTEXT_H
|
||||
# error "Never include <bits/indirect-return.h> directly; use <ucontext.h> instead."
|
||||
#endif
|
||||
|
||||
/* On x86, swapcontext returns via indirect branch when the shadow stack
|
||||
is enabled. Define __INDIRECT_RETURN to indicate whether swapcontext
|
||||
returns via indirect branch. */
|
||||
#if defined __CET__ && (__CET__ & 2) != 0
|
||||
# if __glibc_has_attribute (__indirect_return__)
|
||||
# define __INDIRECT_RETURN __attribute__ ((__indirect_return__))
|
||||
# else
|
||||
/* Newer compilers provide the indirect_return attribute, but without
|
||||
it we can use returns_twice to affect the optimizer in the same
|
||||
way and avoid unsafe optimizations. */
|
||||
# define __INDIRECT_RETURN __attribute__ ((__returns_twice__))
|
||||
# endif
|
||||
#else
|
||||
# define __INDIRECT_RETURN
|
||||
#endif
|
||||
33
libc/include/i386-linux-gnu/bits/ipctypes.h
Normal file
33
libc/include/i386-linux-gnu/bits/ipctypes.h
Normal file
@@ -0,0 +1,33 @@
|
||||
/* bits/ipctypes.h -- Define some types used by SysV IPC/MSG/SHM.
|
||||
Copyright (C) 2012-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_IPC_H
|
||||
# error "Never use <bits/ipctypes.h> directly; include <sys/ipc.h> instead."
|
||||
#endif
|
||||
|
||||
#ifndef _BITS_IPCTYPES_H
|
||||
#define _BITS_IPCTYPES_H 1
|
||||
|
||||
/* Used in `struct shmid_ds'. */
|
||||
# ifdef __x86_64__
|
||||
typedef int __ipc_pid_t;
|
||||
# else
|
||||
typedef unsigned short int __ipc_pid_t;
|
||||
# endif
|
||||
|
||||
#endif /* bits/ipctypes.h */
|
||||
54
libc/include/i386-linux-gnu/bits/iscanonical.h
Normal file
54
libc/include/i386-linux-gnu/bits/iscanonical.h
Normal file
@@ -0,0 +1,54 @@
|
||||
/* Define iscanonical macro. ldbl-96 version.
|
||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _MATH_H
|
||||
# error "Never use <bits/iscanonical.h> directly; include <math.h> instead."
|
||||
#endif
|
||||
|
||||
extern int __iscanonicall (long double __x)
|
||||
__THROW __attribute__ ((__const__));
|
||||
#define __iscanonicalf(x) ((void) (__typeof (x)) (x), 1)
|
||||
#define __iscanonical(x) ((void) (__typeof (x)) (x), 1)
|
||||
#if __HAVE_DISTINCT_FLOAT128
|
||||
# define __iscanonicalf128(x) ((void) (__typeof (x)) (x), 1)
|
||||
#endif
|
||||
|
||||
/* Return nonzero value if X is canonical. In IEEE interchange binary
|
||||
formats, all values are canonical, but the argument must still be
|
||||
converted to its semantic type for any exceptions arising from the
|
||||
conversion, before being discarded; in extended precision, there
|
||||
are encodings that are not consistently handled as corresponding to
|
||||
any particular value of the type, and we return 0 for those. */
|
||||
#ifndef __cplusplus
|
||||
# define iscanonical(x) __MATH_TG ((x), __iscanonical, (x))
|
||||
#else
|
||||
/* In C++ mode, __MATH_TG cannot be used, because it relies on
|
||||
__builtin_types_compatible_p, which is a C-only builtin. On the
|
||||
other hand, overloading provides the means to distinguish between
|
||||
the floating-point types. The overloading resolution will match
|
||||
the correct parameter (regardless of type qualifiers (i.e.: const
|
||||
and volatile)). */
|
||||
extern "C++" {
|
||||
inline int iscanonical (float __val) { return __iscanonicalf (__val); }
|
||||
inline int iscanonical (double __val) { return __iscanonical (__val); }
|
||||
inline int iscanonical (long double __val) { return __iscanonicall (__val); }
|
||||
# if __HAVE_DISTINCT_FLOAT128
|
||||
inline int iscanonical (_Float128 __val) { return __iscanonicalf128 (__val); }
|
||||
# endif
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
159
libc/include/i386-linux-gnu/bits/link.h
Normal file
159
libc/include/i386-linux-gnu/bits/link.h
Normal file
@@ -0,0 +1,159 @@
|
||||
/* Copyright (C) 2004-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _LINK_H
|
||||
# error "Never include <bits/link.h> directly; use <link.h> instead."
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef __x86_64__
|
||||
/* Registers for entry into PLT on IA-32. */
|
||||
typedef struct La_i86_regs
|
||||
{
|
||||
uint32_t lr_edx;
|
||||
uint32_t lr_ecx;
|
||||
uint32_t lr_eax;
|
||||
uint32_t lr_ebp;
|
||||
uint32_t lr_esp;
|
||||
} La_i86_regs;
|
||||
|
||||
/* Return values for calls from PLT on IA-32. */
|
||||
typedef struct La_i86_retval
|
||||
{
|
||||
uint32_t lrv_eax;
|
||||
uint32_t lrv_edx;
|
||||
long double lrv_st0;
|
||||
long double lrv_st1;
|
||||
uint64_t lrv_bnd0;
|
||||
uint64_t lrv_bnd1;
|
||||
} La_i86_retval;
|
||||
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
extern Elf32_Addr la_i86_gnu_pltenter (Elf32_Sym *__sym, unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
La_i86_regs *__regs,
|
||||
unsigned int *__flags,
|
||||
const char *__symname,
|
||||
long int *__framesizep);
|
||||
extern unsigned int la_i86_gnu_pltexit (Elf32_Sym *__sym, unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
const La_i86_regs *__inregs,
|
||||
La_i86_retval *__outregs,
|
||||
const char *symname);
|
||||
|
||||
__END_DECLS
|
||||
|
||||
#else
|
||||
|
||||
/* Registers for entry into PLT on x86-64. */
|
||||
# if __GNUC_PREREQ (4,0)
|
||||
typedef float La_x86_64_xmm __attribute__ ((__vector_size__ (16)));
|
||||
typedef float La_x86_64_ymm
|
||||
__attribute__ ((__vector_size__ (32), __aligned__ (16)));
|
||||
typedef double La_x86_64_zmm
|
||||
__attribute__ ((__vector_size__ (64), __aligned__ (16)));
|
||||
# else
|
||||
typedef float La_x86_64_xmm __attribute__ ((__mode__ (__V4SF__)));
|
||||
# endif
|
||||
|
||||
typedef union
|
||||
{
|
||||
# if __GNUC_PREREQ (4,0)
|
||||
La_x86_64_ymm ymm[2];
|
||||
La_x86_64_zmm zmm[1];
|
||||
# endif
|
||||
La_x86_64_xmm xmm[4];
|
||||
} La_x86_64_vector __attribute__ ((__aligned__ (16)));
|
||||
|
||||
typedef struct La_x86_64_regs
|
||||
{
|
||||
uint64_t lr_rdx;
|
||||
uint64_t lr_r8;
|
||||
uint64_t lr_r9;
|
||||
uint64_t lr_rcx;
|
||||
uint64_t lr_rsi;
|
||||
uint64_t lr_rdi;
|
||||
uint64_t lr_rbp;
|
||||
uint64_t lr_rsp;
|
||||
La_x86_64_xmm lr_xmm[8];
|
||||
La_x86_64_vector lr_vector[8];
|
||||
#ifndef __ILP32__
|
||||
__int128_t lr_bnd[4];
|
||||
#endif
|
||||
} La_x86_64_regs;
|
||||
|
||||
/* Return values for calls from PLT on x86-64. */
|
||||
typedef struct La_x86_64_retval
|
||||
{
|
||||
uint64_t lrv_rax;
|
||||
uint64_t lrv_rdx;
|
||||
La_x86_64_xmm lrv_xmm0;
|
||||
La_x86_64_xmm lrv_xmm1;
|
||||
long double lrv_st0;
|
||||
long double lrv_st1;
|
||||
La_x86_64_vector lrv_vector0;
|
||||
La_x86_64_vector lrv_vector1;
|
||||
#ifndef __ILP32__
|
||||
__int128_t lrv_bnd0;
|
||||
__int128_t lrv_bnd1;
|
||||
#endif
|
||||
} La_x86_64_retval;
|
||||
|
||||
#define La_x32_regs La_x86_64_regs
|
||||
#define La_x32_retval La_x86_64_retval
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
extern Elf64_Addr la_x86_64_gnu_pltenter (Elf64_Sym *__sym,
|
||||
unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
La_x86_64_regs *__regs,
|
||||
unsigned int *__flags,
|
||||
const char *__symname,
|
||||
long int *__framesizep);
|
||||
extern unsigned int la_x86_64_gnu_pltexit (Elf64_Sym *__sym,
|
||||
unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
const La_x86_64_regs *__inregs,
|
||||
La_x86_64_retval *__outregs,
|
||||
const char *__symname);
|
||||
|
||||
extern Elf32_Addr la_x32_gnu_pltenter (Elf32_Sym *__sym,
|
||||
unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
La_x32_regs *__regs,
|
||||
unsigned int *__flags,
|
||||
const char *__symname,
|
||||
long int *__framesizep);
|
||||
extern unsigned int la_x32_gnu_pltexit (Elf32_Sym *__sym,
|
||||
unsigned int __ndx,
|
||||
uintptr_t *__refcook,
|
||||
uintptr_t *__defcook,
|
||||
const La_x32_regs *__inregs,
|
||||
La_x32_retval *__outregs,
|
||||
const char *__symname);
|
||||
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
||||
20
libc/include/i386-linux-gnu/bits/long-double.h
Normal file
20
libc/include/i386-linux-gnu/bits/long-double.h
Normal file
@@ -0,0 +1,20 @@
|
||||
/* Properties of long double type. ldbl-96 version.
|
||||
Copyright (C) 2016-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
/* long double is distinct from double, so there is nothing to
|
||||
define here. */
|
||||
43
libc/include/i386-linux-gnu/bits/math-vector-fortran.h
Normal file
43
libc/include/i386-linux-gnu/bits/math-vector-fortran.h
Normal file
@@ -0,0 +1,43 @@
|
||||
! Platform-specific declarations of SIMD math functions for Fortran. -*- f90 -*-
|
||||
! Copyright (C) 2019 Free Software Foundation, Inc.
|
||||
! This file is part of the GNU C Library.
|
||||
!
|
||||
! The GNU C Library is free software; you can redistribute it and/or
|
||||
! modify it under the terms of the GNU Lesser General Public
|
||||
! License as published by the Free Software Foundation; either
|
||||
! version 2.1 of the License, or (at your option) any later version.
|
||||
!
|
||||
! The GNU C Library is distributed in the hope that it will be useful,
|
||||
! but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
! Lesser General Public License for more details.
|
||||
!
|
||||
! You should have received a copy of the GNU Lesser General Public
|
||||
! License along with the GNU C Library; if not, see
|
||||
! <http://www.gnu.org/licenses/>.
|
||||
|
||||
!GCC$ builtin (cos) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (cosf) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (sin) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (sinf) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (sincos) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (sincosf) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (log) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (logf) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (exp) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (expf) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (pow) attributes simd (notinbranch) if('x86_64')
|
||||
!GCC$ builtin (powf) attributes simd (notinbranch) if('x86_64')
|
||||
|
||||
!GCC$ builtin (cos) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (cosf) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (sin) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (sinf) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (sincos) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (sincosf) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (log) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (logf) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (exp) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (expf) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (pow) attributes simd (notinbranch) if('x32')
|
||||
!GCC$ builtin (powf) attributes simd (notinbranch) if('x32')
|
||||
63
libc/include/i386-linux-gnu/bits/math-vector.h
Normal file
63
libc/include/i386-linux-gnu/bits/math-vector.h
Normal file
@@ -0,0 +1,63 @@
|
||||
/* Platform-specific SIMD declarations of math functions.
|
||||
Copyright (C) 2014-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _MATH_H
|
||||
# error "Never include <bits/math-vector.h> directly;\
|
||||
include <math.h> instead."
|
||||
#endif
|
||||
|
||||
/* Get default empty definitions for simd declarations. */
|
||||
#include <bits/libm-simd-decl-stubs.h>
|
||||
|
||||
#if defined __x86_64__ && defined __FAST_MATH__
|
||||
# if defined _OPENMP && _OPENMP >= 201307
|
||||
/* OpenMP case. */
|
||||
# define __DECL_SIMD_x86_64 _Pragma ("omp declare simd notinbranch")
|
||||
# elif __GNUC_PREREQ (6,0)
|
||||
/* W/o OpenMP use GCC 6.* __attribute__ ((__simd__)). */
|
||||
# define __DECL_SIMD_x86_64 __attribute__ ((__simd__ ("notinbranch")))
|
||||
# endif
|
||||
|
||||
# ifdef __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_cos
|
||||
# define __DECL_SIMD_cos __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_cosf
|
||||
# define __DECL_SIMD_cosf __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_sin
|
||||
# define __DECL_SIMD_sin __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_sinf
|
||||
# define __DECL_SIMD_sinf __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_sincos
|
||||
# define __DECL_SIMD_sincos __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_sincosf
|
||||
# define __DECL_SIMD_sincosf __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_log
|
||||
# define __DECL_SIMD_log __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_logf
|
||||
# define __DECL_SIMD_logf __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_exp
|
||||
# define __DECL_SIMD_exp __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_expf
|
||||
# define __DECL_SIMD_expf __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_pow
|
||||
# define __DECL_SIMD_pow __DECL_SIMD_x86_64
|
||||
# undef __DECL_SIMD_powf
|
||||
# define __DECL_SIMD_powf __DECL_SIMD_x86_64
|
||||
|
||||
# endif
|
||||
#endif
|
||||
34
libc/include/i386-linux-gnu/bits/mman.h
Normal file
34
libc/include/i386-linux-gnu/bits/mman.h
Normal file
@@ -0,0 +1,34 @@
|
||||
/* Definitions for POSIX memory map interface. Linux/x86_64 version.
|
||||
Copyright (C) 2001-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_MMAN_H
|
||||
# error "Never use <bits/mman.h> directly; include <sys/mman.h> instead."
|
||||
#endif
|
||||
|
||||
/* The following definitions basically come from the kernel headers.
|
||||
But the kernel header is not namespace clean. */
|
||||
|
||||
/* Other flags. */
|
||||
#ifdef __USE_MISC
|
||||
# define MAP_32BIT 0x40 /* Only give out 32-bit addresses. */
|
||||
#endif
|
||||
|
||||
#include <bits/mman-map-flags-generic.h>
|
||||
|
||||
/* Include generic Linux declarations. */
|
||||
#include <bits/mman-linux.h>
|
||||
30
libc/include/i386-linux-gnu/bits/procfs-id.h
Normal file
30
libc/include/i386-linux-gnu/bits/procfs-id.h
Normal file
@@ -0,0 +1,30 @@
|
||||
/* Types of pr_uid and pr_gid in struct elf_prpsinfo. x86 version.
|
||||
Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_PROCFS_H
|
||||
# error "Never include <bits/procfs-id.h> directly; use <sys/procfs.h> instead."
|
||||
#endif
|
||||
|
||||
#if __WORDSIZE == 32
|
||||
typedef unsigned short int __pr_uid_t;
|
||||
typedef unsigned short int __pr_gid_t;
|
||||
#else
|
||||
typedef unsigned int __pr_uid_t;
|
||||
typedef unsigned int __pr_gid_t;
|
||||
#endif
|
||||
50
libc/include/i386-linux-gnu/bits/procfs.h
Normal file
50
libc/include/i386-linux-gnu/bits/procfs.h
Normal file
@@ -0,0 +1,50 @@
|
||||
/* Types for registers for sys/procfs.h. x86 version.
|
||||
Copyright (C) 2001-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_PROCFS_H
|
||||
# error "Never include <bits/procfs.h> directly; use <sys/procfs.h> instead."
|
||||
#endif
|
||||
|
||||
/* Type for a general-purpose register. */
|
||||
#ifdef __x86_64__
|
||||
__extension__ typedef unsigned long long elf_greg_t;
|
||||
#else
|
||||
typedef unsigned long elf_greg_t;
|
||||
#endif
|
||||
|
||||
/* And the whole bunch of them. We could have used `struct
|
||||
user_regs_struct' directly in the typedef, but tradition says that
|
||||
the register set is an array, which does have some peculiar
|
||||
semantics, so leave it that way. */
|
||||
#define ELF_NGREG (sizeof (struct user_regs_struct) / sizeof (elf_greg_t))
|
||||
typedef elf_greg_t elf_gregset_t[ELF_NGREG];
|
||||
|
||||
#ifndef __x86_64__
|
||||
/* Register set for the floating-point registers. */
|
||||
typedef struct user_fpregs_struct elf_fpregset_t;
|
||||
|
||||
/* Register set for the extended floating-point registers. Includes
|
||||
the Pentium III SSE registers in addition to the classic
|
||||
floating-point stuff. */
|
||||
typedef struct user_fpxregs_struct elf_fpxregset_t;
|
||||
#else
|
||||
/* Register set for the extended floating-point registers. Includes
|
||||
the Pentium III SSE registers in addition to the classic
|
||||
floating-point stuff. */
|
||||
typedef struct user_fpregs_struct elf_fpregset_t;
|
||||
#endif
|
||||
106
libc/include/i386-linux-gnu/bits/pthreadtypes-arch.h
Normal file
106
libc/include/i386-linux-gnu/bits/pthreadtypes-arch.h
Normal file
@@ -0,0 +1,106 @@
|
||||
/* Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _BITS_PTHREADTYPES_ARCH_H
|
||||
#define _BITS_PTHREADTYPES_ARCH_H 1
|
||||
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
#ifdef __x86_64__
|
||||
# if __WORDSIZE == 64
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 40
|
||||
# define __SIZEOF_PTHREAD_ATTR_T 56
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 40
|
||||
# define __SIZEOF_PTHREAD_RWLOCK_T 56
|
||||
# define __SIZEOF_PTHREAD_BARRIER_T 32
|
||||
# else
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 32
|
||||
# define __SIZEOF_PTHREAD_ATTR_T 32
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 32
|
||||
# define __SIZEOF_PTHREAD_RWLOCK_T 44
|
||||
# define __SIZEOF_PTHREAD_BARRIER_T 20
|
||||
# endif
|
||||
#else
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 24
|
||||
# define __SIZEOF_PTHREAD_ATTR_T 36
|
||||
# define __SIZEOF_PTHREAD_MUTEX_T 24
|
||||
# define __SIZEOF_PTHREAD_RWLOCK_T 32
|
||||
# define __SIZEOF_PTHREAD_BARRIER_T 20
|
||||
#endif
|
||||
#define __SIZEOF_PTHREAD_MUTEXATTR_T 4
|
||||
#define __SIZEOF_PTHREAD_COND_T 48
|
||||
#define __SIZEOF_PTHREAD_CONDATTR_T 4
|
||||
#define __SIZEOF_PTHREAD_RWLOCKATTR_T 8
|
||||
#define __SIZEOF_PTHREAD_BARRIERATTR_T 4
|
||||
|
||||
/* Definitions for internal mutex struct. */
|
||||
#define __PTHREAD_COMPAT_PADDING_MID
|
||||
#define __PTHREAD_COMPAT_PADDING_END
|
||||
#define __PTHREAD_MUTEX_LOCK_ELISION 1
|
||||
#ifdef __x86_64__
|
||||
# define __PTHREAD_MUTEX_NUSERS_AFTER_KIND 0
|
||||
# define __PTHREAD_MUTEX_USE_UNION 0
|
||||
#else
|
||||
# define __PTHREAD_MUTEX_NUSERS_AFTER_KIND 1
|
||||
# define __PTHREAD_MUTEX_USE_UNION 1
|
||||
#endif
|
||||
|
||||
#define __LOCK_ALIGNMENT
|
||||
#define __ONCE_ALIGNMENT
|
||||
|
||||
struct __pthread_rwlock_arch_t
|
||||
{
|
||||
unsigned int __readers;
|
||||
unsigned int __writers;
|
||||
unsigned int __wrphase_futex;
|
||||
unsigned int __writers_futex;
|
||||
unsigned int __pad3;
|
||||
unsigned int __pad4;
|
||||
#ifdef __x86_64__
|
||||
int __cur_writer;
|
||||
int __shared;
|
||||
signed char __rwelision;
|
||||
# ifdef __ILP32__
|
||||
unsigned char __pad1[3];
|
||||
# define __PTHREAD_RWLOCK_ELISION_EXTRA 0, { 0, 0, 0 }
|
||||
# else
|
||||
unsigned char __pad1[7];
|
||||
# define __PTHREAD_RWLOCK_ELISION_EXTRA 0, { 0, 0, 0, 0, 0, 0, 0 }
|
||||
# endif
|
||||
unsigned long int __pad2;
|
||||
/* FLAGS must stay at this position in the structure to maintain
|
||||
binary compatibility. */
|
||||
unsigned int __flags;
|
||||
# define __PTHREAD_RWLOCK_INT_FLAGS_SHARED 1
|
||||
#else
|
||||
/* FLAGS must stay at this position in the structure to maintain
|
||||
binary compatibility. */
|
||||
unsigned char __flags;
|
||||
unsigned char __shared;
|
||||
signed char __rwelision;
|
||||
# define __PTHREAD_RWLOCK_ELISION_EXTRA 0
|
||||
unsigned char __pad2;
|
||||
int __cur_writer;
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifndef __x86_64__
|
||||
/* Extra attributes for the cleanup functions. */
|
||||
# define __cleanup_fct_attribute __attribute__ ((__regparm__ (1)))
|
||||
#endif
|
||||
|
||||
#endif /* bits/pthreadtypes.h */
|
||||
63
libc/include/i386-linux-gnu/bits/select.h
Normal file
63
libc/include/i386-linux-gnu/bits/select.h
Normal file
@@ -0,0 +1,63 @@
|
||||
/* Copyright (C) 1997-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_SELECT_H
|
||||
# error "Never use <bits/select.h> directly; include <sys/select.h> instead."
|
||||
#endif
|
||||
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
|
||||
#if defined __GNUC__ && __GNUC__ >= 2
|
||||
|
||||
# if __WORDSIZE == 64
|
||||
# define __FD_ZERO_STOS "stosq"
|
||||
# else
|
||||
# define __FD_ZERO_STOS "stosl"
|
||||
# endif
|
||||
|
||||
# define __FD_ZERO(fdsp) \
|
||||
do { \
|
||||
int __d0, __d1; \
|
||||
__asm__ __volatile__ ("cld; rep; " __FD_ZERO_STOS \
|
||||
: "=c" (__d0), "=D" (__d1) \
|
||||
: "a" (0), "0" (sizeof (fd_set) \
|
||||
/ sizeof (__fd_mask)), \
|
||||
"1" (&__FDS_BITS (fdsp)[0]) \
|
||||
: "memory"); \
|
||||
} while (0)
|
||||
|
||||
#else /* ! GNU CC */
|
||||
|
||||
/* We don't use `memset' because this would require a prototype and
|
||||
the array isn't too big. */
|
||||
# define __FD_ZERO(set) \
|
||||
do { \
|
||||
unsigned int __i; \
|
||||
fd_set *__arr = (set); \
|
||||
for (__i = 0; __i < sizeof (fd_set) / sizeof (__fd_mask); ++__i) \
|
||||
__FDS_BITS (__arr)[__i] = 0; \
|
||||
} while (0)
|
||||
|
||||
#endif /* GNU CC */
|
||||
|
||||
#define __FD_SET(d, set) \
|
||||
((void) (__FDS_BITS (set)[__FD_ELT (d)] |= __FD_MASK (d)))
|
||||
#define __FD_CLR(d, set) \
|
||||
((void) (__FDS_BITS (set)[__FD_ELT (d)] &= ~__FD_MASK (d)))
|
||||
#define __FD_ISSET(d, set) \
|
||||
((__FDS_BITS (set)[__FD_ELT (d)] & __FD_MASK (d)) != 0)
|
||||
24
libc/include/i386-linux-gnu/bits/sem-pad.h
Normal file
24
libc/include/i386-linux-gnu/bits/sem-pad.h
Normal file
@@ -0,0 +1,24 @@
|
||||
/* Define where padding goes in struct semid_ds. x86 version.
|
||||
Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SYS_SEM_H
|
||||
# error "Never use <bits/sem-pad.h> directly; include <sys/sem.h> instead."
|
||||
#endif
|
||||
|
||||
#define __SEM_PAD_AFTER_TIME 1
|
||||
#define __SEM_PAD_BEFORE_TIME 0
|
||||
40
libc/include/i386-linux-gnu/bits/semaphore.h
Normal file
40
libc/include/i386-linux-gnu/bits/semaphore.h
Normal file
@@ -0,0 +1,40 @@
|
||||
/* Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
Contributed by Ulrich Drepper <drepper@redhat.com>, 2002.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _SEMAPHORE_H
|
||||
# error "Never use <bits/semaphore.h> directly; include <semaphore.h> instead."
|
||||
#endif
|
||||
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
#if __WORDSIZE == 64
|
||||
# define __SIZEOF_SEM_T 32
|
||||
#else
|
||||
# define __SIZEOF_SEM_T 16
|
||||
#endif
|
||||
|
||||
|
||||
/* Value returned if `sem_open' failed. */
|
||||
#define SEM_FAILED ((sem_t *) 0)
|
||||
|
||||
|
||||
typedef union
|
||||
{
|
||||
char __size[__SIZEOF_SEM_T];
|
||||
long int __align;
|
||||
} sem_t;
|
||||
40
libc/include/i386-linux-gnu/bits/setjmp.h
Normal file
40
libc/include/i386-linux-gnu/bits/setjmp.h
Normal file
@@ -0,0 +1,40 @@
|
||||
/* Copyright (C) 2001-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
/* Define the machine-dependent type `jmp_buf'. x86-64 version. */
|
||||
#ifndef _BITS_SETJMP_H
|
||||
#define _BITS_SETJMP_H 1
|
||||
|
||||
#if !defined _SETJMP_H && !defined _PTHREAD_H
|
||||
# error "Never include <bits/setjmp.h> directly; use <setjmp.h> instead."
|
||||
#endif
|
||||
|
||||
#include <bits/wordsize.h>
|
||||
|
||||
#ifndef _ASM
|
||||
|
||||
# if __WORDSIZE == 64
|
||||
typedef long int __jmp_buf[8];
|
||||
# elif defined __x86_64__
|
||||
__extension__ typedef long long int __jmp_buf[8];
|
||||
# else
|
||||
typedef int __jmp_buf[6];
|
||||
# endif
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* bits/setjmp.h */
|
||||
196
libc/include/i386-linux-gnu/bits/sigcontext.h
Normal file
196
libc/include/i386-linux-gnu/bits/sigcontext.h
Normal file
@@ -0,0 +1,196 @@
|
||||
/* Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _BITS_SIGCONTEXT_H
|
||||
#define _BITS_SIGCONTEXT_H 1
|
||||
|
||||
#if !defined _SIGNAL_H && !defined _SYS_UCONTEXT_H
|
||||
# error "Never use <bits/sigcontext.h> directly; include <signal.h> instead."
|
||||
#endif
|
||||
|
||||
#include <bits/types.h>
|
||||
|
||||
#define FP_XSTATE_MAGIC1 0x46505853U
|
||||
#define FP_XSTATE_MAGIC2 0x46505845U
|
||||
#define FP_XSTATE_MAGIC2_SIZE sizeof (FP_XSTATE_MAGIC2)
|
||||
|
||||
struct _fpx_sw_bytes
|
||||
{
|
||||
__uint32_t magic1;
|
||||
__uint32_t extended_size;
|
||||
__uint64_t xstate_bv;
|
||||
__uint32_t xstate_size;
|
||||
__uint32_t __glibc_reserved1[7];
|
||||
};
|
||||
|
||||
struct _fpreg
|
||||
{
|
||||
unsigned short significand[4];
|
||||
unsigned short exponent;
|
||||
};
|
||||
|
||||
struct _fpxreg
|
||||
{
|
||||
unsigned short significand[4];
|
||||
unsigned short exponent;
|
||||
unsigned short __glibc_reserved1[3];
|
||||
};
|
||||
|
||||
struct _xmmreg
|
||||
{
|
||||
__uint32_t element[4];
|
||||
};
|
||||
|
||||
|
||||
|
||||
#ifndef __x86_64__
|
||||
|
||||
struct _fpstate
|
||||
{
|
||||
/* Regular FPU environment. */
|
||||
__uint32_t cw;
|
||||
__uint32_t sw;
|
||||
__uint32_t tag;
|
||||
__uint32_t ipoff;
|
||||
__uint32_t cssel;
|
||||
__uint32_t dataoff;
|
||||
__uint32_t datasel;
|
||||
struct _fpreg _st[8];
|
||||
unsigned short status;
|
||||
unsigned short magic;
|
||||
|
||||
/* FXSR FPU environment. */
|
||||
__uint32_t _fxsr_env[6];
|
||||
__uint32_t mxcsr;
|
||||
__uint32_t __glibc_reserved1;
|
||||
struct _fpxreg _fxsr_st[8];
|
||||
struct _xmmreg _xmm[8];
|
||||
__uint32_t __glibc_reserved2[56];
|
||||
};
|
||||
|
||||
#ifndef sigcontext_struct
|
||||
/* Kernel headers before 2.1.1 define a struct sigcontext_struct, but
|
||||
we need sigcontext. Some packages have come to rely on
|
||||
sigcontext_struct being defined on 32-bit x86, so define this for
|
||||
their benefit. */
|
||||
# define sigcontext_struct sigcontext
|
||||
#endif
|
||||
|
||||
#define X86_FXSR_MAGIC 0x0000
|
||||
|
||||
struct sigcontext
|
||||
{
|
||||
unsigned short gs, __gsh;
|
||||
unsigned short fs, __fsh;
|
||||
unsigned short es, __esh;
|
||||
unsigned short ds, __dsh;
|
||||
unsigned long edi;
|
||||
unsigned long esi;
|
||||
unsigned long ebp;
|
||||
unsigned long esp;
|
||||
unsigned long ebx;
|
||||
unsigned long edx;
|
||||
unsigned long ecx;
|
||||
unsigned long eax;
|
||||
unsigned long trapno;
|
||||
unsigned long err;
|
||||
unsigned long eip;
|
||||
unsigned short cs, __csh;
|
||||
unsigned long eflags;
|
||||
unsigned long esp_at_signal;
|
||||
unsigned short ss, __ssh;
|
||||
struct _fpstate * fpstate;
|
||||
unsigned long oldmask;
|
||||
unsigned long cr2;
|
||||
};
|
||||
|
||||
#else /* __x86_64__ */
|
||||
|
||||
struct _fpstate
|
||||
{
|
||||
/* FPU environment matching the 64-bit FXSAVE layout. */
|
||||
__uint16_t cwd;
|
||||
__uint16_t swd;
|
||||
__uint16_t ftw;
|
||||
__uint16_t fop;
|
||||
__uint64_t rip;
|
||||
__uint64_t rdp;
|
||||
__uint32_t mxcsr;
|
||||
__uint32_t mxcr_mask;
|
||||
struct _fpxreg _st[8];
|
||||
struct _xmmreg _xmm[16];
|
||||
__uint32_t __glibc_reserved1[24];
|
||||
};
|
||||
|
||||
struct sigcontext
|
||||
{
|
||||
__uint64_t r8;
|
||||
__uint64_t r9;
|
||||
__uint64_t r10;
|
||||
__uint64_t r11;
|
||||
__uint64_t r12;
|
||||
__uint64_t r13;
|
||||
__uint64_t r14;
|
||||
__uint64_t r15;
|
||||
__uint64_t rdi;
|
||||
__uint64_t rsi;
|
||||
__uint64_t rbp;
|
||||
__uint64_t rbx;
|
||||
__uint64_t rdx;
|
||||
__uint64_t rax;
|
||||
__uint64_t rcx;
|
||||
__uint64_t rsp;
|
||||
__uint64_t rip;
|
||||
__uint64_t eflags;
|
||||
unsigned short cs;
|
||||
unsigned short gs;
|
||||
unsigned short fs;
|
||||
unsigned short __pad0;
|
||||
__uint64_t err;
|
||||
__uint64_t trapno;
|
||||
__uint64_t oldmask;
|
||||
__uint64_t cr2;
|
||||
__extension__ union
|
||||
{
|
||||
struct _fpstate * fpstate;
|
||||
__uint64_t __fpstate_word;
|
||||
};
|
||||
__uint64_t __reserved1 [8];
|
||||
};
|
||||
|
||||
#endif /* __x86_64__ */
|
||||
|
||||
struct _xsave_hdr
|
||||
{
|
||||
__uint64_t xstate_bv;
|
||||
__uint64_t __glibc_reserved1[2];
|
||||
__uint64_t __glibc_reserved2[5];
|
||||
};
|
||||
|
||||
struct _ymmh_state
|
||||
{
|
||||
__uint32_t ymmh_space[64];
|
||||
};
|
||||
|
||||
struct _xstate
|
||||
{
|
||||
struct _fpstate fpstate;
|
||||
struct _xsave_hdr xstate_hdr;
|
||||
struct _ymmh_state ymmh;
|
||||
};
|
||||
|
||||
#endif /* _BITS_SIGCONTEXT_H */
|
||||
17
libc/include/i386-linux-gnu/bits/siginfo-arch.h
Normal file
17
libc/include/i386-linux-gnu/bits/siginfo-arch.h
Normal file
@@ -0,0 +1,17 @@
|
||||
/* Architecture-specific adjustments to siginfo_t. x86 version. */
|
||||
#ifndef _BITS_SIGINFO_ARCH_H
|
||||
#define _BITS_SIGINFO_ARCH_H 1
|
||||
|
||||
#if defined __x86_64__ && __WORDSIZE == 32
|
||||
/* si_utime and si_stime must be 4 byte aligned for x32 to match the
|
||||
kernel. We align siginfo_t to 8 bytes so that si_utime and
|
||||
si_stime are actually aligned to 8 bytes since their offsets are
|
||||
multiple of 8 bytes. Note: with some compilers, the alignment
|
||||
attribute would be ignored if it were put in __SI_CLOCK_T instead
|
||||
of encapsulated in a typedef. */
|
||||
typedef __clock_t __attribute__ ((__aligned__ (4))) __sigchld_clock_t;
|
||||
# define __SI_ALIGNMENT __attribute__ ((__aligned__ (8)))
|
||||
# define __SI_CLOCK_T __sigchld_clock_t
|
||||
#endif
|
||||
|
||||
#endif
|
||||
210
libc/include/i386-linux-gnu/bits/stat.h
Normal file
210
libc/include/i386-linux-gnu/bits/stat.h
Normal file
@@ -0,0 +1,210 @@
|
||||
/* Copyright (C) 1999-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#if !defined _SYS_STAT_H && !defined _FCNTL_H
|
||||
# error "Never include <bits/stat.h> directly; use <sys/stat.h> instead."
|
||||
#endif
|
||||
|
||||
#ifndef _BITS_STAT_H
|
||||
#define _BITS_STAT_H 1
|
||||
|
||||
/* Versions of the `struct stat' data structure. */
|
||||
#ifndef __x86_64__
|
||||
# define _STAT_VER_LINUX_OLD 1
|
||||
# define _STAT_VER_KERNEL 1
|
||||
# define _STAT_VER_SVR4 2
|
||||
# define _STAT_VER_LINUX 3
|
||||
|
||||
/* i386 versions of the `xmknod' interface. */
|
||||
# define _MKNOD_VER_LINUX 1
|
||||
# define _MKNOD_VER_SVR4 2
|
||||
# define _MKNOD_VER _MKNOD_VER_LINUX /* The bits defined below. */
|
||||
#else
|
||||
# define _STAT_VER_KERNEL 0
|
||||
# define _STAT_VER_LINUX 1
|
||||
|
||||
/* x86-64 versions of the `xmknod' interface. */
|
||||
# define _MKNOD_VER_LINUX 0
|
||||
#endif
|
||||
|
||||
#define _STAT_VER _STAT_VER_LINUX
|
||||
|
||||
struct stat
|
||||
{
|
||||
__dev_t st_dev; /* Device. */
|
||||
#ifndef __x86_64__
|
||||
unsigned short int __pad1;
|
||||
#endif
|
||||
#if defined __x86_64__ || !defined __USE_FILE_OFFSET64
|
||||
__ino_t st_ino; /* File serial number. */
|
||||
#else
|
||||
__ino_t __st_ino; /* 32bit file serial number. */
|
||||
#endif
|
||||
#ifndef __x86_64__
|
||||
__mode_t st_mode; /* File mode. */
|
||||
__nlink_t st_nlink; /* Link count. */
|
||||
#else
|
||||
__nlink_t st_nlink; /* Link count. */
|
||||
__mode_t st_mode; /* File mode. */
|
||||
#endif
|
||||
__uid_t st_uid; /* User ID of the file's owner. */
|
||||
__gid_t st_gid; /* Group ID of the file's group.*/
|
||||
#ifdef __x86_64__
|
||||
int __pad0;
|
||||
#endif
|
||||
__dev_t st_rdev; /* Device number, if device. */
|
||||
#ifndef __x86_64__
|
||||
unsigned short int __pad2;
|
||||
#endif
|
||||
#if defined __x86_64__ || !defined __USE_FILE_OFFSET64
|
||||
__off_t st_size; /* Size of file, in bytes. */
|
||||
#else
|
||||
__off64_t st_size; /* Size of file, in bytes. */
|
||||
#endif
|
||||
__blksize_t st_blksize; /* Optimal block size for I/O. */
|
||||
#if defined __x86_64__ || !defined __USE_FILE_OFFSET64
|
||||
__blkcnt_t st_blocks; /* Number 512-byte blocks allocated. */
|
||||
#else
|
||||
__blkcnt64_t st_blocks; /* Number 512-byte blocks allocated. */
|
||||
#endif
|
||||
#ifdef __USE_XOPEN2K8
|
||||
/* Nanosecond resolution timestamps are stored in a format
|
||||
equivalent to 'struct timespec'. This is the type used
|
||||
whenever possible but the Unix namespace rules do not allow the
|
||||
identifier 'timespec' to appear in the <sys/stat.h> header.
|
||||
Therefore we have to handle the use of this header in strictly
|
||||
standard-compliant sources special. */
|
||||
struct timespec st_atim; /* Time of last access. */
|
||||
struct timespec st_mtim; /* Time of last modification. */
|
||||
struct timespec st_ctim; /* Time of last status change. */
|
||||
# define st_atime st_atim.tv_sec /* Backward compatibility. */
|
||||
# define st_mtime st_mtim.tv_sec
|
||||
# define st_ctime st_ctim.tv_sec
|
||||
#else
|
||||
__time_t st_atime; /* Time of last access. */
|
||||
__syscall_ulong_t st_atimensec; /* Nscecs of last access. */
|
||||
__time_t st_mtime; /* Time of last modification. */
|
||||
__syscall_ulong_t st_mtimensec; /* Nsecs of last modification. */
|
||||
__time_t st_ctime; /* Time of last status change. */
|
||||
__syscall_ulong_t st_ctimensec; /* Nsecs of last status change. */
|
||||
#endif
|
||||
#ifdef __x86_64__
|
||||
__syscall_slong_t __glibc_reserved[3];
|
||||
#else
|
||||
# ifndef __USE_FILE_OFFSET64
|
||||
unsigned long int __glibc_reserved4;
|
||||
unsigned long int __glibc_reserved5;
|
||||
# else
|
||||
__ino64_t st_ino; /* File serial number. */
|
||||
# endif
|
||||
#endif
|
||||
};
|
||||
|
||||
#ifdef __USE_LARGEFILE64
|
||||
/* Note stat64 has the same shape as stat for x86-64. */
|
||||
struct stat64
|
||||
{
|
||||
__dev_t st_dev; /* Device. */
|
||||
# ifdef __x86_64__
|
||||
__ino64_t st_ino; /* File serial number. */
|
||||
__nlink_t st_nlink; /* Link count. */
|
||||
__mode_t st_mode; /* File mode. */
|
||||
# else
|
||||
unsigned int __pad1;
|
||||
__ino_t __st_ino; /* 32bit file serial number. */
|
||||
__mode_t st_mode; /* File mode. */
|
||||
__nlink_t st_nlink; /* Link count. */
|
||||
# endif
|
||||
__uid_t st_uid; /* User ID of the file's owner. */
|
||||
__gid_t st_gid; /* Group ID of the file's group.*/
|
||||
# ifdef __x86_64__
|
||||
int __pad0;
|
||||
__dev_t st_rdev; /* Device number, if device. */
|
||||
__off_t st_size; /* Size of file, in bytes. */
|
||||
# else
|
||||
__dev_t st_rdev; /* Device number, if device. */
|
||||
unsigned int __pad2;
|
||||
__off64_t st_size; /* Size of file, in bytes. */
|
||||
# endif
|
||||
__blksize_t st_blksize; /* Optimal block size for I/O. */
|
||||
__blkcnt64_t st_blocks; /* Nr. 512-byte blocks allocated. */
|
||||
# ifdef __USE_XOPEN2K8
|
||||
/* Nanosecond resolution timestamps are stored in a format
|
||||
equivalent to 'struct timespec'. This is the type used
|
||||
whenever possible but the Unix namespace rules do not allow the
|
||||
identifier 'timespec' to appear in the <sys/stat.h> header.
|
||||
Therefore we have to handle the use of this header in strictly
|
||||
standard-compliant sources special. */
|
||||
struct timespec st_atim; /* Time of last access. */
|
||||
struct timespec st_mtim; /* Time of last modification. */
|
||||
struct timespec st_ctim; /* Time of last status change. */
|
||||
# else
|
||||
__time_t st_atime; /* Time of last access. */
|
||||
__syscall_ulong_t st_atimensec; /* Nscecs of last access. */
|
||||
__time_t st_mtime; /* Time of last modification. */
|
||||
__syscall_ulong_t st_mtimensec; /* Nsecs of last modification. */
|
||||
__time_t st_ctime; /* Time of last status change. */
|
||||
__syscall_ulong_t st_ctimensec; /* Nsecs of last status change. */
|
||||
# endif
|
||||
# ifdef __x86_64__
|
||||
__syscall_slong_t __glibc_reserved[3];
|
||||
# else
|
||||
__ino64_t st_ino; /* File serial number. */
|
||||
# endif
|
||||
};
|
||||
#endif
|
||||
|
||||
/* Tell code we have these members. */
|
||||
#define _STATBUF_ST_BLKSIZE
|
||||
#define _STATBUF_ST_RDEV
|
||||
/* Nanosecond resolution time values are supported. */
|
||||
#define _STATBUF_ST_NSEC
|
||||
|
||||
/* Encoding of the file mode. */
|
||||
|
||||
#define __S_IFMT 0170000 /* These bits determine file type. */
|
||||
|
||||
/* File types. */
|
||||
#define __S_IFDIR 0040000 /* Directory. */
|
||||
#define __S_IFCHR 0020000 /* Character device. */
|
||||
#define __S_IFBLK 0060000 /* Block device. */
|
||||
#define __S_IFREG 0100000 /* Regular file. */
|
||||
#define __S_IFIFO 0010000 /* FIFO. */
|
||||
#define __S_IFLNK 0120000 /* Symbolic link. */
|
||||
#define __S_IFSOCK 0140000 /* Socket. */
|
||||
|
||||
/* POSIX.1b objects. Note that these macros always evaluate to zero. But
|
||||
they do it by enforcing the correct use of the macros. */
|
||||
#define __S_TYPEISMQ(buf) ((buf)->st_mode - (buf)->st_mode)
|
||||
#define __S_TYPEISSEM(buf) ((buf)->st_mode - (buf)->st_mode)
|
||||
#define __S_TYPEISSHM(buf) ((buf)->st_mode - (buf)->st_mode)
|
||||
|
||||
/* Protection bits. */
|
||||
|
||||
#define __S_ISUID 04000 /* Set user ID on execution. */
|
||||
#define __S_ISGID 02000 /* Set group ID on execution. */
|
||||
#define __S_ISVTX 01000 /* Save swapped text after use (sticky). */
|
||||
#define __S_IREAD 0400 /* Read by owner. */
|
||||
#define __S_IWRITE 0200 /* Write by owner. */
|
||||
#define __S_IEXEC 0100 /* Execute by owner. */
|
||||
|
||||
#ifdef __USE_ATFILE
|
||||
# define UTIME_NOW ((1l << 30) - 1l)
|
||||
# define UTIME_OMIT ((1l << 30) - 2l)
|
||||
#endif
|
||||
|
||||
#endif /* bits/stat.h */
|
||||
20
libc/include/i386-linux-gnu/bits/sysctl.h
Normal file
20
libc/include/i386-linux-gnu/bits/sysctl.h
Normal file
@@ -0,0 +1,20 @@
|
||||
/* Copyright (C) 2012-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#if defined __x86_64__ && defined __ILP32__
|
||||
# error "sysctl system call is unsupported in x32 kernel"
|
||||
#endif
|
||||
25
libc/include/i386-linux-gnu/bits/timesize.h
Normal file
25
libc/include/i386-linux-gnu/bits/timesize.h
Normal file
@@ -0,0 +1,25 @@
|
||||
/* Bit size of the time_t type at glibc build time, x86-64 and x32 case.
|
||||
Copyright (C) 2018-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#if defined __x86_64__ && defined __ILP32__
|
||||
/* For x32, time is 64-bit even though word size is 32-bit. */
|
||||
# define __TIMESIZE 64
|
||||
#else
|
||||
/* For others, time size is word size. */
|
||||
# define __TIMESIZE __WORDSIZE
|
||||
#endif
|
||||
95
libc/include/i386-linux-gnu/bits/typesizes.h
Normal file
95
libc/include/i386-linux-gnu/bits/typesizes.h
Normal file
@@ -0,0 +1,95 @@
|
||||
/* bits/typesizes.h -- underlying types for *_t. Linux/x86-64 version.
|
||||
Copyright (C) 2012-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _BITS_TYPES_H
|
||||
# error "Never include <bits/typesizes.h> directly; use <sys/types.h> instead."
|
||||
#endif
|
||||
|
||||
#ifndef _BITS_TYPESIZES_H
|
||||
#define _BITS_TYPESIZES_H 1
|
||||
|
||||
/* See <bits/types.h> for the meaning of these macros. This file exists so
|
||||
that <bits/types.h> need not vary across different GNU platforms. */
|
||||
|
||||
/* X32 kernel interface is 64-bit. */
|
||||
#if defined __x86_64__ && defined __ILP32__
|
||||
# define __SYSCALL_SLONG_TYPE __SQUAD_TYPE
|
||||
# define __SYSCALL_ULONG_TYPE __UQUAD_TYPE
|
||||
#else
|
||||
# define __SYSCALL_SLONG_TYPE __SLONGWORD_TYPE
|
||||
# define __SYSCALL_ULONG_TYPE __ULONGWORD_TYPE
|
||||
#endif
|
||||
|
||||
#define __DEV_T_TYPE __UQUAD_TYPE
|
||||
#define __UID_T_TYPE __U32_TYPE
|
||||
#define __GID_T_TYPE __U32_TYPE
|
||||
#define __INO_T_TYPE __SYSCALL_ULONG_TYPE
|
||||
#define __INO64_T_TYPE __UQUAD_TYPE
|
||||
#define __MODE_T_TYPE __U32_TYPE
|
||||
#ifdef __x86_64__
|
||||
# define __NLINK_T_TYPE __SYSCALL_ULONG_TYPE
|
||||
# define __FSWORD_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#else
|
||||
# define __NLINK_T_TYPE __UWORD_TYPE
|
||||
# define __FSWORD_T_TYPE __SWORD_TYPE
|
||||
#endif
|
||||
#define __OFF_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __OFF64_T_TYPE __SQUAD_TYPE
|
||||
#define __PID_T_TYPE __S32_TYPE
|
||||
#define __RLIM_T_TYPE __SYSCALL_ULONG_TYPE
|
||||
#define __RLIM64_T_TYPE __UQUAD_TYPE
|
||||
#define __BLKCNT_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __BLKCNT64_T_TYPE __SQUAD_TYPE
|
||||
#define __FSBLKCNT_T_TYPE __SYSCALL_ULONG_TYPE
|
||||
#define __FSBLKCNT64_T_TYPE __UQUAD_TYPE
|
||||
#define __FSFILCNT_T_TYPE __SYSCALL_ULONG_TYPE
|
||||
#define __FSFILCNT64_T_TYPE __UQUAD_TYPE
|
||||
#define __ID_T_TYPE __U32_TYPE
|
||||
#define __CLOCK_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __TIME_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __USECONDS_T_TYPE __U32_TYPE
|
||||
#define __SUSECONDS_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __DADDR_T_TYPE __S32_TYPE
|
||||
#define __KEY_T_TYPE __S32_TYPE
|
||||
#define __CLOCKID_T_TYPE __S32_TYPE
|
||||
#define __TIMER_T_TYPE void *
|
||||
#define __BLKSIZE_T_TYPE __SYSCALL_SLONG_TYPE
|
||||
#define __FSID_T_TYPE struct { int __val[2]; }
|
||||
#define __SSIZE_T_TYPE __SWORD_TYPE
|
||||
#define __CPU_MASK_TYPE __SYSCALL_ULONG_TYPE
|
||||
|
||||
#ifdef __x86_64__
|
||||
/* Tell the libc code that off_t and off64_t are actually the same type
|
||||
for all ABI purposes, even if possibly expressed as different base types
|
||||
for C type-checking purposes. */
|
||||
# define __OFF_T_MATCHES_OFF64_T 1
|
||||
|
||||
/* Same for ino_t and ino64_t. */
|
||||
# define __INO_T_MATCHES_INO64_T 1
|
||||
|
||||
/* And for __rlim_t and __rlim64_t. */
|
||||
# define __RLIM_T_MATCHES_RLIM64_T 1
|
||||
#else
|
||||
# define __RLIM_T_MATCHES_RLIM64_T 0
|
||||
#endif
|
||||
|
||||
/* Number of descriptors that can fit in an `fd_set'. */
|
||||
#define __FD_SETSIZE 1024
|
||||
|
||||
|
||||
#endif /* bits/typesizes.h */
|
||||
17
libc/include/i386-linux-gnu/bits/wordsize.h
Normal file
17
libc/include/i386-linux-gnu/bits/wordsize.h
Normal file
@@ -0,0 +1,17 @@
|
||||
/* Determine the wordsize from the preprocessor defines. */
|
||||
|
||||
#if defined __x86_64__ && !defined __ILP32__
|
||||
# define __WORDSIZE 64
|
||||
#else
|
||||
# define __WORDSIZE 32
|
||||
#define __WORDSIZE32_SIZE_ULONG 0
|
||||
#define __WORDSIZE32_PTRDIFF_LONG 0
|
||||
#endif
|
||||
|
||||
#ifdef __x86_64__
|
||||
# define __WORDSIZE_TIME64_COMPAT32 1
|
||||
/* Both x86-64 and x32 use the 64-bit system call interface. */
|
||||
# define __SYSCALL_WORDSIZE 64
|
||||
#else
|
||||
# define __WORDSIZE_TIME64_COMPAT32 0
|
||||
#endif
|
||||
33
libc/include/i386-linux-gnu/bits/xtitypes.h
Normal file
33
libc/include/i386-linux-gnu/bits/xtitypes.h
Normal file
@@ -0,0 +1,33 @@
|
||||
/* bits/xtitypes.h -- Define some types used by <bits/stropts.h>. x86-64.
|
||||
Copyright (C) 2002-2019 Free Software Foundation, Inc.
|
||||
This file is part of the GNU C Library.
|
||||
|
||||
The GNU C Library is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU Lesser General Public
|
||||
License as published by the Free Software Foundation; either
|
||||
version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
The GNU C Library is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
Lesser General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Lesser General Public
|
||||
License along with the GNU C Library; if not, see
|
||||
<http://www.gnu.org/licenses/>. */
|
||||
|
||||
#ifndef _STROPTS_H
|
||||
# error "Never include <bits/xtitypes.h> directly; use <stropts.h> instead."
|
||||
#endif
|
||||
|
||||
#ifndef _BITS_XTITYPES_H
|
||||
#define _BITS_XTITYPES_H 1
|
||||
|
||||
#include <bits/types.h>
|
||||
|
||||
/* This type is used by some structs in <bits/stropts.h>. */
|
||||
typedef __SLONG32_TYPE __t_scalar_t;
|
||||
typedef __ULONG32_TYPE __t_uscalar_t;
|
||||
|
||||
|
||||
#endif /* bits/xtitypes.h */
|
||||
Reference in New Issue
Block a user