From b22c31300b1be606a033114165d97eccbeb75275 Mon Sep 17 00:00:00 2001 From: David Malcolm Date: Tue, 24 Mar 2026 17:05:37 -0400 Subject: [PATCH 43/98] FIXME: clang format --- div-by-zero-1.c | 29651 ++++++++++++++++++++-------------------------- 1 file changed, 12967 insertions(+), 16684 deletions(-) diff --git a/div-by-zero-1.c b/div-by-zero-1.c index 0b4890ad5e63..12871e538ec0 100644 --- a/div-by-zero-1.c +++ b/div-by-zero-1.c @@ -2,23 +2,13 @@ typedef __builtin_va_list __gnuc_va_list; typedef __gnuc_va_list va_list; - - - - typedef long unsigned int size_t; - - - - - typedef unsigned char __u_char; typedef unsigned short int __u_short; typedef unsigned int __u_int; typedef unsigned long int __u_long; - typedef signed char __int8_t; typedef unsigned char __uint8_t; typedef signed short int __int16_t; @@ -29,11 +19,6 @@ typedef unsigned int __uint32_t; typedef signed long int __int64_t; typedef unsigned long int __uint64_t; - - - - - typedef __int8_t __int_least8_t; typedef __uint8_t __uint_least8_t; typedef __int16_t __int_least16_t; @@ -43,21 +28,12 @@ typedef __uint32_t __uint_least32_t; typedef __int64_t __int_least64_t; typedef __uint64_t __uint_least64_t; - - typedef long int __quad_t; typedef unsigned long int __u_quad_t; - - - - - - typedef long int __intmax_t; typedef unsigned long int __uintmax_t; - typedef unsigned long int __dev_t; typedef unsigned int __uid_t; typedef unsigned int __gid_t; @@ -68,7 +44,9 @@ typedef unsigned long int __nlink_t; typedef long int __off_t; typedef long int __off64_t; typedef int __pid_t; -typedef struct { int __val[2]; } __fsid_t; +typedef struct { + int __val[2]; +} __fsid_t; typedef long int __clock_t; typedef unsigned long int __rlim_t; typedef unsigned long int __rlim64_t; @@ -80,112 +58,71 @@ typedef long int __suseconds_t; typedef int __daddr_t; typedef int __key_t; - typedef int __clockid_t; - -typedef void * __timer_t; - +typedef void *__timer_t; typedef long int __blksize_t; - - - typedef long int __blkcnt_t; typedef long int __blkcnt64_t; - typedef unsigned long int __fsblkcnt_t; typedef unsigned long int __fsblkcnt64_t; - typedef unsigned long int __fsfilcnt_t; typedef unsigned long int __fsfilcnt64_t; - typedef long int __fsword_t; typedef long int __ssize_t; - typedef long int __syscall_slong_t; typedef unsigned long int __syscall_ulong_t; - - typedef __off64_t __loff_t; typedef char *__caddr_t; - typedef long int __intptr_t; - typedef unsigned int __socklen_t; - - - typedef int __sig_atomic_t; - - - -typedef struct -{ +typedef struct { int __count; - union - { + union { unsigned int __wch; char __wchb[4]; } __value; } __mbstate_t; - - - -typedef struct _G_fpos_t -{ +typedef struct _G_fpos_t { __off_t __pos; __mbstate_t __state; } __fpos_t; -typedef struct _G_fpos64_t -{ +typedef struct _G_fpos64_t { __off64_t __pos; __mbstate_t __state; } __fpos64_t; - - struct _IO_FILE; typedef struct _IO_FILE __FILE; - - struct _IO_FILE; - typedef struct _IO_FILE FILE; struct _IO_FILE; struct _IO_marker; struct _IO_codecvt; struct _IO_wide_data; - - - typedef void _IO_lock_t; - - - - -struct _IO_FILE -{ +struct _IO_FILE { int _flags; - char *_IO_read_ptr; char *_IO_read_end; char *_IO_read_base; @@ -195,7 +132,6 @@ struct _IO_FILE char *_IO_buf_base; char *_IO_buf_end; - char *_IO_save_base; char *_IO_backup_base; char *_IO_save_end; @@ -208,19 +144,12 @@ struct _IO_FILE int _flags2; __off_t _old_offset; - unsigned short _cur_column; signed char _vtable_offset; char _shortbuf[1]; _IO_lock_t *_lock; - - - - - - __off64_t _offset; struct _IO_codecvt *_codecvt; @@ -230,40 +159,20 @@ struct _IO_FILE size_t __pad5; int _mode; - char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)]; + char _unused2[15 * sizeof(int) - 4 * sizeof(void *) - sizeof(size_t)]; }; +typedef __ssize_t cookie_read_function_t(void *__cookie, char *__buf, + size_t __nbytes); -typedef __ssize_t cookie_read_function_t (void *__cookie, char *__buf, +typedef __ssize_t cookie_write_function_t(void *__cookie, const char *__buf, size_t __nbytes); +typedef int cookie_seek_function_t(void *__cookie, __off64_t *__pos, int __w); +typedef int cookie_close_function_t(void *__cookie); - - - - -typedef __ssize_t cookie_write_function_t (void *__cookie, const char *__buf, - size_t __nbytes); - - - - - - - -typedef int cookie_seek_function_t (void *__cookie, __off64_t *__pos, int __w); - - -typedef int cookie_close_function_t (void *__cookie); - - - - - - -typedef struct _IO_cookie_io_functions_t -{ +typedef struct _IO_cookie_io_functions_t { cookie_read_function_t *read; cookie_write_function_t *write; cookie_seek_function_t *seek; @@ -271,10627 +180,8214 @@ typedef struct _IO_cookie_io_functions_t } cookie_io_functions_t; typedef __off_t off_t; - - - - - typedef __off64_t off64_t; - - - - - typedef __ssize_t ssize_t; - - - - - typedef __fpos_t fpos_t; - - - typedef __fpos64_t fpos64_t; - - extern FILE *stdin; extern FILE *stdout; extern FILE *stderr; +extern int remove(const char *__filename) + __attribute__((__nothrow__, __leaf__)); +extern int rename(const char *__old, const char *__new) + __attribute__((__nothrow__, __leaf__)); +extern int renameat(int __oldfd, const char *__old, int __newfd, + const char *__new) __attribute__((__nothrow__, __leaf__)); +extern int renameat2(int __oldfd, const char *__old, int __newfd, + const char *__new, unsigned int __flags) + __attribute__((__nothrow__, __leaf__)); +extern FILE *tmpfile(void); +extern FILE *tmpfile64(void); +extern char *tmpnam(char *__s) __attribute__((__nothrow__, __leaf__)); -extern int remove (const char *__filename) __attribute__ ((__nothrow__ , __leaf__)); +extern char *tmpnam_r(char *__s) __attribute__((__nothrow__, __leaf__)); +extern char *tempnam(const char *__dir, const char *__pfx) + __attribute__((__nothrow__, __leaf__)) __attribute__((__malloc__)); -extern int rename (const char *__old, const char *__new) __attribute__ ((__nothrow__ , __leaf__)); +extern int fclose(FILE *__stream); +extern int fflush(FILE *__stream); +extern int fflush_unlocked(FILE *__stream); +extern int fcloseall(void); +extern FILE *fopen(const char *__restrict __filename, + const char *__restrict __modes); +extern FILE *freopen(const char *__restrict __filename, + const char *__restrict __modes, FILE *__restrict __stream); +extern FILE *fopen64(const char *__restrict __filename, + const char *__restrict __modes); +extern FILE *freopen64(const char *__restrict __filename, + const char *__restrict __modes, + FILE *__restrict __stream); -extern int renameat (int __oldfd, const char *__old, int __newfd, - const char *__new) __attribute__ ((__nothrow__ , __leaf__)); -extern int renameat2 (int __oldfd, const char *__old, int __newfd, - const char *__new, unsigned int __flags) __attribute__ ((__nothrow__ , __leaf__)); +extern FILE *fdopen(int __fd, const char *__modes) + __attribute__((__nothrow__, __leaf__)); +extern FILE *fopencookie(void *__restrict __magic_cookie, + const char *__restrict __modes, + cookie_io_functions_t __io_funcs) + __attribute__((__nothrow__, __leaf__)); +extern FILE *fmemopen(void *__s, size_t __len, const char *__modes) + __attribute__((__nothrow__, __leaf__)); +extern FILE *open_memstream(char **__bufloc, size_t *__sizeloc) + __attribute__((__nothrow__, __leaf__)); +extern void setbuf(FILE *__restrict __stream, char *__restrict __buf) + __attribute__((__nothrow__, __leaf__)); +extern int setvbuf(FILE *__restrict __stream, char *__restrict __buf, + int __modes, size_t __n) + __attribute__((__nothrow__, __leaf__)); +extern void setbuffer(FILE *__restrict __stream, char *__restrict __buf, + size_t __size) __attribute__((__nothrow__, __leaf__)); -extern FILE *tmpfile (void) ; -extern FILE *tmpfile64 (void) ; +extern void setlinebuf(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int fprintf(FILE *__restrict __stream, const char *__restrict __format, + ...); +extern int printf(const char *__restrict __format, ...); -extern char *tmpnam (char *__s) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int sprintf(char *__restrict __s, const char *__restrict __format, ...) + __attribute__((__nothrow__)); +extern int vfprintf(FILE *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg); +extern int vprintf(const char *__restrict __format, __gnuc_va_list __arg); +extern int vsprintf(char *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) __attribute__((__nothrow__)); -extern char *tmpnam_r (char *__s) __attribute__ ((__nothrow__ , __leaf__)) ; -extern char *tempnam (const char *__dir, const char *__pfx) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) ; +extern int snprintf(char *__restrict __s, size_t __maxlen, + const char *__restrict __format, ...) + __attribute__((__nothrow__)) __attribute__((__format__(__printf__, 3, 4))); +extern int vsnprintf(char *__restrict __s, size_t __maxlen, + const char *__restrict __format, __gnuc_va_list __arg) + __attribute__((__nothrow__)) __attribute__((__format__(__printf__, 3, 0))); +extern int vasprintf(char **__restrict __ptr, const char *__restrict __f, + __gnuc_va_list __arg) __attribute__((__nothrow__)) +__attribute__((__format__(__printf__, 2, 0))); +extern int __asprintf(char **__restrict __ptr, const char *__restrict __fmt, + ...) __attribute__((__nothrow__)) +__attribute__((__format__(__printf__, 2, 3))); +extern int asprintf(char **__restrict __ptr, const char *__restrict __fmt, ...) + __attribute__((__nothrow__)) __attribute__((__format__(__printf__, 2, 3))); +extern int vdprintf(int __fd, const char *__restrict __fmt, + __gnuc_va_list __arg) + __attribute__((__format__(__printf__, 2, 0))); +extern int dprintf(int __fd, const char *__restrict __fmt, ...) + __attribute__((__format__(__printf__, 2, 3))); +extern int fscanf(FILE *__restrict __stream, const char *__restrict __format, + ...); +extern int scanf(const char *__restrict __format, ...); +extern int sscanf(const char *__restrict __s, const char *__restrict __format, + ...) __attribute__((__nothrow__, __leaf__)); -extern int fclose (FILE *__stream); +extern int fscanf(FILE *__restrict __stream, const char *__restrict __format, + ...) __asm__("" + "__isoc99_fscanf") + ; +extern int scanf(const char *__restrict __format, + ...) __asm__("" + "__isoc99_scanf"); +extern int sscanf(const char *__restrict __s, const char *__restrict __format, + ...) __asm__("" + "__isoc99_sscanf") + __attribute__((__nothrow__, __leaf__)) + ; +extern int vfscanf(FILE *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) + __attribute__((__format__(__scanf__, 2, 0))); +extern int vscanf(const char *__restrict __format, __gnuc_va_list __arg) + __attribute__((__format__(__scanf__, 1, 0))); -extern int fflush (FILE *__stream); -extern int fflush_unlocked (FILE *__stream); -extern int fcloseall (void); -extern FILE *fopen (const char *__restrict __filename, - const char *__restrict __modes) ; +extern int vsscanf(const char *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) __attribute__((__nothrow__, __leaf__)) +__attribute__((__format__(__scanf__, 2, 0))); +extern int vfscanf(FILE *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) __asm__("" + "__isoc99_vfscanf") + __attribute__((__format__(__scanf__, 2, 0))); +extern int vscanf(const char *__restrict __format, + __gnuc_va_list __arg) __asm__("" + "__isoc99_vscanf") + __attribute__((__format__(__scanf__, 1, 0))); +extern int vsscanf(const char *__restrict __s, const char *__restrict __format, + __gnuc_va_list __arg) __asm__("" + "__isoc99_vsscanf") + __attribute__((__nothrow__, __leaf__)) -extern FILE *freopen (const char *__restrict __filename, - const char *__restrict __modes, - FILE *__restrict __stream) ; -extern FILE *fopen64 (const char *__restrict __filename, - const char *__restrict __modes) ; -extern FILE *freopen64 (const char *__restrict __filename, - const char *__restrict __modes, - FILE *__restrict __stream) ; + __attribute__((__format__(__scanf__, 2, 0))); +extern int fgetc(FILE *__stream); +extern int getc(FILE *__stream); +extern int getchar(void); +extern int getc_unlocked(FILE *__stream); +extern int getchar_unlocked(void); +extern int fgetc_unlocked(FILE *__stream); +extern int fputc(int __c, FILE *__stream); +extern int putc(int __c, FILE *__stream); +extern int putchar(int __c); +extern int fputc_unlocked(int __c, FILE *__stream); -extern FILE *fdopen (int __fd, const char *__modes) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int putc_unlocked(int __c, FILE *__stream); +extern int putchar_unlocked(int __c); +extern int getw(FILE *__stream); +extern int putw(int __w, FILE *__stream); +extern char *fgets(char *__restrict __s, int __n, FILE *__restrict __stream); +extern char *fgets_unlocked(char *__restrict __s, int __n, + FILE *__restrict __stream); +extern __ssize_t __getdelim(char **__restrict __lineptr, size_t *__restrict __n, + int __delimiter, FILE *__restrict __stream); +extern __ssize_t getdelim(char **__restrict __lineptr, size_t *__restrict __n, + int __delimiter, FILE *__restrict __stream); +extern __ssize_t getline(char **__restrict __lineptr, size_t *__restrict __n, + FILE *__restrict __stream); -extern FILE *fopencookie (void *__restrict __magic_cookie, - const char *__restrict __modes, - cookie_io_functions_t __io_funcs) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int fputs(const char *__restrict __s, FILE *__restrict __stream); +extern int puts(const char *__s); +extern int ungetc(int __c, FILE *__stream); +extern size_t fread(void *__restrict __ptr, size_t __size, size_t __n, + FILE *__restrict __stream); -extern FILE *fmemopen (void *__s, size_t __len, const char *__modes) - __attribute__ ((__nothrow__ , __leaf__)) ; +extern size_t fwrite(const void *__restrict __ptr, size_t __size, size_t __n, + FILE *__restrict __s); +extern int fputs_unlocked(const char *__restrict __s, + FILE *__restrict __stream); +extern size_t fread_unlocked(void *__restrict __ptr, size_t __size, size_t __n, + FILE *__restrict __stream); +extern size_t fwrite_unlocked(const void *__restrict __ptr, size_t __size, + size_t __n, FILE *__restrict __stream); +extern int fseek(FILE *__stream, long int __off, int __whence); +extern long int ftell(FILE *__stream); +extern void rewind(FILE *__stream); +extern int fseeko(FILE *__stream, __off_t __off, int __whence); -extern FILE *open_memstream (char **__bufloc, size_t *__sizeloc) __attribute__ ((__nothrow__ , __leaf__)) ; +extern __off_t ftello(FILE *__stream); +extern int fgetpos(FILE *__restrict __stream, fpos_t *__restrict __pos); +extern int fsetpos(FILE *__stream, const fpos_t *__pos); +extern int fseeko64(FILE *__stream, __off64_t __off, int __whence); +extern __off64_t ftello64(FILE *__stream); +extern int fgetpos64(FILE *__restrict __stream, fpos64_t *__restrict __pos); +extern int fsetpos64(FILE *__stream, const fpos64_t *__pos); +extern void clearerr(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int feof(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int ferror(FILE *__stream) __attribute__((__nothrow__, __leaf__)); -extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)); +extern void clearerr_unlocked(FILE *__stream) + __attribute__((__nothrow__, __leaf__)); +extern int feof_unlocked(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int ferror_unlocked(FILE *__stream) + __attribute__((__nothrow__, __leaf__)); +extern void perror(const char *__s); +extern int sys_nerr; +extern const char *const sys_errlist[]; -extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf, - int __modes, size_t __n) __attribute__ ((__nothrow__ , __leaf__)); +extern int _sys_nerr; +extern const char *const _sys_errlist[]; +extern int fileno(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int fileno_unlocked(FILE *__stream) + __attribute__((__nothrow__, __leaf__)); +extern FILE *popen(const char *__command, const char *__modes); +extern int pclose(FILE *__stream); -extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf, - size_t __size) __attribute__ ((__nothrow__ , __leaf__)); +extern char *ctermid(char *__s) __attribute__((__nothrow__, __leaf__)); +extern char *cuserid(char *__s); -extern void setlinebuf (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); +struct obstack; +extern int obstack_printf(struct obstack *__restrict __obstack, + const char *__restrict __format, ...) + __attribute__((__nothrow__)) __attribute__((__format__(__printf__, 2, 3))); +extern int obstack_vprintf(struct obstack *__restrict __obstack, + const char *__restrict __format, + __gnuc_va_list __args) __attribute__((__nothrow__)) +__attribute__((__format__(__printf__, 2, 0))); +extern void flockfile(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int ftrylockfile(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern void funlockfile(FILE *__stream) __attribute__((__nothrow__, __leaf__)); +extern int __uflow(FILE *); +extern int __overflow(FILE *, int); +struct timespec { + __time_t tv_sec; + __syscall_slong_t tv_nsec; +}; -extern int fprintf (FILE *__restrict __stream, - const char *__restrict __format, ...); +typedef __time_t time_t; +typedef __dev_t dev_t; +typedef __gid_t gid_t; +typedef __ino_t ino_t; -extern int printf (const char *__restrict __format, ...); +typedef __mode_t mode_t; -extern int sprintf (char *__restrict __s, - const char *__restrict __format, ...) __attribute__ ((__nothrow__)); +typedef __nlink_t nlink_t; +typedef __uid_t uid_t; +typedef __blkcnt_t blkcnt_t; +typedef __blksize_t blksize_t; +struct stat { + __dev_t st_dev; + __ino_t st_ino; -extern int vfprintf (FILE *__restrict __s, const char *__restrict __format, - __gnuc_va_list __arg); + __nlink_t st_nlink; + __mode_t st_mode; + __uid_t st_uid; + __gid_t st_gid; + int __pad0; + __dev_t st_rdev; -extern int vprintf (const char *__restrict __format, __gnuc_va_list __arg); + __off_t st_size; -extern int vsprintf (char *__restrict __s, const char *__restrict __format, - __gnuc_va_list __arg) __attribute__ ((__nothrow__)); + __blksize_t st_blksize; + __blkcnt_t st_blocks; + struct timespec st_atim; + struct timespec st_mtim; + struct timespec st_ctim; + __syscall_slong_t __glibc_reserved[3]; +}; +struct stat64 { + __dev_t st_dev; -extern int snprintf (char *__restrict __s, size_t __maxlen, - const char *__restrict __format, ...) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 4))); + __ino64_t st_ino; + __nlink_t st_nlink; + __mode_t st_mode; -extern int vsnprintf (char *__restrict __s, size_t __maxlen, - const char *__restrict __format, __gnuc_va_list __arg) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 3, 0))); + __uid_t st_uid; + __gid_t st_gid; + int __pad0; + __dev_t st_rdev; + __off_t st_size; + __blksize_t st_blksize; + __blkcnt64_t st_blocks; + struct timespec st_atim; + struct timespec st_mtim; + struct timespec st_ctim; + __syscall_slong_t __glibc_reserved[3]; +}; +extern int stat(const char *__restrict __file, struct stat *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int fstat(int __fd, struct stat *__buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int stat64(const char *__restrict __file, + struct stat64 *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int fstat64(int __fd, struct stat64 *__buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int fstatat(int __fd, const char *__restrict __file, + struct stat *__restrict __buf, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int fstatat64(int __fd, const char *__restrict __file, + struct stat64 *__restrict __buf, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); + +extern int lstat(const char *__restrict __file, struct stat *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int lstat64(const char *__restrict __file, + struct stat64 *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int chmod(const char *__file, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int lchmod(const char *__file, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int fchmod(int __fd, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)); + +extern int fchmodat(int __fd, const char *__file, __mode_t __mode, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern __mode_t umask(__mode_t __mask) __attribute__((__nothrow__, __leaf__)); + +extern __mode_t getumask(void) __attribute__((__nothrow__, __leaf__)); + +extern int mkdir(const char *__path, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int mkdirat(int __fd, const char *__path, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int mknod(const char *__path, __mode_t __mode, __dev_t __dev) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int mknodat(int __fd, const char *__path, __mode_t __mode, __dev_t __dev) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int mkfifo(const char *__path, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int mkfifoat(int __fd, const char *__path, __mode_t __mode) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int utimensat(int __fd, const char *__path, + const struct timespec __times[2], int __flags) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int futimens(int __fd, const struct timespec __times[2]) + __attribute__((__nothrow__, __leaf__)); +extern int __fxstat(int __ver, int __fildes, struct stat *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int __xstat(int __ver, const char *__filename, struct stat *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int __lxstat(int __ver, const char *__filename, struct stat *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int __fxstatat(int __ver, int __fildes, const char *__filename, + struct stat *__stat_buf, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3, 4))); +extern int __fxstat64(int __ver, int __fildes, struct stat64 *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int __xstat64(int __ver, const char *__filename, + struct stat64 *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int __lxstat64(int __ver, const char *__filename, + struct stat64 *__stat_buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int __fxstatat64(int __ver, int __fildes, const char *__filename, + struct stat64 *__stat_buf, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3, 4))); + +extern int __xmknod(int __ver, const char *__path, __mode_t __mode, + __dev_t *__dev) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(2, 4))); + +extern int __xmknodat(int __ver, int __fd, const char *__path, __mode_t __mode, + __dev_t *__dev) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3, 5))); +typedef __signed__ char __s8; +typedef unsigned char __u8; -extern int vasprintf (char **__restrict __ptr, const char *__restrict __f, - __gnuc_va_list __arg) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 2, 0))) ; -extern int __asprintf (char **__restrict __ptr, - const char *__restrict __fmt, ...) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 2, 3))) ; -extern int asprintf (char **__restrict __ptr, - const char *__restrict __fmt, ...) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 2, 3))) ; +typedef __signed__ short __s16; +typedef unsigned short __u16; +typedef __signed__ int __s32; +typedef unsigned int __u32; +__extension__ typedef __signed__ long long __s64; +__extension__ typedef unsigned long long __u64; +typedef struct { + unsigned long fds_bits[1024 / (8 * sizeof(long))]; +} __kernel_fd_set; -extern int vdprintf (int __fd, const char *__restrict __fmt, - __gnuc_va_list __arg) - __attribute__ ((__format__ (__printf__, 2, 0))); -extern int dprintf (int __fd, const char *__restrict __fmt, ...) - __attribute__ ((__format__ (__printf__, 2, 3))); +typedef void (*__kernel_sighandler_t)(int); +typedef int __kernel_key_t; +typedef int __kernel_mqd_t; +typedef unsigned short __kernel_old_uid_t; +typedef unsigned short __kernel_old_gid_t; +typedef unsigned long __kernel_old_dev_t; +typedef long __kernel_long_t; +typedef unsigned long __kernel_ulong_t; +typedef __kernel_ulong_t __kernel_ino_t; +typedef unsigned int __kernel_mode_t; -extern int fscanf (FILE *__restrict __stream, - const char *__restrict __format, ...) ; +typedef int __kernel_pid_t; +typedef int __kernel_ipc_pid_t; +typedef unsigned int __kernel_uid_t; +typedef unsigned int __kernel_gid_t; +typedef __kernel_long_t __kernel_suseconds_t; -extern int scanf (const char *__restrict __format, ...) ; +typedef int __kernel_daddr_t; -extern int sscanf (const char *__restrict __s, - const char *__restrict __format, ...) __attribute__ ((__nothrow__ , __leaf__)); +typedef unsigned int __kernel_uid32_t; +typedef unsigned int __kernel_gid32_t; +typedef __kernel_ulong_t __kernel_size_t; +typedef __kernel_long_t __kernel_ssize_t; +typedef __kernel_long_t __kernel_ptrdiff_t; +typedef struct { + int val[2]; +} __kernel_fsid_t; +typedef __kernel_long_t __kernel_off_t; +typedef long long __kernel_loff_t; +typedef __kernel_long_t __kernel_old_time_t; +typedef __kernel_long_t __kernel_time_t; +typedef long long __kernel_time64_t; +typedef __kernel_long_t __kernel_clock_t; +typedef int __kernel_timer_t; +typedef int __kernel_clockid_t; +typedef char *__kernel_caddr_t; +typedef unsigned short __kernel_uid16_t; +typedef unsigned short __kernel_gid16_t; +typedef __u16 __le16; +typedef __u16 __be16; +typedef __u32 __le32; +typedef __u32 __be32; +typedef __u64 __le64; +typedef __u64 __be64; +typedef __u16 __sum16; +typedef __u32 __wsum; +typedef unsigned __poll_t; +struct statx_timestamp { + __s64 tv_sec; + __u32 tv_nsec; + __s32 __reserved; +}; +struct statx { + __u32 stx_mask; + __u32 stx_blksize; + __u64 stx_attributes; + __u32 stx_nlink; + __u32 stx_uid; + __u32 stx_gid; + __u16 stx_mode; + __u16 __spare0[1]; -extern int fscanf (FILE *__restrict __stream, const char *__restrict __format, ...) __asm__ ("" "__isoc99_fscanf") + __u64 stx_ino; + __u64 stx_size; + __u64 stx_blocks; + __u64 stx_attributes_mask; - ; -extern int scanf (const char *__restrict __format, ...) __asm__ ("" "__isoc99_scanf") - ; -extern int sscanf (const char *__restrict __s, const char *__restrict __format, ...) __asm__ ("" "__isoc99_sscanf") __attribute__ ((__nothrow__ , __leaf__)) + struct statx_timestamp stx_atime; + struct statx_timestamp stx_btime; + struct statx_timestamp stx_ctime; + struct statx_timestamp stx_mtime; - ; -extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, - __gnuc_va_list __arg) - __attribute__ ((__format__ (__scanf__, 2, 0))) ; + __u32 stx_rdev_major; + __u32 stx_rdev_minor; + __u32 stx_dev_major; + __u32 stx_dev_minor; + __u64 stx_mnt_id; + __u64 __spare2; + __u64 __spare3[12]; +}; +int statx(int __dirfd, const char *__restrict __path, int __flags, + unsigned int __mask, struct statx *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 5))); +typedef int wchar_t; -extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) - __attribute__ ((__format__ (__scanf__, 1, 0))) ; +typedef struct { + int quot; + int rem; +} div_t; +typedef struct { + long int quot; + long int rem; +} ldiv_t; + +__extension__ typedef struct { + long long int quot; + long long int rem; +} lldiv_t; +extern size_t __ctype_get_mb_cur_max(void) + __attribute__((__nothrow__, __leaf__)); + +extern double atof(const char *__nptr) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1))); + +extern int atoi(const char *__nptr) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1))); + +extern long int atol(const char *__nptr) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1))); + +__extension__ extern long long int atoll(const char *__nptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); + +extern double strtod(const char *__restrict __nptr, char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern float strtof(const char *__restrict __nptr, char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern long double strtold(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern _Float32 strtof32(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern _Float64 strtof64(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern _Float128 strtof128(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern _Float32x strtof32x(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern _Float64x strtof64x(const char *__restrict __nptr, + char **__restrict __endptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern long int strtol(const char *__restrict __nptr, + char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern unsigned long int strtoul(const char *__restrict __nptr, + char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +__extension__ extern long long int +strtoq(const char *__restrict __nptr, char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +__extension__ extern unsigned long long int +strtouq(const char *__restrict __nptr, char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +__extension__ extern long long int +strtoll(const char *__restrict __nptr, char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +__extension__ extern unsigned long long int +strtoull(const char *__restrict __nptr, char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int strfromd(char *__dest, size_t __size, const char *__format, + double __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfromf(char *__dest, size_t __size, const char *__format, + float __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfroml(char *__dest, size_t __size, const char *__format, + long double __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); +extern int strfromf32(char *__dest, size_t __size, const char *__format, + _Float32 __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfromf64(char *__dest, size_t __size, const char *__format, + _Float64 __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfromf128(char *__dest, size_t __size, const char *__format, + _Float128 __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfromf32x(char *__dest, size_t __size, const char *__format, + _Float32x __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); + +extern int strfromf64x(char *__dest, size_t __size, const char *__format, + _Float64x __f) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3))); +struct __locale_struct { -extern int vsscanf (const char *__restrict __s, - const char *__restrict __format, __gnuc_va_list __arg) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__format__ (__scanf__, 2, 0))); + struct __locale_data *__locales[13]; + const unsigned short int *__ctype_b; + const int *__ctype_tolower; + const int *__ctype_toupper; + const char *__names[13]; +}; +typedef struct __locale_struct *__locale_t; -extern int vfscanf (FILE *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vfscanf") +typedef __locale_t locale_t; +extern long int strtol_l(const char *__restrict __nptr, + char **__restrict __endptr, int __base, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 4))); +extern unsigned long int strtoul_l(const char *__restrict __nptr, + char **__restrict __endptr, int __base, + locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 4))); - __attribute__ ((__format__ (__scanf__, 2, 0))) ; -extern int vscanf (const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vscanf") +__extension__ extern long long int strtoll_l(const char *__restrict __nptr, + char **__restrict __endptr, + int __base, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 4))); - __attribute__ ((__format__ (__scanf__, 1, 0))) ; -extern int vsscanf (const char *__restrict __s, const char *__restrict __format, __gnuc_va_list __arg) __asm__ ("" "__isoc99_vsscanf") __attribute__ ((__nothrow__ , __leaf__)) +__extension__ extern unsigned long long int +strtoull_l(const char *__restrict __nptr, char **__restrict __endptr, + int __base, locale_t __loc) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 4))); +extern double strtod_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern float strtof_l(const char *__restrict __nptr, char **__restrict __endptr, + locale_t __loc) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 3))); - __attribute__ ((__format__ (__scanf__, 2, 0))); -extern int fgetc (FILE *__stream); -extern int getc (FILE *__stream); +extern long double strtold_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern _Float32 strtof32_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern _Float64 strtof64_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern _Float128 strtof128_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern _Float32x strtof32x_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern _Float64x strtof64x_l(const char *__restrict __nptr, + char **__restrict __endptr, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern char *l64a(long int __n) __attribute__((__nothrow__, __leaf__)); -extern int getchar (void); +extern long int a64l(const char *__s) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1))); +typedef __u_char u_char; +typedef __u_short u_short; +typedef __u_int u_int; +typedef __u_long u_long; +typedef __quad_t quad_t; +typedef __u_quad_t u_quad_t; +typedef __fsid_t fsid_t; +typedef __loff_t loff_t; +typedef __ino64_t ino64_t; +typedef __pid_t pid_t; +typedef __id_t id_t; +typedef __daddr_t daddr_t; +typedef __caddr_t caddr_t; +typedef __key_t key_t; +typedef __clock_t clock_t; -extern int getc_unlocked (FILE *__stream); -extern int getchar_unlocked (void); -extern int fgetc_unlocked (FILE *__stream); -extern int fputc (int __c, FILE *__stream); -extern int putc (int __c, FILE *__stream); +typedef __clockid_t clockid_t; +typedef __timer_t timer_t; +typedef __useconds_t useconds_t; +typedef __suseconds_t suseconds_t; +typedef unsigned long int ulong; +typedef unsigned short int ushort; +typedef unsigned int uint; -extern int putchar (int __c); -extern int fputc_unlocked (int __c, FILE *__stream); +typedef __int8_t int8_t; +typedef __int16_t int16_t; +typedef __int32_t int32_t; +typedef __int64_t int64_t; +typedef __uint8_t u_int8_t; +typedef __uint16_t u_int16_t; +typedef __uint32_t u_int32_t; +typedef __uint64_t u_int64_t; +typedef int register_t __attribute__((__mode__(__word__))); +static __inline __uint16_t __bswap_16(__uint16_t __bsx) { + return __builtin_bswap16(__bsx); +} +static __inline __uint32_t __bswap_32(__uint32_t __bsx) { + return __builtin_bswap32(__bsx); +} +__extension__ static __inline __uint64_t __bswap_64(__uint64_t __bsx) { + return __builtin_bswap64(__bsx); +} +static __inline __uint16_t __uint16_identity(__uint16_t __x) { return __x; } -extern int putc_unlocked (int __c, FILE *__stream); -extern int putchar_unlocked (int __c); +static __inline __uint32_t __uint32_identity(__uint32_t __x) { return __x; } +static __inline __uint64_t __uint64_identity(__uint64_t __x) { return __x; } +typedef struct { + unsigned long int __val[(1024 / (8 * sizeof(unsigned long int)))]; +} __sigset_t; +typedef __sigset_t sigset_t; +struct timeval { + __time_t tv_sec; + __suseconds_t tv_usec; +}; +typedef long int __fd_mask; +typedef struct { + __fd_mask fds_bits[1024 / (8 * (int)sizeof(__fd_mask))]; -extern int getw (FILE *__stream); +} fd_set; +typedef __fd_mask fd_mask; -extern int putw (int __w, FILE *__stream); +extern int select(int __nfds, fd_set *__restrict __readfds, + fd_set *__restrict __writefds, fd_set *__restrict __exceptfds, + struct timeval *__restrict __timeout); +extern int pselect(int __nfds, fd_set *__restrict __readfds, + fd_set *__restrict __writefds, + fd_set *__restrict __exceptfds, + const struct timespec *__restrict __timeout, + const __sigset_t *__restrict __sigmask); +typedef __fsblkcnt_t fsblkcnt_t; +typedef __fsfilcnt_t fsfilcnt_t; +typedef __blkcnt64_t blkcnt64_t; +typedef __fsblkcnt64_t fsblkcnt64_t; +typedef __fsfilcnt64_t fsfilcnt64_t; +typedef struct __pthread_internal_list { + struct __pthread_internal_list *__prev; + struct __pthread_internal_list *__next; +} __pthread_list_t; +typedef struct __pthread_internal_slist { + struct __pthread_internal_slist *__next; +} __pthread_slist_t; +struct __pthread_mutex_s { + int __lock; + unsigned int __count; + int __owner; + unsigned int __nusers; + int __kind; -extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream) - ; -extern char *fgets_unlocked (char *__restrict __s, int __n, - FILE *__restrict __stream) ; -extern __ssize_t __getdelim (char **__restrict __lineptr, - size_t *__restrict __n, int __delimiter, - FILE *__restrict __stream) ; -extern __ssize_t getdelim (char **__restrict __lineptr, - size_t *__restrict __n, int __delimiter, - FILE *__restrict __stream) ; - - + short __spins; + short __elision; + __pthread_list_t __list; +}; +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; + int __cur_writer; + int __shared; + signed char __rwelision; + unsigned char __pad1[7]; + unsigned long int __pad2; + unsigned int __flags; +}; -extern __ssize_t getline (char **__restrict __lineptr, - size_t *__restrict __n, - FILE *__restrict __stream) ; +struct __pthread_cond_s { + __extension__ union { + __extension__ unsigned long long int __wseq; + struct { + unsigned int __low; + unsigned int __high; + } __wseq32; + }; + __extension__ union { + __extension__ unsigned long long int __g1_start; + struct { + unsigned int __low; + unsigned int __high; + } __g1_start32; + }; + unsigned int __g_refs[2]; + unsigned int __g_size[2]; + unsigned int __g1_orig_size; + unsigned int __wrefs; + unsigned int __g_signals[2]; +}; +typedef unsigned long int pthread_t; +typedef union { + char __size[4]; + int __align; +} pthread_mutexattr_t; +typedef union { + char __size[4]; + int __align; +} pthread_condattr_t; +typedef unsigned int pthread_key_t; +typedef int pthread_once_t; +union pthread_attr_t { + char __size[56]; + long int __align; +}; -extern int fputs (const char *__restrict __s, FILE *__restrict __stream); +typedef union pthread_attr_t pthread_attr_t; +typedef union { + struct __pthread_mutex_s __data; + char __size[40]; + long int __align; +} pthread_mutex_t; +typedef union { + struct __pthread_cond_s __data; + char __size[48]; + __extension__ long long int __align; +} pthread_cond_t; +typedef union { + struct __pthread_rwlock_arch_t __data; + char __size[56]; + long int __align; +} pthread_rwlock_t; +typedef union { + char __size[8]; + long int __align; +} pthread_rwlockattr_t; -extern int puts (const char *__s); +typedef volatile int pthread_spinlock_t; +typedef union { + char __size[32]; + long int __align; +} pthread_barrier_t; +typedef union { + char __size[4]; + int __align; +} pthread_barrierattr_t; +extern long int random(void) __attribute__((__nothrow__, __leaf__)); +extern void srandom(unsigned int __seed) __attribute__((__nothrow__, __leaf__)); +extern char *initstate(unsigned int __seed, char *__statebuf, size_t __statelen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); -extern int ungetc (int __c, FILE *__stream); +extern char *setstate(char *__statebuf) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +struct random_data { + int32_t *fptr; + int32_t *rptr; + int32_t *state; + int rand_type; + int rand_deg; + int rand_sep; + int32_t *end_ptr; +}; +extern int random_r(struct random_data *__restrict __buf, + int32_t *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int srandom_r(unsigned int __seed, struct random_data *__buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int initstate_r(unsigned int __seed, char *__restrict __statebuf, + size_t __statelen, struct random_data *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 4))); +extern int setstate_r(char *__restrict __statebuf, + struct random_data *__restrict __buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern size_t fread (void *__restrict __ptr, size_t __size, - size_t __n, FILE *__restrict __stream) ; +extern int rand(void) __attribute__((__nothrow__, __leaf__)); +extern void srand(unsigned int __seed) __attribute__((__nothrow__, __leaf__)); +extern int rand_r(unsigned int *__seed) __attribute__((__nothrow__, __leaf__)); +extern double drand48(void) __attribute__((__nothrow__, __leaf__)); +extern double erand48(unsigned short int __xsubi[3]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern size_t fwrite (const void *__restrict __ptr, size_t __size, - size_t __n, FILE *__restrict __s); -extern int fputs_unlocked (const char *__restrict __s, - FILE *__restrict __stream); -extern size_t fread_unlocked (void *__restrict __ptr, size_t __size, - size_t __n, FILE *__restrict __stream) ; -extern size_t fwrite_unlocked (const void *__restrict __ptr, size_t __size, - size_t __n, FILE *__restrict __stream); +extern long int lrand48(void) __attribute__((__nothrow__, __leaf__)); +extern long int nrand48(unsigned short int __xsubi[3]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern long int mrand48(void) __attribute__((__nothrow__, __leaf__)); +extern long int jrand48(unsigned short int __xsubi[3]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern void srand48(long int __seedval) __attribute__((__nothrow__, __leaf__)); +extern unsigned short int *seed48(unsigned short int __seed16v[3]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern void lcong48(unsigned short int __param[7]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +struct drand48_data { + unsigned short int __x[3]; + unsigned short int __old_x[3]; + unsigned short int __c; + unsigned short int __init; + __extension__ unsigned long long int __a; +}; +extern int drand48_r(struct drand48_data *__restrict __buffer, + double *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int erand48_r(unsigned short int __xsubi[3], + struct drand48_data *__restrict __buffer, + double *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int lrand48_r(struct drand48_data *__restrict __buffer, + long int *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int nrand48_r(unsigned short int __xsubi[3], + struct drand48_data *__restrict __buffer, + long int *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int mrand48_r(struct drand48_data *__restrict __buffer, + long int *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int jrand48_r(unsigned short int __xsubi[3], + struct drand48_data *__restrict __buffer, + long int *__restrict __result) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int srand48_r(long int __seedval, struct drand48_data *__buffer) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int seed48_r(unsigned short int __seed16v[3], + struct drand48_data *__buffer) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int lcong48_r(unsigned short int __param[7], + struct drand48_data *__buffer) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern void *malloc(size_t __size) __attribute__((__nothrow__, __leaf__)) +__attribute__((__malloc__)) __attribute__((__alloc_size__(1))); + +extern void *calloc(size_t __nmemb, size_t __size) + __attribute__((__nothrow__, __leaf__)) __attribute__((__malloc__)) + __attribute__((__alloc_size__(1, 2))); + +extern void *realloc(void *__ptr, size_t __size) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__warn_unused_result__)) __attribute__((__alloc_size__(2))); + +extern void *reallocarray(void *__ptr, size_t __nmemb, size_t __size) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__warn_unused_result__)) + __attribute__((__alloc_size__(2, 3))); + +extern void free(void *__ptr) __attribute__((__nothrow__, __leaf__)); + +extern void *alloca(size_t __size) __attribute__((__nothrow__, __leaf__)); + +extern void *valloc(size_t __size) __attribute__((__nothrow__, __leaf__)) +__attribute__((__malloc__)) __attribute__((__alloc_size__(1))); + +extern int posix_memalign(void **__memptr, size_t __alignment, size_t __size) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern void *aligned_alloc(size_t __alignment, size_t __size) + __attribute__((__nothrow__, __leaf__)) __attribute__((__malloc__)) + __attribute__((__alloc_size__(2))); + +extern void abort(void) __attribute__((__nothrow__, __leaf__)) +__attribute__((__noreturn__)); + +extern int atexit(void (*__func)(void)) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern int at_quick_exit(void (*__func)(void)) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int on_exit(void (*__func)(int __status, void *__arg), void *__arg) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern void exit(int __status) __attribute__((__nothrow__, __leaf__)) +__attribute__((__noreturn__)); + +extern void quick_exit(int __status) __attribute__((__nothrow__, __leaf__)) +__attribute__((__noreturn__)); + +extern void _Exit(int __status) __attribute__((__nothrow__, __leaf__)) +__attribute__((__noreturn__)); + +extern char *getenv(const char *__name) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern char *secure_getenv(const char *__name) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int putenv(char *__string) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern int setenv(const char *__name, const char *__value, int __replace) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern int unsetenv(const char *__name) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern int clearenv(void) __attribute__((__nothrow__, __leaf__)); +extern char *mktemp(char *__template) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int mkstemp(char *__template) __attribute__((__nonnull__(1))); +extern int mkstemp64(char *__template) __attribute__((__nonnull__(1))); +extern int mkstemps(char *__template, int __suffixlen) + __attribute__((__nonnull__(1))); +extern int mkstemps64(char *__template, int __suffixlen) + __attribute__((__nonnull__(1))); +extern char *mkdtemp(char *__template) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int mkostemp(char *__template, int __flags) + __attribute__((__nonnull__(1))); +extern int mkostemp64(char *__template, int __flags) + __attribute__((__nonnull__(1))); +extern int mkostemps(char *__template, int __suffixlen, int __flags) + __attribute__((__nonnull__(1))); +extern int mkostemps64(char *__template, int __suffixlen, int __flags) + __attribute__((__nonnull__(1))); +extern int system(const char *__command); +extern char *canonicalize_file_name(const char *__name) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern char *realpath(const char *__restrict __name, + char *__restrict __resolved) + __attribute__((__nothrow__, __leaf__)); -extern int fseek (FILE *__stream, long int __off, int __whence); +typedef int (*__compar_fn_t)(const void *, const void *); +typedef __compar_fn_t comparison_fn_t; +typedef int (*__compar_d_fn_t)(const void *, const void *, void *); +extern void *bsearch(const void *__key, const void *__base, size_t __nmemb, + size_t __size, __compar_fn_t __compar) + __attribute__((__nonnull__(1, 2, 5))); -extern long int ftell (FILE *__stream) ; +extern void qsort(void *__base, size_t __nmemb, size_t __size, + __compar_fn_t __compar) __attribute__((__nonnull__(1, 4))); +extern void qsort_r(void *__base, size_t __nmemb, size_t __size, + __compar_d_fn_t __compar, void *__arg) + __attribute__((__nonnull__(1, 4))); +extern int abs(int __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern long int labs(long int __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +__extension__ extern long long int llabs(long long int __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); -extern void rewind (FILE *__stream); -extern int fseeko (FILE *__stream, __off_t __off, int __whence); +extern div_t div(int __numer, int __denom) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern ldiv_t ldiv(long int __numer, long int __denom) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +__extension__ extern lldiv_t lldiv(long long int __numer, long long int __denom) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern char *ecvt(double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3, 4))); +extern char *fcvt(double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(3, 4))); +extern char *gcvt(double __value, int __ndigit, char *__buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); -extern __off_t ftello (FILE *__stream) ; -extern int fgetpos (FILE *__restrict __stream, fpos_t *__restrict __pos); +extern char *qecvt(long double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3, 4))); +extern char *qfcvt(long double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3, 4))); +extern char *qgcvt(long double __value, int __ndigit, char *__buf) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int ecvt_r(double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign, char *__restrict __buf, size_t __len) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(3, 4, 5))); +extern int fcvt_r(double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign, char *__restrict __buf, size_t __len) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(3, 4, 5))); +extern int qecvt_r(long double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign, char *__restrict __buf, size_t __len) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(3, 4, 5))); +extern int qfcvt_r(long double __value, int __ndigit, int *__restrict __decpt, + int *__restrict __sign, char *__restrict __buf, size_t __len) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(3, 4, 5))); +extern int mblen(const char *__s, size_t __n) + __attribute__((__nothrow__, __leaf__)); -extern int fsetpos (FILE *__stream, const fpos_t *__pos); -extern int fseeko64 (FILE *__stream, __off64_t __off, int __whence); -extern __off64_t ftello64 (FILE *__stream) ; -extern int fgetpos64 (FILE *__restrict __stream, fpos64_t *__restrict __pos); -extern int fsetpos64 (FILE *__stream, const fpos64_t *__pos); +extern int mbtowc(wchar_t *__restrict __pwc, const char *__restrict __s, + size_t __n) __attribute__((__nothrow__, __leaf__)); +extern int wctomb(char *__s, wchar_t __wchar) + __attribute__((__nothrow__, __leaf__)); +extern size_t mbstowcs(wchar_t *__restrict __pwcs, const char *__restrict __s, + size_t __n) __attribute__((__nothrow__, __leaf__)); -extern void clearerr (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); +extern size_t wcstombs(char *__restrict __s, const wchar_t *__restrict __pwcs, + size_t __n) __attribute__((__nothrow__, __leaf__)); -extern int feof (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int rpmatch(const char *__response) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int getsubopt(char **__restrict __optionp, + char *const *__restrict __tokens, + char **__restrict __valuep) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(1, 2, 3))); -extern int ferror (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int posix_openpt(int __oflag); +extern int grantpt(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int unlockpt(int __fd) __attribute__((__nothrow__, __leaf__)); -extern void clearerr_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); -extern int feof_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; -extern int ferror_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern char *ptsname(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int ptsname_r(int __fd, char *__buf, size_t __buflen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int getpt(void); +extern int getloadavg(double __loadavg[], int __nelem) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +typedef long int ptrdiff_t; +typedef struct { + long long __max_align_ll __attribute__((__aligned__(__alignof__(long long)))); + long double __max_align_ld + __attribute__((__aligned__(__alignof__(long double)))); +} max_align_t; +extern void *memcpy(void *__restrict __dest, const void *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern void *memmove(void *__dest, const void *__src, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern void *memccpy(void *__restrict __dest, const void *__restrict __src, + int __c, size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern void *memset(void *__s, int __c, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int memcmp(const void *__s1, const void *__s2, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern void *memchr(const void *__s, int __c, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); +extern void *rawmemchr(const void *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); +extern void *memrchr(const void *__s, int __c, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); + +extern char *strcpy(char *__restrict __dest, const char *__restrict __src) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern char *strncpy(char *__restrict __dest, const char *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern char *strcat(char *__restrict __dest, const char *__restrict __src) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern char *strncat(char *__restrict __dest, const char *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern int strcmp(const char *__s1, const char *__s2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern int strncmp(const char *__s1, const char *__s2, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern int strcoll(const char *__s1, const char *__s2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern size_t strxfrm(char *__restrict __dest, const char *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(2))); + +extern int strcoll_l(const char *__s1, const char *__s2, locale_t __l) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2, 3))); + +extern size_t strxfrm_l(char *__dest, const char *__src, size_t __n, + locale_t __l) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(2, 4))); + +extern char *strdup(const char *__s) __attribute__((__nothrow__, __leaf__)) +__attribute__((__malloc__)) __attribute__((__nonnull__(1))); + +extern char *strndup(const char *__string, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__malloc__)) + __attribute__((__nonnull__(1))); +extern char *strchr(const char *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); +extern char *strrchr(const char *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); +extern char *strchrnul(const char *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); + +extern size_t strcspn(const char *__s, const char *__reject) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern size_t strspn(const char *__s, const char *__accept) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern char *strpbrk(const char *__s, const char *__accept) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern char *strstr(const char *__haystack, const char *__needle) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern char *strtok(char *__restrict __s, const char *__restrict __delim) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern char *__strtok_r(char *__restrict __s, const char *__restrict __delim, + char **__restrict __save_ptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); + +extern char *strtok_r(char *__restrict __s, const char *__restrict __delim, + char **__restrict __save_ptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern char *strcasestr(const char *__haystack, const char *__needle) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern void *memmem(const void *__haystack, size_t __haystacklen, + const void *__needle, size_t __needlelen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 3))); + +extern void *__mempcpy(void *__restrict __dest, const void *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +extern void *mempcpy(void *__restrict __dest, const void *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern size_t strlen(const char *__s) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1))); + +extern size_t strnlen(const char *__string, size_t __maxlen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); + +extern char *strerror(int __errnum) __attribute__((__nothrow__, __leaf__)); +extern char *strerror_r(int __errnum, char *__buf, size_t __buflen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern char *strerror_l(int __errnum, locale_t __l) + __attribute__((__nothrow__, __leaf__)); + +extern int bcmp(const void *__s1, const void *__s2, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern void bcopy(const void *__src, void *__dest, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern void bzero(void *__s, size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern char *index(const char *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); +extern char *rindex(const char *__s, int __c) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1))); + +extern int ffs(int __i) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int ffsl(long int __l) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +__extension__ extern int ffsll(long long int __ll) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int strcasecmp(const char *__s1, const char *__s2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern int strncasecmp(const char *__s1, const char *__s2, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern int strcasecmp_l(const char *__s1, const char *__s2, locale_t __loc) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2, 3))); + +extern int strncasecmp_l(const char *__s1, const char *__s2, size_t __n, + locale_t __loc) __attribute__((__nothrow__, __leaf__)) +__attribute__((__pure__)) __attribute__((__nonnull__(1, 2, 4))); + +extern void explicit_bzero(void *__s, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern char *strsep(char **__restrict __stringp, const char *__restrict __delim) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern char *strsignal(int __sig) __attribute__((__nothrow__, __leaf__)); + +extern char *__stpcpy(char *__restrict __dest, const char *__restrict __src) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern char *stpcpy(char *__restrict __dest, const char *__restrict __src) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern char *__stpncpy(char *__restrict __dest, const char *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +extern char *stpncpy(char *__restrict __dest, const char *__restrict __src, + size_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); + +extern int strverscmp(const char *__s1, const char *__s2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern char *strfry(char *__string) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern void *memfrob(void *__s, size_t __n) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern char *basename(const char *__filename) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +typedef __uint8_t uint8_t; +typedef __uint16_t uint16_t; +typedef __uint32_t uint32_t; +typedef __uint64_t uint64_t; -extern void perror (const char *__s); +typedef __int_least8_t int_least8_t; +typedef __int_least16_t int_least16_t; +typedef __int_least32_t int_least32_t; +typedef __int_least64_t int_least64_t; +typedef __uint_least8_t uint_least8_t; +typedef __uint_least16_t uint_least16_t; +typedef __uint_least32_t uint_least32_t; +typedef __uint_least64_t uint_least64_t; +typedef signed char int_fast8_t; +typedef long int int_fast16_t; +typedef long int int_fast32_t; +typedef long int int_fast64_t; +typedef unsigned char uint_fast8_t; +typedef unsigned long int uint_fast16_t; +typedef unsigned long int uint_fast32_t; +typedef unsigned long int uint_fast64_t; +typedef long int intptr_t; -extern int sys_nerr; -extern const char *const sys_errlist[]; +typedef unsigned long int uintptr_t; +typedef __intmax_t intmax_t; +typedef __uintmax_t uintmax_t; +typedef int __gwchar_t; -extern int _sys_nerr; -extern const char *const _sys_errlist[]; +typedef struct { + long int quot; + long int rem; +} imaxdiv_t; +extern intmax_t imaxabs(intmax_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern imaxdiv_t imaxdiv(intmax_t __numer, intmax_t __denom) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern intmax_t strtoimax(const char *__restrict __nptr, + char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)); +extern uintmax_t strtoumax(const char *__restrict __nptr, + char **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)); -extern int fileno (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern intmax_t wcstoimax(const __gwchar_t *__restrict __nptr, + __gwchar_t **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)); +extern uintmax_t wcstoumax(const __gwchar_t *__restrict __nptr, + __gwchar_t **__restrict __endptr, int __base) + __attribute__((__nothrow__, __leaf__)); +typedef __socklen_t socklen_t; +extern int access(const char *__name, int __type) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int euidaccess(const char *__name, int __type) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern int fileno_unlocked (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; -extern FILE *popen (const char *__command, const char *__modes) ; +extern int eaccess(const char *__name, int __type) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int faccessat(int __fd, const char *__file, int __type, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern __off_t lseek(int __fd, __off_t __offset, int __whence) + __attribute__((__nothrow__, __leaf__)); +extern __off64_t lseek64(int __fd, __off64_t __offset, int __whence) + __attribute__((__nothrow__, __leaf__)); +extern int close(int __fd); +extern ssize_t read(int __fd, void *__buf, size_t __nbytes); +extern ssize_t write(int __fd, const void *__buf, size_t __n); +extern ssize_t pread(int __fd, void *__buf, size_t __nbytes, __off_t __offset); -extern int pclose (FILE *__stream); +extern ssize_t pwrite(int __fd, const void *__buf, size_t __n, + __off_t __offset); +extern ssize_t pread64(int __fd, void *__buf, size_t __nbytes, + __off64_t __offset); +extern ssize_t pwrite64(int __fd, const void *__buf, size_t __n, + __off64_t __offset); +extern int pipe(int __pipedes[2]) __attribute__((__nothrow__, __leaf__)); +extern int pipe2(int __pipedes[2], int __flags) + __attribute__((__nothrow__, __leaf__)); +extern unsigned int alarm(unsigned int __seconds) + __attribute__((__nothrow__, __leaf__)); +extern unsigned int sleep(unsigned int __seconds); +extern __useconds_t ualarm(__useconds_t __value, __useconds_t __interval) + __attribute__((__nothrow__, __leaf__)); -extern char *ctermid (char *__s) __attribute__ ((__nothrow__ , __leaf__)); +extern int usleep(__useconds_t __useconds); +extern int pause(void); +extern int chown(const char *__file, __uid_t __owner, __gid_t __group) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int fchown(int __fd, __uid_t __owner, __gid_t __group) + __attribute__((__nothrow__, __leaf__)); +extern int lchown(const char *__file, __uid_t __owner, __gid_t __group) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int fchownat(int __fd, const char *__file, __uid_t __owner, + __gid_t __group, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); -extern char *cuserid (char *__s); +extern int chdir(const char *__path) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int fchdir(int __fd) __attribute__((__nothrow__, __leaf__)); +extern char *getcwd(char *__buf, size_t __size) + __attribute__((__nothrow__, __leaf__)); +extern char *get_current_dir_name(void) __attribute__((__nothrow__, __leaf__)); +extern char *getwd(char *__buf) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))) __attribute__((__deprecated__)); -struct obstack; +extern int dup(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int dup2(int __fd, int __fd2) __attribute__((__nothrow__, __leaf__)); -extern int obstack_printf (struct obstack *__restrict __obstack, - const char *__restrict __format, ...) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 2, 3))); -extern int obstack_vprintf (struct obstack *__restrict __obstack, - const char *__restrict __format, - __gnuc_va_list __args) - __attribute__ ((__nothrow__)) __attribute__ ((__format__ (__printf__, 2, 0))); +extern int dup3(int __fd, int __fd2, int __flags) + __attribute__((__nothrow__, __leaf__)); +extern char **__environ; +extern char **environ; +extern int execve(const char *__path, char *const __argv[], + char *const __envp[]) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +extern int fexecve(int __fd, char *const __argv[], char *const __envp[]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int execv(const char *__path, char *const __argv[]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int execle(const char *__path, const char *__arg, ...) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern void flockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); +extern int execl(const char *__path, const char *__arg, ...) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int execvp(const char *__file, char *const __argv[]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int execlp(const char *__file, const char *__arg, ...) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern int ftrylockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int execvpe(const char *__file, char *const __argv[], + char *const __envp[]) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +extern int nice(int __inc) __attribute__((__nothrow__, __leaf__)); -extern void funlockfile (FILE *__stream) __attribute__ ((__nothrow__ , __leaf__)); -extern int __uflow (FILE *); -extern int __overflow (FILE *, int); +extern void _exit(int __status) __attribute__((__noreturn__)); +enum { + _PC_LINK_MAX, + _PC_MAX_CANON, + _PC_MAX_INPUT, + _PC_NAME_MAX, + _PC_PATH_MAX, + _PC_PIPE_BUF, + _PC_CHOWN_RESTRICTED, + _PC_NO_TRUNC, + _PC_VDISABLE, -struct timespec -{ - __time_t tv_sec; + _PC_SYNC_IO, + _PC_ASYNC_IO, + _PC_PRIO_IO, - __syscall_slong_t tv_nsec; -}; + _PC_SOCK_MAXBUF, + _PC_FILESIZEBITS, + _PC_REC_INCR_XFER_SIZE, + _PC_REC_MAX_XFER_SIZE, + _PC_REC_MIN_XFER_SIZE, + _PC_REC_XFER_ALIGN, + _PC_ALLOC_SIZE_MIN, + _PC_SYMLINK_MAX, + _PC_2_SYMLINKS +}; +enum { + _SC_ARG_MAX, + _SC_CHILD_MAX, -typedef __time_t time_t; + _SC_CLK_TCK, + _SC_NGROUPS_MAX, -typedef __dev_t dev_t; + _SC_OPEN_MAX, + _SC_STREAM_MAX, + _SC_TZNAME_MAX, + _SC_JOB_CONTROL, -typedef __gid_t gid_t; + _SC_SAVED_IDS, + _SC_REALTIME_SIGNALS, + _SC_PRIORITY_SCHEDULING, + _SC_TIMERS, + _SC_ASYNCHRONOUS_IO, -typedef __ino_t ino_t; + _SC_PRIORITIZED_IO, + _SC_SYNCHRONIZED_IO, + _SC_FSYNC, + _SC_MAPPED_FILES, + _SC_MEMLOCK, + _SC_MEMLOCK_RANGE, + _SC_MEMORY_PROTECTION, -typedef __mode_t mode_t; + _SC_MESSAGE_PASSING, + _SC_SEMAPHORES, + _SC_SHARED_MEMORY_OBJECTS, + _SC_AIO_LISTIO_MAX, -typedef __nlink_t nlink_t; -typedef __uid_t uid_t; + _SC_AIO_MAX, + _SC_AIO_PRIO_DELTA_MAX, + _SC_DELAYTIMER_MAX, + _SC_MQ_OPEN_MAX, + _SC_MQ_PRIO_MAX, + _SC_VERSION, + _SC_PAGESIZE, -typedef __blkcnt_t blkcnt_t; + _SC_RTSIG_MAX, + _SC_SEM_NSEMS_MAX, + _SC_SEM_VALUE_MAX, + _SC_SIGQUEUE_MAX, + _SC_TIMER_MAX, + _SC_BC_BASE_MAX, + _SC_BC_DIM_MAX, -typedef __blksize_t blksize_t; + _SC_BC_SCALE_MAX, + _SC_BC_STRING_MAX, + _SC_COLL_WEIGHTS_MAX, + _SC_EQUIV_CLASS_MAX, + _SC_EXPR_NEST_MAX, + _SC_LINE_MAX, -struct stat - { - __dev_t st_dev; + _SC_RE_DUP_MAX, + _SC_CHARCLASS_NAME_MAX, + _SC_2_VERSION, + _SC_2_C_BIND, - __ino_t st_ino; + _SC_2_C_DEV, + _SC_2_FORT_DEV, + _SC_2_FORT_RUN, + _SC_2_SW_DEV, + _SC_2_LOCALEDEF, + _SC_PII, + _SC_PII_XTI, - __nlink_t st_nlink; - __mode_t st_mode; + _SC_PII_SOCKET, - __uid_t st_uid; - __gid_t st_gid; + _SC_PII_INTERNET, - int __pad0; + _SC_PII_OSI, - __dev_t st_rdev; + _SC_POLL, + _SC_SELECT, + _SC_UIO_MAXIOV, + _SC_IOV_MAX = _SC_UIO_MAXIOV, - __off_t st_size; + _SC_PII_INTERNET_STREAM, + _SC_PII_INTERNET_DGRAM, + _SC_PII_OSI_COTS, - __blksize_t st_blksize; + _SC_PII_OSI_CLTS, - __blkcnt_t st_blocks; - struct timespec st_atim; - struct timespec st_mtim; - struct timespec st_ctim; - __syscall_slong_t __glibc_reserved[3]; - }; + _SC_PII_OSI_M, + _SC_T_IOV_MAX, + _SC_THREADS, -struct stat64 - { - __dev_t st_dev; + _SC_THREAD_SAFE_FUNCTIONS, - __ino64_t st_ino; - __nlink_t st_nlink; - __mode_t st_mode; + _SC_GETGR_R_SIZE_MAX, + _SC_GETPW_R_SIZE_MAX, + _SC_LOGIN_NAME_MAX, + _SC_TTY_NAME_MAX, + _SC_THREAD_DESTRUCTOR_ITERATIONS, + _SC_THREAD_KEYS_MAX, - __uid_t st_uid; - __gid_t st_gid; + _SC_THREAD_STACK_MIN, - int __pad0; - __dev_t st_rdev; - __off_t st_size; + _SC_THREAD_THREADS_MAX, + _SC_THREAD_ATTR_STACKADDR, + _SC_THREAD_ATTR_STACKSIZE, + _SC_THREAD_PRIORITY_SCHEDULING, + _SC_THREAD_PRIO_INHERIT, - __blksize_t st_blksize; - __blkcnt64_t st_blocks; + _SC_THREAD_PRIO_PROTECT, + _SC_THREAD_PROCESS_SHARED, + _SC_NPROCESSORS_CONF, + _SC_NPROCESSORS_ONLN, + _SC_PHYS_PAGES, + _SC_AVPHYS_PAGES, + _SC_ATEXIT_MAX, - struct timespec st_atim; - struct timespec st_mtim; - struct timespec st_ctim; - __syscall_slong_t __glibc_reserved[3]; + _SC_PASS_MAX, + _SC_XOPEN_VERSION, + _SC_XOPEN_XCU_VERSION, - }; -extern int stat (const char *__restrict __file, - struct stat *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + _SC_XOPEN_UNIX, + _SC_XOPEN_CRYPT, + _SC_XOPEN_ENH_I18N, -extern int fstat (int __fd, struct stat *__buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); -extern int stat64 (const char *__restrict __file, - struct stat64 *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern int fstat64 (int __fd, struct stat64 *__buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + _SC_XOPEN_SHM, + _SC_2_CHAR_TERM, + _SC_2_C_VERSION, + _SC_2_UPE, + _SC_XOPEN_XPG2, + _SC_XOPEN_XPG3, + _SC_XOPEN_XPG4, -extern int fstatat (int __fd, const char *__restrict __file, - struct stat *__restrict __buf, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern int fstatat64 (int __fd, const char *__restrict __file, - struct stat64 *__restrict __buf, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); + _SC_CHAR_BIT, + _SC_CHAR_MAX, + _SC_CHAR_MIN, + _SC_INT_MAX, + _SC_INT_MIN, + _SC_LONG_BIT, + _SC_WORD_BIT, -extern int lstat (const char *__restrict __file, - struct stat *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern int lstat64 (const char *__restrict __file, - struct stat64 *__restrict __buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + _SC_MB_LEN_MAX, + _SC_NZERO, + _SC_SSIZE_MAX, + _SC_SCHAR_MAX, + _SC_SCHAR_MIN, -extern int chmod (const char *__file, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + _SC_SHRT_MAX, + _SC_SHRT_MIN, + _SC_UCHAR_MAX, + _SC_UINT_MAX, + _SC_ULONG_MAX, -extern int lchmod (const char *__file, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + _SC_USHRT_MAX, + _SC_NL_ARGMAX, + _SC_NL_LANGMAX, + _SC_NL_MSGMAX, -extern int fchmod (int __fd, __mode_t __mode) __attribute__ ((__nothrow__ , __leaf__)); + _SC_NL_NMAX, + _SC_NL_SETMAX, + _SC_NL_TEXTMAX, + _SC_XBS5_ILP32_OFF32, + _SC_XBS5_ILP32_OFFBIG, -extern int fchmodat (int __fd, const char *__file, __mode_t __mode, - int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))) ; + _SC_XBS5_LP64_OFF64, + _SC_XBS5_LPBIG_OFFBIG, + _SC_XOPEN_LEGACY, + _SC_XOPEN_REALTIME, + _SC_XOPEN_REALTIME_THREADS, + _SC_ADVISORY_INFO, -extern __mode_t umask (__mode_t __mask) __attribute__ ((__nothrow__ , __leaf__)); + _SC_BARRIERS, + _SC_BASE, + _SC_C_LANG_SUPPORT, + _SC_C_LANG_SUPPORT_R, -extern __mode_t getumask (void) __attribute__ ((__nothrow__ , __leaf__)); + _SC_CLOCK_SELECTION, + _SC_CPUTIME, + _SC_THREAD_CPUTIME, -extern int mkdir (const char *__path, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + _SC_DEVICE_IO, + _SC_DEVICE_SPECIFIC, + _SC_DEVICE_SPECIFIC_R, + _SC_FD_MGMT, + _SC_FIFO, -extern int mkdirat (int __fd, const char *__path, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + _SC_PIPE, + _SC_FILE_ATTRIBUTES, + _SC_FILE_LOCKING, + _SC_FILE_SYSTEM, + _SC_MONOTONIC_CLOCK, + _SC_MULTI_PROCESS, -extern int mknod (const char *__path, __mode_t __mode, __dev_t __dev) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + _SC_SINGLE_PROCESS, + _SC_NETWORKING, + _SC_READER_WRITER_LOCKS, + _SC_SPIN_LOCKS, + _SC_REGEXP, -extern int mknodat (int __fd, const char *__path, __mode_t __mode, - __dev_t __dev) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + _SC_REGEX_VERSION, + _SC_SHELL, + _SC_SIGNALS, + _SC_SPAWN, + _SC_SPORADIC_SERVER, -extern int mkfifo (const char *__path, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + _SC_THREAD_SPORADIC_SERVER, + _SC_SYSTEM_DATABASE, + _SC_SYSTEM_DATABASE_R, + _SC_TIMEOUTS, + _SC_TYPED_MEMORY_OBJECTS, -extern int mkfifoat (int __fd, const char *__path, __mode_t __mode) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + _SC_USER_GROUPS, + _SC_USER_GROUPS_R, + _SC_2_PBS, + _SC_2_PBS_ACCOUNTING, + _SC_2_PBS_LOCATE, -extern int utimensat (int __fd, const char *__path, - const struct timespec __times[2], - int __flags) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + _SC_2_PBS_MESSAGE, + _SC_2_PBS_TRACK, + _SC_SYMLOOP_MAX, + _SC_STREAMS, -extern int futimens (int __fd, const struct timespec __times[2]) __attribute__ ((__nothrow__ , __leaf__)); -extern int __fxstat (int __ver, int __fildes, struct stat *__stat_buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); -extern int __xstat (int __ver, const char *__filename, - struct stat *__stat_buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern int __lxstat (int __ver, const char *__filename, - struct stat *__stat_buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern int __fxstatat (int __ver, int __fildes, const char *__filename, - struct stat *__stat_buf, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))); -extern int __fxstat64 (int __ver, int __fildes, struct stat64 *__stat_buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); -extern int __xstat64 (int __ver, const char *__filename, - struct stat64 *__stat_buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern int __lxstat64 (int __ver, const char *__filename, - struct stat64 *__stat_buf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern int __fxstatat64 (int __ver, int __fildes, const char *__filename, - struct stat64 *__stat_buf, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))); + _SC_2_PBS_CHECKPOINT, -extern int __xmknod (int __ver, const char *__path, __mode_t __mode, - __dev_t *__dev) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))); + _SC_V6_ILP32_OFF32, -extern int __xmknodat (int __ver, int __fd, const char *__path, - __mode_t __mode, __dev_t *__dev) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 5))); + _SC_V6_ILP32_OFFBIG, + _SC_V6_LP64_OFF64, + _SC_V6_LPBIG_OFFBIG, + _SC_HOST_NAME_MAX, + _SC_TRACE, + _SC_TRACE_EVENT_FILTER, + _SC_TRACE_INHERIT, + _SC_TRACE_LOG, + _SC_LEVEL1_ICACHE_SIZE, + _SC_LEVEL1_ICACHE_ASSOC, + _SC_LEVEL1_ICACHE_LINESIZE, + _SC_LEVEL1_DCACHE_SIZE, + _SC_LEVEL1_DCACHE_ASSOC, + _SC_LEVEL1_DCACHE_LINESIZE, + _SC_LEVEL2_CACHE_SIZE, + _SC_LEVEL2_CACHE_ASSOC, + _SC_LEVEL2_CACHE_LINESIZE, + _SC_LEVEL3_CACHE_SIZE, + _SC_LEVEL3_CACHE_ASSOC, + _SC_LEVEL3_CACHE_LINESIZE, + _SC_LEVEL4_CACHE_SIZE, + _SC_LEVEL4_CACHE_ASSOC, + _SC_LEVEL4_CACHE_LINESIZE, -typedef __signed__ char __s8; -typedef unsigned char __u8; + _SC_IPV6 = _SC_LEVEL1_ICACHE_SIZE + 50, -typedef __signed__ short __s16; -typedef unsigned short __u16; + _SC_RAW_SOCKETS, -typedef __signed__ int __s32; -typedef unsigned int __u32; + _SC_V7_ILP32_OFF32, + _SC_V7_ILP32_OFFBIG, -__extension__ typedef __signed__ long long __s64; -__extension__ typedef unsigned long long __u64; + _SC_V7_LP64_OFF64, + _SC_V7_LPBIG_OFFBIG, + _SC_SS_REPL_MAX, + _SC_TRACE_EVENT_NAME_MAX, + _SC_TRACE_NAME_MAX, + _SC_TRACE_SYS_MAX, + _SC_TRACE_USER_EVENT_MAX, -typedef struct { - unsigned long fds_bits[1024 / (8 * sizeof(long))]; -} __kernel_fd_set; + _SC_XOPEN_STREAMS, + _SC_THREAD_ROBUST_PRIO_INHERIT, -typedef void (*__kernel_sighandler_t)(int); + _SC_THREAD_ROBUST_PRIO_PROTECT +}; -typedef int __kernel_key_t; -typedef int __kernel_mqd_t; +enum { + _CS_PATH, + _CS_V6_WIDTH_RESTRICTED_ENVS, + _CS_GNU_LIBC_VERSION, + _CS_GNU_LIBPTHREAD_VERSION, + _CS_V5_WIDTH_RESTRICTED_ENVS, + _CS_V7_WIDTH_RESTRICTED_ENVS, + _CS_LFS_CFLAGS = 1000, -typedef unsigned short __kernel_old_uid_t; -typedef unsigned short __kernel_old_gid_t; + _CS_LFS_LDFLAGS, + _CS_LFS_LIBS, -typedef unsigned long __kernel_old_dev_t; + _CS_LFS_LINTFLAGS, + _CS_LFS64_CFLAGS, -typedef long __kernel_long_t; -typedef unsigned long __kernel_ulong_t; + _CS_LFS64_LDFLAGS, + _CS_LFS64_LIBS, + _CS_LFS64_LINTFLAGS, -typedef __kernel_ulong_t __kernel_ino_t; + _CS_XBS5_ILP32_OFF32_CFLAGS = 1100, + _CS_XBS5_ILP32_OFF32_LDFLAGS, + _CS_XBS5_ILP32_OFF32_LIBS, -typedef unsigned int __kernel_mode_t; + _CS_XBS5_ILP32_OFF32_LINTFLAGS, + _CS_XBS5_ILP32_OFFBIG_CFLAGS, + _CS_XBS5_ILP32_OFFBIG_LDFLAGS, -typedef int __kernel_pid_t; + _CS_XBS5_ILP32_OFFBIG_LIBS, + _CS_XBS5_ILP32_OFFBIG_LINTFLAGS, + _CS_XBS5_LP64_OFF64_CFLAGS, -typedef int __kernel_ipc_pid_t; + _CS_XBS5_LP64_OFF64_LDFLAGS, + _CS_XBS5_LP64_OFF64_LIBS, + _CS_XBS5_LP64_OFF64_LINTFLAGS, -typedef unsigned int __kernel_uid_t; -typedef unsigned int __kernel_gid_t; + _CS_XBS5_LPBIG_OFFBIG_CFLAGS, + _CS_XBS5_LPBIG_OFFBIG_LDFLAGS, + _CS_XBS5_LPBIG_OFFBIG_LIBS, -typedef __kernel_long_t __kernel_suseconds_t; + _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS, + _CS_POSIX_V6_ILP32_OFF32_CFLAGS, + _CS_POSIX_V6_ILP32_OFF32_LDFLAGS, -typedef int __kernel_daddr_t; + _CS_POSIX_V6_ILP32_OFF32_LIBS, + _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS, + _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS, -typedef unsigned int __kernel_uid32_t; -typedef unsigned int __kernel_gid32_t; -typedef __kernel_ulong_t __kernel_size_t; -typedef __kernel_long_t __kernel_ssize_t; -typedef __kernel_long_t __kernel_ptrdiff_t; + _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS, + _CS_POSIX_V6_ILP32_OFFBIG_LIBS, + _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS, + _CS_POSIX_V6_LP64_OFF64_CFLAGS, -typedef struct { - int val[2]; -} __kernel_fsid_t; + _CS_POSIX_V6_LP64_OFF64_LDFLAGS, + _CS_POSIX_V6_LP64_OFF64_LIBS, + _CS_POSIX_V6_LP64_OFF64_LINTFLAGS, + _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS, + _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS, -typedef __kernel_long_t __kernel_off_t; -typedef long long __kernel_loff_t; -typedef __kernel_long_t __kernel_old_time_t; -typedef __kernel_long_t __kernel_time_t; -typedef long long __kernel_time64_t; -typedef __kernel_long_t __kernel_clock_t; -typedef int __kernel_timer_t; -typedef int __kernel_clockid_t; -typedef char * __kernel_caddr_t; -typedef unsigned short __kernel_uid16_t; -typedef unsigned short __kernel_gid16_t; -typedef __u16 __le16; -typedef __u16 __be16; -typedef __u32 __le32; -typedef __u32 __be32; -typedef __u64 __le64; -typedef __u64 __be64; + _CS_POSIX_V6_LPBIG_OFFBIG_LIBS, -typedef __u16 __sum16; -typedef __u32 __wsum; -typedef unsigned __poll_t; -struct statx_timestamp { - __s64 tv_sec; - __u32 tv_nsec; - __s32 __reserved; -}; -struct statx { + _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS, - __u32 stx_mask; - __u32 stx_blksize; - __u64 stx_attributes; + _CS_POSIX_V7_ILP32_OFF32_CFLAGS, - __u32 stx_nlink; - __u32 stx_uid; - __u32 stx_gid; - __u16 stx_mode; - __u16 __spare0[1]; + _CS_POSIX_V7_ILP32_OFF32_LDFLAGS, - __u64 stx_ino; - __u64 stx_size; - __u64 stx_blocks; - __u64 stx_attributes_mask; + _CS_POSIX_V7_ILP32_OFF32_LIBS, - struct statx_timestamp stx_atime; - struct statx_timestamp stx_btime; - struct statx_timestamp stx_ctime; - struct statx_timestamp stx_mtime; + _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS, - __u32 stx_rdev_major; - __u32 stx_rdev_minor; - __u32 stx_dev_major; - __u32 stx_dev_minor; + _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS, - __u64 stx_mnt_id; - __u64 __spare2; + _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS, - __u64 __spare3[12]; + _CS_POSIX_V7_ILP32_OFFBIG_LIBS, -}; + _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS, + _CS_POSIX_V7_LP64_OFF64_CFLAGS, + _CS_POSIX_V7_LP64_OFF64_LDFLAGS, + _CS_POSIX_V7_LP64_OFF64_LIBS, + _CS_POSIX_V7_LP64_OFF64_LINTFLAGS, + _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS, + _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS, + _CS_POSIX_V7_LPBIG_OFFBIG_LIBS, + _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS, + _CS_V6_ENV, -int statx (int __dirfd, const char *__restrict __path, int __flags, - unsigned int __mask, struct statx *__restrict __buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 5))); + _CS_V7_ENV +}; +extern long int pathconf(const char *__path, int __name) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern long int fpathconf(int __fd, int __name) + __attribute__((__nothrow__, __leaf__)); +extern long int sysconf(int __name) __attribute__((__nothrow__, __leaf__)); +extern size_t confstr(int __name, char *__buf, size_t __len) + __attribute__((__nothrow__, __leaf__)); +extern __pid_t getpid(void) __attribute__((__nothrow__, __leaf__)); +extern __pid_t getppid(void) __attribute__((__nothrow__, __leaf__)); +extern __pid_t getpgrp(void) __attribute__((__nothrow__, __leaf__)); +extern __pid_t __getpgid(__pid_t __pid) __attribute__((__nothrow__, __leaf__)); -typedef int wchar_t; +extern __pid_t getpgid(__pid_t __pid) __attribute__((__nothrow__, __leaf__)); +extern int setpgid(__pid_t __pid, __pid_t __pgid) + __attribute__((__nothrow__, __leaf__)); +extern int setpgrp(void) __attribute__((__nothrow__, __leaf__)); +extern __pid_t setsid(void) __attribute__((__nothrow__, __leaf__)); +extern __pid_t getsid(__pid_t __pid) __attribute__((__nothrow__, __leaf__)); +extern __uid_t getuid(void) __attribute__((__nothrow__, __leaf__)); +extern __uid_t geteuid(void) __attribute__((__nothrow__, __leaf__)); +extern __gid_t getgid(void) __attribute__((__nothrow__, __leaf__)); +extern __gid_t getegid(void) __attribute__((__nothrow__, __leaf__)); +extern int getgroups(int __size, __gid_t __list[]) + __attribute__((__nothrow__, __leaf__)); -typedef struct - { - int quot; - int rem; - } div_t; +extern int group_member(__gid_t __gid) __attribute__((__nothrow__, __leaf__)); +extern int setuid(__uid_t __uid) __attribute__((__nothrow__, __leaf__)); +extern int setreuid(__uid_t __ruid, __uid_t __euid) + __attribute__((__nothrow__, __leaf__)); -typedef struct - { - long int quot; - long int rem; - } ldiv_t; +extern int seteuid(__uid_t __uid) __attribute__((__nothrow__, __leaf__)); +extern int setgid(__gid_t __gid) __attribute__((__nothrow__, __leaf__)); +extern int setregid(__gid_t __rgid, __gid_t __egid) + __attribute__((__nothrow__, __leaf__)); +extern int setegid(__gid_t __gid) __attribute__((__nothrow__, __leaf__)); +extern int getresuid(__uid_t *__ruid, __uid_t *__euid, __uid_t *__suid) + __attribute__((__nothrow__, __leaf__)); -__extension__ typedef struct - { - long long int quot; - long long int rem; - } lldiv_t; -extern size_t __ctype_get_mb_cur_max (void) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int getresgid(__gid_t *__rgid, __gid_t *__egid, __gid_t *__sgid) + __attribute__((__nothrow__, __leaf__)); +extern int setresuid(__uid_t __ruid, __uid_t __euid, __uid_t __suid) + __attribute__((__nothrow__, __leaf__)); +extern int setresgid(__gid_t __rgid, __gid_t __egid, __gid_t __sgid) + __attribute__((__nothrow__, __leaf__)); -extern double atof (const char *__nptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; +extern __pid_t fork(void) __attribute__((__nothrow__)); -extern int atoi (const char *__nptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; +extern __pid_t vfork(void) __attribute__((__nothrow__, __leaf__)); -extern long int atol (const char *__nptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; +extern char *ttyname(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int ttyname_r(int __fd, char *__buf, size_t __buflen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int isatty(int __fd) __attribute__((__nothrow__, __leaf__)); -__extension__ extern long long int atoll (const char *__nptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; +extern int ttyslot(void) __attribute__((__nothrow__, __leaf__)); +extern int link(const char *__from, const char *__to) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int linkat(int __fromfd, const char *__from, int __tofd, + const char *__to, int __flags) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 4))); -extern double strtod (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int symlink(const char *__from, const char *__to) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern ssize_t readlink(const char *__restrict __path, char *__restrict __buf, + size_t __len) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +extern int symlinkat(const char *__from, int __tofd, const char *__to) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); -extern float strtof (const char *__restrict __nptr, - char **__restrict __endptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern ssize_t readlinkat(int __fd, const char *__restrict __path, + char *__restrict __buf, size_t __len) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); -extern long double strtold (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern _Float32 strtof32 (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int unlink(const char *__name) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int unlinkat(int __fd, const char *__name, int __flag) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int rmdir(const char *__path) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); -extern _Float64 strtof64 (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern __pid_t tcgetpgrp(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int tcsetpgrp(int __fd, __pid_t __pgrp_id) + __attribute__((__nothrow__, __leaf__)); +extern char *getlogin(void); -extern _Float128 strtof128 (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int getlogin_r(char *__name, size_t __name_len) + __attribute__((__nonnull__(1))); +extern int setlogin(const char *__name) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern char *optarg; +extern int optind; -extern _Float32x strtof32x (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int opterr; +extern int optopt; +extern int getopt(int ___argc, char *const *___argv, const char *__shortopts) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int gethostname(char *__name, size_t __len) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern _Float64x strtof64x (const char *__restrict __nptr, - char **__restrict __endptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern long int strtol (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int sethostname(const char *__name, size_t __len) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern unsigned long int strtoul (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int sethostid(long int __id) __attribute__((__nothrow__, __leaf__)); +extern int getdomainname(char *__name, size_t __len) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int setdomainname(const char *__name, size_t __len) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int vhangup(void) __attribute__((__nothrow__, __leaf__)); -__extension__ -extern long long int strtoq (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int revoke(const char *__file) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); -__extension__ -extern unsigned long long int strtouq (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int profil(unsigned short int *__sample_buffer, size_t __size, + size_t __offset, unsigned int __scale) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int acct(const char *__name) __attribute__((__nothrow__, __leaf__)); +extern char *getusershell(void) __attribute__((__nothrow__, __leaf__)); +extern void endusershell(void) __attribute__((__nothrow__, __leaf__)); +extern void setusershell(void) __attribute__((__nothrow__, __leaf__)); +extern int daemon(int __nochdir, int __noclose) + __attribute__((__nothrow__, __leaf__)); -__extension__ -extern long long int strtoll (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int chroot(const char *__path) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); -__extension__ -extern unsigned long long int strtoull (const char *__restrict __nptr, - char **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern char *getpass(const char *__prompt) __attribute__((__nonnull__(1))); +extern int fsync(int __fd); +extern int syncfs(int __fd) __attribute__((__nothrow__, __leaf__)); +extern long int gethostid(void); -extern int strfromd (char *__dest, size_t __size, const char *__format, - double __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); +extern void sync(void) __attribute__((__nothrow__, __leaf__)); -extern int strfromf (char *__dest, size_t __size, const char *__format, - float __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); +extern int getpagesize(void) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); -extern int strfroml (char *__dest, size_t __size, const char *__format, - long double __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); -extern int strfromf32 (char *__dest, size_t __size, const char * __format, - _Float32 __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); +extern int getdtablesize(void) __attribute__((__nothrow__, __leaf__)); +extern int truncate(const char *__file, __off_t __length) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int truncate64(const char *__file, __off64_t __length) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int ftruncate(int __fd, __off_t __length) + __attribute__((__nothrow__, __leaf__)); +extern int ftruncate64(int __fd, __off64_t __length) + __attribute__((__nothrow__, __leaf__)); +extern int brk(void *__addr) __attribute__((__nothrow__, __leaf__)); +extern void *sbrk(intptr_t __delta) __attribute__((__nothrow__, __leaf__)); +extern long int syscall(long int __sysno, ...) + __attribute__((__nothrow__, __leaf__)); +extern int lockf(int __fd, int __cmd, __off_t __len); +extern int lockf64(int __fd, int __cmd, __off64_t __len); +ssize_t copy_file_range(int __infd, __off64_t *__pinoff, int __outfd, + __off64_t *__poutoff, size_t __length, + unsigned int __flags); +extern int fdatasync(int __fildes); +extern char *crypt(const char *__key, const char *__salt) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern int strfromf64 (char *__dest, size_t __size, const char * __format, - _Float64 __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); +extern void swab(const void *__restrict __from, void *__restrict __to, + ssize_t __n) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1, 2))); +int getentropy(void *__buffer, size_t __length); +extern __pid_t gettid(void) __attribute__((__nothrow__, __leaf__)); +enum { + _ISupper = ((0) < 8 ? ((1 << (0)) << 8) : ((1 << (0)) >> 8)), + _ISlower = ((1) < 8 ? ((1 << (1)) << 8) : ((1 << (1)) >> 8)), + _ISalpha = ((2) < 8 ? ((1 << (2)) << 8) : ((1 << (2)) >> 8)), + _ISdigit = ((3) < 8 ? ((1 << (3)) << 8) : ((1 << (3)) >> 8)), + _ISxdigit = ((4) < 8 ? ((1 << (4)) << 8) : ((1 << (4)) >> 8)), + _ISspace = ((5) < 8 ? ((1 << (5)) << 8) : ((1 << (5)) >> 8)), + _ISprint = ((6) < 8 ? ((1 << (6)) << 8) : ((1 << (6)) >> 8)), + _ISgraph = ((7) < 8 ? ((1 << (7)) << 8) : ((1 << (7)) >> 8)), + _ISblank = ((8) < 8 ? ((1 << (8)) << 8) : ((1 << (8)) >> 8)), + _IScntrl = ((9) < 8 ? ((1 << (9)) << 8) : ((1 << (9)) >> 8)), + _ISpunct = ((10) < 8 ? ((1 << (10)) << 8) : ((1 << (10)) >> 8)), + _ISalnum = ((11) < 8 ? ((1 << (11)) << 8) : ((1 << (11)) >> 8)) +}; +extern const unsigned short int **__ctype_b_loc(void) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern const __int32_t **__ctype_tolower_loc(void) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern const __int32_t **__ctype_toupper_loc(void) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern int isalnum(int) __attribute__((__nothrow__, __leaf__)); +extern int isalpha(int) __attribute__((__nothrow__, __leaf__)); +extern int iscntrl(int) __attribute__((__nothrow__, __leaf__)); +extern int isdigit(int) __attribute__((__nothrow__, __leaf__)); +extern int islower(int) __attribute__((__nothrow__, __leaf__)); +extern int isgraph(int) __attribute__((__nothrow__, __leaf__)); +extern int isprint(int) __attribute__((__nothrow__, __leaf__)); +extern int ispunct(int) __attribute__((__nothrow__, __leaf__)); +extern int isspace(int) __attribute__((__nothrow__, __leaf__)); +extern int isupper(int) __attribute__((__nothrow__, __leaf__)); +extern int isxdigit(int) __attribute__((__nothrow__, __leaf__)); + +extern int tolower(int __c) __attribute__((__nothrow__, __leaf__)); + +extern int toupper(int __c) __attribute__((__nothrow__, __leaf__)); + +extern int isblank(int) __attribute__((__nothrow__, __leaf__)); + +extern int isctype(int __c, int __mask) __attribute__((__nothrow__, __leaf__)); + +extern int isascii(int __c) __attribute__((__nothrow__, __leaf__)); + +extern int toascii(int __c) __attribute__((__nothrow__, __leaf__)); + +extern int _toupper(int) __attribute__((__nothrow__, __leaf__)); +extern int _tolower(int) __attribute__((__nothrow__, __leaf__)); +extern int isalnum_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isalpha_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int iscntrl_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isdigit_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int islower_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isgraph_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isprint_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int ispunct_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isspace_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isupper_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); +extern int isxdigit_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); + +extern int isblank_l(int, locale_t) __attribute__((__nothrow__, __leaf__)); + +extern int __tolower_l(int __c, locale_t __l) + __attribute__((__nothrow__, __leaf__)); +extern int tolower_l(int __c, locale_t __l) + __attribute__((__nothrow__, __leaf__)); + +extern int __toupper_l(int __c, locale_t __l) + __attribute__((__nothrow__, __leaf__)); +extern int toupper_l(int __c, locale_t __l) + __attribute__((__nothrow__, __leaf__)); + +struct lconv { + char *decimal_point; + char *thousands_sep; -extern int strfromf128 (char *__dest, size_t __size, const char * __format, - _Float128 __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); + char *grouping; + char *int_curr_symbol; + char *currency_symbol; + char *mon_decimal_point; + char *mon_thousands_sep; + char *mon_grouping; + char *positive_sign; + char *negative_sign; + char int_frac_digits; + char frac_digits; + char p_cs_precedes; -extern int strfromf32x (char *__dest, size_t __size, const char * __format, - _Float32x __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); + char p_sep_by_space; + char n_cs_precedes; + char n_sep_by_space; -extern int strfromf64x (char *__dest, size_t __size, const char * __format, - _Float64x __f) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); -struct __locale_struct -{ + char p_sign_posn; + char n_sign_posn; - struct __locale_data *__locales[13]; + char int_p_cs_precedes; + char int_p_sep_by_space; - const unsigned short int *__ctype_b; - const int *__ctype_tolower; - const int *__ctype_toupper; + char int_n_cs_precedes; + char int_n_sep_by_space; - const char *__names[13]; + char int_p_sign_posn; + char int_n_sign_posn; }; -typedef struct __locale_struct *__locale_t; +extern char *setlocale(int __category, const char *__locale) + __attribute__((__nothrow__, __leaf__)); -typedef __locale_t locale_t; +extern struct lconv *localeconv(void) __attribute__((__nothrow__, __leaf__)); +extern locale_t newlocale(int __category_mask, const char *__locale, + locale_t __base) + __attribute__((__nothrow__, __leaf__)); +extern locale_t duplocale(locale_t __dataset) + __attribute__((__nothrow__, __leaf__)); -extern long int strtol_l (const char *__restrict __nptr, - char **__restrict __endptr, int __base, - locale_t __loc) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 4))); +extern void freelocale(locale_t __dataset) + __attribute__((__nothrow__, __leaf__)); -extern unsigned long int strtoul_l (const char *__restrict __nptr, - char **__restrict __endptr, - int __base, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 4))); +extern locale_t uselocale(locale_t __dataset) + __attribute__((__nothrow__, __leaf__)); -__extension__ -extern long long int strtoll_l (const char *__restrict __nptr, - char **__restrict __endptr, int __base, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 4))); +extern int *__errno_location(void) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); -__extension__ -extern unsigned long long int strtoull_l (const char *__restrict __nptr, - char **__restrict __endptr, - int __base, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 4))); +extern char *program_invocation_name; +extern char *program_invocation_short_name; -extern double strtod_l (const char *__restrict __nptr, - char **__restrict __endptr, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); +typedef int error_t; -extern float strtof_l (const char *__restrict __nptr, - char **__restrict __endptr, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); +struct flock { + short int l_type; + short int l_whence; -extern long double strtold_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); -extern _Float32 strtof32_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); + __off_t l_start; + __off_t l_len; + __pid_t l_pid; +}; +struct flock64 { + short int l_type; + short int l_whence; + __off64_t l_start; + __off64_t l_len; + __pid_t l_pid; +}; -extern _Float64 strtof64_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); +struct iovec { + void *iov_base; + size_t iov_len; +}; +enum __pid_type { + F_OWNER_TID = 0, + F_OWNER_PID, + F_OWNER_PGRP, + F_OWNER_GID = F_OWNER_PGRP +}; +struct f_owner_ex { + enum __pid_type type; + __pid_t pid; +}; +struct file_handle { + unsigned int handle_bytes; + int handle_type; -extern _Float128 strtof128_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); + unsigned char f_handle[0]; +}; +extern __ssize_t readahead(int __fd, __off64_t __offset, size_t __count) + __attribute__((__nothrow__, __leaf__)); + +extern int sync_file_range(int __fd, __off64_t __offset, __off64_t __count, + unsigned int __flags); + +extern __ssize_t vmsplice(int __fdout, const struct iovec *__iov, + size_t __count, unsigned int __flags); + +extern __ssize_t splice(int __fdin, __off64_t *__offin, int __fdout, + __off64_t *__offout, size_t __len, + unsigned int __flags); + +extern __ssize_t tee(int __fdin, int __fdout, size_t __len, + unsigned int __flags); + +extern int fallocate(int __fd, int __mode, __off_t __offset, __off_t __len); +extern int fallocate64(int __fd, int __mode, __off64_t __offset, + __off64_t __len); + +extern int name_to_handle_at(int __dfd, const char *__name, + struct file_handle *__handle, int *__mnt_id, + int __flags) + __attribute__((__nothrow__, __leaf__)); + +extern int open_by_handle_at(int __mountdirfd, struct file_handle *__handle, + int __flags); + +extern int fcntl(int __fd, int __cmd, ...); +extern int fcntl64(int __fd, int __cmd, ...); +extern int open(const char *__file, int __oflag, ...) + __attribute__((__nonnull__(1))); +extern int open64(const char *__file, int __oflag, ...) + __attribute__((__nonnull__(1))); +extern int openat(int __fd, const char *__file, int __oflag, ...) + __attribute__((__nonnull__(2))); +extern int openat64(int __fd, const char *__file, int __oflag, ...) + __attribute__((__nonnull__(2))); +extern int creat(const char *__file, mode_t __mode) + __attribute__((__nonnull__(1))); +extern int creat64(const char *__file, mode_t __mode) + __attribute__((__nonnull__(1))); +extern int posix_fadvise(int __fd, off_t __offset, off_t __len, int __advise) + __attribute__((__nothrow__, __leaf__)); +extern int posix_fadvise64(int __fd, off64_t __offset, off64_t __len, + int __advise) __attribute__((__nothrow__, __leaf__)); +extern int posix_fallocate(int __fd, off_t __offset, off_t __len); +extern int posix_fallocate64(int __fd, off64_t __offset, off64_t __len); +typedef float float_t; +typedef double double_t; -extern _Float32x strtof32x_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); +enum { + FP_INT_UPWARD = + 0, + FP_INT_DOWNWARD = + 1, + FP_INT_TOWARDZERO = -extern _Float64x strtof64x_l (const char *__restrict __nptr, - char **__restrict __endptr, - locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); -extern char *l64a (long int __n) __attribute__ ((__nothrow__ , __leaf__)) ; + 2, + FP_INT_TONEARESTFROMZERO = + 3, + FP_INT_TONEAREST = -extern long int a64l (const char *__s) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ; + 4, +}; +extern int __fpclassify(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __signbit(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __isinf(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __finite(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __isnan(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __iseqsig(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern int __issignaling(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double acos(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __acos(double __x) __attribute__((__nothrow__, __leaf__)); +extern double asin(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __asin(double __x) __attribute__((__nothrow__, __leaf__)); +extern double atan(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __atan(double __x) __attribute__((__nothrow__, __leaf__)); +extern double atan2(double __y, double __x) + __attribute__((__nothrow__, __leaf__)); +extern double __atan2(double __y, double __x) + __attribute__((__nothrow__, __leaf__)); -typedef __u_char u_char; -typedef __u_short u_short; -typedef __u_int u_int; -typedef __u_long u_long; -typedef __quad_t quad_t; -typedef __u_quad_t u_quad_t; -typedef __fsid_t fsid_t; +extern double cos(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __cos(double __x) __attribute__((__nothrow__, __leaf__)); +extern double sin(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __sin(double __x) __attribute__((__nothrow__, __leaf__)); -typedef __loff_t loff_t; -typedef __ino64_t ino64_t; -typedef __pid_t pid_t; +extern double tan(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __tan(double __x) __attribute__((__nothrow__, __leaf__)); +extern double cosh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __cosh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double sinh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __sinh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double tanh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __tanh(double __x) __attribute__((__nothrow__, __leaf__)); +extern void sincos(double __x, double *__sinx, double *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincos(double __x, double *__sinx, double *__cosx) + __attribute__((__nothrow__, __leaf__)); -typedef __id_t id_t; -typedef __daddr_t daddr_t; -typedef __caddr_t caddr_t; +extern double acosh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __acosh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double asinh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __asinh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double atanh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __atanh(double __x) __attribute__((__nothrow__, __leaf__)); +extern double exp(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __exp(double __x) __attribute__((__nothrow__, __leaf__)); +extern double frexp(double __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern double __frexp(double __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); -typedef __key_t key_t; +extern double ldexp(double __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern double __ldexp(double __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern double log(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __log(double __x) __attribute__((__nothrow__, __leaf__)); +extern double log10(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __log10(double __x) __attribute__((__nothrow__, __leaf__)); +extern double modf(double __x, double *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern double __modf(double __x, double *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern double exp10(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __exp10(double __x) __attribute__((__nothrow__, __leaf__)); +extern double expm1(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __expm1(double __x) __attribute__((__nothrow__, __leaf__)); +extern double log1p(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __log1p(double __x) __attribute__((__nothrow__, __leaf__)); +extern double logb(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __logb(double __x) __attribute__((__nothrow__, __leaf__)); +extern double exp2(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __exp2(double __x) __attribute__((__nothrow__, __leaf__)); +extern double log2(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __log2(double __x) __attribute__((__nothrow__, __leaf__)); -typedef __clock_t clock_t; +extern double pow(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __pow(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double sqrt(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __sqrt(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double hypot(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __hypot(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double cbrt(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __cbrt(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double ceil(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __ceil(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double fabs(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __fabs(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double floor(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __floor(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double fmod(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __fmod(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern int isinf(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int finite(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double drem(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __drem(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double significand(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __significand(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double copysign(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern double __copysign(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern double nan(const char *__tagb) __attribute__((__nothrow__, __leaf__)); +extern double __nan(const char *__tagb) __attribute__((__nothrow__, __leaf__)); +extern int isnan(double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double j0(double) __attribute__((__nothrow__, __leaf__)); +extern double __j0(double) __attribute__((__nothrow__, __leaf__)); +extern double j1(double) __attribute__((__nothrow__, __leaf__)); +extern double __j1(double) __attribute__((__nothrow__, __leaf__)); +extern double jn(int, double) __attribute__((__nothrow__, __leaf__)); +extern double __jn(int, double) __attribute__((__nothrow__, __leaf__)); +extern double y0(double) __attribute__((__nothrow__, __leaf__)); +extern double __y0(double) __attribute__((__nothrow__, __leaf__)); +extern double y1(double) __attribute__((__nothrow__, __leaf__)); +extern double __y1(double) __attribute__((__nothrow__, __leaf__)); +extern double yn(int, double) __attribute__((__nothrow__, __leaf__)); +extern double __yn(int, double) __attribute__((__nothrow__, __leaf__)); + +extern double erf(double) __attribute__((__nothrow__, __leaf__)); +extern double __erf(double) __attribute__((__nothrow__, __leaf__)); +extern double erfc(double) __attribute__((__nothrow__, __leaf__)); +extern double __erfc(double) __attribute__((__nothrow__, __leaf__)); +extern double lgamma(double) __attribute__((__nothrow__, __leaf__)); +extern double __lgamma(double) __attribute__((__nothrow__, __leaf__)); + +extern double tgamma(double) __attribute__((__nothrow__, __leaf__)); +extern double __tgamma(double) __attribute__((__nothrow__, __leaf__)); + +extern double gamma(double) __attribute__((__nothrow__, __leaf__)); +extern double __gamma(double) __attribute__((__nothrow__, __leaf__)); + +extern double lgamma_r(double, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern double __lgamma_r(double, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern double rint(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __rint(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double nextafter(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __nextafter(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double nexttoward(double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __nexttoward(double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double nextdown(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __nextdown(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double nextup(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __nextup(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double remainder(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __remainder(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double scalbn(double __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern double __scalbn(double __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogb(double __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogb(double __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogb(double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogb(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double scalbln(double __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern double __scalbln(double __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern double nearbyint(double __x) __attribute__((__nothrow__, __leaf__)); +extern double __nearbyint(double __x) __attribute__((__nothrow__, __leaf__)); + +extern double round(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __round(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double trunc(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __trunc(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern double remquo(double __x, double __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern double __remquo(double __x, double __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrint(double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrint(double __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrint(double __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrint(double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lround(double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lround(double __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llround(double __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llround(double __x) + __attribute__((__nothrow__, __leaf__)); + +extern double fdim(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern double __fdim(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); + +extern double fmax(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern double __fmax(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern double fmin(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern double __fmin(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern double fma(double __x, double __y, double __z) + __attribute__((__nothrow__, __leaf__)); +extern double __fma(double __x, double __y, double __z) + __attribute__((__nothrow__, __leaf__)); + +extern double roundeven(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern double __roundeven(double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern __intmax_t fromfp(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfp(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfp(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfp(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpx(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpx(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpx(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpx(double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern double fmaxmag(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern double __fmaxmag(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern double fminmag(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern double __fminmag(double __x, double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalize(double *__cx, const double *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorder(const double *__x, const double *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermag(const double *__x, const double *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern double getpayload(const double *__x) + __attribute__((__nothrow__, __leaf__)); +extern double __getpayload(const double *__x) + __attribute__((__nothrow__, __leaf__)); +extern int setpayload(double *__x, double __payload) + __attribute__((__nothrow__, __leaf__)); -typedef __clockid_t clockid_t; +extern int setpayloadsig(double *__x, double __payload) + __attribute__((__nothrow__, __leaf__)); +extern double scalb(double __x, double __n) + __attribute__((__nothrow__, __leaf__)); +extern double __scalb(double __x, double __n) + __attribute__((__nothrow__, __leaf__)); +extern int __fpclassifyf(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __signbitf(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __isinff(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __finitef(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __isnanf(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __iseqsigf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); -typedef __timer_t timer_t; +extern int __issignalingf(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float acosf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __acosf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float asinf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __asinf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float atanf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __atanf(float __x) __attribute__((__nothrow__, __leaf__)); -typedef __useconds_t useconds_t; +extern float atan2f(float __y, float __x) + __attribute__((__nothrow__, __leaf__)); +extern float __atan2f(float __y, float __x) + __attribute__((__nothrow__, __leaf__)); +extern float cosf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __cosf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float sinf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __sinf(float __x) __attribute__((__nothrow__, __leaf__)); -typedef __suseconds_t suseconds_t; +extern float tanf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __tanf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float coshf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __coshf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float sinhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __sinhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float tanhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __tanhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern void sincosf(float __x, float *__sinx, float *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf(float __x, float *__sinx, float *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern float acoshf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __acoshf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float asinhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __asinhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float atanhf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __atanhf(float __x) __attribute__((__nothrow__, __leaf__)); -typedef unsigned long int ulong; -typedef unsigned short int ushort; -typedef unsigned int uint; +extern float expf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __expf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float frexpf(float __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern float __frexpf(float __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern float ldexpf(float __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern float __ldexpf(float __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern float logf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __logf(float __x) __attribute__((__nothrow__, __leaf__)); -typedef __int8_t int8_t; -typedef __int16_t int16_t; -typedef __int32_t int32_t; -typedef __int64_t int64_t; +extern float log10f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __log10f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float modff(float __x, float *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern float __modff(float __x, float *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); -typedef __uint8_t u_int8_t; -typedef __uint16_t u_int16_t; -typedef __uint32_t u_int32_t; -typedef __uint64_t u_int64_t; +extern float exp10f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __exp10f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float expm1f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __expm1f(float __x) __attribute__((__nothrow__, __leaf__)); -typedef int register_t __attribute__ ((__mode__ (__word__))); -static __inline __uint16_t -__bswap_16 (__uint16_t __bsx) -{ +extern float log1pf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __log1pf(float __x) __attribute__((__nothrow__, __leaf__)); - return __builtin_bswap16 (__bsx); +extern float logbf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __logbf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float exp2f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __exp2f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float log2f(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __log2f(float __x) __attribute__((__nothrow__, __leaf__)); -} +extern float powf(float __x, float __y) __attribute__((__nothrow__, __leaf__)); +extern float __powf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern float sqrtf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __sqrtf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float hypotf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern float __hypotf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern float cbrtf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __cbrtf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float ceilf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __ceilf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float fabsf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __fabsf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); -static __inline __uint32_t -__bswap_32 (__uint32_t __bsx) -{ +extern float floorf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __floorf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); - return __builtin_bswap32 (__bsx); +extern float fmodf(float __x, float __y) __attribute__((__nothrow__, __leaf__)); +extern float __fmodf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern int isinff(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int finitef(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern float dremf(float __x, float __y) __attribute__((__nothrow__, __leaf__)); +extern float __dremf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); + +extern float significandf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __significandf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float copysignf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern float __copysignf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern float nanf(const char *__tagb) __attribute__((__nothrow__, __leaf__)); +extern float __nanf(const char *__tagb) __attribute__((__nothrow__, __leaf__)); +extern int isnanf(float __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern float j0f(float) __attribute__((__nothrow__, __leaf__)); +extern float __j0f(float) __attribute__((__nothrow__, __leaf__)); +extern float j1f(float) __attribute__((__nothrow__, __leaf__)); +extern float __j1f(float) __attribute__((__nothrow__, __leaf__)); +extern float jnf(int, float) __attribute__((__nothrow__, __leaf__)); +extern float __jnf(int, float) __attribute__((__nothrow__, __leaf__)); +extern float y0f(float) __attribute__((__nothrow__, __leaf__)); +extern float __y0f(float) __attribute__((__nothrow__, __leaf__)); +extern float y1f(float) __attribute__((__nothrow__, __leaf__)); +extern float __y1f(float) __attribute__((__nothrow__, __leaf__)); +extern float ynf(int, float) __attribute__((__nothrow__, __leaf__)); +extern float __ynf(int, float) __attribute__((__nothrow__, __leaf__)); + +extern float erff(float) __attribute__((__nothrow__, __leaf__)); +extern float __erff(float) __attribute__((__nothrow__, __leaf__)); +extern float erfcf(float) __attribute__((__nothrow__, __leaf__)); +extern float __erfcf(float) __attribute__((__nothrow__, __leaf__)); +extern float lgammaf(float) __attribute__((__nothrow__, __leaf__)); +extern float __lgammaf(float) __attribute__((__nothrow__, __leaf__)); + +extern float tgammaf(float) __attribute__((__nothrow__, __leaf__)); +extern float __tgammaf(float) __attribute__((__nothrow__, __leaf__)); + +extern float gammaf(float) __attribute__((__nothrow__, __leaf__)); +extern float __gammaf(float) __attribute__((__nothrow__, __leaf__)); + +extern float lgammaf_r(float, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern float __lgammaf_r(float, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern float rintf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __rintf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float nextafterf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern float __nextafterf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); + +extern float nexttowardf(float __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern float __nexttowardf(float __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern float nextdownf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __nextdownf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float nextupf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __nextupf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float remainderf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); +extern float __remainderf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); + +extern float scalbnf(float __x, int __n) __attribute__((__nothrow__, __leaf__)); +extern float __scalbnf(float __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf(float __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf(float __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float scalblnf(float __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern float __scalblnf(float __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern float nearbyintf(float __x) __attribute__((__nothrow__, __leaf__)); +extern float __nearbyintf(float __x) __attribute__((__nothrow__, __leaf__)); + +extern float roundf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __roundf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern float truncf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __truncf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern float remquof(float __x, float __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern float __remquof(float __x, float __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf(float __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf(float __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf(float __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf(float __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf(float __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf(float __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf(float __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf(float __x) + __attribute__((__nothrow__, __leaf__)); + +extern float fdimf(float __x, float __y) __attribute__((__nothrow__, __leaf__)); +extern float __fdimf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)); + +extern float fmaxf(float __x, float __y) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __fmaxf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern float fminf(float __x, float __y) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __fminf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern float fmaf(float __x, float __y, float __z) + __attribute__((__nothrow__, __leaf__)); +extern float __fmaf(float __x, float __y, float __z) + __attribute__((__nothrow__, __leaf__)); + +extern float roundevenf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern float __roundevenf(float __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern __intmax_t fromfpf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf(float __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern float fmaxmagf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern float __fmaxmagf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern float fminmagf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern float __fminmagf(float __x, float __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef(float *__cx, const float *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf(const float *__x, const float *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermagf(const float *__x, const float *__y) + __attribute__((__nothrow__, __leaf__)) -} -__extension__ static __inline __uint64_t -__bswap_64 (__uint64_t __bsx) -{ + __attribute__((__pure__)); - return __builtin_bswap64 (__bsx); +extern float getpayloadf(const float *__x) + __attribute__((__nothrow__, __leaf__)); +extern float __getpayloadf(const float *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadf(float *__x, float __payload) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadsigf(float *__x, float __payload) + __attribute__((__nothrow__, __leaf__)); + +extern float scalbf(float __x, float __n) + __attribute__((__nothrow__, __leaf__)); +extern float __scalbf(float __x, float __n) + __attribute__((__nothrow__, __leaf__)); +extern int __fpclassifyl(long double __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int __signbitl(long double __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int __isinfl(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int __finitel(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int __isnanl(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int __iseqsigl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern int __issignalingl(long double __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double acosl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __acosl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double asinl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __asinl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double atanl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __atanl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double atan2l(long double __y, long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __atan2l(long double __y, long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double cosl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long double __cosl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double sinl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long double __sinl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double tanl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long double __tanl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double coshl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __coshl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double sinhl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __sinhl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double tanhl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __tanhl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern void sincosl(long double __x, long double *__sinx, long double *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosl(long double __x, long double *__sinx, long double *__cosx) + __attribute__((__nothrow__, __leaf__)); + +extern long double acoshl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __acoshl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double asinhl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __asinhl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double atanhl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __atanhl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double expl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long double __expl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double frexpl(long double __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern long double __frexpl(long double __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern long double ldexpl(long double __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern long double __ldexpl(long double __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern long double logl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long double __logl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double log10l(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __log10l(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double modfl(long double __x, long double *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern long double __modfl(long double __x, long double *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern long double exp10l(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __exp10l(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double expm1l(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __expm1l(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double log1pl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __log1pl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double logbl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __logbl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double exp2l(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __exp2l(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double log2l(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __log2l(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double powl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __powl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double sqrtl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __sqrtl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double hypotl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __hypotl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double cbrtl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __cbrtl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double ceill(long double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern long double __ceill(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double fabsl(long double __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern long double __fabsl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double floorl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __floorl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double fmodl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __fmodl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern int isinfl(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int finitel(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern long double dreml(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __dreml(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double significandl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __significandl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double copysignl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __copysignl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double nanl(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern long double __nanl(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern int isnanl(long double __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern long double j0l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __j0l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double j1l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __j1l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double jnl(int, long double) __attribute__((__nothrow__, __leaf__)); +extern long double __jnl(int, long double) + __attribute__((__nothrow__, __leaf__)); +extern long double y0l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __y0l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double y1l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __y1l(long double) __attribute__((__nothrow__, __leaf__)); +extern long double ynl(int, long double) __attribute__((__nothrow__, __leaf__)); +extern long double __ynl(int, long double) + __attribute__((__nothrow__, __leaf__)); + +extern long double erfl(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __erfl(long double) __attribute__((__nothrow__, __leaf__)); +extern long double erfcl(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __erfcl(long double) __attribute__((__nothrow__, __leaf__)); +extern long double lgammal(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __lgammal(long double) + __attribute__((__nothrow__, __leaf__)); + +extern long double tgammal(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __tgammal(long double) + __attribute__((__nothrow__, __leaf__)); + +extern long double gammal(long double) __attribute__((__nothrow__, __leaf__)); +extern long double __gammal(long double) __attribute__((__nothrow__, __leaf__)); + +extern long double lgammal_r(long double, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern long double __lgammal_r(long double, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern long double rintl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __rintl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double nextafterl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __nextafterl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double nexttowardl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __nexttowardl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double nextdownl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __nextdownl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double nextupl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __nextupl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double remainderl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __remainderl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double scalbnl(long double __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern long double __scalbnl(long double __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbl(long double __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double scalblnl(long double __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern long double __scalblnl(long double __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern long double nearbyintl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long double __nearbyintl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double roundl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __roundl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double truncl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __truncl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double remquol(long double __x, long double __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern long double __remquol(long double __x, long double __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintl(long double __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundl(long double __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lroundl(long double __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundl(long double __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundl(long double __x) + __attribute__((__nothrow__, __leaf__)); + +extern long double fdiml(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern long double __fdiml(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); + +extern long double fmaxl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __fmaxl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double fminl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __fminl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double fmal(long double __x, long double __y, long double __z) + __attribute__((__nothrow__, __leaf__)); +extern long double __fmal(long double __x, long double __y, long double __z) + __attribute__((__nothrow__, __leaf__)); + +extern long double roundevenl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __roundevenl(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpl(long double __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxl(long double __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxl(long double __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern long double fmaxmagl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __fmaxmagl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern long double fminmagl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern long double __fminmagl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizel(long double *__cx, const long double *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderl(const long double *__x, const long double *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermagl(const long double *__x, const long double *__y) + __attribute__((__nothrow__, __leaf__)) -} -static __inline __uint16_t -__uint16_identity (__uint16_t __x) -{ - return __x; -} + __attribute__((__pure__)); -static __inline __uint32_t -__uint32_identity (__uint32_t __x) -{ - return __x; -} +extern long double getpayloadl(const long double *__x) + __attribute__((__nothrow__, __leaf__)); +extern long double __getpayloadl(const long double *__x) + __attribute__((__nothrow__, __leaf__)); -static __inline __uint64_t -__uint64_identity (__uint64_t __x) -{ - return __x; -} +extern int setpayloadl(long double *__x, long double __payload) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadsigl(long double *__x, long double __payload) + __attribute__((__nothrow__, __leaf__)); +extern long double scalbl(long double __x, long double __n) + __attribute__((__nothrow__, __leaf__)); +extern long double __scalbl(long double __x, long double __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 acosf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __acosf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 asinf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __asinf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 atanf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __atanf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 atan2f32(_Float32 __y, _Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __atan2f32(_Float32 __y, _Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 cosf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __cosf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 sinf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __sinf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 tanf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __tanf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 coshf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __coshf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 sinhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __sinhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); -typedef struct -{ - unsigned long int __val[(1024 / (8 * sizeof (unsigned long int)))]; -} __sigset_t; +extern _Float32 tanhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __tanhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern void sincosf32(_Float32 __x, _Float32 *__sinx, _Float32 *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf32(_Float32 __x, _Float32 *__sinx, _Float32 *__cosx) + __attribute__((__nothrow__, __leaf__)); -typedef __sigset_t sigset_t; +extern _Float32 acoshf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __acoshf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 asinhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __asinhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 atanhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __atanhf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 expf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __expf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 frexpf32(_Float32 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __frexpf32(_Float32 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 ldexpf32(_Float32 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __ldexpf32(_Float32 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 logf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __logf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 log10f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __log10f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 modff32(_Float32 __x, _Float32 *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __modff32(_Float32 __x, _Float32 *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern _Float32 exp10f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __exp10f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 expm1f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __expm1f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 log1pf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __log1pf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 logbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __logbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 exp2f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __exp2f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 log2f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __log2f32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 powf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __powf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 sqrtf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __sqrtf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 hypotf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __hypotf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 cbrtf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __cbrtf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 ceilf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32 __ceilf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float32 fabsf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32 __fabsf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float32 floorf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32 __floorf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float32 fmodf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __fmodf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 copysignf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __copysignf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32 nanf32(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __nanf32(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 j0f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __j0f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 j1f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __j1f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 jnf32(int, _Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __jnf32(int, _Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 y0f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __y0f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 y1f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __y1f32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 ynf32(int, _Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __ynf32(int, _Float32) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 erff32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __erff32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 erfcf32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __erfcf32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 lgammaf32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __lgammaf32(_Float32) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 tgammaf32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __tgammaf32(_Float32) __attribute__((__nothrow__, __leaf__)); +extern _Float32 lgammaf32_r(_Float32, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __lgammaf32_r(_Float32, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 rintf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __rintf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 nextafterf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __nextafterf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 nextdownf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __nextdownf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 nextupf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32 __nextupf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 remainderf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __remainderf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 scalbnf32(_Float32 __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __scalbnf32(_Float32 __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32 scalblnf32(_Float32 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __scalblnf32(_Float32 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 nearbyintf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __nearbyintf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 roundf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32 __roundf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float32 truncf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32 __truncf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float32 remquof32(_Float32 __x, _Float32 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __remquof32(_Float32 __x, _Float32 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf32(_Float32 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 fdimf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __fdimf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 fmaxf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __fmaxf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32 fminf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __fminf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32 fmaf32(_Float32 __x, _Float32 __y, _Float32 __z) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __fmaf32(_Float32 __x, _Float32 __y, _Float32 __z) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 roundevenf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __roundevenf32(_Float32 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf32(_Float32 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf32(_Float32 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32 fmaxmagf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __fmaxmagf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32 fminmagf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32 __fminmagf32(_Float32 __x, _Float32 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef32(_Float32 *__cx, const _Float32 *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf32(const _Float32 *__x, const _Float32 *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermagf32(const _Float32 *__x, const _Float32 *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern _Float32 getpayloadf32(const _Float32 *__x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 __getpayloadf32(const _Float32 *__x) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadf32(_Float32 *__x, _Float32 __payload) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadsigf32(_Float32 *__x, _Float32 __payload) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 acosf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __acosf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 asinf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __asinf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 atanf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __atanf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 atan2f64(_Float64 __y, _Float64 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __atan2f64(_Float64 __y, _Float64 __x) + __attribute__((__nothrow__, __leaf__)); -struct timeval -{ - __time_t tv_sec; - __suseconds_t tv_usec; -}; -typedef long int __fd_mask; -typedef struct - { +extern _Float64 cosf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __cosf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 sinf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __sinf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 tanf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __tanf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); - __fd_mask fds_bits[1024 / (8 * (int) sizeof (__fd_mask))]; +extern _Float64 coshf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __coshf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 sinhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __sinhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 tanhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __tanhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern void sincosf64(_Float64 __x, _Float64 *__sinx, _Float64 *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf64(_Float64 __x, _Float64 *__sinx, _Float64 *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 acoshf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __acoshf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); - } fd_set; +extern _Float64 asinhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __asinhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 atanhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __atanhf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 expf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __expf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 frexpf64(_Float64 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __frexpf64(_Float64 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 ldexpf64(_Float64 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __ldexpf64(_Float64 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 logf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __logf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 log10f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __log10f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 modff64(_Float64 __x, _Float64 *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __modff64(_Float64 __x, _Float64 *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern _Float64 exp10f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __exp10f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 expm1f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __expm1f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 log1pf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __log1pf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 logbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __logbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 exp2f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __exp2f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 log2f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __log2f64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 powf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __powf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 sqrtf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __sqrtf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 hypotf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __hypotf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 cbrtf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __cbrtf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 ceilf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64 __ceilf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float64 fabsf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64 __fabsf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float64 floorf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64 __floorf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float64 fmodf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __fmodf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 copysignf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __copysignf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64 nanf64(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __nanf64(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 j0f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __j0f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 j1f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __j1f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 jnf64(int, _Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __jnf64(int, _Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 y0f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __y0f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 y1f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __y1f64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 ynf64(int, _Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __ynf64(int, _Float64) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 erff64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __erff64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 erfcf64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __erfcf64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 lgammaf64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __lgammaf64(_Float64) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 tgammaf64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __tgammaf64(_Float64) __attribute__((__nothrow__, __leaf__)); +extern _Float64 lgammaf64_r(_Float64, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __lgammaf64_r(_Float64, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 rintf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __rintf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 nextafterf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __nextafterf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 nextdownf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __nextdownf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 nextupf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64 __nextupf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 remainderf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __remainderf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 scalbnf64(_Float64 __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __scalbnf64(_Float64 __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64 scalblnf64(_Float64 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __scalblnf64(_Float64 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 nearbyintf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __nearbyintf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 roundf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64 __roundf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float64 truncf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64 __truncf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern _Float64 remquof64(_Float64 __x, _Float64 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __remquof64(_Float64 __x, _Float64 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf64(_Float64 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 fdimf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __fdimf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 fmaxf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __fmaxf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64 fminf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __fminf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64 fmaf64(_Float64 __x, _Float64 __y, _Float64 __z) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __fmaf64(_Float64 __x, _Float64 __y, _Float64 __z) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 roundevenf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __roundevenf64(_Float64 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf64(_Float64 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf64(_Float64 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64 fmaxmagf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __fmaxmagf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64 fminmagf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64 __fminmagf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef64(_Float64 *__cx, const _Float64 *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf64(const _Float64 *__x, const _Float64 *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermagf64(const _Float64 *__x, const _Float64 *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern _Float64 getpayloadf64(const _Float64 *__x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 __getpayloadf64(const _Float64 *__x) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadf64(_Float64 *__x, _Float64 __payload) + __attribute__((__nothrow__, __leaf__)); -typedef __fd_mask fd_mask; +extern int setpayloadsigf64(_Float64 *__x, _Float64 __payload) + __attribute__((__nothrow__, __leaf__)); +extern int __fpclassifyf128(_Float128 __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); -extern int select (int __nfds, fd_set *__restrict __readfds, - fd_set *__restrict __writefds, - fd_set *__restrict __exceptfds, - struct timeval *__restrict __timeout); -extern int pselect (int __nfds, fd_set *__restrict __readfds, - fd_set *__restrict __writefds, - fd_set *__restrict __exceptfds, - const struct timespec *__restrict __timeout, - const __sigset_t *__restrict __sigmask); +extern int __signbitf128(_Float128 __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); -typedef __fsblkcnt_t fsblkcnt_t; +extern int __isinff128(_Float128 __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); + +extern int __finitef128(_Float128 __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern int __isnanf128(_Float128 __value) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int __iseqsigf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern int __issignalingf128(_Float128 __value) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 acosf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __acosf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 asinf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __asinf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 atanf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __atanf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 atan2f128(_Float128 __y, _Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __atan2f128(_Float128 __y, _Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 cosf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __cosf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 sinf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __sinf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 tanf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __tanf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 coshf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __coshf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 sinhf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __sinhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 tanhf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __tanhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern void sincosf128(_Float128 __x, _Float128 *__sinx, _Float128 *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf128(_Float128 __x, _Float128 *__sinx, _Float128 *__cosx) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 acoshf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __acoshf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 asinhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __asinhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 atanhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __atanhf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 expf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __expf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 frexpf128(_Float128 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __frexpf128(_Float128 __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 ldexpf128(_Float128 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __ldexpf128(_Float128 __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 logf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __logf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 log10f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __log10f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 modff128(_Float128 __x, _Float128 *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __modff128(_Float128 __x, _Float128 *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern _Float128 exp10f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __exp10f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 expm1f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __expm1f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 log1pf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __log1pf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 logbf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __logbf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 exp2f128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __exp2f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 log2f128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __log2f128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 powf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __powf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 sqrtf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __sqrtf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 hypotf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __hypotf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 cbrtf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __cbrtf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 ceilf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float128 __ceilf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 fabsf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float128 __fabsf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 floorf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float128 __floorf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 fmodf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __fmodf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 copysignf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __copysignf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 nanf128(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __nanf128(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 j0f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __j0f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 j1f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __j1f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 jnf128(int, _Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __jnf128(int, _Float128) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 y0f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __y0f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 y1f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __y1f128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 ynf128(int, _Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __ynf128(int, _Float128) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 erff128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __erff128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 erfcf128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __erfcf128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 lgammaf128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __lgammaf128(_Float128) __attribute__((__nothrow__, __leaf__)); + +extern _Float128 tgammaf128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __tgammaf128(_Float128) __attribute__((__nothrow__, __leaf__)); +extern _Float128 lgammaf128_r(_Float128, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __lgammaf128_r(_Float128, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 rintf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern _Float128 __rintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 nextafterf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __nextafterf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 nextdownf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __nextdownf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 nextupf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __nextupf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 remainderf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __remainderf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 scalbnf128(_Float128 __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __scalbnf128(_Float128 __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 scalblnf128(_Float128 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __scalblnf128(_Float128 __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 nearbyintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __nearbyintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 roundf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float128 __roundf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 truncf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float128 __truncf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 remquof128(_Float128 __x, _Float128 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __remquof128(_Float128 __x, _Float128 __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf128(_Float128 __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 fdimf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __fdimf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 fmaxf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __fmaxf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 fminf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __fminf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 fmaf128(_Float128 __x, _Float128 __y, _Float128 __z) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __fmaf128(_Float128 __x, _Float128 __y, _Float128 __z) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 roundevenf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __roundevenf128(_Float128 __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpf128(_Float128 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf128(_Float128 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf128(_Float128 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf128(_Float128 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf128(_Float128 __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf128(_Float128 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf128(_Float128 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf128(_Float128 __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern _Float128 fmaxmagf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __fmaxmagf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float128 fminmagf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float128 __fminmagf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef128(_Float128 *__cx, const _Float128 *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf128(const _Float128 *__x, const _Float128 *__y) + __attribute__((__nothrow__, __leaf__)) -typedef __fsfilcnt_t fsfilcnt_t; -typedef __blkcnt64_t blkcnt64_t; -typedef __fsblkcnt64_t fsblkcnt64_t; -typedef __fsfilcnt64_t fsfilcnt64_t; + __attribute__((__pure__)); +extern int totalordermagf128(const _Float128 *__x, const _Float128 *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern _Float128 getpayloadf128(const _Float128 *__x) + __attribute__((__nothrow__, __leaf__)); +extern _Float128 __getpayloadf128(const _Float128 *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadf128(_Float128 *__x, _Float128 __payload) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadsigf128(_Float128 *__x, _Float128 __payload) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x acosf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __acosf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x asinf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __asinf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x atanf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __atanf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x atan2f32x(_Float32x __y, _Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __atan2f32x(_Float32x __y, _Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x cosf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __cosf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x sinf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __sinf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x tanf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __tanf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x coshf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __coshf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x sinhf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __sinhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x tanhf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __tanhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern void sincosf32x(_Float32x __x, _Float32x *__sinx, _Float32x *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf32x(_Float32x __x, _Float32x *__sinx, _Float32x *__cosx) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x acoshf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __acoshf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x asinhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __asinhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x atanhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __atanhf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x expf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __expf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x frexpf32x(_Float32x __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __frexpf32x(_Float32x __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x ldexpf32x(_Float32x __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __ldexpf32x(_Float32x __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x logf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __logf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x log10f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __log10f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x modff32x(_Float32x __x, _Float32x *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __modff32x(_Float32x __x, _Float32x *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern _Float32x exp10f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __exp10f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x expm1f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __expm1f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x log1pf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __log1pf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x logbf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __logbf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x exp2f32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __exp2f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x log2f32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __log2f32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x powf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __powf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x sqrtf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __sqrtf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x hypotf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __hypotf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x cbrtf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __cbrtf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x ceilf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32x __ceilf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x fabsf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32x __fabsf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x floorf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32x __floorf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x fmodf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __fmodf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x copysignf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __copysignf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x nanf32x(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __nanf32x(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x j0f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __j0f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x j1f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __j1f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x jnf32x(int, _Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __jnf32x(int, _Float32x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x y0f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __y0f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x y1f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __y1f32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x ynf32x(int, _Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __ynf32x(int, _Float32x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x erff32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __erff32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x erfcf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __erfcf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x lgammaf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __lgammaf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); + +extern _Float32x tgammaf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __tgammaf32x(_Float32x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x lgammaf32x_r(_Float32x, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __lgammaf32x_r(_Float32x, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x rintf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float32x __rintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x nextafterf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __nextafterf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x nextdownf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __nextdownf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x nextupf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __nextupf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x remainderf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __remainderf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x scalbnf32x(_Float32x __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __scalbnf32x(_Float32x __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x scalblnf32x(_Float32x __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __scalblnf32x(_Float32x __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x nearbyintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __nearbyintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x roundf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32x __roundf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x truncf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float32x __truncf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x remquof32x(_Float32x __x, _Float32x __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __remquof32x(_Float32x __x, _Float32x __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf32x(_Float32x __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x fdimf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __fdimf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x fmaxf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __fmaxf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x fminf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __fminf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x fmaf32x(_Float32x __x, _Float32x __y, _Float32x __z) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __fmaf32x(_Float32x __x, _Float32x __y, _Float32x __z) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x roundevenf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __roundevenf32x(_Float32x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpf32x(_Float32x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf32x(_Float32x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf32x(_Float32x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf32x(_Float32x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf32x(_Float32x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf32x(_Float32x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf32x(_Float32x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf32x(_Float32x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern _Float32x fmaxmagf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __fmaxmagf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float32x fminmagf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float32x __fminmagf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef32x(_Float32x *__cx, const _Float32x *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf32x(const _Float32x *__x, const _Float32x *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern int totalordermagf32x(const _Float32x *__x, const _Float32x *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); +extern _Float32x getpayloadf32x(const _Float32x *__x) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x __getpayloadf32x(const _Float32x *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadf32x(_Float32x *__x, _Float32x __payload) + __attribute__((__nothrow__, __leaf__)); + +extern int setpayloadsigf32x(_Float32x *__x, _Float32x __payload) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x acosf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __acosf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x asinf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __asinf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x atanf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __atanf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x atan2f64x(_Float64x __y, _Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __atan2f64x(_Float64x __y, _Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x cosf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __cosf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x sinf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __sinf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x tanf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __tanf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x coshf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __coshf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x sinhf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __sinhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x tanhf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __tanhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern void sincosf64x(_Float64x __x, _Float64x *__sinx, _Float64x *__cosx) + __attribute__((__nothrow__, __leaf__)); +extern void __sincosf64x(_Float64x __x, _Float64x *__sinx, _Float64x *__cosx) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x acoshf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __acoshf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x asinhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __asinhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x atanhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __atanhf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x expf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __expf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x frexpf64x(_Float64x __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __frexpf64x(_Float64x __x, int *__exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x ldexpf64x(_Float64x __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __ldexpf64x(_Float64x __x, int __exponent) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x logf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __logf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x log10f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __log10f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x modff64x(_Float64x __x, _Float64x *__iptr) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __modff64x(_Float64x __x, _Float64x *__iptr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +extern _Float64x exp10f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __exp10f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x expm1f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __expm1f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x log1pf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __log1pf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x logbf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __logbf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x exp2f64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __exp2f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x log2f64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __log2f64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x powf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __powf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x sqrtf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __sqrtf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x hypotf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __hypotf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x cbrtf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __cbrtf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x ceilf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64x __ceilf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x fabsf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64x __fabsf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x floorf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64x __floorf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x fmodf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __fmodf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x copysignf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __copysignf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x nanf64x(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __nanf64x(const char *__tagb) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x j0f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __j0f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x j1f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __j1f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x jnf64x(int, _Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __jnf64x(int, _Float64x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x y0f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __y0f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x y1f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __y1f64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x ynf64x(int, _Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __ynf64x(int, _Float64x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x erff64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __erff64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x erfcf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __erfcf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x lgammaf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __lgammaf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); + +extern _Float64x tgammaf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __tgammaf64x(_Float64x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x lgammaf64x_r(_Float64x, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __lgammaf64x_r(_Float64x, int *__signgamp) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x rintf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern _Float64x __rintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x nextafterf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __nextafterf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x nextdownf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __nextdownf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x nextupf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __nextupf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x remainderf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __remainderf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x scalbnf64x(_Float64x __x, int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __scalbnf64x(_Float64x __x, int __n) + __attribute__((__nothrow__, __leaf__)); + +extern int ilogbf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern int __ilogbf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); + +extern long int llogbf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern long int __llogbf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x scalblnf64x(_Float64x __x, long int __n) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __scalblnf64x(_Float64x __x, long int __n) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x nearbyintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __nearbyintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x roundf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64x __roundf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x truncf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern _Float64x __truncf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x remquof64x(_Float64x __x, _Float64x __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __remquof64x(_Float64x __x, _Float64x __y, int *__quo) + __attribute__((__nothrow__, __leaf__)); + +extern long int lrintf64x(_Float64x __x) __attribute__((__nothrow__, __leaf__)); +extern long int __lrintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llrintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llrintf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern long int lroundf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern long int __lroundf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +__extension__ extern long long int llroundf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); +extern long long int __llroundf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x fdimf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __fdimf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x fmaxf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __fmaxf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x fminf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __fminf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x fmaf64x(_Float64x __x, _Float64x __y, _Float64x __z) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __fmaf64x(_Float64x __x, _Float64x __y, _Float64x __z) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x roundevenf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __roundevenf64x(_Float64x __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern __intmax_t fromfpf64x(_Float64x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpf64x(_Float64x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpf64x(_Float64x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpf64x(_Float64x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __intmax_t fromfpxf64x(_Float64x __x, int __round, unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __intmax_t __fromfpxf64x(_Float64x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern __uintmax_t ufromfpxf64x(_Float64x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); +extern __uintmax_t __ufromfpxf64x(_Float64x __x, int __round, + unsigned int __width) + __attribute__((__nothrow__, __leaf__)); + +extern _Float64x fmaxmagf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __fmaxmagf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern _Float64x fminmagf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern _Float64x __fminmagf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); + +extern int canonicalizef64x(_Float64x *__cx, const _Float64x *__x) + __attribute__((__nothrow__, __leaf__)); + +extern int totalorderf64x(const _Float64x *__x, const _Float64x *__y) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__pure__)); -typedef struct __pthread_internal_list -{ - struct __pthread_internal_list *__prev; - struct __pthread_internal_list *__next; -} __pthread_list_t; +extern int totalordermagf64x(const _Float64x *__x, const _Float64x *__y) + __attribute__((__nothrow__, __leaf__)) -typedef struct __pthread_internal_slist -{ - struct __pthread_internal_slist *__next; -} __pthread_slist_t; -struct __pthread_mutex_s -{ - int __lock; - unsigned int __count; - int __owner; + __attribute__((__pure__)); - unsigned int __nusers; +extern _Float64x getpayloadf64x(const _Float64x *__x) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x __getpayloadf64x(const _Float64x *__x) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadf64x(_Float64x *__x, _Float64x __payload) + __attribute__((__nothrow__, __leaf__)); +extern int setpayloadsigf64x(_Float64x *__x, _Float64x __payload) + __attribute__((__nothrow__, __leaf__)); +extern float fadd(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); - int __kind; +extern float fdiv(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); - short __spins; - short __elision; - __pthread_list_t __list; -}; -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; +extern float fmul(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); - int __cur_writer; - int __shared; - signed char __rwelision; +extern float fsub(double __x, double __y) + __attribute__((__nothrow__, __leaf__)); +extern float faddl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern float fdivl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern float fmull(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern float fsubl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern double daddl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); - unsigned char __pad1[7]; +extern double ddivl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern double dmull(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); - unsigned long int __pad2; +extern double dsubl(long double __x, long double __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32addf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32divf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); - unsigned int __flags; -}; +extern _Float32 f32mulf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32subf32x(_Float32x __x, _Float32x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32addf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32divf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32mulf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); -struct __pthread_cond_s -{ - __extension__ union - { - __extension__ unsigned long long int __wseq; - struct - { - unsigned int __low; - unsigned int __high; - } __wseq32; - }; - __extension__ union - { - __extension__ unsigned long long int __g1_start; - struct - { - unsigned int __low; - unsigned int __high; - } __g1_start32; - }; - unsigned int __g_refs[2] ; - unsigned int __g_size[2]; - unsigned int __g1_orig_size; - unsigned int __wrefs; - unsigned int __g_signals[2]; -}; +extern _Float32 f32subf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32addf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32divf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32mulf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); -typedef unsigned long int pthread_t; +extern _Float32 f32subf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32addf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32divf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32mulf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32 f32subf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xaddf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); -typedef union -{ - char __size[4]; - int __align; -} pthread_mutexattr_t; +extern _Float32x f32xdivf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xmulf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xsubf64(_Float64 __x, _Float64 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xaddf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xdivf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); -typedef union -{ - char __size[4]; - int __align; -} pthread_condattr_t; +extern _Float32x f32xmulf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xsubf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xaddf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xdivf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); -typedef unsigned int pthread_key_t; +extern _Float32x f32xmulf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float32x f32xsubf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 f64addf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 f64divf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); -typedef int pthread_once_t; +extern _Float64 f64mulf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 f64subf64x(_Float64x __x, _Float64x __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 f64addf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); -union pthread_attr_t -{ - char __size[56]; - long int __align; -}; +extern _Float64 f64divf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); -typedef union pthread_attr_t pthread_attr_t; +extern _Float64 f64mulf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64 f64subf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x f64xaddf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x f64xdivf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern _Float64x f64xmulf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); -typedef union -{ - struct __pthread_mutex_s __data; - char __size[40]; - long int __align; -} pthread_mutex_t; +extern _Float64x f64xsubf128(_Float128 __x, _Float128 __y) + __attribute__((__nothrow__, __leaf__)); +extern int signgam; +enum { + FP_NAN = + 0, + FP_INFINITE = -typedef union -{ - struct __pthread_cond_s __data; - char __size[48]; - __extension__ long long int __align; -} pthread_cond_t; + 1, + FP_ZERO = + 2, + FP_SUBNORMAL = + 3, + FP_NORMAL = + 4 +}; +extern int __iscanonicall(long double __x) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +struct timex { + unsigned int modes; + __syscall_slong_t offset; + __syscall_slong_t freq; + __syscall_slong_t maxerror; + __syscall_slong_t esterror; + int status; + __syscall_slong_t constant; + __syscall_slong_t precision; + __syscall_slong_t tolerance; + struct timeval time; + __syscall_slong_t tick; + __syscall_slong_t ppsfreq; + __syscall_slong_t jitter; + int shift; + __syscall_slong_t stabil; + __syscall_slong_t jitcnt; + __syscall_slong_t calcnt; + __syscall_slong_t errcnt; + __syscall_slong_t stbcnt; -typedef union -{ - struct __pthread_rwlock_arch_t __data; - char __size[56]; - long int __align; -} pthread_rwlock_t; + int tai; -typedef union -{ - char __size[8]; - long int __align; -} pthread_rwlockattr_t; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; + int : 32; +}; +extern int clock_adjtime(__clockid_t __clock_id, struct timex *__utx) + __attribute__((__nothrow__, __leaf__)); +struct tm { + int tm_sec; + int tm_min; + int tm_hour; + int tm_mday; + int tm_mon; + int tm_year; + int tm_wday; + int tm_yday; + int tm_isdst; + long int tm_gmtoff; + const char *tm_zone; +}; +struct itimerspec { + struct timespec it_interval; + struct timespec it_value; +}; +struct sigevent; -typedef volatile int pthread_spinlock_t; +extern clock_t clock(void) __attribute__((__nothrow__, __leaf__)); +extern time_t time(time_t *__timer) __attribute__((__nothrow__, __leaf__)); +extern double difftime(time_t __time1, time_t __time0) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern time_t mktime(struct tm *__tp) __attribute__((__nothrow__, __leaf__)); -typedef union -{ - char __size[32]; - long int __align; -} pthread_barrier_t; +extern size_t strftime(char *__restrict __s, size_t __maxsize, + const char *__restrict __format, + const struct tm *__restrict __tp) + __attribute__((__nothrow__, __leaf__)); -typedef union -{ - char __size[4]; - int __align; -} pthread_barrierattr_t; +extern char *strptime(const char *__restrict __s, const char *__restrict __fmt, + struct tm *__tp) __attribute__((__nothrow__, __leaf__)); +extern size_t strftime_l(char *__restrict __s, size_t __maxsize, + const char *__restrict __format, + const struct tm *__restrict __tp, locale_t __loc) + __attribute__((__nothrow__, __leaf__)); +extern char *strptime_l(const char *__restrict __s, + const char *__restrict __fmt, struct tm *__tp, + locale_t __loc) __attribute__((__nothrow__, __leaf__)); +extern struct tm *gmtime(const time_t *__timer) + __attribute__((__nothrow__, __leaf__)); +extern struct tm *localtime(const time_t *__timer) + __attribute__((__nothrow__, __leaf__)); +extern struct tm *gmtime_r(const time_t *__restrict __timer, + struct tm *__restrict __tp) + __attribute__((__nothrow__, __leaf__)); +extern struct tm *localtime_r(const time_t *__restrict __timer, + struct tm *__restrict __tp) + __attribute__((__nothrow__, __leaf__)); +extern char *asctime(const struct tm *__tp) + __attribute__((__nothrow__, __leaf__)); +extern char *ctime(const time_t *__timer) + __attribute__((__nothrow__, __leaf__)); -extern long int random (void) __attribute__ ((__nothrow__ , __leaf__)); +extern char *asctime_r(const struct tm *__restrict __tp, char *__restrict __buf) + __attribute__((__nothrow__, __leaf__)); +extern char *ctime_r(const time_t *__restrict __timer, char *__restrict __buf) + __attribute__((__nothrow__, __leaf__)); -extern void srandom (unsigned int __seed) __attribute__ ((__nothrow__ , __leaf__)); +extern char *__tzname[2]; +extern int __daylight; +extern long int __timezone; +extern char *tzname[2]; +extern void tzset(void) __attribute__((__nothrow__, __leaf__)); +extern int daylight; +extern long int timezone; +extern time_t timegm(struct tm *__tp) __attribute__((__nothrow__, __leaf__)); +extern time_t timelocal(struct tm *__tp) __attribute__((__nothrow__, __leaf__)); -extern char *initstate (unsigned int __seed, char *__statebuf, - size_t __statelen) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); +extern int dysize(int __year) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int nanosleep(const struct timespec *__requested_time, + struct timespec *__remaining); +extern int clock_getres(clockid_t __clock_id, struct timespec *__res) + __attribute__((__nothrow__, __leaf__)); +extern int clock_gettime(clockid_t __clock_id, struct timespec *__tp) + __attribute__((__nothrow__, __leaf__)); -extern char *setstate (char *__statebuf) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int clock_settime(clockid_t __clock_id, const struct timespec *__tp) + __attribute__((__nothrow__, __leaf__)); +extern int clock_nanosleep(clockid_t __clock_id, int __flags, + const struct timespec *__req, + struct timespec *__rem); +extern int clock_getcpuclockid(pid_t __pid, clockid_t *__clock_id) + __attribute__((__nothrow__, __leaf__)); +extern int timer_create(clockid_t __clock_id, struct sigevent *__restrict __evp, + timer_t *__restrict __timerid) + __attribute__((__nothrow__, __leaf__)); +extern int timer_delete(timer_t __timerid) + __attribute__((__nothrow__, __leaf__)); +extern int timer_settime(timer_t __timerid, int __flags, + const struct itimerspec *__restrict __value, + struct itimerspec *__restrict __ovalue) + __attribute__((__nothrow__, __leaf__)); +extern int timer_gettime(timer_t __timerid, struct itimerspec *__value) + __attribute__((__nothrow__, __leaf__)); -struct random_data - { - int32_t *fptr; - int32_t *rptr; - int32_t *state; - int rand_type; - int rand_deg; - int rand_sep; - int32_t *end_ptr; - }; +extern int timer_getoverrun(timer_t __timerid) + __attribute__((__nothrow__, __leaf__)); -extern int random_r (struct random_data *__restrict __buf, - int32_t *__restrict __result) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int timespec_get(struct timespec *__ts, int __base) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int getdate_err; +extern struct tm *getdate(const char *__string); +extern int getdate_r(const char *__restrict __string, + struct tm *__restrict __resbufp); -extern int srandom_r (unsigned int __seed, struct random_data *__buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); +typedef __sig_atomic_t sig_atomic_t; -extern int initstate_r (unsigned int __seed, char *__restrict __statebuf, - size_t __statelen, - struct random_data *__restrict __buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))); +union sigval { + int sival_int; + void *sival_ptr; +}; -extern int setstate_r (char *__restrict __statebuf, - struct random_data *__restrict __buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +typedef union sigval __sigval_t; +typedef struct { + int si_signo; + + int si_errno; + + int si_code; + + int __pad0; + + union { + int _pad[((128 / sizeof(int)) - 4)]; + + struct { + __pid_t si_pid; + __uid_t si_uid; + } _kill; + + struct { + int si_tid; + int si_overrun; + __sigval_t si_sigval; + } _timer; + + struct { + __pid_t si_pid; + __uid_t si_uid; + __sigval_t si_sigval; + } _rt; + + struct { + __pid_t si_pid; + __uid_t si_uid; + int si_status; + __clock_t si_utime; + __clock_t si_stime; + } _sigchld; + + struct { + void *si_addr; + + short int si_addr_lsb; + union { + + struct { + void *_lower; + void *_upper; + } _addr_bnd; + + __uint32_t _pkey; + } _bounds; + } _sigfault; + + struct { + long int si_band; + int si_fd; + } _sigpoll; + + struct { + void *_call_addr; + int _syscall; + unsigned int _arch; + } _sigsys; + + } _sifields; +} siginfo_t; +enum { + SI_ASYNCNL = -60, + SI_DETHREAD = -7, + SI_TKILL, + SI_SIGIO, + SI_ASYNCIO, + SI_MESGQ, + SI_TIMER, + SI_QUEUE, + SI_USER, + SI_KERNEL = 0x80 +}; +enum { + ILL_ILLOPC = 1, -extern int rand (void) __attribute__ ((__nothrow__ , __leaf__)); + ILL_ILLOPN, -extern void srand (unsigned int __seed) __attribute__ ((__nothrow__ , __leaf__)); + ILL_ILLADR, + ILL_ILLTRP, + ILL_PRVOPC, -extern int rand_r (unsigned int *__seed) __attribute__ ((__nothrow__ , __leaf__)); + ILL_PRVREG, + ILL_COPROC, + ILL_BADSTK, + ILL_BADIADDR +}; +enum { + FPE_INTDIV = 1, + FPE_INTOVF, -extern double drand48 (void) __attribute__ ((__nothrow__ , __leaf__)); -extern double erand48 (unsigned short int __xsubi[3]) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + FPE_FLTDIV, + FPE_FLTOVF, -extern long int lrand48 (void) __attribute__ ((__nothrow__ , __leaf__)); -extern long int nrand48 (unsigned short int __xsubi[3]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + FPE_FLTUND, + FPE_FLTRES, -extern long int mrand48 (void) __attribute__ ((__nothrow__ , __leaf__)); -extern long int jrand48 (unsigned short int __xsubi[3]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern void srand48 (long int __seedval) __attribute__ ((__nothrow__ , __leaf__)); -extern unsigned short int *seed48 (unsigned short int __seed16v[3]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern void lcong48 (unsigned short int __param[7]) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - -struct drand48_data - { - unsigned short int __x[3]; - unsigned short int __old_x[3]; - unsigned short int __c; - unsigned short int __init; - __extension__ unsigned long long int __a; - - }; - + FPE_FLTINV, -extern int drand48_r (struct drand48_data *__restrict __buffer, - double *__restrict __result) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern int erand48_r (unsigned short int __xsubi[3], - struct drand48_data *__restrict __buffer, - double *__restrict __result) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + FPE_FLTSUB, + FPE_FLTUNK = 14, -extern int lrand48_r (struct drand48_data *__restrict __buffer, - long int *__restrict __result) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern int nrand48_r (unsigned short int __xsubi[3], - struct drand48_data *__restrict __buffer, - long int *__restrict __result) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + FPE_CONDTRAP +}; -extern int mrand48_r (struct drand48_data *__restrict __buffer, - long int *__restrict __result) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern int jrand48_r (unsigned short int __xsubi[3], - struct drand48_data *__restrict __buffer, - long int *__restrict __result) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +enum { + SEGV_MAPERR = 1, + SEGV_ACCERR, -extern int srand48_r (long int __seedval, struct drand48_data *__buffer) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + SEGV_BNDERR, -extern int seed48_r (unsigned short int __seed16v[3], - struct drand48_data *__buffer) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + SEGV_PKUERR, -extern int lcong48_r (unsigned short int __param[7], - struct drand48_data *__buffer) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + SEGV_ACCADI, + SEGV_ADIDERR, + SEGV_ADIPERR +}; -extern void *malloc (size_t __size) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) - __attribute__ ((__alloc_size__ (1))) ; +enum { + BUS_ADRALN = 1, -extern void *calloc (size_t __nmemb, size_t __size) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) __attribute__ ((__alloc_size__ (1, 2))) ; + BUS_ADRERR, + BUS_OBJERR, + BUS_MCEERR_AR, + BUS_MCEERR_AO +}; +enum { + TRAP_BRKPT = 1, -extern void *realloc (void *__ptr, size_t __size) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__warn_unused_result__)) __attribute__ ((__alloc_size__ (2))); + TRAP_TRACE, + TRAP_BRANCH, + TRAP_HWBKPT, + TRAP_UNK +}; +enum { + CLD_EXITED = 1, + CLD_KILLED, -extern void *reallocarray (void *__ptr, size_t __nmemb, size_t __size) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__warn_unused_result__)) - __attribute__ ((__alloc_size__ (2, 3))); + CLD_DUMPED, + CLD_TRAPPED, + CLD_STOPPED, -extern void free (void *__ptr) __attribute__ ((__nothrow__ , __leaf__)); + CLD_CONTINUED +}; +enum { + POLL_IN = 1, + POLL_OUT, + POLL_MSG, + POLL_ERR, + POLL_PRI, + POLL_HUP +}; -extern void *alloca (size_t __size) __attribute__ ((__nothrow__ , __leaf__)); +typedef __sigval_t sigval_t; +typedef struct sigevent { + __sigval_t sigev_value; + int sigev_signo; + int sigev_notify; + union { + int _pad[((64 / sizeof(int)) - 4)]; + __pid_t _tid; + struct { + void (*_function)(__sigval_t); + pthread_attr_t *_attribute; + } _sigev_thread; + } _sigev_un; +} sigevent_t; +enum { + SIGEV_SIGNAL = 0, + SIGEV_NONE, + SIGEV_THREAD, + SIGEV_THREAD_ID = 4 +}; +typedef void (*__sighandler_t)(int); +extern __sighandler_t __sysv_signal(int __sig, __sighandler_t __handler) + __attribute__((__nothrow__, __leaf__)); -extern void *valloc (size_t __size) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) - __attribute__ ((__alloc_size__ (1))) ; +extern __sighandler_t sysv_signal(int __sig, __sighandler_t __handler) + __attribute__((__nothrow__, __leaf__)); +extern __sighandler_t signal(int __sig, __sighandler_t __handler) + __attribute__((__nothrow__, __leaf__)); +extern int kill(__pid_t __pid, int __sig) + __attribute__((__nothrow__, __leaf__)); +extern int killpg(__pid_t __pgrp, int __sig) + __attribute__((__nothrow__, __leaf__)); +extern int raise(int __sig) __attribute__((__nothrow__, __leaf__)); -extern int posix_memalign (void **__memptr, size_t __alignment, size_t __size) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; +extern __sighandler_t ssignal(int __sig, __sighandler_t __handler) + __attribute__((__nothrow__, __leaf__)); +extern int gsignal(int __sig) __attribute__((__nothrow__, __leaf__)); +extern void psignal(int __sig, const char *__s); +extern void psiginfo(const siginfo_t *__pinfo, const char *__s); +extern int sigpause(int __sig) __asm__("__xpg_sigpause"); +extern int sigblock(int __mask) __attribute__((__nothrow__, __leaf__)) +__attribute__((__deprecated__)); +extern int sigsetmask(int __mask) __attribute__((__nothrow__, __leaf__)) +__attribute__((__deprecated__)); -extern void *aligned_alloc (size_t __alignment, size_t __size) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) __attribute__ ((__alloc_size__ (2))) ; +extern int siggetmask(void) __attribute__((__nothrow__, __leaf__)) +__attribute__((__deprecated__)); +typedef __sighandler_t sighandler_t; +typedef __sighandler_t sig_t; +extern int sigemptyset(sigset_t *__set) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); -extern void abort (void) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); +extern int sigfillset(sigset_t *__set) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int sigaddset(sigset_t *__set, int __signo) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int sigdelset(sigset_t *__set, int __signo) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern int atexit (void (*__func) (void)) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int sigismember(const sigset_t *__set, int __signo) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int sigisemptyset(const sigset_t *__set) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int sigandset(sigset_t *__set, const sigset_t *__left, + const sigset_t *__right) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(1, 2, 3))); +extern int sigorset(sigset_t *__set, const sigset_t *__left, + const sigset_t *__right) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(1, 2, 3))); +struct sigaction { + union { + __sighandler_t sa_handler; -extern int at_quick_exit (void (*__func) (void)) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + void (*sa_sigaction)(int, siginfo_t *, void *); + } __sigaction_handler; + __sigset_t sa_mask; + int sa_flags; + void (*sa_restorer)(void); +}; +extern int sigprocmask(int __how, const sigset_t *__restrict __set, + sigset_t *__restrict __oset) + __attribute__((__nothrow__, __leaf__)); +extern int sigsuspend(const sigset_t *__set) __attribute__((__nonnull__(1))); -extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int sigaction(int __sig, const struct sigaction *__restrict __act, + struct sigaction *__restrict __oact) + __attribute__((__nothrow__, __leaf__)); +extern int sigpending(sigset_t *__set) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int sigwait(const sigset_t *__restrict __set, int *__restrict __sig) + __attribute__((__nonnull__(1, 2))); +extern int sigwaitinfo(const sigset_t *__restrict __set, + siginfo_t *__restrict __info) + __attribute__((__nonnull__(1))); +extern int sigtimedwait(const sigset_t *__restrict __set, + siginfo_t *__restrict __info, + const struct timespec *__restrict __timeout) + __attribute__((__nonnull__(1))); -extern void exit (int __status) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); +extern int sigqueue(__pid_t __pid, int __sig, const union sigval __val) + __attribute__((__nothrow__, __leaf__)); +extern const char *const _sys_siglist[(64 + 1)]; +extern const char *const sys_siglist[(64 + 1)]; +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]; +}; +struct _fpstate { -extern void quick_exit (int __status) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); + __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]; +}; +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; +}; -extern void _Exit (int __status) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); +extern int sigreturn(struct sigcontext *__scp) + __attribute__((__nothrow__, __leaf__)); +typedef struct { + void *ss_sp; + int ss_flags; + size_t ss_size; +} stack_t; +__extension__ typedef long long int greg_t; +typedef greg_t gregset_t[23]; +enum { + REG_R8 = 0, -extern char *getenv (const char *__name) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; + REG_R9, + REG_R10, + REG_R11, + REG_R12, -extern char *secure_getenv (const char *__name) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; + REG_R13, + REG_R14, + REG_R15, + REG_RDI, + REG_RSI, + REG_RBP, -extern int putenv (char *__string) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + REG_RBX, + REG_RDX, + REG_RAX, + REG_RCX, + REG_RSP, -extern int setenv (const char *__name, const char *__value, int __replace) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); + REG_RIP, + REG_EFL, -extern int unsetenv (const char *__name) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + REG_CSGSFS, + REG_ERR, + REG_TRAPNO, + REG_OLDMASK, + REG_CR2 +}; -extern int clearenv (void) __attribute__ ((__nothrow__ , __leaf__)); -extern char *mktemp (char *__template) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int mkstemp (char *__template) __attribute__ ((__nonnull__ (1))) ; -extern int mkstemp64 (char *__template) __attribute__ ((__nonnull__ (1))) ; -extern int mkstemps (char *__template, int __suffixlen) __attribute__ ((__nonnull__ (1))) ; -extern int mkstemps64 (char *__template, int __suffixlen) - __attribute__ ((__nonnull__ (1))) ; -extern char *mkdtemp (char *__template) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern int mkostemp (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ; -extern int mkostemp64 (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ; -extern int mkostemps (char *__template, int __suffixlen, int __flags) - __attribute__ ((__nonnull__ (1))) ; -extern int mkostemps64 (char *__template, int __suffixlen, int __flags) - __attribute__ ((__nonnull__ (1))) ; -extern int system (const char *__command) ; +struct _libc_fpxreg { + unsigned short int significand[4]; + unsigned short int exponent; + unsigned short int __glibc_reserved1[3]; +}; +struct _libc_xmmreg { + __uint32_t element[4]; +}; +struct _libc_fpstate { + __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 _libc_fpxreg _st[8]; + struct _libc_xmmreg _xmm[16]; + __uint32_t __glibc_reserved1[24]; +}; +typedef struct _libc_fpstate *fpregset_t; -extern char *canonicalize_file_name (const char *__name) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern char *realpath (const char *__restrict __name, - char *__restrict __resolved) __attribute__ ((__nothrow__ , __leaf__)) ; +typedef struct { + gregset_t gregs; + fpregset_t fpregs; + __extension__ unsigned long long __reserved1[8]; +} mcontext_t; +typedef struct ucontext_t { + unsigned long int uc_flags; + struct ucontext_t *uc_link; + stack_t uc_stack; + mcontext_t uc_mcontext; + sigset_t uc_sigmask; + struct _libc_fpstate __fpregs_mem; + __extension__ unsigned long long int __ssp[4]; +} ucontext_t; +extern int siginterrupt(int __sig, int __interrupt) + __attribute__((__nothrow__, __leaf__)); +enum { + SS_ONSTACK = 1, + SS_DISABLE -typedef int (*__compar_fn_t) (const void *, const void *); +}; +extern int sigaltstack(const stack_t *__restrict __ss, + stack_t *__restrict __oss) + __attribute__((__nothrow__, __leaf__)); -typedef __compar_fn_t comparison_fn_t; +struct sigstack { + void *ss_sp; + int ss_onstack; +}; +extern int sigstack(struct sigstack *__ss, struct sigstack *__oss) + __attribute__((__nothrow__, __leaf__)) __attribute__((__deprecated__)); +extern int sighold(int __sig) __attribute__((__nothrow__, __leaf__)); -typedef int (*__compar_d_fn_t) (const void *, const void *, void *); +extern int sigrelse(int __sig) __attribute__((__nothrow__, __leaf__)); +extern int sigignore(int __sig) __attribute__((__nothrow__, __leaf__)); +extern __sighandler_t sigset(int __sig, __sighandler_t __disp) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_sigmask(int __how, const __sigset_t *__restrict __newmask, + __sigset_t *__restrict __oldmask) + __attribute__((__nothrow__, __leaf__)); -extern void *bsearch (const void *__key, const void *__base, - size_t __nmemb, size_t __size, __compar_fn_t __compar) - __attribute__ ((__nonnull__ (1, 2, 5))) ; +extern int pthread_kill(pthread_t __threadid, int __signo) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_sigqueue(pthread_t __threadid, int __signo, + const union sigval __value) + __attribute__((__nothrow__, __leaf__)); +extern int __libc_current_sigrtmin(void) __attribute__((__nothrow__, __leaf__)); +extern int __libc_current_sigrtmax(void) __attribute__((__nothrow__, __leaf__)); +extern int tgkill(__pid_t __tgid, __pid_t __tid, int __signal); +extern void __assert_fail(const char *__assertion, const char *__file, + unsigned int __line, const char *__function) + __attribute__((__nothrow__, __leaf__)) __attribute__((__noreturn__)); +extern void __assert_perror_fail(int __errnum, const char *__file, + unsigned int __line, const char *__function) + __attribute__((__nothrow__, __leaf__)) __attribute__((__noreturn__)); -extern void qsort (void *__base, size_t __nmemb, size_t __size, - __compar_fn_t __compar) __attribute__ ((__nonnull__ (1, 4))); +extern void __assert(const char *__assertion, const char *__file, int __line) + __attribute__((__nothrow__, __leaf__)) __attribute__((__noreturn__)); -extern void qsort_r (void *__base, size_t __nmemb, size_t __size, - __compar_d_fn_t __compar, void *__arg) - __attribute__ ((__nonnull__ (1, 4))); +struct sched_param { + int sched_priority; +}; +extern int clone(int (*__fn)(void *__arg), void *__child_stack, int __flags, + void *__arg, ...) __attribute__((__nothrow__, __leaf__)); +extern int unshare(int __flags) __attribute__((__nothrow__, __leaf__)); +extern int sched_getcpu(void) __attribute__((__nothrow__, __leaf__)); -extern int abs (int __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; -extern long int labs (long int __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; +extern int getcpu(unsigned int *, unsigned int *) + __attribute__((__nothrow__, __leaf__)); +extern int setns(int __fd, int __nstype) __attribute__((__nothrow__, __leaf__)); -__extension__ extern long long int llabs (long long int __x) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; +typedef unsigned long int __cpu_mask; +typedef struct { + __cpu_mask __bits[1024 / (8 * sizeof(__cpu_mask))]; +} cpu_set_t; +extern int __sched_cpucount(size_t __setsize, const cpu_set_t *__setp) + __attribute__((__nothrow__, __leaf__)); +extern cpu_set_t *__sched_cpualloc(size_t __count) + __attribute__((__nothrow__, __leaf__)); +extern void __sched_cpufree(cpu_set_t *__set) + __attribute__((__nothrow__, __leaf__)); +extern int sched_setparam(__pid_t __pid, const struct sched_param *__param) + __attribute__((__nothrow__, __leaf__)); +extern int sched_getparam(__pid_t __pid, struct sched_param *__param) + __attribute__((__nothrow__, __leaf__)); +extern int sched_setscheduler(__pid_t __pid, int __policy, + const struct sched_param *__param) + __attribute__((__nothrow__, __leaf__)); -extern div_t div (int __numer, int __denom) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; -extern ldiv_t ldiv (long int __numer, long int __denom) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; +extern int sched_getscheduler(__pid_t __pid) + __attribute__((__nothrow__, __leaf__)); +extern int sched_yield(void) __attribute__((__nothrow__, __leaf__)); -__extension__ extern lldiv_t lldiv (long long int __numer, - long long int __denom) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)) ; -extern char *ecvt (double __value, int __ndigit, int *__restrict __decpt, - int *__restrict __sign) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))) ; +extern int sched_get_priority_max(int __algorithm) + __attribute__((__nothrow__, __leaf__)); +extern int sched_get_priority_min(int __algorithm) + __attribute__((__nothrow__, __leaf__)); +extern int sched_rr_get_interval(__pid_t __pid, struct timespec *__t) + __attribute__((__nothrow__, __leaf__)); +extern int sched_setaffinity(__pid_t __pid, size_t __cpusetsize, + const cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)); +extern int sched_getaffinity(__pid_t __pid, size_t __cpusetsize, + cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)); -extern char *fcvt (double __value, int __ndigit, int *__restrict __decpt, - int *__restrict __sign) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))) ; +typedef long int __jmp_buf[8]; +enum { + PTHREAD_CREATE_JOINABLE, + PTHREAD_CREATE_DETACHED +}; -extern char *gcvt (double __value, int __ndigit, char *__buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))) ; +enum { + PTHREAD_MUTEX_TIMED_NP, + PTHREAD_MUTEX_RECURSIVE_NP, + PTHREAD_MUTEX_ERRORCHECK_NP, + PTHREAD_MUTEX_ADAPTIVE_NP + , + PTHREAD_MUTEX_NORMAL = PTHREAD_MUTEX_TIMED_NP, + PTHREAD_MUTEX_RECURSIVE = PTHREAD_MUTEX_RECURSIVE_NP, + PTHREAD_MUTEX_ERRORCHECK = PTHREAD_MUTEX_ERRORCHECK_NP, + PTHREAD_MUTEX_DEFAULT = PTHREAD_MUTEX_NORMAL + , + PTHREAD_MUTEX_FAST_NP = PTHREAD_MUTEX_TIMED_NP +}; -extern char *qecvt (long double __value, int __ndigit, - int *__restrict __decpt, int *__restrict __sign) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))) ; -extern char *qfcvt (long double __value, int __ndigit, - int *__restrict __decpt, int *__restrict __sign) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4))) ; -extern char *qgcvt (long double __value, int __ndigit, char *__buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))) ; +enum { + PTHREAD_MUTEX_STALLED, + PTHREAD_MUTEX_STALLED_NP = PTHREAD_MUTEX_STALLED, + PTHREAD_MUTEX_ROBUST, + PTHREAD_MUTEX_ROBUST_NP = PTHREAD_MUTEX_ROBUST +}; +enum { PTHREAD_PRIO_NONE, PTHREAD_PRIO_INHERIT, PTHREAD_PRIO_PROTECT }; +enum { + PTHREAD_RWLOCK_PREFER_READER_NP, + PTHREAD_RWLOCK_PREFER_WRITER_NP, + PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP, + PTHREAD_RWLOCK_DEFAULT_NP = PTHREAD_RWLOCK_PREFER_READER_NP +}; +enum { + PTHREAD_INHERIT_SCHED, + PTHREAD_EXPLICIT_SCHED +}; -extern int ecvt_r (double __value, int __ndigit, int *__restrict __decpt, - int *__restrict __sign, char *__restrict __buf, - size_t __len) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4, 5))); -extern int fcvt_r (double __value, int __ndigit, int *__restrict __decpt, - int *__restrict __sign, char *__restrict __buf, - size_t __len) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4, 5))); +enum { + PTHREAD_SCOPE_SYSTEM, -extern int qecvt_r (long double __value, int __ndigit, - int *__restrict __decpt, int *__restrict __sign, - char *__restrict __buf, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4, 5))); -extern int qfcvt_r (long double __value, int __ndigit, - int *__restrict __decpt, int *__restrict __sign, - char *__restrict __buf, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3, 4, 5))); + PTHREAD_SCOPE_PROCESS +}; +enum { + PTHREAD_PROCESS_PRIVATE, + PTHREAD_PROCESS_SHARED +}; +struct _pthread_cleanup_buffer { + void (*__routine)(void *); + void *__arg; + int __canceltype; + struct _pthread_cleanup_buffer *__prev; +}; -extern int mblen (const char *__s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)); +enum { + PTHREAD_CANCEL_ENABLE, + PTHREAD_CANCEL_DISABLE -extern int mbtowc (wchar_t *__restrict __pwc, - const char *__restrict __s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)); +}; +enum { + PTHREAD_CANCEL_DEFERRED, + PTHREAD_CANCEL_ASYNCHRONOUS -extern int wctomb (char *__s, wchar_t __wchar) __attribute__ ((__nothrow__ , __leaf__)); +}; +extern int pthread_create(pthread_t *__restrict __newthread, + const pthread_attr_t *__restrict __attr, + void *(*__start_routine)(void *), + void *__restrict __arg) __attribute__((__nothrow__)) +__attribute__((__nonnull__(1, 3))); +extern void pthread_exit(void *__retval) __attribute__((__noreturn__)); -extern size_t mbstowcs (wchar_t *__restrict __pwcs, - const char *__restrict __s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)); +extern int pthread_join(pthread_t __th, void **__thread_return); -extern size_t wcstombs (char *__restrict __s, - const wchar_t *__restrict __pwcs, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)); +extern int pthread_tryjoin_np(pthread_t __th, void **__thread_return) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_timedjoin_np(pthread_t __th, void **__thread_return, + const struct timespec *__abstime); +extern int pthread_clockjoin_np(pthread_t __th, void **__thread_return, + clockid_t __clockid, + const struct timespec *__abstime); +extern int pthread_detach(pthread_t __th) + __attribute__((__nothrow__, __leaf__)); +extern pthread_t pthread_self(void) __attribute__((__nothrow__, __leaf__)) +__attribute__((__const__)); +extern int pthread_equal(pthread_t __thread1, pthread_t __thread2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__const__)); +extern int pthread_attr_init(pthread_attr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_destroy(pthread_attr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern int rpmatch (const char *__response) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern int getsubopt (char **__restrict __optionp, - char *const *__restrict __tokens, - char **__restrict __valuep) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2, 3))) ; +extern int pthread_attr_getdetachstate(const pthread_attr_t *__attr, + int *__detachstate) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_setdetachstate(pthread_attr_t *__attr, + int __detachstate) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getguardsize(const pthread_attr_t *__attr, + size_t *__guardsize) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_setguardsize(pthread_attr_t *__attr, size_t __guardsize) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getschedparam(const pthread_attr_t *__restrict __attr, + struct sched_param *__restrict __param) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int +pthread_attr_setschedparam(pthread_attr_t *__restrict __attr, + const struct sched_param *__restrict __param) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_getschedpolicy(const pthread_attr_t *__restrict __attr, + int *__restrict __policy) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern int posix_openpt (int __oflag) ; +extern int pthread_attr_setschedpolicy(pthread_attr_t *__attr, int __policy) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getinheritsched(const pthread_attr_t *__restrict __attr, + int *__restrict __inherit) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_setinheritsched(pthread_attr_t *__attr, int __inherit) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getscope(const pthread_attr_t *__restrict __attr, + int *__restrict __scope) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_setscope(pthread_attr_t *__attr, int __scope) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getstackaddr(const pthread_attr_t *__restrict __attr, + void **__restrict __stackaddr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))) + __attribute__((__deprecated__)); +extern int pthread_attr_setstackaddr(pthread_attr_t *__attr, void *__stackaddr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))) + __attribute__((__deprecated__)); -extern int grantpt (int __fd) __attribute__ ((__nothrow__ , __leaf__)); +extern int pthread_attr_getstacksize(const pthread_attr_t *__restrict __attr, + size_t *__restrict __stacksize) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_attr_setstacksize(pthread_attr_t *__attr, size_t __stacksize) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_getstack(const pthread_attr_t *__restrict __attr, + void **__restrict __stackaddr, + size_t *__restrict __stacksize) + __attribute__((__nothrow__, __leaf__)) + __attribute__((__nonnull__(1, 2, 3))); -extern int unlockpt (int __fd) __attribute__ ((__nothrow__ , __leaf__)); +extern int pthread_attr_setstack(pthread_attr_t *__attr, void *__stackaddr, + size_t __stacksize) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_attr_setaffinity_np(pthread_attr_t *__attr, + size_t __cpusetsize, + const cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern int pthread_attr_getaffinity_np(const pthread_attr_t *__attr, + size_t __cpusetsize, cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); +extern int pthread_getattr_default_np(pthread_attr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern char *ptsname (int __fd) __attribute__ ((__nothrow__ , __leaf__)) ; +extern int pthread_setattr_default_np(const pthread_attr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_getattr_np(pthread_t __th, pthread_attr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int pthread_setschedparam(pthread_t __target_thread, int __policy, + const struct sched_param *__param) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int pthread_getschedparam(pthread_t __target_thread, + int *__restrict __policy, + struct sched_param *__restrict __param) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 3))); +extern int pthread_setschedprio(pthread_t __target_thread, int __prio) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_getname_np(pthread_t __target_thread, char *__buf, + size_t __buflen) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); -extern int ptsname_r (int __fd, char *__buf, size_t __buflen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); +extern int pthread_setname_np(pthread_t __target_thread, const char *__name) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int pthread_getconcurrency(void) __attribute__((__nothrow__, __leaf__)); -extern int getpt (void); +extern int pthread_setconcurrency(int __level) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_yield(void) __attribute__((__nothrow__, __leaf__)); +extern int pthread_setaffinity_np(pthread_t __th, size_t __cpusetsize, + const cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int pthread_getaffinity_np(pthread_t __th, size_t __cpusetsize, + cpu_set_t *__cpuset) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(3))); +extern int pthread_once(pthread_once_t *__once_control, + void (*__init_routine)(void)) + __attribute__((__nonnull__(1, 2))); +extern int pthread_setcancelstate(int __state, int *__oldstate); +extern int pthread_setcanceltype(int __type, int *__oldtype); +extern int pthread_cancel(pthread_t __th); -extern int getloadavg (double __loadavg[], int __nelem) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern void pthread_testcancel(void); -typedef long int ptrdiff_t; typedef struct { - long long __max_align_ll __attribute__((__aligned__(__alignof__(long long)))); - long double __max_align_ld __attribute__((__aligned__(__alignof__(long double)))); -} max_align_t; - - - + struct { + __jmp_buf __cancel_jmp_buf; + int __mask_was_saved; + } __cancel_jmp_buf[1]; + void *__pad[4]; +} __pthread_unwind_buf_t __attribute__((__aligned__)); +struct __pthread_cleanup_frame { + void (*__cancel_routine)(void *); + void *__cancel_arg; + int __do_it; + int __cancel_type; +}; +extern __inline __attribute__((__gnu_inline__)) void +__pthread_cleanup_routine(struct __pthread_cleanup_frame *__frame) { + if (__frame->__do_it) + __frame->__cancel_routine(__frame->__cancel_arg); +} +struct __jmp_buf_tag; +extern int __sigsetjmp(struct __jmp_buf_tag *__env, int __savemask) + __attribute__((__nothrow__)); +extern int pthread_mutex_init(pthread_mutex_t *__mutex, + const pthread_mutexattr_t *__mutexattr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_mutex_destroy(pthread_mutex_t *__mutex) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern void *memcpy (void *__restrict __dest, const void *__restrict __src, - size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int pthread_mutex_trylock(pthread_mutex_t *__mutex) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); +extern int pthread_mutex_lock(pthread_mutex_t *__mutex) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_mutex_timedlock(pthread_mutex_t *__restrict __mutex, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_mutex_clocklock(pthread_mutex_t *__restrict __mutex, + clockid_t __clockid, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 3))); + +extern int pthread_mutex_unlock(pthread_mutex_t *__mutex) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int +pthread_mutex_getprioceiling(const pthread_mutex_t *__restrict __mutex, + int *__restrict __prioceiling) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_mutex_setprioceiling(pthread_mutex_t *__restrict __mutex, + int __prioceiling, + int *__restrict __old_ceiling) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 3))); + +extern int pthread_mutex_consistent(pthread_mutex_t *__mutex) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_mutex_consistent_np(pthread_mutex_t *__mutex) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_mutexattr_init(pthread_mutexattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern void *memmove (void *__dest, const void *__src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int pthread_mutexattr_destroy(pthread_mutexattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int +pthread_mutexattr_getpshared(const pthread_mutexattr_t *__restrict __attr, + int *__restrict __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_mutexattr_setpshared(pthread_mutexattr_t *__attr, + int __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int +pthread_mutexattr_gettype(const pthread_mutexattr_t *__restrict __attr, + int *__restrict __kind) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_mutexattr_settype(pthread_mutexattr_t *__attr, int __kind) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_mutexattr_getprotocol(const pthread_mutexattr_t *__restrict __attr, + int *__restrict __protocol) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); -extern void *memccpy (void *__restrict __dest, const void *__restrict __src, - int __c, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int pthread_mutexattr_setprotocol(pthread_mutexattr_t *__attr, + int __protocol) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int +pthread_mutexattr_getprioceiling(const pthread_mutexattr_t *__restrict __attr, + int *__restrict __prioceiling) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_mutexattr_setprioceiling(pthread_mutexattr_t *__attr, + int __prioceiling) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_mutexattr_getrobust(const pthread_mutexattr_t *__attr, + int *__robustness) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_mutexattr_getrobust_np(const pthread_mutexattr_t *__attr, + int *__robustness) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_mutexattr_setrobust(pthread_mutexattr_t *__attr, + int __robustness) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_mutexattr_setrobust_np(pthread_mutexattr_t *__attr, + int __robustness) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_rwlock_init(pthread_rwlock_t *__restrict __rwlock, + const pthread_rwlockattr_t *__restrict __attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlock_destroy(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlock_rdlock(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlock_tryrdlock(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int +pthread_rwlock_timedrdlock(pthread_rwlock_t *__restrict __rwlock, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 2))); + +extern int +pthread_rwlock_clockrdlock(pthread_rwlock_t *__restrict __rwlock, + clockid_t __clockid, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 3))); + +extern int pthread_rwlock_wrlock(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlock_trywrlock(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int +pthread_rwlock_timedwrlock(pthread_rwlock_t *__restrict __rwlock, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 2))); + +extern int +pthread_rwlock_clockwrlock(pthread_rwlock_t *__restrict __rwlock, + clockid_t __clockid, + const struct timespec *__restrict __abstime) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1, 3))); + +extern int pthread_rwlock_unlock(pthread_rwlock_t *__rwlock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlockattr_init(pthread_rwlockattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_rwlockattr_destroy(pthread_rwlockattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_rwlockattr_getpshared(const pthread_rwlockattr_t *__restrict __attr, + int *__restrict __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *__attr, + int __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_rwlockattr_getkind_np(const pthread_rwlockattr_t *__restrict __attr, + int *__restrict __pref) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_rwlockattr_setkind_np(pthread_rwlockattr_t *__attr, + int __pref) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_cond_init(pthread_cond_t *__restrict __cond, + const pthread_condattr_t *__restrict __cond_attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_cond_destroy(pthread_cond_t *__cond) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_cond_signal(pthread_cond_t *__cond) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_cond_broadcast(pthread_cond_t *__cond) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_cond_wait(pthread_cond_t *__restrict __cond, + pthread_mutex_t *__restrict __mutex) + __attribute__((__nonnull__(1, 2))); +extern int pthread_cond_timedwait(pthread_cond_t *__restrict __cond, + pthread_mutex_t *__restrict __mutex, + const struct timespec *__restrict __abstime) + __attribute__((__nonnull__(1, 2, 3))); +extern int pthread_cond_clockwait(pthread_cond_t *__restrict __cond, + pthread_mutex_t *__restrict __mutex, + __clockid_t __clock_id, + const struct timespec *__restrict __abstime) + __attribute__((__nonnull__(1, 2, 4))); + +extern int pthread_condattr_init(pthread_condattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_condattr_destroy(pthread_condattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_condattr_getpshared(const pthread_condattr_t *__restrict __attr, + int *__restrict __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_condattr_setpshared(pthread_condattr_t *__attr, + int __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_condattr_getclock(const pthread_condattr_t *__restrict __attr, + __clockid_t *__restrict __clock_id) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); + +extern int pthread_condattr_setclock(pthread_condattr_t *__attr, + __clockid_t __clock_id) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_spin_init(pthread_spinlock_t *__lock, int __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_spin_destroy(pthread_spinlock_t *__lock) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_spin_lock(pthread_spinlock_t *__lock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); -extern void *memset (void *__s, int __c, size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int pthread_spin_trylock(pthread_spinlock_t *__lock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_spin_unlock(pthread_spinlock_t *__lock) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); + +extern int pthread_barrier_init(pthread_barrier_t *__restrict __barrier, + const pthread_barrierattr_t *__restrict __attr, + unsigned int __count) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_barrier_destroy(pthread_barrier_t *__barrier) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_barrier_wait(pthread_barrier_t *__barrier) + __attribute__((__nothrow__)) __attribute__((__nonnull__(1))); -extern int memcmp (const void *__s1, const void *__s2, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern void *memchr (const void *__s, int __c, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); -extern void *rawmemchr (const void *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); -extern void *memrchr (const void *__s, int __c, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); +extern int pthread_barrierattr_init(pthread_barrierattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_barrierattr_destroy(pthread_barrierattr_t *__attr) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int +pthread_barrierattr_getpshared(const pthread_barrierattr_t *__restrict __attr, + int *__restrict __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1, 2))); +extern int pthread_barrierattr_setpshared(pthread_barrierattr_t *__attr, + int __pshared) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int pthread_key_create(pthread_key_t *__key, + void (*__destr_function)(void *)) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern int pthread_key_delete(pthread_key_t __key) + __attribute__((__nothrow__, __leaf__)); +extern void *pthread_getspecific(pthread_key_t __key) + __attribute__((__nothrow__, __leaf__)); +extern int pthread_setspecific(pthread_key_t __key, const void *__pointer) + __attribute__((__nothrow__, __leaf__)); -extern char *strcpy (char *__restrict __dest, const char *__restrict __src) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int pthread_getcpuclockid(pthread_t __thread_id, __clockid_t *__clock_id) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); +extern int pthread_atfork(void (*__prepare)(void), void (*__parent)(void), + void (*__child)(void)) + __attribute__((__nothrow__, __leaf__)); -extern char *strncpy (char *__restrict __dest, - const char *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +typedef struct { + unsigned char _x[4] __attribute__((__aligned__(4))); +} omp_lock_t; +typedef struct { + unsigned char _x[16] __attribute__((__aligned__(8))); +} omp_nest_lock_t; -extern char *strcat (char *__restrict __dest, const char *__restrict __src) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - -extern char *strncat (char *__restrict __dest, const char *__restrict __src, - size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +typedef enum omp_sched_t { + omp_sched_static = 1, + omp_sched_dynamic = 2, + omp_sched_guided = 3, + omp_sched_auto = 4, + omp_sched_monotonic = 0x80000000U +} omp_sched_t; +typedef enum omp_proc_bind_t { + omp_proc_bind_false = 0, + omp_proc_bind_true = 1, + omp_proc_bind_primary = 2, + omp_proc_bind_master __attribute__((__deprecated__)) = omp_proc_bind_primary, + omp_proc_bind_close = 3, + omp_proc_bind_spread = 4 +} omp_proc_bind_t; -extern int strcmp (const char *__s1, const char *__s2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +typedef enum omp_sync_hint_t { + omp_sync_hint_none = 0, + omp_lock_hint_none __attribute__((__deprecated__)) = omp_sync_hint_none, + omp_sync_hint_uncontended = 1, + omp_lock_hint_uncontended __attribute__((__deprecated__)) = + omp_sync_hint_uncontended, + omp_sync_hint_contended = 2, + omp_lock_hint_contended __attribute__((__deprecated__)) = + omp_sync_hint_contended, + omp_sync_hint_nonspeculative = 4, + omp_lock_hint_nonspeculative __attribute__((__deprecated__)) = + omp_sync_hint_nonspeculative, + omp_sync_hint_speculative = 8, + omp_lock_hint_speculative __attribute__((__deprecated__)) = + omp_sync_hint_speculative +} omp_sync_hint_t; -extern int strncmp (const char *__s1, const char *__s2, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +typedef __attribute__((__deprecated__)) omp_sync_hint_t omp_lock_hint_t; +typedef struct __attribute__((__aligned__(sizeof(void *)))) omp_depend_t { + char __omp_depend_t__[2 * sizeof(void *)]; +} omp_depend_t; -extern int strcoll (const char *__s1, const char *__s2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +typedef enum omp_pause_resource_t { + omp_pause_soft = 1, + omp_pause_hard = 2 +} omp_pause_resource_t; -extern size_t strxfrm (char *__restrict __dest, - const char *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); +typedef long int omp_intptr_t; +typedef long unsigned int omp_uintptr_t; +typedef enum omp_memspace_handle_t { + omp_default_mem_space = 0, + omp_large_cap_mem_space = 1, + omp_const_mem_space = 2, + omp_high_bw_mem_space = 3, + omp_low_lat_mem_space = 4, + ompx_gnu_managed_mem_space = 200, + __omp_memspace_handle_t_max__ = 0xffffffffffffffffUL +} omp_memspace_handle_t; +typedef enum omp_allocator_handle_t { + omp_null_allocator = 0, + omp_default_mem_alloc = 1, + omp_large_cap_mem_alloc = 2, + omp_const_mem_alloc = 3, + omp_high_bw_mem_alloc = 4, + omp_low_lat_mem_alloc = 5, + omp_cgroup_mem_alloc = 6, + omp_pteam_mem_alloc = 7, + omp_thread_mem_alloc = 8, + ompx_gnu_pinned_mem_alloc = 200, + ompx_gnu_managed_mem_alloc = 201, + __omp_allocator_handle_t_max__ = 0xffffffffffffffffUL +} omp_allocator_handle_t; +typedef enum omp_alloctrait_key_t { + omp_atk_sync_hint = 1, + omp_atk_alignment = 2, + omp_atk_access = 3, + omp_atk_pool_size = 4, + omp_atk_fallback = 5, + omp_atk_fb_data = 6, + omp_atk_pinned = 7, + omp_atk_partition = 8 +} omp_alloctrait_key_t; +typedef enum omp_alloctrait_value_t { + omp_atv_default = (long unsigned int)-1, + omp_atv_false = 0, + omp_atv_true = 1, + omp_atv_contended = 3, + omp_atv_uncontended = 4, + omp_atv_serialized = 5, + omp_atv_sequential __attribute__((__deprecated__)) = omp_atv_serialized, + omp_atv_private = 6, + omp_atv_all = 7, + omp_atv_thread = 8, + omp_atv_pteam = 9, + omp_atv_cgroup = 10, + omp_atv_default_mem_fb = 11, + omp_atv_null_fb = 12, + omp_atv_abort_fb = 13, + omp_atv_allocator_fb = 14, + omp_atv_environment = 15, + omp_atv_nearest = 16, + omp_atv_blocked = 17, + omp_atv_interleaved = 18 +} omp_alloctrait_value_t; +typedef struct omp_alloctrait_t { + omp_alloctrait_key_t key; + omp_uintptr_t value; +} omp_alloctrait_t; -extern int strcoll_l (const char *__s1, const char *__s2, locale_t __l) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 3))); +typedef enum omp_event_handle_t { + __omp_event_handle_t_max__ = 0xffffffffffffffffUL +} omp_event_handle_t; +enum { + omp_initial_device = -1, + omp_invalid_device = -4, + omp_default_device = -5 +}; -extern size_t strxfrm_l (char *__dest, const char *__src, size_t __n, - locale_t __l) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))); +typedef enum omp_interop_t { + omp_interop_none = 0, + __omp_interop_t_max__ = 0xffffffffffffffffUL +} omp_interop_t; +typedef enum omp_interop_fr_t { + omp_ifr_cuda = 1, + omp_ifr_cuda_driver = 2, + omp_ifr_opencl = 3, + omp_ifr_sycl = 4, + omp_ifr_hip = 5, + omp_ifr_level_zero = 6, + omp_ifr_hsa = 7, + omp_ifr_last = omp_ifr_hsa +} omp_interop_fr_t; +typedef enum omp_interop_property_t { + omp_ipr_fr_id = -1, + omp_ipr_fr_name = -2, + omp_ipr_vendor = -3, + omp_ipr_vendor_name = -4, + omp_ipr_device_num = -5, + omp_ipr_platform = -6, + omp_ipr_device = -7, + omp_ipr_device_context = -8, + omp_ipr_targetsync = -9, + omp_ipr_first = -9 +} omp_interop_property_t; +typedef enum omp_interop_rc_t { + omp_irc_no_value = 1, + omp_irc_success = 0, + omp_irc_empty = -1, + omp_irc_out_of_range = -2, + omp_irc_type_int = -3, + omp_irc_type_ptr = -4, + omp_irc_type_str = -5, + omp_irc_other = -6 +} omp_interop_rc_t; +extern void omp_set_num_threads(int) __attribute__((__nothrow__)); +extern int omp_get_num_threads(void) __attribute__((__nothrow__)); +extern int omp_get_max_threads(void) __attribute__((__nothrow__)); +extern int omp_get_thread_num(void) __attribute__((__nothrow__)); +extern int omp_get_num_procs(void) __attribute__((__nothrow__)); + +extern int omp_in_parallel(void) __attribute__((__nothrow__)); + +extern void omp_set_dynamic(int) __attribute__((__nothrow__)); +extern int omp_get_dynamic(void) __attribute__((__nothrow__)); + +extern void omp_set_nested(int) __attribute__((__nothrow__)) +__attribute__((__deprecated__)); +extern int omp_get_nested(void) __attribute__((__nothrow__)) +__attribute__((__deprecated__)); + +extern void omp_init_lock(omp_lock_t *) __attribute__((__nothrow__)); +extern void omp_init_lock_with_hint(omp_lock_t *, omp_sync_hint_t) + __attribute__((__nothrow__)); +extern void omp_destroy_lock(omp_lock_t *) __attribute__((__nothrow__)); +extern void omp_set_lock(omp_lock_t *) __attribute__((__nothrow__)); +extern void omp_unset_lock(omp_lock_t *) __attribute__((__nothrow__)); +extern int omp_test_lock(omp_lock_t *) __attribute__((__nothrow__)); + +extern void omp_init_nest_lock(omp_nest_lock_t *) __attribute__((__nothrow__)); +extern void omp_init_nest_lock_with_hint(omp_nest_lock_t *, omp_sync_hint_t) + __attribute__((__nothrow__)); +extern void omp_destroy_nest_lock(omp_nest_lock_t *) + __attribute__((__nothrow__)); +extern void omp_set_nest_lock(omp_nest_lock_t *) __attribute__((__nothrow__)); +extern void omp_unset_nest_lock(omp_nest_lock_t *) __attribute__((__nothrow__)); +extern int omp_test_nest_lock(omp_nest_lock_t *) __attribute__((__nothrow__)); + +extern double omp_get_wtime(void) __attribute__((__nothrow__)); +extern double omp_get_wtick(void) __attribute__((__nothrow__)); + +extern void omp_set_schedule(omp_sched_t, int) __attribute__((__nothrow__)); +extern void omp_get_schedule(omp_sched_t *, int *) __attribute__((__nothrow__)); +extern int omp_get_thread_limit(void) __attribute__((__nothrow__)); +extern void omp_set_max_active_levels(int) __attribute__((__nothrow__)); +extern int omp_get_max_active_levels(void) __attribute__((__nothrow__)); +extern int omp_get_supported_active_levels(void) __attribute__((__nothrow__)); +extern int omp_get_level(void) __attribute__((__nothrow__)); +extern int omp_get_ancestor_thread_num(int) __attribute__((__nothrow__)); +extern int omp_get_team_size(int) __attribute__((__nothrow__)); +extern int omp_get_active_level(void) __attribute__((__nothrow__)); + +extern int omp_in_final(void) __attribute__((__nothrow__)); +extern int omp_in_explicit_task(void) __attribute__((__nothrow__)); + +extern int omp_get_cancellation(void) __attribute__((__nothrow__)); +extern omp_proc_bind_t omp_get_proc_bind(void) __attribute__((__nothrow__)); +extern int omp_get_num_places(void) __attribute__((__nothrow__)); +extern int omp_get_place_num_procs(int) __attribute__((__nothrow__)); +extern void omp_get_place_proc_ids(int, int *) __attribute__((__nothrow__)); +extern int omp_get_place_num(void) __attribute__((__nothrow__)); +extern int omp_get_partition_num_places(void) __attribute__((__nothrow__)); +extern void omp_get_partition_place_nums(int *) __attribute__((__nothrow__)); + +extern void omp_set_default_device(int) __attribute__((__nothrow__)); +extern int omp_get_default_device(void) __attribute__((__nothrow__)); +extern int omp_get_num_devices(void) __attribute__((__nothrow__)); +extern int omp_get_device_num(void) __attribute__((__nothrow__)); +extern int omp_get_num_teams(void) __attribute__((__nothrow__)); +extern int omp_get_team_num(void) __attribute__((__nothrow__)); + +extern int omp_is_initial_device(void) __attribute__((__nothrow__)); +extern int omp_get_initial_device(void) __attribute__((__nothrow__)); +extern int omp_get_max_task_priority(void) __attribute__((__nothrow__)); + +extern void omp_fulfill_event(omp_event_handle_t) __attribute__((__nothrow__)); + +extern void omp_set_num_teams(int) __attribute__((__nothrow__)); +extern int omp_get_max_teams(void) __attribute__((__nothrow__)); +extern void omp_set_teams_thread_limit(int) __attribute__((__nothrow__)); +extern int omp_get_teams_thread_limit(void) __attribute__((__nothrow__)); + +extern void *omp_target_alloc(long unsigned int, int) + __attribute__((__nothrow__)); +extern void omp_target_free(void *, int) __attribute__((__nothrow__)); +extern int omp_target_is_present(const void *, int) + __attribute__((__nothrow__)); +extern int omp_target_memcpy(void *, const void *, long unsigned int, + long unsigned int, long unsigned int, int, int) + __attribute__((__nothrow__)); +extern int omp_target_memcpy_async(void *, const void *, long unsigned int, + long unsigned int, long unsigned int, int, + int, int, omp_depend_t *) + __attribute__((__nothrow__)); +extern int +omp_target_memcpy_rect(void *, const void *, long unsigned int, int, + const long unsigned int *, const long unsigned int *, + const long unsigned int *, const long unsigned int *, + const long unsigned int *, int, int) + __attribute__((__nothrow__)); +extern int omp_target_memcpy_rect_async( + void *, const void *, long unsigned int, int, const long unsigned int *, + const long unsigned int *, const long unsigned int *, + const long unsigned int *, const long unsigned int *, int, int, int, + omp_depend_t *) __attribute__((__nothrow__)); +extern void *omp_target_memset(void *, int, long unsigned int, int) + __attribute__((__nothrow__)); +extern void *omp_target_memset_async(void *, int, long unsigned int, int, int, + omp_depend_t *) + __attribute__((__nothrow__)); +extern int omp_target_associate_ptr(const void *, const void *, + long unsigned int, long unsigned int, int) + __attribute__((__nothrow__)); +extern int omp_target_disassociate_ptr(const void *, int) + __attribute__((__nothrow__)); +extern void *omp_get_mapped_ptr(const void *, int) __attribute__((__nothrow__)); +extern int omp_target_is_accessible(const void *, long unsigned int, int) + __attribute__((__nothrow__)); + +extern void omp_set_affinity_format(const char *) __attribute__((__nothrow__)); +extern long unsigned int omp_get_affinity_format(char *, long unsigned int) + __attribute__((__nothrow__)); +extern void omp_display_affinity(const char *) __attribute__((__nothrow__)); +extern long unsigned int omp_capture_affinity(char *, long unsigned int, + const char *) + __attribute__((__nothrow__)); + +extern int omp_pause_resource(omp_pause_resource_t, int) + __attribute__((__nothrow__)); +extern int omp_pause_resource_all(omp_pause_resource_t) + __attribute__((__nothrow__)); + +extern omp_allocator_handle_t omp_init_allocator(omp_memspace_handle_t, int, + const omp_alloctrait_t[]) + __attribute__((__nothrow__)); +extern void omp_destroy_allocator(omp_allocator_handle_t) + __attribute__((__nothrow__)); +extern void omp_set_default_allocator(omp_allocator_handle_t) + __attribute__((__nothrow__)); +extern omp_allocator_handle_t omp_get_default_allocator(void) + __attribute__((__nothrow__)); +extern void omp_free(void *, omp_allocator_handle_t) + __attribute__((__nothrow__)); +extern void *omp_alloc(long unsigned int, omp_allocator_handle_t) + __attribute__((__nothrow__)) + __attribute__((__malloc__, __malloc__(omp_free), __alloc_size__(1))); +extern void *omp_aligned_alloc(long unsigned int, long unsigned int, + omp_allocator_handle_t) + __attribute__((__nothrow__)) + __attribute__((__malloc__, __malloc__(omp_free), __alloc_size__(2), + __alloc_align__(1))); +extern void *omp_calloc(long unsigned int, long unsigned int, + omp_allocator_handle_t) __attribute__((__nothrow__)) +__attribute__((__malloc__, __malloc__(omp_free), __alloc_size__(1, 2))); +extern void *omp_aligned_calloc(long unsigned int, long unsigned int, + long unsigned int, omp_allocator_handle_t) + __attribute__((__nothrow__)) + __attribute__((__malloc__, __malloc__(omp_free), __alloc_size__(2, 3), + __alloc_align__(1))); +extern void *omp_realloc(void *, long unsigned int, omp_allocator_handle_t, + omp_allocator_handle_t) __attribute__((__nothrow__)) +__attribute__((__malloc__(omp_free), __alloc_size__(2))); + +extern void omp_display_env(int) __attribute__((__nothrow__)); + +extern int omp_get_num_interop_properties(const omp_interop_t) + __attribute__((__nothrow__)); + +extern omp_intptr_t omp_get_interop_int(const omp_interop_t, + omp_interop_property_t, + omp_interop_rc_t *) + __attribute__((__nothrow__)); + +extern void *omp_get_interop_ptr(const omp_interop_t, omp_interop_property_t, + omp_interop_rc_t *) + __attribute__((__nothrow__)); + +extern const char *omp_get_interop_str(const omp_interop_t, + omp_interop_property_t, + omp_interop_rc_t *) + __attribute__((__nothrow__)); + +extern const char *omp_get_interop_name(const omp_interop_t, + omp_interop_property_t) + __attribute__((__nothrow__)); + +extern const char *omp_get_interop_type_desc(const omp_interop_t, + omp_interop_property_t) + __attribute__((__nothrow__)); + +extern const char *omp_get_interop_rc_desc(const omp_interop_t, + omp_interop_rc_t) + __attribute__((__nothrow__)); + +extern int omp_get_device_from_uid(const char *) __attribute__((__nothrow__)); +extern const char *omp_get_uid_from_device(int) __attribute__((__nothrow__)); + +struct dirent { + + __ino_t d_ino; + __off_t d_off; + + unsigned short int d_reclen; + unsigned char d_type; + char d_name[256]; +}; +struct dirent64 { + __ino64_t d_ino; + __off64_t d_off; + unsigned short int d_reclen; + unsigned char d_type; + char d_name[256]; +}; +enum { + DT_UNKNOWN = 0, -extern char *strdup (const char *__s) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1))); + DT_FIFO = 1, + DT_CHR = 2, + DT_DIR = 4, + DT_BLK = 6, + DT_REG = 8, + DT_LNK = 10, -extern char *strndup (const char *__string, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__malloc__)) __attribute__ ((__nonnull__ (1))); -extern char *strchr (const char *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); -extern char *strrchr (const char *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); -extern char *strchrnul (const char *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); + DT_SOCK = 12, + DT_WHT = 14 +}; +typedef struct __dirstream DIR; +extern DIR *opendir(const char *__name) __attribute__((__nonnull__(1))); + +extern DIR *fdopendir(int __fd); + +extern int closedir(DIR *__dirp) __attribute__((__nonnull__(1))); +extern struct dirent *readdir(DIR *__dirp) __attribute__((__nonnull__(1))); +extern struct dirent64 *readdir64(DIR *__dirp) __attribute__((__nonnull__(1))); +extern int readdir_r(DIR *__restrict __dirp, struct dirent *__restrict __entry, + struct dirent **__restrict __result) + __attribute__((__nonnull__(1, 2, 3))) __attribute__((__deprecated__)); +extern int readdir64_r(DIR *__restrict __dirp, + struct dirent64 *__restrict __entry, + struct dirent64 **__restrict __result) + __attribute__((__nonnull__(1, 2, 3))) __attribute__((__deprecated__)); + +extern void rewinddir(DIR *__dirp) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern void seekdir(DIR *__dirp, long int __pos) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); + +extern long int telldir(DIR *__dirp) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); + +extern int dirfd(DIR *__dirp) __attribute__((__nothrow__, __leaf__)) +__attribute__((__nonnull__(1))); +extern int scandir(const char *__restrict __dir, + struct dirent ***__restrict __namelist, + int (*__selector)(const struct dirent *), + int (*__cmp)(const struct dirent **, const struct dirent **)) + __attribute__((__nonnull__(1, 2))); +extern int scandir64(const char *__restrict __dir, + struct dirent64 ***__restrict __namelist, + int (*__selector)(const struct dirent64 *), + int (*__cmp)(const struct dirent64 **, + const struct dirent64 **)) + __attribute__((__nonnull__(1, 2))); +extern int scandirat(int __dfd, const char *__restrict __dir, + struct dirent ***__restrict __namelist, + int (*__selector)(const struct dirent *), + int (*__cmp)(const struct dirent **, + const struct dirent **)) + __attribute__((__nonnull__(2, 3))); +extern int scandirat64(int __dfd, const char *__restrict __dir, + struct dirent64 ***__restrict __namelist, + int (*__selector)(const struct dirent64 *), + int (*__cmp)(const struct dirent64 **, + const struct dirent64 **)) + __attribute__((__nonnull__(2, 3))); + +extern int alphasort(const struct dirent **__e1, const struct dirent **__e2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern int alphasort64(const struct dirent64 **__e1, + const struct dirent64 **__e2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern __ssize_t getdirentries(int __fd, char *__restrict __buf, + size_t __nbytes, __off_t *__restrict __basep) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 4))); +extern __ssize_t getdirentries64(int __fd, char *__restrict __buf, + size_t __nbytes, __off64_t *__restrict __basep) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2, 4))); + +extern int versionsort(const struct dirent **__e1, const struct dirent **__e2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); +extern int versionsort64(const struct dirent64 **__e1, + const struct dirent64 **__e2) + __attribute__((__nothrow__, __leaf__)) __attribute__((__pure__)) + __attribute__((__nonnull__(1, 2))); + +extern __ssize_t getdents64(int __fd, void *__buffer, size_t __length) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(2))); + +typedef enum { P_ALL, P_PID, P_PGID } idtype_t; +extern __pid_t wait(int *__stat_loc); +extern __pid_t waitpid(__pid_t __pid, int *__stat_loc, int __options); +extern int waitid(idtype_t __idtype, __id_t __id, siginfo_t *__infop, + int __options); +struct rusage; -extern size_t strcspn (const char *__s, const char *__reject) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +extern __pid_t wait3(int *__stat_loc, int __options, struct rusage *__usage) + __attribute__((__nothrow__)); +extern __pid_t wait4(__pid_t __pid, int *__stat_loc, int __options, + struct rusage *__usage) __attribute__((__nothrow__)); -extern size_t strspn (const char *__s, const char *__accept) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern char *strpbrk (const char *__s, const char *__accept) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern char *strstr (const char *__haystack, const char *__needle) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +struct passwd { + char *pw_name; + char *pw_passwd; + __uid_t pw_uid; + __gid_t pw_gid; + char *pw_gecos; + char *pw_dir; + char *pw_shell; +}; +extern void setpwent(void); +extern void endpwent(void); +extern struct passwd *getpwent(void); +extern struct passwd *fgetpwent(FILE *__stream) __attribute__((__nonnull__(1))); -extern char *strtok (char *__restrict __s, const char *__restrict __delim) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); +extern int putpwent(const struct passwd *__restrict __p, FILE *__restrict __f); +extern struct passwd *getpwuid(__uid_t __uid); +extern struct passwd *getpwnam(const char *__name) + __attribute__((__nonnull__(1))); +extern int getpwent_r(struct passwd *__restrict __resultbuf, + char *__restrict __buffer, size_t __buflen, + struct passwd **__restrict __result) + __attribute__((__nonnull__(1, 2, 4))); -extern char *__strtok_r (char *__restrict __s, - const char *__restrict __delim, - char **__restrict __save_ptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); +extern int getpwuid_r(__uid_t __uid, struct passwd *__restrict __resultbuf, + char *__restrict __buffer, size_t __buflen, + struct passwd **__restrict __result) + __attribute__((__nonnull__(2, 3, 5))); -extern char *strtok_r (char *__restrict __s, const char *__restrict __delim, - char **__restrict __save_ptr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); -extern char *strcasestr (const char *__haystack, const char *__needle) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +extern int getpwnam_r(const char *__restrict __name, + struct passwd *__restrict __resultbuf, + char *__restrict __buffer, size_t __buflen, + struct passwd **__restrict __result) + __attribute__((__nonnull__(1, 2, 3, 5))); +extern int fgetpwent_r(FILE *__restrict __stream, + struct passwd *__restrict __resultbuf, + char *__restrict __buffer, size_t __buflen, + struct passwd **__restrict __result) + __attribute__((__nonnull__(1, 2, 3, 5))); +extern int getpw(__uid_t __uid, char *__buffer); +typedef float MagickFloatType; +typedef double MagickDoubleType; +typedef MagickFloatType Quantum; +typedef MagickDoubleType MagickRealType; +typedef unsigned int MagickStatusType; +typedef long long MagickOffsetType; +typedef unsigned long long MagickSizeType; +typedef uintptr_t MagickAddressType; +typedef MagickSizeType QuantumAny; +typedef enum { UndefinedClass, DirectClass, PseudoClass } ClassType; +typedef enum { MagickFalse = 0, MagickTrue = 1 } MagickBooleanType; +typedef struct _BlobInfo BlobInfo; +typedef struct _ExceptionInfo ExceptionInfo; -extern void *memmem (const void *__haystack, size_t __haystacklen, - const void *__needle, size_t __needlelen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 3))); +typedef struct _Image Image; +typedef struct _ImageInfo ImageInfo; +struct timezone { + int tz_minuteswest; + int tz_dsttime; +}; +extern int gettimeofday(struct timeval *__restrict __tv, void *__restrict __tz) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); -extern void *__mempcpy (void *__restrict __dest, - const void *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern void *mempcpy (void *__restrict __dest, - const void *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int settimeofday(const struct timeval *__tv, const struct timezone *__tz) + __attribute__((__nothrow__, __leaf__)); +extern int adjtime(const struct timeval *__delta, struct timeval *__olddelta) + __attribute__((__nothrow__, __leaf__)); +enum __itimer_which { + ITIMER_REAL = 0, -extern size_t strlen (const char *__s) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); + ITIMER_VIRTUAL = 1, + ITIMER_PROF = 2 +}; +struct itimerval { -extern size_t strnlen (const char *__string, size_t __maxlen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); + struct timeval it_interval; + struct timeval it_value; +}; +typedef enum __itimer_which __itimer_which_t; +extern int getitimer(__itimer_which_t __which, struct itimerval *__value) + __attribute__((__nothrow__, __leaf__)); -extern char *strerror (int __errnum) __attribute__ ((__nothrow__ , __leaf__)); -extern char *strerror_r (int __errnum, char *__buf, size_t __buflen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))) ; +extern int setitimer(__itimer_which_t __which, + const struct itimerval *__restrict __new, + struct itimerval *__restrict __old) + __attribute__((__nothrow__, __leaf__)); +extern int utimes(const char *__file, const struct timeval __tvp[2]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int lutimes(const char *__file, const struct timeval __tvp[2]) + __attribute__((__nothrow__, __leaf__)) __attribute__((__nonnull__(1))); +extern int futimes(int __fd, const struct timeval __tvp[2]) + __attribute__((__nothrow__, __leaf__)); +extern int futimesat(int __fd, const char *__file, + const struct timeval __tvp[2]) + __attribute__((__nothrow__, __leaf__)); -extern char *strerror_l (int __errnum, locale_t __l) __attribute__ ((__nothrow__ , __leaf__)); +struct tms { + clock_t tms_utime; + clock_t tms_stime; + clock_t tms_cutime; + clock_t tms_cstime; +}; +extern clock_t times(struct tms *__buffer) + __attribute__((__nothrow__, __leaf__)); +enum __rlimit_resource { + RLIMIT_CPU = 0, + RLIMIT_FSIZE = 1, + RLIMIT_DATA = 2, + RLIMIT_STACK = 3, + RLIMIT_CORE = 4, + __RLIMIT_RSS = 5, + RLIMIT_NOFILE = 7, + __RLIMIT_OFILE = RLIMIT_NOFILE, + RLIMIT_AS = 9, + __RLIMIT_NPROC = 6, -extern int bcmp (const void *__s1, const void *__s2, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); + __RLIMIT_MEMLOCK = 8, + __RLIMIT_LOCKS = 10, -extern void bcopy (const void *__src, void *__dest, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + __RLIMIT_SIGPENDING = 11, + __RLIMIT_MSGQUEUE = 12, -extern void bzero (void *__s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern char *index (const char *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); -extern char *rindex (const char *__s, int __c) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))); + __RLIMIT_NICE = 13, + __RLIMIT_RTPRIO = 14, + __RLIMIT_RTTIME = 15, + __RLIMIT_NLIMITS = 16, + __RLIM_NLIMITS = __RLIMIT_NLIMITS +}; +typedef __rlim_t rlim_t; +typedef __rlim64_t rlim64_t; -extern int ffs (int __i) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); +struct rlimit { + rlim_t rlim_cur; + rlim_t rlim_max; +}; +struct rlimit64 { + rlim64_t rlim_cur; -extern int ffsl (long int __l) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); -__extension__ extern int ffsll (long long int __ll) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); + rlim64_t rlim_max; +}; +enum __rusage_who { + RUSAGE_SELF = 0, -extern int strcasecmp (const char *__s1, const char *__s2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); + RUSAGE_CHILDREN = -1 + , -extern int strncasecmp (const char *__s1, const char *__s2, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); + RUSAGE_THREAD = 1 +}; +struct rusage { + struct timeval ru_utime; + struct timeval ru_stime; + __extension__ union { + long int ru_maxrss; + __syscall_slong_t __ru_maxrss_word; + }; -extern int strcasecmp_l (const char *__s1, const char *__s2, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 3))); + __extension__ union { + long int ru_ixrss; + __syscall_slong_t __ru_ixrss_word; + }; + __extension__ union { + long int ru_idrss; + __syscall_slong_t __ru_idrss_word; + }; + __extension__ union { + long int ru_isrss; + __syscall_slong_t __ru_isrss_word; + }; -extern int strncasecmp_l (const char *__s1, const char *__s2, - size_t __n, locale_t __loc) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2, 4))); + __extension__ union { + long int ru_minflt; + __syscall_slong_t __ru_minflt_word; + }; + __extension__ union { + long int ru_majflt; + __syscall_slong_t __ru_majflt_word; + }; + __extension__ union { + long int ru_nswap; + __syscall_slong_t __ru_nswap_word; + }; + __extension__ union { + long int ru_inblock; + __syscall_slong_t __ru_inblock_word; + }; + __extension__ union { + long int ru_oublock; + __syscall_slong_t __ru_oublock_word; + }; + __extension__ union { + long int ru_msgsnd; + __syscall_slong_t __ru_msgsnd_word; + }; -extern void explicit_bzero (void *__s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); + __extension__ union { + long int ru_msgrcv; + __syscall_slong_t __ru_msgrcv_word; + }; + __extension__ union { + long int ru_nsignals; + __syscall_slong_t __ru_nsignals_word; + }; + __extension__ union { + long int ru_nvcsw; + __syscall_slong_t __ru_nvcsw_word; + }; -extern char *strsep (char **__restrict __stringp, - const char *__restrict __delim) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); + __extension__ union { + long int ru_nivcsw; + __syscall_slong_t __ru_nivcsw_word; + }; +}; +enum __priority_which { + PRIO_PROCESS = 0, + PRIO_PGRP = 1, + PRIO_USER = 2 -extern char *strsignal (int __sig) __attribute__ ((__nothrow__ , __leaf__)); +}; +extern int prlimit(__pid_t __pid, enum __rlimit_resource __resource, + const struct rlimit *__new_limit, struct rlimit *__old_limit) + __attribute__((__nothrow__, __leaf__)); +extern int prlimit64(__pid_t __pid, enum __rlimit_resource __resource, + const struct rlimit64 *__new_limit, + struct rlimit64 *__old_limit) + __attribute__((__nothrow__, __leaf__)); -extern char *__stpcpy (char *__restrict __dest, const char *__restrict __src) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern char *stpcpy (char *__restrict __dest, const char *__restrict __src) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +typedef enum __rlimit_resource __rlimit_resource_t; +typedef enum __rusage_who __rusage_who_t; +typedef enum __priority_which __priority_which_t; +extern int getrlimit(__rlimit_resource_t __resource, struct rlimit *__rlimits) + __attribute__((__nothrow__, __leaf__)); +extern int getrlimit64(__rlimit_resource_t __resource, + struct rlimit64 *__rlimits) + __attribute__((__nothrow__, __leaf__)); +extern int setrlimit(__rlimit_resource_t __resource, + const struct rlimit *__rlimits) + __attribute__((__nothrow__, __leaf__)); +extern int setrlimit64(__rlimit_resource_t __resource, + const struct rlimit64 *__rlimits) + __attribute__((__nothrow__, __leaf__)); +extern int getrusage(__rusage_who_t __who, struct rusage *__usage) + __attribute__((__nothrow__, __leaf__)); -extern char *__stpncpy (char *__restrict __dest, - const char *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -extern char *stpncpy (char *__restrict __dest, - const char *__restrict __src, size_t __n) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); +extern int getpriority(__priority_which_t __which, id_t __who) + __attribute__((__nothrow__, __leaf__)); +extern int setpriority(__priority_which_t __which, id_t __who, int __prio) + __attribute__((__nothrow__, __leaf__)); +int memfd_create(const char *__name, unsigned int __flags) + __attribute__((__nothrow__, __leaf__)); +int mlock2(const void *__addr, size_t __length, unsigned int __flags) + __attribute__((__nothrow__, __leaf__)); -extern int strverscmp (const char *__s1, const char *__s2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); +int pkey_alloc(unsigned int __flags, unsigned int __access_rights) + __attribute__((__nothrow__, __leaf__)); +int pkey_set(int __key, unsigned int __access_rights) + __attribute__((__nothrow__, __leaf__)); -extern char *strfry (char *__string) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +int pkey_get(int __key) __attribute__((__nothrow__, __leaf__)); +int pkey_free(int __key) __attribute__((__nothrow__, __leaf__)); -extern void *memfrob (void *__s, size_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern char *basename (const char *__filename) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +int pkey_mprotect(void *__addr, size_t __len, int __prot, int __pkey) + __attribute__((__nothrow__, __leaf__)); +extern void *mmap(void *__addr, size_t __len, int __prot, int __flags, int __fd, + __off_t __offset) __attribute__((__nothrow__, __leaf__)); +extern void *mmap64(void *__addr, size_t __len, int __prot, int __flags, + int __fd, __off64_t __offset) + __attribute__((__nothrow__, __leaf__)); +extern int munmap(void *__addr, size_t __len) + __attribute__((__nothrow__, __leaf__)); +extern int mprotect(void *__addr, size_t __len, int __prot) + __attribute__((__nothrow__, __leaf__)); +extern int msync(void *__addr, size_t __len, int __flags); +extern int madvise(void *__addr, size_t __len, int __advice) + __attribute__((__nothrow__, __leaf__)); - +extern int posix_madvise(void *__addr, size_t __len, int __advice) + __attribute__((__nothrow__, __leaf__)); +extern int mlock(const void *__addr, size_t __len) + __attribute__((__nothrow__, __leaf__)); +extern int munlock(const void *__addr, size_t __len) + __attribute__((__nothrow__, __leaf__)); +extern int mlockall(int __flags) __attribute__((__nothrow__, __leaf__)); +extern int munlockall(void) __attribute__((__nothrow__, __leaf__)); +extern int mincore(void *__start, size_t __len, unsigned char *__vec) + __attribute__((__nothrow__, __leaf__)); +extern void *mremap(void *__addr, size_t __old_len, size_t __new_len, + int __flags, ...) __attribute__((__nothrow__, __leaf__)); +extern int remap_file_pages(void *__start, size_t __size, int __prot, + size_t __pgoff, int __flags) + __attribute__((__nothrow__, __leaf__)); +extern int shm_open(const char *__name, int __oflag, mode_t __mode); -typedef __uint8_t uint8_t; -typedef __uint16_t uint16_t; -typedef __uint32_t uint32_t; -typedef __uint64_t uint64_t; +extern int shm_unlink(const char *__name); +extern ssize_t sendfile(int __out_fd, int __in_fd, off_t *__offset, + size_t __count) __attribute__((__nothrow__, __leaf__)); +extern ssize_t sendfile64(int __out_fd, int __in_fd, __off64_t *__offset, + size_t __count) + __attribute__((__nothrow__, __leaf__)); +enum __socket_type { + SOCK_STREAM = 1, + SOCK_DGRAM = 2, + SOCK_RAW = 3, -typedef __int_least8_t int_least8_t; -typedef __int_least16_t int_least16_t; -typedef __int_least32_t int_least32_t; -typedef __int_least64_t int_least64_t; + SOCK_RDM = 4, + SOCK_SEQPACKET = 5, -typedef __uint_least8_t uint_least8_t; -typedef __uint_least16_t uint_least16_t; -typedef __uint_least32_t uint_least32_t; -typedef __uint_least64_t uint_least64_t; + SOCK_DCCP = 6, + SOCK_PACKET = 10, + SOCK_CLOEXEC = 02000000, + SOCK_NONBLOCK = 00004000 +}; +typedef unsigned short int sa_family_t; -typedef signed char int_fast8_t; +struct sockaddr { + sa_family_t sa_family; + char sa_data[14]; +}; +struct sockaddr_storage { + sa_family_t ss_family; + char __ss_padding[(128 - (sizeof(unsigned short int)) - + sizeof(unsigned long int))]; + unsigned long int __ss_align; +}; -typedef long int int_fast16_t; -typedef long int int_fast32_t; -typedef long int int_fast64_t; -typedef unsigned char uint_fast8_t; +enum { + MSG_OOB = 0x01, -typedef unsigned long int uint_fast16_t; -typedef unsigned long int uint_fast32_t; -typedef unsigned long int uint_fast64_t; -typedef long int intptr_t; + MSG_PEEK = 0x02, + MSG_DONTROUTE = 0x04, -typedef unsigned long int uintptr_t; -typedef __intmax_t intmax_t; -typedef __uintmax_t uintmax_t; + MSG_TRYHARD = MSG_DONTROUTE, + MSG_CTRUNC = 0x08, + MSG_PROXY = 0x10, + MSG_TRUNC = 0x20, + MSG_DONTWAIT = 0x40, + MSG_EOR = 0x80, -typedef int __gwchar_t; + MSG_WAITALL = 0x100, + MSG_FIN = 0x200, + MSG_SYN = 0x400, + MSG_CONFIRM = 0x800, + MSG_RST = 0x1000, -typedef struct - { - long int quot; - long int rem; - } imaxdiv_t; -extern intmax_t imaxabs (intmax_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); + MSG_ERRQUEUE = 0x2000, + MSG_NOSIGNAL = 0x4000, -extern imaxdiv_t imaxdiv (intmax_t __numer, intmax_t __denom) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); + MSG_MORE = 0x8000, + MSG_WAITFORONE = 0x10000, -extern intmax_t strtoimax (const char *__restrict __nptr, - char **__restrict __endptr, int __base) __attribute__ ((__nothrow__ , __leaf__)); + MSG_BATCH = 0x40000, + MSG_ZEROCOPY = 0x4000000, -extern uintmax_t strtoumax (const char *__restrict __nptr, - char ** __restrict __endptr, int __base) __attribute__ ((__nothrow__ , __leaf__)); + MSG_FASTOPEN = 0x20000000, + MSG_CMSG_CLOEXEC = 0x40000000 -extern intmax_t wcstoimax (const __gwchar_t *__restrict __nptr, - __gwchar_t **__restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)); +}; +struct msghdr { + void *msg_name; + socklen_t msg_namelen; -extern uintmax_t wcstoumax (const __gwchar_t *__restrict __nptr, - __gwchar_t ** __restrict __endptr, int __base) - __attribute__ ((__nothrow__ , __leaf__)); + struct iovec *msg_iov; + size_t msg_iovlen; + void *msg_control; + size_t msg_controllen; + int msg_flags; +}; +struct cmsghdr { + size_t cmsg_len; + int cmsg_level; + int cmsg_type; + __extension__ unsigned char __cmsg_data[]; +}; +extern struct cmsghdr *__cmsg_nxthdr(struct msghdr *__mhdr, + struct cmsghdr *__cmsg) + __attribute__((__nothrow__, __leaf__)); +enum { + SCM_RIGHTS = 0x01 + , + SCM_CREDENTIALS = 0x02 +}; +struct ucred { + pid_t pid; + uid_t uid; + gid_t gid; +}; +struct linger { + int l_onoff; + int l_linger; +}; -typedef __socklen_t socklen_t; -extern int access (const char *__name, int __type) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +struct osockaddr { + unsigned short int sa_family; + unsigned char sa_data[14]; +}; +enum { + SHUT_RD = 0, + SHUT_WR, + SHUT_RDWR -extern int euidaccess (const char *__name, int __type) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +}; +typedef union { + struct sockaddr *__restrict __sockaddr__; + struct sockaddr_at *__restrict __sockaddr_at__; + struct sockaddr_ax25 *__restrict __sockaddr_ax25__; + struct sockaddr_dl *__restrict __sockaddr_dl__; + struct sockaddr_eon *__restrict __sockaddr_eon__; + struct sockaddr_in *__restrict __sockaddr_in__; + struct sockaddr_in6 *__restrict __sockaddr_in6__; + struct sockaddr_inarp *__restrict __sockaddr_inarp__; + struct sockaddr_ipx *__restrict __sockaddr_ipx__; + struct sockaddr_iso *__restrict __sockaddr_iso__; + struct sockaddr_ns *__restrict __sockaddr_ns__; + struct sockaddr_un *__restrict __sockaddr_un__; + struct sockaddr_x25 *__restrict __sockaddr_x25__; +} __SOCKADDR_ARG __attribute__((__transparent_union__)); + +typedef union { + const struct sockaddr *__restrict __sockaddr__; + const struct sockaddr_at *__restrict __sockaddr_at__; + const struct sockaddr_ax25 *__restrict __sockaddr_ax25__; + const struct sockaddr_dl *__restrict __sockaddr_dl__; + const struct sockaddr_eon *__restrict __sockaddr_eon__; + const struct sockaddr_in *__restrict __sockaddr_in__; + const struct sockaddr_in6 *__restrict __sockaddr_in6__; + const struct sockaddr_inarp *__restrict __sockaddr_inarp__; + const struct sockaddr_ipx *__restrict __sockaddr_ipx__; + const struct sockaddr_iso *__restrict __sockaddr_iso__; + const struct sockaddr_ns *__restrict __sockaddr_ns__; + const struct sockaddr_un *__restrict __sockaddr_un__; + const struct sockaddr_x25 *__restrict __sockaddr_x25__; +} __CONST_SOCKADDR_ARG __attribute__((__transparent_union__)); + +struct mmsghdr { + struct msghdr msg_hdr; + unsigned int msg_len; +}; +extern int socket(int __domain, int __type, int __protocol) + __attribute__((__nothrow__, __leaf__)); -extern int eaccess (const char *__name, int __type) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); +extern int socketpair(int __domain, int __type, int __protocol, int __fds[2]) + __attribute__((__nothrow__, __leaf__)); +extern int bind(int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len) + __attribute__((__nothrow__, __leaf__)); +extern int getsockname(int __fd, __SOCKADDR_ARG __addr, + socklen_t *__restrict __len) + __attribute__((__nothrow__, __leaf__)); +extern int connect(int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len); +extern int getpeername(int __fd, __SOCKADDR_ARG __addr, + socklen_t *__restrict __len) + __attribute__((__nothrow__, __leaf__)); +extern ssize_t send(int __fd, const void *__buf, size_t __n, int __flags); +extern ssize_t recv(int __fd, void *__buf, size_t __n, int __flags); -extern int faccessat (int __fd, const char *__file, int __type, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))) ; -extern __off_t lseek (int __fd, __off_t __offset, int __whence) __attribute__ ((__nothrow__ , __leaf__)); -extern __off64_t lseek64 (int __fd, __off64_t __offset, int __whence) - __attribute__ ((__nothrow__ , __leaf__)); +extern ssize_t sendto(int __fd, const void *__buf, size_t __n, int __flags, + __CONST_SOCKADDR_ARG __addr, socklen_t __addr_len); +extern ssize_t recvfrom(int __fd, void *__restrict __buf, size_t __n, + int __flags, __SOCKADDR_ARG __addr, + socklen_t *__restrict __addr_len); +extern ssize_t sendmsg(int __fd, const struct msghdr *__message, int __flags); +extern int sendmmsg(int __fd, struct mmsghdr *__vmessages, unsigned int __vlen, + int __flags); +extern ssize_t recvmsg(int __fd, struct msghdr *__message, int __flags); +extern int recvmmsg(int __fd, struct mmsghdr *__vmessages, unsigned int __vlen, + int __flags, struct timespec *__tmo); +extern int getsockopt(int __fd, int __level, int __optname, + void *__restrict __optval, socklen_t *__restrict __optlen) + __attribute__((__nothrow__, __leaf__)); -extern int close (int __fd); +extern int setsockopt(int __fd, int __level, int __optname, + const void *__optval, socklen_t __optlen) + __attribute__((__nothrow__, __leaf__)); +extern int listen(int __fd, int __n) __attribute__((__nothrow__, __leaf__)); +extern int accept(int __fd, __SOCKADDR_ARG __addr, + socklen_t *__restrict __addr_len); +extern int accept4(int __fd, __SOCKADDR_ARG __addr, + socklen_t *__restrict __addr_len, int __flags); +extern int shutdown(int __fd, int __how) __attribute__((__nothrow__, __leaf__)); +extern int sockatmark(int __fd) __attribute__((__nothrow__, __leaf__)); +extern int isfdtype(int __fd, int __fdtype) + __attribute__((__nothrow__, __leaf__)); +extern ssize_t readv(int __fd, const struct iovec *__iovec, int __count); +extern ssize_t writev(int __fd, const struct iovec *__iovec, int __count); +extern ssize_t preadv(int __fd, const struct iovec *__iovec, int __count, + __off_t __offset); +extern ssize_t pwritev(int __fd, const struct iovec *__iovec, int __count, + __off_t __offset); +extern ssize_t preadv64(int __fd, const struct iovec *__iovec, int __count, + __off64_t __offset); +extern ssize_t pwritev64(int __fd, const struct iovec *__iovec, int __count, + __off64_t __offset); -extern ssize_t read (int __fd, void *__buf, size_t __nbytes) ; +extern ssize_t preadv2(int __fp, const struct iovec *__iovec, int __count, + __off_t __offset, int ___flags); +extern ssize_t pwritev2(int __fd, const struct iovec *__iodev, int __count, + __off_t __offset, int __flags); +extern ssize_t preadv64v2(int __fp, const struct iovec *__iovec, int __count, + __off64_t __offset, int ___flags); +extern ssize_t pwritev64v2(int __fd, const struct iovec *__iodev, int __count, + __off64_t __offset, int __flags); +extern ssize_t +process_vm_readv(pid_t __pid, const struct iovec *__lvec, + unsigned long int __liovcnt, const struct iovec *__rvec, + unsigned long int __riovcnt, unsigned long int __flags) + __attribute__((__nothrow__, __leaf__)); +extern ssize_t +process_vm_writev(pid_t __pid, const struct iovec *__lvec, + unsigned long int __liovcnt, const struct iovec *__rvec, + unsigned long int __riovcnt, unsigned long int __flags) + __attribute__((__nothrow__, __leaf__)); -extern ssize_t write (int __fd, const void *__buf, size_t __n) ; -extern ssize_t pread (int __fd, void *__buf, size_t __nbytes, - __off_t __offset) ; +typedef enum { + NoValue = 0x0000, - - - - -extern ssize_t pwrite (int __fd, const void *__buf, size_t __n, - __off_t __offset) ; -extern ssize_t pread64 (int __fd, void *__buf, size_t __nbytes, - __off64_t __offset) ; - - -extern ssize_t pwrite64 (int __fd, const void *__buf, size_t __n, - __off64_t __offset) ; - - - - - - - -extern int pipe (int __pipedes[2]) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int pipe2 (int __pipedes[2], int __flags) __attribute__ ((__nothrow__ , __leaf__)) ; -extern unsigned int alarm (unsigned int __seconds) __attribute__ ((__nothrow__ , __leaf__)); -extern unsigned int sleep (unsigned int __seconds); - - - - - - - -extern __useconds_t ualarm (__useconds_t __value, __useconds_t __interval) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int usleep (__useconds_t __useconds); -extern int pause (void); - - - -extern int chown (const char *__file, __uid_t __owner, __gid_t __group) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - -extern int fchown (int __fd, __uid_t __owner, __gid_t __group) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int lchown (const char *__file, __uid_t __owner, __gid_t __group) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - - - - -extern int fchownat (int __fd, const char *__file, __uid_t __owner, - __gid_t __group, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))) ; - - - -extern int chdir (const char *__path) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - -extern int fchdir (int __fd) __attribute__ ((__nothrow__ , __leaf__)) ; -extern char *getcwd (char *__buf, size_t __size) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - -extern char *get_current_dir_name (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern char *getwd (char *__buf) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__)) ; - - - - -extern int dup (int __fd) __attribute__ ((__nothrow__ , __leaf__)) ; - - -extern int dup2 (int __fd, int __fd2) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int dup3 (int __fd, int __fd2, int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern char **__environ; - -extern char **environ; - - - - - -extern int execve (const char *__path, char *const __argv[], - char *const __envp[]) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - -extern int fexecve (int __fd, char *const __argv[], char *const __envp[]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - - -extern int execv (const char *__path, char *const __argv[]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int execle (const char *__path, const char *__arg, ...) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int execl (const char *__path, const char *__arg, ...) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int execvp (const char *__file, char *const __argv[]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - -extern int execlp (const char *__file, const char *__arg, ...) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - -extern int execvpe (const char *__file, char *const __argv[], - char *const __envp[]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - - -extern int nice (int __inc) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern void _exit (int __status) __attribute__ ((__noreturn__)); - - - - - -enum - { - _PC_LINK_MAX, - - _PC_MAX_CANON, - - _PC_MAX_INPUT, - - _PC_NAME_MAX, - - _PC_PATH_MAX, - - _PC_PIPE_BUF, - - _PC_CHOWN_RESTRICTED, - - _PC_NO_TRUNC, - - _PC_VDISABLE, - - _PC_SYNC_IO, - - _PC_ASYNC_IO, - - _PC_PRIO_IO, - - _PC_SOCK_MAXBUF, - - _PC_FILESIZEBITS, - - _PC_REC_INCR_XFER_SIZE, - - _PC_REC_MAX_XFER_SIZE, - - _PC_REC_MIN_XFER_SIZE, - - _PC_REC_XFER_ALIGN, - - _PC_ALLOC_SIZE_MIN, - - _PC_SYMLINK_MAX, - - _PC_2_SYMLINKS - - }; - - -enum - { - _SC_ARG_MAX, - - _SC_CHILD_MAX, - - _SC_CLK_TCK, - - _SC_NGROUPS_MAX, - - _SC_OPEN_MAX, - - _SC_STREAM_MAX, - - _SC_TZNAME_MAX, - - _SC_JOB_CONTROL, - - _SC_SAVED_IDS, - - _SC_REALTIME_SIGNALS, - - _SC_PRIORITY_SCHEDULING, - - _SC_TIMERS, - - _SC_ASYNCHRONOUS_IO, - - _SC_PRIORITIZED_IO, - - _SC_SYNCHRONIZED_IO, - - _SC_FSYNC, - - _SC_MAPPED_FILES, - - _SC_MEMLOCK, - - _SC_MEMLOCK_RANGE, - - _SC_MEMORY_PROTECTION, - - _SC_MESSAGE_PASSING, - - _SC_SEMAPHORES, - - _SC_SHARED_MEMORY_OBJECTS, - - _SC_AIO_LISTIO_MAX, - - _SC_AIO_MAX, - - _SC_AIO_PRIO_DELTA_MAX, - - _SC_DELAYTIMER_MAX, - - _SC_MQ_OPEN_MAX, - - _SC_MQ_PRIO_MAX, - - _SC_VERSION, - - _SC_PAGESIZE, - - - _SC_RTSIG_MAX, - - _SC_SEM_NSEMS_MAX, - - _SC_SEM_VALUE_MAX, - - _SC_SIGQUEUE_MAX, - - _SC_TIMER_MAX, - - - - - _SC_BC_BASE_MAX, - - _SC_BC_DIM_MAX, - - _SC_BC_SCALE_MAX, - - _SC_BC_STRING_MAX, - - _SC_COLL_WEIGHTS_MAX, - - _SC_EQUIV_CLASS_MAX, - - _SC_EXPR_NEST_MAX, - - _SC_LINE_MAX, - - _SC_RE_DUP_MAX, - - _SC_CHARCLASS_NAME_MAX, - - - _SC_2_VERSION, - - _SC_2_C_BIND, - - _SC_2_C_DEV, - - _SC_2_FORT_DEV, - - _SC_2_FORT_RUN, - - _SC_2_SW_DEV, - - _SC_2_LOCALEDEF, - - - _SC_PII, - - _SC_PII_XTI, - - _SC_PII_SOCKET, - - _SC_PII_INTERNET, - - _SC_PII_OSI, - - _SC_POLL, - - _SC_SELECT, - - _SC_UIO_MAXIOV, - - _SC_IOV_MAX = _SC_UIO_MAXIOV, - - _SC_PII_INTERNET_STREAM, - - _SC_PII_INTERNET_DGRAM, - - _SC_PII_OSI_COTS, - - _SC_PII_OSI_CLTS, - - _SC_PII_OSI_M, - - _SC_T_IOV_MAX, - - - - _SC_THREADS, - - _SC_THREAD_SAFE_FUNCTIONS, - - _SC_GETGR_R_SIZE_MAX, - - _SC_GETPW_R_SIZE_MAX, - - _SC_LOGIN_NAME_MAX, - - _SC_TTY_NAME_MAX, - - _SC_THREAD_DESTRUCTOR_ITERATIONS, - - _SC_THREAD_KEYS_MAX, - - _SC_THREAD_STACK_MIN, - - _SC_THREAD_THREADS_MAX, - - _SC_THREAD_ATTR_STACKADDR, - - _SC_THREAD_ATTR_STACKSIZE, - - _SC_THREAD_PRIORITY_SCHEDULING, - - _SC_THREAD_PRIO_INHERIT, - - _SC_THREAD_PRIO_PROTECT, - - _SC_THREAD_PROCESS_SHARED, - - - _SC_NPROCESSORS_CONF, - - _SC_NPROCESSORS_ONLN, - - _SC_PHYS_PAGES, - - _SC_AVPHYS_PAGES, - - _SC_ATEXIT_MAX, - - _SC_PASS_MAX, - - - _SC_XOPEN_VERSION, - - _SC_XOPEN_XCU_VERSION, - - _SC_XOPEN_UNIX, - - _SC_XOPEN_CRYPT, - - _SC_XOPEN_ENH_I18N, - - _SC_XOPEN_SHM, - - - _SC_2_CHAR_TERM, - - _SC_2_C_VERSION, - - _SC_2_UPE, - - - _SC_XOPEN_XPG2, - - _SC_XOPEN_XPG3, - - _SC_XOPEN_XPG4, - - - _SC_CHAR_BIT, - - _SC_CHAR_MAX, - - _SC_CHAR_MIN, - - _SC_INT_MAX, - - _SC_INT_MIN, - - _SC_LONG_BIT, - - _SC_WORD_BIT, - - _SC_MB_LEN_MAX, - - _SC_NZERO, - - _SC_SSIZE_MAX, - - _SC_SCHAR_MAX, - - _SC_SCHAR_MIN, - - _SC_SHRT_MAX, - - _SC_SHRT_MIN, - - _SC_UCHAR_MAX, - - _SC_UINT_MAX, - - _SC_ULONG_MAX, - - _SC_USHRT_MAX, - - - _SC_NL_ARGMAX, - - _SC_NL_LANGMAX, - - _SC_NL_MSGMAX, - - _SC_NL_NMAX, - - _SC_NL_SETMAX, - - _SC_NL_TEXTMAX, - - - _SC_XBS5_ILP32_OFF32, - - _SC_XBS5_ILP32_OFFBIG, - - _SC_XBS5_LP64_OFF64, - - _SC_XBS5_LPBIG_OFFBIG, - - - _SC_XOPEN_LEGACY, - - _SC_XOPEN_REALTIME, - - _SC_XOPEN_REALTIME_THREADS, - - - _SC_ADVISORY_INFO, - - _SC_BARRIERS, - - _SC_BASE, - - _SC_C_LANG_SUPPORT, - - _SC_C_LANG_SUPPORT_R, - - _SC_CLOCK_SELECTION, - - _SC_CPUTIME, - - _SC_THREAD_CPUTIME, - - _SC_DEVICE_IO, - - _SC_DEVICE_SPECIFIC, - - _SC_DEVICE_SPECIFIC_R, - - _SC_FD_MGMT, - - _SC_FIFO, - - _SC_PIPE, - - _SC_FILE_ATTRIBUTES, - - _SC_FILE_LOCKING, - - _SC_FILE_SYSTEM, - - _SC_MONOTONIC_CLOCK, - - _SC_MULTI_PROCESS, - - _SC_SINGLE_PROCESS, - - _SC_NETWORKING, - - _SC_READER_WRITER_LOCKS, - - _SC_SPIN_LOCKS, - - _SC_REGEXP, - - _SC_REGEX_VERSION, - - _SC_SHELL, - - _SC_SIGNALS, - - _SC_SPAWN, - - _SC_SPORADIC_SERVER, - - _SC_THREAD_SPORADIC_SERVER, - - _SC_SYSTEM_DATABASE, - - _SC_SYSTEM_DATABASE_R, - - _SC_TIMEOUTS, - - _SC_TYPED_MEMORY_OBJECTS, - - _SC_USER_GROUPS, - - _SC_USER_GROUPS_R, - - _SC_2_PBS, - - _SC_2_PBS_ACCOUNTING, - - _SC_2_PBS_LOCATE, - - _SC_2_PBS_MESSAGE, - - _SC_2_PBS_TRACK, - - _SC_SYMLOOP_MAX, - - _SC_STREAMS, - - _SC_2_PBS_CHECKPOINT, - - - _SC_V6_ILP32_OFF32, - - _SC_V6_ILP32_OFFBIG, - - _SC_V6_LP64_OFF64, - - _SC_V6_LPBIG_OFFBIG, - - - _SC_HOST_NAME_MAX, - - _SC_TRACE, - - _SC_TRACE_EVENT_FILTER, - - _SC_TRACE_INHERIT, - - _SC_TRACE_LOG, - - - _SC_LEVEL1_ICACHE_SIZE, - - _SC_LEVEL1_ICACHE_ASSOC, - - _SC_LEVEL1_ICACHE_LINESIZE, - - _SC_LEVEL1_DCACHE_SIZE, - - _SC_LEVEL1_DCACHE_ASSOC, - - _SC_LEVEL1_DCACHE_LINESIZE, - - _SC_LEVEL2_CACHE_SIZE, - - _SC_LEVEL2_CACHE_ASSOC, - - _SC_LEVEL2_CACHE_LINESIZE, - - _SC_LEVEL3_CACHE_SIZE, - - _SC_LEVEL3_CACHE_ASSOC, - - _SC_LEVEL3_CACHE_LINESIZE, - - _SC_LEVEL4_CACHE_SIZE, - - _SC_LEVEL4_CACHE_ASSOC, - - _SC_LEVEL4_CACHE_LINESIZE, - - - - _SC_IPV6 = _SC_LEVEL1_ICACHE_SIZE + 50, - - _SC_RAW_SOCKETS, - - - _SC_V7_ILP32_OFF32, - - _SC_V7_ILP32_OFFBIG, - - _SC_V7_LP64_OFF64, - - _SC_V7_LPBIG_OFFBIG, - - - _SC_SS_REPL_MAX, - - - _SC_TRACE_EVENT_NAME_MAX, - - _SC_TRACE_NAME_MAX, - - _SC_TRACE_SYS_MAX, - - _SC_TRACE_USER_EVENT_MAX, - - - _SC_XOPEN_STREAMS, - - - _SC_THREAD_ROBUST_PRIO_INHERIT, - - _SC_THREAD_ROBUST_PRIO_PROTECT - - }; - - -enum - { - _CS_PATH, - - - _CS_V6_WIDTH_RESTRICTED_ENVS, - - - - _CS_GNU_LIBC_VERSION, - - _CS_GNU_LIBPTHREAD_VERSION, - - - _CS_V5_WIDTH_RESTRICTED_ENVS, - - - - _CS_V7_WIDTH_RESTRICTED_ENVS, - - - - _CS_LFS_CFLAGS = 1000, - - _CS_LFS_LDFLAGS, - - _CS_LFS_LIBS, - - _CS_LFS_LINTFLAGS, - - _CS_LFS64_CFLAGS, - - _CS_LFS64_LDFLAGS, - - _CS_LFS64_LIBS, - - _CS_LFS64_LINTFLAGS, - - - _CS_XBS5_ILP32_OFF32_CFLAGS = 1100, - - _CS_XBS5_ILP32_OFF32_LDFLAGS, - - _CS_XBS5_ILP32_OFF32_LIBS, - - _CS_XBS5_ILP32_OFF32_LINTFLAGS, - - _CS_XBS5_ILP32_OFFBIG_CFLAGS, - - _CS_XBS5_ILP32_OFFBIG_LDFLAGS, - - _CS_XBS5_ILP32_OFFBIG_LIBS, - - _CS_XBS5_ILP32_OFFBIG_LINTFLAGS, - - _CS_XBS5_LP64_OFF64_CFLAGS, - - _CS_XBS5_LP64_OFF64_LDFLAGS, - - _CS_XBS5_LP64_OFF64_LIBS, - - _CS_XBS5_LP64_OFF64_LINTFLAGS, - - _CS_XBS5_LPBIG_OFFBIG_CFLAGS, - - _CS_XBS5_LPBIG_OFFBIG_LDFLAGS, - - _CS_XBS5_LPBIG_OFFBIG_LIBS, - - _CS_XBS5_LPBIG_OFFBIG_LINTFLAGS, - - - _CS_POSIX_V6_ILP32_OFF32_CFLAGS, - - _CS_POSIX_V6_ILP32_OFF32_LDFLAGS, - - _CS_POSIX_V6_ILP32_OFF32_LIBS, - - _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS, - - _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS, - - _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS, - - _CS_POSIX_V6_ILP32_OFFBIG_LIBS, - - _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS, - - _CS_POSIX_V6_LP64_OFF64_CFLAGS, - - _CS_POSIX_V6_LP64_OFF64_LDFLAGS, - - _CS_POSIX_V6_LP64_OFF64_LIBS, - - _CS_POSIX_V6_LP64_OFF64_LINTFLAGS, - - _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS, - - _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS, - - _CS_POSIX_V6_LPBIG_OFFBIG_LIBS, - - _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS, - - - _CS_POSIX_V7_ILP32_OFF32_CFLAGS, - - _CS_POSIX_V7_ILP32_OFF32_LDFLAGS, - - _CS_POSIX_V7_ILP32_OFF32_LIBS, - - _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS, - - _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS, - - _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS, - - _CS_POSIX_V7_ILP32_OFFBIG_LIBS, - - _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS, - - _CS_POSIX_V7_LP64_OFF64_CFLAGS, - - _CS_POSIX_V7_LP64_OFF64_LDFLAGS, - - _CS_POSIX_V7_LP64_OFF64_LIBS, - - _CS_POSIX_V7_LP64_OFF64_LINTFLAGS, - - _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS, - - _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS, - - _CS_POSIX_V7_LPBIG_OFFBIG_LIBS, - - _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS, - - - _CS_V6_ENV, - - _CS_V7_ENV - - }; - - -extern long int pathconf (const char *__path, int __name) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern long int fpathconf (int __fd, int __name) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long int sysconf (int __name) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern size_t confstr (int __name, char *__buf, size_t __len) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern __pid_t getpid (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __pid_t getppid (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __pid_t getpgrp (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __pid_t __getpgid (__pid_t __pid) __attribute__ ((__nothrow__ , __leaf__)); - -extern __pid_t getpgid (__pid_t __pid) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int setpgid (__pid_t __pid, __pid_t __pgid) __attribute__ ((__nothrow__ , __leaf__)); -extern int setpgrp (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern __pid_t setsid (void) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern __pid_t getsid (__pid_t __pid) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern __uid_t getuid (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __uid_t geteuid (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __gid_t getgid (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __gid_t getegid (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int getgroups (int __size, __gid_t __list[]) __attribute__ ((__nothrow__ , __leaf__)) ; - - - -extern int group_member (__gid_t __gid) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int setuid (__uid_t __uid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int setreuid (__uid_t __ruid, __uid_t __euid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int seteuid (__uid_t __uid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - - -extern int setgid (__gid_t __gid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int setregid (__gid_t __rgid, __gid_t __egid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int setegid (__gid_t __gid) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - -extern int getresuid (__uid_t *__ruid, __uid_t *__euid, __uid_t *__suid) - __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int getresgid (__gid_t *__rgid, __gid_t *__egid, __gid_t *__sgid) - __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int setresuid (__uid_t __ruid, __uid_t __euid, __uid_t __suid) - __attribute__ ((__nothrow__ , __leaf__)) ; - - - -extern int setresgid (__gid_t __rgid, __gid_t __egid, __gid_t __sgid) - __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - - -extern __pid_t fork (void) __attribute__ ((__nothrow__)); - - - - - - - -extern __pid_t vfork (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern char *ttyname (int __fd) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ttyname_r (int __fd, char *__buf, size_t __buflen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))) ; - - - -extern int isatty (int __fd) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int ttyslot (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int link (const char *__from, const char *__to) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))) ; - - - - -extern int linkat (int __fromfd, const char *__from, int __tofd, - const char *__to, int __flags) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))) ; - - - - -extern int symlink (const char *__from, const char *__to) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))) ; - - - - -extern ssize_t readlink (const char *__restrict __path, - char *__restrict __buf, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))) ; - - - - -extern int symlinkat (const char *__from, int __tofd, - const char *__to) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))) ; - - -extern ssize_t readlinkat (int __fd, const char *__restrict __path, - char *__restrict __buf, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))) ; - - - -extern int unlink (const char *__name) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int unlinkat (int __fd, const char *__name, int __flag) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern int rmdir (const char *__path) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern __pid_t tcgetpgrp (int __fd) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int tcsetpgrp (int __fd, __pid_t __pgrp_id) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern char *getlogin (void); - - - - - - - -extern int getlogin_r (char *__name, size_t __name_len) __attribute__ ((__nonnull__ (1))); - - - - -extern int setlogin (const char *__name) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - - - - - - - - - - - -extern char *optarg; -extern int optind; - - - - -extern int opterr; - - - -extern int optopt; -extern int getopt (int ___argc, char *const *___argv, const char *__shortopts) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); - - - - - - - - - - - - -extern int gethostname (char *__name, size_t __len) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - - -extern int sethostname (const char *__name, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - -extern int sethostid (long int __id) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - -extern int getdomainname (char *__name, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern int setdomainname (const char *__name, size_t __len) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - - - -extern int vhangup (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int revoke (const char *__file) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - - - - - -extern int profil (unsigned short int *__sample_buffer, size_t __size, - size_t __offset, unsigned int __scale) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - -extern int acct (const char *__name) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern char *getusershell (void) __attribute__ ((__nothrow__ , __leaf__)); -extern void endusershell (void) __attribute__ ((__nothrow__ , __leaf__)); -extern void setusershell (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int daemon (int __nochdir, int __noclose) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - - -extern int chroot (const char *__path) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; - - - -extern char *getpass (const char *__prompt) __attribute__ ((__nonnull__ (1))); - - - - - - - -extern int fsync (int __fd); - - - - - -extern int syncfs (int __fd) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int gethostid (void); - - -extern void sync (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int getpagesize (void) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern int getdtablesize (void) __attribute__ ((__nothrow__ , __leaf__)); -extern int truncate (const char *__file, __off_t __length) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern int truncate64 (const char *__file, __off64_t __length) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) ; -extern int ftruncate (int __fd, __off_t __length) __attribute__ ((__nothrow__ , __leaf__)) ; -extern int ftruncate64 (int __fd, __off64_t __length) __attribute__ ((__nothrow__ , __leaf__)) ; -extern int brk (void *__addr) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - - -extern void *sbrk (intptr_t __delta) __attribute__ ((__nothrow__ , __leaf__)); -extern long int syscall (long int __sysno, ...) __attribute__ ((__nothrow__ , __leaf__)); -extern int lockf (int __fd, int __cmd, __off_t __len) ; -extern int lockf64 (int __fd, int __cmd, __off64_t __len) ; -ssize_t copy_file_range (int __infd, __off64_t *__pinoff, - int __outfd, __off64_t *__poutoff, - size_t __length, unsigned int __flags); - - - - - -extern int fdatasync (int __fildes); -extern char *crypt (const char *__key, const char *__salt) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - - - - -extern void swab (const void *__restrict __from, void *__restrict __to, - ssize_t __n) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); -int getentropy (void *__buffer, size_t __length) ; -extern __pid_t gettid (void) __attribute__ ((__nothrow__ , __leaf__)); - - - -enum -{ - _ISupper = ((0) < 8 ? ((1 << (0)) << 8) : ((1 << (0)) >> 8)), - _ISlower = ((1) < 8 ? ((1 << (1)) << 8) : ((1 << (1)) >> 8)), - _ISalpha = ((2) < 8 ? ((1 << (2)) << 8) : ((1 << (2)) >> 8)), - _ISdigit = ((3) < 8 ? ((1 << (3)) << 8) : ((1 << (3)) >> 8)), - _ISxdigit = ((4) < 8 ? ((1 << (4)) << 8) : ((1 << (4)) >> 8)), - _ISspace = ((5) < 8 ? ((1 << (5)) << 8) : ((1 << (5)) >> 8)), - _ISprint = ((6) < 8 ? ((1 << (6)) << 8) : ((1 << (6)) >> 8)), - _ISgraph = ((7) < 8 ? ((1 << (7)) << 8) : ((1 << (7)) >> 8)), - _ISblank = ((8) < 8 ? ((1 << (8)) << 8) : ((1 << (8)) >> 8)), - _IScntrl = ((9) < 8 ? ((1 << (9)) << 8) : ((1 << (9)) >> 8)), - _ISpunct = ((10) < 8 ? ((1 << (10)) << 8) : ((1 << (10)) >> 8)), - _ISalnum = ((11) < 8 ? ((1 << (11)) << 8) : ((1 << (11)) >> 8)) -}; -extern const unsigned short int **__ctype_b_loc (void) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); -extern const __int32_t **__ctype_tolower_loc (void) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); -extern const __int32_t **__ctype_toupper_loc (void) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); -extern int isalnum (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isalpha (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int iscntrl (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isdigit (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int islower (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isgraph (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isprint (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int ispunct (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isspace (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isupper (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isxdigit (int) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int tolower (int __c) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int toupper (int __c) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int isblank (int) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int isctype (int __c, int __mask) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int isascii (int __c) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int toascii (int __c) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int _toupper (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int _tolower (int) __attribute__ ((__nothrow__ , __leaf__)); -extern int isalnum_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isalpha_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int iscntrl_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isdigit_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int islower_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isgraph_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isprint_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int ispunct_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isspace_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isupper_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); -extern int isxdigit_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); - -extern int isblank_l (int, locale_t) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int __tolower_l (int __c, locale_t __l) __attribute__ ((__nothrow__ , __leaf__)); -extern int tolower_l (int __c, locale_t __l) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int __toupper_l (int __c, locale_t __l) __attribute__ ((__nothrow__ , __leaf__)); -extern int toupper_l (int __c, locale_t __l) __attribute__ ((__nothrow__ , __leaf__)); - - - -struct lconv -{ - - - char *decimal_point; - char *thousands_sep; - - - - - - char *grouping; - - - - - - char *int_curr_symbol; - char *currency_symbol; - char *mon_decimal_point; - char *mon_thousands_sep; - char *mon_grouping; - char *positive_sign; - char *negative_sign; - char int_frac_digits; - char frac_digits; - - char p_cs_precedes; - - char p_sep_by_space; - - char n_cs_precedes; - - char n_sep_by_space; - - - - - - - char p_sign_posn; - char n_sign_posn; - - - char int_p_cs_precedes; - - char int_p_sep_by_space; - - char int_n_cs_precedes; - - char int_n_sep_by_space; - - - - - - - char int_p_sign_posn; - char int_n_sign_posn; -}; - - - -extern char *setlocale (int __category, const char *__locale) __attribute__ ((__nothrow__ , __leaf__)); - - -extern struct lconv *localeconv (void) __attribute__ ((__nothrow__ , __leaf__)); -extern locale_t newlocale (int __category_mask, const char *__locale, - locale_t __base) __attribute__ ((__nothrow__ , __leaf__)); -extern locale_t duplocale (locale_t __dataset) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern void freelocale (locale_t __dataset) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern locale_t uselocale (locale_t __dataset) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - - - - - - - - - - -extern int *__errno_location (void) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - - - - -extern char *program_invocation_name; -extern char *program_invocation_short_name; - -typedef int error_t; - - - - - - - - - - - -struct flock - { - short int l_type; - short int l_whence; - - __off_t l_start; - __off_t l_len; - - - - - __pid_t l_pid; - }; - - -struct flock64 - { - short int l_type; - short int l_whence; - __off64_t l_start; - __off64_t l_len; - __pid_t l_pid; - }; - - - - - -struct iovec - { - void *iov_base; - size_t iov_len; - }; -enum __pid_type - { - F_OWNER_TID = 0, - F_OWNER_PID, - F_OWNER_PGRP, - F_OWNER_GID = F_OWNER_PGRP - }; - - -struct f_owner_ex - { - enum __pid_type type; - __pid_t pid; - }; - - - -struct file_handle -{ - unsigned int handle_bytes; - int handle_type; - - unsigned char f_handle[0]; -}; - - - - - - - - - - -extern __ssize_t readahead (int __fd, __off64_t __offset, size_t __count) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int sync_file_range (int __fd, __off64_t __offset, __off64_t __count, - unsigned int __flags); - - - - - - -extern __ssize_t vmsplice (int __fdout, const struct iovec *__iov, - size_t __count, unsigned int __flags); - - - - - -extern __ssize_t splice (int __fdin, __off64_t *__offin, int __fdout, - __off64_t *__offout, size_t __len, - unsigned int __flags); - - - - - -extern __ssize_t tee (int __fdin, int __fdout, size_t __len, - unsigned int __flags); - - - - - - -extern int fallocate (int __fd, int __mode, __off_t __offset, __off_t __len); -extern int fallocate64 (int __fd, int __mode, __off64_t __offset, - __off64_t __len); - - - - -extern int name_to_handle_at (int __dfd, const char *__name, - struct file_handle *__handle, int *__mnt_id, - int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int open_by_handle_at (int __mountdirfd, struct file_handle *__handle, - int __flags); - - - - -extern int fcntl (int __fd, int __cmd, ...); -extern int fcntl64 (int __fd, int __cmd, ...); -extern int open (const char *__file, int __oflag, ...) __attribute__ ((__nonnull__ (1))); -extern int open64 (const char *__file, int __oflag, ...) __attribute__ ((__nonnull__ (1))); -extern int openat (int __fd, const char *__file, int __oflag, ...) - __attribute__ ((__nonnull__ (2))); -extern int openat64 (int __fd, const char *__file, int __oflag, ...) - __attribute__ ((__nonnull__ (2))); -extern int creat (const char *__file, mode_t __mode) __attribute__ ((__nonnull__ (1))); -extern int creat64 (const char *__file, mode_t __mode) __attribute__ ((__nonnull__ (1))); -extern int posix_fadvise (int __fd, off_t __offset, off_t __len, - int __advise) __attribute__ ((__nothrow__ , __leaf__)); -extern int posix_fadvise64 (int __fd, off64_t __offset, off64_t __len, - int __advise) __attribute__ ((__nothrow__ , __leaf__)); -extern int posix_fallocate (int __fd, off_t __offset, off_t __len); -extern int posix_fallocate64 (int __fd, off64_t __offset, off64_t __len); - - - - - - - - - - - - - -typedef float float_t; -typedef double double_t; - - - -enum - { - FP_INT_UPWARD = - - 0, - FP_INT_DOWNWARD = - - 1, - FP_INT_TOWARDZERO = - - 2, - FP_INT_TONEARESTFROMZERO = - - 3, - FP_INT_TONEAREST = - - 4, - }; -extern int __fpclassify (double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - -extern int __signbit (double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - - -extern int __isinf (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __finite (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __isnan (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __iseqsig (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int __issignaling (double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); -extern double acos (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __acos (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double asin (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __asin (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double atan (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __atan (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double atan2 (double __y, double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __atan2 (double __y, double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern double cos (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __cos (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern double sin (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __sin (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double tan (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __tan (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double cosh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __cosh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double sinh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __sinh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double tanh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __tanh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincos (double __x, double *__sinx, double *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincos (double __x, double *__sinx, double *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern double acosh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __acosh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double asinh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __asinh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double atanh (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __atanh (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern double exp (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __exp (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double frexp (double __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern double __frexp (double __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double ldexp (double __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern double __ldexp (double __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern double log (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __log (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double log10 (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __log10 (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double modf (double __x, double *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern double __modf (double __x, double *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern double exp10 (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __exp10 (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double expm1 (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __expm1 (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double log1p (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __log1p (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double logb (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __logb (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double exp2 (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __exp2 (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double log2 (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __log2 (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern double pow (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __pow (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double sqrt (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __sqrt (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double hypot (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __hypot (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double cbrt (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __cbrt (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern double ceil (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __ceil (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double fabs (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __fabs (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double floor (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __floor (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double fmod (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __fmod (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); -extern int isinf (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern int finite (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double drem (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __drem (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double significand (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __significand (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern double copysign (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __copysign (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern double nan (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern double __nan (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern int isnan (double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - - -extern double j0 (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __j0 (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double j1 (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __j1 (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double jn (int, double) __attribute__ ((__nothrow__ , __leaf__)); extern double __jn (int, double) __attribute__ ((__nothrow__ , __leaf__)); -extern double y0 (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __y0 (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double y1 (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __y1 (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double yn (int, double) __attribute__ ((__nothrow__ , __leaf__)); extern double __yn (int, double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern double erf (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __erf (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double erfc (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __erfc (double) __attribute__ ((__nothrow__ , __leaf__)); -extern double lgamma (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __lgamma (double) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double tgamma (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __tgamma (double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern double gamma (double) __attribute__ ((__nothrow__ , __leaf__)); extern double __gamma (double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern double lgamma_r (double, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern double __lgamma_r (double, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern double rint (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __rint (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double nextafter (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __nextafter (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - -extern double nexttoward (double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __nexttoward (double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double nextdown (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __nextdown (double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern double nextup (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __nextup (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double remainder (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __remainder (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double scalbn (double __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern double __scalbn (double __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogb (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogb (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogb (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogb (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double scalbln (double __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern double __scalbln (double __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double nearbyint (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern double __nearbyint (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double round (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __round (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern double trunc (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __trunc (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern double remquo (double __x, double __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern double __remquo (double __x, double __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrint (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrint (double __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrint (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrint (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lround (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lround (double __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llround (double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llround (double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern double fdim (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); extern double __fdim (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double fmax (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __fmax (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double fmin (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __fmin (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double fma (double __x, double __y, double __z) __attribute__ ((__nothrow__ , __leaf__)); extern double __fma (double __x, double __y, double __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern double roundeven (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __roundeven (double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfp (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfp (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfp (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfp (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpx (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpx (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpx (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpx (double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern double fmaxmag (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __fmaxmag (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern double fminmag (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern double __fminmag (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalize (double *__cx, const double *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorder (const double *__x, const double *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermag (const double *__x, const double *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern double getpayload (const double *__x) __attribute__ ((__nothrow__ , __leaf__)); extern double __getpayload (const double *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayload (double *__x, double __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsig (double *__x, double __payload) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern double scalb (double __x, double __n) __attribute__ ((__nothrow__ , __leaf__)); extern double __scalb (double __x, double __n) __attribute__ ((__nothrow__ , __leaf__)); -extern int __fpclassifyf (float __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - -extern int __signbitf (float __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - - -extern int __isinff (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __finitef (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __isnanf (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __iseqsigf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int __issignalingf (float __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); -extern float acosf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __acosf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float asinf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __asinf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float atanf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __atanf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float atan2f (float __y, float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __atan2f (float __y, float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern float cosf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __cosf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern float sinf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __sinf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float tanf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __tanf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float coshf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __coshf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float sinhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __sinhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float tanhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __tanhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf (float __x, float *__sinx, float *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf (float __x, float *__sinx, float *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern float acoshf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __acoshf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float asinhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __asinhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float atanhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __atanhf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern float expf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __expf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float frexpf (float __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern float __frexpf (float __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float ldexpf (float __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern float __ldexpf (float __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern float logf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __logf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float log10f (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __log10f (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float modff (float __x, float *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern float __modff (float __x, float *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern float exp10f (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __exp10f (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float expm1f (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __expm1f (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float log1pf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __log1pf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float logbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __logbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float exp2f (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __exp2f (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float log2f (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __log2f (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern float powf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __powf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float sqrtf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __sqrtf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float hypotf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __hypotf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float cbrtf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __cbrtf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern float ceilf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __ceilf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float fabsf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __fabsf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float floorf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __floorf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float fmodf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __fmodf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); -extern int isinff (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern int finitef (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float dremf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __dremf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float significandf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __significandf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern float copysignf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __copysignf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern float nanf (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern float __nanf (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern int isnanf (float __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - - -extern float j0f (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __j0f (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float j1f (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __j1f (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float jnf (int, float) __attribute__ ((__nothrow__ , __leaf__)); extern float __jnf (int, float) __attribute__ ((__nothrow__ , __leaf__)); -extern float y0f (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __y0f (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float y1f (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __y1f (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float ynf (int, float) __attribute__ ((__nothrow__ , __leaf__)); extern float __ynf (int, float) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern float erff (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __erff (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float erfcf (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __erfcf (float) __attribute__ ((__nothrow__ , __leaf__)); -extern float lgammaf (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __lgammaf (float) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float tgammaf (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __tgammaf (float) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern float gammaf (float) __attribute__ ((__nothrow__ , __leaf__)); extern float __gammaf (float) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern float lgammaf_r (float, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern float __lgammaf_r (float, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern float rintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __rintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float nextafterf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __nextafterf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - -extern float nexttowardf (float __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __nexttowardf (float __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float nextdownf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __nextdownf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern float nextupf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __nextupf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float remainderf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __remainderf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float scalbnf (float __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern float __scalbnf (float __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float scalblnf (float __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern float __scalblnf (float __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float nearbyintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern float __nearbyintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float roundf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __roundf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern float truncf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __truncf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern float remquof (float __x, float __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern float __remquof (float __x, float __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf (float __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf (float __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf (float __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern float fdimf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); extern float __fdimf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fmaxf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __fmaxf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float fminf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __fminf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float fmaf (float __x, float __y, float __z) __attribute__ ((__nothrow__ , __leaf__)); extern float __fmaf (float __x, float __y, float __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern float roundevenf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __roundevenf (float __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf (float __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern float fmaxmagf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __fmaxmagf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern float fminmagf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern float __fminmagf (float __x, float __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef (float *__cx, const float *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf (const float *__x, const float *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf (const float *__x, const float *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern float getpayloadf (const float *__x) __attribute__ ((__nothrow__ , __leaf__)); extern float __getpayloadf (const float *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf (float *__x, float __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf (float *__x, float __payload) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern float scalbf (float __x, float __n) __attribute__ ((__nothrow__ , __leaf__)); extern float __scalbf (float __x, float __n) __attribute__ ((__nothrow__ , __leaf__)); -extern int __fpclassifyl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - -extern int __signbitl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - - -extern int __isinfl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __finitel (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __isnanl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __iseqsigl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int __issignalingl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); -extern long double acosl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __acosl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double asinl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __asinl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double atanl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __atanl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double atan2l (long double __y, long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __atan2l (long double __y, long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern long double cosl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __cosl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern long double sinl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __sinl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double tanl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __tanl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double coshl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __coshl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double sinhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __sinhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double tanhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __tanhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosl (long double __x, long double *__sinx, long double *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosl (long double __x, long double *__sinx, long double *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern long double acoshl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __acoshl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double asinhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __asinhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double atanhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __atanhl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern long double expl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __expl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double frexpl (long double __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern long double __frexpl (long double __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double ldexpl (long double __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern long double __ldexpl (long double __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern long double logl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __logl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double log10l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __log10l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double modfl (long double __x, long double *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern long double __modfl (long double __x, long double *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern long double exp10l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __exp10l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double expm1l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __expm1l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double log1pl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __log1pl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double logbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __logbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double exp2l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __exp2l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double log2l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __log2l (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern long double powl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __powl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double sqrtl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __sqrtl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double hypotl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __hypotl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double cbrtl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __cbrtl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long double ceill (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __ceill (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double fabsl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __fabsl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double floorl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __floorl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double fmodl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __fmodl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); -extern int isinfl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern int finitel (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double dreml (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __dreml (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double significandl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __significandl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long double copysignl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __copysignl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern long double nanl (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nanl (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern int isnanl (long double __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - - -extern long double j0l (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __j0l (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double j1l (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __j1l (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double jnl (int, long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __jnl (int, long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double y0l (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __y0l (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double y1l (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __y1l (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double ynl (int, long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __ynl (int, long double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern long double erfl (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __erfl (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double erfcl (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __erfcl (long double) __attribute__ ((__nothrow__ , __leaf__)); -extern long double lgammal (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __lgammal (long double) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double tgammal (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __tgammal (long double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern long double gammal (long double) __attribute__ ((__nothrow__ , __leaf__)); extern long double __gammal (long double) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern long double lgammal_r (long double, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern long double __lgammal_r (long double, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long double rintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __rintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double nextafterl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nextafterl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double nexttowardl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nexttowardl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double nextdownl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nextdownl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern long double nextupl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nextupl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double remainderl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __remainderl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double scalbnl (long double __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern long double __scalbnl (long double __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double scalblnl (long double __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern long double __scalblnl (long double __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double nearbyintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __nearbyintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double roundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __roundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern long double truncl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __truncl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern long double remquol (long double __x, long double __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern long double __remquol (long double __x, long double __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundl (long double __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long double fdiml (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); extern long double __fdiml (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern long double fmaxl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __fmaxl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double fminl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __fminl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double fmal (long double __x, long double __y, long double __z) __attribute__ ((__nothrow__ , __leaf__)); extern long double __fmal (long double __x, long double __y, long double __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long double roundevenl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __roundevenl (long double __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxl (long double __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern long double fmaxmagl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __fmaxmagl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern long double fminmagl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern long double __fminmagl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizel (long double *__cx, const long double *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderl (const long double *__x, const long double *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagl (const long double *__x, const long double *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern long double getpayloadl (const long double *__x) __attribute__ ((__nothrow__ , __leaf__)); extern long double __getpayloadl (const long double *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadl (long double *__x, long double __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigl (long double *__x, long double __payload) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern long double scalbl (long double __x, long double __n) __attribute__ ((__nothrow__ , __leaf__)); extern long double __scalbl (long double __x, long double __n) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 acosf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __acosf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 asinf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __asinf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 atanf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __atanf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 atan2f32 (_Float32 __y, _Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __atan2f32 (_Float32 __y, _Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float32 cosf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __cosf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern _Float32 sinf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __sinf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 tanf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __tanf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 coshf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __coshf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 sinhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __sinhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 tanhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __tanhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf32 (_Float32 __x, _Float32 *__sinx, _Float32 *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf32 (_Float32 __x, _Float32 *__sinx, _Float32 *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern _Float32 acoshf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __acoshf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 asinhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __asinhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 atanhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __atanhf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern _Float32 expf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __expf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 frexpf32 (_Float32 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __frexpf32 (_Float32 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 ldexpf32 (_Float32 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __ldexpf32 (_Float32 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float32 logf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __logf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 log10f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __log10f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 modff32 (_Float32 __x, _Float32 *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __modff32 (_Float32 __x, _Float32 *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern _Float32 exp10f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __exp10f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 expm1f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __expm1f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 log1pf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __log1pf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 logbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __logbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 exp2f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __exp2f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 log2f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __log2f32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern _Float32 powf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __powf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 sqrtf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __sqrtf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 hypotf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __hypotf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 cbrtf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __cbrtf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32 ceilf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __ceilf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 fabsf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __fabsf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 floorf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __floorf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 fmodf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __fmodf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 copysignf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __copysignf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float32 nanf32 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __nanf32 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 j0f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __j0f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 j1f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __j1f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 jnf32 (int, _Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __jnf32 (int, _Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 y0f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __y0f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 y1f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __y1f32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 ynf32 (int, _Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __ynf32 (int, _Float32) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern _Float32 erff32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __erff32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 erfcf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __erfcf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 lgammaf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __lgammaf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 tgammaf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __tgammaf32 (_Float32) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 lgammaf32_r (_Float32, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __lgammaf32_r (_Float32, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32 rintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __rintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 nextafterf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __nextafterf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32 nextdownf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __nextdownf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32 nextupf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __nextupf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 remainderf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __remainderf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 scalbnf32 (_Float32 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __scalbnf32 (_Float32 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 scalblnf32 (_Float32 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __scalblnf32 (_Float32 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 nearbyintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __nearbyintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 roundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __roundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern _Float32 truncf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __truncf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float32 remquof32 (_Float32 __x, _Float32 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __remquof32 (_Float32 __x, _Float32 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32 fdimf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __fdimf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 fmaxf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __fmaxf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 fminf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __fminf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 fmaf32 (_Float32 __x, _Float32 __y, _Float32 __z) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __fmaf32 (_Float32 __x, _Float32 __y, _Float32 __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32 roundevenf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __roundevenf32 (_Float32 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf32 (_Float32 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern _Float32 fmaxmagf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __fmaxmagf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32 fminmagf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32 __fminmagf32 (_Float32 __x, _Float32 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef32 (_Float32 *__cx, const _Float32 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf32 (const _Float32 *__x, const _Float32 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf32 (const _Float32 *__x, const _Float32 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern _Float32 getpayloadf32 (const _Float32 *__x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32 __getpayloadf32 (const _Float32 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf32 (_Float32 *__x, _Float32 __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf32 (_Float32 *__x, _Float32 __payload) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 acosf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __acosf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 asinf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __asinf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 atanf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __atanf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 atan2f64 (_Float64 __y, _Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __atan2f64 (_Float64 __y, _Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float64 cosf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __cosf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern _Float64 sinf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __sinf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 tanf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __tanf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 coshf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __coshf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 sinhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __sinhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 tanhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __tanhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf64 (_Float64 __x, _Float64 *__sinx, _Float64 *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf64 (_Float64 __x, _Float64 *__sinx, _Float64 *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern _Float64 acoshf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __acoshf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 asinhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __asinhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 atanhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __atanhf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern _Float64 expf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __expf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 frexpf64 (_Float64 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __frexpf64 (_Float64 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 ldexpf64 (_Float64 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __ldexpf64 (_Float64 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float64 logf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __logf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 log10f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __log10f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 modff64 (_Float64 __x, _Float64 *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __modff64 (_Float64 __x, _Float64 *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern _Float64 exp10f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __exp10f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 expm1f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __expm1f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 log1pf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __log1pf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 logbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __logbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 exp2f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __exp2f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 log2f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __log2f64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern _Float64 powf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __powf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 sqrtf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __sqrtf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 hypotf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __hypotf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 cbrtf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __cbrtf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64 ceilf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __ceilf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 fabsf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __fabsf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 floorf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __floorf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 fmodf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __fmodf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 copysignf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __copysignf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float64 nanf64 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __nanf64 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 j0f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __j0f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 j1f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __j1f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 jnf64 (int, _Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __jnf64 (int, _Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 y0f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __y0f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 y1f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __y1f64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 ynf64 (int, _Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __ynf64 (int, _Float64) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern _Float64 erff64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __erff64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 erfcf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __erfcf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 lgammaf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __lgammaf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 tgammaf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __tgammaf64 (_Float64) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 lgammaf64_r (_Float64, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __lgammaf64_r (_Float64, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64 rintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __rintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 nextafterf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __nextafterf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64 nextdownf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __nextdownf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64 nextupf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __nextupf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 remainderf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __remainderf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 scalbnf64 (_Float64 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __scalbnf64 (_Float64 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 scalblnf64 (_Float64 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __scalblnf64 (_Float64 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 nearbyintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __nearbyintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 roundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __roundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern _Float64 truncf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __truncf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float64 remquof64 (_Float64 __x, _Float64 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __remquof64 (_Float64 __x, _Float64 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64 fdimf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __fdimf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 fmaxf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __fmaxf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 fminf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __fminf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 fmaf64 (_Float64 __x, _Float64 __y, _Float64 __z) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __fmaf64 (_Float64 __x, _Float64 __y, _Float64 __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64 roundevenf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __roundevenf64 (_Float64 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf64 (_Float64 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern _Float64 fmaxmagf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __fmaxmagf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64 fminmagf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64 __fminmagf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef64 (_Float64 *__cx, const _Float64 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf64 (const _Float64 *__x, const _Float64 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf64 (const _Float64 *__x, const _Float64 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern _Float64 getpayloadf64 (const _Float64 *__x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64 __getpayloadf64 (const _Float64 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf64 (_Float64 *__x, _Float64 __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf64 (_Float64 *__x, _Float64 __payload) __attribute__ ((__nothrow__ , __leaf__)); -extern int __fpclassifyf128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - -extern int __signbitf128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - - -extern int __isinff128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __finitef128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __isnanf128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int __iseqsigf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int __issignalingf128 (_Float128 __value) __attribute__ ((__nothrow__ , __leaf__)) - __attribute__ ((__const__)); - - -extern _Float128 acosf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __acosf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 asinf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __asinf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 atanf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __atanf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 atan2f128 (_Float128 __y, _Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __atan2f128 (_Float128 __y, _Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float128 cosf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __cosf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern _Float128 sinf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __sinf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 tanf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __tanf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 coshf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __coshf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 sinhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __sinhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 tanhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __tanhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf128 (_Float128 __x, _Float128 *__sinx, _Float128 *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf128 (_Float128 __x, _Float128 *__sinx, _Float128 *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern _Float128 acoshf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __acoshf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 asinhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __asinhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 atanhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __atanhf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern _Float128 expf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __expf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 frexpf128 (_Float128 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __frexpf128 (_Float128 __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 ldexpf128 (_Float128 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __ldexpf128 (_Float128 __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float128 logf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __logf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 log10f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __log10f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 modff128 (_Float128 __x, _Float128 *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __modff128 (_Float128 __x, _Float128 *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern _Float128 exp10f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __exp10f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 expm1f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __expm1f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 log1pf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __log1pf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 logbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __logbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 exp2f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __exp2f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 log2f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __log2f128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern _Float128 powf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __powf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 sqrtf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __sqrtf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 hypotf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __hypotf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 cbrtf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __cbrtf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float128 ceilf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __ceilf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 fabsf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __fabsf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 floorf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __floorf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 fmodf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __fmodf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 copysignf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __copysignf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float128 nanf128 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __nanf128 (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 j0f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __j0f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 j1f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __j1f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 jnf128 (int, _Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __jnf128 (int, _Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 y0f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __y0f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 y1f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __y1f128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 ynf128 (int, _Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __ynf128 (int, _Float128) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern _Float128 erff128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __erff128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 erfcf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __erfcf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 lgammaf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __lgammaf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 tgammaf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __tgammaf128 (_Float128) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float128 lgammaf128_r (_Float128, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __lgammaf128_r (_Float128, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float128 rintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __rintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 nextafterf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __nextafterf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float128 nextdownf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __nextdownf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float128 nextupf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __nextupf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 remainderf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __remainderf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 scalbnf128 (_Float128 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __scalbnf128 (_Float128 __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 scalblnf128 (_Float128 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __scalblnf128 (_Float128 __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 nearbyintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __nearbyintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 roundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __roundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern _Float128 truncf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __truncf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float128 remquof128 (_Float128 __x, _Float128 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __remquof128 (_Float128 __x, _Float128 __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float128 fdimf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __fdimf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float128 fmaxf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __fmaxf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 fminf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __fminf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 fmaf128 (_Float128 __x, _Float128 __y, _Float128 __z) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __fmaf128 (_Float128 __x, _Float128 __y, _Float128 __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float128 roundevenf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __roundevenf128 (_Float128 __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf128 (_Float128 __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern _Float128 fmaxmagf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __fmaxmagf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float128 fminmagf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float128 __fminmagf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef128 (_Float128 *__cx, const _Float128 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf128 (const _Float128 *__x, const _Float128 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf128 (const _Float128 *__x, const _Float128 *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern _Float128 getpayloadf128 (const _Float128 *__x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float128 __getpayloadf128 (const _Float128 *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf128 (_Float128 *__x, _Float128 __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf128 (_Float128 *__x, _Float128 __payload) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x acosf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __acosf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x asinf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __asinf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x atanf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __atanf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x atan2f32x (_Float32x __y, _Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __atan2f32x (_Float32x __y, _Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float32x cosf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __cosf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern _Float32x sinf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __sinf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x tanf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __tanf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x coshf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __coshf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x sinhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __sinhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x tanhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __tanhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf32x (_Float32x __x, _Float32x *__sinx, _Float32x *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf32x (_Float32x __x, _Float32x *__sinx, _Float32x *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern _Float32x acoshf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __acoshf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x asinhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __asinhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x atanhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __atanhf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern _Float32x expf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __expf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x frexpf32x (_Float32x __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __frexpf32x (_Float32x __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x ldexpf32x (_Float32x __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __ldexpf32x (_Float32x __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float32x logf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __logf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x log10f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __log10f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x modff32x (_Float32x __x, _Float32x *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __modff32x (_Float32x __x, _Float32x *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern _Float32x exp10f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __exp10f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x expm1f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __expm1f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x log1pf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __log1pf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x logbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __logbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x exp2f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __exp2f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x log2f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __log2f32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern _Float32x powf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __powf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x sqrtf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __sqrtf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x hypotf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __hypotf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x cbrtf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __cbrtf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32x ceilf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __ceilf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x fabsf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __fabsf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x floorf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __floorf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x fmodf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __fmodf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x copysignf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __copysignf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float32x nanf32x (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __nanf32x (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x j0f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __j0f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x j1f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __j1f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x jnf32x (int, _Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __jnf32x (int, _Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x y0f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __y0f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x y1f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __y1f32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x ynf32x (int, _Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __ynf32x (int, _Float32x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern _Float32x erff32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __erff32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x erfcf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __erfcf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x lgammaf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __lgammaf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x tgammaf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __tgammaf32x (_Float32x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x lgammaf32x_r (_Float32x, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __lgammaf32x_r (_Float32x, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32x rintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __rintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x nextafterf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __nextafterf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float32x nextdownf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __nextdownf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float32x nextupf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __nextupf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x remainderf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __remainderf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x scalbnf32x (_Float32x __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __scalbnf32x (_Float32x __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x scalblnf32x (_Float32x __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __scalblnf32x (_Float32x __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x nearbyintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __nearbyintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x roundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __roundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern _Float32x truncf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __truncf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float32x remquof32x (_Float32x __x, _Float32x __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __remquof32x (_Float32x __x, _Float32x __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float32x fdimf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __fdimf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x fmaxf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __fmaxf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x fminf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __fminf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x fmaf32x (_Float32x __x, _Float32x __y, _Float32x __z) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __fmaf32x (_Float32x __x, _Float32x __y, _Float32x __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float32x roundevenf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __roundevenf32x (_Float32x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf32x (_Float32x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern _Float32x fmaxmagf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __fmaxmagf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float32x fminmagf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float32x __fminmagf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef32x (_Float32x *__cx, const _Float32x *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf32x (const _Float32x *__x, const _Float32x *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf32x (const _Float32x *__x, const _Float32x *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern _Float32x getpayloadf32x (const _Float32x *__x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float32x __getpayloadf32x (const _Float32x *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf32x (_Float32x *__x, _Float32x __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf32x (_Float32x *__x, _Float32x __payload) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x acosf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __acosf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x asinf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __asinf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x atanf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __atanf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x atan2f64x (_Float64x __y, _Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __atan2f64x (_Float64x __y, _Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float64x cosf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __cosf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - extern _Float64x sinf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __sinf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x tanf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __tanf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x coshf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __coshf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x sinhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __sinhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x tanhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __tanhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - extern void sincosf64x (_Float64x __x, _Float64x *__sinx, _Float64x *__cosx) __attribute__ ((__nothrow__ , __leaf__)); extern void __sincosf64x (_Float64x __x, _Float64x *__sinx, _Float64x *__cosx) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern _Float64x acoshf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __acoshf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x asinhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __asinhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x atanhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __atanhf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - extern _Float64x expf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __expf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x frexpf64x (_Float64x __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __frexpf64x (_Float64x __x, int *__exponent) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x ldexpf64x (_Float64x __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __ldexpf64x (_Float64x __x, int __exponent) __attribute__ ((__nothrow__ , __leaf__)); - - - extern _Float64x logf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __logf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x log10f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __log10f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x modff64x (_Float64x __x, _Float64x *__iptr) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __modff64x (_Float64x __x, _Float64x *__iptr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - -extern _Float64x exp10f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __exp10f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x expm1f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __expm1f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x log1pf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __log1pf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x logbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __logbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x exp2f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __exp2f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x log2f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __log2f64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - extern _Float64x powf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __powf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x sqrtf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __sqrtf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x hypotf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __hypotf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x cbrtf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __cbrtf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64x ceilf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __ceilf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x fabsf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __fabsf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x floorf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __floorf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x fmodf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __fmodf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x copysignf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __copysignf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float64x nanf64x (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __nanf64x (const char *__tagb) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x j0f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __j0f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x j1f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __j1f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x jnf64x (int, _Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __jnf64x (int, _Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x y0f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __y0f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x y1f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __y1f64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x ynf64x (int, _Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __ynf64x (int, _Float64x) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern _Float64x erff64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __erff64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x erfcf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __erfcf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x lgammaf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __lgammaf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x tgammaf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __tgammaf64x (_Float64x) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x lgammaf64x_r (_Float64x, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __lgammaf64x_r (_Float64x, int *__signgamp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64x rintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __rintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x nextafterf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __nextafterf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern _Float64x nextdownf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __nextdownf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - -extern _Float64x nextupf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __nextupf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x remainderf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __remainderf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x scalbnf64x (_Float64x __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __scalbnf64x (_Float64x __x, int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int ilogbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern int __ilogbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern long int llogbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __llogbf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x scalblnf64x (_Float64x __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __scalblnf64x (_Float64x __x, long int __n) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x nearbyintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __nearbyintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x roundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __roundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern _Float64x truncf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __truncf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -extern _Float64x remquof64x (_Float64x __x, _Float64x __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __remquof64x (_Float64x __x, _Float64x __y, int *__quo) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern long int lrintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lrintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llrintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llrintf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern long int lroundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long int __lroundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); -__extension__ -extern long long int llroundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); extern long long int __llroundf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern _Float64x fdimf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __fdimf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x fmaxf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __fmaxf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x fminf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __fminf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x fmaf64x (_Float64x __x, _Float64x __y, _Float64x __z) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __fmaf64x (_Float64x __x, _Float64x __y, _Float64x __z) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern _Float64x roundevenf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __roundevenf64x (_Float64x __x) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - -extern __intmax_t fromfpf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - -extern __uintmax_t ufromfpf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __intmax_t fromfpxf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __intmax_t __fromfpxf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - - - -extern __uintmax_t ufromfpxf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)); extern __uintmax_t __ufromfpxf64x (_Float64x __x, int __round, unsigned int __width) __attribute__ ((__nothrow__ , __leaf__)) - ; - - -extern _Float64x fmaxmagf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __fmaxmagf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern _Float64x fminmagf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); extern _Float64x __fminmagf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int canonicalizef64x (_Float64x *__cx, const _Float64x *__x) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int totalorderf64x (const _Float64x *__x, const _Float64x *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern int totalordermagf64x (const _Float64x *__x, const _Float64x *__y) __attribute__ ((__nothrow__ , __leaf__)) - - __attribute__ ((__pure__)); - - -extern _Float64x getpayloadf64x (const _Float64x *__x) __attribute__ ((__nothrow__ , __leaf__)); extern _Float64x __getpayloadf64x (const _Float64x *__x) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadf64x (_Float64x *__x, _Float64x __payload) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setpayloadsigf64x (_Float64x *__x, _Float64x __payload) __attribute__ ((__nothrow__ , __leaf__)); -extern float fadd (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fdiv (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fmul (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fsub (double __x, double __y) __attribute__ ((__nothrow__ , __leaf__)); -extern float faddl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fdivl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fmull (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern float fsubl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); -extern double daddl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double ddivl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double dmull (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double dsubl (long double __x, long double __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 f32addf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32divf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32mulf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32subf32x (_Float32x __x, _Float32x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 f32addf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32divf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32mulf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32subf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 f32addf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32divf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32mulf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32subf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32 f32addf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32divf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32mulf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32 f32subf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x f32xaddf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xdivf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xmulf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xsubf64 (_Float64 __x, _Float64 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x f32xaddf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xdivf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xmulf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xsubf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float32x f32xaddf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xdivf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xmulf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float32x f32xsubf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 f64addf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64divf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64mulf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64subf64x (_Float64x __x, _Float64x __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64 f64addf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64divf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64mulf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64 f64subf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern _Float64x f64xaddf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x f64xdivf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x f64xmulf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); - - -extern _Float64x f64xsubf128 (_Float128 __x, _Float128 __y) __attribute__ ((__nothrow__ , __leaf__)); -extern int signgam; -enum - { - FP_NAN = - - 0, - FP_INFINITE = - - 1, - FP_ZERO = - - 2, - FP_SUBNORMAL = - - 3, - FP_NORMAL = - - 4 - }; -extern int __iscanonicall (long double __x) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - -struct timex -{ - unsigned int modes; - __syscall_slong_t offset; - __syscall_slong_t freq; - __syscall_slong_t maxerror; - __syscall_slong_t esterror; - int status; - __syscall_slong_t constant; - __syscall_slong_t precision; - __syscall_slong_t tolerance; - struct timeval time; - __syscall_slong_t tick; - __syscall_slong_t ppsfreq; - __syscall_slong_t jitter; - int shift; - __syscall_slong_t stabil; - __syscall_slong_t jitcnt; - __syscall_slong_t calcnt; - __syscall_slong_t errcnt; - __syscall_slong_t stbcnt; - - int tai; - - - int :32; int :32; int :32; int :32; - int :32; int :32; int :32; int :32; - int :32; int :32; int :32; -}; - - - - -extern int clock_adjtime (__clockid_t __clock_id, struct timex *__utx) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - - - -struct tm -{ - int tm_sec; - int tm_min; - int tm_hour; - int tm_mday; - int tm_mon; - int tm_year; - int tm_wday; - int tm_yday; - int tm_isdst; - - - long int tm_gmtoff; - const char *tm_zone; - - - - -}; - - - - - - - -struct itimerspec - { - struct timespec it_interval; - struct timespec it_value; - }; -struct sigevent; - - - - -extern clock_t clock (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern time_t time (time_t *__timer) __attribute__ ((__nothrow__ , __leaf__)); - - -extern double difftime (time_t __time1, time_t __time0) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern time_t mktime (struct tm *__tp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern size_t strftime (char *__restrict __s, size_t __maxsize, - const char *__restrict __format, - const struct tm *__restrict __tp) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern char *strptime (const char *__restrict __s, - const char *__restrict __fmt, struct tm *__tp) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern size_t strftime_l (char *__restrict __s, size_t __maxsize, - const char *__restrict __format, - const struct tm *__restrict __tp, - locale_t __loc) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern char *strptime_l (const char *__restrict __s, - const char *__restrict __fmt, struct tm *__tp, - locale_t __loc) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern struct tm *gmtime (const time_t *__timer) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern struct tm *localtime (const time_t *__timer) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern struct tm *gmtime_r (const time_t *__restrict __timer, - struct tm *__restrict __tp) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern struct tm *localtime_r (const time_t *__restrict __timer, - struct tm *__restrict __tp) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern char *asctime (const struct tm *__tp) __attribute__ ((__nothrow__ , __leaf__)); - - -extern char *ctime (const time_t *__timer) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern char *asctime_r (const struct tm *__restrict __tp, - char *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)); - - -extern char *ctime_r (const time_t *__restrict __timer, - char *__restrict __buf) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern char *__tzname[2]; -extern int __daylight; -extern long int __timezone; - - - - -extern char *tzname[2]; - - - -extern void tzset (void) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int daylight; -extern long int timezone; -extern time_t timegm (struct tm *__tp) __attribute__ ((__nothrow__ , __leaf__)); - - -extern time_t timelocal (struct tm *__tp) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int dysize (int __year) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); -extern int nanosleep (const struct timespec *__requested_time, - struct timespec *__remaining); - - - -extern int clock_getres (clockid_t __clock_id, struct timespec *__res) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int clock_gettime (clockid_t __clock_id, struct timespec *__tp) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int clock_settime (clockid_t __clock_id, const struct timespec *__tp) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int clock_nanosleep (clockid_t __clock_id, int __flags, - const struct timespec *__req, - struct timespec *__rem); - - -extern int clock_getcpuclockid (pid_t __pid, clockid_t *__clock_id) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int timer_create (clockid_t __clock_id, - struct sigevent *__restrict __evp, - timer_t *__restrict __timerid) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int timer_delete (timer_t __timerid) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int timer_settime (timer_t __timerid, int __flags, - const struct itimerspec *__restrict __value, - struct itimerspec *__restrict __ovalue) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int timer_gettime (timer_t __timerid, struct itimerspec *__value) - __attribute__ ((__nothrow__ , __leaf__)); - - -extern int timer_getoverrun (timer_t __timerid) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int timespec_get (struct timespec *__ts, int __base) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int getdate_err; -extern struct tm *getdate (const char *__string); -extern int getdate_r (const char *__restrict __string, - struct tm *__restrict __resbufp); - - - - - - - - - - - - - - - - - - - - - - - - - - - -typedef __sig_atomic_t sig_atomic_t; - - - - -union sigval -{ - int sival_int; - void *sival_ptr; -}; - -typedef union sigval __sigval_t; -typedef struct - { - int si_signo; - - int si_errno; - - int si_code; - - - - - - int __pad0; - - - union - { - int _pad[((128 / sizeof (int)) - 4)]; - - - struct - { - __pid_t si_pid; - __uid_t si_uid; - } _kill; - - - struct - { - int si_tid; - int si_overrun; - __sigval_t si_sigval; - } _timer; - - - struct - { - __pid_t si_pid; - __uid_t si_uid; - __sigval_t si_sigval; - } _rt; - - - struct - { - __pid_t si_pid; - __uid_t si_uid; - int si_status; - __clock_t si_utime; - __clock_t si_stime; - } _sigchld; - - - struct - { - void *si_addr; - - short int si_addr_lsb; - union - { - - struct - { - void *_lower; - void *_upper; - } _addr_bnd; - - __uint32_t _pkey; - } _bounds; - } _sigfault; - - - struct - { - long int si_band; - int si_fd; - } _sigpoll; - - - - struct - { - void *_call_addr; - int _syscall; - unsigned int _arch; - } _sigsys; - - } _sifields; - } siginfo_t ; -enum -{ - SI_ASYNCNL = -60, - SI_DETHREAD = -7, - - SI_TKILL, - SI_SIGIO, - - SI_ASYNCIO, - SI_MESGQ, - SI_TIMER, - - - - - - SI_QUEUE, - SI_USER, - SI_KERNEL = 0x80 -}; - - - - -enum -{ - ILL_ILLOPC = 1, - - ILL_ILLOPN, - - ILL_ILLADR, - - ILL_ILLTRP, - - ILL_PRVOPC, - - ILL_PRVREG, - - ILL_COPROC, - - ILL_BADSTK, - - ILL_BADIADDR - -}; - - -enum -{ - FPE_INTDIV = 1, - - FPE_INTOVF, - - FPE_FLTDIV, - - FPE_FLTOVF, - - FPE_FLTUND, - - FPE_FLTRES, - - FPE_FLTINV, - - FPE_FLTSUB, - - FPE_FLTUNK = 14, - - FPE_CONDTRAP - -}; - - -enum -{ - SEGV_MAPERR = 1, - - SEGV_ACCERR, - - SEGV_BNDERR, - - SEGV_PKUERR, - - SEGV_ACCADI, - - SEGV_ADIDERR, - - SEGV_ADIPERR - -}; - - -enum -{ - BUS_ADRALN = 1, - - BUS_ADRERR, - - BUS_OBJERR, - - BUS_MCEERR_AR, - - BUS_MCEERR_AO - -}; - - - - -enum -{ - TRAP_BRKPT = 1, - - TRAP_TRACE, - - TRAP_BRANCH, - - TRAP_HWBKPT, - - TRAP_UNK - -}; - - - - -enum -{ - CLD_EXITED = 1, - - CLD_KILLED, - - CLD_DUMPED, - - CLD_TRAPPED, - - CLD_STOPPED, - - CLD_CONTINUED - -}; - - -enum -{ - POLL_IN = 1, - - POLL_OUT, - - POLL_MSG, - - POLL_ERR, - - POLL_PRI, - - POLL_HUP - -}; - - - - - - - - -typedef __sigval_t sigval_t; - - - - - - -typedef struct sigevent - { - __sigval_t sigev_value; - int sigev_signo; - int sigev_notify; - - union - { - int _pad[((64 / sizeof (int)) - 4)]; - - - - __pid_t _tid; - - struct - { - void (*_function) (__sigval_t); - pthread_attr_t *_attribute; - } _sigev_thread; - } _sigev_un; - } sigevent_t; -enum -{ - SIGEV_SIGNAL = 0, - - SIGEV_NONE, - - SIGEV_THREAD, - - - SIGEV_THREAD_ID = 4 - - -}; - - - - -typedef void (*__sighandler_t) (int); - - - - -extern __sighandler_t __sysv_signal (int __sig, __sighandler_t __handler) - __attribute__ ((__nothrow__ , __leaf__)); - -extern __sighandler_t sysv_signal (int __sig, __sighandler_t __handler) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern __sighandler_t signal (int __sig, __sighandler_t __handler) - __attribute__ ((__nothrow__ , __leaf__)); -extern int kill (__pid_t __pid, int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int killpg (__pid_t __pgrp, int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int raise (int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern __sighandler_t ssignal (int __sig, __sighandler_t __handler) - __attribute__ ((__nothrow__ , __leaf__)); -extern int gsignal (int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern void psignal (int __sig, const char *__s); - - -extern void psiginfo (const siginfo_t *__pinfo, const char *__s); -extern int sigpause (int __sig) __asm__ ("__xpg_sigpause"); -extern int sigblock (int __mask) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__deprecated__)); - - -extern int sigsetmask (int __mask) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__deprecated__)); - - -extern int siggetmask (void) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__deprecated__)); -typedef __sighandler_t sighandler_t; - - - - -typedef __sighandler_t sig_t; - - - - - -extern int sigemptyset (sigset_t *__set) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int sigfillset (sigset_t *__set) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int sigaddset (sigset_t *__set, int __signo) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int sigdelset (sigset_t *__set, int __signo) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int sigismember (const sigset_t *__set, int __signo) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int sigisemptyset (const sigset_t *__set) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int sigandset (sigset_t *__set, const sigset_t *__left, - const sigset_t *__right) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2, 3))); - - -extern int sigorset (sigset_t *__set, const sigset_t *__left, - const sigset_t *__right) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2, 3))); - - - - -struct sigaction - { - - - union - { - - __sighandler_t sa_handler; - - void (*sa_sigaction) (int, siginfo_t *, void *); - } - __sigaction_handler; - - - - - - - - __sigset_t sa_mask; - - - int sa_flags; - - - void (*sa_restorer) (void); - }; - - -extern int sigprocmask (int __how, const sigset_t *__restrict __set, - sigset_t *__restrict __oset) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int sigsuspend (const sigset_t *__set) __attribute__ ((__nonnull__ (1))); - - -extern int sigaction (int __sig, const struct sigaction *__restrict __act, - struct sigaction *__restrict __oact) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sigpending (sigset_t *__set) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - - - -extern int sigwait (const sigset_t *__restrict __set, int *__restrict __sig) - __attribute__ ((__nonnull__ (1, 2))); - - - - - - - -extern int sigwaitinfo (const sigset_t *__restrict __set, - siginfo_t *__restrict __info) __attribute__ ((__nonnull__ (1))); - - - - - - -extern int sigtimedwait (const sigset_t *__restrict __set, - siginfo_t *__restrict __info, - const struct timespec *__restrict __timeout) - __attribute__ ((__nonnull__ (1))); - - - -extern int sigqueue (__pid_t __pid, int __sig, const union sigval __val) - __attribute__ ((__nothrow__ , __leaf__)); -extern const char *const _sys_siglist[(64 + 1)]; -extern const char *const sys_siglist[(64 + 1)]; - - - -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]; -}; -struct _fpstate -{ - - __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]; -}; - - - -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; -}; - - -extern int sigreturn (struct sigcontext *__scp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - -typedef struct - { - void *ss_sp; - int ss_flags; - size_t ss_size; - } stack_t; - - -__extension__ typedef long long int greg_t; -typedef greg_t gregset_t[23]; - - - -enum -{ - REG_R8 = 0, - - REG_R9, - - REG_R10, - - REG_R11, - - REG_R12, - - REG_R13, - - REG_R14, - - REG_R15, - - REG_RDI, - - REG_RSI, - - REG_RBP, - - REG_RBX, - - REG_RDX, - - REG_RAX, - - REG_RCX, - - REG_RSP, - - REG_RIP, - - REG_EFL, - - REG_CSGSFS, - - REG_ERR, - - REG_TRAPNO, - - REG_OLDMASK, - - REG_CR2 - -}; - - -struct _libc_fpxreg -{ - unsigned short int significand[4]; - unsigned short int exponent; - unsigned short int __glibc_reserved1[3]; -}; - -struct _libc_xmmreg -{ - __uint32_t element[4]; -}; - -struct _libc_fpstate -{ - - __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 _libc_fpxreg _st[8]; - struct _libc_xmmreg _xmm[16]; - __uint32_t __glibc_reserved1[24]; -}; - - -typedef struct _libc_fpstate *fpregset_t; - - -typedef struct - { - gregset_t gregs; - - fpregset_t fpregs; - __extension__ unsigned long long __reserved1 [8]; -} mcontext_t; - - -typedef struct ucontext_t - { - unsigned long int uc_flags; - struct ucontext_t *uc_link; - stack_t uc_stack; - mcontext_t uc_mcontext; - sigset_t uc_sigmask; - struct _libc_fpstate __fpregs_mem; - __extension__ unsigned long long int __ssp[4]; - } ucontext_t; - - - - - - - -extern int siginterrupt (int __sig, int __interrupt) __attribute__ ((__nothrow__ , __leaf__)); - -enum -{ - SS_ONSTACK = 1, - - SS_DISABLE - -}; - - - -extern int sigaltstack (const stack_t *__restrict __ss, - stack_t *__restrict __oss) __attribute__ ((__nothrow__ , __leaf__)); - - - - -struct sigstack - { - void *ss_sp; - int ss_onstack; - }; - - - - - - - -extern int sigstack (struct sigstack *__ss, struct sigstack *__oss) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__deprecated__)); - - - - - - -extern int sighold (int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sigrelse (int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sigignore (int __sig) __attribute__ ((__nothrow__ , __leaf__)); - - -extern __sighandler_t sigset (int __sig, __sighandler_t __disp) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int pthread_sigmask (int __how, - const __sigset_t *__restrict __newmask, - __sigset_t *__restrict __oldmask)__attribute__ ((__nothrow__ , __leaf__)); - - -extern int pthread_kill (pthread_t __threadid, int __signo) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int pthread_sigqueue (pthread_t __threadid, int __signo, - const union sigval __value) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int __libc_current_sigrtmin (void) __attribute__ ((__nothrow__ , __leaf__)); - -extern int __libc_current_sigrtmax (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int tgkill (__pid_t __tgid, __pid_t __tid, int __signal); - - - - - -extern void __assert_fail (const char *__assertion, const char *__file, - unsigned int __line, const char *__function) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); - - -extern void __assert_perror_fail (int __errnum, const char *__file, - unsigned int __line, const char *__function) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); - - - - -extern void __assert (const char *__assertion, const char *__file, int __line) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); - - - - - - - - -struct sched_param -{ - int sched_priority; -}; - - - - - -extern int clone (int (*__fn) (void *__arg), void *__child_stack, - int __flags, void *__arg, ...) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int unshare (int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_getcpu (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int getcpu (unsigned int *, unsigned int *) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int setns (int __fd, int __nstype) __attribute__ ((__nothrow__ , __leaf__)); - - - -typedef unsigned long int __cpu_mask; - - - - - - -typedef struct -{ - __cpu_mask __bits[1024 / (8 * sizeof (__cpu_mask))]; -} cpu_set_t; - - -extern int __sched_cpucount (size_t __setsize, const cpu_set_t *__setp) - __attribute__ ((__nothrow__ , __leaf__)); -extern cpu_set_t *__sched_cpualloc (size_t __count) __attribute__ ((__nothrow__ , __leaf__)) ; -extern void __sched_cpufree (cpu_set_t *__set) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - -extern int sched_setparam (__pid_t __pid, const struct sched_param *__param) - __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_getparam (__pid_t __pid, struct sched_param *__param) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_setscheduler (__pid_t __pid, int __policy, - const struct sched_param *__param) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_getscheduler (__pid_t __pid) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_yield (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_get_priority_max (int __algorithm) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_get_priority_min (int __algorithm) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_rr_get_interval (__pid_t __pid, struct timespec *__t) __attribute__ ((__nothrow__ , __leaf__)); -extern int sched_setaffinity (__pid_t __pid, size_t __cpusetsize, - const cpu_set_t *__cpuset) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int sched_getaffinity (__pid_t __pid, size_t __cpusetsize, - cpu_set_t *__cpuset) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - -typedef long int __jmp_buf[8]; - - - - -enum -{ - PTHREAD_CREATE_JOINABLE, - - PTHREAD_CREATE_DETACHED - -}; - - - -enum -{ - PTHREAD_MUTEX_TIMED_NP, - PTHREAD_MUTEX_RECURSIVE_NP, - PTHREAD_MUTEX_ERRORCHECK_NP, - PTHREAD_MUTEX_ADAPTIVE_NP - - , - PTHREAD_MUTEX_NORMAL = PTHREAD_MUTEX_TIMED_NP, - PTHREAD_MUTEX_RECURSIVE = PTHREAD_MUTEX_RECURSIVE_NP, - PTHREAD_MUTEX_ERRORCHECK = PTHREAD_MUTEX_ERRORCHECK_NP, - PTHREAD_MUTEX_DEFAULT = PTHREAD_MUTEX_NORMAL - - - - , PTHREAD_MUTEX_FAST_NP = PTHREAD_MUTEX_TIMED_NP - -}; - - - - -enum -{ - PTHREAD_MUTEX_STALLED, - PTHREAD_MUTEX_STALLED_NP = PTHREAD_MUTEX_STALLED, - PTHREAD_MUTEX_ROBUST, - PTHREAD_MUTEX_ROBUST_NP = PTHREAD_MUTEX_ROBUST -}; - - - - - -enum -{ - PTHREAD_PRIO_NONE, - PTHREAD_PRIO_INHERIT, - PTHREAD_PRIO_PROTECT -}; -enum -{ - PTHREAD_RWLOCK_PREFER_READER_NP, - PTHREAD_RWLOCK_PREFER_WRITER_NP, - PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP, - PTHREAD_RWLOCK_DEFAULT_NP = PTHREAD_RWLOCK_PREFER_READER_NP -}; -enum -{ - PTHREAD_INHERIT_SCHED, - - PTHREAD_EXPLICIT_SCHED - -}; - - - -enum -{ - PTHREAD_SCOPE_SYSTEM, - - PTHREAD_SCOPE_PROCESS - -}; - - - -enum -{ - PTHREAD_PROCESS_PRIVATE, - - PTHREAD_PROCESS_SHARED - -}; -struct _pthread_cleanup_buffer -{ - void (*__routine) (void *); - void *__arg; - int __canceltype; - struct _pthread_cleanup_buffer *__prev; -}; - - -enum -{ - PTHREAD_CANCEL_ENABLE, - - PTHREAD_CANCEL_DISABLE - -}; -enum -{ - PTHREAD_CANCEL_DEFERRED, - - PTHREAD_CANCEL_ASYNCHRONOUS - -}; - - - - - -extern int pthread_create (pthread_t *__restrict __newthread, - const pthread_attr_t *__restrict __attr, - void *(*__start_routine) (void *), - void *__restrict __arg) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 3))); - - - - - -extern void pthread_exit (void *__retval) __attribute__ ((__noreturn__)); - - - - - - - -extern int pthread_join (pthread_t __th, void **__thread_return); - - - - -extern int pthread_tryjoin_np (pthread_t __th, void **__thread_return) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern int pthread_timedjoin_np (pthread_t __th, void **__thread_return, - const struct timespec *__abstime); -extern int pthread_clockjoin_np (pthread_t __th, void **__thread_return, - clockid_t __clockid, - const struct timespec *__abstime); - - - - - - -extern int pthread_detach (pthread_t __th) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern pthread_t pthread_self (void) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - -extern int pthread_equal (pthread_t __thread1, pthread_t __thread2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__const__)); - - - - - - - -extern int pthread_attr_init (pthread_attr_t *__attr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_attr_destroy (pthread_attr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_attr_getdetachstate (const pthread_attr_t *__attr, - int *__detachstate) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setdetachstate (pthread_attr_t *__attr, - int __detachstate) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_attr_getguardsize (const pthread_attr_t *__attr, - size_t *__guardsize) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setguardsize (pthread_attr_t *__attr, - size_t __guardsize) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_attr_getschedparam (const pthread_attr_t *__restrict __attr, - struct sched_param *__restrict __param) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setschedparam (pthread_attr_t *__restrict __attr, - const struct sched_param *__restrict - __param) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_getschedpolicy (const pthread_attr_t *__restrict - __attr, int *__restrict __policy) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setschedpolicy (pthread_attr_t *__attr, int __policy) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_attr_getinheritsched (const pthread_attr_t *__restrict - __attr, int *__restrict __inherit) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setinheritsched (pthread_attr_t *__attr, - int __inherit) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_attr_getscope (const pthread_attr_t *__restrict __attr, - int *__restrict __scope) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_attr_setscope (pthread_attr_t *__attr, int __scope) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_attr_getstackaddr (const pthread_attr_t *__restrict - __attr, void **__restrict __stackaddr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))) __attribute__ ((__deprecated__)); - - - - - -extern int pthread_attr_setstackaddr (pthread_attr_t *__attr, - void *__stackaddr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))) __attribute__ ((__deprecated__)); - - -extern int pthread_attr_getstacksize (const pthread_attr_t *__restrict - __attr, size_t *__restrict __stacksize) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - -extern int pthread_attr_setstacksize (pthread_attr_t *__attr, - size_t __stacksize) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_attr_getstack (const pthread_attr_t *__restrict __attr, - void **__restrict __stackaddr, - size_t *__restrict __stacksize) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2, 3))); - - - - -extern int pthread_attr_setstack (pthread_attr_t *__attr, void *__stackaddr, - size_t __stacksize) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - -extern int pthread_attr_setaffinity_np (pthread_attr_t *__attr, - size_t __cpusetsize, - const cpu_set_t *__cpuset) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); - - - -extern int pthread_attr_getaffinity_np (const pthread_attr_t *__attr, - size_t __cpusetsize, - cpu_set_t *__cpuset) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); - - -extern int pthread_getattr_default_np (pthread_attr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_setattr_default_np (const pthread_attr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - -extern int pthread_getattr_np (pthread_t __th, pthread_attr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - - - - - -extern int pthread_setschedparam (pthread_t __target_thread, int __policy, - const struct sched_param *__param) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); - - -extern int pthread_getschedparam (pthread_t __target_thread, - int *__restrict __policy, - struct sched_param *__restrict __param) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 3))); - - -extern int pthread_setschedprio (pthread_t __target_thread, int __prio) - __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int pthread_getname_np (pthread_t __target_thread, char *__buf, - size_t __buflen) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - -extern int pthread_setname_np (pthread_t __target_thread, const char *__name) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - - - -extern int pthread_getconcurrency (void) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int pthread_setconcurrency (int __level) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern int pthread_yield (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int pthread_setaffinity_np (pthread_t __th, size_t __cpusetsize, - const cpu_set_t *__cpuset) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); - - -extern int pthread_getaffinity_np (pthread_t __th, size_t __cpusetsize, - cpu_set_t *__cpuset) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (3))); -extern int pthread_once (pthread_once_t *__once_control, - void (*__init_routine) (void)) __attribute__ ((__nonnull__ (1, 2))); -extern int pthread_setcancelstate (int __state, int *__oldstate); - - - -extern int pthread_setcanceltype (int __type, int *__oldtype); - - -extern int pthread_cancel (pthread_t __th); - - - - -extern void pthread_testcancel (void); - - - - -typedef struct -{ - struct - { - __jmp_buf __cancel_jmp_buf; - int __mask_was_saved; - } __cancel_jmp_buf[1]; - void *__pad[4]; -} __pthread_unwind_buf_t __attribute__ ((__aligned__)); -struct __pthread_cleanup_frame -{ - void (*__cancel_routine) (void *); - void *__cancel_arg; - int __do_it; - int __cancel_type; -}; -extern __inline __attribute__ ((__gnu_inline__)) void -__pthread_cleanup_routine (struct __pthread_cleanup_frame *__frame) -{ - if (__frame->__do_it) - __frame->__cancel_routine (__frame->__cancel_arg); -} -struct __jmp_buf_tag; -extern int __sigsetjmp (struct __jmp_buf_tag *__env, int __savemask) __attribute__ ((__nothrow__)); - - - - - -extern int pthread_mutex_init (pthread_mutex_t *__mutex, - const pthread_mutexattr_t *__mutexattr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutex_destroy (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutex_trylock (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutex_lock (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_mutex_timedlock (pthread_mutex_t *__restrict __mutex, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_mutex_clocklock (pthread_mutex_t *__restrict __mutex, - clockid_t __clockid, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 3))); - - - -extern int pthread_mutex_unlock (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_mutex_getprioceiling (const pthread_mutex_t * - __restrict __mutex, - int *__restrict __prioceiling) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_mutex_setprioceiling (pthread_mutex_t *__restrict __mutex, - int __prioceiling, - int *__restrict __old_ceiling) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 3))); - - - - -extern int pthread_mutex_consistent (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - -extern int pthread_mutex_consistent_np (pthread_mutex_t *__mutex) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int pthread_mutexattr_init (pthread_mutexattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutexattr_destroy (pthread_mutexattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutexattr_getpshared (const pthread_mutexattr_t * - __restrict __attr, - int *__restrict __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_mutexattr_setpshared (pthread_mutexattr_t *__attr, - int __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_mutexattr_gettype (const pthread_mutexattr_t *__restrict - __attr, int *__restrict __kind) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - - -extern int pthread_mutexattr_settype (pthread_mutexattr_t *__attr, int __kind) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_mutexattr_getprotocol (const pthread_mutexattr_t * - __restrict __attr, - int *__restrict __protocol) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_mutexattr_setprotocol (pthread_mutexattr_t *__attr, - int __protocol) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_mutexattr_getprioceiling (const pthread_mutexattr_t * - __restrict __attr, - int *__restrict __prioceiling) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_mutexattr_setprioceiling (pthread_mutexattr_t *__attr, - int __prioceiling) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_mutexattr_getrobust (const pthread_mutexattr_t *__attr, - int *__robustness) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - -extern int pthread_mutexattr_getrobust_np (const pthread_mutexattr_t *__attr, - int *__robustness) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_mutexattr_setrobust (pthread_mutexattr_t *__attr, - int __robustness) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - -extern int pthread_mutexattr_setrobust_np (pthread_mutexattr_t *__attr, - int __robustness) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int pthread_rwlock_init (pthread_rwlock_t *__restrict __rwlock, - const pthread_rwlockattr_t *__restrict - __attr) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlock_destroy (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlock_rdlock (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlock_tryrdlock (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_rwlock_timedrdlock (pthread_rwlock_t *__restrict __rwlock, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_rwlock_clockrdlock (pthread_rwlock_t *__restrict __rwlock, - clockid_t __clockid, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 3))); - - - -extern int pthread_rwlock_wrlock (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlock_trywrlock (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_rwlock_timedwrlock (pthread_rwlock_t *__restrict __rwlock, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 2))); - - - -extern int pthread_rwlock_clockwrlock (pthread_rwlock_t *__restrict __rwlock, - clockid_t __clockid, - const struct timespec *__restrict - __abstime) __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1, 3))); - - - -extern int pthread_rwlock_unlock (pthread_rwlock_t *__rwlock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - - - -extern int pthread_rwlockattr_init (pthread_rwlockattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlockattr_destroy (pthread_rwlockattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlockattr_getpshared (const pthread_rwlockattr_t * - __restrict __attr, - int *__restrict __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_rwlockattr_setpshared (pthread_rwlockattr_t *__attr, - int __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_rwlockattr_getkind_np (const pthread_rwlockattr_t * - __restrict __attr, - int *__restrict __pref) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_rwlockattr_setkind_np (pthread_rwlockattr_t *__attr, - int __pref) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - - - -extern int pthread_cond_init (pthread_cond_t *__restrict __cond, - const pthread_condattr_t *__restrict __cond_attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_cond_destroy (pthread_cond_t *__cond) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_cond_signal (pthread_cond_t *__cond) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_cond_broadcast (pthread_cond_t *__cond) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - - - - -extern int pthread_cond_wait (pthread_cond_t *__restrict __cond, - pthread_mutex_t *__restrict __mutex) - __attribute__ ((__nonnull__ (1, 2))); -extern int pthread_cond_timedwait (pthread_cond_t *__restrict __cond, - pthread_mutex_t *__restrict __mutex, - const struct timespec *__restrict __abstime) - __attribute__ ((__nonnull__ (1, 2, 3))); -extern int pthread_cond_clockwait (pthread_cond_t *__restrict __cond, - pthread_mutex_t *__restrict __mutex, - __clockid_t __clock_id, - const struct timespec *__restrict __abstime) - __attribute__ ((__nonnull__ (1, 2, 4))); - - - - - -extern int pthread_condattr_init (pthread_condattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_condattr_destroy (pthread_condattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_condattr_getpshared (const pthread_condattr_t * - __restrict __attr, - int *__restrict __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_condattr_setpshared (pthread_condattr_t *__attr, - int __pshared) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_condattr_getclock (const pthread_condattr_t * - __restrict __attr, - __clockid_t *__restrict __clock_id) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_condattr_setclock (pthread_condattr_t *__attr, - __clockid_t __clock_id) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int pthread_spin_init (pthread_spinlock_t *__lock, int __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_spin_destroy (pthread_spinlock_t *__lock) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_spin_lock (pthread_spinlock_t *__lock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_spin_trylock (pthread_spinlock_t *__lock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_spin_unlock (pthread_spinlock_t *__lock) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - - - - -extern int pthread_barrier_init (pthread_barrier_t *__restrict __barrier, - const pthread_barrierattr_t *__restrict - __attr, unsigned int __count) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_barrier_destroy (pthread_barrier_t *__barrier) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_barrier_wait (pthread_barrier_t *__barrier) - __attribute__ ((__nothrow__)) __attribute__ ((__nonnull__ (1))); - - - -extern int pthread_barrierattr_init (pthread_barrierattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_barrierattr_destroy (pthread_barrierattr_t *__attr) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_barrierattr_getpshared (const pthread_barrierattr_t * - __restrict __attr, - int *__restrict __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1, 2))); - - -extern int pthread_barrierattr_setpshared (pthread_barrierattr_t *__attr, - int __pshared) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int pthread_key_create (pthread_key_t *__key, - void (*__destr_function) (void *)) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int pthread_key_delete (pthread_key_t __key) __attribute__ ((__nothrow__ , __leaf__)); - - -extern void *pthread_getspecific (pthread_key_t __key) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int pthread_setspecific (pthread_key_t __key, - const void *__pointer) __attribute__ ((__nothrow__ , __leaf__)) ; - - - - -extern int pthread_getcpuclockid (pthread_t __thread_id, - __clockid_t *__clock_id) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); -extern int pthread_atfork (void (*__prepare) (void), - void (*__parent) (void), - void (*__child) (void)) __attribute__ ((__nothrow__ , __leaf__)); - -typedef struct -{ - unsigned char _x[4] - __attribute__((__aligned__(4))); -} omp_lock_t; - -typedef struct -{ - unsigned char _x[16] - __attribute__((__aligned__(8))); -} omp_nest_lock_t; - - -typedef enum omp_sched_t -{ - omp_sched_static = 1, - omp_sched_dynamic = 2, - omp_sched_guided = 3, - omp_sched_auto = 4, - omp_sched_monotonic = 0x80000000U -} omp_sched_t; - -typedef enum omp_proc_bind_t -{ - omp_proc_bind_false = 0, - omp_proc_bind_true = 1, - omp_proc_bind_primary = 2, - omp_proc_bind_master __attribute__((__deprecated__)) - = omp_proc_bind_primary, - omp_proc_bind_close = 3, - omp_proc_bind_spread = 4 -} omp_proc_bind_t; - -typedef enum omp_sync_hint_t -{ - omp_sync_hint_none = 0, - omp_lock_hint_none __attribute__((__deprecated__)) = omp_sync_hint_none, - omp_sync_hint_uncontended = 1, - omp_lock_hint_uncontended __attribute__((__deprecated__)) = omp_sync_hint_uncontended, - omp_sync_hint_contended = 2, - omp_lock_hint_contended __attribute__((__deprecated__)) = omp_sync_hint_contended, - omp_sync_hint_nonspeculative = 4, - omp_lock_hint_nonspeculative __attribute__((__deprecated__)) - = omp_sync_hint_nonspeculative, - omp_sync_hint_speculative = 8, - omp_lock_hint_speculative __attribute__((__deprecated__)) = omp_sync_hint_speculative -} omp_sync_hint_t; - -typedef __attribute__((__deprecated__)) omp_sync_hint_t omp_lock_hint_t; - -typedef struct __attribute__((__aligned__ (sizeof (void *)))) omp_depend_t -{ - char __omp_depend_t__[2 * sizeof (void *)]; -} omp_depend_t; - -typedef enum omp_pause_resource_t -{ - omp_pause_soft = 1, - omp_pause_hard = 2 -} omp_pause_resource_t; - -typedef long int omp_intptr_t; -typedef long unsigned int omp_uintptr_t; - - - - - - - -typedef enum omp_memspace_handle_t -{ - omp_default_mem_space = 0, - omp_large_cap_mem_space = 1, - omp_const_mem_space = 2, - omp_high_bw_mem_space = 3, - omp_low_lat_mem_space = 4, - ompx_gnu_managed_mem_space = 200, - __omp_memspace_handle_t_max__ = 0xffffffffffffffffUL -} omp_memspace_handle_t; - -typedef enum omp_allocator_handle_t -{ - omp_null_allocator = 0, - omp_default_mem_alloc = 1, - omp_large_cap_mem_alloc = 2, - omp_const_mem_alloc = 3, - omp_high_bw_mem_alloc = 4, - omp_low_lat_mem_alloc = 5, - omp_cgroup_mem_alloc = 6, - omp_pteam_mem_alloc = 7, - omp_thread_mem_alloc = 8, - ompx_gnu_pinned_mem_alloc = 200, - ompx_gnu_managed_mem_alloc = 201, - __omp_allocator_handle_t_max__ = 0xffffffffffffffffUL -} omp_allocator_handle_t; - -typedef enum omp_alloctrait_key_t -{ - omp_atk_sync_hint = 1, - omp_atk_alignment = 2, - omp_atk_access = 3, - omp_atk_pool_size = 4, - omp_atk_fallback = 5, - omp_atk_fb_data = 6, - omp_atk_pinned = 7, - omp_atk_partition = 8 -} omp_alloctrait_key_t; - -typedef enum omp_alloctrait_value_t -{ - omp_atv_default = (long unsigned int) -1, - omp_atv_false = 0, - omp_atv_true = 1, - omp_atv_contended = 3, - omp_atv_uncontended = 4, - omp_atv_serialized = 5, - omp_atv_sequential __attribute__((__deprecated__)) = omp_atv_serialized, - omp_atv_private = 6, - omp_atv_all = 7, - omp_atv_thread = 8, - omp_atv_pteam = 9, - omp_atv_cgroup = 10, - omp_atv_default_mem_fb = 11, - omp_atv_null_fb = 12, - omp_atv_abort_fb = 13, - omp_atv_allocator_fb = 14, - omp_atv_environment = 15, - omp_atv_nearest = 16, - omp_atv_blocked = 17, - omp_atv_interleaved = 18 -} omp_alloctrait_value_t; - -typedef struct omp_alloctrait_t -{ - omp_alloctrait_key_t key; - omp_uintptr_t value; -} omp_alloctrait_t; - -typedef enum omp_event_handle_t -{ - __omp_event_handle_t_max__ = 0xffffffffffffffffUL -} omp_event_handle_t; - -enum -{ - omp_initial_device = -1, - omp_invalid_device = -4, - omp_default_device = -5 -}; - -typedef enum omp_interop_t -{ - omp_interop_none = 0, - __omp_interop_t_max__ = 0xffffffffffffffffUL -} omp_interop_t; - -typedef enum omp_interop_fr_t -{ - omp_ifr_cuda = 1, - omp_ifr_cuda_driver = 2, - omp_ifr_opencl = 3, - omp_ifr_sycl = 4, - omp_ifr_hip = 5, - omp_ifr_level_zero = 6, - omp_ifr_hsa = 7, - omp_ifr_last = omp_ifr_hsa -} omp_interop_fr_t; - -typedef enum omp_interop_property_t -{ - omp_ipr_fr_id = -1, - omp_ipr_fr_name = -2, - omp_ipr_vendor = -3, - omp_ipr_vendor_name = -4, - omp_ipr_device_num = -5, - omp_ipr_platform = -6, - omp_ipr_device = -7, - omp_ipr_device_context = -8, - omp_ipr_targetsync = -9, - omp_ipr_first = -9 -} omp_interop_property_t; - - -typedef enum omp_interop_rc_t -{ - omp_irc_no_value = 1, - omp_irc_success = 0, - omp_irc_empty = -1, - omp_irc_out_of_range = -2, - omp_irc_type_int = -3, - omp_irc_type_ptr = -4, - omp_irc_type_str = -5, - omp_irc_other = -6 -} omp_interop_rc_t; -extern void omp_set_num_threads (int) __attribute__((__nothrow__)); -extern int omp_get_num_threads (void) __attribute__((__nothrow__)); -extern int omp_get_max_threads (void) __attribute__((__nothrow__)); -extern int omp_get_thread_num (void) __attribute__((__nothrow__)); -extern int omp_get_num_procs (void) __attribute__((__nothrow__)); - -extern int omp_in_parallel (void) __attribute__((__nothrow__)); - -extern void omp_set_dynamic (int) __attribute__((__nothrow__)); -extern int omp_get_dynamic (void) __attribute__((__nothrow__)); - -extern void omp_set_nested (int) __attribute__((__nothrow__)) __attribute__((__deprecated__)); -extern int omp_get_nested (void) __attribute__((__nothrow__)) __attribute__((__deprecated__)); - -extern void omp_init_lock (omp_lock_t *) __attribute__((__nothrow__)); -extern void omp_init_lock_with_hint (omp_lock_t *, omp_sync_hint_t) - __attribute__((__nothrow__)); -extern void omp_destroy_lock (omp_lock_t *) __attribute__((__nothrow__)); -extern void omp_set_lock (omp_lock_t *) __attribute__((__nothrow__)); -extern void omp_unset_lock (omp_lock_t *) __attribute__((__nothrow__)); -extern int omp_test_lock (omp_lock_t *) __attribute__((__nothrow__)); - -extern void omp_init_nest_lock (omp_nest_lock_t *) __attribute__((__nothrow__)); -extern void omp_init_nest_lock_with_hint (omp_nest_lock_t *, omp_sync_hint_t) - __attribute__((__nothrow__)); -extern void omp_destroy_nest_lock (omp_nest_lock_t *) __attribute__((__nothrow__)); -extern void omp_set_nest_lock (omp_nest_lock_t *) __attribute__((__nothrow__)); -extern void omp_unset_nest_lock (omp_nest_lock_t *) __attribute__((__nothrow__)); -extern int omp_test_nest_lock (omp_nest_lock_t *) __attribute__((__nothrow__)); - -extern double omp_get_wtime (void) __attribute__((__nothrow__)); -extern double omp_get_wtick (void) __attribute__((__nothrow__)); - -extern void omp_set_schedule (omp_sched_t, int) __attribute__((__nothrow__)); -extern void omp_get_schedule (omp_sched_t *, int *) __attribute__((__nothrow__)); -extern int omp_get_thread_limit (void) __attribute__((__nothrow__)); -extern void omp_set_max_active_levels (int) __attribute__((__nothrow__)); -extern int omp_get_max_active_levels (void) __attribute__((__nothrow__)); -extern int omp_get_supported_active_levels (void) __attribute__((__nothrow__)); -extern int omp_get_level (void) __attribute__((__nothrow__)); -extern int omp_get_ancestor_thread_num (int) __attribute__((__nothrow__)); -extern int omp_get_team_size (int) __attribute__((__nothrow__)); -extern int omp_get_active_level (void) __attribute__((__nothrow__)); - -extern int omp_in_final (void) __attribute__((__nothrow__)); -extern int omp_in_explicit_task (void) __attribute__((__nothrow__)); - -extern int omp_get_cancellation (void) __attribute__((__nothrow__)); -extern omp_proc_bind_t omp_get_proc_bind (void) __attribute__((__nothrow__)); -extern int omp_get_num_places (void) __attribute__((__nothrow__)); -extern int omp_get_place_num_procs (int) __attribute__((__nothrow__)); -extern void omp_get_place_proc_ids (int, int *) __attribute__((__nothrow__)); -extern int omp_get_place_num (void) __attribute__((__nothrow__)); -extern int omp_get_partition_num_places (void) __attribute__((__nothrow__)); -extern void omp_get_partition_place_nums (int *) __attribute__((__nothrow__)); - -extern void omp_set_default_device (int) __attribute__((__nothrow__)); -extern int omp_get_default_device (void) __attribute__((__nothrow__)); -extern int omp_get_num_devices (void) __attribute__((__nothrow__)); -extern int omp_get_device_num (void) __attribute__((__nothrow__)); -extern int omp_get_num_teams (void) __attribute__((__nothrow__)); -extern int omp_get_team_num (void) __attribute__((__nothrow__)); - -extern int omp_is_initial_device (void) __attribute__((__nothrow__)); -extern int omp_get_initial_device (void) __attribute__((__nothrow__)); -extern int omp_get_max_task_priority (void) __attribute__((__nothrow__)); - -extern void omp_fulfill_event (omp_event_handle_t) __attribute__((__nothrow__)); - -extern void omp_set_num_teams (int) __attribute__((__nothrow__)); -extern int omp_get_max_teams (void) __attribute__((__nothrow__)); -extern void omp_set_teams_thread_limit (int) __attribute__((__nothrow__)); -extern int omp_get_teams_thread_limit (void) __attribute__((__nothrow__)); - -extern void *omp_target_alloc (long unsigned int, int) __attribute__((__nothrow__)); -extern void omp_target_free (void *, int) __attribute__((__nothrow__)); -extern int omp_target_is_present (const void *, int) __attribute__((__nothrow__)); -extern int omp_target_memcpy (void *, const void *, long unsigned int, - long unsigned int, long unsigned int, int, int) - __attribute__((__nothrow__)); -extern int omp_target_memcpy_async (void *, const void *, long unsigned int, - long unsigned int, long unsigned int, int, int, - int, omp_depend_t * ) - __attribute__((__nothrow__)); -extern int omp_target_memcpy_rect (void *, const void *, long unsigned int, int, - const long unsigned int *, - const long unsigned int *, - const long unsigned int *, - const long unsigned int *, - const long unsigned int *, int, int) - __attribute__((__nothrow__)); -extern int omp_target_memcpy_rect_async (void *, const void *, long unsigned int, - int, const long unsigned int *, - const long unsigned int *, - const long unsigned int *, - const long unsigned int *, - const long unsigned int *, int, int, int, - omp_depend_t * ) - __attribute__((__nothrow__)); -extern void *omp_target_memset (void *, int, long unsigned int, int) __attribute__((__nothrow__)); -extern void *omp_target_memset_async (void *, int, long unsigned int, int, - int, omp_depend_t * ) - __attribute__((__nothrow__)); -extern int omp_target_associate_ptr (const void *, const void *, long unsigned int, - long unsigned int, int) __attribute__((__nothrow__)); -extern int omp_target_disassociate_ptr (const void *, int) __attribute__((__nothrow__)); -extern void *omp_get_mapped_ptr (const void *, int) __attribute__((__nothrow__)); -extern int omp_target_is_accessible (const void *, long unsigned int, int) - __attribute__((__nothrow__)); - -extern void omp_set_affinity_format (const char *) __attribute__((__nothrow__)); -extern long unsigned int omp_get_affinity_format (char *, long unsigned int) - __attribute__((__nothrow__)); -extern void omp_display_affinity (const char *) __attribute__((__nothrow__)); -extern long unsigned int omp_capture_affinity (char *, long unsigned int, const char *) - __attribute__((__nothrow__)); - -extern int omp_pause_resource (omp_pause_resource_t, int) __attribute__((__nothrow__)); -extern int omp_pause_resource_all (omp_pause_resource_t) __attribute__((__nothrow__)); - -extern omp_allocator_handle_t omp_init_allocator (omp_memspace_handle_t, - int, - const omp_alloctrait_t []) - __attribute__((__nothrow__)); -extern void omp_destroy_allocator (omp_allocator_handle_t) __attribute__((__nothrow__)); -extern void omp_set_default_allocator (omp_allocator_handle_t) __attribute__((__nothrow__)); -extern omp_allocator_handle_t omp_get_default_allocator (void) __attribute__((__nothrow__)); -extern void omp_free (void *, - omp_allocator_handle_t ) - __attribute__((__nothrow__)); -extern void *omp_alloc (long unsigned int, - omp_allocator_handle_t ) - __attribute__((__nothrow__)) __attribute__((__malloc__, __malloc__ (omp_free), - __alloc_size__ (1))); -extern void *omp_aligned_alloc (long unsigned int, long unsigned int, - omp_allocator_handle_t - ) - __attribute__((__nothrow__)) __attribute__((__malloc__, __malloc__ (omp_free), - __alloc_size__ (2), __alloc_align__ (1))); -extern void *omp_calloc (long unsigned int, long unsigned int, - omp_allocator_handle_t ) - __attribute__((__nothrow__)) __attribute__((__malloc__, __malloc__ (omp_free), - __alloc_size__ (1, 2))); -extern void *omp_aligned_calloc (long unsigned int, long unsigned int, long unsigned int, - omp_allocator_handle_t - ) - __attribute__((__nothrow__)) __attribute__((__malloc__, __malloc__ (omp_free), - __alloc_size__ (2, 3), __alloc_align__ (1))); -extern void *omp_realloc (void *, long unsigned int, - omp_allocator_handle_t , - omp_allocator_handle_t ) - __attribute__((__nothrow__)) __attribute__((__malloc__ (omp_free), __alloc_size__ (2))); - -extern void omp_display_env (int) __attribute__((__nothrow__)); - -extern int omp_get_num_interop_properties (const omp_interop_t) __attribute__((__nothrow__)); - -extern omp_intptr_t omp_get_interop_int (const omp_interop_t, - omp_interop_property_t, - omp_interop_rc_t * ) - __attribute__((__nothrow__)); - -extern void *omp_get_interop_ptr (const omp_interop_t, omp_interop_property_t, - omp_interop_rc_t * ) - __attribute__((__nothrow__)); - -extern const char *omp_get_interop_str (const omp_interop_t, - omp_interop_property_t, - omp_interop_rc_t * ) - __attribute__((__nothrow__)); - -extern const char *omp_get_interop_name (const omp_interop_t, - omp_interop_property_t) __attribute__((__nothrow__)); - -extern const char *omp_get_interop_type_desc (const omp_interop_t, - omp_interop_property_t) - __attribute__((__nothrow__)); - -extern const char *omp_get_interop_rc_desc (const omp_interop_t, - omp_interop_rc_t) __attribute__((__nothrow__)); - -extern int omp_get_device_from_uid (const char *) __attribute__((__nothrow__)); -extern const char *omp_get_uid_from_device (int) __attribute__((__nothrow__)); - -struct dirent - { - - __ino_t d_ino; - __off_t d_off; - - - - - unsigned short int d_reclen; - unsigned char d_type; - char d_name[256]; - }; - - -struct dirent64 - { - __ino64_t d_ino; - __off64_t d_off; - unsigned short int d_reclen; - unsigned char d_type; - char d_name[256]; - }; -enum - { - DT_UNKNOWN = 0, - - DT_FIFO = 1, - - DT_CHR = 2, - - DT_DIR = 4, - - DT_BLK = 6, - - DT_REG = 8, - - DT_LNK = 10, - - DT_SOCK = 12, - - DT_WHT = 14 - - }; -typedef struct __dirstream DIR; - - - - - - -extern DIR *opendir (const char *__name) __attribute__ ((__nonnull__ (1))); - - - - - - -extern DIR *fdopendir (int __fd); - - - - - - - -extern int closedir (DIR *__dirp) __attribute__ ((__nonnull__ (1))); -extern struct dirent *readdir (DIR *__dirp) __attribute__ ((__nonnull__ (1))); -extern struct dirent64 *readdir64 (DIR *__dirp) __attribute__ ((__nonnull__ (1))); -extern int readdir_r (DIR *__restrict __dirp, - struct dirent *__restrict __entry, - struct dirent **__restrict __result) - __attribute__ ((__nonnull__ (1, 2, 3))) __attribute__ ((__deprecated__)); -extern int readdir64_r (DIR *__restrict __dirp, - struct dirent64 *__restrict __entry, - struct dirent64 **__restrict __result) - __attribute__ ((__nonnull__ (1, 2, 3))) __attribute__ ((__deprecated__)); - - - - -extern void rewinddir (DIR *__dirp) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - -extern void seekdir (DIR *__dirp, long int __pos) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern long int telldir (DIR *__dirp) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - -extern int dirfd (DIR *__dirp) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); -extern int scandir (const char *__restrict __dir, - struct dirent ***__restrict __namelist, - int (*__selector) (const struct dirent *), - int (*__cmp) (const struct dirent **, - const struct dirent **)) - __attribute__ ((__nonnull__ (1, 2))); -extern int scandir64 (const char *__restrict __dir, - struct dirent64 ***__restrict __namelist, - int (*__selector) (const struct dirent64 *), - int (*__cmp) (const struct dirent64 **, - const struct dirent64 **)) - __attribute__ ((__nonnull__ (1, 2))); -extern int scandirat (int __dfd, const char *__restrict __dir, - struct dirent ***__restrict __namelist, - int (*__selector) (const struct dirent *), - int (*__cmp) (const struct dirent **, - const struct dirent **)) - __attribute__ ((__nonnull__ (2, 3))); -extern int scandirat64 (int __dfd, const char *__restrict __dir, - struct dirent64 ***__restrict __namelist, - int (*__selector) (const struct dirent64 *), - int (*__cmp) (const struct dirent64 **, - const struct dirent64 **)) - __attribute__ ((__nonnull__ (2, 3))); - - - - -extern int alphasort (const struct dirent **__e1, - const struct dirent **__e2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern int alphasort64 (const struct dirent64 **__e1, - const struct dirent64 **__e2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern __ssize_t getdirentries (int __fd, char *__restrict __buf, - size_t __nbytes, - __off_t *__restrict __basep) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))); -extern __ssize_t getdirentries64 (int __fd, char *__restrict __buf, - size_t __nbytes, - __off64_t *__restrict __basep) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2, 4))); - - - - - - -extern int versionsort (const struct dirent **__e1, - const struct dirent **__e2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); -extern int versionsort64 (const struct dirent64 **__e1, - const struct dirent64 **__e2) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1, 2))); - - - - - - - - - - - -extern __ssize_t getdents64 (int __fd, void *__buffer, size_t __length) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (2))); - - - - - - -typedef enum -{ - P_ALL, - P_PID, - P_PGID -} idtype_t; -extern __pid_t wait (int *__stat_loc); -extern __pid_t waitpid (__pid_t __pid, int *__stat_loc, int __options); -extern int waitid (idtype_t __idtype, __id_t __id, siginfo_t *__infop, - int __options); - - - - - - -struct rusage; - - - - - - -extern __pid_t wait3 (int *__stat_loc, int __options, - struct rusage * __usage) __attribute__ ((__nothrow__)); - - - - -extern __pid_t wait4 (__pid_t __pid, int *__stat_loc, int __options, - struct rusage *__usage) __attribute__ ((__nothrow__)); - - - - - - - - - -struct passwd -{ - char *pw_name; - char *pw_passwd; - - __uid_t pw_uid; - __gid_t pw_gid; - char *pw_gecos; - char *pw_dir; - char *pw_shell; -}; -extern void setpwent (void); - - - - - -extern void endpwent (void); - - - - - -extern struct passwd *getpwent (void); -extern struct passwd *fgetpwent (FILE *__stream) __attribute__ ((__nonnull__ (1))); - - - - - - - -extern int putpwent (const struct passwd *__restrict __p, - FILE *__restrict __f); - - - - - - -extern struct passwd *getpwuid (__uid_t __uid); - - - - - -extern struct passwd *getpwnam (const char *__name) __attribute__ ((__nonnull__ (1))); -extern int getpwent_r (struct passwd *__restrict __resultbuf, - char *__restrict __buffer, size_t __buflen, - struct passwd **__restrict __result) - __attribute__ ((__nonnull__ (1, 2, 4))); - - -extern int getpwuid_r (__uid_t __uid, - struct passwd *__restrict __resultbuf, - char *__restrict __buffer, size_t __buflen, - struct passwd **__restrict __result) - __attribute__ ((__nonnull__ (2, 3, 5))); - -extern int getpwnam_r (const char *__restrict __name, - struct passwd *__restrict __resultbuf, - char *__restrict __buffer, size_t __buflen, - struct passwd **__restrict __result) - __attribute__ ((__nonnull__ (1, 2, 3, 5))); -extern int fgetpwent_r (FILE *__restrict __stream, - struct passwd *__restrict __resultbuf, - char *__restrict __buffer, size_t __buflen, - struct passwd **__restrict __result) - __attribute__ ((__nonnull__ (1, 2, 3, 5))); -extern int getpw (__uid_t __uid, char *__buffer); - - - - - - - - - - - -typedef float MagickFloatType; -typedef double MagickDoubleType; -typedef MagickFloatType Quantum; -typedef MagickDoubleType MagickRealType; -typedef unsigned int MagickStatusType; - - -typedef long long MagickOffsetType; -typedef unsigned long long MagickSizeType; -typedef uintptr_t MagickAddressType; - - - - - -typedef MagickSizeType QuantumAny; - -typedef enum -{ - UndefinedClass, - DirectClass, - PseudoClass -} ClassType; - -typedef enum -{ - MagickFalse = 0, - MagickTrue = 1 -} MagickBooleanType; -typedef struct _BlobInfo BlobInfo; - -typedef struct _ExceptionInfo ExceptionInfo; - -typedef struct _Image Image; - -typedef struct _ImageInfo ImageInfo; - - - -struct timezone - { - int tz_minuteswest; - int tz_dsttime; - }; -extern int gettimeofday (struct timeval *__restrict __tv, - void *__restrict __tz) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - - - - - -extern int settimeofday (const struct timeval *__tv, - const struct timezone *__tz) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int adjtime (const struct timeval *__delta, - struct timeval *__olddelta) __attribute__ ((__nothrow__ , __leaf__)); - - - - -enum __itimer_which - { - - ITIMER_REAL = 0, - - - ITIMER_VIRTUAL = 1, - - - - ITIMER_PROF = 2 - - }; - - - -struct itimerval - { - - struct timeval it_interval; - - struct timeval it_value; - }; - - - - -typedef enum __itimer_which __itimer_which_t; - - - - - - -extern int getitimer (__itimer_which_t __which, - struct itimerval *__value) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int setitimer (__itimer_which_t __which, - const struct itimerval *__restrict __new, - struct itimerval *__restrict __old) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int utimes (const char *__file, const struct timeval __tvp[2]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - - -extern int lutimes (const char *__file, const struct timeval __tvp[2]) - __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__nonnull__ (1))); - - -extern int futimes (int __fd, const struct timeval __tvp[2]) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int futimesat (int __fd, const char *__file, - const struct timeval __tvp[2]) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -struct tms - { - clock_t tms_utime; - clock_t tms_stime; - - clock_t tms_cutime; - clock_t tms_cstime; - }; - - - - - - -extern clock_t times (struct tms *__buffer) __attribute__ ((__nothrow__ , __leaf__)); - - - - -enum __rlimit_resource -{ - - RLIMIT_CPU = 0, - - - - RLIMIT_FSIZE = 1, - - - - RLIMIT_DATA = 2, - - - - RLIMIT_STACK = 3, - - - - RLIMIT_CORE = 4, - - - - - - - __RLIMIT_RSS = 5, - - - - RLIMIT_NOFILE = 7, - __RLIMIT_OFILE = RLIMIT_NOFILE, - - - - - RLIMIT_AS = 9, - - - - __RLIMIT_NPROC = 6, - - - - __RLIMIT_MEMLOCK = 8, - - - - __RLIMIT_LOCKS = 10, - - - - __RLIMIT_SIGPENDING = 11, - - - - __RLIMIT_MSGQUEUE = 12, - - - - - - __RLIMIT_NICE = 13, - - - - - __RLIMIT_RTPRIO = 14, - - - - - - __RLIMIT_RTTIME = 15, - - - __RLIMIT_NLIMITS = 16, - __RLIM_NLIMITS = __RLIMIT_NLIMITS - - -}; -typedef __rlim_t rlim_t; - - - - -typedef __rlim64_t rlim64_t; - - -struct rlimit - { - - rlim_t rlim_cur; - - rlim_t rlim_max; - }; - - -struct rlimit64 - { - - rlim64_t rlim_cur; - - rlim64_t rlim_max; - }; - - - -enum __rusage_who -{ - - RUSAGE_SELF = 0, - - - - RUSAGE_CHILDREN = -1 - - - - , - - RUSAGE_THREAD = 1 - - - - -}; - - -struct rusage - { - - struct timeval ru_utime; - - struct timeval ru_stime; - - __extension__ union - { - long int ru_maxrss; - __syscall_slong_t __ru_maxrss_word; - }; - - - __extension__ union - { - long int ru_ixrss; - __syscall_slong_t __ru_ixrss_word; - }; - - __extension__ union - { - long int ru_idrss; - __syscall_slong_t __ru_idrss_word; - }; - - __extension__ union - { - long int ru_isrss; - __syscall_slong_t __ru_isrss_word; - }; - - - __extension__ union - { - long int ru_minflt; - __syscall_slong_t __ru_minflt_word; - }; - - __extension__ union - { - long int ru_majflt; - __syscall_slong_t __ru_majflt_word; - }; - - __extension__ union - { - long int ru_nswap; - __syscall_slong_t __ru_nswap_word; - }; - - - __extension__ union - { - long int ru_inblock; - __syscall_slong_t __ru_inblock_word; - }; - - __extension__ union - { - long int ru_oublock; - __syscall_slong_t __ru_oublock_word; - }; - - __extension__ union - { - long int ru_msgsnd; - __syscall_slong_t __ru_msgsnd_word; - }; - - __extension__ union - { - long int ru_msgrcv; - __syscall_slong_t __ru_msgrcv_word; - }; - - __extension__ union - { - long int ru_nsignals; - __syscall_slong_t __ru_nsignals_word; - }; - - - - __extension__ union - { - long int ru_nvcsw; - __syscall_slong_t __ru_nvcsw_word; - }; - - - __extension__ union - { - long int ru_nivcsw; - __syscall_slong_t __ru_nivcsw_word; - }; - }; - - - - - - - -enum __priority_which -{ - PRIO_PROCESS = 0, - - PRIO_PGRP = 1, - - PRIO_USER = 2 - -}; - - - - - - - -extern int prlimit (__pid_t __pid, enum __rlimit_resource __resource, - const struct rlimit *__new_limit, - struct rlimit *__old_limit) __attribute__ ((__nothrow__ , __leaf__)); -extern int prlimit64 (__pid_t __pid, enum __rlimit_resource __resource, - const struct rlimit64 *__new_limit, - struct rlimit64 *__old_limit) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - - - - - - - -typedef enum __rlimit_resource __rlimit_resource_t; -typedef enum __rusage_who __rusage_who_t; -typedef enum __priority_which __priority_which_t; -extern int getrlimit (__rlimit_resource_t __resource, - struct rlimit *__rlimits) __attribute__ ((__nothrow__ , __leaf__)); -extern int getrlimit64 (__rlimit_resource_t __resource, - struct rlimit64 *__rlimits) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern int setrlimit (__rlimit_resource_t __resource, - const struct rlimit *__rlimits) __attribute__ ((__nothrow__ , __leaf__)); -extern int setrlimit64 (__rlimit_resource_t __resource, - const struct rlimit64 *__rlimits) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int getrusage (__rusage_who_t __who, struct rusage *__usage) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int getpriority (__priority_which_t __which, id_t __who) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int setpriority (__priority_which_t __which, id_t __who, int __prio) - __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - -int memfd_create (const char *__name, unsigned int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - -int mlock2 (const void *__addr, size_t __length, unsigned int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -int pkey_alloc (unsigned int __flags, unsigned int __access_rights) __attribute__ ((__nothrow__ , __leaf__)); - - - -int pkey_set (int __key, unsigned int __access_rights) __attribute__ ((__nothrow__ , __leaf__)); - - - -int pkey_get (int __key) __attribute__ ((__nothrow__ , __leaf__)); - - - -int pkey_free (int __key) __attribute__ ((__nothrow__ , __leaf__)); - - - -int pkey_mprotect (void *__addr, size_t __len, int __prot, int __pkey) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern void *mmap (void *__addr, size_t __len, int __prot, - int __flags, int __fd, __off_t __offset) __attribute__ ((__nothrow__ , __leaf__)); -extern void *mmap64 (void *__addr, size_t __len, int __prot, - int __flags, int __fd, __off64_t __offset) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int munmap (void *__addr, size_t __len) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int mprotect (void *__addr, size_t __len, int __prot) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern int msync (void *__addr, size_t __len, int __flags); - - - - -extern int madvise (void *__addr, size_t __len, int __advice) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int posix_madvise (void *__addr, size_t __len, int __advice) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int mlock (const void *__addr, size_t __len) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int munlock (const void *__addr, size_t __len) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int mlockall (int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int munlockall (void) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern int mincore (void *__start, size_t __len, unsigned char *__vec) - __attribute__ ((__nothrow__ , __leaf__)); -extern void *mremap (void *__addr, size_t __old_len, size_t __new_len, - int __flags, ...) __attribute__ ((__nothrow__ , __leaf__)); - - - -extern int remap_file_pages (void *__start, size_t __size, int __prot, - size_t __pgoff, int __flags) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int shm_open (const char *__name, int __oflag, mode_t __mode); - - -extern int shm_unlink (const char *__name); - - - - - - - - - - - - -extern ssize_t sendfile (int __out_fd, int __in_fd, off_t *__offset, - size_t __count) __attribute__ ((__nothrow__ , __leaf__)); -extern ssize_t sendfile64 (int __out_fd, int __in_fd, __off64_t *__offset, - size_t __count) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - - - - - - - -enum __socket_type -{ - SOCK_STREAM = 1, - - - SOCK_DGRAM = 2, - - - SOCK_RAW = 3, - - SOCK_RDM = 4, - - SOCK_SEQPACKET = 5, - - - SOCK_DCCP = 6, - - SOCK_PACKET = 10, - - - - - - - - SOCK_CLOEXEC = 02000000, - - - SOCK_NONBLOCK = 00004000 - - -}; -typedef unsigned short int sa_family_t; - - -struct sockaddr - { - sa_family_t sa_family; - char sa_data[14]; - }; -struct sockaddr_storage - { - sa_family_t ss_family; - char __ss_padding[(128 - (sizeof (unsigned short int)) - sizeof (unsigned long int))]; - unsigned long int __ss_align; - }; - - - -enum - { - MSG_OOB = 0x01, - - MSG_PEEK = 0x02, - - MSG_DONTROUTE = 0x04, - - - - MSG_TRYHARD = MSG_DONTROUTE, - - - MSG_CTRUNC = 0x08, - - MSG_PROXY = 0x10, - - MSG_TRUNC = 0x20, - - MSG_DONTWAIT = 0x40, - - MSG_EOR = 0x80, - - MSG_WAITALL = 0x100, - - MSG_FIN = 0x200, - - MSG_SYN = 0x400, - - MSG_CONFIRM = 0x800, - - MSG_RST = 0x1000, - - MSG_ERRQUEUE = 0x2000, - - MSG_NOSIGNAL = 0x4000, - - MSG_MORE = 0x8000, - - MSG_WAITFORONE = 0x10000, - - MSG_BATCH = 0x40000, - - MSG_ZEROCOPY = 0x4000000, - - MSG_FASTOPEN = 0x20000000, - - - MSG_CMSG_CLOEXEC = 0x40000000 - - - - }; - - - - -struct msghdr - { - void *msg_name; - socklen_t msg_namelen; - - struct iovec *msg_iov; - size_t msg_iovlen; - - void *msg_control; - size_t msg_controllen; - - - - - int msg_flags; - }; - - -struct cmsghdr - { - size_t cmsg_len; - - - - - int cmsg_level; - int cmsg_type; - - __extension__ unsigned char __cmsg_data []; - - }; -extern struct cmsghdr *__cmsg_nxthdr (struct msghdr *__mhdr, - struct cmsghdr *__cmsg) __attribute__ ((__nothrow__ , __leaf__)); -enum - { - SCM_RIGHTS = 0x01 - - - , SCM_CREDENTIALS = 0x02 - - - }; - - - -struct ucred -{ - pid_t pid; - uid_t uid; - gid_t gid; -}; - - - - - - - - - - - - - - - -struct linger - { - int l_onoff; - int l_linger; - }; - - - - - - - -struct osockaddr -{ - unsigned short int sa_family; - unsigned char sa_data[14]; -}; - - - - -enum -{ - SHUT_RD = 0, - - SHUT_WR, - - SHUT_RDWR - -}; -typedef union { struct sockaddr *__restrict __sockaddr__; struct sockaddr_at *__restrict __sockaddr_at__; struct sockaddr_ax25 *__restrict __sockaddr_ax25__; struct sockaddr_dl *__restrict __sockaddr_dl__; struct sockaddr_eon *__restrict __sockaddr_eon__; struct sockaddr_in *__restrict __sockaddr_in__; struct sockaddr_in6 *__restrict __sockaddr_in6__; struct sockaddr_inarp *__restrict __sockaddr_inarp__; struct sockaddr_ipx *__restrict __sockaddr_ipx__; struct sockaddr_iso *__restrict __sockaddr_iso__; struct sockaddr_ns *__restrict __sockaddr_ns__; struct sockaddr_un *__restrict __sockaddr_un__; struct sockaddr_x25 *__restrict __sockaddr_x25__; - } __SOCKADDR_ARG __attribute__ ((__transparent_union__)); - - -typedef union { const struct sockaddr *__restrict __sockaddr__; const struct sockaddr_at *__restrict __sockaddr_at__; const struct sockaddr_ax25 *__restrict __sockaddr_ax25__; const struct sockaddr_dl *__restrict __sockaddr_dl__; const struct sockaddr_eon *__restrict __sockaddr_eon__; const struct sockaddr_in *__restrict __sockaddr_in__; const struct sockaddr_in6 *__restrict __sockaddr_in6__; const struct sockaddr_inarp *__restrict __sockaddr_inarp__; const struct sockaddr_ipx *__restrict __sockaddr_ipx__; const struct sockaddr_iso *__restrict __sockaddr_iso__; const struct sockaddr_ns *__restrict __sockaddr_ns__; const struct sockaddr_un *__restrict __sockaddr_un__; const struct sockaddr_x25 *__restrict __sockaddr_x25__; - } __CONST_SOCKADDR_ARG __attribute__ ((__transparent_union__)); - - - - - -struct mmsghdr - { - struct msghdr msg_hdr; - unsigned int msg_len; - - }; - - - - - - -extern int socket (int __domain, int __type, int __protocol) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int socketpair (int __domain, int __type, int __protocol, - int __fds[2]) __attribute__ ((__nothrow__ , __leaf__)); - - -extern int bind (int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len) - __attribute__ ((__nothrow__ , __leaf__)); - - -extern int getsockname (int __fd, __SOCKADDR_ARG __addr, - socklen_t *__restrict __len) __attribute__ ((__nothrow__ , __leaf__)); -extern int connect (int __fd, __CONST_SOCKADDR_ARG __addr, socklen_t __len); - - - -extern int getpeername (int __fd, __SOCKADDR_ARG __addr, - socklen_t *__restrict __len) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - -extern ssize_t send (int __fd, const void *__buf, size_t __n, int __flags); - - - - - - -extern ssize_t recv (int __fd, void *__buf, size_t __n, int __flags); - - - - - - -extern ssize_t sendto (int __fd, const void *__buf, size_t __n, - int __flags, __CONST_SOCKADDR_ARG __addr, - socklen_t __addr_len); -extern ssize_t recvfrom (int __fd, void *__restrict __buf, size_t __n, - int __flags, __SOCKADDR_ARG __addr, - socklen_t *__restrict __addr_len); - - - - - - - -extern ssize_t sendmsg (int __fd, const struct msghdr *__message, - int __flags); - - - - - - - -extern int sendmmsg (int __fd, struct mmsghdr *__vmessages, - unsigned int __vlen, int __flags); - - - - - - - -extern ssize_t recvmsg (int __fd, struct msghdr *__message, int __flags); - - - - - - - -extern int recvmmsg (int __fd, struct mmsghdr *__vmessages, - unsigned int __vlen, int __flags, - struct timespec *__tmo); - - - - - - -extern int getsockopt (int __fd, int __level, int __optname, - void *__restrict __optval, - socklen_t *__restrict __optlen) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int setsockopt (int __fd, int __level, int __optname, - const void *__optval, socklen_t __optlen) __attribute__ ((__nothrow__ , __leaf__)); - - - - - -extern int listen (int __fd, int __n) __attribute__ ((__nothrow__ , __leaf__)); -extern int accept (int __fd, __SOCKADDR_ARG __addr, - socklen_t *__restrict __addr_len); - - - - - - -extern int accept4 (int __fd, __SOCKADDR_ARG __addr, - socklen_t *__restrict __addr_len, int __flags); -extern int shutdown (int __fd, int __how) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern int sockatmark (int __fd) __attribute__ ((__nothrow__ , __leaf__)); - - - - - - - -extern int isfdtype (int __fd, int __fdtype) __attribute__ ((__nothrow__ , __leaf__)); - - - - -extern ssize_t readv (int __fd, const struct iovec *__iovec, int __count) - ; -extern ssize_t writev (int __fd, const struct iovec *__iovec, int __count) - ; -extern ssize_t preadv (int __fd, const struct iovec *__iovec, int __count, - __off_t __offset) ; -extern ssize_t pwritev (int __fd, const struct iovec *__iovec, int __count, - __off_t __offset) ; -extern ssize_t preadv64 (int __fd, const struct iovec *__iovec, int __count, - __off64_t __offset) ; -extern ssize_t pwritev64 (int __fd, const struct iovec *__iovec, int __count, - __off64_t __offset) ; - - - - - - - -extern ssize_t preadv2 (int __fp, const struct iovec *__iovec, int __count, - __off_t __offset, int ___flags) ; - - -extern ssize_t pwritev2 (int __fd, const struct iovec *__iodev, int __count, - __off_t __offset, int __flags) ; -extern ssize_t preadv64v2 (int __fp, const struct iovec *__iovec, - int __count, __off64_t __offset, - int ___flags) ; - - -extern ssize_t pwritev64v2 (int __fd, const struct iovec *__iodev, - int __count, __off64_t __offset, - int __flags) ; - - - - - - - - - - - -extern ssize_t process_vm_readv (pid_t __pid, const struct iovec *__lvec, - unsigned long int __liovcnt, - const struct iovec *__rvec, - unsigned long int __riovcnt, - unsigned long int __flags) - __attribute__ ((__nothrow__ , __leaf__)); - - -extern ssize_t process_vm_writev (pid_t __pid, const struct iovec *__lvec, - unsigned long int __liovcnt, - const struct iovec *__rvec, - unsigned long int __riovcnt, - unsigned long int __flags) - __attribute__ ((__nothrow__ , __leaf__)); - - -typedef enum -{ - - NoValue = 0x0000, - - XValue = 0x0001, - XiValue = 0x0001, + XValue = 0x0001, + XiValue = 0x0001, YValue = 0x0002, PsiValue = 0x0002, @@ -10925,8 +8421,7 @@ typedef enum AllValues = 0x7fffffff } GeometryFlags; -typedef enum -{ +typedef enum { UndefinedGravity, ForgetGravity = 0, NorthWestGravity = 1, @@ -10940,83 +8435,55 @@ typedef enum SouthEastGravity = 9 } GravityType; -typedef struct _AffineMatrix -{ - double - sx, - rx, - ry, - sy, - tx, - ty; +typedef struct _AffineMatrix { + double sx, rx, ry, sy, tx, ty; } AffineMatrix; -typedef struct _GeometryInfo -{ - double - rho, - sigma, - xi, - psi, - chi; +typedef struct _GeometryInfo { + double rho, sigma, xi, psi, chi; } GeometryInfo; -typedef struct _OffsetInfo -{ - ssize_t - x, - y; +typedef struct _OffsetInfo { + ssize_t x, y; } OffsetInfo; -typedef struct _PointInfo -{ - double - x, - y; +typedef struct _PointInfo { + double x, y; } PointInfo; -typedef struct _RectangleInfo -{ - size_t - width, - height; +typedef struct _RectangleInfo { + size_t width, height; - ssize_t - x, - y; + ssize_t x, y; } RectangleInfo; -extern __attribute__ ((visibility ("default"))) char - *GetPageGeometry(const char *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - IsGeometry(const char *), - IsSceneGeometry(const char *,const MagickBooleanType); - -extern __attribute__ ((visibility ("default"))) MagickStatusType - GetGeometry(const char *,ssize_t *,ssize_t *,size_t *,size_t *), - ParseAbsoluteGeometry(const char *,RectangleInfo *), - ParseAffineGeometry(const char *,AffineMatrix *,ExceptionInfo *), - ParseGeometry(const char *,GeometryInfo *), - ParseGravityGeometry(const Image *,const char *,RectangleInfo *, - ExceptionInfo *), - ParseMetaGeometry(const char *,ssize_t *,ssize_t *,size_t *,size_t *), - ParsePageGeometry(const Image *,const char *,RectangleInfo *,ExceptionInfo *), - ParseRegionGeometry(const Image *,const char *,RectangleInfo *, - ExceptionInfo *); +extern __attribute__((visibility("default"))) char * +GetPageGeometry(const char *); + +extern __attribute__((visibility("default"))) MagickBooleanType +IsGeometry(const char *), + IsSceneGeometry(const char *, const MagickBooleanType); + +extern __attribute__((visibility("default"))) MagickStatusType +GetGeometry(const char *, ssize_t *, ssize_t *, size_t *, size_t *), + ParseAbsoluteGeometry(const char *, RectangleInfo *), + ParseAffineGeometry(const char *, AffineMatrix *, ExceptionInfo *), + ParseGeometry(const char *, GeometryInfo *), + ParseGravityGeometry(const Image *, const char *, RectangleInfo *, + ExceptionInfo *), + ParseMetaGeometry(const char *, ssize_t *, ssize_t *, size_t *, size_t *), + ParsePageGeometry(const Image *, const char *, RectangleInfo *, + ExceptionInfo *), + ParseRegionGeometry(const Image *, const char *, RectangleInfo *, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +GravityAdjustGeometry(const size_t, const size_t, const GravityType, + RectangleInfo *), + SetGeometry(const Image *, RectangleInfo *), + SetGeometryInfo(GeometryInfo *); -extern __attribute__ ((visibility ("default"))) void - GravityAdjustGeometry(const size_t,const size_t,const GravityType, - RectangleInfo *), - SetGeometry(const Image *,RectangleInfo *), - SetGeometryInfo(GeometryInfo *); - - - - - -typedef enum -{ +typedef enum { UndefinedKernel, UnityKernel, GaussianKernel, @@ -11057,8 +8524,7 @@ typedef enum UserDefinedKernel } KernelInfoType; -typedef enum -{ +typedef enum { UndefinedMorphology, ConvolveMorphology, @@ -11090,53 +8556,37 @@ typedef enum VoronoiMorphology } MorphologyMethod; -typedef struct _KernelInfo -{ - KernelInfoType - type; +typedef struct _KernelInfo { + KernelInfoType type; - size_t - width, - height; + size_t width, height; - ssize_t - x, - y; + ssize_t x, y; - MagickRealType - *values; + MagickRealType *values; - double - minimum, - maximum, - negative_range, - positive_range, - angle; + double minimum, maximum, negative_range, positive_range, angle; - struct _KernelInfo - *next; + struct _KernelInfo *next; - size_t - signature; + size_t signature; } KernelInfo; -extern __attribute__ ((visibility ("default"))) KernelInfo - *AcquireKernelInfo(const char *,ExceptionInfo *), - *AcquireKernelBuiltIn(const KernelInfoType,const GeometryInfo *, - ExceptionInfo *), - *CloneKernelInfo(const KernelInfo *), - *DestroyKernelInfo(KernelInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *MorphologyImage(const Image *,const MorphologyMethod,const ssize_t, - const KernelInfo *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) void - ScaleGeometryKernelInfo(KernelInfo *,const char *), - ScaleKernelInfo(KernelInfo *,const double,const GeometryFlags), - UnityAddKernelInfo(KernelInfo *,const double); -typedef enum -{ +extern __attribute__((visibility("default"))) KernelInfo * +AcquireKernelInfo(const char *, ExceptionInfo *), + *AcquireKernelBuiltIn(const KernelInfoType, const GeometryInfo *, + ExceptionInfo *), + *CloneKernelInfo(const KernelInfo *), *DestroyKernelInfo(KernelInfo *); + +extern __attribute__((visibility("default"))) Image * +MorphologyImage(const Image *, const MorphologyMethod, const ssize_t, + const KernelInfo *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +ScaleGeometryKernelInfo(KernelInfo *, const char *), + ScaleKernelInfo(KernelInfo *, const double, const GeometryFlags), + UnityAddKernelInfo(KernelInfo *, const double); +typedef enum { UndefinedColorspace, CMYColorspace, CMYKColorspace, @@ -11177,16 +8627,15 @@ typedef enum ProPhotoColorspace } ColorspaceType; -extern __attribute__ ((visibility ("default"))) ColorspaceType - GetImageColorspaceType(const Image *,ExceptionInfo *); +extern __attribute__((visibility("default"))) ColorspaceType +GetImageColorspaceType(const Image *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - SetImageColorspace(Image *,const ColorspaceType,ExceptionInfo *), - SetImageGray(Image *,ExceptionInfo *), - SetImageMonochrome(Image *,ExceptionInfo *), - TransformImageColorspace(Image *,const ColorspaceType,ExceptionInfo *); -typedef enum -{ +extern __attribute__((visibility("default"))) MagickBooleanType +SetImageColorspace(Image *, const ColorspaceType, ExceptionInfo *), + SetImageGray(Image *, ExceptionInfo *), + SetImageMonochrome(Image *, ExceptionInfo *), + TransformImageColorspace(Image *, const ColorspaceType, ExceptionInfo *); +typedef enum { UndefinedChannel = 0x0000, RedChannel = 0x0001, GrayChannel = 0x0001, @@ -11209,12 +8658,6 @@ typedef enum CompositeChannels = 0x001F, AllChannels = 0x7ffffff, - - - - - - TrueAlphaChannel = 0x0100, RGBChannels = 0x0200, GrayChannels = 0x0400, @@ -11222,8 +8665,7 @@ typedef enum DefaultChannels = AllChannels } ChannelType; -typedef enum -{ +typedef enum { UndefinedPixelChannel = 0, RedPixelChannel = 0, CyanPixelChannel = 0, @@ -11249,11 +8691,10 @@ typedef enum MetaPixelChannels = 10, IntensityPixelChannel = 64, CompositePixelChannel = 64, - SyncPixelChannel = 64 +1 + SyncPixelChannel = 64 + 1 } PixelChannel; -typedef enum -{ +typedef enum { UndefinedPixelIntensityMethod = 0, AveragePixelIntensityMethod, BrightnessPixelIntensityMethod, @@ -11266,8 +8707,7 @@ typedef enum RMSPixelIntensityMethod } PixelIntensityMethod; -typedef enum -{ +typedef enum { UndefinedInterpolatePixel, AverageInterpolatePixel, Average9InterpolatePixel, @@ -11282,24 +8722,21 @@ typedef enum SplineInterpolatePixel } PixelInterpolateMethod; -typedef enum -{ +typedef enum { UndefinedPixelMask = 0x000000, ReadPixelMask = 0x000001, WritePixelMask = 0x000002, CompositePixelMask = 0x000004 } PixelMask; -typedef enum -{ +typedef enum { UndefinedPixelTrait = 0x000000, CopyPixelTrait = 0x000001, UpdatePixelTrait = 0x000002, BlendPixelTrait = 0x000004 } PixelTrait; -typedef enum -{ +typedef enum { UndefinedPixel, CharPixel, DoublePixel, @@ -11310,119 +8747,88 @@ typedef enum ShortPixel } StorageType; +typedef struct _PixelChannelMap { + PixelChannel channel; + PixelTrait traits; - -typedef struct _PixelChannelMap -{ - PixelChannel - channel; - - PixelTrait - traits; - - ssize_t - offset; + ssize_t offset; } PixelChannelMap; -typedef struct _PixelInfo -{ - ClassType - storage_class; +typedef struct _PixelInfo { + ClassType storage_class; - ColorspaceType - colorspace; + ColorspaceType colorspace; - PixelTrait - alpha_trait; + PixelTrait alpha_trait; - double - fuzz; + double fuzz; - size_t - depth; + size_t depth; - MagickSizeType - count; + MagickSizeType count; - MagickRealType - red, - green, - blue, - black, - alpha, - index; + MagickRealType red, green, blue, black, alpha, index; } PixelInfo; -typedef struct _PixelPacket -{ - unsigned int - red, - green, - blue, - alpha, - black; +typedef struct _PixelPacket { + unsigned int red, green, blue, alpha, black; } PixelPacket; -typedef struct _CacheView - CacheView_; +typedef struct _CacheView CacheView_; + +extern __attribute__((visibility("default"))) ChannelType +SetPixelChannelMask(Image *, const ChannelType); + +extern __attribute__((visibility("default"))) MagickBooleanType +ExportImagePixels(const Image *, const ssize_t, const ssize_t, const size_t, + const size_t, const char *, const StorageType, void *, + ExceptionInfo *), + ImportImagePixels(Image *, const ssize_t, const ssize_t, const size_t, + const size_t, const char *, const StorageType, + const void *, ExceptionInfo *), + InterpolatePixelChannel(const Image *__restrict__, const CacheView_ *, + const PixelChannel, const PixelInterpolateMethod, + const double, const double, double *, + ExceptionInfo *), + InterpolatePixelChannels(const Image *__restrict__, const CacheView_ *, + const Image *__restrict__, + const PixelInterpolateMethod, const double, + const double, Quantum *, ExceptionInfo *), + InterpolatePixelInfo(const Image *, const CacheView_ *, + const PixelInterpolateMethod, const double, + const double, PixelInfo *, ExceptionInfo *), + IsFuzzyEquivalencePixel(const Image *, const Quantum *, const Image *, + const Quantum *) __attribute__((__pure__)), + IsFuzzyEquivalencePixelInfo(const PixelInfo *, const PixelInfo *) + __attribute__((__pure__)), + SetPixelMetaChannels(Image *, const size_t, ExceptionInfo *), + SortImagePixels(Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickRealType +GetPixelInfoIntensity(const Image *__restrict__, const PixelInfo *__restrict__) + __attribute__((__hot__)), + GetPixelIntensity(const Image *__restrict__, const Quantum *__restrict__) + __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) PixelChannelMap * +AcquirePixelChannelMap(void), + *ClonePixelChannelMap(PixelChannelMap *), + *DestroyPixelChannelMap(PixelChannelMap *); + +extern __attribute__((visibility("default"))) PixelInfo * +ClonePixelInfo(const PixelInfo *); + +extern __attribute__((visibility("default"))) MagickRealType +DecodePixelGamma(const MagickRealType) __attribute__((__hot__)), + EncodePixelGamma(const MagickRealType) __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) void +ConformPixelInfo(Image *, const PixelInfo *, PixelInfo *, ExceptionInfo *), + GetPixelInfo(const Image *, PixelInfo *), + InitializePixelChannelMap(Image *); - - - -extern __attribute__ ((visibility ("default"))) ChannelType - SetPixelChannelMask(Image *,const ChannelType); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ExportImagePixels(const Image *,const ssize_t,const ssize_t,const size_t, - const size_t,const char *,const StorageType,void *,ExceptionInfo *), - ImportImagePixels(Image *,const ssize_t,const ssize_t,const size_t, - const size_t,const char *,const StorageType,const void *,ExceptionInfo *), - InterpolatePixelChannel(const Image *__restrict__,const CacheView_ *, - const PixelChannel,const PixelInterpolateMethod,const double,const double, - double *,ExceptionInfo *), - InterpolatePixelChannels(const Image *__restrict__,const CacheView_ *, - const Image * __restrict__,const PixelInterpolateMethod,const double, - const double,Quantum *,ExceptionInfo *), - InterpolatePixelInfo(const Image *,const CacheView_ *, - const PixelInterpolateMethod,const double,const double,PixelInfo *, - ExceptionInfo *), - IsFuzzyEquivalencePixel(const Image *,const Quantum *,const Image *, - const Quantum *) __attribute__((__pure__)), - IsFuzzyEquivalencePixelInfo(const PixelInfo *,const PixelInfo *) - __attribute__((__pure__)), - SetPixelMetaChannels(Image *,const size_t,ExceptionInfo *), - SortImagePixels(Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickRealType - GetPixelInfoIntensity(const Image *__restrict__, - const PixelInfo *__restrict__) __attribute__((__hot__)), - GetPixelIntensity(const Image *__restrict__, - const Quantum *__restrict__) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) PixelChannelMap - *AcquirePixelChannelMap(void), - *ClonePixelChannelMap(PixelChannelMap *), - *DestroyPixelChannelMap(PixelChannelMap *); - -extern __attribute__ ((visibility ("default"))) PixelInfo - *ClonePixelInfo(const PixelInfo *); - -extern __attribute__ ((visibility ("default"))) MagickRealType - DecodePixelGamma(const MagickRealType) __attribute__((__hot__)), - EncodePixelGamma(const MagickRealType) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) void - ConformPixelInfo(Image *,const PixelInfo *,PixelInfo *,ExceptionInfo *), - GetPixelInfo(const Image *,PixelInfo *), - InitializePixelChannelMap(Image *); - - - - - -typedef enum -{ +typedef enum { UndefinedVirtualPixelMethod, BackgroundVirtualPixelMethod, DitherVirtualPixelMethod, @@ -11442,62 +8848,64 @@ typedef enum CheckerTileVirtualPixelMethod } VirtualPixelMethod; -typedef struct _CacheView - CacheView; - -extern __attribute__ ((visibility ("default"))) CacheView - *AcquireAuthenticCacheView(const Image *,ExceptionInfo *), - *AcquireVirtualCacheView(const Image *,ExceptionInfo *), - *CloneCacheView(const CacheView *), - *DestroyCacheView(CacheView *); - -extern __attribute__ ((visibility ("default"))) ClassType - GetCacheViewStorageClass(const CacheView *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) ColorspaceType - GetCacheViewColorspace(const CacheView *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) const Image - *GetCacheViewImage(const CacheView *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) const Quantum - *GetCacheViewVirtualPixels(const CacheView *,const ssize_t,const ssize_t, - const size_t,const size_t,ExceptionInfo *) __attribute__((__hot__)), - *GetCacheViewVirtualPixelQueue(const CacheView *) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) const void - *GetCacheViewVirtualMetacontent(const CacheView *) - __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - GetOneCacheViewAuthenticPixel(const CacheView *,const ssize_t,const ssize_t, - Quantum *,ExceptionInfo *), - GetOneCacheViewVirtualMethodPixel(const CacheView *,const VirtualPixelMethod, - const ssize_t,const ssize_t,Quantum *,ExceptionInfo *), - GetOneCacheViewVirtualPixel(const CacheView *,const ssize_t,const ssize_t, - Quantum *,ExceptionInfo *), - GetOneCacheViewVirtualPixelInfo(const CacheView *,const ssize_t,const ssize_t, - PixelInfo *,ExceptionInfo *), - SetCacheViewStorageClass(CacheView *,const ClassType,ExceptionInfo *), - SetCacheViewVirtualPixelMethod(CacheView *__restrict__, - const VirtualPixelMethod), - SyncCacheViewAuthenticPixels(CacheView *__restrict__,ExceptionInfo *) - __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) MagickSizeType - GetCacheViewExtent(const CacheView *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) Quantum - *GetCacheViewAuthenticPixelQueue(CacheView *) __attribute__((__hot__)), - *GetCacheViewAuthenticPixels(CacheView *,const ssize_t,const ssize_t, - const size_t,const size_t,ExceptionInfo *) __attribute__((__hot__)), - *QueueCacheViewAuthenticPixels(CacheView *,const ssize_t,const ssize_t, - const size_t,const size_t,ExceptionInfo *) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) void - *GetCacheViewAuthenticMetacontent(CacheView *); -typedef enum -{ +typedef struct _CacheView CacheView; + +extern __attribute__((visibility("default"))) CacheView * +AcquireAuthenticCacheView(const Image *, ExceptionInfo *), + *AcquireVirtualCacheView(const Image *, ExceptionInfo *), + *CloneCacheView(const CacheView *), *DestroyCacheView(CacheView *); + +extern __attribute__((visibility("default"))) ClassType +GetCacheViewStorageClass(const CacheView *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) ColorspaceType +GetCacheViewColorspace(const CacheView *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) const Image * +GetCacheViewImage(const CacheView *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) const Quantum * +GetCacheViewVirtualPixels(const CacheView *, const ssize_t, const ssize_t, + const size_t, const size_t, ExceptionInfo *) + __attribute__((__hot__)), + *GetCacheViewVirtualPixelQueue(const CacheView *) __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) const void * +GetCacheViewVirtualMetacontent(const CacheView *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) MagickBooleanType +GetOneCacheViewAuthenticPixel(const CacheView *, const ssize_t, const ssize_t, + Quantum *, ExceptionInfo *), + GetOneCacheViewVirtualMethodPixel(const CacheView *, + const VirtualPixelMethod, const ssize_t, + const ssize_t, Quantum *, + ExceptionInfo *), + GetOneCacheViewVirtualPixel(const CacheView *, const ssize_t, const ssize_t, + Quantum *, ExceptionInfo *), + GetOneCacheViewVirtualPixelInfo(const CacheView *, const ssize_t, + const ssize_t, PixelInfo *, + ExceptionInfo *), + SetCacheViewStorageClass(CacheView *, const ClassType, ExceptionInfo *), + SetCacheViewVirtualPixelMethod(CacheView *__restrict__, + const VirtualPixelMethod), + SyncCacheViewAuthenticPixels(CacheView *__restrict__, ExceptionInfo *) + __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) MagickSizeType +GetCacheViewExtent(const CacheView *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) Quantum * +GetCacheViewAuthenticPixelQueue(CacheView *) __attribute__((__hot__)), + *GetCacheViewAuthenticPixels(CacheView *, const ssize_t, const ssize_t, + const size_t, const size_t, ExceptionInfo *) + __attribute__((__hot__)), + *QueueCacheViewAuthenticPixels(CacheView *, const ssize_t, const ssize_t, + const size_t, const size_t, ExceptionInfo *) + __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) void * +GetCacheViewAuthenticMetacontent(CacheView *); +typedef enum { UndefinedFilter, PointFilter, BoxFilter, @@ -11532,101 +8940,69 @@ typedef enum CubicSplineFilter, SentinelFilter } FilterType; -typedef struct _ResampleFilter - ResampleFilter; - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ResamplePixelColor(ResampleFilter *,const double,const double, - PixelInfo *,ExceptionInfo *), - SetResampleFilterInterpolateMethod(ResampleFilter *, - const PixelInterpolateMethod), - SetResampleFilterVirtualPixelMethod(ResampleFilter *, - const VirtualPixelMethod); - -extern __attribute__ ((visibility ("default"))) ResampleFilter - *AcquireResampleFilter(const Image *,ExceptionInfo *), - *DestroyResampleFilter(ResampleFilter *); - -extern __attribute__ ((visibility ("default"))) void - ScaleResampleFilter(ResampleFilter *,const double,const double,const double, - const double), - SetResampleFilter(ResampleFilter *,const FilterType); -typedef struct _ResizeFilter - ResizeFilter; - -extern __attribute__ ((visibility ("default"))) Image - *AdaptiveResizeImage(const Image *,const size_t,const size_t,ExceptionInfo *), - *InterpolativeResizeImage(const Image *,const size_t,const size_t, - const PixelInterpolateMethod,ExceptionInfo *), - *LiquidRescaleImage(const Image *,const size_t,const size_t,const double, - const double,ExceptionInfo *), - *MagnifyImage(const Image *,ExceptionInfo *), - *MinifyImage(const Image *,ExceptionInfo *), - *ResampleImage(const Image *,const double,const double,const FilterType, - ExceptionInfo *), - *ResizeImage(const Image *,const size_t,const size_t,const FilterType, - ExceptionInfo *), - *SampleImage(const Image *,const size_t,const size_t,ExceptionInfo *), - *ScaleImage(const Image *,const size_t,const size_t,ExceptionInfo *), - *ThumbnailImage(const Image *,const size_t,const size_t,ExceptionInfo *); -typedef struct _ChannelStatistics -{ - size_t - depth; - - double - area, - minima, - maxima, - sum, - sum_squared, - sum_cubed, - sum_fourth_power, - mean, - variance, - standard_deviation, - kurtosis, - skewness, - entropy, - median; +typedef struct _ResampleFilter ResampleFilter; + +extern __attribute__((visibility("default"))) MagickBooleanType +ResamplePixelColor(ResampleFilter *, const double, const double, PixelInfo *, + ExceptionInfo *), + SetResampleFilterInterpolateMethod(ResampleFilter *, + const PixelInterpolateMethod), + SetResampleFilterVirtualPixelMethod(ResampleFilter *, + const VirtualPixelMethod); + +extern __attribute__((visibility("default"))) ResampleFilter * +AcquireResampleFilter(const Image *, ExceptionInfo *), + *DestroyResampleFilter(ResampleFilter *); + +extern __attribute__((visibility("default"))) void +ScaleResampleFilter(ResampleFilter *, const double, const double, const double, + const double), + SetResampleFilter(ResampleFilter *, const FilterType); +typedef struct _ResizeFilter ResizeFilter; + +extern __attribute__((visibility("default"))) Image * +AdaptiveResizeImage(const Image *, const size_t, const size_t, ExceptionInfo *), + *InterpolativeResizeImage(const Image *, const size_t, const size_t, + const PixelInterpolateMethod, ExceptionInfo *), + *LiquidRescaleImage(const Image *, const size_t, const size_t, const double, + const double, ExceptionInfo *), + *MagnifyImage(const Image *, ExceptionInfo *), + *MinifyImage(const Image *, ExceptionInfo *), + *ResampleImage(const Image *, const double, const double, const FilterType, + ExceptionInfo *), + *ResizeImage(const Image *, const size_t, const size_t, const FilterType, + ExceptionInfo *), + *SampleImage(const Image *, const size_t, const size_t, ExceptionInfo *), + *ScaleImage(const Image *, const size_t, const size_t, ExceptionInfo *), + *ThumbnailImage(const Image *, const size_t, const size_t, ExceptionInfo *); +typedef struct _ChannelStatistics { + size_t depth; + + double area, minima, maxima, sum, sum_squared, sum_cubed, sum_fourth_power, + mean, variance, standard_deviation, kurtosis, skewness, entropy, median; } ChannelStatistics; -typedef struct _ChannelMoments -{ - double - invariant[8 +1]; +typedef struct _ChannelMoments { + double invariant[8 + 1]; - PointInfo - centroid, - ellipse_axis; + PointInfo centroid, ellipse_axis; - double - ellipse_angle, - ellipse_eccentricity, - ellipse_intensity; + double ellipse_angle, ellipse_eccentricity, ellipse_intensity; } ChannelMoments; -typedef struct _ChannelPerceptualHash -{ - double - srgb_hu_phash[8 +1], - hclp_hu_phash[8 +1]; +typedef struct _ChannelPerceptualHash { + double srgb_hu_phash[8 + 1], hclp_hu_phash[8 + 1]; - size_t - number_colorspaces; + size_t number_colorspaces; - ColorspaceType - colorspace[6 +1]; + ColorspaceType colorspace[6 + 1]; - double - phash[6 +1][8 +1]; + double phash[6 + 1][8 + 1]; - size_t - number_channels; + size_t number_channels; } ChannelPerceptualHash; -typedef enum -{ +typedef enum { UndefinedEvaluateOperator, AbsEvaluateOperator, AddEvaluateOperator, @@ -11663,8 +9039,7 @@ typedef enum InverseLogEvaluateOperator } MagickEvaluateOperator; -typedef enum -{ +typedef enum { UndefinedFunction, ArcsinFunction, ArctanFunction, @@ -11672,8 +9047,7 @@ typedef enum SinusoidFunction } MagickFunction; -typedef enum -{ +typedef enum { UndefinedStatistic, GradientStatistic, MaximumStatistic, @@ -11687,34 +9061,34 @@ typedef enum ContrastStatistic } StatisticType; -extern __attribute__ ((visibility ("default"))) ChannelStatistics - *GetImageStatistics(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ChannelMoments - *GetImageMoments(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ChannelPerceptualHash - *GetImagePerceptualHash(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *EvaluateImages(const Image *,const MagickEvaluateOperator,ExceptionInfo *), - *PolynomialImage(const Image *,const size_t,const double *,ExceptionInfo *), - *StatisticImage(const Image *,const StatisticType,const size_t,const size_t, - ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - EvaluateImage(Image *,const MagickEvaluateOperator,const double, - ExceptionInfo *), - FunctionImage(Image *,const MagickFunction,const size_t,const double *, - ExceptionInfo *), - GetImageEntropy(const Image *,double *,ExceptionInfo *), - GetImageExtrema(const Image *,size_t *,size_t *,ExceptionInfo *), - GetImageMean(const Image *,double *,double *,ExceptionInfo *), - GetImageMedian(const Image *,double *,ExceptionInfo *), - GetImageKurtosis(const Image *,double *,double *,ExceptionInfo *), - GetImageRange(const Image *,double *,double *,ExceptionInfo *); -typedef enum -{ +extern __attribute__((visibility("default"))) ChannelStatistics * +GetImageStatistics(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) ChannelMoments * +GetImageMoments(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) ChannelPerceptualHash * +GetImagePerceptualHash(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) Image * +EvaluateImages(const Image *, const MagickEvaluateOperator, ExceptionInfo *), + *PolynomialImage(const Image *, const size_t, const double *, + ExceptionInfo *), + *StatisticImage(const Image *, const StatisticType, const size_t, + const size_t, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +EvaluateImage(Image *, const MagickEvaluateOperator, const double, + ExceptionInfo *), + FunctionImage(Image *, const MagickFunction, const size_t, const double *, + ExceptionInfo *), + GetImageEntropy(const Image *, double *, ExceptionInfo *), + GetImageExtrema(const Image *, size_t *, size_t *, ExceptionInfo *), + GetImageMean(const Image *, double *, double *, ExceptionInfo *), + GetImageMedian(const Image *, double *, ExceptionInfo *), + GetImageKurtosis(const Image *, double *, double *, ExceptionInfo *), + GetImageRange(const Image *, double *, double *, ExceptionInfo *); +typedef enum { UndefinedAlphaChannel, ActivateAlphaChannel, AssociateAlphaChannel, @@ -11733,8 +9107,7 @@ typedef enum TransparentAlphaChannel } AlphaChannelOption; -typedef enum -{ +typedef enum { UndefinedType, BilevelType, GrayscaleType, @@ -11749,8 +9122,7 @@ typedef enum PaletteBilevelAlphaType } ImageType; -typedef enum -{ +typedef enum { UndefinedInterlace, NoInterlace, LineInterlace, @@ -11761,8 +9133,7 @@ typedef enum PNGInterlace } InterlaceType; -typedef enum -{ +typedef enum { UndefinedOrientation, TopLeftOrientation, TopRightOrientation, @@ -11774,32 +9145,21 @@ typedef enum LeftBottomOrientation } OrientationType; -typedef enum -{ +typedef enum { UndefinedResolution, PixelsPerInchResolution, PixelsPerCentimeterResolution } ResolutionType; -typedef struct _PrimaryInfo -{ - double - x, - y, - z; +typedef struct _PrimaryInfo { + double x, y, z; } PrimaryInfo; -typedef struct _SegmentInfo -{ - double - x1, - y1, - x2, - y2; +typedef struct _SegmentInfo { + double x1, y1, x2, y2; } SegmentInfo; -typedef enum -{ +typedef enum { UndefinedTransmitType, FileTransmitType, BlobTransmitType, @@ -11807,121 +9167,97 @@ typedef enum ImageTransmitType } TransmitType; -typedef struct _ChromaticityInfo -{ - PrimaryInfo - red_primary, - green_primary, - blue_primary, - white_point; +typedef struct _ChromaticityInfo { + PrimaryInfo red_primary, green_primary, blue_primary, white_point; } ChromaticityInfo; -typedef enum -{ - ReadMode, - WriteMode, - IOMode, - PersistMode -} MapMode; - -typedef ssize_t - (*CustomStreamHandler)(unsigned char *,const size_t,void *); - -typedef MagickOffsetType - (*CustomStreamSeeker)(const MagickOffsetType,const int,void *); - -typedef MagickOffsetType - (*CustomStreamTeller)(void *); - -typedef struct _CustomStreamInfo - CustomStreamInfo; +typedef enum { ReadMode, WriteMode, IOMode, PersistMode } MapMode; -typedef struct _StreamInfo - StreamInfo; +typedef ssize_t (*CustomStreamHandler)(unsigned char *, const size_t, void *); -typedef size_t - (*StreamHandler)(const Image *,const void *,const size_t); +typedef MagickOffsetType (*CustomStreamSeeker)(const MagickOffsetType, + const int, void *); -extern __attribute__ ((visibility ("default"))) Image - *ReadStream(const ImageInfo *,StreamHandler,ExceptionInfo *), - *StreamImage(const ImageInfo *,StreamInfo *,ExceptionInfo *); +typedef MagickOffsetType (*CustomStreamTeller)(void *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - OpenStream(const ImageInfo *,StreamInfo *,const char *,ExceptionInfo *), - WriteStream(const ImageInfo *,Image *,StreamHandler,ExceptionInfo *); +typedef struct _CustomStreamInfo CustomStreamInfo; -extern __attribute__ ((visibility ("default"))) StreamInfo - *AcquireStreamInfo(const ImageInfo *,ExceptionInfo *), - *DestroyStreamInfo(StreamInfo *); +typedef struct _StreamInfo StreamInfo; -extern __attribute__ ((visibility ("default"))) void - SetStreamInfoMap(StreamInfo *,const char *), - SetStreamInfoStorageType(StreamInfo *,const StorageType); +typedef size_t (*StreamHandler)(const Image *, const void *, const size_t); -extern __attribute__ ((visibility ("default"))) CustomStreamInfo - *AcquireCustomStreamInfo(ExceptionInfo *), - *DestroyCustomStreamInfo(CustomStreamInfo *); +extern __attribute__((visibility("default"))) Image * +ReadStream(const ImageInfo *, StreamHandler, ExceptionInfo *), + *StreamImage(const ImageInfo *, StreamInfo *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) FILE - *GetBlobFileHandle(const Image *) __attribute__((__pure__)); +extern __attribute__((visibility("default"))) MagickBooleanType +OpenStream(const ImageInfo *, StreamInfo *, const char *, ExceptionInfo *), + WriteStream(const ImageInfo *, Image *, StreamHandler, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) Image - *BlobToImage(const ImageInfo *,const void *,const size_t,ExceptionInfo *), - *PingBlob(const ImageInfo *,const void *,const size_t,ExceptionInfo *), - *CustomStreamToImage(const ImageInfo *,ExceptionInfo *); +extern __attribute__((visibility("default"))) StreamInfo * +AcquireStreamInfo(const ImageInfo *, ExceptionInfo *), + *DestroyStreamInfo(StreamInfo *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - BlobToFile(char *,const void *,const size_t,ExceptionInfo *), - FileToImage(Image *,const char *,ExceptionInfo *), - GetBlobError(const Image *) __attribute__((__pure__)), - ImageToFile(Image *,char *,ExceptionInfo *), - InjectImageBlob(const ImageInfo *,Image *,Image *,const char *, - ExceptionInfo *), - IsBlobExempt(const Image *) __attribute__((__pure__)), - IsBlobSeekable(const Image *) __attribute__((__pure__)), - IsBlobTemporary(const Image *) __attribute__((__pure__)); +extern __attribute__((visibility("default"))) void +SetStreamInfoMap(StreamInfo *, const char *), + SetStreamInfoStorageType(StreamInfo *, const StorageType); -extern __attribute__ ((visibility ("default"))) MagickSizeType - GetBlobSize(const Image *); +extern __attribute__((visibility("default"))) CustomStreamInfo * +AcquireCustomStreamInfo(ExceptionInfo *), + *DestroyCustomStreamInfo(CustomStreamInfo *); -extern __attribute__ ((visibility ("default"))) StreamHandler - GetBlobStreamHandler(const Image *) __attribute__((__pure__)); +extern __attribute__((visibility("default"))) FILE * +GetBlobFileHandle(const Image *) __attribute__((__pure__)); -extern __attribute__ ((visibility ("default"))) void - *GetBlobStreamData(const Image *) __attribute__((__pure__)), - DestroyBlob(Image *), - DuplicateBlob(Image *,const Image *), - *FileToBlob(const char *,const size_t,size_t *,ExceptionInfo *), - *ImageToBlob(const ImageInfo *,Image *,size_t *,ExceptionInfo *), - ImageToCustomStream(const ImageInfo *,Image *,ExceptionInfo *), - *ImagesToBlob(const ImageInfo *,Image *,size_t *,ExceptionInfo *), - ImagesToCustomStream(const ImageInfo *,Image *,ExceptionInfo *), - SetBlobExempt(Image *,const MagickBooleanType), - SetCustomStreamData(CustomStreamInfo *,void *), - SetCustomStreamReader(CustomStreamInfo *,CustomStreamHandler), - SetCustomStreamSeeker(CustomStreamInfo *,CustomStreamSeeker), - SetCustomStreamTeller(CustomStreamInfo *,CustomStreamTeller), - SetCustomStreamWriter(CustomStreamInfo *,CustomStreamHandler); +extern __attribute__((visibility("default"))) Image * +BlobToImage(const ImageInfo *, const void *, const size_t, ExceptionInfo *), + *PingBlob(const ImageInfo *, const void *, const size_t, ExceptionInfo *), + *CustomStreamToImage(const ImageInfo *, ExceptionInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +BlobToFile(char *, const void *, const size_t, ExceptionInfo *), + FileToImage(Image *, const char *, ExceptionInfo *), + GetBlobError(const Image *) __attribute__((__pure__)), + ImageToFile(Image *, char *, ExceptionInfo *), + InjectImageBlob(const ImageInfo *, Image *, Image *, const char *, + ExceptionInfo *), + IsBlobExempt(const Image *) __attribute__((__pure__)), + IsBlobSeekable(const Image *) __attribute__((__pure__)), + IsBlobTemporary(const Image *) __attribute__((__pure__)); -typedef struct SemaphoreInfo - SemaphoreInfo; +extern __attribute__((visibility("default"))) MagickSizeType +GetBlobSize(const Image *); -extern __attribute__ ((visibility ("default"))) SemaphoreInfo - *AcquireSemaphoreInfo(void); +extern __attribute__((visibility("default"))) StreamHandler +GetBlobStreamHandler(const Image *) __attribute__((__pure__)); -extern __attribute__ ((visibility ("default"))) void - ActivateSemaphoreInfo(SemaphoreInfo **), - LockSemaphoreInfo(SemaphoreInfo *), - RelinquishSemaphoreInfo(SemaphoreInfo **), - UnlockSemaphoreInfo(SemaphoreInfo *); +extern __attribute__((visibility("default"))) void * +GetBlobStreamData(const Image *) __attribute__((__pure__)), + DestroyBlob(Image *), DuplicateBlob(Image *, const Image *), + *FileToBlob(const char *, const size_t, size_t *, ExceptionInfo *), + *ImageToBlob(const ImageInfo *, Image *, size_t *, ExceptionInfo *), + ImageToCustomStream(const ImageInfo *, Image *, ExceptionInfo *), + *ImagesToBlob(const ImageInfo *, Image *, size_t *, ExceptionInfo *), + ImagesToCustomStream(const ImageInfo *, Image *, ExceptionInfo *), + SetBlobExempt(Image *, const MagickBooleanType), + SetCustomStreamData(CustomStreamInfo *, void *), + SetCustomStreamReader(CustomStreamInfo *, CustomStreamHandler), + SetCustomStreamSeeker(CustomStreamInfo *, CustomStreamSeeker), + SetCustomStreamTeller(CustomStreamInfo *, CustomStreamTeller), + SetCustomStreamWriter(CustomStreamInfo *, CustomStreamHandler); +typedef struct SemaphoreInfo SemaphoreInfo; +extern __attribute__((visibility("default"))) SemaphoreInfo * +AcquireSemaphoreInfo(void); +extern __attribute__((visibility("default"))) void +ActivateSemaphoreInfo(SemaphoreInfo **), + LockSemaphoreInfo(SemaphoreInfo *), + RelinquishSemaphoreInfo(SemaphoreInfo **), + UnlockSemaphoreInfo(SemaphoreInfo *); - -typedef enum -{ +typedef enum { UndefinedException, WarningException = 300, ResourceLimitWarning = 300, @@ -11994,83 +9330,69 @@ typedef enum PolicyFatalError = 799 } ExceptionType; -struct _ExceptionInfo -{ - ExceptionType - severity; +struct _ExceptionInfo { + ExceptionType severity; - int - error_number; + int error_number; - char - *reason, - *description; + char *reason, *description; - void - *exceptions; + void *exceptions; - MagickBooleanType - relinquish; + MagickBooleanType relinquish; - SemaphoreInfo - *semaphore; + SemaphoreInfo *semaphore; - size_t - signature; + size_t signature; }; -typedef void - (*ErrorHandler)(const ExceptionType,const char *,const char *); - -typedef void - (*FatalErrorHandler)(const ExceptionType,const char *,const char *); - -typedef void - (*WarningHandler)(const ExceptionType,const char *,const char *); - -extern __attribute__ ((visibility ("default"))) char - *GetExceptionMessage(const int); - -extern __attribute__ ((visibility ("default"))) const char - *GetLocaleExceptionMessage(const ExceptionType,const char *); +typedef void (*ErrorHandler)(const ExceptionType, const char *, const char *); -extern __attribute__ ((visibility ("default"))) ErrorHandler - SetErrorHandler(ErrorHandler); +typedef void (*FatalErrorHandler)(const ExceptionType, const char *, + const char *); -extern __attribute__ ((visibility ("default"))) ExceptionInfo - *AcquireExceptionInfo(void), - *CloneExceptionInfo(ExceptionInfo *), - *DestroyExceptionInfo(ExceptionInfo *); +typedef void (*WarningHandler)(const ExceptionType, const char *, const char *); -extern __attribute__ ((visibility ("default"))) FatalErrorHandler - SetFatalErrorHandler(FatalErrorHandler); +extern __attribute__((visibility("default"))) char * +GetExceptionMessage(const int); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ThrowException(ExceptionInfo *,const ExceptionType,const char *, - const char *), - ThrowMagickExceptionList(ExceptionInfo *,const char *,const char *, - const size_t,const ExceptionType,const char *,const char *,va_list), - ThrowMagickException(ExceptionInfo *,const char *,const char *,const size_t, - const ExceptionType,const char *,const char *,...) - __attribute__((__format__ (__printf__,7,8))); +extern __attribute__((visibility("default"))) const char * +GetLocaleExceptionMessage(const ExceptionType, const char *); -extern __attribute__ ((visibility ("default"))) void - CatchException(ExceptionInfo *), - ClearMagickException(ExceptionInfo *), - InheritException(ExceptionInfo *,const ExceptionInfo *), - MagickError(const ExceptionType,const char *,const char *), - MagickFatalError(const ExceptionType,const char *,const char *), - MagickWarning(const ExceptionType,const char *,const char *); +extern __attribute__((visibility("default"))) +ErrorHandler SetErrorHandler(ErrorHandler); -extern __attribute__ ((visibility ("default"))) WarningHandler - SetWarningHandler(WarningHandler); +extern __attribute__((visibility("default"))) ExceptionInfo * +AcquireExceptionInfo(void), + *CloneExceptionInfo(ExceptionInfo *), + *DestroyExceptionInfo(ExceptionInfo *); +extern __attribute__((visibility("default"))) +FatalErrorHandler SetFatalErrorHandler(FatalErrorHandler); +extern __attribute__((visibility("default"))) MagickBooleanType +ThrowException(ExceptionInfo *, const ExceptionType, const char *, + const char *), + ThrowMagickExceptionList(ExceptionInfo *, const char *, const char *, + const size_t, const ExceptionType, const char *, + const char *, va_list), + ThrowMagickException(ExceptionInfo *, const char *, const char *, + const size_t, const ExceptionType, const char *, + const char *, ...) + __attribute__((__format__(__printf__, 7, 8))); +extern __attribute__((visibility("default"))) void +CatchException(ExceptionInfo *), + ClearMagickException(ExceptionInfo *), + InheritException(ExceptionInfo *, const ExceptionInfo *), + MagickError(const ExceptionType, const char *, const char *), + MagickFatalError(const ExceptionType, const char *, const char *), + MagickWarning(const ExceptionType, const char *, const char *); +extern __attribute__((visibility("default"))) +WarningHandler SetWarningHandler(WarningHandler); -typedef enum -{ +typedef enum { UndefinedCompliance, NoCompliance = 0x0000, CSSCompliance = 0x0001, @@ -12081,8 +9403,7 @@ typedef enum AllCompliance = 0x7fffffff } ComplianceType; -typedef enum -{ +typedef enum { UndefinedIlluminant = 5, AIlluminant = 0, BIlluminant = 1, @@ -12097,56 +9418,43 @@ typedef enum F11Illuminant = 10 } IlluminantType; -typedef struct _ColorInfo -{ - char - *path, - *name; +typedef struct _ColorInfo { + char *path, *name; - ComplianceType - compliance; + ComplianceType compliance; - PixelInfo - color; + PixelInfo color; - MagickBooleanType - exempt, - stealth; + MagickBooleanType exempt, stealth; - size_t - signature; + size_t signature; } ColorInfo; -typedef struct _ErrorInfo -{ - double - mean_error_per_pixel, - normalized_mean_error, - normalized_maximum_error; +typedef struct _ErrorInfo { + double mean_error_per_pixel, normalized_mean_error, normalized_maximum_error; } ErrorInfo; -extern __attribute__ ((visibility ("default"))) char - **GetColorList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) const ColorInfo - *GetColorInfo(const char *,ExceptionInfo *), - **GetColorInfoList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - IsEquivalentImage(const Image *,const Image *,ssize_t *x,ssize_t *y, - ExceptionInfo *), - ListColorInfo(FILE *,ExceptionInfo *), - QueryColorCompliance(const char *,const ComplianceType,PixelInfo *, - ExceptionInfo *), - QueryColorname(const Image *,const PixelInfo *,const ComplianceType, - char *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) void - ConcatenateColorComponent(const PixelInfo *,const PixelChannel, - const ComplianceType,char *), - GetColorTuple(const PixelInfo *,const MagickBooleanType,char *); -typedef enum -{ +extern __attribute__((visibility("default"))) char ** +GetColorList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) const ColorInfo * +GetColorInfo(const char *, ExceptionInfo *), + **GetColorInfoList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +IsEquivalentImage(const Image *, const Image *, ssize_t *x, ssize_t *y, + ExceptionInfo *), + ListColorInfo(FILE *, ExceptionInfo *), + QueryColorCompliance(const char *, const ComplianceType, PixelInfo *, + ExceptionInfo *), + QueryColorname(const Image *, const PixelInfo *, const ComplianceType, + char *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +ConcatenateColorComponent(const PixelInfo *, const PixelChannel, + const ComplianceType, char *), + GetColorTuple(const PixelInfo *, const MagickBooleanType, char *); +typedef enum { UndefinedCompositeOp, AlphaCompositeOp, AtopCompositeOp, @@ -12231,12 +9539,12 @@ typedef enum SeamlessBlendCompositeOp } CompositeOperator; -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CompositeImage(Image *,const Image *,const CompositeOperator, - const MagickBooleanType,const ssize_t,const ssize_t,ExceptionInfo *), - TextureImage(Image *,const Image *,ExceptionInfo *); -typedef enum -{ +extern __attribute__((visibility("default"))) MagickBooleanType +CompositeImage(Image *, const Image *, const CompositeOperator, + const MagickBooleanType, const ssize_t, const ssize_t, + ExceptionInfo *), + TextureImage(Image *, const Image *, ExceptionInfo *); +typedef enum { UndefinedCompression, B44ACompression, B44Compression, @@ -12266,25 +9574,22 @@ typedef enum BC7Compression } CompressionType; -typedef struct _Ascii85Info - Ascii85Info; - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - HuffmanDecodeImage(Image *,ExceptionInfo *), - HuffmanEncodeImage(const ImageInfo *,Image *,Image *,ExceptionInfo *), - LZWEncodeImage(Image *,const size_t,unsigned char *__restrict__, - ExceptionInfo *), - PackbitsEncodeImage(Image *,const size_t,unsigned char *__restrict__, - ExceptionInfo *), - ZLIBEncodeImage(Image *,const size_t,unsigned char *__restrict__, - ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) void - Ascii85Encode(Image *,const unsigned char), - Ascii85Flush(Image *), - Ascii85Initialize(Image *); -typedef enum -{ +typedef struct _Ascii85Info Ascii85Info; + +extern __attribute__((visibility("default"))) MagickBooleanType +HuffmanDecodeImage(Image *, ExceptionInfo *), + HuffmanEncodeImage(const ImageInfo *, Image *, Image *, ExceptionInfo *), + LZWEncodeImage(Image *, const size_t, unsigned char *__restrict__, + ExceptionInfo *), + PackbitsEncodeImage(Image *, const size_t, unsigned char *__restrict__, + ExceptionInfo *), + ZLIBEncodeImage(Image *, const size_t, unsigned char *__restrict__, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +Ascii85Encode(Image *, const unsigned char), + Ascii85Flush(Image *), Ascii85Initialize(Image *); +typedef enum { UndefinedPreview, RotatePreview, ShearPreview, @@ -12317,36 +9622,37 @@ typedef enum JPEGPreview } PreviewType; -extern __attribute__ ((visibility ("default"))) Image - *AdaptiveBlurImage(const Image *,const double,const double,ExceptionInfo *), - *AdaptiveSharpenImage(const Image *,const double,const double, - ExceptionInfo *), - *BilateralBlurImage(const Image *,const size_t,const size_t, - const double,const double,ExceptionInfo *), - *BlurImage(const Image *,const double,const double,ExceptionInfo *), - *ConvolveImage(const Image *,const KernelInfo *,ExceptionInfo *), - *DespeckleImage(const Image *,ExceptionInfo *), - *EdgeImage(const Image *,const double,ExceptionInfo *), - *EmbossImage(const Image *,const double,const double,ExceptionInfo *), - *GaussianBlurImage(const Image *,const double,const double,ExceptionInfo *), - *KuwaharaImage(const Image *,const double,const double,ExceptionInfo *), - *LocalContrastImage(const Image *,const double,const double,ExceptionInfo *), - *MotionBlurImage(const Image *,const double,const double,const double, - ExceptionInfo *), - *PreviewImage(const Image *,const PreviewType,ExceptionInfo *), - *RotationalBlurImage(const Image *,const double,ExceptionInfo *), - *SelectiveBlurImage(const Image *,const double,const double,const double, - ExceptionInfo *), - *ShadeImage(const Image *,const MagickBooleanType,const double,const double, - ExceptionInfo *), - *SharpenImage(const Image *,const double,const double,ExceptionInfo *), - *SpreadImage(const Image *,const PixelInterpolateMethod,const double, - ExceptionInfo *), - *UnsharpMaskImage(const Image *,const double,const double,const double, - const double,ExceptionInfo *); - -typedef enum -{ +extern __attribute__((visibility("default"))) Image * +AdaptiveBlurImage(const Image *, const double, const double, ExceptionInfo *), + *AdaptiveSharpenImage(const Image *, const double, const double, + ExceptionInfo *), + *BilateralBlurImage(const Image *, const size_t, const size_t, const double, + const double, ExceptionInfo *), + *BlurImage(const Image *, const double, const double, ExceptionInfo *), + *ConvolveImage(const Image *, const KernelInfo *, ExceptionInfo *), + *DespeckleImage(const Image *, ExceptionInfo *), + *EdgeImage(const Image *, const double, ExceptionInfo *), + *EmbossImage(const Image *, const double, const double, ExceptionInfo *), + *GaussianBlurImage(const Image *, const double, const double, + ExceptionInfo *), + *KuwaharaImage(const Image *, const double, const double, ExceptionInfo *), + *LocalContrastImage(const Image *, const double, const double, + ExceptionInfo *), + *MotionBlurImage(const Image *, const double, const double, const double, + ExceptionInfo *), + *PreviewImage(const Image *, const PreviewType, ExceptionInfo *), + *RotationalBlurImage(const Image *, const double, ExceptionInfo *), + *SelectiveBlurImage(const Image *, const double, const double, const double, + ExceptionInfo *), + *ShadeImage(const Image *, const MagickBooleanType, const double, + const double, ExceptionInfo *), + *SharpenImage(const Image *, const double, const double, ExceptionInfo *), + *SpreadImage(const Image *, const PixelInterpolateMethod, const double, + ExceptionInfo *), + *UnsharpMaskImage(const Image *, const double, const double, const double, + const double, ExceptionInfo *); + +typedef enum { UnrecognizedDispose, UndefinedDispose = 0, NoneDispose = 1, @@ -12354,8 +9660,7 @@ typedef enum PreviousDispose = 3 } DisposeType; -typedef enum -{ +typedef enum { UndefinedLayer, CoalesceLayer, CompareAnyLayer, @@ -12375,224 +9680,194 @@ typedef enum TrimBoundsLayer } LayerMethod; -extern __attribute__ ((visibility ("default"))) Image - *CoalesceImages(const Image *,ExceptionInfo *), - *DisposeImages(const Image *,ExceptionInfo *), - *CompareImagesLayers(const Image *,const LayerMethod,ExceptionInfo *), - *MergeImageLayers(Image *,const LayerMethod,ExceptionInfo *), - *OptimizeImageLayers(const Image *,ExceptionInfo *), - *OptimizePlusImageLayers(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) void - CompositeLayers(Image *,const CompositeOperator,Image *,const ssize_t, - const ssize_t,ExceptionInfo *), - OptimizeImageTransparency(const Image *,ExceptionInfo *), - RemoveDuplicateLayers(Image **,ExceptionInfo *), - RemoveZeroDelayLayers(Image **,ExceptionInfo *); -typedef struct _LinkedListInfo - LinkedListInfo; - -extern __attribute__ ((visibility ("default"))) LinkedListInfo - *DestroyLinkedList(LinkedListInfo *,void *(*)(void *)), - *NewLinkedList(const size_t); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AppendValueToLinkedList(LinkedListInfo *,const void *), - InsertValueInLinkedList(LinkedListInfo *,const size_t,const void *), - InsertValueInSortedLinkedList(LinkedListInfo *, - int (*)(const void *,const void *),void **,const void *), - IsLinkedListEmpty(const LinkedListInfo *), - LinkedListToArray(LinkedListInfo *,void **); - -extern __attribute__ ((visibility ("default"))) size_t - GetNumberOfElementsInLinkedList(const LinkedListInfo *); - -extern __attribute__ ((visibility ("default"))) void - ClearLinkedList(LinkedListInfo *,void *(*)(void *)), - *GetLastValueInLinkedList(LinkedListInfo *), - *GetNextValueInLinkedList(LinkedListInfo *), - *GetValueFromLinkedList(LinkedListInfo *,const size_t), - *RemoveElementByValueFromLinkedList(LinkedListInfo *,const void *), - *RemoveElementFromLinkedList(LinkedListInfo *,const size_t), - *RemoveLastElementFromLinkedList(LinkedListInfo *), - ResetLinkedListIterator(LinkedListInfo *); - - - - - -typedef struct _LocaleInfo -{ - char - *path, - *tag, - *message; - - MagickBooleanType - stealth; - - size_t - signature; +extern __attribute__((visibility("default"))) Image * +CoalesceImages(const Image *, ExceptionInfo *), + *DisposeImages(const Image *, ExceptionInfo *), + *CompareImagesLayers(const Image *, const LayerMethod, ExceptionInfo *), + *MergeImageLayers(Image *, const LayerMethod, ExceptionInfo *), + *OptimizeImageLayers(const Image *, ExceptionInfo *), + *OptimizePlusImageLayers(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +CompositeLayers(Image *, const CompositeOperator, Image *, const ssize_t, + const ssize_t, ExceptionInfo *), + OptimizeImageTransparency(const Image *, ExceptionInfo *), + RemoveDuplicateLayers(Image **, ExceptionInfo *), + RemoveZeroDelayLayers(Image **, ExceptionInfo *); +typedef struct _LinkedListInfo LinkedListInfo; + +extern __attribute__((visibility("default"))) LinkedListInfo * +DestroyLinkedList(LinkedListInfo *, void *(*)(void *)), + *NewLinkedList(const size_t); + +extern __attribute__((visibility("default"))) MagickBooleanType +AppendValueToLinkedList(LinkedListInfo *, const void *), + InsertValueInLinkedList(LinkedListInfo *, const size_t, const void *), + InsertValueInSortedLinkedList(LinkedListInfo *, + int (*)(const void *, const void *), void **, + const void *), + IsLinkedListEmpty(const LinkedListInfo *), + LinkedListToArray(LinkedListInfo *, void **); + +extern __attribute__((visibility("default"))) size_t +GetNumberOfElementsInLinkedList(const LinkedListInfo *); + +extern __attribute__((visibility("default"))) void +ClearLinkedList(LinkedListInfo *, void *(*)(void *)), + *GetLastValueInLinkedList(LinkedListInfo *), + *GetNextValueInLinkedList(LinkedListInfo *), + *GetValueFromLinkedList(LinkedListInfo *, const size_t), + *RemoveElementByValueFromLinkedList(LinkedListInfo *, const void *), + *RemoveElementFromLinkedList(LinkedListInfo *, const size_t), + *RemoveLastElementFromLinkedList(LinkedListInfo *), + ResetLinkedListIterator(LinkedListInfo *); + +typedef struct _LocaleInfo { + char *path, *tag, *message; + + MagickBooleanType stealth; + + size_t signature; } LocaleInfo; -extern __attribute__ ((visibility ("default"))) char - **GetLocaleList(const char *,size_t *,ExceptionInfo *); +extern __attribute__((visibility("default"))) char ** +GetLocaleList(const char *, size_t *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) const char - *GetLocaleMessage(const char *); +extern __attribute__((visibility("default"))) const char * +GetLocaleMessage(const char *); -extern __attribute__ ((visibility ("default"))) const LocaleInfo - *GetLocaleInfo_(const char *,ExceptionInfo *), - **GetLocaleInfoList(const char *,size_t *,ExceptionInfo *); +extern __attribute__((visibility("default"))) const LocaleInfo * +GetLocaleInfo_(const char *, ExceptionInfo *), + **GetLocaleInfoList(const char *, size_t *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) double - InterpretLocaleValue(const char *__restrict__,char *__restrict__ *); +extern __attribute__((visibility("default"))) double +InterpretLocaleValue(const char *__restrict__, char *__restrict__ *); -extern __attribute__ ((visibility ("default"))) int - LocaleCompare(const char *,const char *) __attribute__((__pure__)), - LocaleLowercase(const int), - LocaleNCompare(const char *,const char *,const size_t) +extern __attribute__((visibility("default"))) int LocaleCompare(const char *, + const char *) __attribute__((__pure__)), - LocaleUppercase(const int); - -extern __attribute__ ((visibility ("default"))) LinkedListInfo - *DestroyLocaleOptions(LinkedListInfo *), - *GetLocaleOptions(const char *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ListLocaleInfo(FILE *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ssize_t - FormatLocaleFile(FILE *,const char *__restrict__,...) - __attribute__((__format__ (__printf__,2,3))), - FormatLocaleString(char *__restrict__,const size_t, - const char *__restrict__,...) - __attribute__((__format__ (__printf__,3,4))); - -extern __attribute__ ((visibility ("default"))) void - LocaleLower(char *), - LocaleUpper(char *); -typedef MagickBooleanType - (*MagickProgressMonitor)(const char *,const MagickOffsetType, - const MagickSizeType,void *); - -__attribute__ ((visibility ("default"))) MagickBooleanType - SetImageProgress(const Image *,const char *,const MagickOffsetType, - const MagickSizeType); - -__attribute__ ((visibility ("default"))) MagickProgressMonitor - SetImageProgressMonitor(Image *,const MagickProgressMonitor,void *), - SetImageInfoProgressMonitor(ImageInfo *,const MagickProgressMonitor,void *); + LocaleLowercase(const int), + LocaleNCompare(const char *, const char *, const size_t) + __attribute__((__pure__)), + LocaleUppercase(const int); + +extern __attribute__((visibility("default"))) LinkedListInfo * +DestroyLocaleOptions(LinkedListInfo *), + *GetLocaleOptions(const char *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +ListLocaleInfo(FILE *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) ssize_t +FormatLocaleFile(FILE *, const char *__restrict__, ...) + __attribute__((__format__(__printf__, 2, 3))), + FormatLocaleString(char *__restrict__, const size_t, + const char *__restrict__, ...) + __attribute__((__format__(__printf__, 3, 4))); + +extern __attribute__((visibility("default"))) void LocaleLower(char *), + LocaleUpper(char *); +typedef MagickBooleanType (*MagickProgressMonitor)(const char *, + const MagickOffsetType, + const MagickSizeType, + void *); + +__attribute__((visibility("default"))) MagickBooleanType +SetImageProgress(const Image *, const char *, const MagickOffsetType, + const MagickSizeType); + +__attribute__((visibility("default"))) MagickProgressMonitor +SetImageProgressMonitor(Image *, const MagickProgressMonitor, void *), + SetImageInfoProgressMonitor(ImageInfo *, const MagickProgressMonitor, + void *); static inline MagickBooleanType QuantumTick(const MagickOffsetType offset, - const MagickSizeType span) -{ + const MagickSizeType span) { if (span <= 100) - return(MagickTrue); - if (offset == (MagickOffsetType) (span-1)) - return(MagickTrue); - if ((offset % (MagickOffsetType) (span/100)) == 0) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + if (offset == (MagickOffsetType)(span - 1)) + return (MagickTrue); + if ((offset % (MagickOffsetType)(span / 100)) == 0) + return (MagickTrue); + return (MagickFalse); } -typedef struct _StringInfo -{ - char - *path; +typedef struct _StringInfo { + char *path; - unsigned char - *datum; + unsigned char *datum; - size_t - length, - signature; + size_t length, signature; - char - *name; + char *name; } StringInfo; -extern __attribute__ ((visibility ("default"))) char - *AcquireString(const char *), - *CloneString(char **,const char *), - *ConstantString(const char *), - *DestroyString(char *), - **DestroyStringList(char **), - *EscapeString(const char *,const char), - *FileToString(const char *,const size_t,ExceptionInfo *), - *GetEnvironmentValue(const char *), - *SanitizeString(const char *), - *StringInfoToDigest(const StringInfo *), - *StringInfoToHexString(const StringInfo *), - *StringInfoToString(const StringInfo *), - **StringToArgv(const char *,int *), - *StringToken(const char *,char **), - **StringToList(const char *), - **StringToStrings(const char *,size_t *); - -extern __attribute__ ((visibility ("default"))) const char - *GetStringInfoName(const StringInfo *), - *GetStringInfoPath(const StringInfo *); - -extern __attribute__ ((visibility ("default"))) double - InterpretSiPrefixValue(const char *__restrict__,char **__restrict__), - *StringToArrayOfDoubles(const char *,ssize_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) int - CompareStringInfo(const StringInfo *,const StringInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ConcatenateString(char **__restrict__,const char *__restrict__), - IsStringTrue(const char *) __attribute__((__pure__)), - IsStringFalse(const char *) __attribute__((__pure__)), - SubstituteString(char **,const char *,const char *); - -extern __attribute__ ((visibility ("default"))) size_t - ConcatenateMagickString(char *__restrict__,const char *__restrict__, - const size_t) __attribute__((__nonnull__)), - CopyMagickString(char *__restrict__,const char *__restrict__, - const size_t) __attribute__((__nonnull__)), - GetStringInfoLength(const StringInfo *), - StripMagickString(char *); - -extern __attribute__ ((visibility ("default"))) ssize_t - FormatMagickSize(const MagickSizeType,const MagickBooleanType,const char *, - const size_t,char *); - -extern __attribute__ ((visibility ("default"))) StringInfo - *AcquireStringInfo(const size_t), - *BlobToStringInfo(const void *,const size_t), - *CloneStringInfo(const StringInfo *), - *ConfigureFileToStringInfo(const char *), - *DestroyStringInfo(StringInfo *), - *FileToStringInfo(const char *,const size_t,ExceptionInfo *), - *SplitStringInfo(StringInfo *,const size_t), - *StringToStringInfo(const char *); - -extern __attribute__ ((visibility ("default"))) unsigned char - *GetStringInfoDatum(const StringInfo *); - -extern __attribute__ ((visibility ("default"))) void - ConcatenateStringInfo(StringInfo *,const StringInfo *) +extern __attribute__((visibility("default"))) char *AcquireString(const char *), + *CloneString(char **, const char *), *ConstantString(const char *), + *DestroyString(char *), **DestroyStringList(char **), + *EscapeString(const char *, const char), + *FileToString(const char *, const size_t, ExceptionInfo *), + *GetEnvironmentValue(const char *), *SanitizeString(const char *), + *StringInfoToDigest(const StringInfo *), + *StringInfoToHexString(const StringInfo *), + *StringInfoToString(const StringInfo *), + **StringToArgv(const char *, int *), *StringToken(const char *, char **), + **StringToList(const char *), **StringToStrings(const char *, size_t *); + +extern __attribute__((visibility("default"))) const char * +GetStringInfoName(const StringInfo *), + *GetStringInfoPath(const StringInfo *); + +extern __attribute__((visibility("default"))) double +InterpretSiPrefixValue(const char *__restrict__, char **__restrict__), + *StringToArrayOfDoubles(const char *, ssize_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) int +CompareStringInfo(const StringInfo *, const StringInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +ConcatenateString(char **__restrict__, const char *__restrict__), + IsStringTrue(const char *) __attribute__((__pure__)), + IsStringFalse(const char *) __attribute__((__pure__)), + SubstituteString(char **, const char *, const char *); + +extern __attribute__((visibility("default"))) size_t +ConcatenateMagickString(char *__restrict__, const char *__restrict__, + const size_t) __attribute__((__nonnull__)), + CopyMagickString(char *__restrict__, const char *__restrict__, const size_t) + __attribute__((__nonnull__)), + GetStringInfoLength(const StringInfo *), StripMagickString(char *); + +extern __attribute__((visibility("default"))) ssize_t +FormatMagickSize(const MagickSizeType, const MagickBooleanType, const char *, + const size_t, char *); + +extern __attribute__((visibility("default"))) StringInfo * +AcquireStringInfo(const size_t), + *BlobToStringInfo(const void *, const size_t), + *CloneStringInfo(const StringInfo *), + *ConfigureFileToStringInfo(const char *), *DestroyStringInfo(StringInfo *), + *FileToStringInfo(const char *, const size_t, ExceptionInfo *), + *SplitStringInfo(StringInfo *, const size_t), + *StringToStringInfo(const char *); + +extern __attribute__((visibility("default"))) unsigned char * +GetStringInfoDatum(const StringInfo *); + +extern __attribute__((visibility("default"))) void +ConcatenateStringInfo(StringInfo *, const StringInfo *) __attribute__((__nonnull__)), - PrintStringInfo(FILE *file,const char *,const StringInfo *), - ResetStringInfo(StringInfo *), - SetStringInfo(StringInfo *,const StringInfo *), - SetStringInfoDatum(StringInfo *,const unsigned char *), - SetStringInfoLength(StringInfo *,const size_t), - SetStringInfoName(StringInfo *,const char *), - SetStringInfoPath(StringInfo *,const char *), - StripString(char *); - - - - + PrintStringInfo(FILE *file, const char *, const StringInfo *), + ResetStringInfo(StringInfo *), + SetStringInfo(StringInfo *, const StringInfo *), + SetStringInfoDatum(StringInfo *, const unsigned char *), + SetStringInfoLength(StringInfo *, const size_t), + SetStringInfoName(StringInfo *, const char *), + SetStringInfoPath(StringInfo *, const char *), StripString(char *); -typedef struct _ProfileInfo - ProfileInfo; +typedef struct _ProfileInfo ProfileInfo; -typedef enum -{ +typedef enum { UndefinedIntent, SaturationIntent, PerceptualIntent, @@ -12600,55 +9875,42 @@ typedef enum RelativeIntent } RenderingIntent; -extern __attribute__ ((visibility ("default"))) char - *GetNextImageProfile(const Image *); - -extern __attribute__ ((visibility ("default"))) const StringInfo - *GetImageProfile(const Image *,const char *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CloneImageProfiles(Image *,const Image *), - DeleteImageProfile(Image *,const char *), - ProfileImage(Image *,const char *,const void *,const size_t,ExceptionInfo *), - SetImageProfile(Image *,const char *,const StringInfo *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) StringInfo - *RemoveImageProfile(Image *,const char *); - -extern __attribute__ ((visibility ("default"))) void - DestroyImageProfiles(Image *), - ResetImageProfileIterator(const Image *); - - +extern __attribute__((visibility("default"))) char * +GetNextImageProfile(const Image *); +extern __attribute__((visibility("default"))) const StringInfo * +GetImageProfile(const Image *, const char *); +extern __attribute__((visibility("default"))) MagickBooleanType +CloneImageProfiles(Image *, const Image *), + DeleteImageProfile(Image *, const char *), + ProfileImage(Image *, const char *, const void *, const size_t, + ExceptionInfo *), + SetImageProfile(Image *, const char *, const StringInfo *, ExceptionInfo *); +extern __attribute__((visibility("default"))) StringInfo * +RemoveImageProfile(Image *, const char *); +extern __attribute__((visibility("default"))) void +DestroyImageProfiles(Image *), + ResetImageProfileIterator(const Image *); -typedef enum -{ - UndefinedEndian, - LSBEndian, - MSBEndian -} EndianType; +typedef enum { UndefinedEndian, LSBEndian, MSBEndian } EndianType; -typedef enum -{ +typedef enum { UndefinedQuantumAlpha, AssociatedQuantumAlpha, DisassociatedQuantumAlpha } QuantumAlphaType; -typedef enum -{ +typedef enum { UndefinedQuantumFormat, FloatingPointQuantumFormat, SignedQuantumFormat, UnsignedQuantumFormat } QuantumFormatType; -typedef enum -{ +typedef enum { UndefinedQuantum, AlphaQuantum, BGRAQuantum, @@ -12679,546 +9941,360 @@ typedef enum MultispectralQuantum } QuantumType; -typedef struct _QuantumInfo - QuantumInfo; - -static inline Quantum ClampToQuantum(const MagickRealType quantum) -{ - - return((Quantum) quantum); - - - - - +typedef struct _QuantumInfo QuantumInfo; +static inline Quantum ClampToQuantum(const MagickRealType quantum) { + return ((Quantum)quantum); } -static inline unsigned char ScaleQuantumToChar(const Quantum quantum) -{ - - - - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return(0); - if ((quantum/257.0) >= 255.0) - return(255); - return((unsigned char) (quantum/257.0+0.5)); +static inline unsigned char ScaleQuantumToChar(const Quantum quantum) { + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return (0); + if ((quantum / 257.0) >= 255.0) + return (255); + return ((unsigned char)(quantum / 257.0 + 0.5)); } -extern __attribute__ ((visibility ("default"))) EndianType - GetQuantumEndian(const QuantumInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - SetQuantumDepth(const Image *,QuantumInfo *,const size_t), - SetQuantumEndian(const Image *,QuantumInfo *,const EndianType), - SetQuantumFormat(const Image *,QuantumInfo *,const QuantumFormatType), - SetQuantumPad(const Image *,QuantumInfo *,const size_t); +extern __attribute__((visibility("default"))) EndianType +GetQuantumEndian(const QuantumInfo *); -extern __attribute__ ((visibility ("default"))) QuantumFormatType - GetQuantumFormat(const QuantumInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +SetQuantumDepth(const Image *, QuantumInfo *, const size_t), + SetQuantumEndian(const Image *, QuantumInfo *, const EndianType), + SetQuantumFormat(const Image *, QuantumInfo *, const QuantumFormatType), + SetQuantumPad(const Image *, QuantumInfo *, const size_t); -extern __attribute__ ((visibility ("default"))) QuantumInfo - *AcquireQuantumInfo(const ImageInfo *,Image *), - *DestroyQuantumInfo(QuantumInfo *); +extern __attribute__((visibility("default"))) QuantumFormatType +GetQuantumFormat(const QuantumInfo *); -extern __attribute__ ((visibility ("default"))) QuantumType - GetQuantumType(Image *,ExceptionInfo *); +extern __attribute__((visibility("default"))) QuantumInfo * +AcquireQuantumInfo(const ImageInfo *, Image *), + *DestroyQuantumInfo(QuantumInfo *); -extern __attribute__ ((visibility ("default"))) size_t - ExportQuantumPixels(const Image *,CacheView *,QuantumInfo *,const QuantumType, - unsigned char *__restrict__,ExceptionInfo *), - GetQuantumExtent(const Image *,const QuantumInfo *,const QuantumType), - ImportQuantumPixels(const Image *,CacheView *,QuantumInfo *,const QuantumType, - const unsigned char *__restrict__,ExceptionInfo *); +extern __attribute__((visibility("default"))) QuantumType +GetQuantumType(Image *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) unsigned char - *GetQuantumPixels(const QuantumInfo *); +extern __attribute__((visibility("default"))) size_t +ExportQuantumPixels(const Image *, CacheView *, QuantumInfo *, + const QuantumType, unsigned char *__restrict__, + ExceptionInfo *), + GetQuantumExtent(const Image *, const QuantumInfo *, const QuantumType), + ImportQuantumPixels(const Image *, CacheView *, QuantumInfo *, + const QuantumType, const unsigned char *__restrict__, + ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) void - GetQuantumInfo(const ImageInfo *,QuantumInfo *), - SetQuantumAlphaType(QuantumInfo *,const QuantumAlphaType), - SetQuantumImageType(Image *,const QuantumType), - SetQuantumMinIsWhite(QuantumInfo *,const MagickBooleanType), - SetQuantumPack(QuantumInfo *,const MagickBooleanType), - SetQuantumQuantum(QuantumInfo *,const size_t), - SetQuantumScale(QuantumInfo *,const double); +extern __attribute__((visibility("default"))) unsigned char * +GetQuantumPixels(const QuantumInfo *); +extern __attribute__((visibility("default"))) void +GetQuantumInfo(const ImageInfo *, QuantumInfo *), + SetQuantumAlphaType(QuantumInfo *, const QuantumAlphaType), + SetQuantumImageType(Image *, const QuantumType), + SetQuantumMinIsWhite(QuantumInfo *, const MagickBooleanType), + SetQuantumPack(QuantumInfo *, const MagickBooleanType), + SetQuantumQuantum(QuantumInfo *, const size_t), + SetQuantumScale(QuantumInfo *, const double); - - -typedef enum -{ +typedef enum { UndefinedTimerState, StoppedTimerState, RunningTimerState } TimerState; -typedef struct _Timer -{ - double - start, - stop, - total; +typedef struct _Timer { + double start, stop, total; } Timer; -typedef struct _TimerInfo -{ - Timer - user, - elapsed; +typedef struct _TimerInfo { + Timer user, elapsed; - TimerState - state; + TimerState state; - size_t - signature; + size_t signature; } TimerInfo; -extern __attribute__ ((visibility ("default"))) double - GetElapsedTime(TimerInfo *), - GetUserTime(TimerInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ContinueTimer(TimerInfo *); - -extern __attribute__ ((visibility ("default"))) ssize_t - FormatMagickTime(const time_t,const size_t,char *); +extern __attribute__((visibility("default"))) double +GetElapsedTime(TimerInfo *), + GetUserTime(TimerInfo *); -extern __attribute__ ((visibility ("default"))) TimerInfo - *AcquireTimerInfo(void), - *DestroyTimerInfo(TimerInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +ContinueTimer(TimerInfo *); -extern __attribute__ ((visibility ("default"))) void - GetTimerInfo(TimerInfo *), - ResetTimer(TimerInfo *), - StartTimer(TimerInfo *,const MagickBooleanType); +extern __attribute__((visibility("default"))) ssize_t +FormatMagickTime(const time_t, const size_t, char *); -struct _Image -{ - ClassType - storage_class; - - ColorspaceType - colorspace; +extern __attribute__((visibility("default"))) TimerInfo *AcquireTimerInfo(void), + *DestroyTimerInfo(TimerInfo *); - CompressionType - compression; +extern __attribute__((visibility("default"))) void GetTimerInfo(TimerInfo *), + ResetTimer(TimerInfo *), StartTimer(TimerInfo *, const MagickBooleanType); - size_t - quality; +struct _Image { + ClassType storage_class; - OrientationType - orientation; + ColorspaceType colorspace; - MagickBooleanType - taint; + CompressionType compression; - size_t - columns, - rows, - depth, - colors; + size_t quality; + OrientationType orientation; - PixelInfo - *colormap, - alpha_color, - background_color, - border_color, - transparent_color; + MagickBooleanType taint; - double - gamma; + size_t columns, rows, depth, colors; - ChromaticityInfo - chromaticity; + PixelInfo *colormap, alpha_color, background_color, border_color, + transparent_color; - RenderingIntent - rendering_intent; + double gamma; - void - *profiles; + ChromaticityInfo chromaticity; - ResolutionType - units; + RenderingIntent rendering_intent; - char - *montage, - *directory, - *geometry; + void *profiles; - ssize_t - offset; + ResolutionType units; - PointInfo - resolution; + char *montage, *directory, *geometry; - RectangleInfo - page, - extract_info; + ssize_t offset; - double - fuzz; + PointInfo resolution; - FilterType - filter; + RectangleInfo page, extract_info; - PixelIntensityMethod - intensity; + double fuzz; - InterlaceType - interlace; + FilterType filter; - EndianType - endian; + PixelIntensityMethod intensity; - GravityType - gravity; + InterlaceType interlace; - CompositeOperator - compose; + EndianType endian; - DisposeType - dispose; + GravityType gravity; - size_t - scene, - delay, - duration; + CompositeOperator compose; - ssize_t - ticks_per_second; + DisposeType dispose; - size_t - iterations, - total_colors; + size_t scene, delay, duration; - ssize_t - start_loop; + ssize_t ticks_per_second; - PixelInterpolateMethod - interpolate; + size_t iterations, total_colors; - MagickBooleanType - black_point_compensation; + ssize_t start_loop; - RectangleInfo - tile_offset; + PixelInterpolateMethod interpolate; - ImageType - type; + MagickBooleanType black_point_compensation; - MagickBooleanType - dither; + RectangleInfo tile_offset; - MagickSizeType - extent; + ImageType type; - MagickBooleanType - ping; + MagickBooleanType dither; - MagickBooleanType - read_mask, - write_mask; + MagickSizeType extent; - PixelTrait - alpha_trait; + MagickBooleanType ping; - size_t - number_channels, - number_meta_channels, - metacontent_extent; + MagickBooleanType read_mask, write_mask; - ChannelType - channel_mask; + PixelTrait alpha_trait; - PixelChannelMap - *channel_map; + size_t number_channels, number_meta_channels, metacontent_extent; - void - *cache; + ChannelType channel_mask; - ErrorInfo - error; + PixelChannelMap *channel_map; - TimerInfo - timer; + void *cache; - MagickProgressMonitor - progress_monitor; + ErrorInfo error; - void - *client_data; + TimerInfo timer; - Ascii85Info - *ascii85; + MagickProgressMonitor progress_monitor; - ProfileInfo - *generic_profile; + void *client_data; - void - *properties, - *artifacts; + Ascii85Info *ascii85; - char - filename[4096], - magick_filename[4096], - magick[4096]; + ProfileInfo *generic_profile; - size_t - magick_columns, - magick_rows; + void *properties, *artifacts; - BlobInfo - *blob; + char filename[4096], magick_filename[4096], magick[4096]; - time_t - timestamp; + size_t magick_columns, magick_rows; - MagickBooleanType - debug; + BlobInfo *blob; - volatile ssize_t - reference_count; + time_t timestamp; - SemaphoreInfo - *semaphore; + MagickBooleanType debug; - struct _ImageInfo - *image_info; + volatile ssize_t reference_count; + SemaphoreInfo *semaphore; + struct _ImageInfo *image_info; + struct _Image *list, *previous, *next; - struct _Image - *list, - *previous, - *next; + size_t signature; - size_t - signature; + PixelInfo matte_color; - PixelInfo - matte_color; + MagickBooleanType composite_mask; - MagickBooleanType - composite_mask; + PixelTrait mask_trait; - PixelTrait - mask_trait; - - ChannelType - channels; + ChannelType channels; }; +struct _ImageInfo { + CompressionType compression; + OrientationType orientation; + MagickBooleanType temporary, adjoin, affirm, antialias; + char *size, *extract, *page, *scenes; + size_t scene, number_scenes, depth; + InterlaceType interlace; -struct _ImageInfo -{ - CompressionType - compression; - - OrientationType - orientation; - - MagickBooleanType - temporary, - adjoin, - affirm, - antialias; - - char - *size, - *extract, - *page, - *scenes; - - size_t - scene, - number_scenes, - depth; - - InterlaceType - interlace; - - EndianType - endian; - - ResolutionType - units; - - size_t - quality; + EndianType endian; - char - *sampling_factor, - *server_name, - *font, - *texture, - *density; + ResolutionType units; - double - pointsize, - fuzz; + size_t quality; - PixelInfo - alpha_color, - background_color, - border_color, - transparent_color; + char *sampling_factor, *server_name, *font, *texture, *density; + double pointsize, fuzz; + PixelInfo alpha_color, background_color, border_color, transparent_color; - MagickBooleanType - dither, - monochrome; + MagickBooleanType dither, monochrome; - ColorspaceType - colorspace; + ColorspaceType colorspace; - CompositeOperator - compose; + CompositeOperator compose; - ImageType - type; + ImageType type; - MagickBooleanType - ping, - verbose; + MagickBooleanType ping, verbose; - ChannelType - channel; + ChannelType channel; - void - *options; + void *options; - void - *profile; + void *profile; - MagickBooleanType - synchronize; + MagickBooleanType synchronize; - MagickProgressMonitor - progress_monitor; + MagickProgressMonitor progress_monitor; - void - *client_data, - *cache; + void *client_data, *cache; - StreamHandler - stream; + StreamHandler stream; - FILE - *file; + FILE *file; - void - *blob; + void *blob; - size_t - length; + size_t length; - char - magick[4096], - unique[4096], - filename[4096]; + char magick[4096], unique[4096], filename[4096]; - MagickBooleanType - debug; + MagickBooleanType debug; - size_t - signature; + size_t signature; - CustomStreamInfo - *custom_stream; + CustomStreamInfo *custom_stream; - PixelInfo - matte_color; + PixelInfo matte_color; }; -extern __attribute__ ((visibility ("default"))) ChannelType - SetImageChannelMask(Image *,const ChannelType); - -extern __attribute__ ((visibility ("default"))) ExceptionType - CatchImageException(Image *); - -extern __attribute__ ((visibility ("default"))) FILE - *GetImageInfoFile(const ImageInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *AcquireImage(const ImageInfo *,ExceptionInfo *), - *AppendImages(const Image *,const MagickBooleanType,ExceptionInfo *), - *CloneImage(const Image *,const size_t,const size_t,const MagickBooleanType, - ExceptionInfo *), - *DestroyImage(Image *), - *GetImageMask(const Image *,const PixelMask,ExceptionInfo *), - *NewMagickImage(const ImageInfo *,const size_t,const size_t,const PixelInfo *, - ExceptionInfo *), - *ReferenceImage(Image *), - *SmushImages(const Image *,const MagickBooleanType,const ssize_t, - ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ImageInfo - *AcquireImageInfo(void), - *CloneImageInfo(const ImageInfo *), - *DestroyImageInfo(ImageInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ClipImage(Image *,ExceptionInfo *), - ClipImagePath(Image *,const char *,const MagickBooleanType,ExceptionInfo *), - CopyImagePixels(Image *,const Image *,const RectangleInfo *, - const OffsetInfo *,ExceptionInfo *), - IsTaintImage(const Image *), - IsHighDynamicRangeImage(const Image *,ExceptionInfo *), - IsImageObject(const Image *), - ListMagickInfo(FILE *,ExceptionInfo *), - ModifyImage(Image **,ExceptionInfo *), - ResetImagePage(Image *,const char *), - ResetImagePixels(Image *,ExceptionInfo *), - SetImageAlpha(Image *,const Quantum,ExceptionInfo *), - SetImageBackgroundColor(Image *,ExceptionInfo *), - SetImageColor(Image *,const PixelInfo *,ExceptionInfo *), - SetImageExtent(Image *,const size_t,const size_t,ExceptionInfo *), - SetImageInfo(ImageInfo *,const unsigned int,ExceptionInfo *), - SetImageMask(Image *,const PixelMask type,const Image *,ExceptionInfo *), - SetImageRegionMask(Image *,const PixelMask type,const RectangleInfo *, - ExceptionInfo *), - SetImageStorageClass(Image *,const ClassType,ExceptionInfo *), - StripImage(Image *,ExceptionInfo *), - SyncImage(Image *,ExceptionInfo *), - SyncImageSettings(const ImageInfo *,Image *,ExceptionInfo *), - SyncImagesSettings(ImageInfo *,Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) size_t - InterpretImageFilename(const ImageInfo *,Image *,const char *,int,char *, - ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ssize_t - GetImageReferenceCount(Image *); - -extern __attribute__ ((visibility ("default"))) VirtualPixelMethod - GetImageVirtualPixelMethod(const Image *), - SetImageVirtualPixelMethod(Image *,const VirtualPixelMethod,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) void - AcquireNextImage(const ImageInfo *,Image *,ExceptionInfo *), - DestroyImagePixels(Image *), - DisassociateImageStream(Image *), - GetImageInfo(ImageInfo *), - SetImageInfoBlob(ImageInfo *,const void *,const size_t), - SetImageInfoFile(ImageInfo *,FILE *), - SetImageInfoCustomStream(ImageInfo *,CustomStreamInfo *); - -typedef enum -{ +extern __attribute__((visibility("default"))) ChannelType +SetImageChannelMask(Image *, const ChannelType); + +extern __attribute__((visibility("default"))) ExceptionType +CatchImageException(Image *); + +extern __attribute__((visibility("default"))) FILE * +GetImageInfoFile(const ImageInfo *); + +extern __attribute__((visibility("default"))) Image * +AcquireImage(const ImageInfo *, ExceptionInfo *), + *AppendImages(const Image *, const MagickBooleanType, ExceptionInfo *), + *CloneImage(const Image *, const size_t, const size_t, + const MagickBooleanType, ExceptionInfo *), + *DestroyImage(Image *), + *GetImageMask(const Image *, const PixelMask, ExceptionInfo *), + *NewMagickImage(const ImageInfo *, const size_t, const size_t, + const PixelInfo *, ExceptionInfo *), + *ReferenceImage(Image *), + *SmushImages(const Image *, const MagickBooleanType, const ssize_t, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) ImageInfo *AcquireImageInfo(void), + *CloneImageInfo(const ImageInfo *), *DestroyImageInfo(ImageInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +ClipImage(Image *, ExceptionInfo *), + ClipImagePath(Image *, const char *, const MagickBooleanType, + ExceptionInfo *), + CopyImagePixels(Image *, const Image *, const RectangleInfo *, + const OffsetInfo *, ExceptionInfo *), + IsTaintImage(const Image *), + IsHighDynamicRangeImage(const Image *, ExceptionInfo *), + IsImageObject(const Image *), ListMagickInfo(FILE *, ExceptionInfo *), + ModifyImage(Image **, ExceptionInfo *), + ResetImagePage(Image *, const char *), + ResetImagePixels(Image *, ExceptionInfo *), + SetImageAlpha(Image *, const Quantum, ExceptionInfo *), + SetImageBackgroundColor(Image *, ExceptionInfo *), + SetImageColor(Image *, const PixelInfo *, ExceptionInfo *), + SetImageExtent(Image *, const size_t, const size_t, ExceptionInfo *), + SetImageInfo(ImageInfo *, const unsigned int, ExceptionInfo *), + SetImageMask(Image *, const PixelMask type, const Image *, ExceptionInfo *), + SetImageRegionMask(Image *, const PixelMask type, const RectangleInfo *, + ExceptionInfo *), + SetImageStorageClass(Image *, const ClassType, ExceptionInfo *), + StripImage(Image *, ExceptionInfo *), SyncImage(Image *, ExceptionInfo *), + SyncImageSettings(const ImageInfo *, Image *, ExceptionInfo *), + SyncImagesSettings(ImageInfo *, Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) size_t +InterpretImageFilename(const ImageInfo *, Image *, const char *, int, char *, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) ssize_t +GetImageReferenceCount(Image *); + +extern __attribute__((visibility("default"))) VirtualPixelMethod +GetImageVirtualPixelMethod(const Image *), + SetImageVirtualPixelMethod(Image *, const VirtualPixelMethod, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +AcquireNextImage(const ImageInfo *, Image *, ExceptionInfo *), + DestroyImagePixels(Image *), DisassociateImageStream(Image *), + GetImageInfo(ImageInfo *), + SetImageInfoBlob(ImageInfo *, const void *, const size_t), + SetImageInfoFile(ImageInfo *, FILE *), + SetImageInfoCustomStream(ImageInfo *, CustomStreamInfo *); + +typedef enum { UndefinedStretch, NormalStretch, UltraCondensedStretch, @@ -13232,8 +10308,7 @@ typedef enum AnyStretch } StretchType; -typedef enum -{ +typedef enum { UndefinedStyle, NormalStyle, ItalicStyle, @@ -13242,75 +10317,46 @@ typedef enum BoldStyle } StyleType; -typedef struct _TypeInfo -{ - size_t - face; +typedef struct _TypeInfo { + size_t face; - char - *path, - *name, - *description, - *family; + char *path, *name, *description, *family; - StyleType - style; + StyleType style; - StretchType - stretch; + StretchType stretch; - size_t - weight; + size_t weight; - char - *encoding, - *foundry, - *format, - *metrics, - *glyphs; + char *encoding, *foundry, *format, *metrics, *glyphs; - MagickBooleanType - stealth; + MagickBooleanType stealth; - size_t - signature; + size_t signature; } TypeInfo; -extern __attribute__ ((visibility ("default"))) char - **GetTypeList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - ListTypeInfo(FILE *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) const TypeInfo - *GetTypeInfo(const char *,ExceptionInfo *), - *GetTypeInfoByFamily(const char *,const StyleType,const StretchType, - const size_t,ExceptionInfo *), - **GetTypeInfoList(const char *,size_t *,ExceptionInfo *); +extern __attribute__((visibility("default"))) char ** +GetTypeList(const char *, size_t *, ExceptionInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +ListTypeInfo(FILE *, ExceptionInfo *); +extern __attribute__((visibility("default"))) const TypeInfo * +GetTypeInfo(const char *, ExceptionInfo *), + *GetTypeInfoByFamily(const char *, const StyleType, const StretchType, + const size_t, ExceptionInfo *), + **GetTypeInfoList(const char *, size_t *, ExceptionInfo *); +typedef enum { UndefinedAlign, LeftAlign, CenterAlign, RightAlign } AlignType; - - -typedef enum -{ - UndefinedAlign, - LeftAlign, - CenterAlign, - RightAlign -} AlignType; - -typedef enum -{ +typedef enum { UndefinedPathUnits, UserSpace, UserSpaceOnUse, ObjectBoundingBox } ClipPathUnits; -typedef enum -{ +typedef enum { UndefinedDecoration, NoDecoration, UnderlineDecoration, @@ -13318,46 +10364,26 @@ typedef enum LineThroughDecoration } DecorationType; -typedef enum -{ +typedef enum { UndefinedDirection, RightToLeftDirection, LeftToRightDirection } DirectionType; -typedef enum -{ +typedef enum { UndefinedRule, EvenOddRule, NonZeroRule } FillRule; -typedef enum -{ - UndefinedGradient, - LinearGradient, - RadialGradient -} GradientType; +typedef enum { UndefinedGradient, LinearGradient, RadialGradient } GradientType; -typedef enum -{ - UndefinedCap, - ButtCap, - RoundCap, - SquareCap -} LineCap; +typedef enum { UndefinedCap, ButtCap, RoundCap, SquareCap } LineCap; -typedef enum -{ - UndefinedJoin, - MiterJoin, - RoundJoin, - BevelJoin -} LineJoin; +typedef enum { UndefinedJoin, MiterJoin, RoundJoin, BevelJoin } LineJoin; -typedef enum -{ +typedef enum { UndefinedMethod, PointMethod, ReplaceMethod, @@ -13366,8 +10392,7 @@ typedef enum ResetMethod } PaintMethod; -typedef enum -{ +typedef enum { UndefinedPrimitive, AlphaPrimitive, ArcPrimitive, @@ -13386,303 +10411,195 @@ typedef enum TextPrimitive } PrimitiveType; -typedef enum -{ - UndefinedReference, - GradientReference -} ReferenceType; +typedef enum { UndefinedReference, GradientReference } ReferenceType; -typedef enum -{ +typedef enum { UndefinedSpread, PadSpread, ReflectSpread, RepeatSpread } SpreadMethod; -typedef enum -{ +typedef enum { UndefinedWordBreakType, NormalWordBreakType, BreakWordBreakType } WordBreakType; -typedef struct _StopInfo -{ - PixelInfo - color; +typedef struct _StopInfo { + PixelInfo color; - double - offset; + double offset; } StopInfo; -typedef struct _GradientInfo -{ - GradientType - type; +typedef struct _GradientInfo { + GradientType type; - RectangleInfo - bounding_box; + RectangleInfo bounding_box; - SegmentInfo - gradient_vector; + SegmentInfo gradient_vector; - StopInfo - *stops; + StopInfo *stops; - size_t - number_stops; + size_t number_stops; - SpreadMethod - spread; + SpreadMethod spread; - MagickBooleanType - debug; + MagickBooleanType debug; - PointInfo - center, - radii; + PointInfo center, radii; - double - radius, - angle; + double radius, angle; - size_t - signature; + size_t signature; } GradientInfo; -typedef struct _ElementReference -{ - char - *id; +typedef struct _ElementReference { + char *id; - ReferenceType - type; + ReferenceType type; - GradientInfo - gradient; + GradientInfo gradient; - struct _ElementReference - *previous, - *next; + struct _ElementReference *previous, *next; - size_t - signature; + size_t signature; } ElementReference; -typedef struct _DrawInfo -{ - char - *primitive, - *geometry; +typedef struct _DrawInfo { + char *primitive, *geometry; - RectangleInfo - viewbox; + RectangleInfo viewbox; - AffineMatrix - affine; + AffineMatrix affine; - PixelInfo - fill, - stroke, - undercolor, - border_color; + PixelInfo fill, stroke, undercolor, border_color; - Image - *fill_pattern, - *stroke_pattern; + Image *fill_pattern, *stroke_pattern; - double - stroke_width; + double stroke_width; - GradientInfo - gradient; + GradientInfo gradient; - MagickBooleanType - stroke_antialias, - text_antialias; + MagickBooleanType stroke_antialias, text_antialias; - FillRule - fill_rule; + FillRule fill_rule; - LineCap - linecap; + LineCap linecap; - LineJoin - linejoin; + LineJoin linejoin; - size_t - miterlimit; + size_t miterlimit; - double - dash_offset; + double dash_offset; - DecorationType - decorate; + DecorationType decorate; - CompositeOperator - compose; + CompositeOperator compose; - char - *text, - *font, - *metrics, - *family; + char *text, *font, *metrics, *family; - size_t - face; + size_t face; - StyleType - style; + StyleType style; - StretchType - stretch; + StretchType stretch; - size_t - weight; + size_t weight; - char - *encoding; + char *encoding; - double - pointsize; + double pointsize; - char - *density; + char *density; - AlignType - align; + AlignType align; - GravityType - gravity; + GravityType gravity; - char - *server_name; + char *server_name; - double - *dash_pattern; + double *dash_pattern; - char - *clip_mask; + char *clip_mask; - SegmentInfo - bounds; + SegmentInfo bounds; - ClipPathUnits - clip_units; + ClipPathUnits clip_units; - Quantum - alpha; + Quantum alpha; - MagickBooleanType - render; + MagickBooleanType render; - ElementReference - element_reference; + ElementReference element_reference; - double - kerning, - interword_spacing, - interline_spacing; + double kerning, interword_spacing, interline_spacing; - DirectionType - direction; + DirectionType direction; - MagickBooleanType - debug; + MagickBooleanType debug; - size_t - signature; + size_t signature; - double - fill_alpha, - stroke_alpha; + double fill_alpha, stroke_alpha; - MagickBooleanType - clip_path; + MagickBooleanType clip_path; - Image - *clipping_mask; + Image *clipping_mask; - ComplianceType - compliance; + ComplianceType compliance; - Image - *composite_mask; + Image *composite_mask; - char - *id; + char *id; - WordBreakType - word_break; + WordBreakType word_break; } DrawInfo; -typedef struct _PrimitiveInfo -{ - PointInfo - point; +typedef struct _PrimitiveInfo { + PointInfo point; - size_t - coordinates; + size_t coordinates; - PrimitiveType - primitive; + PrimitiveType primitive; - PaintMethod - method; + PaintMethod method; - char - *text; + char *text; - MagickBooleanType - closed_subpath; + MagickBooleanType closed_subpath; } PrimitiveInfo; -typedef struct _TypeMetric -{ - PointInfo - pixels_per_em; - - double - ascent, - descent, - width, - height, - max_advance, - underline_position, - underline_thickness; - - SegmentInfo - bounds; - - PointInfo - origin; -} TypeMetric; - -extern __attribute__ ((visibility ("default"))) DrawInfo - *AcquireDrawInfo(void), - *CloneDrawInfo(const ImageInfo *,const DrawInfo *), - *DestroyDrawInfo(DrawInfo *); +typedef struct _TypeMetric { + PointInfo pixels_per_em; -extern __attribute__ ((visibility ("default"))) MagickBooleanType - DrawAffineImage(Image *,const Image *,const AffineMatrix *,ExceptionInfo *), - DrawClipPath(Image *,const DrawInfo *,const char *,ExceptionInfo *), - DrawGradientImage(Image *,const DrawInfo *,ExceptionInfo *), - DrawImage(Image *,const DrawInfo *,ExceptionInfo *), - DrawPatternPath(Image *,const DrawInfo *,const char *,Image **, - ExceptionInfo *), - DrawPrimitive(Image *,const DrawInfo *,const PrimitiveInfo *,ExceptionInfo *); + double ascent, descent, width, height, max_advance, underline_position, + underline_thickness; -extern __attribute__ ((visibility ("default"))) void - GetAffineMatrix(AffineMatrix *), - GetDrawInfo(const ImageInfo *,DrawInfo *); + SegmentInfo bounds; + PointInfo origin; +} TypeMetric; +extern __attribute__((visibility("default"))) DrawInfo *AcquireDrawInfo(void), + *CloneDrawInfo(const ImageInfo *, const DrawInfo *), + *DestroyDrawInfo(DrawInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +DrawAffineImage(Image *, const Image *, const AffineMatrix *, ExceptionInfo *), + DrawClipPath(Image *, const DrawInfo *, const char *, ExceptionInfo *), + DrawGradientImage(Image *, const DrawInfo *, ExceptionInfo *), + DrawImage(Image *, const DrawInfo *, ExceptionInfo *), + DrawPatternPath(Image *, const DrawInfo *, const char *, Image **, + ExceptionInfo *), + DrawPrimitive(Image *, const DrawInfo *, const PrimitiveInfo *, + ExceptionInfo *); +extern __attribute__((visibility("default"))) void +GetAffineMatrix(AffineMatrix *), + GetDrawInfo(const ImageInfo *, DrawInfo *); -typedef enum -{ +typedef enum { UndefinedNoise, UniformNoise, GaussianNoise, @@ -13693,88 +10610,88 @@ typedef enum RandomNoise } NoiseType; -extern __attribute__ ((visibility ("default"))) Image - *AddNoiseImage(const Image *,const NoiseType,const double,ExceptionInfo *), - *BlueShiftImage(const Image *,const double,ExceptionInfo *), - *CharcoalImage(const Image *,const double,const double,ExceptionInfo *), - *ColorizeImage(const Image *,const char *,const PixelInfo *,ExceptionInfo *), - *ColorMatrixImage(const Image *,const KernelInfo *kernel,ExceptionInfo *), - *ImplodeImage(const Image *,const double,const PixelInterpolateMethod, - ExceptionInfo *), - *MorphImages(const Image *,const size_t,ExceptionInfo *), - *PolaroidImage(const Image *,const DrawInfo *,const char *,const double, - const PixelInterpolateMethod,ExceptionInfo *), - *SepiaToneImage(const Image *,const double,ExceptionInfo *), - *ShadowImage(const Image *,const double,const double,const ssize_t, - const ssize_t,ExceptionInfo *), - *SketchImage(const Image *,const double,const double,const double, - ExceptionInfo *), - *SteganoImage(const Image *,const Image *,ExceptionInfo *), - *StereoImage(const Image *,const Image *,ExceptionInfo *), - *StereoAnaglyphImage(const Image *,const Image *,const ssize_t,const ssize_t, - ExceptionInfo *), - *SwirlImage(const Image *,double,const PixelInterpolateMethod, - ExceptionInfo *), - *TintImage(const Image *,const char *,const PixelInfo *,ExceptionInfo *), - *VignetteImage(const Image *,const double,const double,const ssize_t, - const ssize_t,ExceptionInfo *), - *WaveImage(const Image *,const double,const double, - const PixelInterpolateMethod,ExceptionInfo *), - *WaveletDenoiseImage(const Image *,const double,const double,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - PlasmaImage(Image *,const SegmentInfo *,size_t,size_t,ExceptionInfo *), - SolarizeImage(Image *,const double,ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AnnotateImage(Image *,const DrawInfo *,ExceptionInfo *), - GetMultilineTypeMetrics(Image *,const DrawInfo *,TypeMetric *, - ExceptionInfo *), - GetTypeMetrics(Image *,const DrawInfo *,TypeMetric *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ssize_t - FormatMagickCaption(Image *,DrawInfo *,const MagickBooleanType,TypeMetric *, - char **,ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) char - *RemoveImageArtifact(Image *,const char *); - -extern __attribute__ ((visibility ("default"))) const char - *GetNextImageArtifact(const Image *), - *GetImageArtifact(const Image *,const char *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CloneImageArtifacts(Image *,const Image *), - DefineImageArtifact(Image *,const char *), - DeleteImageArtifact(Image *,const char *), - SetImageArtifact(Image *,const char *,const char *); - -extern __attribute__ ((visibility ("default"))) void - DestroyImageArtifacts(Image *), - ResetImageArtifactIterator(const Image *); -extern __attribute__ ((visibility ("default"))) ImageType - GetImageType(const Image *), - IdentifyImageGray(const Image *,ExceptionInfo *), - IdentifyImageType(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - IdentifyImageMonochrome(const Image *,ExceptionInfo *), - IsImageGray(const Image *), - IsImageMonochrome(const Image *), - IsImageOpaque(const Image *,ExceptionInfo *), - SetImageDepth(Image *,const size_t,ExceptionInfo *), - SetImageType(Image *,const ImageType,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) PointInfo - *GetImageConvexHull(const Image *,size_t *,ExceptionInfo *), - *GetImageMinimumBoundingBox(Image *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) RectangleInfo - GetImageBoundingBox(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) size_t - GetImageDepth(const Image *,ExceptionInfo *), - GetImageQuantumDepth(const Image *,const MagickBooleanType); -typedef enum -{ +extern __attribute__((visibility("default"))) Image * +AddNoiseImage(const Image *, const NoiseType, const double, ExceptionInfo *), + *BlueShiftImage(const Image *, const double, ExceptionInfo *), + *CharcoalImage(const Image *, const double, const double, ExceptionInfo *), + *ColorizeImage(const Image *, const char *, const PixelInfo *, + ExceptionInfo *), + *ColorMatrixImage(const Image *, const KernelInfo *kernel, ExceptionInfo *), + *ImplodeImage(const Image *, const double, const PixelInterpolateMethod, + ExceptionInfo *), + *MorphImages(const Image *, const size_t, ExceptionInfo *), + *PolaroidImage(const Image *, const DrawInfo *, const char *, const double, + const PixelInterpolateMethod, ExceptionInfo *), + *SepiaToneImage(const Image *, const double, ExceptionInfo *), + *ShadowImage(const Image *, const double, const double, const ssize_t, + const ssize_t, ExceptionInfo *), + *SketchImage(const Image *, const double, const double, const double, + ExceptionInfo *), + *SteganoImage(const Image *, const Image *, ExceptionInfo *), + *StereoImage(const Image *, const Image *, ExceptionInfo *), + *StereoAnaglyphImage(const Image *, const Image *, const ssize_t, + const ssize_t, ExceptionInfo *), + *SwirlImage(const Image *, double, const PixelInterpolateMethod, + ExceptionInfo *), + *TintImage(const Image *, const char *, const PixelInfo *, ExceptionInfo *), + *VignetteImage(const Image *, const double, const double, const ssize_t, + const ssize_t, ExceptionInfo *), + *WaveImage(const Image *, const double, const double, + const PixelInterpolateMethod, ExceptionInfo *), + *WaveletDenoiseImage(const Image *, const double, const double, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +PlasmaImage(Image *, const SegmentInfo *, size_t, size_t, ExceptionInfo *), + SolarizeImage(Image *, const double, ExceptionInfo *); +extern __attribute__((visibility("default"))) MagickBooleanType +AnnotateImage(Image *, const DrawInfo *, ExceptionInfo *), + GetMultilineTypeMetrics(Image *, const DrawInfo *, TypeMetric *, + ExceptionInfo *), + GetTypeMetrics(Image *, const DrawInfo *, TypeMetric *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) ssize_t +FormatMagickCaption(Image *, DrawInfo *, const MagickBooleanType, TypeMetric *, + char **, ExceptionInfo *); +extern __attribute__((visibility("default"))) char * +RemoveImageArtifact(Image *, const char *); + +extern __attribute__((visibility("default"))) const char * +GetNextImageArtifact(const Image *), + *GetImageArtifact(const Image *, const char *); + +extern __attribute__((visibility("default"))) MagickBooleanType +CloneImageArtifacts(Image *, const Image *), + DefineImageArtifact(Image *, const char *), + DeleteImageArtifact(Image *, const char *), + SetImageArtifact(Image *, const char *, const char *); + +extern __attribute__((visibility("default"))) void +DestroyImageArtifacts(Image *), + ResetImageArtifactIterator(const Image *); +extern __attribute__((visibility("default"))) ImageType +GetImageType(const Image *), + IdentifyImageGray(const Image *, ExceptionInfo *), + IdentifyImageType(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +IdentifyImageMonochrome(const Image *, ExceptionInfo *), + IsImageGray(const Image *), IsImageMonochrome(const Image *), + IsImageOpaque(const Image *, ExceptionInfo *), + SetImageDepth(Image *, const size_t, ExceptionInfo *), + SetImageType(Image *, const ImageType, ExceptionInfo *); + +extern __attribute__((visibility("default"))) PointInfo * +GetImageConvexHull(const Image *, size_t *, ExceptionInfo *), + *GetImageMinimumBoundingBox(Image *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) RectangleInfo +GetImageBoundingBox(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) size_t +GetImageDepth(const Image *, ExceptionInfo *), + GetImageQuantumDepth(const Image *, const MagickBooleanType); +typedef enum { UndefinedCache, DiskCache, DistributedCache, @@ -13783,1903 +10700,1575 @@ typedef enum PingCache } CacheType; -extern __attribute__ ((visibility ("default"))) CacheType - GetImagePixelCacheType(const Image *); - -extern __attribute__ ((visibility ("default"))) const char - *GetPixelCacheFilename(const Image *); - -extern __attribute__ ((visibility ("default"))) const Quantum - *GetVirtualPixels(const Image *,const ssize_t,const ssize_t,const size_t, - const size_t,ExceptionInfo *) __attribute__((__hot__)), - *GetVirtualPixelQueue(const Image *) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) const void - *GetVirtualMetacontent(const Image *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - GetOneAuthenticPixel(Image *,const ssize_t,const ssize_t,Quantum *, - ExceptionInfo *), - GetOneVirtualPixel(const Image *,const ssize_t,const ssize_t,Quantum *, - ExceptionInfo *), - GetOneVirtualPixelInfo(const Image *,const VirtualPixelMethod, - const ssize_t,const ssize_t,PixelInfo *,ExceptionInfo *), - PersistPixelCache(Image *,const char *,const MagickBooleanType, - MagickOffsetType *,ExceptionInfo *), - SyncAuthenticPixels(Image *,ExceptionInfo *) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) MagickSizeType - GetImageExtent(const Image *); - -extern __attribute__ ((visibility ("default"))) Quantum - *GetAuthenticPixels(Image *,const ssize_t,const ssize_t,const size_t, - const size_t,ExceptionInfo *) __attribute__((__hot__)), - *GetAuthenticPixelQueue(const Image *) __attribute__((__hot__)), - *QueueAuthenticPixels(Image *,const ssize_t,const ssize_t,const size_t, - const size_t,ExceptionInfo *) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) void - *AcquirePixelCachePixels(const Image *,size_t *,ExceptionInfo *), - *GetAuthenticMetacontent(const Image *), - *GetPixelCachePixels(Image *,MagickSizeType *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *ChannelFxImage(const Image *,const char *,ExceptionInfo *), - *CombineImages(const Image *,const ColorspaceType,ExceptionInfo *), - *SeparateImage(const Image *,const ChannelType,ExceptionInfo *), - *SeparateImages(const Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - GetImageAlphaChannel(const Image *), - SetImageAlphaChannel(Image *,const AlphaChannelOption,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *FxImage(const Image *,const char *,ExceptionInfo *); -typedef struct _RandomInfo - RandomInfo; - - - - -extern __attribute__ ((visibility ("default"))) double - GetRandomValue(RandomInfo *), - GetPseudoRandomValue(RandomInfo *__restrict__); - -extern __attribute__ ((visibility ("default"))) RandomInfo - *AcquireRandomInfo(void), - *DestroyRandomInfo(RandomInfo *); - -extern __attribute__ ((visibility ("default"))) StringInfo - *GetRandomKey(RandomInfo *,const size_t); - -extern __attribute__ ((visibility ("default"))) unsigned long - GetRandomSecretKey(const RandomInfo *); - -extern __attribute__ ((visibility ("default"))) void - SetRandomKey(RandomInfo *,const size_t,unsigned char *), - SetRandomSecretKey(const unsigned long), - SetRandomTrueRandom(const MagickBooleanType); - - - - - -extern __attribute__ ((visibility ("default"))) double - ExpandAffine(const AffineMatrix *); - -extern __attribute__ ((visibility ("default"))) void - ConvertHSLToRGB(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHSL(const double,const double,const double,double *,double *, - double *); - -typedef struct _MemoryInfo - MemoryInfo; - -typedef void - *(*AcquireMemoryHandler)(size_t) __attribute__((__alloc_size__(1))), - (*DestroyMemoryHandler)(void *), - *(*ResizeMemoryHandler)(void *,size_t) __attribute__((__alloc_size__(2))), - *(*AcquireAlignedMemoryHandler)(const size_t,const size_t), - (*RelinquishAlignedMemoryHandler)(void *); - -extern __attribute__ ((visibility ("default"))) MemoryInfo - *AcquireVirtualMemory(const size_t,const size_t) __attribute__((__alloc_size__(1,2))), - *RelinquishVirtualMemory(MemoryInfo *); - -extern __attribute__ ((visibility ("default"))) size_t - GetMaxMemoryRequest(void); - -extern __attribute__ ((visibility ("default"))) void - *AcquireAlignedMemory(const size_t,const size_t) - __attribute__((__malloc__)) __attribute__((__alloc_size__(1,2))), - *AcquireMagickMemory(const size_t) __attribute__((__malloc__)) +extern __attribute__((visibility("default"))) CacheType +GetImagePixelCacheType(const Image *); + +extern __attribute__((visibility("default"))) const char * +GetPixelCacheFilename(const Image *); + +extern __attribute__((visibility("default"))) const Quantum * +GetVirtualPixels(const Image *, const ssize_t, const ssize_t, const size_t, + const size_t, ExceptionInfo *) __attribute__((__hot__)), + *GetVirtualPixelQueue(const Image *) __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) const void * +GetVirtualMetacontent(const Image *); + +extern __attribute__((visibility("default"))) MagickBooleanType +GetOneAuthenticPixel(Image *, const ssize_t, const ssize_t, Quantum *, + ExceptionInfo *), + GetOneVirtualPixel(const Image *, const ssize_t, const ssize_t, Quantum *, + ExceptionInfo *), + GetOneVirtualPixelInfo(const Image *, const VirtualPixelMethod, + const ssize_t, const ssize_t, PixelInfo *, + ExceptionInfo *), + PersistPixelCache(Image *, const char *, const MagickBooleanType, + MagickOffsetType *, ExceptionInfo *), + SyncAuthenticPixels(Image *, ExceptionInfo *) __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) MagickSizeType +GetImageExtent(const Image *); + +extern __attribute__((visibility("default"))) Quantum * +GetAuthenticPixels(Image *, const ssize_t, const ssize_t, const size_t, + const size_t, ExceptionInfo *) __attribute__((__hot__)), + *GetAuthenticPixelQueue(const Image *) __attribute__((__hot__)), + *QueueAuthenticPixels(Image *, const ssize_t, const ssize_t, const size_t, + const size_t, ExceptionInfo *) + __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) void * +AcquirePixelCachePixels(const Image *, size_t *, ExceptionInfo *), + *GetAuthenticMetacontent(const Image *), + *GetPixelCachePixels(Image *, MagickSizeType *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) Image * +ChannelFxImage(const Image *, const char *, ExceptionInfo *), + *CombineImages(const Image *, const ColorspaceType, ExceptionInfo *), + *SeparateImage(const Image *, const ChannelType, ExceptionInfo *), + *SeparateImages(const Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +GetImageAlphaChannel(const Image *), + SetImageAlphaChannel(Image *, const AlphaChannelOption, ExceptionInfo *); + +extern __attribute__((visibility("default"))) Image * +FxImage(const Image *, const char *, ExceptionInfo *); +typedef struct _RandomInfo RandomInfo; + +extern __attribute__((visibility("default"))) double +GetRandomValue(RandomInfo *), + GetPseudoRandomValue(RandomInfo *__restrict__); + +extern __attribute__((visibility("default"))) RandomInfo * +AcquireRandomInfo(void), + *DestroyRandomInfo(RandomInfo *); + +extern __attribute__((visibility("default"))) StringInfo * +GetRandomKey(RandomInfo *, const size_t); + +extern __attribute__((visibility("default"))) unsigned long +GetRandomSecretKey(const RandomInfo *); + +extern __attribute__((visibility("default"))) void +SetRandomKey(RandomInfo *, const size_t, unsigned char *), + SetRandomSecretKey(const unsigned long), + SetRandomTrueRandom(const MagickBooleanType); + +extern __attribute__((visibility("default"))) double +ExpandAffine(const AffineMatrix *); + +extern __attribute__((visibility("default"))) void +ConvertHSLToRGB(const double, const double, const double, double *, double *, + double *), + ConvertRGBToHSL(const double, const double, const double, double *, + double *, double *); + +typedef struct _MemoryInfo MemoryInfo; + +typedef void *(*AcquireMemoryHandler)(size_t) __attribute__((__alloc_size__(1))), - *AcquireCriticalMemory(const size_t), - *AcquireQuantumMemory(const size_t,const size_t) - __attribute__((__malloc__)) __attribute__((__alloc_size__(1,2))), - *CopyMagickMemory(void *__restrict__,const void *__restrict__, - const size_t) __attribute__((__nonnull__)), - DestroyMagickMemory(void), - GetMagickMemoryMethods(AcquireMemoryHandler *,ResizeMemoryHandler *, - DestroyMemoryHandler *), - *GetVirtualMemoryBlob(const MemoryInfo *), - *RelinquishAlignedMemory(void *), - *RelinquishMagickMemory(void *), - *ResetMagickMemory(void *,int,const size_t), - *ResizeMagickMemory(void *,const size_t) - __attribute__((__malloc__)) __attribute__((__alloc_size__(2))), - *ResizeQuantumMemory(void *,const size_t,const size_t) - __attribute__((__malloc__)) __attribute__((__alloc_size__(2,3))), - SetMagickAlignedMemoryMethods(AcquireAlignedMemoryHandler, - RelinquishAlignedMemoryHandler), - SetMagickMemoryMethods(AcquireMemoryHandler,ResizeMemoryHandler, - DestroyMemoryHandler); - -static inline MagickBooleanType HeapOverflowSanityCheck( - const size_t count,const size_t quantum) -{ + (*DestroyMemoryHandler)(void *), + *(*ResizeMemoryHandler)(void *, size_t) __attribute__((__alloc_size__(2))), + *(*AcquireAlignedMemoryHandler)(const size_t, const size_t), + (*RelinquishAlignedMemoryHandler)(void *); + +extern __attribute__((visibility("default"))) MemoryInfo * +AcquireVirtualMemory(const size_t, const size_t) + __attribute__((__alloc_size__(1, 2))), + *RelinquishVirtualMemory(MemoryInfo *); + +extern __attribute__((visibility("default"))) size_t GetMaxMemoryRequest(void); + +extern __attribute__((visibility("default"))) void * +AcquireAlignedMemory(const size_t, const size_t) __attribute__((__malloc__)) +__attribute__((__alloc_size__(1, 2))), + *AcquireMagickMemory(const size_t) __attribute__((__malloc__)) + __attribute__((__alloc_size__(1))), + *AcquireCriticalMemory(const size_t), + *AcquireQuantumMemory(const size_t, const size_t) + __attribute__((__malloc__)) __attribute__((__alloc_size__(1, 2))), + *CopyMagickMemory(void *__restrict__, const void *__restrict__, + const size_t) __attribute__((__nonnull__)), + DestroyMagickMemory(void), + GetMagickMemoryMethods(AcquireMemoryHandler *, ResizeMemoryHandler *, + DestroyMemoryHandler *), + *GetVirtualMemoryBlob(const MemoryInfo *), *RelinquishAlignedMemory(void *), + *RelinquishMagickMemory(void *), + *ResetMagickMemory(void *, int, const size_t), + *ResizeMagickMemory(void *, const size_t) __attribute__((__malloc__)) + __attribute__((__alloc_size__(2))), + *ResizeQuantumMemory(void *, const size_t, const size_t) + __attribute__((__malloc__)) __attribute__((__alloc_size__(2, 3))), + SetMagickAlignedMemoryMethods(AcquireAlignedMemoryHandler, + RelinquishAlignedMemoryHandler), + SetMagickMemoryMethods(AcquireMemoryHandler, ResizeMemoryHandler, + DestroyMemoryHandler); + +static inline MagickBooleanType HeapOverflowSanityCheck(const size_t count, + const size_t quantum) { if ((count == 0) || (quantum == 0)) - return(MagickTrue); - if (quantum != ((count*quantum)/count)) - { - - (*__errno_location ()) - = - 12 - ; - return(MagickTrue); - } - return(MagickFalse); -} - -static inline MagickBooleanType HeapOverflowSanityCheckGetSize( - const size_t count,const size_t quantum,size_t *const extent) -{ - size_t - length; + return (MagickTrue); + if (quantum != ((count * quantum) / count)) { - if ((count == 0) || (quantum == 0)) - return(MagickTrue); - length=count*quantum; - if (quantum != (length/count)) - { - - (*__errno_location ()) - = - 12 - ; - return(MagickTrue); - } - if (extent != - ((void *)0) - ) - *extent=length; - return(MagickFalse); + (*__errno_location()) = 12; + return (MagickTrue); + } + return (MagickFalse); } +static inline MagickBooleanType +HeapOverflowSanityCheckGetSize(const size_t count, const size_t quantum, + size_t *const extent) { + size_t length; + if ((count == 0) || (quantum == 0)) + return (MagickTrue); + length = count * quantum; + if (quantum != (length / count)) { + (*__errno_location()) = 12; + return (MagickTrue); + } + if (extent != ((void *)0)) + *extent = length; + return (MagickFalse); +} +static inline Quantum ClampPixel(const MagickRealType pixel) { + if (pixel < 0.0f) + return ((Quantum)0); + if (pixel >= (MagickRealType)65535.0f) + return ((Quantum)65535.0f); - - -static inline Quantum ClampPixel(const MagickRealType pixel) -{ - if (pixel < 0.0f) - return((Quantum) 0); - if (pixel >= (MagickRealType) 65535.0f) - return((Quantum) 65535.0f); - - - - return((Quantum) pixel); - + return ((Quantum)pixel); } static inline Quantum GetPixela(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[aPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[aPixelChannel].offset]); } static inline Quantum GetPixelAlpha(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[AlphaPixelChannel].traits == UndefinedPixelTrait) - return(((Quantum) 65535.0f)); - return(pixel[image->channel_map[AlphaPixelChannel].offset]); + return (((Quantum)65535.0f)); + return (pixel[image->channel_map[AlphaPixelChannel].offset]); } -static inline PixelTrait GetPixelAlphaTraits(const Image *__restrict__ image) -{ - return(image->channel_map[AlphaPixelChannel].traits); +static inline PixelTrait GetPixelAlphaTraits(const Image *__restrict__ image) { + return (image->channel_map[AlphaPixelChannel].traits); } static inline Quantum GetPixelb(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[bPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[bPixelChannel].offset]); } static inline Quantum GetPixelBlack(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[BlackPixelChannel].traits == UndefinedPixelTrait) - return((Quantum) 0); - return(pixel[image->channel_map[BlackPixelChannel].offset]); + return ((Quantum)0); + return (pixel[image->channel_map[BlackPixelChannel].offset]); } -static inline PixelTrait GetPixelBlackTraits(const Image *__restrict__ image) -{ - return(image->channel_map[BlackPixelChannel].traits); +static inline PixelTrait GetPixelBlackTraits(const Image *__restrict__ image) { + return (image->channel_map[BlackPixelChannel].traits); } static inline Quantum GetPixelBlue(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[BluePixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[BluePixelChannel].offset]); } -static inline PixelTrait GetPixelBlueTraits(const Image *__restrict__ image) -{ - return(image->channel_map[BluePixelChannel].traits); +static inline PixelTrait GetPixelBlueTraits(const Image *__restrict__ image) { + return (image->channel_map[BluePixelChannel].traits); } static inline Quantum GetPixelCb(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[CbPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[CbPixelChannel].offset]); } -static inline PixelTrait GetPixelCbTraits(const Image *__restrict__ image) -{ - return(image->channel_map[CbPixelChannel].traits); +static inline PixelTrait GetPixelCbTraits(const Image *__restrict__ image) { + return (image->channel_map[CbPixelChannel].traits); } static inline Quantum GetPixelChannel(const Image *__restrict__ image, - const PixelChannel channel,const Quantum *__restrict__ pixel) -{ + const PixelChannel channel, + const Quantum *__restrict__ pixel) { if (image->channel_map[channel].traits == UndefinedPixelTrait) - return((Quantum) 0); - return(pixel[image->channel_map[channel].offset]); + return ((Quantum)0); + return (pixel[image->channel_map[channel].offset]); } -static inline PixelChannel GetPixelChannelChannel( - const Image *__restrict__ image,const ssize_t offset) -{ - return(image->channel_map[offset].channel); +static inline PixelChannel +GetPixelChannelChannel(const Image *__restrict__ image, const ssize_t offset) { + return (image->channel_map[offset].channel); } static inline ssize_t GetPixelChannelOffset(const Image *__restrict__ image, - const PixelChannel channel) -{ - return(image->channel_map[channel].offset); + const PixelChannel channel) { + return (image->channel_map[channel].offset); } -static inline PixelTrait GetPixelChannelTraits( - const Image *__restrict__ image,const PixelChannel channel) -{ - return(image->channel_map[channel].traits); +static inline PixelTrait GetPixelChannelTraits(const Image *__restrict__ image, + const PixelChannel channel) { + return (image->channel_map[channel].traits); } -static inline size_t GetPixelChannels(const Image *__restrict__ image) -{ - return(image->number_channels); +static inline size_t GetPixelChannels(const Image *__restrict__ image) { + return (image->number_channels); } -static inline Quantum GetPixelCompositeMask( - const Image *__restrict__ image,const Quantum *__restrict__ pixel) -{ - if (image->channel_map[CompositeMaskPixelChannel].traits == UndefinedPixelTrait) - return((Quantum) 65535.0f); - return(pixel[image->channel_map[CompositeMaskPixelChannel].offset]); +static inline Quantum GetPixelCompositeMask(const Image *__restrict__ image, + const Quantum *__restrict__ pixel) { + if (image->channel_map[CompositeMaskPixelChannel].traits == + UndefinedPixelTrait) + return ((Quantum)65535.0f); + return (pixel[image->channel_map[CompositeMaskPixelChannel].offset]); } -static inline PixelTrait GetPixelCompositeMaskTraits( - const Image *__restrict__ image) -{ - return(image->channel_map[CompositeMaskPixelChannel].traits); +static inline PixelTrait +GetPixelCompositeMaskTraits(const Image *__restrict__ image) { + return (image->channel_map[CompositeMaskPixelChannel].traits); } static inline Quantum GetPixelCr(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[CrPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[CrPixelChannel].offset]); } -static inline PixelTrait GetPixelCrTraits(const Image *__restrict__ image) -{ - return(image->channel_map[CrPixelChannel].traits); +static inline PixelTrait GetPixelCrTraits(const Image *__restrict__ image) { + return (image->channel_map[CrPixelChannel].traits); } static inline Quantum GetPixelCyan(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[CyanPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[CyanPixelChannel].offset]); } -static inline PixelTrait GetPixelCyanTraits(const Image *__restrict__ image) -{ - return(image->channel_map[CyanPixelChannel].traits); +static inline PixelTrait GetPixelCyanTraits(const Image *__restrict__ image) { + return (image->channel_map[CyanPixelChannel].traits); } static inline Quantum GetPixelGray(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[GrayPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[GrayPixelChannel].offset]); } -static inline PixelTrait GetPixelGrayTraits(const Image *__restrict__ image) -{ - return(image->channel_map[GrayPixelChannel].traits); +static inline PixelTrait GetPixelGrayTraits(const Image *__restrict__ image) { + return (image->channel_map[GrayPixelChannel].traits); } static inline Quantum GetPixelGreen(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[GreenPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[GreenPixelChannel].offset]); } -static inline PixelTrait GetPixelGreenTraits(const Image *__restrict__ image) -{ - return(image->channel_map[GreenPixelChannel].traits); +static inline PixelTrait GetPixelGreenTraits(const Image *__restrict__ image) { + return (image->channel_map[GreenPixelChannel].traits); } static inline Quantum GetPixelIndex(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[IndexPixelChannel].traits == UndefinedPixelTrait) - return((Quantum) 0); - return(pixel[image->channel_map[IndexPixelChannel].offset]); -} - -static inline PixelTrait GetPixelIndexTraits(const Image *__restrict__ image) -{ - return(image->channel_map[IndexPixelChannel].traits); -} - -static inline MagickRealType GetPixelInfoChannel( - const PixelInfo *__restrict__ pixel_info,const PixelChannel channel) -{ - switch (channel) - { - case RedPixelChannel: return(pixel_info->red); - case GreenPixelChannel: return(pixel_info->green); - case BluePixelChannel: return(pixel_info->blue); - case BlackPixelChannel: - { - if (pixel_info->colorspace != CMYKColorspace) - return(0.0); - return(pixel_info->black); - } - case AlphaPixelChannel: - { - if (pixel_info->alpha_trait == UndefinedPixelTrait) - return(((Quantum) 65535.0f)); - return(pixel_info->alpha); - } - case IndexPixelChannel: return(pixel_info->index); - default: return((MagickRealType) 0.0); + return ((Quantum)0); + return (pixel[image->channel_map[IndexPixelChannel].offset]); +} + +static inline PixelTrait GetPixelIndexTraits(const Image *__restrict__ image) { + return (image->channel_map[IndexPixelChannel].traits); +} + +static inline MagickRealType +GetPixelInfoChannel(const PixelInfo *__restrict__ pixel_info, + const PixelChannel channel) { + switch (channel) { + case RedPixelChannel: + return (pixel_info->red); + case GreenPixelChannel: + return (pixel_info->green); + case BluePixelChannel: + return (pixel_info->blue); + case BlackPixelChannel: { + if (pixel_info->colorspace != CMYKColorspace) + return (0.0); + return (pixel_info->black); + } + case AlphaPixelChannel: { + if (pixel_info->alpha_trait == UndefinedPixelTrait) + return (((Quantum)65535.0f)); + return (pixel_info->alpha); + } + case IndexPixelChannel: + return (pixel_info->index); + default: + return ((MagickRealType)0.0); } } -static inline double PerceptibleReciprocal(const double x) -{ - double - sign; - - - +static inline double PerceptibleReciprocal(const double x) { + double sign; - sign=x < 0.0 ? -1.0 : 1.0; - if ((sign*x) >= 1.0e-12) - return(1.0/x); - return(sign/1.0e-12); + sign = x < 0.0 ? -1.0 : 1.0; + if ((sign * x) >= 1.0e-12) + return (1.0 / x); + return (sign / 1.0e-12); } -static inline MagickRealType GetPixelInfoLuma( - const PixelInfo *__restrict__ pixel) -{ - MagickRealType - intensity; +static inline MagickRealType +GetPixelInfoLuma(const PixelInfo *__restrict__ pixel) { + MagickRealType intensity; - if (pixel->colorspace == sRGBColorspace) - { - intensity=(MagickRealType) (0.212656f*pixel->red+0.715158f*pixel->green+ - 0.072186f*pixel->blue); - return(intensity); - } - intensity=(MagickRealType) (0.212656f*EncodePixelGamma(pixel->red)+ - 0.715158f*EncodePixelGamma(pixel->green)+ - 0.072186f*EncodePixelGamma(pixel->blue)); - return(intensity); + if (pixel->colorspace == sRGBColorspace) { + intensity = + (MagickRealType)(0.212656f * pixel->red + 0.715158f * pixel->green + + 0.072186f * pixel->blue); + return (intensity); + } + intensity = (MagickRealType)(0.212656f * EncodePixelGamma(pixel->red) + + 0.715158f * EncodePixelGamma(pixel->green) + + 0.072186f * EncodePixelGamma(pixel->blue)); + return (intensity); } -static inline MagickRealType GetPixelInfoLuminance( - const PixelInfo *__restrict__ pixel) -{ - MagickRealType - intensity; +static inline MagickRealType +GetPixelInfoLuminance(const PixelInfo *__restrict__ pixel) { + MagickRealType intensity; - if (pixel->colorspace != sRGBColorspace) - { - intensity=(MagickRealType) (0.212656f*pixel->red+0.715158f*pixel->green+ - 0.072186f*pixel->blue); - return(intensity); - } - intensity=(MagickRealType) (0.212656f*DecodePixelGamma(pixel->red)+ - 0.715158f*DecodePixelGamma(pixel->green)+ - 0.072186f*DecodePixelGamma(pixel->blue)); - return(intensity); + if (pixel->colorspace != sRGBColorspace) { + intensity = + (MagickRealType)(0.212656f * pixel->red + 0.715158f * pixel->green + + 0.072186f * pixel->blue); + return (intensity); + } + intensity = (MagickRealType)(0.212656f * DecodePixelGamma(pixel->red) + + 0.715158f * DecodePixelGamma(pixel->green) + + 0.072186f * DecodePixelGamma(pixel->blue)); + return (intensity); } static inline Quantum GetPixelL(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[LPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[LPixelChannel].offset]); } static inline ssize_t GetPixelLabel(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return((ssize_t) pixel[image->channel_map[LabelPixelChannel].offset]); -} - -static inline MagickRealType GetPixelLuma( - const Image *__restrict__ image,const Quantum *__restrict__ pixel) -{ - MagickRealType - intensity; - - intensity= - 0.212656f*(MagickRealType) pixel[image->channel_map[RedPixelChannel].offset]+ - 0.715158f*(MagickRealType) pixel[image->channel_map[GreenPixelChannel].offset]+ - 0.072186f*(MagickRealType) pixel[image->channel_map[BluePixelChannel].offset]; - return(intensity); -} - -static inline MagickRealType GetPixelLuminance( - const Image *__restrict__ image,const Quantum *__restrict__ pixel) -{ - MagickRealType - intensity; - - if (image->colorspace != sRGBColorspace) - { - intensity= - 0.212656f*(MagickRealType) pixel[image->channel_map[RedPixelChannel].offset]+ - 0.715158f*(MagickRealType) pixel[image->channel_map[GreenPixelChannel].offset]+ - 0.072186f*(MagickRealType) pixel[image->channel_map[BluePixelChannel].offset]; - return(intensity); - } - intensity=(MagickRealType) (0.212656f*DecodePixelGamma((MagickRealType) - pixel[image->channel_map[RedPixelChannel].offset])+0.715158f* - DecodePixelGamma((MagickRealType) - pixel[image->channel_map[GreenPixelChannel].offset])+0.072186f* - DecodePixelGamma((MagickRealType) - pixel[image->channel_map[BluePixelChannel].offset])); - return(intensity); + const Quantum *__restrict__ pixel) { + return ((ssize_t)pixel[image->channel_map[LabelPixelChannel].offset]); +} + +static inline MagickRealType GetPixelLuma(const Image *__restrict__ image, + const Quantum *__restrict__ pixel) { + MagickRealType intensity; + + intensity = + 0.212656f * + (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset] + + 0.715158f * + (MagickRealType)pixel[image->channel_map[GreenPixelChannel].offset] + + 0.072186f * + (MagickRealType)pixel[image->channel_map[BluePixelChannel].offset]; + return (intensity); +} + +static inline MagickRealType +GetPixelLuminance(const Image *__restrict__ image, + const Quantum *__restrict__ pixel) { + MagickRealType intensity; + + if (image->colorspace != sRGBColorspace) { + intensity = + 0.212656f * + (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset] + + 0.715158f * (MagickRealType) + pixel[image->channel_map[GreenPixelChannel].offset] + + 0.072186f * + (MagickRealType)pixel[image->channel_map[BluePixelChannel].offset]; + return (intensity); + } + intensity = (MagickRealType)( + 0.212656f * DecodePixelGamma( + (MagickRealType) + pixel[image->channel_map[RedPixelChannel].offset]) + + 0.715158f * DecodePixelGamma( + (MagickRealType) + pixel[image->channel_map[GreenPixelChannel].offset]) + + 0.072186f * DecodePixelGamma( + (MagickRealType) + pixel[image->channel_map[BluePixelChannel].offset])); + return (intensity); } static inline Quantum GetPixelMagenta(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[MagentaPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[MagentaPixelChannel].offset]); } -static inline PixelTrait GetPixelMagentaTraits( - const Image *__restrict__ image) -{ - return(image->channel_map[MagentaPixelChannel].traits); +static inline PixelTrait +GetPixelMagentaTraits(const Image *__restrict__ image) { + return (image->channel_map[MagentaPixelChannel].traits); } static inline Quantum GetPixelMeta(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[MetaPixelChannel].traits == UndefinedPixelTrait) - return(((Quantum) 65535.0f)); - return(pixel[image->channel_map[MetaPixelChannel].offset]); + return (((Quantum)65535.0f)); + return (pixel[image->channel_map[MetaPixelChannel].offset]); } -static inline PixelTrait GetPixelMetaTraits(const Image *__restrict__ image) -{ - return(image->channel_map[MetaPixelChannel].traits); +static inline PixelTrait GetPixelMetaTraits(const Image *__restrict__ image) { + return (image->channel_map[MetaPixelChannel].traits); } static inline Quantum GetPixelReadMask(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[ReadMaskPixelChannel].traits == UndefinedPixelTrait) - return((Quantum) 65535.0f); - return(pixel[image->channel_map[ReadMaskPixelChannel].offset]); + return ((Quantum)65535.0f); + return (pixel[image->channel_map[ReadMaskPixelChannel].offset]); } -static inline void GetPixelInfoRGBA(const Quantum red,const Quantum green, - const Quantum blue,const Quantum alpha,PixelInfo *__restrict__ pixel) -{ - GetPixelInfo((Image *) - ((void *)0) - ,pixel); - pixel->red=red; - pixel->green=green; - pixel->blue=blue; - pixel->alpha=alpha; +static inline void GetPixelInfoRGBA(const Quantum red, const Quantum green, + const Quantum blue, const Quantum alpha, + PixelInfo *__restrict__ pixel) { + GetPixelInfo((Image *)((void *)0), pixel); + pixel->red = red; + pixel->green = green; + pixel->blue = blue; + pixel->alpha = alpha; } -static inline Quantum GetPixelWriteMask( - const Image *__restrict__ image,const Quantum *__restrict__ pixel) -{ +static inline Quantum GetPixelWriteMask(const Image *__restrict__ image, + const Quantum *__restrict__ pixel) { if (image->channel_map[WriteMaskPixelChannel].traits == UndefinedPixelTrait) - return((Quantum) 65535.0f); - return(pixel[image->channel_map[WriteMaskPixelChannel].offset]); + return ((Quantum)65535.0f); + return (pixel[image->channel_map[WriteMaskPixelChannel].offset]); } -static inline PixelTrait GetPixelReadMaskTraits( - const Image *__restrict__ image) -{ - return(image->channel_map[ReadMaskPixelChannel].traits); +static inline PixelTrait +GetPixelReadMaskTraits(const Image *__restrict__ image) { + return (image->channel_map[ReadMaskPixelChannel].traits); } -static inline size_t GetPixelMetaChannels(const Image *__restrict__ image) -{ - return(image->number_meta_channels); +static inline size_t GetPixelMetaChannels(const Image *__restrict__ image) { + return (image->number_meta_channels); } -static inline size_t GetPixelMetacontentExtent( - const Image *__restrict__ image) -{ - return(image->metacontent_extent); +static inline size_t +GetPixelMetacontentExtent(const Image *__restrict__ image) { + return (image->metacontent_extent); } static inline Quantum GetPixelOpacity(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ + const Quantum *__restrict__ pixel) { if (image->channel_map[AlphaPixelChannel].traits != BlendPixelTrait) - return(65535.0f -((Quantum) 65535.0f)); - return(65535.0f -pixel[image->channel_map[AlphaPixelChannel].offset]); + return (65535.0f - ((Quantum)65535.0f)); + return (65535.0f - pixel[image->channel_map[AlphaPixelChannel].offset]); } static inline Quantum GetPixelRed(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[RedPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[RedPixelChannel].offset]); } -static inline PixelTrait GetPixelRedTraits(const Image *__restrict__ image) -{ - return(image->channel_map[RedPixelChannel].traits); +static inline PixelTrait GetPixelRedTraits(const Image *__restrict__ image) { + return (image->channel_map[RedPixelChannel].traits); } static inline void GetPixelInfoPixel(const Image *__restrict__ image, - const Quantum *__restrict__ pixel,PixelInfo *__restrict__ pixel_info) -{ - (void) ResetMagickMemory(pixel_info,0,sizeof(*pixel_info)); - pixel_info->storage_class=DirectClass; - pixel_info->colorspace=sRGBColorspace; - pixel_info->depth=16; - pixel_info->alpha_trait=UndefinedPixelTrait; - pixel_info->alpha=(MagickRealType) ((Quantum) 65535.0f); - if (image != (Image *) - ((void *)0) - ) - { - pixel_info->storage_class=image->storage_class; - pixel_info->colorspace=image->colorspace; - pixel_info->fuzz=image->fuzz; - pixel_info->depth=image->depth; - pixel_info->alpha_trait=image->alpha_trait; - if (pixel != (Quantum *) - ((void *)0) - ) - { - pixel_info->red=(MagickRealType) - pixel[image->channel_map[RedPixelChannel].offset]; - pixel_info->green=(MagickRealType) - pixel[image->channel_map[GreenPixelChannel].offset]; - pixel_info->blue=(MagickRealType) - pixel[image->channel_map[BluePixelChannel].offset]; - if (image->channel_map[BlackPixelChannel].traits != UndefinedPixelTrait) - pixel_info->black=(MagickRealType) - pixel[image->channel_map[BlackPixelChannel].offset]; - if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) - pixel_info->alpha=(MagickRealType) - pixel[image->channel_map[AlphaPixelChannel].offset]; - if (image->channel_map[IndexPixelChannel].traits != UndefinedPixelTrait) - pixel_info->index=(MagickRealType) - pixel[image->channel_map[IndexPixelChannel].offset]; - } + const Quantum *__restrict__ pixel, + PixelInfo *__restrict__ pixel_info) { + (void)ResetMagickMemory(pixel_info, 0, sizeof(*pixel_info)); + pixel_info->storage_class = DirectClass; + pixel_info->colorspace = sRGBColorspace; + pixel_info->depth = 16; + pixel_info->alpha_trait = UndefinedPixelTrait; + pixel_info->alpha = (MagickRealType)((Quantum)65535.0f); + if (image != (Image *)((void *)0)) { + pixel_info->storage_class = image->storage_class; + pixel_info->colorspace = image->colorspace; + pixel_info->fuzz = image->fuzz; + pixel_info->depth = image->depth; + pixel_info->alpha_trait = image->alpha_trait; + if (pixel != (Quantum *)((void *)0)) { + pixel_info->red = + (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset]; + pixel_info->green = + (MagickRealType)pixel[image->channel_map[GreenPixelChannel].offset]; + pixel_info->blue = + (MagickRealType)pixel[image->channel_map[BluePixelChannel].offset]; + if (image->channel_map[BlackPixelChannel].traits != UndefinedPixelTrait) + pixel_info->black = + (MagickRealType)pixel[image->channel_map[BlackPixelChannel].offset]; + if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) + pixel_info->alpha = + (MagickRealType)pixel[image->channel_map[AlphaPixelChannel].offset]; + if (image->channel_map[IndexPixelChannel].traits != UndefinedPixelTrait) + pixel_info->index = + (MagickRealType)pixel[image->channel_map[IndexPixelChannel].offset]; } + } } static inline PixelTrait GetPixelTraits(const Image *__restrict__ image, - const PixelChannel channel) -{ - return(image->channel_map[channel].traits); + const PixelChannel channel) { + return (image->channel_map[channel].traits); } -static inline PixelTrait GetPixelWriteMaskTraits( - const Image *__restrict__ image) -{ - return(image->channel_map[WriteMaskPixelChannel].traits); +static inline PixelTrait +GetPixelWriteMaskTraits(const Image *__restrict__ image) { + return (image->channel_map[WriteMaskPixelChannel].traits); } static inline Quantum GetPixelY(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[YPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[YPixelChannel].offset]); } -static inline PixelTrait GetPixelYTraits(const Image *__restrict__ image) -{ - return(image->channel_map[YPixelChannel].traits); +static inline PixelTrait GetPixelYTraits(const Image *__restrict__ image) { + return (image->channel_map[YPixelChannel].traits); } static inline Quantum GetPixelYellow(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - return(pixel[image->channel_map[YellowPixelChannel].offset]); + const Quantum *__restrict__ pixel) { + return (pixel[image->channel_map[YellowPixelChannel].offset]); } -static inline PixelTrait GetPixelYellowTraits( - const Image *__restrict__ image) -{ - return(image->channel_map[YellowPixelChannel].traits); +static inline PixelTrait GetPixelYellowTraits(const Image *__restrict__ image) { + return (image->channel_map[YellowPixelChannel].traits); } -static inline MagickRealType AbsolutePixelValue(const MagickRealType x) -{ - return(x < 0.0f ? -x : x); +static inline MagickRealType AbsolutePixelValue(const MagickRealType x) { + return (x < 0.0f ? -x : x); } static inline MagickBooleanType IsPixelAtDepth(const Quantum pixel, - const QuantumAny range) -{ - Quantum - quantum; + const QuantumAny range) { + Quantum quantum; if (range == 0) - return(MagickTrue); - - - - - quantum=(Quantum) (((MagickRealType) 65535.0f*((QuantumAny) - (((MagickRealType) range*pixel)/65535.0f +0.5)))/(MagickRealType) range); - - return(pixel == quantum ? MagickTrue : MagickFalse); -} - -static inline MagickBooleanType IsPixelEquivalent( - const Image *__restrict__ image,const Quantum *__restrict__ p, - const PixelInfo *__restrict__ q) -{ - MagickRealType - alpha, - beta, - color; - - color=(MagickRealType) p[image->channel_map[AlphaPixelChannel].offset]; - alpha=image->alpha_trait == UndefinedPixelTrait ? (MagickRealType) - ((Quantum) 65535.0f) : color; - beta=q->alpha_trait == UndefinedPixelTrait ? (MagickRealType) ((Quantum) 65535.0f) : - q->alpha; - if (AbsolutePixelValue(alpha-beta) >= 1.0e-12) - return(MagickFalse); - if ((AbsolutePixelValue(alpha-((Quantum) 0)) < 1.0e-12) || - (AbsolutePixelValue(beta-((Quantum) 0)) < 1.0e-12)) - return(MagickTrue); - color=(MagickRealType) p[image->channel_map[RedPixelChannel].offset]; - if (AbsolutePixelValue(color-q->red) >= 1.0e-12) - return(MagickFalse); - color=(MagickRealType) p[image->channel_map[GreenPixelChannel].offset]; - if (AbsolutePixelValue(color-q->green) >= 1.0e-12) - return(MagickFalse); - color=(MagickRealType) p[image->channel_map[BluePixelChannel].offset]; - if (AbsolutePixelValue(color-q->blue) >= 1.0e-12) - return(MagickFalse); - if (image->colorspace == CMYKColorspace) - { - color=(MagickRealType) p[image->channel_map[BlackPixelChannel].offset]; - if (AbsolutePixelValue(color-q->black) >= 1.0e-12) - return(MagickFalse); - } - return(MagickTrue); + return (MagickTrue); + + quantum = (Quantum)( + ((MagickRealType)65535.0f * + ((QuantumAny)(((MagickRealType)range * pixel) / 65535.0f + 0.5))) / + (MagickRealType)range); + + return (pixel == quantum ? MagickTrue : MagickFalse); +} + +static inline MagickBooleanType +IsPixelEquivalent(const Image *__restrict__ image, + const Quantum *__restrict__ p, + const PixelInfo *__restrict__ q) { + MagickRealType alpha, beta, color; + + color = (MagickRealType)p[image->channel_map[AlphaPixelChannel].offset]; + alpha = image->alpha_trait == UndefinedPixelTrait + ? (MagickRealType)((Quantum)65535.0f) + : color; + beta = q->alpha_trait == UndefinedPixelTrait + ? (MagickRealType)((Quantum)65535.0f) + : q->alpha; + if (AbsolutePixelValue(alpha - beta) >= 1.0e-12) + return (MagickFalse); + if ((AbsolutePixelValue(alpha - ((Quantum)0)) < 1.0e-12) || + (AbsolutePixelValue(beta - ((Quantum)0)) < 1.0e-12)) + return (MagickTrue); + color = (MagickRealType)p[image->channel_map[RedPixelChannel].offset]; + if (AbsolutePixelValue(color - q->red) >= 1.0e-12) + return (MagickFalse); + color = (MagickRealType)p[image->channel_map[GreenPixelChannel].offset]; + if (AbsolutePixelValue(color - q->green) >= 1.0e-12) + return (MagickFalse); + color = (MagickRealType)p[image->channel_map[BluePixelChannel].offset]; + if (AbsolutePixelValue(color - q->blue) >= 1.0e-12) + return (MagickFalse); + if (image->colorspace == CMYKColorspace) { + color = (MagickRealType)p[image->channel_map[BlackPixelChannel].offset]; + if (AbsolutePixelValue(color - q->black) >= 1.0e-12) + return (MagickFalse); + } + return (MagickTrue); } static inline MagickBooleanType IsPixelGray(const Image *__restrict__ image, - const Quantum *__restrict__ pixel) -{ - MagickRealType - green_blue, - red_green; - - red_green=(MagickRealType) pixel[image->channel_map[RedPixelChannel].offset]- - pixel[image->channel_map[GreenPixelChannel].offset]; - green_blue=(MagickRealType) - pixel[image->channel_map[GreenPixelChannel].offset]- - pixel[image->channel_map[BluePixelChannel].offset]; + const Quantum *__restrict__ pixel) { + MagickRealType green_blue, red_green; + + red_green = + (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset] - + pixel[image->channel_map[GreenPixelChannel].offset]; + green_blue = + (MagickRealType)pixel[image->channel_map[GreenPixelChannel].offset] - + pixel[image->channel_map[BluePixelChannel].offset]; if ((AbsolutePixelValue(red_green) < 1.0e-12) && (AbsolutePixelValue(green_blue) < 1.0e-12)) - return(MagickTrue); - return(MagickFalse); -} - -static inline MagickBooleanType IsPixelInfoEquivalent( - const PixelInfo *__restrict__ p,const PixelInfo *__restrict__ q) -{ - MagickRealType - alpha, - beta; - - alpha=p->alpha_trait == UndefinedPixelTrait ? (MagickRealType) ((Quantum) 65535.0f) : - p->alpha; - beta=q->alpha_trait == UndefinedPixelTrait ? (MagickRealType) ((Quantum) 65535.0f) : - q->alpha; - if (AbsolutePixelValue(alpha-beta) >= 1.0e-12) - return(MagickFalse); - if ((AbsolutePixelValue(alpha-((Quantum) 0)) < 1.0e-12) || - (AbsolutePixelValue(beta-((Quantum) 0)) < 1.0e-12)) - return(MagickTrue); - if (AbsolutePixelValue(p->red-q->red) >= 1.0e-12) - return(MagickFalse); - if (AbsolutePixelValue(p->green-q->green) >= 1.0e-12) - return(MagickFalse); - if (AbsolutePixelValue(p->blue-q->blue) >= 1.0e-12) - return(MagickFalse); - if (p->colorspace == CMYKColorspace) - { - if (AbsolutePixelValue(p->black-q->black) >= 1.0e-12) - return(MagickFalse); - } - return(MagickTrue); + return (MagickTrue); + return (MagickFalse); +} + +static inline MagickBooleanType +IsPixelInfoEquivalent(const PixelInfo *__restrict__ p, + const PixelInfo *__restrict__ q) { + MagickRealType alpha, beta; + + alpha = p->alpha_trait == UndefinedPixelTrait + ? (MagickRealType)((Quantum)65535.0f) + : p->alpha; + beta = q->alpha_trait == UndefinedPixelTrait + ? (MagickRealType)((Quantum)65535.0f) + : q->alpha; + if (AbsolutePixelValue(alpha - beta) >= 1.0e-12) + return (MagickFalse); + if ((AbsolutePixelValue(alpha - ((Quantum)0)) < 1.0e-12) || + (AbsolutePixelValue(beta - ((Quantum)0)) < 1.0e-12)) + return (MagickTrue); + if (AbsolutePixelValue(p->red - q->red) >= 1.0e-12) + return (MagickFalse); + if (AbsolutePixelValue(p->green - q->green) >= 1.0e-12) + return (MagickFalse); + if (AbsolutePixelValue(p->blue - q->blue) >= 1.0e-12) + return (MagickFalse); + if (p->colorspace == CMYKColorspace) { + if (AbsolutePixelValue(p->black - q->black) >= 1.0e-12) + return (MagickFalse); + } + return (MagickTrue); } -static inline MagickBooleanType IsPixelMonochrome( - const Image *__restrict__ image,const Quantum *__restrict__ pixel) -{ - MagickRealType - green_blue, - red, - red_green; +static inline MagickBooleanType +IsPixelMonochrome(const Image *__restrict__ image, + const Quantum *__restrict__ pixel) { + MagickRealType green_blue, red, red_green; - red=(MagickRealType) pixel[image->channel_map[RedPixelChannel].offset]; + red = (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset]; if ((AbsolutePixelValue(red) >= 1.0e-12) && - (AbsolutePixelValue(red-65535.0f) >= 1.0e-12)) - return(MagickFalse); - red_green=(MagickRealType) pixel[image->channel_map[RedPixelChannel].offset]- - pixel[image->channel_map[GreenPixelChannel].offset]; - green_blue=(MagickRealType) - pixel[image->channel_map[GreenPixelChannel].offset]- - pixel[image->channel_map[BluePixelChannel].offset]; + (AbsolutePixelValue(red - 65535.0f) >= 1.0e-12)) + return (MagickFalse); + red_green = + (MagickRealType)pixel[image->channel_map[RedPixelChannel].offset] - + pixel[image->channel_map[GreenPixelChannel].offset]; + green_blue = + (MagickRealType)pixel[image->channel_map[GreenPixelChannel].offset] - + pixel[image->channel_map[BluePixelChannel].offset]; if ((AbsolutePixelValue(red_green) < 1.0e-12) && (AbsolutePixelValue(green_blue) < 1.0e-12)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsPixelInfoGray( - const PixelInfo *__restrict__ pixel) -{ - if ((AbsolutePixelValue(pixel->red-pixel->green) < 1.0e-12) && - (AbsolutePixelValue(pixel->green-pixel->blue) < 1.0e-12)) - return(MagickTrue); - return(MagickFalse); +static inline MagickBooleanType +IsPixelInfoGray(const PixelInfo *__restrict__ pixel) { + if ((AbsolutePixelValue(pixel->red - pixel->green) < 1.0e-12) && + (AbsolutePixelValue(pixel->green - pixel->blue) < 1.0e-12)) + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsPixelInfoMonochrome( - const PixelInfo *__restrict__ pixel_info) -{ - MagickRealType - green_blue, - red_green; +static inline MagickBooleanType +IsPixelInfoMonochrome(const PixelInfo *__restrict__ pixel_info) { + MagickRealType green_blue, red_green; if ((AbsolutePixelValue(pixel_info->red) >= 1.0e-12) || - (AbsolutePixelValue(pixel_info->red-65535.0f) >= 1.0e-12)) - return(MagickFalse); - red_green=pixel_info->red-pixel_info->green; - green_blue=pixel_info->green-pixel_info->blue; + (AbsolutePixelValue(pixel_info->red - 65535.0f) >= 1.0e-12)) + return (MagickFalse); + red_green = pixel_info->red - pixel_info->green; + green_blue = pixel_info->green - pixel_info->blue; if ((AbsolutePixelValue(red_green) < 1.0e-12) && (AbsolutePixelValue(green_blue) < 1.0e-12)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline void SetPixela(const Image *__restrict__ image, - const Quantum a,Quantum *__restrict__ pixel) -{ +static inline void SetPixela(const Image *__restrict__ image, const Quantum a, + Quantum *__restrict__ pixel) { if (image->channel_map[aPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[aPixelChannel].offset]=a; + pixel[image->channel_map[aPixelChannel].offset] = a; } static inline void SetPixelAlpha(const Image *__restrict__ image, - const Quantum alpha,Quantum *__restrict__ pixel) -{ + const Quantum alpha, + Quantum *__restrict__ pixel) { if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[AlphaPixelChannel].offset]=alpha; + pixel[image->channel_map[AlphaPixelChannel].offset] = alpha; } -static inline void SetPixelAlphaTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[AlphaPixelChannel].traits=traits; +static inline void SetPixelAlphaTraits(Image *image, const PixelTrait traits) { + image->channel_map[AlphaPixelChannel].traits = traits; } -static inline void SetPixelb(const Image *__restrict__ image, - const Quantum b,Quantum *__restrict__ pixel) -{ +static inline void SetPixelb(const Image *__restrict__ image, const Quantum b, + Quantum *__restrict__ pixel) { if (image->channel_map[bPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[bPixelChannel].offset]=b; + pixel[image->channel_map[bPixelChannel].offset] = b; } static inline void SetPixelBackgroundColor(const Image *__restrict__ image, - Quantum *__restrict__ pixel) -{ - ssize_t - i; - - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - pixel[i]=(Quantum) 0; - pixel[image->channel_map[RedPixelChannel].offset]= - ClampToQuantum(image->background_color.red); - pixel[image->channel_map[GreenPixelChannel].offset]= - ClampToQuantum(image->background_color.green); - pixel[image->channel_map[BluePixelChannel].offset]= - ClampToQuantum(image->background_color.blue); + Quantum *__restrict__ pixel) { + ssize_t i; + + for (i = 0; i < (ssize_t)GetPixelChannels(image); i++) + pixel[i] = (Quantum)0; + pixel[image->channel_map[RedPixelChannel].offset] = + ClampToQuantum(image->background_color.red); + pixel[image->channel_map[GreenPixelChannel].offset] = + ClampToQuantum(image->background_color.green); + pixel[image->channel_map[BluePixelChannel].offset] = + ClampToQuantum(image->background_color.blue); if (image->channel_map[BlackPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[BlackPixelChannel].offset]= - ClampToQuantum(image->background_color.black); + pixel[image->channel_map[BlackPixelChannel].offset] = + ClampToQuantum(image->background_color.black); if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[AlphaPixelChannel].offset]= - image->background_color.alpha_trait == UndefinedPixelTrait ? ((Quantum) 65535.0f) : - ClampToQuantum(image->background_color.alpha); + pixel[image->channel_map[AlphaPixelChannel].offset] = + image->background_color.alpha_trait == UndefinedPixelTrait + ? ((Quantum)65535.0f) + : ClampToQuantum(image->background_color.alpha); } static inline void SetPixelBackgoundColor(const Image *__restrict__ image, - Quantum *__restrict__ pixel) __attribute__((deprecated)); + Quantum *__restrict__ pixel) + __attribute__((deprecated)); static inline void SetPixelBackgoundColor(const Image *__restrict__ image, - Quantum *__restrict__ pixel) -{ - SetPixelBackgroundColor(image,pixel); + Quantum *__restrict__ pixel) { + SetPixelBackgroundColor(image, pixel); } static inline void SetPixelBlack(const Image *__restrict__ image, - const Quantum black,Quantum *__restrict__ pixel) -{ + const Quantum black, + Quantum *__restrict__ pixel) { if (image->channel_map[BlackPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[BlackPixelChannel].offset]=black; + pixel[image->channel_map[BlackPixelChannel].offset] = black; } -static inline void SetPixelBlackTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[BlackPixelChannel].traits=traits; +static inline void SetPixelBlackTraits(Image *image, const PixelTrait traits) { + image->channel_map[BlackPixelChannel].traits = traits; } static inline void SetPixelBlue(const Image *__restrict__ image, - const Quantum blue,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[BluePixelChannel].offset]=blue; + const Quantum blue, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[BluePixelChannel].offset] = blue; } -static inline void SetPixelBlueTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[BluePixelChannel].traits=traits; +static inline void SetPixelBlueTraits(Image *image, const PixelTrait traits) { + image->channel_map[BluePixelChannel].traits = traits; } -static inline void SetPixelCb(const Image *__restrict__ image, - const Quantum cb,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[CbPixelChannel].offset]=cb; +static inline void SetPixelCb(const Image *__restrict__ image, const Quantum cb, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[CbPixelChannel].offset] = cb; } -static inline void SetPixelCbTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[CbPixelChannel].traits=traits; +static inline void SetPixelCbTraits(Image *image, const PixelTrait traits) { + image->channel_map[CbPixelChannel].traits = traits; } static inline void SetPixelChannel(const Image *__restrict__ image, - const PixelChannel channel,const Quantum quantum, - Quantum *__restrict__ pixel) -{ + const PixelChannel channel, + const Quantum quantum, + Quantum *__restrict__ pixel) { if (image->channel_map[channel].traits != UndefinedPixelTrait) - pixel[image->channel_map[channel].offset]=quantum; + pixel[image->channel_map[channel].offset] = quantum; } -static inline void SetPixelChannelAttributes( - const Image *__restrict__ image,const PixelChannel channel, - const PixelTrait traits,const ssize_t offset) -{ - if ((ssize_t) channel >= 64) +static inline void SetPixelChannelAttributes(const Image *__restrict__ image, + const PixelChannel channel, + const PixelTrait traits, + const ssize_t offset) { + if ((ssize_t)channel >= 64) return; if (offset >= 64) return; - image->channel_map[offset].channel=channel; - image->channel_map[channel].offset=offset; - image->channel_map[channel].traits=traits; + image->channel_map[offset].channel = channel; + image->channel_map[channel].offset = offset; + image->channel_map[channel].traits = traits; } static inline void SetPixelChannelChannel(const Image *__restrict__ image, - const PixelChannel channel,const ssize_t offset) -{ - image->channel_map[offset].channel=channel; - image->channel_map[channel].offset=offset; + const PixelChannel channel, + const ssize_t offset) { + image->channel_map[offset].channel = channel; + image->channel_map[channel].offset = offset; } -static inline void SetPixelChannels(Image *image,const size_t number_channels) -{ - image->number_channels=number_channels; +static inline void SetPixelChannels(Image *image, + const size_t number_channels) { + image->number_channels = number_channels; } static inline void SetPixelChannelTraits(Image *image, - const PixelChannel channel,const PixelTrait traits) -{ - image->channel_map[channel].traits=traits; + const PixelChannel channel, + const PixelTrait traits) { + image->channel_map[channel].traits = traits; } static inline void SetPixelCompositeMask(const Image *__restrict__ image, - const Quantum mask,Quantum *__restrict__ pixel) -{ - if (image->channel_map[CompositeMaskPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[CompositeMaskPixelChannel].offset]=mask; + const Quantum mask, + Quantum *__restrict__ pixel) { + if (image->channel_map[CompositeMaskPixelChannel].traits != + UndefinedPixelTrait) + pixel[image->channel_map[CompositeMaskPixelChannel].offset] = mask; } -static inline void SetPixelCr(const Image *__restrict__ image, - const Quantum cr,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[CrPixelChannel].offset]=cr; +static inline void SetPixelCr(const Image *__restrict__ image, const Quantum cr, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[CrPixelChannel].offset] = cr; } -static inline void SetPixelCrTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[CrPixelChannel].traits=traits; +static inline void SetPixelCrTraits(Image *image, const PixelTrait traits) { + image->channel_map[CrPixelChannel].traits = traits; } static inline void SetPixelCyan(const Image *__restrict__ image, - const Quantum cyan,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[CyanPixelChannel].offset]=cyan; + const Quantum cyan, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[CyanPixelChannel].offset] = cyan; } static inline void SetPixelGray(const Image *__restrict__ image, - const Quantum gray,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[GrayPixelChannel].offset]=gray; + const Quantum gray, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[GrayPixelChannel].offset] = gray; } -static inline void SetPixelGrayTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[GrayPixelChannel].traits=traits; +static inline void SetPixelGrayTraits(Image *image, const PixelTrait traits) { + image->channel_map[GrayPixelChannel].traits = traits; } static inline void SetPixelGreen(const Image *__restrict__ image, - const Quantum green,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[GreenPixelChannel].offset]=green; + const Quantum green, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[GreenPixelChannel].offset] = green; } -static inline void SetPixelGreenTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[GreenPixelChannel].traits=traits; +static inline void SetPixelGreenTraits(Image *image, const PixelTrait traits) { + image->channel_map[GreenPixelChannel].traits = traits; } static inline void SetPixelIndex(const Image *__restrict__ image, - const Quantum index,Quantum *__restrict__ pixel) -{ + const Quantum index, + Quantum *__restrict__ pixel) { if (image->channel_map[IndexPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[IndexPixelChannel].offset]=index; + pixel[image->channel_map[IndexPixelChannel].offset] = index; } -static inline void SetPixelIndexTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[IndexPixelChannel].traits=traits; +static inline void SetPixelIndexTraits(Image *image, const PixelTrait traits) { + image->channel_map[IndexPixelChannel].traits = traits; } -static inline void SetPixelViaPixelInfo(const Image *__restrict__ image, - const PixelInfo *__restrict__ pixel_info,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[RedPixelChannel].offset]= - ClampToQuantum(pixel_info->red); - pixel[image->channel_map[GreenPixelChannel].offset]= - ClampToQuantum(pixel_info->green); - pixel[image->channel_map[BluePixelChannel].offset]= - ClampToQuantum(pixel_info->blue); +static inline void +SetPixelViaPixelInfo(const Image *__restrict__ image, + const PixelInfo *__restrict__ pixel_info, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[RedPixelChannel].offset] = + ClampToQuantum(pixel_info->red); + pixel[image->channel_map[GreenPixelChannel].offset] = + ClampToQuantum(pixel_info->green); + pixel[image->channel_map[BluePixelChannel].offset] = + ClampToQuantum(pixel_info->blue); if (image->channel_map[BlackPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[BlackPixelChannel].offset]= - ClampToQuantum(pixel_info->black); + pixel[image->channel_map[BlackPixelChannel].offset] = + ClampToQuantum(pixel_info->black); if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[AlphaPixelChannel].offset]= - pixel_info->alpha_trait == UndefinedPixelTrait ? ((Quantum) 65535.0f) : - ClampToQuantum(pixel_info->alpha); + pixel[image->channel_map[AlphaPixelChannel].offset] = + pixel_info->alpha_trait == UndefinedPixelTrait + ? ((Quantum)65535.0f) + : ClampToQuantum(pixel_info->alpha); } -static inline void SetPixelL(const Image *__restrict__ image,const Quantum L, - Quantum *__restrict__ pixel) -{ +static inline void SetPixelL(const Image *__restrict__ image, const Quantum L, + Quantum *__restrict__ pixel) { if (image->channel_map[LPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[LPixelChannel].offset]=L; + pixel[image->channel_map[LPixelChannel].offset] = L; } static inline void SetPixelMagenta(const Image *__restrict__ image, - const Quantum magenta,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[MagentaPixelChannel].offset]=magenta; + const Quantum magenta, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[MagentaPixelChannel].offset] = magenta; } -static inline void SetPixelMagentaTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[MagentaPixelChannel].traits=traits; +static inline void SetPixelMagentaTraits(Image *image, + const PixelTrait traits) { + image->channel_map[MagentaPixelChannel].traits = traits; } static inline void SetPixelMeta(const Image *__restrict__ image, - const Quantum red,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[MetaPixelChannel].offset]=red; + const Quantum red, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[MetaPixelChannel].offset] = red; } -static inline void SetPixelMetaTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[MetaPixelChannel].traits=traits; +static inline void SetPixelMetaTraits(Image *image, const PixelTrait traits) { + image->channel_map[MetaPixelChannel].traits = traits; } static inline void SetPixelReadMask(const Image *__restrict__ image, - const Quantum mask,Quantum *__restrict__ pixel) -{ + const Quantum mask, + Quantum *__restrict__ pixel) { if (image->channel_map[ReadMaskPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[ReadMaskPixelChannel].offset]=mask; + pixel[image->channel_map[ReadMaskPixelChannel].offset] = mask; } -static inline void SetPixelMetacontentExtent(Image *image,const size_t extent) -{ - image->metacontent_extent=extent; +static inline void SetPixelMetacontentExtent(Image *image, + const size_t extent) { + image->metacontent_extent = extent; } static inline void SetPixelOpacity(const Image *__restrict__ image, - const Quantum alpha,Quantum *__restrict__ pixel) -{ + const Quantum alpha, + Quantum *__restrict__ pixel) { if (image->channel_map[AlphaPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[AlphaPixelChannel].offset]=65535.0f -alpha; -} - -static inline void SetPixelRed(const Image *__restrict__ image, - const Quantum red,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[RedPixelChannel].offset]=red; -} - -static inline void SetPixelRedTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[RedPixelChannel].traits=traits; -} - -static inline void SetPixelWriteMask(const Image *__restrict__ image, - const Quantum mask,Quantum *__restrict__ pixel) -{ - if (image->channel_map[WriteMaskPixelChannel].traits != UndefinedPixelTrait) - pixel[image->channel_map[WriteMaskPixelChannel].offset]=mask; -} - -static inline void SetPixelYellow(const Image *__restrict__ image, - const Quantum yellow,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[YellowPixelChannel].offset]=yellow; -} - -static inline void SetPixelYellowTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[YellowPixelChannel].traits=traits; -} - -static inline void SetPixelY(const Image *__restrict__ image, - const Quantum y,Quantum *__restrict__ pixel) -{ - pixel[image->channel_map[YPixelChannel].offset]=y; -} - -static inline void SetPixelYTraits(Image *image,const PixelTrait traits) -{ - image->channel_map[YPixelChannel].traits=traits; -} - - - - - - -typedef struct _QuantumState -{ - double - inverse_scale; - - unsigned int - pixel; - - size_t - bits; - - const unsigned int - *mask; -} QuantumState; - -struct _QuantumInfo -{ - size_t - depth, - quantum; - - QuantumFormatType - format; - - double - minimum, - maximum, - scale; - - size_t - pad; - - MagickBooleanType - min_is_white, - pack; - - QuantumAlphaType - alpha_type; - - size_t - number_threads; - - MemoryInfo - **pixels; - - size_t - extent; - - EndianType - endian; - - QuantumState - state; - - SemaphoreInfo - *semaphore; - - size_t - signature; -}; - -extern __attribute__ ((visibility ("hidden"))) void - ResetQuantumState(QuantumInfo *); - -static inline MagickSizeType GetQuantumRange(const size_t depth) -{ - MagickSizeType - one; - - size_t - max_depth; - - if (depth == 0) - return(0); - one=1; - max_depth=8*sizeof(MagickSizeType); - return((MagickSizeType) ((one << ((((depth) < (max_depth)) ? (depth) : (max_depth))-1))+ - ((one << ((((depth) < (max_depth)) ? (depth) : (max_depth))-1))-1))); -} - -static inline float HalfToSinglePrecision(const unsigned short half) -{ - - - - - - - - typedef union _SinglePrecision - { - unsigned int - fixed_point; - - float - single_precision; - } SinglePrecision; - - unsigned int - exponent, - significand, - sign_bit; - - SinglePrecision - map; - - unsigned int - value; - sign_bit=(unsigned int) ((half >> 15) & 0x00000001); - exponent=(unsigned int) ((half >> 10) & 0x0000001f); - significand=(unsigned int) (half & 0x000003ff); - if (exponent == 0) - { - if (significand == 0) - value=sign_bit << 31; - else - { - while ((significand & 0x00000400) == 0) - { - significand<<=1; - exponent--; - } - exponent++; - significand&=(~0x00000400); - exponent+=(127-15); - value=(sign_bit << 31) | (exponent << 23) | - (significand << 13); - } - } - else - if (exponent == 31) - { - value=(sign_bit << 31) | 0x7f800000; - if (significand != 0) - value|=(significand << 13); - } - else - { - exponent+=(127-15); - significand<<=13; - value=(sign_bit << 31) | (exponent << 23) | - significand; - } - map.fixed_point=value; - return(map.single_precision); -} - -static inline unsigned char *PopCharPixel(const unsigned char pixel, - unsigned char *__restrict__ pixels) -{ - *pixels++=pixel; - return(pixels); -} - -static inline unsigned char *PopLongPixel(const EndianType endian, - const unsigned int pixel,unsigned char *__restrict__ pixels) -{ - unsigned int - quantum; - - quantum=(unsigned int) pixel; - if (endian == LSBEndian) - { - *pixels++=(unsigned char) (quantum); - *pixels++=(unsigned char) (quantum >> 8); - *pixels++=(unsigned char) (quantum >> 16); - *pixels++=(unsigned char) (quantum >> 24); - return(pixels); - } - *pixels++=(unsigned char) (quantum >> 24); - *pixels++=(unsigned char) (quantum >> 16); - *pixels++=(unsigned char) (quantum >> 8); - *pixels++=(unsigned char) (quantum); - return(pixels); -} - -static inline unsigned char *PopShortPixel(const EndianType endian, - const unsigned short pixel,unsigned char *__restrict__ pixels) -{ - unsigned int - quantum; - - quantum=pixel; - if (endian == LSBEndian) - { - *pixels++=(unsigned char) (quantum); - *pixels++=(unsigned char) (quantum >> 8); - return(pixels); - } - *pixels++=(unsigned char) (quantum >> 8); - *pixels++=(unsigned char) (quantum); - return(pixels); -} - -static inline const unsigned char *PushCharPixel( - const unsigned char *__restrict__ pixels, - unsigned char *__restrict__ pixel) -{ - *pixel=(*pixels++); - return(pixels); + pixel[image->channel_map[AlphaPixelChannel].offset] = 65535.0f - alpha; } -static inline const unsigned char *PushLongPixel(const EndianType endian, - const unsigned char *__restrict__ pixels, - unsigned int *__restrict__ pixel) -{ - unsigned int - quantum; +static inline void SetPixelRed(const Image *__restrict__ image, + const Quantum red, Quantum *__restrict__ pixel) { + pixel[image->channel_map[RedPixelChannel].offset] = red; +} - if (endian == LSBEndian) - { - quantum=((unsigned int) *pixels++); - quantum|=((unsigned int) *pixels++ << 8); - quantum|=((unsigned int) *pixels++ << 16); - quantum|=((unsigned int) *pixels++ << 24); - *pixel=quantum; - return(pixels); - } - quantum=((unsigned int) *pixels++ << 24); - quantum|=((unsigned int) *pixels++ << 16); - quantum|=((unsigned int) *pixels++ << 8); - quantum|=((unsigned int) *pixels++); - *pixel=quantum; - return(pixels); +static inline void SetPixelRedTraits(Image *image, const PixelTrait traits) { + image->channel_map[RedPixelChannel].traits = traits; } -static inline const unsigned char *PushShortPixel(const EndianType endian, - const unsigned char *__restrict__ pixels, - unsigned short *__restrict__ pixel) -{ - unsigned int - quantum; +static inline void SetPixelWriteMask(const Image *__restrict__ image, + const Quantum mask, + Quantum *__restrict__ pixel) { + if (image->channel_map[WriteMaskPixelChannel].traits != UndefinedPixelTrait) + pixel[image->channel_map[WriteMaskPixelChannel].offset] = mask; +} - if (endian == LSBEndian) - { - quantum=(unsigned int) *pixels++; - quantum|=(unsigned int) (*pixels++ << 8); - *pixel=(unsigned short) (quantum & 0xffff); - return(pixels); - } - quantum=(unsigned int) (*pixels++ << 8); - quantum|=(unsigned int) *pixels++; - *pixel=(unsigned short) (quantum & 0xffff); - return(pixels); +static inline void SetPixelYellow(const Image *__restrict__ image, + const Quantum yellow, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[YellowPixelChannel].offset] = yellow; } -static inline const unsigned char *PushFloatPixel(const EndianType endian, - const unsigned char *__restrict__ pixels, - MagickFloatType *__restrict__ pixel) -{ - union - { - unsigned int - unsigned_value; +static inline void SetPixelYellowTraits(Image *image, const PixelTrait traits) { + image->channel_map[YellowPixelChannel].traits = traits; +} - MagickFloatType - float_value; - } quantum; +static inline void SetPixelY(const Image *__restrict__ image, const Quantum y, + Quantum *__restrict__ pixel) { + pixel[image->channel_map[YPixelChannel].offset] = y; +} - if (endian == LSBEndian) - { - quantum.unsigned_value=((unsigned int) *pixels++); - quantum.unsigned_value|=((unsigned int) *pixels++ << 8); - quantum.unsigned_value|=((unsigned int) *pixels++ << 16); - quantum.unsigned_value|=((unsigned int) *pixels++ << 24); - *pixel=quantum.float_value; - return(pixels); - } - quantum.unsigned_value=((unsigned int) *pixels++ << 24); - quantum.unsigned_value|=((unsigned int) *pixels++ << 16); - quantum.unsigned_value|=((unsigned int) *pixels++ << 8); - quantum.unsigned_value|=((unsigned int) *pixels++); - *pixel=quantum.float_value; - return(pixels); +static inline void SetPixelYTraits(Image *image, const PixelTrait traits) { + image->channel_map[YPixelChannel].traits = traits; } -static inline Quantum ScaleAnyToQuantum(const QuantumAny quantum, - const QuantumAny range) -{ - if (quantum > range) - return(65535.0f); +typedef struct _QuantumState { + double inverse_scale; + unsigned int pixel; + size_t bits; + const unsigned int *mask; +} QuantumState; - return((Quantum) ((double) 65535.0f*(quantum* - PerceptibleReciprocal((double) range)))); +struct _QuantumInfo { + size_t depth, quantum; -} + QuantumFormatType format; -static inline QuantumAny ScaleQuantumToAny(const Quantum quantum, - const QuantumAny range) -{ + double minimum, maximum, scale; + size_t pad; + MagickBooleanType min_is_white, pack; - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return((QuantumAny) 0UL); - if (((double) range*quantum/65535.0f) >= 18446744073709551615.0) - return((QuantumAny) ((MagickSizeType) (18446744073709551615ULL))); - return((QuantumAny) ((double) range*quantum/65535.0f +0.5)); + QuantumAlphaType alpha_type; -} -static inline Quantum ScaleCharToQuantum(const unsigned char value) -{ + size_t number_threads; + MemoryInfo **pixels; + size_t extent; - return((Quantum) (257.0*value)); + EndianType endian; -} + QuantumState state; -static inline Quantum ScaleLongToQuantum(const unsigned int value) -{ + SemaphoreInfo *semaphore; + + size_t signature; +}; +extern __attribute__((visibility("hidden"))) void +ResetQuantumState(QuantumInfo *); +static inline MagickSizeType GetQuantumRange(const size_t depth) { + MagickSizeType one; - return((Quantum) (value/65537.0)); + size_t max_depth; + if (depth == 0) + return (0); + one = 1; + max_depth = 8 * sizeof(MagickSizeType); + return ((MagickSizeType)( + (one << ((((depth) < (max_depth)) ? (depth) : (max_depth)) - 1)) + + ((one << ((((depth) < (max_depth)) ? (depth) : (max_depth)) - 1)) - 1))); } -static inline Quantum ScaleLongLongToQuantum(const MagickSizeType value) -{ +static inline float HalfToSinglePrecision(const unsigned short half) { + typedef union _SinglePrecision { + unsigned int fixed_point; + float single_precision; + } SinglePrecision; - return((Quantum) (value/281479271743489.0)); + unsigned int exponent, significand, sign_bit; + + SinglePrecision map; + + unsigned int value; + sign_bit = (unsigned int)((half >> 15) & 0x00000001); + exponent = (unsigned int)((half >> 10) & 0x0000001f); + significand = (unsigned int)(half & 0x000003ff); + if (exponent == 0) { + if (significand == 0) + value = sign_bit << 31; + else { + while ((significand & 0x00000400) == 0) { + significand <<= 1; + exponent--; + } + exponent++; + significand &= (~0x00000400); + exponent += (127 - 15); + value = (sign_bit << 31) | (exponent << 23) | (significand << 13); + } + } else if (exponent == 31) { + value = (sign_bit << 31) | 0x7f800000; + if (significand != 0) + value |= (significand << 13); + } else { + exponent += (127 - 15); + significand <<= 13; + value = (sign_bit << 31) | (exponent << 23) | significand; + } + map.fixed_point = value; + return (map.single_precision); +} +static inline unsigned char *PopCharPixel(const unsigned char pixel, + unsigned char *__restrict__ pixels) { + *pixels++ = pixel; + return (pixels); } -static inline Quantum ScaleMapToQuantum(const MagickRealType value) -{ - if (value <= 0.0) - return((Quantum) 0); - if (value >= 65535UL) - return(65535.0f); +static inline unsigned char *PopLongPixel(const EndianType endian, + const unsigned int pixel, + unsigned char *__restrict__ pixels) { + unsigned int quantum; + + quantum = (unsigned int)pixel; + if (endian == LSBEndian) { + *pixels++ = (unsigned char)(quantum); + *pixels++ = (unsigned char)(quantum >> 8); + *pixels++ = (unsigned char)(quantum >> 16); + *pixels++ = (unsigned char)(quantum >> 24); + return (pixels); + } + *pixels++ = (unsigned char)(quantum >> 24); + *pixels++ = (unsigned char)(quantum >> 16); + *pixels++ = (unsigned char)(quantum >> 8); + *pixels++ = (unsigned char)(quantum); + return (pixels); +} +static inline unsigned char *PopShortPixel(const EndianType endian, + const unsigned short pixel, + unsigned char *__restrict__ pixels) { + unsigned int quantum; + + quantum = pixel; + if (endian == LSBEndian) { + *pixels++ = (unsigned char)(quantum); + *pixels++ = (unsigned char)(quantum >> 8); + return (pixels); + } + *pixels++ = (unsigned char)(quantum >> 8); + *pixels++ = (unsigned char)(quantum); + return (pixels); +} + +static inline const unsigned char * +PushCharPixel(const unsigned char *__restrict__ pixels, + unsigned char *__restrict__ pixel) { + *pixel = (*pixels++); + return (pixels); +} + +static inline const unsigned char * +PushLongPixel(const EndianType endian, const unsigned char *__restrict__ pixels, + unsigned int *__restrict__ pixel) { + unsigned int quantum; + + if (endian == LSBEndian) { + quantum = ((unsigned int)*pixels++); + quantum |= ((unsigned int)*pixels++ << 8); + quantum |= ((unsigned int)*pixels++ << 16); + quantum |= ((unsigned int)*pixels++ << 24); + *pixel = quantum; + return (pixels); + } + quantum = ((unsigned int)*pixels++ << 24); + quantum |= ((unsigned int)*pixels++ << 16); + quantum |= ((unsigned int)*pixels++ << 8); + quantum |= ((unsigned int)*pixels++); + *pixel = quantum; + return (pixels); +} + +static inline const unsigned char * +PushShortPixel(const EndianType endian, + const unsigned char *__restrict__ pixels, + unsigned short *__restrict__ pixel) { + unsigned int quantum; + + if (endian == LSBEndian) { + quantum = (unsigned int)*pixels++; + quantum |= (unsigned int)(*pixels++ << 8); + *pixel = (unsigned short)(quantum & 0xffff); + return (pixels); + } + quantum = (unsigned int)(*pixels++ << 8); + quantum |= (unsigned int)*pixels++; + *pixel = (unsigned short)(quantum & 0xffff); + return (pixels); +} +static inline const unsigned char * +PushFloatPixel(const EndianType endian, + const unsigned char *__restrict__ pixels, + MagickFloatType *__restrict__ pixel) { + union { + unsigned int unsigned_value; - return((Quantum) value); + MagickFloatType float_value; + } quantum; + if (endian == LSBEndian) { + quantum.unsigned_value = ((unsigned int)*pixels++); + quantum.unsigned_value |= ((unsigned int)*pixels++ << 8); + quantum.unsigned_value |= ((unsigned int)*pixels++ << 16); + quantum.unsigned_value |= ((unsigned int)*pixels++ << 24); + *pixel = quantum.float_value; + return (pixels); + } + quantum.unsigned_value = ((unsigned int)*pixels++ << 24); + quantum.unsigned_value |= ((unsigned int)*pixels++ << 16); + quantum.unsigned_value |= ((unsigned int)*pixels++ << 8); + quantum.unsigned_value |= ((unsigned int)*pixels++); + *pixel = quantum.float_value; + return (pixels); } -static inline unsigned int ScaleQuantumToLong(const Quantum quantum) -{ - +static inline Quantum ScaleAnyToQuantum(const QuantumAny quantum, + const QuantumAny range) { + if (quantum > range) + return (65535.0f); + return ((Quantum)((double)65535.0f * + (quantum * PerceptibleReciprocal((double)range)))); +} - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return(0U); - if ((65537.0*quantum) >= 4294967295.0) - return(4294967295U); - return((unsigned int) (65537.0*quantum+0.5)); +static inline QuantumAny ScaleQuantumToAny(const Quantum quantum, + const QuantumAny range) { + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return ((QuantumAny)0UL); + if (((double)range * quantum / 65535.0f) >= 18446744073709551615.0) + return ((QuantumAny)((MagickSizeType)(18446744073709551615ULL))); + return ((QuantumAny)((double)range * quantum / 65535.0f + 0.5)); } +static inline Quantum ScaleCharToQuantum(const unsigned char value) { -static inline MagickSizeType ScaleQuantumToLongLong(const Quantum quantum) -{ + return ((Quantum)(257.0 * value)); +} +static inline Quantum ScaleLongToQuantum(const unsigned int value) { + return ((Quantum)(value / 65537.0)); +} - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return(0UL); - if ((281479271743489.0*quantum) >= 18446744073709551615.0) - return(((MagickSizeType) (18446744073709551615ULL))); - return((MagickSizeType) (281479271743489.0*quantum+0.5)); +static inline Quantum ScaleLongLongToQuantum(const MagickSizeType value) { + return ((Quantum)(value / 281479271743489.0)); } -static inline unsigned int ScaleQuantumToMap(const Quantum quantum) -{ - if (quantum >= (Quantum) 65535UL) - return((unsigned int) 65535UL); +static inline Quantum ScaleMapToQuantum(const MagickRealType value) { + if (value <= 0.0) + return ((Quantum)0); + if (value >= 65535UL) + return (65535.0f); + + return ((Quantum)value); +} +static inline unsigned int ScaleQuantumToLong(const Quantum quantum) { + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return (0U); + if ((65537.0 * quantum) >= 4294967295.0) + return (4294967295U); + return ((unsigned int)(65537.0 * quantum + 0.5)); +} - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return(0U); - return((unsigned int) (quantum+0.5)); +static inline MagickSizeType ScaleQuantumToLongLong(const Quantum quantum) { + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return (0UL); + if ((281479271743489.0 * quantum) >= 18446744073709551615.0) + return (((MagickSizeType)(18446744073709551615ULL))); + return ((MagickSizeType)(281479271743489.0 * quantum + 0.5)); } -static inline unsigned short ScaleQuantumToShort(const Quantum quantum) -{ +static inline unsigned int ScaleQuantumToMap(const Quantum quantum) { + if (quantum >= (Quantum)65535UL) + return ((unsigned int)65535UL); + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return (0U); + return ((unsigned int)(quantum + 0.5)); +} +static inline unsigned short ScaleQuantumToShort(const Quantum quantum) { - if (( - __builtin_isnan ( - quantum - ) - != 0) || (quantum <= 0.0)) - return(0); + if ((__builtin_isnan(quantum) != 0) || (quantum <= 0.0)) + return (0); if (quantum >= 65535.0) - return(65535); - return((unsigned short) (quantum+0.5)); - + return (65535); + return ((unsigned short)(quantum + 0.5)); } -static inline Quantum ScaleShortToQuantum(const unsigned short value) -{ - return((Quantum) value); +static inline Quantum ScaleShortToQuantum(const unsigned short value) { + return ((Quantum)value); } -static inline unsigned short SinglePrecisionToHalf(const float value) -{ - typedef union _SinglePrecision - { - unsigned int - fixed_point; +static inline unsigned short SinglePrecisionToHalf(const float value) { + typedef union _SinglePrecision { + unsigned int fixed_point; - float - single_precision; + float single_precision; } SinglePrecision; - int - exponent; - - unsigned int - significand, - sign_bit; - - SinglePrecision - map; - - unsigned short - half; - map.single_precision=value; - sign_bit=(map.fixed_point >> 16) & 0x00008000; - exponent=(int) ((map.fixed_point >> 23) & 0x000000ff)-(127-15); - significand=map.fixed_point & 0x007fffff; - if (exponent <= 0) - { - int - shift; - - if (exponent < -10) - return((unsigned short) sign_bit); - significand=significand | 0x00800000; - shift=(int) (14-exponent); - significand=(unsigned int) ((significand+((1 << (shift-1))-1)+ - ((significand >> shift) & 0x01)) >> shift); - return((unsigned short) (sign_bit | significand)); + int exponent; + + unsigned int significand, sign_bit; + + SinglePrecision map; + + unsigned short half; + map.single_precision = value; + sign_bit = (map.fixed_point >> 16) & 0x00008000; + exponent = (int)((map.fixed_point >> 23) & 0x000000ff) - (127 - 15); + significand = map.fixed_point & 0x007fffff; + if (exponent <= 0) { + int shift; + + if (exponent < -10) + return ((unsigned short)sign_bit); + significand = significand | 0x00800000; + shift = (int)(14 - exponent); + significand = (unsigned int)((significand + ((1 << (shift - 1)) - 1) + + ((significand >> shift) & 0x01)) >> + shift); + return ((unsigned short)(sign_bit | significand)); + } else if (exponent == (0xff - (127 - 15))) { + if (significand == 0) + return ((unsigned short)(sign_bit | 0x7c00)); + else { + significand >>= 13; + half = (unsigned short)(sign_bit | significand | (significand == 0) | + 0x7c00); + return (half); } - else - if (exponent == (0xff-(127-15))) - { - if (significand == 0) - return((unsigned short) (sign_bit | 0x7c00)); - else - { - significand>>=13; - half=(unsigned short) (sign_bit | significand | - (significand == 0) | 0x7c00); - return(half); - } - } - significand=significand+((significand >> 13) & 0x01)+0x00000fff; - if ((significand & 0x00800000) != 0) - { - significand=0; - exponent++; - } - if (exponent > 30) - { - float - alpha; - - int - i; - - + } + significand = significand + ((significand >> 13) & 0x01) + 0x00000fff; + if ((significand & 0x00800000) != 0) { + significand = 0; + exponent++; + } + if (exponent > 30) { + float alpha; + int i; - alpha=1.0e10; - for (i=0; i < 10; i++) - alpha*=alpha; - return((unsigned short) (sign_bit | 0x7c00)); - } - half=(unsigned short) (sign_bit | (exponent << 10) | - (significand >> 13)); - return(half); -} -static inline ssize_t CastDoubleToLong(const double x) -{ - if ( - __builtin_isnan ( - x - ) - != 0) - return(0); - if (x > ((double) (0x7fffffffffffffffL - )+0.5)) - return((ssize_t) (0x7fffffffffffffffL - )); - if (x < ((double) (-(0x7fffffffffffffffL - )-1)-0.5)) - return((ssize_t) (-(0x7fffffffffffffffL - )-1)); + alpha = 1.0e10; + for (i = 0; i < 10; i++) + alpha *= alpha; + return ((unsigned short)(sign_bit | 0x7c00)); + } + half = (unsigned short)(sign_bit | (exponent << 10) | (significand >> 13)); + return (half); +} +static inline ssize_t CastDoubleToLong(const double x) { + if (__builtin_isnan(x) != 0) + return (0); + if (x > ((double)(0x7fffffffffffffffL) + 0.5)) + return ((ssize_t)(0x7fffffffffffffffL)); + if (x < ((double)(-(0x7fffffffffffffffL) - 1) - 0.5)) + return ((ssize_t)(-(0x7fffffffffffffffL) - 1)); if (x >= 0.0) - return((ssize_t) (x+0.5)); - return((ssize_t) (x-0.5)); + return ((ssize_t)(x + 0.5)); + return ((ssize_t)(x - 0.5)); } -static inline QuantumAny CastDoubleToQuantumAny(const double x) -{ - if ( - __builtin_isnan ( - x - ) - != 0) - return(0); - if (x > ((double) ((QuantumAny) ~0))) - return((QuantumAny) ~0); +static inline QuantumAny CastDoubleToQuantumAny(const double x) { + if (__builtin_isnan(x) != 0) + return (0); + if (x > ((double)((QuantumAny)~0))) + return ((QuantumAny)~0); if (x < 0.0) - return((QuantumAny) 0); - return((QuantumAny) (x+0.5)); + return ((QuantumAny)0); + return ((QuantumAny)(x + 0.5)); } -static inline double DegreesToRadians(const double degrees) -{ - return((double) (3.14159265358979323846264338327950288419716939937510*degrees/180.0)); +static inline double DegreesToRadians(const double degrees) { + return ((double)(3.14159265358979323846264338327950288419716939937510 * + degrees / 180.0)); } -static inline size_t GetImageChannels(const Image *image) -{ - ssize_t - i; +static inline size_t GetImageChannels(const Image *image) { + ssize_t i; - size_t - channels; + size_t channels; - channels=0; - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - PixelChannel channel = GetPixelChannelChannel(image,i); - PixelTrait traits = GetPixelChannelTraits(image,channel); + channels = 0; + for (i = 0; i < (ssize_t)GetPixelChannels(image); i++) { + PixelChannel channel = GetPixelChannelChannel(image, i); + PixelTrait traits = GetPixelChannelTraits(image, channel); if ((traits & UpdatePixelTrait) != 0) channels++; } - return(channels == 0 ? (size_t) 1 : channels); + return (channels == 0 ? (size_t)1 : channels); } -static inline double RadiansToDegrees(const double radians) -{ - return((double) (180.0*radians/3.14159265358979323846264338327950288419716939937510)); +static inline double RadiansToDegrees(const double radians) { + return ((double)(180.0 * radians / + 3.14159265358979323846264338327950288419716939937510)); } -static inline unsigned char ScaleColor5to8(const unsigned int color) -{ - return((unsigned char) (((color) << 3) | ((color) >> 2))); +static inline unsigned char ScaleColor5to8(const unsigned int color) { + return ((unsigned char)(((color) << 3) | ((color) >> 2))); } -static inline unsigned char ScaleColor6to8(const unsigned int color) -{ - return((unsigned char) (((color) << 2) | ((color) >> 4))); +static inline unsigned char ScaleColor6to8(const unsigned int color) { + return ((unsigned char)(((color) << 2) | ((color) >> 4))); } -static inline unsigned int ScaleColor8to5(const unsigned char color) -{ - return((unsigned int) (((color) & ~0x07) >> 3)); +static inline unsigned int ScaleColor8to5(const unsigned char color) { + return ((unsigned int)(((color) & ~0x07) >> 3)); } -static inline unsigned int ScaleColor8to6(const unsigned char color) -{ - return((unsigned int) (((color) & ~0x03) >> 2)); +static inline unsigned int ScaleColor8to6(const unsigned char color) { + return ((unsigned int)(((color) & ~0x03) >> 2)); } +extern __attribute__((visibility("hidden"))) MagickBooleanType +ColorComponentGenesis(void), + IsEquivalentAlpha(const Image *, const PixelInfo *, const PixelInfo *), + IsEquivalentIntensity(const Image *, const PixelInfo *, const PixelInfo *); - - - -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - ColorComponentGenesis(void), - IsEquivalentAlpha(const Image *,const PixelInfo *,const PixelInfo *), - IsEquivalentIntensity(const Image *,const PixelInfo *,const PixelInfo *); - -extern __attribute__ ((visibility ("hidden"))) void - ColorComponentTerminus(void); +extern __attribute__((visibility("hidden"))) void ColorComponentTerminus(void); static inline MagickBooleanType GetColorRange(const char *color, - PixelInfo *start,PixelInfo *stop,ExceptionInfo *exception) -{ - char - start_color[4096] = "white", - stop_color[4096] = "black"; - - MagickBooleanType - status; - - if (color == (const char *) - ((void *)0) - ) - return(MagickFalse); - if (*color != '\0') - { - char - *p; - - (void) CopyMagickString(start_color,color,4096); - for (p=start_color; (*p != '-') && (*p != '\0'); p++) - if (*p == '(') - { - for (p++; (*p != ')') && (*p != '\0'); p++); - if (*p == '\0') - break; - } - if (*p == '-') - (void) CopyMagickString(stop_color,p+1,4096); - *p='\0'; - } - status=QueryColorCompliance(start_color,AllCompliance,start,exception); + PixelInfo *start, PixelInfo *stop, + ExceptionInfo *exception) { + char start_color[4096] = "white", stop_color[4096] = "black"; + + MagickBooleanType status; + + if (color == (const char *)((void *)0)) + return (MagickFalse); + if (*color != '\0') { + char *p; + + (void)CopyMagickString(start_color, color, 4096); + for (p = start_color; (*p != '-') && (*p != '\0'); p++) + if (*p == '(') { + for (p++; (*p != ')') && (*p != '\0'); p++) + ; + if (*p == '\0') + break; + } + if (*p == '-') + (void)CopyMagickString(stop_color, p + 1, 4096); + *p = '\0'; + } + status = QueryColorCompliance(start_color, AllCompliance, start, exception); if (status == MagickFalse) - return(status); - return(QueryColorCompliance(stop_color,AllCompliance,stop,exception)); -} - -static inline double GetFuzzyColorDistance(const Image *p,const Image *q) -{ - double - fuzz; - - fuzz=(double) ((((((p->fuzz) > (q->fuzz)) ? (p->fuzz) : (q->fuzz))) > ((MagickRealType) 0.70710678118654752440084436210484903928483593768847)) ? ((((p->fuzz) > (q->fuzz)) ? (p->fuzz) : (q->fuzz))) : ((MagickRealType) 0.70710678118654752440084436210484903928483593768847)) - ; - return(fuzz*fuzz); -} -static inline void ConvertCMYKToRGB(PixelInfo *pixel) -{ - pixel->red=((65535.0f -(((double) 1.0/(double) 65535.0f)*pixel->red*(65535.0f - - pixel->black)+pixel->black))); - pixel->green=((65535.0f -(((double) 1.0/(double) 65535.0f)*pixel->green*(65535.0f - - pixel->black)+pixel->black))); - pixel->blue=((65535.0f -(((double) 1.0/(double) 65535.0f)*pixel->blue*(65535.0f - - pixel->black)+pixel->black))); -} - -static inline void ConvertRGBToCMYK(PixelInfo *pixel) -{ - MagickRealType - black, - blue, - cyan, - green, - magenta, - red, - yellow; - - if (pixel->colorspace != sRGBColorspace) - { - red=((double) 1.0/(double) 65535.0f)*pixel->red; - green=((double) 1.0/(double) 65535.0f)*pixel->green; - blue=((double) 1.0/(double) 65535.0f)*pixel->blue; - } - else - { - red=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(pixel->red); - green=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(pixel->green); - blue=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(pixel->blue); - } - if ((fabs((double) red) < 1.0e-12) && - (fabs((double) green) < 1.0e-12) && - (fabs((double) blue) < 1.0e-12)) - { - pixel->black=(MagickRealType) 65535.0f; - return; - } - cyan=(MagickRealType) (1.0-red); - magenta=(MagickRealType) (1.0-green); - yellow=(MagickRealType) (1.0-blue); - black=cyan; + return (status); + return (QueryColorCompliance(stop_color, AllCompliance, stop, exception)); +} + +static inline double GetFuzzyColorDistance(const Image *p, const Image *q) { + double fuzz; + + fuzz = + (double)((((((p->fuzz) > (q->fuzz)) ? (p->fuzz) : (q->fuzz))) > + ((MagickRealType)0.70710678118654752440084436210484903928483593768847)) + ? ((((p->fuzz) > (q->fuzz)) ? (p->fuzz) : (q->fuzz))) + : ((MagickRealType)0.70710678118654752440084436210484903928483593768847)); + return (fuzz * fuzz); +} +static inline void ConvertCMYKToRGB(PixelInfo *pixel) { + pixel->red = ((65535.0f - (((double)1.0 / (double)65535.0f) * pixel->red * + (65535.0f - pixel->black) + + pixel->black))); + pixel->green = ((65535.0f - (((double)1.0 / (double)65535.0f) * pixel->green * + (65535.0f - pixel->black) + + pixel->black))); + pixel->blue = ((65535.0f - (((double)1.0 / (double)65535.0f) * pixel->blue * + (65535.0f - pixel->black) + + pixel->black))); +} + +static inline void ConvertRGBToCMYK(PixelInfo *pixel) { + MagickRealType black, blue, cyan, green, magenta, red, yellow; + + if (pixel->colorspace != sRGBColorspace) { + red = ((double)1.0 / (double)65535.0f) * pixel->red; + green = ((double)1.0 / (double)65535.0f) * pixel->green; + blue = ((double)1.0 / (double)65535.0f) * pixel->blue; + } else { + red = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(pixel->red); + green = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(pixel->green); + blue = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(pixel->blue); + } + if ((fabs((double)red) < 1.0e-12) && (fabs((double)green) < 1.0e-12) && + (fabs((double)blue) < 1.0e-12)) { + pixel->black = (MagickRealType)65535.0f; + return; + } + cyan = (MagickRealType)(1.0 - red); + magenta = (MagickRealType)(1.0 - green); + yellow = (MagickRealType)(1.0 - blue); + black = cyan; if (magenta < black) - black=magenta; + black = magenta; if (yellow < black) - black=yellow; - cyan=(MagickRealType) (PerceptibleReciprocal(1.0-black)*(cyan-black)); - magenta=(MagickRealType) (PerceptibleReciprocal(1.0-black)*(magenta-black)); - yellow=(MagickRealType) (PerceptibleReciprocal(1.0-black)*(yellow-black)); - pixel->colorspace=CMYKColorspace; - pixel->red=65535.0f*cyan; - pixel->green=65535.0f*magenta; - pixel->blue=65535.0f*yellow; - pixel->black=65535.0f*black; -} - -static inline MagickBooleanType IsCMYKColorspace( - const ColorspaceType colorspace) -{ + black = yellow; + cyan = (MagickRealType)(PerceptibleReciprocal(1.0 - black) * (cyan - black)); + magenta = + (MagickRealType)(PerceptibleReciprocal(1.0 - black) * (magenta - black)); + yellow = + (MagickRealType)(PerceptibleReciprocal(1.0 - black) * (yellow - black)); + pixel->colorspace = CMYKColorspace; + pixel->red = 65535.0f * cyan; + pixel->green = 65535.0f * magenta; + pixel->blue = 65535.0f * yellow; + pixel->black = 65535.0f * black; +} + +static inline MagickBooleanType +IsCMYKColorspace(const ColorspaceType colorspace) { if (colorspace == CMYKColorspace) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsGrayColorspace( - const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IsGrayColorspace(const ColorspaceType colorspace) { if ((colorspace == LinearGRAYColorspace) || (colorspace == GRAYColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsGrayImageType(const ImageType type) -{ +static inline MagickBooleanType IsGrayImageType(const ImageType type) { if ((type == GrayscaleType) || (type == GrayscaleAlphaType) || (type == BilevelType)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsHueCompatibleColorspace( - const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IsHueCompatibleColorspace(const ColorspaceType colorspace) { if ((colorspace == HCLColorspace) || (colorspace == HCLpColorspace) || (colorspace == HSBColorspace) || (colorspace == HSIColorspace) || (colorspace == HSLColorspace) || (colorspace == HSVColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsRGBColorspace(const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IsRGBColorspace(const ColorspaceType colorspace) { if ((colorspace == RGBColorspace) || (colorspace == scRGBColorspace) || (colorspace == LinearGRAYColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IssRGBColorspace( - const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IssRGBColorspace(const ColorspaceType colorspace) { if ((colorspace == sRGBColorspace) || (colorspace == TransparentColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IssRGBCompatibleColorspace( - const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IssRGBCompatibleColorspace(const ColorspaceType colorspace) { if ((colorspace == sRGBColorspace) || (colorspace == RGBColorspace) || (colorspace == Adobe98Colorspace) || (colorspace == ProPhotoColorspace) || (colorspace == DisplayP3Colorspace) || (colorspace == scRGBColorspace) || (colorspace == TransparentColorspace) || (colorspace == GRAYColorspace) || (colorspace == LinearGRAYColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -static inline MagickBooleanType IsYCbCrCompatibleColorspace( - const ColorspaceType colorspace) -{ +static inline MagickBooleanType +IsYCbCrCompatibleColorspace(const ColorspaceType colorspace) { if ((colorspace == YCbCrColorspace) || (colorspace == Rec709YCbCrColorspace) || (colorspace == Rec601YCbCrColorspace)) - return(MagickTrue); - return(MagickFalse); + return (MagickTrue); + return (MagickFalse); } -typedef struct _FrameInfo -{ - size_t - width, - height; - - ssize_t - x, - y, - inner_bevel, - outer_bevel; +typedef struct _FrameInfo { + size_t width, height; + + ssize_t x, y, inner_bevel, outer_bevel; } FrameInfo; -extern __attribute__ ((visibility ("default"))) Image - *BorderImage(const Image *,const RectangleInfo *,const CompositeOperator, - ExceptionInfo *), - *FrameImage(const Image *,const FrameInfo *,const CompositeOperator, - ExceptionInfo *); +extern __attribute__((visibility("default"))) Image * +BorderImage(const Image *, const RectangleInfo *, const CompositeOperator, + ExceptionInfo *), + *FrameImage(const Image *, const FrameInfo *, const CompositeOperator, + ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - RaiseImage(Image *,const RectangleInfo *,const MagickBooleanType, - ExceptionInfo *); -typedef enum -{ +extern __attribute__((visibility("default"))) MagickBooleanType +RaiseImage(Image *, const RectangleInfo *, const MagickBooleanType, + ExceptionInfo *); +typedef enum { UndefinedDistortion, AffineDistortion, AffineProjectionDistortion, @@ -15703,62 +12292,62 @@ typedef enum RigidAffineDistortion } DistortMethod; -typedef enum -{ +typedef enum { UndefinedColorInterpolate = UndefinedDistortion, BarycentricColorInterpolate = AffineDistortion, BilinearColorInterpolate = BilinearReverseDistortion, PolynomialColorInterpolate = PolynomialDistortion, ShepardsColorInterpolate = ShepardsDistortion, - - VoronoiColorInterpolate = SentinelDistortion, InverseColorInterpolate, ManhattanColorInterpolate } SparseColorMethod; -extern __attribute__ ((visibility ("default"))) Image - *AffineTransformImage(const Image *,const AffineMatrix *,ExceptionInfo *), - *DistortImage(const Image *,const DistortMethod,const size_t, - const double *,MagickBooleanType,ExceptionInfo *exception), - *DistortResizeImage(const Image *,const size_t,const size_t,ExceptionInfo *), - *RotateImage(const Image *,const double,ExceptionInfo *), - *SparseColorImage(const Image *,const SparseColorMethod,const size_t, - const double *,ExceptionInfo *); - - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AutoGammaImage(Image *,ExceptionInfo *), - AutoLevelImage(Image *,ExceptionInfo *), - BrightnessContrastImage(Image *,const double,const double,ExceptionInfo *), - CLAHEImage(Image *,const size_t,const size_t,const size_t,const double, - ExceptionInfo *), - ClutImage(Image *,const Image *,const PixelInterpolateMethod,ExceptionInfo *), - ColorDecisionListImage(Image *,const char *,ExceptionInfo *), - ContrastImage(Image *,const MagickBooleanType,ExceptionInfo *), - ContrastStretchImage(Image *,const double,const double,ExceptionInfo *), - EqualizeImage(Image *image,ExceptionInfo *), - GammaImage(Image *,const double,ExceptionInfo *), - GrayscaleImage(Image *,const PixelIntensityMethod,ExceptionInfo *), - HaldClutImage(Image *,const Image *,ExceptionInfo *), - LevelImage(Image *,const double,const double,const double,ExceptionInfo *), - LevelizeImage(Image *,const double,const double,const double,ExceptionInfo *), - LevelImageColors(Image *,const PixelInfo *,const PixelInfo *, - const MagickBooleanType,ExceptionInfo *), - LinearStretchImage(Image *,const double,const double,ExceptionInfo *), - ModulateImage(Image *,const char *,ExceptionInfo *), - NegateImage(Image *,const MagickBooleanType,ExceptionInfo *), - NormalizeImage(Image *,ExceptionInfo *), - SigmoidalContrastImage(Image *,const MagickBooleanType,const double, - const double,ExceptionInfo *), - WhiteBalanceImage(Image *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) Image - *EnhanceImage(const Image *,ExceptionInfo *); - -typedef enum -{ +extern __attribute__((visibility("default"))) Image * +AffineTransformImage(const Image *, const AffineMatrix *, ExceptionInfo *), + *DistortImage(const Image *, const DistortMethod, const size_t, + const double *, MagickBooleanType, ExceptionInfo *exception), + *DistortResizeImage(const Image *, const size_t, const size_t, + ExceptionInfo *), + *RotateImage(const Image *, const double, ExceptionInfo *), + *SparseColorImage(const Image *, const SparseColorMethod, const size_t, + const double *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +AutoGammaImage(Image *, ExceptionInfo *), + AutoLevelImage(Image *, ExceptionInfo *), + BrightnessContrastImage(Image *, const double, const double, + ExceptionInfo *), + CLAHEImage(Image *, const size_t, const size_t, const size_t, const double, + ExceptionInfo *), + ClutImage(Image *, const Image *, const PixelInterpolateMethod, + ExceptionInfo *), + ColorDecisionListImage(Image *, const char *, ExceptionInfo *), + ContrastImage(Image *, const MagickBooleanType, ExceptionInfo *), + ContrastStretchImage(Image *, const double, const double, ExceptionInfo *), + EqualizeImage(Image *image, ExceptionInfo *), + GammaImage(Image *, const double, ExceptionInfo *), + GrayscaleImage(Image *, const PixelIntensityMethod, ExceptionInfo *), + HaldClutImage(Image *, const Image *, ExceptionInfo *), + LevelImage(Image *, const double, const double, const double, + ExceptionInfo *), + LevelizeImage(Image *, const double, const double, const double, + ExceptionInfo *), + LevelImageColors(Image *, const PixelInfo *, const PixelInfo *, + const MagickBooleanType, ExceptionInfo *), + LinearStretchImage(Image *, const double, const double, ExceptionInfo *), + ModulateImage(Image *, const char *, ExceptionInfo *), + NegateImage(Image *, const MagickBooleanType, ExceptionInfo *), + NormalizeImage(Image *, ExceptionInfo *), + SigmoidalContrastImage(Image *, const MagickBooleanType, const double, + const double, ExceptionInfo *), + WhiteBalanceImage(Image *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) Image * +EnhanceImage(const Image *, ExceptionInfo *); + +typedef enum { UndefinedEvents = 0x000000, NoEvents = 0x00000, AccelerateEvent = 0x00001, @@ -15785,49 +12374,45 @@ typedef enum AllEvents = 0x7fffffff } LogEventType; -typedef struct _LogInfo - LogInfo; +typedef struct _LogInfo LogInfo; -typedef void - (*MagickLogMethod)(const LogEventType,const char *); +typedef void (*MagickLogMethod)(const LogEventType, const char *); -extern __attribute__ ((visibility ("default"))) char - **GetLogList(const char *,size_t *,ExceptionInfo *); +extern __attribute__((visibility("default"))) char ** +GetLogList(const char *, size_t *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) const char - *GetLogName(void) __attribute__((__pure__)), - *SetLogName(const char *); +extern __attribute__((visibility("default"))) const char *GetLogName(void) + __attribute__((__pure__)), + *SetLogName(const char *); -extern __attribute__ ((visibility ("default"))) LogEventType - GetLogEventMask(void) __attribute__((__pure__)); +extern __attribute__((visibility("default"))) LogEventType GetLogEventMask(void) + __attribute__((__pure__)); -extern __attribute__ ((visibility ("default"))) const LogInfo - **GetLogInfoList(const char *,size_t *,ExceptionInfo *); +extern __attribute__((visibility("default"))) const LogInfo ** +GetLogInfoList(const char *, size_t *, ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) LogEventType - SetLogEventMask(const char *); +extern __attribute__((visibility("default"))) LogEventType +SetLogEventMask(const char *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - IsEventLogging(void) __attribute__((__pure__)), - ListLogInfo(FILE *,ExceptionInfo *), - LogMagickEvent(const LogEventType,const char *,const char *,const size_t, - const char *,...) __attribute__((__format__ (__printf__,5,6))), - LogMagickEventList(const LogEventType,const char *,const char *,const size_t, - const char *,va_list) __attribute__((__format__ (__printf__,5,0))); +extern __attribute__((visibility("default"))) MagickBooleanType +IsEventLogging(void) __attribute__((__pure__)), + ListLogInfo(FILE *, ExceptionInfo *), + LogMagickEvent(const LogEventType, const char *, const char *, const size_t, + const char *, ...) + __attribute__((__format__(__printf__, 5, 6))), + LogMagickEventList(const LogEventType, const char *, const char *, + const size_t, const char *, va_list) + __attribute__((__format__(__printf__, 5, 0))); -extern __attribute__ ((visibility ("default"))) void - CloseMagickLog(void), - SetLogFormat(const char *), - SetLogMethod(MagickLogMethod); -typedef enum -{ +extern __attribute__((visibility("default"))) void CloseMagickLog(void), + SetLogFormat(const char *), SetLogMethod(MagickLogMethod); +typedef enum { UndefinedFormatType, ImplicitFormatType, ExplicitFormatType } MagickFormatType; -typedef enum -{ +typedef enum { CoderNoFlag = 0x0000, CoderAdjoinFlag = 0x0001, CoderBlobSupportFlag = 0x0002, @@ -15843,819 +12428,725 @@ typedef enum } MagickInfoFlag; -typedef Image - *DecodeImageHandler(const ImageInfo *,ExceptionInfo *); +typedef Image *DecodeImageHandler(const ImageInfo *, ExceptionInfo *); -typedef MagickBooleanType - EncodeImageHandler(const ImageInfo *,Image *,ExceptionInfo *); +typedef MagickBooleanType EncodeImageHandler(const ImageInfo *, Image *, + ExceptionInfo *); -typedef MagickBooleanType - IsImageFormatHandler(const unsigned char *,const size_t); +typedef MagickBooleanType IsImageFormatHandler(const unsigned char *, + const size_t); -typedef struct _MagickInfo -{ - char - *name, - *description, - *version, - *mime_type, - *note, - *module; +typedef struct _MagickInfo { + char *name, *description, *version, *mime_type, *note, *module; - DecodeImageHandler - *decoder; + DecodeImageHandler *decoder; - EncodeImageHandler - *encoder; + EncodeImageHandler *encoder; - ImageInfo - *image_info; + ImageInfo *image_info; - IsImageFormatHandler - *magick; + IsImageFormatHandler *magick; - MagickFormatType - format_type; + MagickFormatType format_type; - MagickStatusType - flags; + MagickStatusType flags; - SemaphoreInfo - *semaphore; + SemaphoreInfo *semaphore; - size_t - signature; + size_t signature; - void - *client_data; + void *client_data; } MagickInfo; -extern __attribute__ ((visibility ("default"))) char - **GetMagickList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) const char - *GetMagickDescription(const MagickInfo *), - *GetMagickMimeType(const MagickInfo *), - *GetMagickModuleName(const MagickInfo *), - *GetMagickName(const MagickInfo *); - -extern __attribute__ ((visibility ("default"))) DecodeImageHandler - *GetImageDecoder(const MagickInfo *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) EncodeImageHandler - *GetImageEncoder(const MagickInfo *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) int - GetMagickPrecision(void), - SetMagickPrecision(const int); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - GetImageMagick(const unsigned char *,const size_t,char *), - GetMagickAdjoin(const MagickInfo *) __attribute__((__pure__)), - GetMagickBlobSupport(const MagickInfo *) __attribute__((__pure__)), - GetMagickDecoderSeekableStream(const MagickInfo *) - __attribute__((__pure__)), - GetMagickDecoderThreadSupport(const MagickInfo *) - __attribute__((__pure__)), - GetMagickEncoderSeekableStream(const MagickInfo *) - __attribute__((__pure__)), - GetMagickEncoderThreadSupport(const MagickInfo *) - __attribute__((__pure__)), - GetMagickEndianSupport(const MagickInfo *) __attribute__((__pure__)), - GetMagickRawSupport(const MagickInfo *) __attribute__((__pure__)), - GetMagickStealth(const MagickInfo *) __attribute__((__pure__)), - GetMagickUseExtension(const MagickInfo *) __attribute__((__pure__)), - IsMagickCoreInstantiated(void) __attribute__((__pure__)), - RegisterMagickInfo(MagickInfo *), - UnregisterMagickInfo(const char *); - -extern const __attribute__ ((visibility ("default"))) MagickInfo - *GetMagickInfo(const char *,ExceptionInfo *), - **GetMagickInfoList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickInfo - *AcquireMagickInfo(const char *, const char *, const char *); - -extern __attribute__ ((visibility ("default"))) void - MagickCoreGenesis(const char *,const MagickBooleanType), - MagickCoreTerminus(void); -extern __attribute__ ((visibility ("hidden"))) void - ExceptionComponentTerminus(void), - InitializeExceptionInfo(ExceptionInfo *); - -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - ExceptionComponentGenesis(void); - -typedef struct _FxInfo - FxInfo; - -extern __attribute__ ((visibility ("hidden"))) FxInfo - *AcquireFxInfo(const Image *,const char *,ExceptionInfo *), - *DestroyFxInfo(FxInfo *); - -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - FxEvaluateChannelExpression(FxInfo *,const PixelChannel,const ssize_t, - const ssize_t,double *,ExceptionInfo *); - -static const PrimaryInfo - illuminant_tristimulus[] = - { - { 1.09850, 1.00000, 0.35585 }, - { 0.99072, 1.00000, 0.85223 }, - { 0.98074, 1.00000, 1.18232 }, - { 0.96422, 1.00000, 0.82521 }, - { 0.95682, 1.00000, 0.92149 }, - { 0.95047, 1.00000, 1.08883 }, - { 0.94972, 1.00000, 1.22638 }, - { 1.00000, 1.00000, 1.00000 }, - { 0.99186, 1.00000, 0.67393 }, - { 0.95041, 1.00000, 1.08747 }, - { 1.00962, 1.00000, 0.64350 } - }; - -extern __attribute__ ((visibility ("hidden"))) double - GenerateDifferentialNoise(RandomInfo *,const Quantum,const NoiseType, - const double); - -extern __attribute__ ((visibility ("hidden"))) size_t - GetOptimalKernelWidth(const double,const double), - GetOptimalKernelWidth1D(const double,const double), - GetOptimalKernelWidth2D(const double,const double); - -extern __attribute__ ((visibility ("hidden"))) void - ConvertHCLToRGB(const double,const double,const double,double *,double *, - double *), - ConvertHCLpToRGB(const double,const double,const double,double *,double *, - double *), - ConvertHSBToRGB(const double,const double,const double,double *,double *, - double *), - ConvertHSIToRGB(const double,const double,const double,double *,double *, - double *), - ConvertHSVToRGB(const double,const double,const double,double *,double *, - double *), - ConvertHWBToRGB(const double,const double,const double,double *,double *, - double *), - ConvertLCHabToRGB(const double,const double,const double,const IlluminantType, - double *,double *,double *), - ConvertLCHuvToRGB(const double,const double,const double,const IlluminantType, - double *,double *,double *), - ConvertRGBToHCL(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHCLp(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHSB(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHSI(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHSV(const double,const double,const double,double *,double *, - double *), - ConvertRGBToHWB(const double,const double,const double,double *,double *, - double *), - ConvertRGBToLab(const double,const double,const double,const IlluminantType, - double *,double *,double *), - ConvertRGBToLCHab(const double,const double,const double,const IlluminantType, - double *,double *,double *), - ConvertRGBToLCHuv(const double,const double,const double,const IlluminantType, - double *,double *,double *); - -static inline void ConvertAdobe98ToXYZ(const double red,const double green, - const double blue,double *X,double *Y,double *Z) -{ - double - b, - g, - r; - - - - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 106, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 107, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 108, __extension__ __PRETTY_FUNCTION__); })) - ; - r=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(red); - g=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(green); - b=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(blue); - *X=0.57666904291013050*r+0.18555823790654630*g+0.18822864623499470*b; - *Y=0.29734497525053605*r+0.62736356625546610*g+0.07529145849399788*b; - *Z=0.02703136138641234*r+0.07068885253582723*g+0.99133753683763880*b; -} - -static inline void ConvertDisplayP3ToXYZ(const double red,const double green, - const double blue,double *X,double *Y,double *Z) -{ - double - b, - g, - r; - - - - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 128, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 129, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 130, __extension__ __PRETTY_FUNCTION__); })) - ; - r=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(red); - g=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(green); - b=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(blue); - *X=0.4865709486482162*r+0.26566769316909306*g+0.1982172852343625*b; - *Y=0.2289745640697488*r+0.69173852183650640*g+0.0792869140937450*b; - *Z=0.0000000000000000*r+0.04511338185890264*g+1.0439443689009760*b; -} - -static inline void ConvertLabToXYZ(const double L,const double a,const double b, - const IlluminantType illuminant,double *X,double *Y,double *Z) -{ - double - x, - y, - z; - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 147, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 148, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 149, __extension__ __PRETTY_FUNCTION__); })) - ; - y=(L+16.0)/116.0; - x=y+a/500.0; - z=y-b/200.0; - if ((x*x*x) > (216.0/24389.0)) - x=(x*x*x); +extern __attribute__((visibility("default"))) char ** +GetMagickList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) const char * +GetMagickDescription(const MagickInfo *), + *GetMagickMimeType(const MagickInfo *), + *GetMagickModuleName(const MagickInfo *), + *GetMagickName(const MagickInfo *); + +extern __attribute__((visibility("default"))) DecodeImageHandler * +GetImageDecoder(const MagickInfo *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) EncodeImageHandler * +GetImageEncoder(const MagickInfo *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) int GetMagickPrecision(void), + SetMagickPrecision(const int); + +extern __attribute__((visibility("default"))) MagickBooleanType +GetImageMagick(const unsigned char *, const size_t, char *), + GetMagickAdjoin(const MagickInfo *) __attribute__((__pure__)), + GetMagickBlobSupport(const MagickInfo *) __attribute__((__pure__)), + GetMagickDecoderSeekableStream(const MagickInfo *) + __attribute__((__pure__)), + GetMagickDecoderThreadSupport(const MagickInfo *) __attribute__((__pure__)), + GetMagickEncoderSeekableStream(const MagickInfo *) + __attribute__((__pure__)), + GetMagickEncoderThreadSupport(const MagickInfo *) __attribute__((__pure__)), + GetMagickEndianSupport(const MagickInfo *) __attribute__((__pure__)), + GetMagickRawSupport(const MagickInfo *) __attribute__((__pure__)), + GetMagickStealth(const MagickInfo *) __attribute__((__pure__)), + GetMagickUseExtension(const MagickInfo *) __attribute__((__pure__)), + IsMagickCoreInstantiated(void) __attribute__((__pure__)), + RegisterMagickInfo(MagickInfo *), UnregisterMagickInfo(const char *); + +extern const __attribute__((visibility("default"))) MagickInfo * +GetMagickInfo(const char *, ExceptionInfo *), + **GetMagickInfoList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickInfo * +AcquireMagickInfo(const char *, const char *, const char *); + +extern __attribute__((visibility("default"))) void +MagickCoreGenesis(const char *, const MagickBooleanType), + MagickCoreTerminus(void); +extern __attribute__((visibility("hidden"))) void +ExceptionComponentTerminus(void), + InitializeExceptionInfo(ExceptionInfo *); + +extern __attribute__((visibility("hidden"))) MagickBooleanType +ExceptionComponentGenesis(void); + +typedef struct _FxInfo FxInfo; + +extern __attribute__((visibility("hidden"))) FxInfo * +AcquireFxInfo(const Image *, const char *, ExceptionInfo *), + *DestroyFxInfo(FxInfo *); + +extern __attribute__((visibility("hidden"))) MagickBooleanType +FxEvaluateChannelExpression(FxInfo *, const PixelChannel, const ssize_t, + const ssize_t, double *, ExceptionInfo *); + +static const PrimaryInfo illuminant_tristimulus[] = { + {1.09850, 1.00000, 0.35585}, {0.99072, 1.00000, 0.85223}, + {0.98074, 1.00000, 1.18232}, {0.96422, 1.00000, 0.82521}, + {0.95682, 1.00000, 0.92149}, {0.95047, 1.00000, 1.08883}, + {0.94972, 1.00000, 1.22638}, {1.00000, 1.00000, 1.00000}, + {0.99186, 1.00000, 0.67393}, {0.95041, 1.00000, 1.08747}, + {1.00962, 1.00000, 0.64350}}; + +extern __attribute__((visibility("hidden"))) double +GenerateDifferentialNoise(RandomInfo *, const Quantum, const NoiseType, + const double); + +extern __attribute__((visibility("hidden"))) size_t +GetOptimalKernelWidth(const double, const double), + GetOptimalKernelWidth1D(const double, const double), + GetOptimalKernelWidth2D(const double, const double); + +extern __attribute__((visibility("hidden"))) void +ConvertHCLToRGB(const double, const double, const double, double *, double *, + double *), + ConvertHCLpToRGB(const double, const double, const double, double *, + double *, double *), + ConvertHSBToRGB(const double, const double, const double, double *, + double *, double *), + ConvertHSIToRGB(const double, const double, const double, double *, + double *, double *), + ConvertHSVToRGB(const double, const double, const double, double *, + double *, double *), + ConvertHWBToRGB(const double, const double, const double, double *, + double *, double *), + ConvertLCHabToRGB(const double, const double, const double, + const IlluminantType, double *, double *, double *), + ConvertLCHuvToRGB(const double, const double, const double, + const IlluminantType, double *, double *, double *), + ConvertRGBToHCL(const double, const double, const double, double *, + double *, double *), + ConvertRGBToHCLp(const double, const double, const double, double *, + double *, double *), + ConvertRGBToHSB(const double, const double, const double, double *, + double *, double *), + ConvertRGBToHSI(const double, const double, const double, double *, + double *, double *), + ConvertRGBToHSV(const double, const double, const double, double *, + double *, double *), + ConvertRGBToHWB(const double, const double, const double, double *, + double *, double *), + ConvertRGBToLab(const double, const double, const double, + const IlluminantType, double *, double *, double *), + ConvertRGBToLCHab(const double, const double, const double, + const IlluminantType, double *, double *, double *), + ConvertRGBToLCHuv(const double, const double, const double, + const IlluminantType, double *, double *, double *); + +static inline void ConvertAdobe98ToXYZ(const double red, const double green, + const double blue, double *X, double *Y, + double *Z) { + double b, g, r; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 106, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 107, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 108, + __extension__ __PRETTY_FUNCTION__); + })); + r = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(red); + g = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(green); + b = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(blue); + *X = 0.57666904291013050 * r + 0.18555823790654630 * g + + 0.18822864623499470 * b; + *Y = 0.29734497525053605 * r + 0.62736356625546610 * g + + 0.07529145849399788 * b; + *Z = 0.02703136138641234 * r + 0.07068885253582723 * g + + 0.99133753683763880 * b; +} + +static inline void ConvertDisplayP3ToXYZ(const double red, const double green, + const double blue, double *X, + double *Y, double *Z) { + double b, g, r; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 128, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 129, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 130, + __extension__ __PRETTY_FUNCTION__); + })); + r = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(red); + g = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(green); + b = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(blue); + *X = + 0.4865709486482162 * r + 0.26566769316909306 * g + 0.1982172852343625 * b; + *Y = + 0.2289745640697488 * r + 0.69173852183650640 * g + 0.0792869140937450 * b; + *Z = + 0.0000000000000000 * r + 0.04511338185890264 * g + 1.0439443689009760 * b; +} + +static inline void ConvertLabToXYZ(const double L, const double a, + const double b, + const IlluminantType illuminant, double *X, + double *Y, double *Z) { + double x, y, z; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 147, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 148, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 149, + __extension__ __PRETTY_FUNCTION__); + })); + y = (L + 16.0) / 116.0; + x = y + a / 500.0; + z = y - b / 200.0; + if ((x * x * x) > (216.0 / 24389.0)) + x = (x * x * x); else - x=(116.0*x-16.0)/(24389.0/27.0); - if (L > ((24389.0/27.0)*(216.0/24389.0))) - y=(y*y*y); + x = (116.0 * x - 16.0) / (24389.0 / 27.0); + if (L > ((24389.0 / 27.0) * (216.0 / 24389.0))) + y = (y * y * y); else - y=L/(24389.0/27.0); - if ((z*z*z) > (216.0/24389.0)) - z=(z*z*z); + y = L / (24389.0 / 27.0); + if ((z * z * z) > (216.0 / 24389.0)) + z = (z * z * z); else - z=(116.0*z-16.0)/(24389.0/27.0); - *X=illuminant_tristimulus[illuminant].x*x; - *Y=illuminant_tristimulus[illuminant].y*y; - *Z=illuminant_tristimulus[illuminant].z*z; -} - -static inline void ConvertLuvToXYZ(const double L,const double u,const double v, - const IlluminantType illuminant,double *X,double *Y,double *Z) -{ - double - gamma; - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 176, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 177, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 178, __extension__ __PRETTY_FUNCTION__); })) - ; - if (L > ((24389.0/27.0)*(216.0/24389.0))) - *Y=(double) pow((L+16.0)/116.0,3.0); + z = (116.0 * z - 16.0) / (24389.0 / 27.0); + *X = illuminant_tristimulus[illuminant].x * x; + *Y = illuminant_tristimulus[illuminant].y * y; + *Z = illuminant_tristimulus[illuminant].z * z; +} + +static inline void ConvertLuvToXYZ(const double L, const double u, + const double v, + const IlluminantType illuminant, double *X, + double *Y, double *Z) { + double gamma; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 176, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 177, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 178, + __extension__ __PRETTY_FUNCTION__); + })); + if (L > ((24389.0 / 27.0) * (216.0 / 24389.0))) + *Y = (double)pow((L + 16.0) / 116.0, 3.0); else - *Y=L/(24389.0/27.0); - gamma=PerceptibleReciprocal((((52.0*L*PerceptibleReciprocal(u+13.0*L* - (4.0*illuminant_tristimulus[illuminant].x/ - (illuminant_tristimulus[illuminant].x+15.0* - illuminant_tristimulus[illuminant].y+3.0* - illuminant_tristimulus[illuminant].z))))-1.0)/3.0)-(-1.0/3.0)); - *X=gamma*((*Y*((39.0*L*PerceptibleReciprocal(v+13.0*L*(9.0* - illuminant_tristimulus[illuminant].y/ - (illuminant_tristimulus[illuminant].x+15.0* - illuminant_tristimulus[illuminant].y+3.0* - illuminant_tristimulus[illuminant].z))))-5.0))+5.0*(*Y)); - *Z=(*X*(((52.0*L*PerceptibleReciprocal(u+13.0*L*(4.0* - illuminant_tristimulus[illuminant].x/ - (illuminant_tristimulus[illuminant].x+15.0* - illuminant_tristimulus[illuminant].y+3.0* - illuminant_tristimulus[illuminant].z))))-1.0)/3.0))-5.0*(*Y); -} - -static inline void ConvertProPhotoToXYZ(const double red,const double green, - const double blue,double *X,double *Y,double *Z) -{ - double - b, - g, - r; - - - - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 211, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 212, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 213, __extension__ __PRETTY_FUNCTION__); })) - ; - r=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(red); - g=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(green); - b=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(blue); - *X=0.7977604896723027*r+0.13518583717574031*g+0.03134934958152480000*b; - *Y=0.2880711282292934*r+0.71184321781010140*g+0.00008565396060525902*b; - *Z=0.0000000000000000*r+0.00000000000000000*g+0.82510460251046010000*b; -} - -static inline void ConvertRGBToXYZ(const double red,const double green, - const double blue,double *X,double *Y,double *Z) -{ - double - b, - g, - r; - - - - - - ((void) sizeof (( - X != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - X != (double *) - ((void *)0)) ; else __assert_fail ( - "X != (double *) NULL" - , "./MagickCore/gem-private.h", 233, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Y != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Y != (double *) - ((void *)0)) ; else __assert_fail ( - "Y != (double *) NULL" - , "./MagickCore/gem-private.h", 234, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - Z != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - Z != (double *) - ((void *)0)) ; else __assert_fail ( - "Z != (double *) NULL" - , "./MagickCore/gem-private.h", 235, __extension__ __PRETTY_FUNCTION__); })) - ; - r=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(red); - g=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(green); - b=((double) 1.0/(double) 65535.0f)*DecodePixelGamma(blue); - *X=0.4124564*r+0.3575761*g+0.1804375*b; - *Y=0.2126729*r+0.7151522*g+0.0721750*b; - *Z=0.0193339*r+0.1191920*g+0.9503041*b; -} - -static inline void ConvertXYZToAdobe98(const double X,const double Y, - const double Z,double *red,double *green,double *blue) -{ - double - b, - g, - r; - - - ((void) sizeof (( - red != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - red != (double *) - ((void *)0)) ; else __assert_fail ( - "red != (double *) NULL" - , "./MagickCore/gem-private.h", 252, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - green != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - green != (double *) - ((void *)0)) ; else __assert_fail ( - "green != (double *) NULL" - , "./MagickCore/gem-private.h", 253, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - blue != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - blue != (double *) - ((void *)0)) ; else __assert_fail ( - "blue != (double *) NULL" - , "./MagickCore/gem-private.h", 254, __extension__ __PRETTY_FUNCTION__); })) - ; - r=2.041587903810746500*X-0.56500697427885960*Y-0.34473135077832956*Z; - g=(-0.969243636280879500)*X+1.87596750150772020*Y+0.04155505740717557*Z; - b=0.013444280632031142*X-0.11836239223101838*Y+1.01517499439120540*Z; - *red=EncodePixelGamma(65535.0f*r); - *green=EncodePixelGamma(65535.0f*g); - *blue=EncodePixelGamma(65535.0f*b); -} - -static inline void ConvertXYZToDisplayP3(const double X,const double Y, - const double Z,double *red,double *green,double *blue) -{ - double - b, - g, - r; - - - ((void) sizeof (( - red != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - red != (double *) - ((void *)0)) ; else __assert_fail ( - "red != (double *) NULL" - , "./MagickCore/gem-private.h", 271, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - green != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - green != (double *) - ((void *)0)) ; else __assert_fail ( - "green != (double *) NULL" - , "./MagickCore/gem-private.h", 272, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - blue != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - blue != (double *) - ((void *)0)) ; else __assert_fail ( - "blue != (double *) NULL" - , "./MagickCore/gem-private.h", 273, __extension__ __PRETTY_FUNCTION__); })) - ; - r=2.49349691194142500*X-0.93138361791912390*Y-0.402710784450716840*Z; - g=(-0.82948896956157470)*X+1.76266406031834630*Y+0.023624685841943577*Z; - b=0.03584583024378447*X-0.07617238926804182*Y+0.956884524007687200*Z; - *red=EncodePixelGamma(65535.0f*r); - *green=EncodePixelGamma(65535.0f*g); - *blue=EncodePixelGamma(65535.0f*b); -} - -static inline void ConvertXYZToLab(const double X,const double Y,const double Z, - const IlluminantType illuminant,double *L,double *a,double *b) -{ - double - x, - y, - z; - - - ((void) sizeof (( - L != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - L != (double *) - ((void *)0)) ; else __assert_fail ( - "L != (double *) NULL" - , "./MagickCore/gem-private.h", 290, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - a != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - a != (double *) - ((void *)0)) ; else __assert_fail ( - "a != (double *) NULL" - , "./MagickCore/gem-private.h", 291, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - b != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - b != (double *) - ((void *)0)) ; else __assert_fail ( - "b != (double *) NULL" - , "./MagickCore/gem-private.h", 292, __extension__ __PRETTY_FUNCTION__); })) - ; - if ((X/illuminant_tristimulus[illuminant].x) > (216.0/24389.0)) - x=pow(X/illuminant_tristimulus[illuminant].x,1.0/3.0); + *Y = L / (24389.0 / 27.0); + gamma = PerceptibleReciprocal( + (((52.0 * L * + PerceptibleReciprocal( + u + 13.0 * L * + (4.0 * illuminant_tristimulus[illuminant].x / + (illuminant_tristimulus[illuminant].x + + 15.0 * illuminant_tristimulus[illuminant].y + + 3.0 * illuminant_tristimulus[illuminant].z)))) - + 1.0) / + 3.0) - + (-1.0 / 3.0)); + *X = gamma * + ((*Y * ((39.0 * L * + PerceptibleReciprocal( + v + 13.0 * L * + (9.0 * illuminant_tristimulus[illuminant].y / + (illuminant_tristimulus[illuminant].x + + 15.0 * illuminant_tristimulus[illuminant].y + + 3.0 * illuminant_tristimulus[illuminant].z)))) - + 5.0)) + + 5.0 * (*Y)); + *Z = (*X * (((52.0 * L * + PerceptibleReciprocal( + u + 13.0 * L * + (4.0 * illuminant_tristimulus[illuminant].x / + (illuminant_tristimulus[illuminant].x + + 15.0 * illuminant_tristimulus[illuminant].y + + 3.0 * illuminant_tristimulus[illuminant].z)))) - + 1.0) / + 3.0)) - + 5.0 * (*Y); +} + +static inline void ConvertProPhotoToXYZ(const double red, const double green, + const double blue, double *X, double *Y, + double *Z) { + double b, g, r; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 211, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 212, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 213, + __extension__ __PRETTY_FUNCTION__); + })); + r = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(red); + g = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(green); + b = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(blue); + *X = 0.7977604896723027 * r + 0.13518583717574031 * g + + 0.03134934958152480000 * b; + *Y = 0.2880711282292934 * r + 0.71184321781010140 * g + + 0.00008565396060525902 * b; + *Z = 0.0000000000000000 * r + 0.00000000000000000 * g + + 0.82510460251046010000 * b; +} + +static inline void ConvertRGBToXYZ(const double red, const double green, + const double blue, double *X, double *Y, + double *Z) { + double b, g, r; + + ((void)sizeof((X != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (X != (double *)((void *)0)) + ; + else + __assert_fail("X != (double *) NULL", "./MagickCore/gem-private.h", 233, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Y != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Y != (double *)((void *)0)) + ; + else + __assert_fail("Y != (double *) NULL", "./MagickCore/gem-private.h", 234, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((Z != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (Z != (double *)((void *)0)) + ; + else + __assert_fail("Z != (double *) NULL", "./MagickCore/gem-private.h", 235, + __extension__ __PRETTY_FUNCTION__); + })); + r = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(red); + g = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(green); + b = ((double)1.0 / (double)65535.0f) * DecodePixelGamma(blue); + *X = 0.4124564 * r + 0.3575761 * g + 0.1804375 * b; + *Y = 0.2126729 * r + 0.7151522 * g + 0.0721750 * b; + *Z = 0.0193339 * r + 0.1191920 * g + 0.9503041 * b; +} + +static inline void ConvertXYZToAdobe98(const double X, const double Y, + const double Z, double *red, + double *green, double *blue) { + double b, g, r; + + ((void)sizeof((red != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (red != (double *)((void *)0)) + ; + else + __assert_fail("red != (double *) NULL", "./MagickCore/gem-private.h", + 252, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((green != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (green != (double *)((void *)0)) + ; + else + __assert_fail("green != (double *) NULL", "./MagickCore/gem-private.h", + 253, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((blue != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (blue != (double *)((void *)0)) + ; + else + __assert_fail("blue != (double *) NULL", "./MagickCore/gem-private.h", + 254, __extension__ __PRETTY_FUNCTION__); + })); + r = 2.041587903810746500 * X - 0.56500697427885960 * Y - + 0.34473135077832956 * Z; + g = (-0.969243636280879500) * X + 1.87596750150772020 * Y + + 0.04155505740717557 * Z; + b = 0.013444280632031142 * X - 0.11836239223101838 * Y + + 1.01517499439120540 * Z; + *red = EncodePixelGamma(65535.0f * r); + *green = EncodePixelGamma(65535.0f * g); + *blue = EncodePixelGamma(65535.0f * b); +} + +static inline void ConvertXYZToDisplayP3(const double X, const double Y, + const double Z, double *red, + double *green, double *blue) { + double b, g, r; + + ((void)sizeof((red != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (red != (double *)((void *)0)) + ; + else + __assert_fail("red != (double *) NULL", "./MagickCore/gem-private.h", + 271, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((green != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (green != (double *)((void *)0)) + ; + else + __assert_fail("green != (double *) NULL", "./MagickCore/gem-private.h", + 272, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((blue != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (blue != (double *)((void *)0)) + ; + else + __assert_fail("blue != (double *) NULL", "./MagickCore/gem-private.h", + 273, __extension__ __PRETTY_FUNCTION__); + })); + r = 2.49349691194142500 * X - 0.93138361791912390 * Y - + 0.402710784450716840 * Z; + g = (-0.82948896956157470) * X + 1.76266406031834630 * Y + + 0.023624685841943577 * Z; + b = 0.03584583024378447 * X - 0.07617238926804182 * Y + + 0.956884524007687200 * Z; + *red = EncodePixelGamma(65535.0f * r); + *green = EncodePixelGamma(65535.0f * g); + *blue = EncodePixelGamma(65535.0f * b); +} + +static inline void ConvertXYZToLab(const double X, const double Y, + const double Z, + const IlluminantType illuminant, double *L, + double *a, double *b) { + double x, y, z; + + ((void)sizeof((L != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (L != (double *)((void *)0)) + ; + else + __assert_fail("L != (double *) NULL", "./MagickCore/gem-private.h", 290, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((a != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (a != (double *)((void *)0)) + ; + else + __assert_fail("a != (double *) NULL", "./MagickCore/gem-private.h", 291, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((b != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (b != (double *)((void *)0)) + ; + else + __assert_fail("b != (double *) NULL", "./MagickCore/gem-private.h", 292, + __extension__ __PRETTY_FUNCTION__); + })); + if ((X / illuminant_tristimulus[illuminant].x) > (216.0 / 24389.0)) + x = pow(X / illuminant_tristimulus[illuminant].x, 1.0 / 3.0); else - x=((24389.0/27.0)*X/illuminant_tristimulus[illuminant].x+16.0)/116.0; - if ((Y/illuminant_tristimulus[illuminant].y) > (216.0/24389.0)) - y=pow(Y/illuminant_tristimulus[illuminant].y,1.0/3.0); + x = ((24389.0 / 27.0) * X / illuminant_tristimulus[illuminant].x + 16.0) / + 116.0; + if ((Y / illuminant_tristimulus[illuminant].y) > (216.0 / 24389.0)) + y = pow(Y / illuminant_tristimulus[illuminant].y, 1.0 / 3.0); else - y=((24389.0/27.0)*Y/illuminant_tristimulus[illuminant].y+16.0)/116.0; - if ((Z/illuminant_tristimulus[illuminant].z) > (216.0/24389.0)) - z=pow(Z/illuminant_tristimulus[illuminant].z,1.0/3.0); + y = ((24389.0 / 27.0) * Y / illuminant_tristimulus[illuminant].y + 16.0) / + 116.0; + if ((Z / illuminant_tristimulus[illuminant].z) > (216.0 / 24389.0)) + z = pow(Z / illuminant_tristimulus[illuminant].z, 1.0 / 3.0); else - z=((24389.0/27.0)*Z/illuminant_tristimulus[illuminant].z+16.0)/116.0; - *L=((116.0*y)-16.0)/100.0; - *a=(500.0*(x-y))/255.0+0.5; - *b=(200.0*(y-z))/255.0+0.5; -} - -static inline void ConvertXYZToLuv(const double X,const double Y,const double Z, - const IlluminantType illuminant,double *L,double *u,double *v) -{ - double - alpha; - - - ((void) sizeof (( - L != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - L != (double *) - ((void *)0)) ; else __assert_fail ( - "L != (double *) NULL" - , "./MagickCore/gem-private.h", 316, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - u != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - u != (double *) - ((void *)0)) ; else __assert_fail ( - "u != (double *) NULL" - , "./MagickCore/gem-private.h", 317, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - v != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - v != (double *) - ((void *)0)) ; else __assert_fail ( - "v != (double *) NULL" - , "./MagickCore/gem-private.h", 318, __extension__ __PRETTY_FUNCTION__); })) - ; - if ((Y/illuminant_tristimulus[illuminant].y) > (216.0/24389.0)) - *L=(double) (116.0*pow(Y/illuminant_tristimulus[illuminant].y, - 1.0/3.0)-16.0); + z = ((24389.0 / 27.0) * Z / illuminant_tristimulus[illuminant].z + 16.0) / + 116.0; + *L = ((116.0 * y) - 16.0) / 100.0; + *a = (500.0 * (x - y)) / 255.0 + 0.5; + *b = (200.0 * (y - z)) / 255.0 + 0.5; +} + +static inline void ConvertXYZToLuv(const double X, const double Y, + const double Z, + const IlluminantType illuminant, double *L, + double *u, double *v) { + double alpha; + + ((void)sizeof((L != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (L != (double *)((void *)0)) + ; + else + __assert_fail("L != (double *) NULL", "./MagickCore/gem-private.h", 316, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((u != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (u != (double *)((void *)0)) + ; + else + __assert_fail("u != (double *) NULL", "./MagickCore/gem-private.h", 317, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((v != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (v != (double *)((void *)0)) + ; + else + __assert_fail("v != (double *) NULL", "./MagickCore/gem-private.h", 318, + __extension__ __PRETTY_FUNCTION__); + })); + if ((Y / illuminant_tristimulus[illuminant].y) > (216.0 / 24389.0)) + *L = (double)(116.0 * + pow(Y / illuminant_tristimulus[illuminant].y, 1.0 / 3.0) - + 16.0); else - *L=(24389.0/27.0)*(Y/illuminant_tristimulus[illuminant].y); - alpha=PerceptibleReciprocal(X+15.0*Y+3.0*Z); - *u=13.0*(*L)*((4.0*alpha*X)-(4.0*illuminant_tristimulus[illuminant].x/ - (illuminant_tristimulus[illuminant].x+15.0* - illuminant_tristimulus[illuminant].y+3.0* - illuminant_tristimulus[illuminant].z))); - *v=13.0*(*L)*((9.0*alpha*Y)-(9.0*illuminant_tristimulus[illuminant].y/ - (illuminant_tristimulus[illuminant].x+15.0* - illuminant_tristimulus[illuminant].y+3.0* - illuminant_tristimulus[illuminant].z))); - *L/=100.0; - *u=(*u+134.0)/354.0; - *v=(*v+140.0)/262.0; -} - -static inline void ConvertXYZToProPhoto(const double X,const double Y, - const double Z,double *red,double *green,double *blue) -{ - double - b, - g, - r; - - - ((void) sizeof (( - red != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - red != (double *) - ((void *)0)) ; else __assert_fail ( - "red != (double *) NULL" - , "./MagickCore/gem-private.h", 346, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - green != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - green != (double *) - ((void *)0)) ; else __assert_fail ( - "green != (double *) NULL" - , "./MagickCore/gem-private.h", 347, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - blue != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - blue != (double *) - ((void *)0)) ; else __assert_fail ( - "blue != (double *) NULL" - , "./MagickCore/gem-private.h", 348, __extension__ __PRETTY_FUNCTION__); })) - ; - r=1.3457989731028281*X-0.25558010007997534*Y-0.05110628506753401*Z; - g=(-0.5446224939028347)*X+1.50823274131327810*Y+0.02053603239147973*Z; - b=0.0000000000000000*X+0.0000000000000000*Y+1.21196754563894540*Z; - *red=EncodePixelGamma(65535.0f*r); - *green=EncodePixelGamma(65535.0f*g); - *blue=EncodePixelGamma(65535.0f*b); -} - -static inline void ConvertXYZToRGB(const double X,const double Y,const double Z, - double *red,double *green,double *blue) -{ - double - b, - g, - r; - - - ((void) sizeof (( - red != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - red != (double *) - ((void *)0)) ; else __assert_fail ( - "red != (double *) NULL" - , "./MagickCore/gem-private.h", 365, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - green != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - green != (double *) - ((void *)0)) ; else __assert_fail ( - "green != (double *) NULL" - , "./MagickCore/gem-private.h", 366, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - blue != (double *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - blue != (double *) - ((void *)0)) ; else __assert_fail ( - "blue != (double *) NULL" - , "./MagickCore/gem-private.h", 367, __extension__ __PRETTY_FUNCTION__); })) - ; - r=3.2404542*X-1.5371385*Y-0.4985314*Z; - g=(-0.9692660)*X+1.8760108*Y+0.0415560*Z; - b=0.0556434*X-0.2040259*Y+1.0572252*Z; - *red=EncodePixelGamma(65535.0f*r); - *green=EncodePixelGamma(65535.0f*g); - *blue=EncodePixelGamma(65535.0f*b); -} - - -extern __attribute__ ((visibility ("default"))) Image - *CloneImageList(const Image *,ExceptionInfo *), - *CloneImages(const Image *,const char *,ExceptionInfo *), - *DestroyImageList(Image *), - *DuplicateImages(Image *,const size_t,const char *,ExceptionInfo *), - *GetFirstImageInList(const Image *) __attribute__((__pure__)), - *GetImageFromList(const Image *,const ssize_t) __attribute__((__pure__)), - *GetLastImageInList(const Image *) __attribute__((__pure__)), - *GetNextImageInList(const Image *) __attribute__((__pure__)), - *GetPreviousImageInList(const Image *) __attribute__((__pure__)), - **ImageListToArray(const Image *,ExceptionInfo *), - *NewImageList(void) __attribute__((__const__)), - *RemoveImageFromList(Image **), - *RemoveLastImageFromList(Image **), - *RemoveFirstImageFromList(Image **), - *SpliceImageIntoList(Image **,const size_t,const Image *), - *SplitImageList(Image *), - *SyncNextImageInList(const Image *); - -extern __attribute__ ((visibility ("default"))) size_t - GetImageListLength(const Image *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) ssize_t - GetImageIndexInList(const Image *) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) void - AppendImageToList(Image **,const Image *), - DeleteImageFromList(Image **), - DeleteImages(Image **,const char *,ExceptionInfo *), - InsertImageInList(Image **,Image *), - PrependImageToList(Image **,Image *), - ReplaceImageInList(Image **,Image *), - ReplaceImageInListReturnLast(Image **,Image *), - ReverseImageList(Image **), - SyncImageList(Image *); - - - - - -static inline size_t OverAllocateMemory(const size_t length) -{ - size_t - extent; - - - - - extent=length; + *L = (24389.0 / 27.0) * (Y / illuminant_tristimulus[illuminant].y); + alpha = PerceptibleReciprocal(X + 15.0 * Y + 3.0 * Z); + *u = 13.0 * (*L) * + ((4.0 * alpha * X) - (4.0 * illuminant_tristimulus[illuminant].x / + (illuminant_tristimulus[illuminant].x + + 15.0 * illuminant_tristimulus[illuminant].y + + 3.0 * illuminant_tristimulus[illuminant].z))); + *v = 13.0 * (*L) * + ((9.0 * alpha * Y) - (9.0 * illuminant_tristimulus[illuminant].y / + (illuminant_tristimulus[illuminant].x + + 15.0 * illuminant_tristimulus[illuminant].y + + 3.0 * illuminant_tristimulus[illuminant].z))); + *L /= 100.0; + *u = (*u + 134.0) / 354.0; + *v = (*v + 140.0) / 262.0; +} + +static inline void ConvertXYZToProPhoto(const double X, const double Y, + const double Z, double *red, + double *green, double *blue) { + double b, g, r; + + ((void)sizeof((red != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (red != (double *)((void *)0)) + ; + else + __assert_fail("red != (double *) NULL", "./MagickCore/gem-private.h", + 346, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((green != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (green != (double *)((void *)0)) + ; + else + __assert_fail("green != (double *) NULL", "./MagickCore/gem-private.h", + 347, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((blue != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (blue != (double *)((void *)0)) + ; + else + __assert_fail("blue != (double *) NULL", "./MagickCore/gem-private.h", + 348, __extension__ __PRETTY_FUNCTION__); + })); + r = 1.3457989731028281 * X - 0.25558010007997534 * Y - + 0.05110628506753401 * Z; + g = (-0.5446224939028347) * X + 1.50823274131327810 * Y + + 0.02053603239147973 * Z; + b = 0.0000000000000000 * X + 0.0000000000000000 * Y + 1.21196754563894540 * Z; + *red = EncodePixelGamma(65535.0f * r); + *green = EncodePixelGamma(65535.0f * g); + *blue = EncodePixelGamma(65535.0f * b); +} + +static inline void ConvertXYZToRGB(const double X, const double Y, + const double Z, double *red, double *green, + double *blue) { + double b, g, r; + + ((void)sizeof((red != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (red != (double *)((void *)0)) + ; + else + __assert_fail("red != (double *) NULL", "./MagickCore/gem-private.h", + 365, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((green != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (green != (double *)((void *)0)) + ; + else + __assert_fail("green != (double *) NULL", "./MagickCore/gem-private.h", + 366, __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((blue != (double *)((void *)0)) ? 1 : 0), __extension__({ + if (blue != (double *)((void *)0)) + ; + else + __assert_fail("blue != (double *) NULL", "./MagickCore/gem-private.h", + 367, __extension__ __PRETTY_FUNCTION__); + })); + r = 3.2404542 * X - 1.5371385 * Y - 0.4985314 * Z; + g = (-0.9692660) * X + 1.8760108 * Y + 0.0415560 * Z; + b = 0.0556434 * X - 0.2040259 * Y + 1.0572252 * Z; + *red = EncodePixelGamma(65535.0f * r); + *green = EncodePixelGamma(65535.0f * g); + *blue = EncodePixelGamma(65535.0f * b); +} + +extern __attribute__((visibility("default"))) Image * +CloneImageList(const Image *, ExceptionInfo *), + *CloneImages(const Image *, const char *, ExceptionInfo *), + *DestroyImageList(Image *), + *DuplicateImages(Image *, const size_t, const char *, ExceptionInfo *), + *GetFirstImageInList(const Image *) __attribute__((__pure__)), + *GetImageFromList(const Image *, const ssize_t) __attribute__((__pure__)), + *GetLastImageInList(const Image *) __attribute__((__pure__)), + *GetNextImageInList(const Image *) __attribute__((__pure__)), + *GetPreviousImageInList(const Image *) __attribute__((__pure__)), + **ImageListToArray(const Image *, ExceptionInfo *), + *NewImageList(void) __attribute__((__const__)), + *RemoveImageFromList(Image **), *RemoveLastImageFromList(Image **), + *RemoveFirstImageFromList(Image **), + *SpliceImageIntoList(Image **, const size_t, const Image *), + *SplitImageList(Image *), *SyncNextImageInList(const Image *); + +extern __attribute__((visibility("default"))) size_t +GetImageListLength(const Image *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) ssize_t +GetImageIndexInList(const Image *) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) void +AppendImageToList(Image **, const Image *), + DeleteImageFromList(Image **), + DeleteImages(Image **, const char *, ExceptionInfo *), + InsertImageInList(Image **, Image *), PrependImageToList(Image **, Image *), + ReplaceImageInList(Image **, Image *), + ReplaceImageInListReturnLast(Image **, Image *), ReverseImageList(Image **), + SyncImageList(Image *); + +static inline size_t OverAllocateMemory(const size_t length) { + size_t extent; + + extent = length; if (extent < 131072) - for (extent=256; extent < length; extent*=2); - return(extent); + for (extent = 256; extent < length; extent *= 2) + ; + return (extent); } -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - ShredMagickMemory(void *,const size_t); +extern __attribute__((visibility("hidden"))) MagickBooleanType +ShredMagickMemory(void *, const size_t); -extern __attribute__ ((visibility ("hidden"))) void - ResetMaxMemoryRequest(void), - ResetVirtualAnonymousMemory(void); +extern __attribute__((visibility("hidden"))) void ResetMaxMemoryRequest(void), + ResetVirtualAnonymousMemory(void); -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - MonitorComponentGenesis(void); +extern __attribute__((visibility("hidden"))) MagickBooleanType +MonitorComponentGenesis(void); -extern __attribute__ ((visibility ("hidden"))) void - MonitorComponentTerminus(void); -typedef enum -{ +extern __attribute__((visibility("hidden"))) void +MonitorComponentTerminus(void); +typedef enum { MagickUndefinedOptions = -1, MagickAlignOptions = 0, MagickAlphaChannelOptions, @@ -16741,8 +13232,7 @@ typedef enum MagickWordBreakOptions } CommandOption; -typedef enum -{ +typedef enum { UndefinedValidate, NoValidate = 0x00000, ColorspaceValidate = 0x00001, @@ -16760,13 +13250,7 @@ typedef enum AllValidate = 0x7fffffff } ValidateType; - - - - - -typedef enum -{ +typedef enum { UndefinedOptionFlag = 0x0000, ImageInfoOptionFlag = 0x0001, @@ -16782,69 +13266,58 @@ typedef enum SpecialOptionFlag = 0x0100, - AlwaysInterpretArgsFlag = 0x0400, - NeverInterpretArgsFlag = 0x0800, - - - NonMagickOptionFlag = 0x1000, - FireOptionFlag = 0x2000, - DeprecateOptionFlag = 0x4000, - ReplacedOptionFlag = 0x8800 - -} CommandOptionFlags; - -typedef struct _OptionInfo -{ - const char - *mnemonic; - - ssize_t - type, - flags; - - MagickBooleanType - stealth; -} OptionInfo; - - -extern __attribute__ ((visibility ("default"))) char - **GetCommandOptions(const CommandOption), - *GetNextImageOption(const ImageInfo *), - *RemoveImageOption(ImageInfo *,const char *); + NeverInterpretArgsFlag = 0x0800, -extern __attribute__ ((visibility ("default"))) const char - *CommandOptionToMnemonic(const CommandOption,const ssize_t), - *GetImageOption(const ImageInfo *,const char *); + NonMagickOptionFlag = 0x1000, + FireOptionFlag = 0x2000, + DeprecateOptionFlag = 0x4000, + ReplacedOptionFlag = 0x8800 -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CloneImageOptions(ImageInfo *,const ImageInfo *), - DefineImageOption(ImageInfo *,const char *), - DeleteImageOption(ImageInfo *,const char *), - IsCommandOption(const char *), - IsOptionMember(const char *,const char *), - ListCommandOptions(FILE *,const CommandOption,ExceptionInfo *), - SetImageOption(ImageInfo *,const char *,const char *); +} CommandOptionFlags; -extern __attribute__ ((visibility ("default"))) ssize_t - GetCommandOptionFlags(const CommandOption,const MagickBooleanType, - const char *), - ParseChannelOption(const char *), - ParsePixelChannelOption(const char *), - ParseCommandOption(const CommandOption,const MagickBooleanType,const char *); +typedef struct _OptionInfo { + const char *mnemonic; -extern __attribute__ ((visibility ("default"))) void - DestroyImageOptions(ImageInfo *), - ResetImageOptions(const ImageInfo *), - ResetImageOptionIterator(const ImageInfo *); + ssize_t type, flags; -extern __attribute__ ((visibility ("default"))) const OptionInfo - *GetCommandOptionInfo(const char *value); + MagickBooleanType stealth; +} OptionInfo; +extern __attribute__((visibility("default"))) char ** +GetCommandOptions(const CommandOption), + *GetNextImageOption(const ImageInfo *), + *RemoveImageOption(ImageInfo *, const char *); + +extern __attribute__((visibility("default"))) const char * +CommandOptionToMnemonic(const CommandOption, const ssize_t), + *GetImageOption(const ImageInfo *, const char *); + +extern __attribute__((visibility("default"))) MagickBooleanType +CloneImageOptions(ImageInfo *, const ImageInfo *), + DefineImageOption(ImageInfo *, const char *), + DeleteImageOption(ImageInfo *, const char *), IsCommandOption(const char *), + IsOptionMember(const char *, const char *), + ListCommandOptions(FILE *, const CommandOption, ExceptionInfo *), + SetImageOption(ImageInfo *, const char *, const char *); + +extern __attribute__((visibility("default"))) ssize_t +GetCommandOptionFlags(const CommandOption, const MagickBooleanType, + const char *), + ParseChannelOption(const char *), ParsePixelChannelOption(const char *), + ParseCommandOption(const CommandOption, const MagickBooleanType, + const char *); + +extern __attribute__((visibility("default"))) void +DestroyImageOptions(ImageInfo *), + ResetImageOptions(const ImageInfo *), + ResetImageOptionIterator(const ImageInfo *); + +extern __attribute__((visibility("default"))) const OptionInfo * +GetCommandOptionInfo(const char *value); -typedef enum -{ +typedef enum { UndefinedPolicyDomain, CoderPolicyDomain, DelegatePolicyDomain, @@ -16856,8 +13329,7 @@ typedef enum ModulePolicyDomain } PolicyDomain; -typedef enum -{ +typedef enum { UndefinedPolicyRights = 0x00, NoPolicyRights = 0x00, ReadPolicyRights = 0x01, @@ -16866,48 +13338,43 @@ typedef enum AllPolicyRights = 0xff } PolicyRights; -typedef struct _PolicyInfo - PolicyInfo; - -extern __attribute__ ((visibility ("default"))) char - *GetPolicyValue(const char *), - **GetPolicyList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) const PolicyInfo - **GetPolicyInfoList(const char *,size_t *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - IsRightsAuthorized(const PolicyDomain,const PolicyRights,const char *), - ListPolicyInfo(FILE *,ExceptionInfo *), - SetMagickSecurityPolicy(const char *,ExceptionInfo *), - SetMagickSecurityPolicyValue(const PolicyDomain,const char *,const char *, - ExceptionInfo *); -extern __attribute__ ((visibility ("default"))) char - *InterpretImageProperties(ImageInfo *,Image *,const char *, - ExceptionInfo *), - *RemoveImageProperty(Image *,const char *); - -extern __attribute__ ((visibility ("default"))) const char - *GetNextImageProperty(const Image *), - *GetImageProperty(const Image *,const char *,ExceptionInfo *), - *GetMagickProperty(ImageInfo *,Image *,const char *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CloneImageProperties(Image *,const Image *), - DefineImageProperty(Image *,const char *,ExceptionInfo *), - DeleteImageProperty(Image *,const char *), - FormatImageProperty(Image *,const char *,const char *,...) - __attribute__((__format__ (__printf__,3,4))), - SetImageProperty(Image *,const char *,const char *,ExceptionInfo *); +typedef struct _PolicyInfo PolicyInfo; + +extern __attribute__((visibility("default"))) char * +GetPolicyValue(const char *), + **GetPolicyList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) const PolicyInfo ** +GetPolicyInfoList(const char *, size_t *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +IsRightsAuthorized(const PolicyDomain, const PolicyRights, const char *), + ListPolicyInfo(FILE *, ExceptionInfo *), + SetMagickSecurityPolicy(const char *, ExceptionInfo *), + SetMagickSecurityPolicyValue(const PolicyDomain, const char *, const char *, + ExceptionInfo *); +extern __attribute__((visibility("default"))) char * +InterpretImageProperties(ImageInfo *, Image *, const char *, ExceptionInfo *), + *RemoveImageProperty(Image *, const char *); + +extern __attribute__((visibility("default"))) const char * +GetNextImageProperty(const Image *), + *GetImageProperty(const Image *, const char *, ExceptionInfo *), + *GetMagickProperty(ImageInfo *, Image *, const char *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +CloneImageProperties(Image *, const Image *), + DefineImageProperty(Image *, const char *, ExceptionInfo *), + DeleteImageProperty(Image *, const char *), + FormatImageProperty(Image *, const char *, const char *, ...) + __attribute__((__format__(__printf__, 3, 4))), + SetImageProperty(Image *, const char *, const char *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) void +DestroyImageProperties(Image *), + ResetImagePropertyIterator(const Image *); -extern __attribute__ ((visibility ("default"))) void - DestroyImageProperties(Image *), - ResetImagePropertyIterator(const Image *); - - - -typedef enum -{ +typedef enum { UndefinedResource, AreaResource, DiskResource, @@ -16922,400 +13389,325 @@ typedef enum ListLengthResource } ResourceType; +extern __attribute__((visibility("default"))) int +AcquireUniqueFileResource(char *); +extern __attribute__((visibility("default"))) MagickBooleanType +AcquireMagickResource(const ResourceType, const MagickSizeType), + GetPathTemplate(char *), ListMagickResourceInfo(FILE *, ExceptionInfo *), + RelinquishUniqueFileResource(const char *), + SetMagickResourceLimit(const ResourceType, const MagickSizeType); -extern __attribute__ ((visibility ("default"))) int - AcquireUniqueFileResource(char *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AcquireMagickResource(const ResourceType,const MagickSizeType), - GetPathTemplate(char *), - ListMagickResourceInfo(FILE *,ExceptionInfo *), - RelinquishUniqueFileResource(const char *), - SetMagickResourceLimit(const ResourceType,const MagickSizeType); +extern __attribute__((visibility("default"))) MagickSizeType +GetMagickResource(const ResourceType), + GetMagickResourceLimit(const ResourceType); -extern __attribute__ ((visibility ("default"))) MagickSizeType - GetMagickResource(const ResourceType), - GetMagickResourceLimit(const ResourceType); - -extern __attribute__ ((visibility ("default"))) void - RelinquishMagickResource(const ResourceType,const MagickSizeType); +extern __attribute__((visibility("default"))) void +RelinquishMagickResource(const ResourceType, const MagickSizeType); typedef pthread_t MagickThreadType; - - - - - - typedef pthread_key_t MagickThreadKey; +extern __attribute__((visibility("default"))) MagickBooleanType +CreateMagickThreadKey(MagickThreadKey *, void (*destructor)(void *)), + DeleteMagickThreadKey(MagickThreadKey), + SetMagickThreadValue(MagickThreadKey, const void *); - - - - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - CreateMagickThreadKey(MagickThreadKey *,void (*destructor)(void *)), - DeleteMagickThreadKey(MagickThreadKey), - SetMagickThreadValue(MagickThreadKey,const void *); - -extern __attribute__ ((visibility ("default"))) void - *GetMagickThreadValue(MagickThreadKey); - typedef pthread_mutex_t MagickMutexType; - - - - - +extern __attribute__((visibility("default"))) void * + GetMagickThreadValue(MagickThreadKey); +typedef pthread_mutex_t MagickMutexType; static inline int GetMagickNumberThreads(const Image *source, - const Image *destination,const size_t chunk,int multithreaded) -{ - const CacheType - destination_type = (CacheType) GetImagePixelCacheType(destination), - source_type = (CacheType) GetImagePixelCacheType(source); - - int - number_threads; - - + const Image *destination, + const size_t chunk, + int multithreaded) { + const CacheType destination_type = + (CacheType)GetImagePixelCacheType(destination), + source_type = (CacheType)GetImagePixelCacheType(source); + int number_threads; if (multithreaded == 0) - return(1); + return (1); if (((source_type != MemoryCache) && (source_type != MapCache)) || ((destination_type != MemoryCache) && (destination_type != MapCache))) - number_threads=(int) (((GetMagickResourceLimit(ThreadResource)) < (2)) ? (GetMagickResourceLimit(ThreadResource)) : (2)); + number_threads = (int)(((GetMagickResourceLimit(ThreadResource)) < (2)) + ? (GetMagickResourceLimit(ThreadResource)) + : (2)); else - number_threads=(int) ((((ssize_t) GetMagickResourceLimit(ThreadResource)) < ((ssize_t) (chunk)/64)) ? ((ssize_t) GetMagickResourceLimit(ThreadResource)) : ((ssize_t) (chunk)/64)) - ; - return((((number_threads) > (1)) ? (number_threads) : (1))); + number_threads = + (int)((((ssize_t)GetMagickResourceLimit(ThreadResource)) < + ((ssize_t)(chunk) / 64)) + ? ((ssize_t)GetMagickResourceLimit(ThreadResource)) + : ((ssize_t)(chunk) / 64)); + return ((((number_threads) > (1)) ? (number_threads) : (1))); } -static inline MagickThreadType GetMagickThreadId(void) -{ - - return(pthread_self()); - - - - +static inline MagickThreadType GetMagickThreadId(void) { + return (pthread_self()); } -static inline size_t GetMagickThreadSignature(void) -{ +static inline size_t GetMagickThreadSignature(void) { { - union - { - pthread_t - id; + union { + pthread_t id; - size_t - signature; + size_t signature; } magick_thread; - magick_thread.signature=0UL; - magick_thread.id=pthread_self(); - return(magick_thread.signature); + magick_thread.signature = 0UL; + magick_thread.id = pthread_self(); + return (magick_thread.signature); } - - - - - } -static inline MagickBooleanType IsMagickThreadEqual(const MagickThreadType id) -{ - - if (pthread_equal(id,pthread_self()) != 0) - return(MagickTrue); - - +static inline MagickBooleanType IsMagickThreadEqual(const MagickThreadType id) { + if (pthread_equal(id, pthread_self()) != 0) + return (MagickTrue); - - - - return(MagickFalse); + return (MagickFalse); } +static inline size_t GetOpenMPMaximumThreads(void) { - - -static inline size_t GetOpenMPMaximumThreads(void) -{ - - return(omp_get_max_threads()); - - - + return (omp_get_max_threads()); } -static inline int GetOpenMPThreadId(void) -{ - - return(omp_get_thread_num()); +static inline int GetOpenMPThreadId(void) { return (omp_get_thread_num()); } - - -} - -static inline void SetOpenMPMaximumThreads(const int threads) -{ +static inline void SetOpenMPMaximumThreads(const int threads) { omp_set_num_threads(threads); - - - } -static inline void SetOpenMPNested(const int value) -{ - - omp_set_nested(value); - - - -} - - +static inline void SetOpenMPNested(const int value) { omp_set_nested(value); } +extern __attribute__((visibility("hidden"))) double +GetRandomInfoNormalize(const RandomInfo *); +extern __attribute__((visibility("hidden"))) MagickBooleanType +RandomComponentGenesis(void); -extern __attribute__ ((visibility ("hidden"))) double - GetRandomInfoNormalize(const RandomInfo *); +extern __attribute__((visibility("hidden"))) unsigned long * +GetRandomInfoSeed(RandomInfo *); -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - RandomComponentGenesis(void); +extern __attribute__((visibility("hidden"))) void RandomComponentTerminus(void); -extern __attribute__ ((visibility ("hidden"))) unsigned long - *GetRandomInfoSeed(RandomInfo *); +static inline RandomInfo **DestroyRandomInfoTLS(RandomInfo **random_info) { + ssize_t i; -extern __attribute__ ((visibility ("hidden"))) void - RandomComponentTerminus(void); + ((void)sizeof((random_info != (RandomInfo **)((void *)0)) ? 1 : 0), + __extension__({ + if (random_info != (RandomInfo **)((void *)0)) + ; + else + __assert_fail("random_info != (RandomInfo **) NULL", + "./MagickCore/random-private.h", 44, + __extension__ __PRETTY_FUNCTION__); + })); + for (i = 0; i < (ssize_t)GetMagickResourceLimit(ThreadResource); i++) + if (random_info[i] != (RandomInfo *)((void *)0)) + random_info[i] = DestroyRandomInfo(random_info[i]); + return ((RandomInfo **)RelinquishMagickMemory(random_info)); +} + +static inline RandomInfo **AcquireRandomInfoTLS(void) { + ssize_t i; -static inline RandomInfo **DestroyRandomInfoTLS(RandomInfo **random_info) -{ - ssize_t - i; - - - ((void) sizeof (( - random_info != (RandomInfo **) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - random_info != (RandomInfo **) - ((void *)0)) ; else __assert_fail ( - "random_info != (RandomInfo **) NULL" - , "./MagickCore/random-private.h", 44, __extension__ __PRETTY_FUNCTION__); })) - ; - for (i=0; i < (ssize_t) GetMagickResourceLimit(ThreadResource); i++) - if (random_info[i] != (RandomInfo *) - ((void *)0) - ) - random_info[i]=DestroyRandomInfo(random_info[i]); - return((RandomInfo **) RelinquishMagickMemory(random_info)); + RandomInfo **random_info; + + size_t number_threads; + + number_threads = (size_t)GetMagickResourceLimit(ThreadResource); + random_info = + (RandomInfo **)AcquireQuantumMemory(number_threads, sizeof(*random_info)); + if (random_info == (RandomInfo **)((void *)0)) { + char *fatal_message; + ExceptionInfo *fatal_exception; + fatal_exception = AcquireExceptionInfo(); + fatal_message = GetExceptionMessage((*__errno_location())); + (void)ThrowMagickException(fatal_exception, "./MagickCore/random-private.h", + __func__, (unsigned long)66, + ResourceLimitFatalError, + "MemoryAllocationFailed", "`%s'", fatal_message); + fatal_message = DestroyString(fatal_message); + CatchException(fatal_exception); + (void)DestroyExceptionInfo(fatal_exception); + MagickCoreTerminus(); + _exit((int)(ResourceLimitFatalError - FatalErrorException) + 1); + }; + (void)memset(random_info, 0, number_threads * sizeof(*random_info)); + for (i = 0; i < (ssize_t)number_threads; i++) + random_info[i] = AcquireRandomInfo(); + return (random_info); } -static inline RandomInfo **AcquireRandomInfoTLS(void) -{ - ssize_t - i; - - RandomInfo - **random_info; - - size_t - number_threads; - - number_threads=(size_t) GetMagickResourceLimit(ThreadResource); - random_info=(RandomInfo **) AcquireQuantumMemory(number_threads, - sizeof(*random_info)); - if (random_info == (RandomInfo **) - ((void *)0) - ) - { char *fatal_message; ExceptionInfo *fatal_exception; fatal_exception=AcquireExceptionInfo(); fatal_message=GetExceptionMessage( - (*__errno_location ()) - ); (void) ThrowMagickException(fatal_exception,"./MagickCore/random-private.h",__func__,(unsigned long) 66,ResourceLimitFatalError,"MemoryAllocationFailed", "`%s'",fatal_message); fatal_message=DestroyString(fatal_message); CatchException(fatal_exception); (void) DestroyExceptionInfo(fatal_exception); MagickCoreTerminus(); _exit((int) (ResourceLimitFatalError-FatalErrorException)+1); }; - (void) memset(random_info,0,number_threads*sizeof(*random_info)); - for (i=0; i < (ssize_t) number_threads; i++) - random_info[i]=AcquireRandomInfo(); - return(random_info); -} +static inline ResampleFilter ** +DestroyResampleFilterTLS(ResampleFilter **filter) { + ssize_t i; -static inline ResampleFilter **DestroyResampleFilterTLS(ResampleFilter **filter) -{ - ssize_t - i; - - - ((void) sizeof (( - filter != (ResampleFilter **) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - filter != (ResampleFilter **) - ((void *)0)) ; else __assert_fail ( - "filter != (ResampleFilter **) NULL" - , "./MagickCore/resample-private.h", 32, __extension__ __PRETTY_FUNCTION__); })) - ; - for (i=0; i < (ssize_t) GetMagickResourceLimit(ThreadResource); i++) - if (filter[i] != (ResampleFilter *) - ((void *)0) - ) - filter[i]=DestroyResampleFilter(filter[i]); - filter=(ResampleFilter **) RelinquishMagickMemory(filter); - return(filter); -} + ((void)sizeof((filter != (ResampleFilter **)((void *)0)) ? 1 : 0), + __extension__({ + if (filter != (ResampleFilter **)((void *)0)) + ; + else + __assert_fail("filter != (ResampleFilter **) NULL", + "./MagickCore/resample-private.h", 32, + __extension__ __PRETTY_FUNCTION__); + })); + for (i = 0; i < (ssize_t)GetMagickResourceLimit(ThreadResource); i++) + if (filter[i] != (ResampleFilter *)((void *)0)) + filter[i] = DestroyResampleFilter(filter[i]); + filter = (ResampleFilter **)RelinquishMagickMemory(filter); + return (filter); +} + +static inline ResampleFilter ** +AcquireResampleFilterTLS(const Image *image, const VirtualPixelMethod method, + const MagickBooleanType interpolate, + ExceptionInfo *exception) { + ssize_t i; -static inline ResampleFilter **AcquireResampleFilterTLS(const Image *image, - const VirtualPixelMethod method,const MagickBooleanType interpolate, - ExceptionInfo *exception) -{ - ssize_t - i; - - ResampleFilter - **filter; - - size_t - number_threads; - - number_threads=(size_t) GetMagickResourceLimit(ThreadResource); - filter=(ResampleFilter **) AcquireQuantumMemory(number_threads, - sizeof(*filter)); - if (filter == (ResampleFilter **) - ((void *)0) - ) - { char *fatal_message; ExceptionInfo *fatal_exception; fatal_exception=AcquireExceptionInfo(); fatal_message=GetExceptionMessage( - (*__errno_location ()) - ); (void) ThrowMagickException(fatal_exception,"./MagickCore/resample-private.h",__func__,(unsigned long) 57,ResourceLimitFatalError,"MemoryAllocationFailed", "`%s'",fatal_message); fatal_message=DestroyString(fatal_message); CatchException(fatal_exception); (void) DestroyExceptionInfo(fatal_exception); MagickCoreTerminus(); _exit((int) (ResourceLimitFatalError-FatalErrorException)+1); }; - (void) memset(filter,0,number_threads*sizeof(*filter)); - for (i=0; i < (ssize_t) number_threads; i++) - { - filter[i]=AcquireResampleFilter(image,exception); + ResampleFilter **filter; + + size_t number_threads; + + number_threads = (size_t)GetMagickResourceLimit(ThreadResource); + filter = + (ResampleFilter **)AcquireQuantumMemory(number_threads, sizeof(*filter)); + if (filter == (ResampleFilter **)((void *)0)) { + char *fatal_message; + ExceptionInfo *fatal_exception; + fatal_exception = AcquireExceptionInfo(); + fatal_message = GetExceptionMessage((*__errno_location())); + (void)ThrowMagickException(fatal_exception, + "./MagickCore/resample-private.h", __func__, + (unsigned long)57, ResourceLimitFatalError, + "MemoryAllocationFailed", "`%s'", fatal_message); + fatal_message = DestroyString(fatal_message); + CatchException(fatal_exception); + (void)DestroyExceptionInfo(fatal_exception); + MagickCoreTerminus(); + _exit((int)(ResourceLimitFatalError - FatalErrorException) + 1); + }; + (void)memset(filter, 0, number_threads * sizeof(*filter)); + for (i = 0; i < (ssize_t)number_threads; i++) { + filter[i] = AcquireResampleFilter(image, exception); if (method != UndefinedVirtualPixelMethod) - (void) SetResampleFilterVirtualPixelMethod(filter[i],method); + (void)SetResampleFilterVirtualPixelMethod(filter[i], method); if (interpolate != MagickFalse) - SetResampleFilter(filter[i],PointFilter); + SetResampleFilter(filter[i], PointFilter); } - return(filter); + return (filter); } +typedef struct _SplayTreeInfo SplayTreeInfo; -typedef struct _SplayTreeInfo - SplayTreeInfo; - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AddValueToSplayTree(SplayTreeInfo *,const void *,const void *), - DeleteNodeByValueFromSplayTree(SplayTreeInfo *,const void *), - DeleteNodeFromSplayTree(SplayTreeInfo *,const void *); +extern __attribute__((visibility("default"))) MagickBooleanType +AddValueToSplayTree(SplayTreeInfo *, const void *, const void *), + DeleteNodeByValueFromSplayTree(SplayTreeInfo *, const void *), + DeleteNodeFromSplayTree(SplayTreeInfo *, const void *); -extern __attribute__ ((visibility ("default"))) const void - *GetNextKeyInSplayTree(SplayTreeInfo *), - *GetNextValueInSplayTree(SplayTreeInfo *), - *GetRootValueFromSplayTree(SplayTreeInfo *), - *GetValueFromSplayTree(SplayTreeInfo *,const void *); +extern __attribute__((visibility("default"))) const void * +GetNextKeyInSplayTree(SplayTreeInfo *), + *GetNextValueInSplayTree(SplayTreeInfo *), + *GetRootValueFromSplayTree(SplayTreeInfo *), + *GetValueFromSplayTree(SplayTreeInfo *, const void *); -extern __attribute__ ((visibility ("default"))) int - CompareSplayTreeString(const void *,const void *), - CompareSplayTreeStringInfo(const void *,const void *); +extern __attribute__((visibility("default"))) int +CompareSplayTreeString(const void *, const void *), + CompareSplayTreeStringInfo(const void *, const void *); -extern __attribute__ ((visibility ("default"))) SplayTreeInfo - *CloneSplayTree(SplayTreeInfo *,void *(*)(void *),void *(*)(void *)), - *DestroySplayTree(SplayTreeInfo *), - *NewSplayTree(int (*)(const void *,const void *),void *(*)(void *), - void *(*)(void *)); +extern __attribute__((visibility("default"))) SplayTreeInfo * +CloneSplayTree(SplayTreeInfo *, void *(*)(void *), void *(*)(void *)), + *DestroySplayTree(SplayTreeInfo *), + *NewSplayTree(int (*)(const void *, const void *), void *(*)(void *), + void *(*)(void *)); -extern __attribute__ ((visibility ("default"))) size_t - GetNumberOfNodesInSplayTree(const SplayTreeInfo *); +extern __attribute__((visibility("default"))) size_t +GetNumberOfNodesInSplayTree(const SplayTreeInfo *); -extern __attribute__ ((visibility ("default"))) void - *RemoveNodeByValueFromSplayTree(SplayTreeInfo *,const void *), - *RemoveNodeFromSplayTree(SplayTreeInfo *,const void *), - ResetSplayTree(SplayTreeInfo *), - ResetSplayTreeIterator(SplayTreeInfo *); +extern __attribute__((visibility("default"))) void * +RemoveNodeByValueFromSplayTree(SplayTreeInfo *, const void *), + *RemoveNodeFromSplayTree(SplayTreeInfo *, const void *), + ResetSplayTree(SplayTreeInfo *), ResetSplayTreeIterator(SplayTreeInfo *); -static inline double MagickLog10(const double x) -{ +static inline double MagickLog10(const double x) { if (fabs(x) < 1.0e-12) - return(log10(1.0e-12)); - return(log10(fabs(x))); + return (log10(1.0e-12)); + return (log10(fabs(x))); } - -typedef enum -{ +typedef enum { UndefinedThresholdMethod, KapurThresholdMethod, OTSUThresholdMethod, TriangleThresholdMethod } AutoThresholdMethod; -typedef struct _ThresholdMap - ThresholdMap; - -extern __attribute__ ((visibility ("default"))) Image - *AdaptiveThresholdImage(const Image *,const size_t,const size_t,const double, - ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) ThresholdMap - *DestroyThresholdMap(ThresholdMap *), - *GetThresholdMap(const char *,ExceptionInfo *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AutoThresholdImage(Image *,const AutoThresholdMethod,ExceptionInfo *), - BilevelImage(Image *,const double,ExceptionInfo *), - BlackThresholdImage(Image *,const char *,ExceptionInfo *), - ClampImage(Image *,ExceptionInfo *), - ColorThresholdImage(Image *,const PixelInfo *,const PixelInfo *, - ExceptionInfo *), - ListThresholdMaps(FILE *,ExceptionInfo *), - OrderedDitherImage(Image *,const char *,ExceptionInfo *), - PerceptibleImage(Image *,const double,ExceptionInfo *), - RandomThresholdImage(Image *,const double,const double,ExceptionInfo *), - RangeThresholdImage(Image *,const double,const double,const double, - const double,ExceptionInfo *), - WhiteThresholdImage(Image *,const char *,ExceptionInfo *); -typedef struct _TokenInfo - TokenInfo; - -extern __attribute__ ((visibility ("default"))) int - Tokenizer(TokenInfo *,const unsigned int,char *,const size_t,const char *, - const char *,const char *,const char *,const char,char *,int *,char *); - -extern __attribute__ ((visibility ("default"))) MagickBooleanType - GlobExpression(const char *__restrict__,const char *__restrict__, - const MagickBooleanType) __attribute__((__pure__)); - -extern __attribute__ ((visibility ("default"))) size_t - GetNextToken(const char *__restrict__,const char **__restrict__, - const size_t,char *__restrict__) __attribute__((__hot__)); - -extern __attribute__ ((visibility ("default"))) TokenInfo - *AcquireTokenInfo(void), - *DestroyTokenInfo(TokenInfo *); -extern __attribute__ ((visibility ("default"))) Image - *AutoOrientImage(const Image *,const OrientationType,ExceptionInfo *), - *ChopImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *ConsolidateCMYKImages(const Image *,ExceptionInfo *), - *CropImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *CropImageToTiles(const Image *,const char *, ExceptionInfo *), - *ExcerptImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *ExtentImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *FlipImage(const Image *,ExceptionInfo *), - *FlopImage(const Image *,ExceptionInfo *), - *RollImage(const Image *,const ssize_t,const ssize_t,ExceptionInfo *), - *ShaveImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *SpliceImage(const Image *,const RectangleInfo *,ExceptionInfo *), - *TransposeImage(const Image *,ExceptionInfo *), - *TransverseImage(const Image *,ExceptionInfo *), - *TrimImage(const Image *,ExceptionInfo *); -extern __attribute__ ((visibility ("hidden"))) MagickBooleanType - TransformImage(Image **,const char *,const char *,ExceptionInfo *); -typedef enum -{ +typedef struct _ThresholdMap ThresholdMap; + +extern __attribute__((visibility("default"))) Image * +AdaptiveThresholdImage(const Image *, const size_t, const size_t, const double, + ExceptionInfo *); + +extern __attribute__((visibility("default"))) ThresholdMap * +DestroyThresholdMap(ThresholdMap *), + *GetThresholdMap(const char *, ExceptionInfo *); + +extern __attribute__((visibility("default"))) MagickBooleanType +AutoThresholdImage(Image *, const AutoThresholdMethod, ExceptionInfo *), + BilevelImage(Image *, const double, ExceptionInfo *), + BlackThresholdImage(Image *, const char *, ExceptionInfo *), + ClampImage(Image *, ExceptionInfo *), + ColorThresholdImage(Image *, const PixelInfo *, const PixelInfo *, + ExceptionInfo *), + ListThresholdMaps(FILE *, ExceptionInfo *), + OrderedDitherImage(Image *, const char *, ExceptionInfo *), + PerceptibleImage(Image *, const double, ExceptionInfo *), + RandomThresholdImage(Image *, const double, const double, ExceptionInfo *), + RangeThresholdImage(Image *, const double, const double, const double, + const double, ExceptionInfo *), + WhiteThresholdImage(Image *, const char *, ExceptionInfo *); +typedef struct _TokenInfo TokenInfo; + +extern __attribute__((visibility("default"))) int +Tokenizer(TokenInfo *, const unsigned int, char *, const size_t, const char *, + const char *, const char *, const char *, const char, char *, int *, + char *); + +extern __attribute__((visibility("default"))) MagickBooleanType +GlobExpression(const char *__restrict__, const char *__restrict__, + const MagickBooleanType) __attribute__((__pure__)); + +extern __attribute__((visibility("default"))) size_t +GetNextToken(const char *__restrict__, const char **__restrict__, const size_t, + char *__restrict__) __attribute__((__hot__)); + +extern __attribute__((visibility("default"))) TokenInfo *AcquireTokenInfo(void), + *DestroyTokenInfo(TokenInfo *); +extern __attribute__((visibility("default"))) Image * +AutoOrientImage(const Image *, const OrientationType, ExceptionInfo *), + *ChopImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *ConsolidateCMYKImages(const Image *, ExceptionInfo *), + *CropImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *CropImageToTiles(const Image *, const char *, ExceptionInfo *), + *ExcerptImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *ExtentImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *FlipImage(const Image *, ExceptionInfo *), + *FlopImage(const Image *, ExceptionInfo *), + *RollImage(const Image *, const ssize_t, const ssize_t, ExceptionInfo *), + *ShaveImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *SpliceImage(const Image *, const RectangleInfo *, ExceptionInfo *), + *TransposeImage(const Image *, ExceptionInfo *), + *TransverseImage(const Image *, ExceptionInfo *), + *TrimImage(const Image *, ExceptionInfo *); +extern __attribute__((visibility("hidden"))) MagickBooleanType +TransformImage(Image **, const char *, const char *, ExceptionInfo *); +typedef enum { UndefinedPath, MagickPath, RootPath, @@ -17329,26 +13721,25 @@ typedef enum BasePathSansCompressExtension } PathType; -extern __attribute__ ((visibility ("default"))) char - *Base64Encode(const unsigned char *,const size_t,size_t *); +extern __attribute__((visibility("default"))) char * +Base64Encode(const unsigned char *, const size_t, size_t *); -extern __attribute__ ((visibility ("default"))) MagickBooleanType - AcquireUniqueFilename(char *), - AcquireUniqueSymbolicLink(const char *,char *), - ExpandFilenames(int *,char ***), - GetPathAttributes(const char *,void *), - IsPathAccessible(const char *); +extern __attribute__((visibility("default"))) MagickBooleanType +AcquireUniqueFilename(char *), + AcquireUniqueSymbolicLink(const char *, char *), + ExpandFilenames(int *, char ***), GetPathAttributes(const char *, void *), + IsPathAccessible(const char *); -extern __attribute__ ((visibility ("default"))) size_t - MultilineCensus(const char *) __attribute__((__pure__)); +extern __attribute__((visibility("default"))) size_t +MultilineCensus(const char *) __attribute__((__pure__)); -extern __attribute__ ((visibility ("default"))) unsigned char - *Base64Decode(const char *, size_t *); +extern __attribute__((visibility("default"))) unsigned char * +Base64Decode(const char *, size_t *); -extern __attribute__ ((visibility ("default"))) void - AppendImageFormat(const char *,char *), - GetPathComponent(const char *,PathType,char *), - MagickDelay(const MagickSizeType); +extern __attribute__((visibility("default"))) void +AppendImageFormat(const char *, char *), + GetPathComponent(const char *, PathType, char *), + MagickDelay(const MagickSizeType); typedef long double fxFltType; typedef enum { @@ -17394,51 +13785,31 @@ typedef enum { typedef struct { OperatorE op; - const char * str; + const char *str; int precedence; int nArgs; } OperatorT; static const OperatorT Operators[] = { - {oAddEq, "+=", 12, 1}, - {oSubtractEq, "-=", 12, 1}, - {oMultiplyEq, "*=", 13, 1}, - {oDivideEq, "/=", 13, 1}, - {oPlusPlus, "++", 12, 0}, - {oSubSub, "--", 12, 0}, - {oAdd, "+", 12, 2}, - {oSubtract, "-", 12, 2}, - {oMultiply, "*", 13, 2}, - {oDivide, "/", 13, 2}, - {oModulus, "%", 13, 2}, - {oUnaryPlus, "+", 14, 1}, - {oUnaryMinus, "-", 14, 1}, - {oLshift, "<<", 11, 2}, - {oRshift, ">>", 11, 2}, - {oEq, "==", 9, 2}, - {oNotEq, "!=", 9, 2}, - {oLtEq, "<=", 10, 2}, - {oGtEq, ">=", 10, 2}, - {oLt, "<", 10, 2}, - {oGt, ">", 10, 2}, - {oLogAnd, "&&", 6, 2}, - {oLogOr, "||", 5, 2}, - {oLogNot, "!", 16, 1}, - {oBitAnd, "&", 8, 2}, - {oBitOr, "|", 7, 2}, - {oBitNot, "~", 16, 1}, - {oPow, "^", 15, 2}, - {oQuery, "?", 4, 1}, - {oColon, ":", 4, 1}, - {oOpenParen, "(", 0, 0}, - {oCloseParen, ")", 0, 0}, - {oOpenBracket, "[", 0, 0}, - {oCloseBracket,"]", 0, 0}, - {oOpenBrace, "{", 0, 0}, - {oCloseBrace, "}", 0, 0}, - {oAssign, "=", 3, 1}, - {oNull, "onull", 17, 0} -}; + {oAddEq, "+=", 12, 1}, {oSubtractEq, "-=", 12, 1}, + {oMultiplyEq, "*=", 13, 1}, {oDivideEq, "/=", 13, 1}, + {oPlusPlus, "++", 12, 0}, {oSubSub, "--", 12, 0}, + {oAdd, "+", 12, 2}, {oSubtract, "-", 12, 2}, + {oMultiply, "*", 13, 2}, {oDivide, "/", 13, 2}, + {oModulus, "%", 13, 2}, {oUnaryPlus, "+", 14, 1}, + {oUnaryMinus, "-", 14, 1}, {oLshift, "<<", 11, 2}, + {oRshift, ">>", 11, 2}, {oEq, "==", 9, 2}, + {oNotEq, "!=", 9, 2}, {oLtEq, "<=", 10, 2}, + {oGtEq, ">=", 10, 2}, {oLt, "<", 10, 2}, + {oGt, ">", 10, 2}, {oLogAnd, "&&", 6, 2}, + {oLogOr, "||", 5, 2}, {oLogNot, "!", 16, 1}, + {oBitAnd, "&", 8, 2}, {oBitOr, "|", 7, 2}, + {oBitNot, "~", 16, 1}, {oPow, "^", 15, 2}, + {oQuery, "?", 4, 1}, {oColon, ":", 4, 1}, + {oOpenParen, "(", 0, 0}, {oCloseParen, ")", 0, 0}, + {oOpenBracket, "[", 0, 0}, {oCloseBracket, "]", 0, 0}, + {oOpenBrace, "{", 0, 0}, {oCloseBrace, "}", 0, 0}, + {oAssign, "=", 3, 1}, {oNull, "onull", 17, 0}}; typedef enum { cEpsilon, @@ -17456,26 +13827,23 @@ typedef enum { typedef struct { ConstantE cons; fxFltType val; - const char * str; + const char *str; } ConstantT; static const ConstantT Constants[] = { - {cEpsilon, 1.0e-12, "epsilon"}, - {cE, 2.7182818284590452354, "e"}, - {cOpaque, 1.0, "opaque"}, - {cPhi, 1.61803398874989484820458683436563811772030917980576, "phi"}, - {cPi, 3.14159265358979323846264338327950288419716939937510, "pi"}, - {cQuantumRange, 65535.0f, "quantumrange"}, - {cQuantumScale, ((double) 1.0/(double) 65535.0f), "quantumscale"}, - {cTransparent, 0.0, "transparent"}, - {cMaxRgb, 65535.0f, "MaxRGB"}, - {cNull, 0.0, "cnull"} -}; - - + {cEpsilon, 1.0e-12, "epsilon"}, + {cE, 2.7182818284590452354, "e"}, + {cOpaque, 1.0, "opaque"}, + {cPhi, 1.61803398874989484820458683436563811772030917980576, "phi"}, + {cPi, 3.14159265358979323846264338327950288419716939937510, "pi"}, + {cQuantumRange, 65535.0f, "quantumrange"}, + {cQuantumScale, ((double)1.0 / (double)65535.0f), "quantumscale"}, + {cTransparent, 0.0, "transparent"}, + {cMaxRgb, 65535.0f, "MaxRGB"}, + {cNull, 0.0, "cnull"}}; typedef enum { - fAbs = oNull+1, + fAbs = oNull + 1, fAcosh, @@ -17513,10 +13881,8 @@ typedef enum { fJ0, - fJ1, - fJinc, fLn, @@ -17556,94 +13922,67 @@ typedef enum { typedef struct { FunctionE func; - const char * str; + const char *str; int nArgs; } FunctionT; static const FunctionT Functions[] = { - {fAbs, "abs" , 1}, - - {fAcosh, "acosh" , 1}, - - {fAcos, "acos" , 1}, - - {fAiry, "airy" , 1}, - - {fAlt, "alt" , 1}, - - {fAsinh, "asinh" , 1}, - - {fAsin, "asin" , 1}, - - {fAtanh, "atanh" , 1}, - - {fAtan2, "atan2" , 2}, - {fAtan, "atan" , 1}, - {fCeil, "ceil" , 1}, - {fChannel, "channel", 5}, - {fClamp, "clamp" , 1}, - {fCosh, "cosh" , 1}, - {fCos, "cos" , 1}, - {fDebug, "debug" , 1}, - {fDrc, "drc" , 2}, - - {fErf, "erf" , 1}, - - {fExp, "exp" , 1}, - {fFloor, "floor" , 1}, - {fGauss, "gauss" , 2}, - {fGcd, "gcd" , 2}, - {fHypot, "hypot" , 2}, - {fInt, "int" , 1}, - {fIsnan, "isnan" , 1}, - - {fJ0, "j0" , 1}, - - - {fJ1, "j1" , 1}, - - - {fJinc, "jinc" , 1}, - - {fLn, "ln" , 1}, - {fLogtwo, "logtwo", 1}, - {fLog, "log" , 1}, - {fMax, "max" , 2}, - {fMin, "min" , 2}, - {fMod, "mod" , 2}, - {fNot, "not" , 1}, - {fPow, "pow" , 2}, - {fRand, "rand" , 0}, - {fRound, "round" , 1}, - {fSign, "sign" , 1}, - {fSinc, "sinc" , 1}, - {fSinh, "sinh" , 1}, - {fSin, "sin" , 1}, - {fSqrt, "sqrt" , 1}, - {fSquish, "squish", 1}, - {fTanh, "tanh" , 1}, - {fTan, "tan" , 1}, - {fTrunc, "trunc" , 1}, - {fDo, "do", 2}, - {fFor, "for", 3}, - {fIf, "if", 3}, - {fWhile, "while", 2}, - {fU, "u", 1}, - {fU0, "u0", 0}, - {fUP, "up", 3}, - {fS, "s", 0}, - {fV, "v", 0}, - {fP, "p", 2}, - {fSP, "sp", 2}, - {fVP, "vp", 2}, - - {fNull, "fnull" , 0} -}; + {fAbs, "abs", 1}, + + {fAcosh, "acosh", 1}, + + {fAcos, "acos", 1}, + + {fAiry, "airy", 1}, + + {fAlt, "alt", 1}, + + {fAsinh, "asinh", 1}, + + {fAsin, "asin", 1}, + + {fAtanh, "atanh", 1}, + + {fAtan2, "atan2", 2}, {fAtan, "atan", 1}, + {fCeil, "ceil", 1}, {fChannel, "channel", 5}, + {fClamp, "clamp", 1}, {fCosh, "cosh", 1}, + {fCos, "cos", 1}, {fDebug, "debug", 1}, + {fDrc, "drc", 2}, + + {fErf, "erf", 1}, + + {fExp, "exp", 1}, {fFloor, "floor", 1}, + {fGauss, "gauss", 2}, {fGcd, "gcd", 2}, + {fHypot, "hypot", 2}, {fInt, "int", 1}, + {fIsnan, "isnan", 1}, + + {fJ0, "j0", 1}, + + {fJ1, "j1", 1}, + + {fJinc, "jinc", 1}, + {fLn, "ln", 1}, {fLogtwo, "logtwo", 1}, + {fLog, "log", 1}, {fMax, "max", 2}, + {fMin, "min", 2}, {fMod, "mod", 2}, + {fNot, "not", 1}, {fPow, "pow", 2}, + {fRand, "rand", 0}, {fRound, "round", 1}, + {fSign, "sign", 1}, {fSinc, "sinc", 1}, + {fSinh, "sinh", 1}, {fSin, "sin", 1}, + {fSqrt, "sqrt", 1}, {fSquish, "squish", 1}, + {fTanh, "tanh", 1}, {fTan, "tan", 1}, + {fTrunc, "trunc", 1}, {fDo, "do", 2}, + {fFor, "for", 3}, {fIf, "if", 3}, + {fWhile, "while", 2}, {fU, "u", 1}, + {fU0, "u0", 0}, {fUP, "up", 3}, + {fS, "s", 0}, {fV, "v", 0}, + {fP, "p", 2}, {fSP, "sp", 2}, + {fVP, "vp", 2}, + {fNull, "fnull", 0}}; typedef enum { - aDepth = fNull+1, + aDepth = fNull + 1, aExtent, aKurtosis, aMaxima, @@ -17674,47 +14013,43 @@ typedef enum { typedef struct { ImgAttrE attr; - const char * str; + const char *str; int NeedStats; } ImgAttrT; -static const ImgAttrT ImgAttrs[] = { - {aDepth, "depth", 1}, - {aExtent, "extent", 0}, - {aKurtosis, "kurtosis", 1}, - {aMaxima, "maxima", 1}, - {aMean, "mean", 1}, - {aMedian, "median", 1}, - {aMinima, "minima", 1}, - {aPage, "page", 0}, - {aPageX, "page.x", 0}, - {aPageY, "page.y", 0}, - {aPageWid, "page.width", 0}, - {aPageHt, "page.height", 0}, - {aPrintsize, "printsize", 0}, - {aPrintsizeX, "printsize.x", 0}, - {aPrintsizeY, "printsize.y", 0}, - {aQuality, "quality", 0}, - {aRes, "resolution", 0}, - {aResX, "resolution.x", 0}, - {aResY, "resolution.y", 0}, - {aSkewness, "skewness", 1}, - {aStdDev, "standard_deviation", 1}, - {aH, "h", 0}, - {aN, "n", 0}, - {aT, "t", 0}, - {aW, "w", 0}, - {aZ, "z", 0}, - {aNull, "anull", 0}, - {aNull, "anull", 0}, - {aNull, "anull", 0}, - {aNull, "anull", 0} -}; - - +static const ImgAttrT ImgAttrs[] = {{aDepth, "depth", 1}, + {aExtent, "extent", 0}, + {aKurtosis, "kurtosis", 1}, + {aMaxima, "maxima", 1}, + {aMean, "mean", 1}, + {aMedian, "median", 1}, + {aMinima, "minima", 1}, + {aPage, "page", 0}, + {aPageX, "page.x", 0}, + {aPageY, "page.y", 0}, + {aPageWid, "page.width", 0}, + {aPageHt, "page.height", 0}, + {aPrintsize, "printsize", 0}, + {aPrintsizeX, "printsize.x", 0}, + {aPrintsizeY, "printsize.y", 0}, + {aQuality, "quality", 0}, + {aRes, "resolution", 0}, + {aResX, "resolution.x", 0}, + {aResY, "resolution.y", 0}, + {aSkewness, "skewness", 1}, + {aStdDev, "standard_deviation", 1}, + {aH, "h", 0}, + {aN, "n", 0}, + {aT, "t", 0}, + {aW, "w", 0}, + {aZ, "z", 0}, + {aNull, "anull", 0}, + {aNull, "anull", 0}, + {aNull, "anull", 0}, + {aNull, "anull", 0}}; typedef enum { - sHue = aNull+1, + sHue = aNull + 1, sIntensity, sLightness, sLuma, @@ -17736,31 +14071,29 @@ typedef enum { typedef struct { SymbolE sym; - const char * str; + const char *str; } SymbolT; -static const SymbolT Symbols[] = { - {sHue, "hue"}, - {sIntensity, "intensity"}, - {sLightness, "lightness"}, - {sLuma, "luma"}, - {sLuminance, "luminance"}, - {sSaturation, "saturation"}, - {sA, "a"}, - {sB, "b"}, - {sC, "c"}, - {sG, "g"}, - {sI, "i"}, - {sJ, "j"}, - {sK, "k"}, - {sM, "m"}, - {sO, "o"}, - {sR, "r"}, - {sY, "y"}, - {sNull, "snull"} -}; +static const SymbolT Symbols[] = {{sHue, "hue"}, + {sIntensity, "intensity"}, + {sLightness, "lightness"}, + {sLuma, "luma"}, + {sLuminance, "luminance"}, + {sSaturation, "saturation"}, + {sA, "a"}, + {sB, "b"}, + {sC, "c"}, + {sG, "g"}, + {sI, "i"}, + {sJ, "j"}, + {sK, "k"}, + {sM, "m"}, + {sO, "o"}, + {sR, "r"}, + {sY, "y"}, + {sNull, "snull"}}; typedef enum { - rGoto = (sNull+1), + rGoto = (sNull + 1), rIfZeroGoto, rIfNotZeroGoto, rCopyFrom, @@ -17771,21 +14104,17 @@ typedef enum { typedef struct { ControlE cont; - const char * str; + const char *str; int nArgs; } ControlT; -static const ControlT Controls[] = { - {rGoto, "goto", 0}, - {rIfZeroGoto, "ifzerogoto", 1}, - {rIfNotZeroGoto, "ifnotzerogoto", 1}, - {rCopyFrom, "copyfrom", 0}, - {rCopyTo, "copyto", 1}, - {rZerStk, "zerstk", 0}, - {rNull, "rnull", 0} -}; - - +static const ControlT Controls[] = {{rGoto, "goto", 0}, + {rIfZeroGoto, "ifzerogoto", 1}, + {rIfNotZeroGoto, "ifnotzerogoto", 1}, + {rCopyFrom, "copyfrom", 0}, + {rCopyTo, "copyto", 1}, + {rZerStk, "zerstk", 0}, + {rNull, "rnull", 0}}; typedef struct { int addrQuery; @@ -17793,32 +14122,28 @@ typedef struct { } TernaryT; typedef struct { - const char * str; + const char *str; PixelChannel pixChan; } ChannelT; -static const ChannelT Channels[] = { - {"r", RedPixelChannel}, - {"g", GreenPixelChannel}, - {"b", BluePixelChannel}, - {"c", CyanPixelChannel}, - {"m", MagentaPixelChannel}, - {"y", YellowPixelChannel}, - {"k", BlackPixelChannel}, - {"a", AlphaPixelChannel}, - {"o", AlphaPixelChannel}, - {"hue", ((PixelChannel) (-3))}, - {"saturation", ((PixelChannel) (-4))}, - {"lightness", ((PixelChannel) (-5))}, - {"intensity", ((PixelChannel) (-6))}, - {"all", CompositePixelChannel}, - {"this", ((PixelChannel) (-2))}, - {"", ((PixelChannel) (-1))} -}; - - +static const ChannelT Channels[] = {{"r", RedPixelChannel}, + {"g", GreenPixelChannel}, + {"b", BluePixelChannel}, + {"c", CyanPixelChannel}, + {"m", MagentaPixelChannel}, + {"y", YellowPixelChannel}, + {"k", BlackPixelChannel}, + {"a", AlphaPixelChannel}, + {"o", AlphaPixelChannel}, + {"hue", ((PixelChannel)(-3))}, + {"saturation", ((PixelChannel)(-4))}, + {"lightness", ((PixelChannel)(-5))}, + {"intensity", ((PixelChannel)(-6))}, + {"all", CompositePixelChannel}, + {"this", ((PixelChannel)(-2))}, + {"", ((PixelChannel)(-1))}}; typedef struct { - char * pex; + char *pex; size_t len; } UserSymbolT; @@ -17832,20 +14157,13 @@ typedef enum { etControl } ElementTypeE; -static const char * sElementTypes[] = { - "Operator", - "Constant", - "Function", - "ImgAttr", - "Symbol", - "ColConst", - "Control" -}; +static const char *sElementTypes[] = {"Operator", "Constant", "Function", + "ImgAttr", "Symbol", "ColConst", + "Control"}; typedef struct { ElementTypeE type; - fxFltType - val, val1, val2; + fxFltType val, val1, val2; int oprNum; int nArgs; MagickBooleanType IsRelative; @@ -17854,15 +14172,11 @@ typedef struct { int nDest; PixelChannel ChannelQual; ImgAttrE ImgAttrQual; - char * pExpStart; + char *pExpStart; int lenExp; } ElementT; -typedef enum { - rtUnknown, - rtEntireImage, - rtCornerOnly -} RunTypeE; +typedef enum { rtUnknown, rtEntireImage, rtCornerOnly } RunTypeE; typedef struct { CacheView *View; @@ -17870,16 +14184,16 @@ typedef struct { } ImgT; typedef struct { - RandomInfo * __restrict__ random_info; + RandomInfo *__restrict__ random_info; int numValStack; int usedValStack; - fxFltType * ValStack; - fxFltType * UserSymVals; - Quantum * thisPixel; + fxFltType *ValStack; + fxFltType *UserSymVals; + Quantum *thisPixel; } fxRtT; struct _FxInfo { - Image * image; + Image *image; size_t ImgListLen; ssize_t ImgNum; MagickBooleanType NeedStats; @@ -17887,845 +14201,830 @@ struct _FxInfo { MagickBooleanType NeedHsl; MagickBooleanType DebugOpt; MagickBooleanType ContainsDebug; - char * expression; - char * pex; + char *expression; + char *pex; char ShortExp[4096]; int teDepth; char token[4096]; size_t lenToken; int numElements; int usedElements; - ElementT * Elements; + ElementT *Elements; int numUserSymbols; int usedUserSymbols; - UserSymbolT * UserSymbols; + UserSymbolT *UserSymbols; int numOprStack; int usedOprStack; int maxUsedOprStack; - OperatorE * OperatorStack; - ChannelStatistics ** statistics; + OperatorE *OperatorStack; + ChannelStatistics **statistics; int precision; RunTypeE runType; - RandomInfo - **__restrict__ random_infos; + RandomInfo **__restrict__ random_infos; - ImgT * Imgs; - Image ** Images; + ImgT *Imgs; + Image **Images; - ExceptionInfo * exception; + ExceptionInfo *exception; - fxRtT * fxrts; + fxRtT *fxrts; }; +static MagickBooleanType +TranslateStatementList(FxInfo *pfx, const char *strLimit, char *chLimit); +static MagickBooleanType TranslateExpression(FxInfo *pfx, const char *strLimit, + char *chLimit, + MagickBooleanType *needPopAll); -static MagickBooleanType TranslateStatementList - (FxInfo * pfx, const char * strLimit, char * chLimit); +static MagickBooleanType GetFunction(FxInfo *pfx, FunctionE fe); -static MagickBooleanType TranslateExpression - (FxInfo * pfx, const char * strLimit, char * chLimit, MagickBooleanType * needPopAll); - -static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe); - -static MagickBooleanType inline ChanIsVirtual (PixelChannel pc) -{ - if (pc==((PixelChannel) (-3)) || pc==((PixelChannel) (-4)) || pc==((PixelChannel) (-5)) || pc==((PixelChannel) (-6))) +static MagickBooleanType inline ChanIsVirtual(PixelChannel pc) { + if (pc == ((PixelChannel)(-3)) || pc == ((PixelChannel)(-4)) || + pc == ((PixelChannel)(-5)) || pc == ((PixelChannel)(-6))) return MagickTrue; return MagickFalse; } -static MagickBooleanType InitFx (FxInfo * pfx, const Image * img, - MagickBooleanType CalcAllStats, ExceptionInfo *exception) -{ - ssize_t i=0; - const Image * next; +static MagickBooleanType InitFx(FxInfo *pfx, const Image *img, + MagickBooleanType CalcAllStats, + ExceptionInfo *exception) { + ssize_t i = 0; + const Image *next; - pfx->ImgListLen = GetImageListLength (img); - pfx->ImgNum = GetImageIndexInList (img); + pfx->ImgListLen = GetImageListLength(img); + pfx->ImgNum = GetImageIndexInList(img); pfx->image = (Image *)img; pfx->NeedStats = MagickFalse; pfx->GotStats = MagickFalse; pfx->NeedHsl = MagickFalse; - pfx->DebugOpt = IsStringTrue (GetImageArtifact (img, "fx:debug")); - pfx->statistics = - ((void *)0) - ; - pfx->Imgs = - ((void *)0) - ; - pfx->Images = - ((void *)0) - ; + pfx->DebugOpt = IsStringTrue(GetImageArtifact(img, "fx:debug")); + pfx->statistics = ((void *)0); + pfx->Imgs = ((void *)0); + pfx->Images = ((void *)0); pfx->exception = exception; - pfx->precision = GetMagickPrecision (); - pfx->random_infos = AcquireRandomInfoTLS (); + pfx->precision = GetMagickPrecision(); + pfx->random_infos = AcquireRandomInfoTLS(); pfx->ContainsDebug = MagickFalse; pfx->runType = (CalcAllStats) ? rtEntireImage : rtCornerOnly; - pfx->Imgs = (ImgT *)AcquireQuantumMemory (pfx->ImgListLen, sizeof (ImgT)); + pfx->Imgs = (ImgT *)AcquireQuantumMemory(pfx->ImgListLen, sizeof(ImgT)); if (!pfx->Imgs) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 740, ResourceLimitFatalError, - "Imgs", "%lu", - (unsigned long) pfx->ImgListLen); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)740, ResourceLimitFatalError, + "Imgs", "%lu", (unsigned long)pfx->ImgListLen); return MagickFalse; } - next = GetFirstImageInList (img); - for ( ; next != (Image *) - ((void *)0) - ; next=next->next) - { - ImgT * pimg = &pfx->Imgs[i]; - pimg->View = AcquireVirtualCacheView (next, pfx->exception); + next = GetFirstImageInList(img); + for (; next != (Image *)((void *)0); next = next->next) { + ImgT *pimg = &pfx->Imgs[i]; + pimg->View = AcquireVirtualCacheView(next, pfx->exception); if (!pimg->View) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 753, ResourceLimitFatalError, - "View", "[%li]", - (long) i); - - for ( ; i > 0; i--) { - pimg = &pfx->Imgs[i-1]; - pimg->View = DestroyCacheView (pimg->View); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)753, ResourceLimitFatalError, + "View", "[%li]", (long)i); + + for (; i > 0; i--) { + pimg = &pfx->Imgs[i - 1]; + pimg->View = DestroyCacheView(pimg->View); } - pfx->Imgs=(ImgT *) RelinquishMagickMemory (pfx->Imgs); + pfx->Imgs = (ImgT *)RelinquishMagickMemory(pfx->Imgs); return MagickFalse; } i++; } - pfx->Images = ImageListToArray (img, pfx->exception); + pfx->Images = ImageListToArray(img, pfx->exception); return MagickTrue; } -static MagickBooleanType DeInitFx (FxInfo * pfx) -{ +static MagickBooleanType DeInitFx(FxInfo *pfx) { ssize_t i; - if (pfx->Images) pfx->Images = (Image**) RelinquishMagickMemory (pfx->Images); + if (pfx->Images) + pfx->Images = (Image **)RelinquishMagickMemory(pfx->Images); if (pfx->Imgs) { for (i = (ssize_t)GetImageListLength(pfx->image); i > 0; i--) { - ImgT * pimg = &pfx->Imgs[i-1]; - pimg->View = DestroyCacheView (pimg->View); + ImgT *pimg = &pfx->Imgs[i - 1]; + pimg->View = DestroyCacheView(pimg->View); } - pfx->Imgs=(ImgT *) RelinquishMagickMemory (pfx->Imgs); + pfx->Imgs = (ImgT *)RelinquishMagickMemory(pfx->Imgs); } - pfx->random_infos = DestroyRandomInfoTLS (pfx->random_infos); + pfx->random_infos = DestroyRandomInfoTLS(pfx->random_infos); if (pfx->statistics) { for (i = (ssize_t)GetImageListLength(pfx->image); i > 0; i--) { - pfx->statistics[i-1]=(ChannelStatistics *) RelinquishMagickMemory (pfx->statistics[i-1]); + pfx->statistics[i - 1] = + (ChannelStatistics *)RelinquishMagickMemory(pfx->statistics[i - 1]); } - pfx->statistics = (ChannelStatistics**) RelinquishMagickMemory(pfx->statistics); + pfx->statistics = + (ChannelStatistics **)RelinquishMagickMemory(pfx->statistics); } return MagickTrue; } -static ElementTypeE TypeOfOpr (int op) -{ - if (op < oNull) return etOperator; - if (op == oNull) return etConstant; - if (op <= fNull) return etFunction; - if (op <= aNull) return etImgAttr; - if (op <= sNull) return etSymbol; - if (op <= rNull) return etControl; - - return (ElementTypeE) 0; -} +static ElementTypeE TypeOfOpr(int op) { + if (op < oNull) + return etOperator; + if (op == oNull) + return etConstant; + if (op <= fNull) + return etFunction; + if (op <= aNull) + return etImgAttr; + if (op <= sNull) + return etSymbol; + if (op <= rNull) + return etControl; -static char * SetPtrShortExp (FxInfo * pfx, char * pExp, size_t len) -{ + return (ElementTypeE)0; +} +static char *SetPtrShortExp(FxInfo *pfx, char *pExp, size_t len) { size_t slen; - char * p; + char *p; *pfx->ShortExp = '\0'; if (pExp && len) { - slen = CopyMagickString (pfx->ShortExp, pExp, len); + slen = CopyMagickString(pfx->ShortExp, pExp, len); if (slen > 20) { - (void) CopyMagickString (pfx->ShortExp+20, "...", 4); + (void)CopyMagickString(pfx->ShortExp + 20, "...", 4); } - p = strchr (pfx->ShortExp, '\n'); - if (p) (void) CopyMagickString (p, "...", 4); - p = strchr (pfx->ShortExp, '\r'); - if (p) (void) CopyMagickString (p, "...", 4); + p = strchr(pfx->ShortExp, '\n'); + if (p) + (void)CopyMagickString(p, "...", 4); + p = strchr(pfx->ShortExp, '\r'); + if (p) + (void)CopyMagickString(p, "...", 4); } return pfx->ShortExp; } -static char * SetShortExp (FxInfo * pfx) -{ - return SetPtrShortExp (pfx, pfx->pex, 100 -1); +static char *SetShortExp(FxInfo *pfx) { + return SetPtrShortExp(pfx, pfx->pex, 100 - 1); } -static int FindUserSymbol (FxInfo * pfx, char * name) - - +static int FindUserSymbol(FxInfo *pfx, char *name) { int i; size_t lenName; - lenName = strlen (name); - for (i=0; i < pfx->usedUserSymbols; i++) { + lenName = strlen(name); + for (i = 0; i < pfx->usedUserSymbols; i++) { UserSymbolT *pus = &pfx->UserSymbols[i]; - if (lenName == pus->len && LocaleNCompare (name, pus->pex, lenName)==0) break; + if (lenName == pus->len && LocaleNCompare(name, pus->pex, lenName) == 0) + break; } - if (i == pfx->usedUserSymbols) return -2; + if (i == pfx->usedUserSymbols) + return -2; return i; } -static MagickBooleanType ExtendUserSymbols (FxInfo * pfx) -{ - pfx->numUserSymbols = (int) ceil (pfx->numUserSymbols * (1 + 0.1)); - pfx->UserSymbols = (UserSymbolT*) ResizeMagickMemory (pfx->UserSymbols, pfx->numUserSymbols * sizeof(UserSymbolT)); +static MagickBooleanType ExtendUserSymbols(FxInfo *pfx) { + pfx->numUserSymbols = (int)ceil(pfx->numUserSymbols * (1 + 0.1)); + pfx->UserSymbols = (UserSymbolT *)ResizeMagickMemory( + pfx->UserSymbols, pfx->numUserSymbols * sizeof(UserSymbolT)); if (!pfx->UserSymbols) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 859, ResourceLimitFatalError, - "UserSymbols", "%i", - pfx->numUserSymbols); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)859, ResourceLimitFatalError, + "UserSymbols", "%i", pfx->numUserSymbols); return MagickFalse; } return MagickTrue; } -static int AddUserSymbol (FxInfo * pfx, char * pex, size_t len) -{ +static int AddUserSymbol(FxInfo *pfx, char *pex, size_t len) { UserSymbolT *pus; if (++pfx->usedUserSymbols >= pfx->numUserSymbols) { - if (!ExtendUserSymbols (pfx)) return -1; + if (!ExtendUserSymbols(pfx)) + return -1; } - pus = &pfx->UserSymbols[pfx->usedUserSymbols-1]; + pus = &pfx->UserSymbols[pfx->usedUserSymbols - 1]; pus->pex = pex; pus->len = len; - return pfx->usedUserSymbols-1; + return pfx->usedUserSymbols - 1; } -static void DumpTables (FILE * fh) -{ +static void DumpTables(FILE *fh) { int i; - for (i=0; i <= rNull; i++) { - const char * str = ""; - if ( i < oNull) str = Operators[i].str; - if (i >= ((FunctionE) (oNull+1)) && i < fNull) str = Functions[i-((FunctionE) (oNull+1))].str; - if (i >= ((ImgAttrE) (fNull+1)) && i < aNull) str = ImgAttrs[i-((ImgAttrE) (fNull+1))].str; - if (i >= ((SymbolE) (aNull+1)) && i < sNull) str = Symbols[i-((SymbolE) (aNull+1))].str; - if (i >= (sNull+1) && i < rNull) str = Controls[i-(sNull+1)].str; - if (i==0 ) fprintf ( - stderr - , "Operators:\n "); - else if (i==oNull) fprintf ( - stderr - , "\nFunctions:\n "); - else if (i==fNull) fprintf ( - stderr - , "\nImage attributes:\n "); - else if (i==aNull) fprintf ( - stderr - , "\nSymbols:\n "); - else if (i==sNull) fprintf ( - stderr - , "\nControls:\n "); - fprintf (fh, " %s", str); + for (i = 0; i <= rNull; i++) { + const char *str = ""; + if (i < oNull) + str = Operators[i].str; + if (i >= ((FunctionE)(oNull + 1)) && i < fNull) + str = Functions[i - ((FunctionE)(oNull + 1))].str; + if (i >= ((ImgAttrE)(fNull + 1)) && i < aNull) + str = ImgAttrs[i - ((ImgAttrE)(fNull + 1))].str; + if (i >= ((SymbolE)(aNull + 1)) && i < sNull) + str = Symbols[i - ((SymbolE)(aNull + 1))].str; + if (i >= (sNull + 1) && i < rNull) + str = Controls[i - (sNull + 1)].str; + if (i == 0) + fprintf(stderr, "Operators:\n "); + else if (i == oNull) + fprintf(stderr, "\nFunctions:\n "); + else if (i == fNull) + fprintf(stderr, "\nImage attributes:\n "); + else if (i == aNull) + fprintf(stderr, "\nSymbols:\n "); + else if (i == sNull) + fprintf(stderr, "\nControls:\n "); + fprintf(fh, " %s", str); } - fprintf (fh, "\n"); + fprintf(fh, "\n"); } -static char * NameOfUserSym (FxInfo * pfx, int ndx, char * buf) -{ - UserSymbolT * pus; - - ((void) sizeof (( - ndx >= 0 && ndx < pfx->usedUserSymbols - ) ? 1 : 0), __extension__ ({ if ( - ndx >= 0 && ndx < pfx->usedUserSymbols - ) ; else __assert_fail ( - "ndx >= 0 && ndx < pfx->usedUserSymbols" - , "MagickCore/fx.c", 905, __extension__ __PRETTY_FUNCTION__); })) - ; +static char *NameOfUserSym(FxInfo *pfx, int ndx, char *buf) { + UserSymbolT *pus; + + ((void)sizeof((ndx >= 0 && ndx < pfx->usedUserSymbols) ? 1 : 0), + __extension__({ + if (ndx >= 0 && ndx < pfx->usedUserSymbols) + ; + else + __assert_fail("ndx >= 0 && ndx < pfx->usedUserSymbols", + "MagickCore/fx.c", 905, __extension__ __PRETTY_FUNCTION__); + })); pus = &pfx->UserSymbols[ndx]; - (void) CopyMagickString (buf, pus->pex, pus->len+1); + (void)CopyMagickString(buf, pus->pex, pus->len + 1); return buf; } -static void DumpUserSymbols (FxInfo * pfx, FILE * fh) -{ +static void DumpUserSymbols(FxInfo *pfx, FILE *fh) { char UserSym[4096]; int i; - fprintf (fh, "UserSymbols (%i)\n", pfx->usedUserSymbols); - for (i=0; i < pfx->usedUserSymbols; i++) { - fprintf (fh, " %i: '%s'\n", i, NameOfUserSym (pfx, i, UserSym)); + fprintf(fh, "UserSymbols (%i)\n", pfx->usedUserSymbols); + for (i = 0; i < pfx->usedUserSymbols; i++) { + fprintf(fh, " %i: '%s'\n", i, NameOfUserSym(pfx, i, UserSym)); } } -static MagickBooleanType BuildRPN (FxInfo * pfx) -{ +static MagickBooleanType BuildRPN(FxInfo *pfx) { pfx->numUserSymbols = 50; pfx->usedUserSymbols = 0; - pfx->UserSymbols = (UserSymbolT*) AcquireMagickMemory (pfx->numUserSymbols * sizeof(UserSymbolT)); + pfx->UserSymbols = (UserSymbolT *)AcquireMagickMemory(pfx->numUserSymbols * + sizeof(UserSymbolT)); if (!pfx->UserSymbols) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 928, ResourceLimitFatalError, - "UserSymbols", "%i", - pfx->numUserSymbols); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)928, ResourceLimitFatalError, + "UserSymbols", "%i", pfx->numUserSymbols); return MagickFalse; } pfx->numElements = 100; pfx->usedElements = 0; - pfx->Elements = - ((void *)0) - ; + pfx->Elements = ((void *)0); - pfx->Elements = (ElementT*) AcquireMagickMemory (pfx->numElements * sizeof(ElementT)); + pfx->Elements = + (ElementT *)AcquireMagickMemory(pfx->numElements * sizeof(ElementT)); if (!pfx->Elements) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 942, ResourceLimitFatalError, - "Elements", "%i", - pfx->numElements); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)942, ResourceLimitFatalError, + "Elements", "%i", pfx->numElements); return MagickFalse; } pfx->usedOprStack = 0; pfx->maxUsedOprStack = 0; pfx->numOprStack = 50; - pfx->OperatorStack = (OperatorE*) AcquireMagickMemory (pfx->numOprStack * sizeof(OperatorE)); + pfx->OperatorStack = + (OperatorE *)AcquireMagickMemory(pfx->numOprStack * sizeof(OperatorE)); if (!pfx->OperatorStack) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 954, ResourceLimitFatalError, - "OperatorStack", "%i", - pfx->numOprStack); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)954, ResourceLimitFatalError, + "OperatorStack", "%i", pfx->numOprStack); return MagickFalse; } return MagickTrue; } -static MagickBooleanType AllocFxRt (FxInfo * pfx, fxRtT * pfxrt) -{ +static MagickBooleanType AllocFxRt(FxInfo *pfx, fxRtT *pfxrt) { int nRnd; int i; - pfxrt->random_info = AcquireRandomInfo (); - pfxrt->thisPixel = - ((void *)0) - ; + pfxrt->random_info = AcquireRandomInfo(); + pfxrt->thisPixel = ((void *)0); - nRnd = 20 + 10 * (int) GetPseudoRandomValue (pfxrt->random_info); - for (i=0; i < nRnd; i++) (void) GetPseudoRandomValue (pfxrt->random_info);; + nRnd = 20 + 10 * (int)GetPseudoRandomValue(pfxrt->random_info); + for (i = 0; i < nRnd; i++) + (void)GetPseudoRandomValue(pfxrt->random_info); + ; pfxrt->usedValStack = 0; pfxrt->numValStack = 2 * pfx->maxUsedOprStack; - if (pfxrt->numValStack < 100) pfxrt->numValStack = 100; - pfxrt->ValStack = (fxFltType*) AcquireMagickMemory (pfxrt->numValStack * sizeof(fxFltType)); + if (pfxrt->numValStack < 100) + pfxrt->numValStack = 100; + pfxrt->ValStack = + (fxFltType *)AcquireMagickMemory(pfxrt->numValStack * sizeof(fxFltType)); if (!pfxrt->ValStack) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 979, ResourceLimitFatalError, - "ValStack", "%i", - pfxrt->numValStack); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)979, ResourceLimitFatalError, + "ValStack", "%i", pfxrt->numValStack); return MagickFalse; } - pfxrt->UserSymVals = - ((void *)0) - ; + pfxrt->UserSymVals = ((void *)0); if (pfx->usedUserSymbols) { - pfxrt->UserSymVals = (fxFltType*) AcquireMagickMemory (pfx->usedUserSymbols * sizeof(fxFltType)); + pfxrt->UserSymVals = (fxFltType *)AcquireMagickMemory(pfx->usedUserSymbols * + sizeof(fxFltType)); if (!pfxrt->UserSymVals) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 991, ResourceLimitFatalError, - "UserSymVals", "%i", - pfx->usedUserSymbols); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)991, ResourceLimitFatalError, + "UserSymVals", "%i", pfx->usedUserSymbols); return MagickFalse; } - for (i = 0; i < pfx->usedUserSymbols; i++) pfxrt->UserSymVals[i] = (fxFltType) 0; + for (i = 0; i < pfx->usedUserSymbols; i++) + pfxrt->UserSymVals[i] = (fxFltType)0; } return MagickTrue; } -static MagickBooleanType ExtendRPN (FxInfo * pfx) -{ - pfx->numElements = (int) ceil (pfx->numElements * (1 + 0.1)); - pfx->Elements = (ElementT*) ResizeMagickMemory (pfx->Elements, pfx->numElements * sizeof(ElementT)); +static MagickBooleanType ExtendRPN(FxInfo *pfx) { + pfx->numElements = (int)ceil(pfx->numElements * (1 + 0.1)); + pfx->Elements = (ElementT *)ResizeMagickMemory( + pfx->Elements, pfx->numElements * sizeof(ElementT)); if (!pfx->Elements) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1007, ResourceLimitFatalError, - "Elements", "%i", - pfx->numElements); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1007, ResourceLimitFatalError, + "Elements", "%i", pfx->numElements); return MagickFalse; } return MagickTrue; } -static MagickBooleanType inline OprInPlace (int op) -{ +static MagickBooleanType inline OprInPlace(int op) { return (op >= oAddEq && op <= oSubSub ? MagickTrue : MagickFalse); } -static const char * OprStr (int oprNum) -{ - const char * str; - if (oprNum < 0) str = "bad OprStr"; - else if (oprNum <= oNull) str = Operators[oprNum].str; - else if (oprNum <= fNull) str = Functions[oprNum-((FunctionE) (oNull+1))].str; - else if (oprNum <= aNull) str = ImgAttrs[oprNum-((ImgAttrE) (fNull+1))].str; - else if (oprNum <= sNull) str = Symbols[oprNum-((SymbolE) (aNull+1))].str; - else if (oprNum <= rNull) str = Controls[oprNum-(sNull+1)].str; +static const char *OprStr(int oprNum) { + const char *str; + if (oprNum < 0) + str = "bad OprStr"; + else if (oprNum <= oNull) + str = Operators[oprNum].str; + else if (oprNum <= fNull) + str = Functions[oprNum - ((FunctionE)(oNull + 1))].str; + else if (oprNum <= aNull) + str = ImgAttrs[oprNum - ((ImgAttrE)(fNull + 1))].str; + else if (oprNum <= sNull) + str = Symbols[oprNum - ((SymbolE)(aNull + 1))].str; + else if (oprNum <= rNull) + str = Controls[oprNum - (sNull + 1)].str; else { str = "bad OprStr"; } return str; } -static MagickBooleanType DumpRPN (FxInfo * pfx, FILE * fh) -{ +static MagickBooleanType DumpRPN(FxInfo *pfx, FILE *fh) { int i; - fprintf (fh, "DumpRPN:"); - fprintf (fh, " numElements=%i", pfx->numElements); - fprintf (fh, " usedElements=%i", pfx->usedElements); - fprintf (fh, " maxUsedOprStack=%i", pfx->maxUsedOprStack); - fprintf (fh, " ImgListLen=%g", (double) pfx->ImgListLen); - fprintf (fh, " NeedStats=%s", pfx->NeedStats ? "yes" : "no"); - fprintf (fh, " GotStats=%s", pfx->GotStats ? "yes" : "no"); - fprintf (fh, " NeedHsl=%s\n", pfx->NeedHsl ? "yes" : "no"); - if (pfx->runType==rtEntireImage) fprintf ( - stderr - , "EntireImage"); - else if (pfx->runType==rtCornerOnly) fprintf ( - stderr - , "CornerOnly"); - fprintf (fh, "\n"); - - - for (i=0; i < pfx->usedElements; i++) { - ElementT * pel = &pfx->Elements[i]; + fprintf(fh, "DumpRPN:"); + fprintf(fh, " numElements=%i", pfx->numElements); + fprintf(fh, " usedElements=%i", pfx->usedElements); + fprintf(fh, " maxUsedOprStack=%i", pfx->maxUsedOprStack); + fprintf(fh, " ImgListLen=%g", (double)pfx->ImgListLen); + fprintf(fh, " NeedStats=%s", pfx->NeedStats ? "yes" : "no"); + fprintf(fh, " GotStats=%s", pfx->GotStats ? "yes" : "no"); + fprintf(fh, " NeedHsl=%s\n", pfx->NeedHsl ? "yes" : "no"); + if (pfx->runType == rtEntireImage) + fprintf(stderr, "EntireImage"); + else if (pfx->runType == rtCornerOnly) + fprintf(stderr, "CornerOnly"); + fprintf(fh, "\n"); + + for (i = 0; i < pfx->usedElements; i++) { + ElementT *pel = &pfx->Elements[i]; pel->nDest = 0; } - for (i=0; i < pfx->usedElements; i++) { - ElementT * pel = &pfx->Elements[i]; - if (pel->oprNum == rGoto || pel->oprNum == rIfZeroGoto || pel->oprNum == rIfNotZeroGoto) { + for (i = 0; i < pfx->usedElements; i++) { + ElementT *pel = &pfx->Elements[i]; + if (pel->oprNum == rGoto || pel->oprNum == rIfZeroGoto || + pel->oprNum == rIfNotZeroGoto) { if (pel->EleNdx >= 0 && pel->EleNdx < pfx->numElements) { - ElementT * pelDest = &pfx->Elements[pel->EleNdx]; + ElementT *pelDest = &pfx->Elements[pel->EleNdx]; pelDest->nDest++; } } } - for (i=0; i < pfx->usedElements; i++) { + for (i = 0; i < pfx->usedElements; i++) { char UserSym[4096]; - ElementT * pel = &pfx->Elements[i]; - const char * str = OprStr (pel->oprNum); + ElementT *pel = &pfx->Elements[i]; + const char *str = OprStr(pel->oprNum); const char *sRelAbs = ""; - if (pel->oprNum == fP || pel->oprNum == fUP || pel->oprNum == fVP || pel->oprNum == fSP) + if (pel->oprNum == fP || pel->oprNum == fUP || pel->oprNum == fVP || + pel->oprNum == fSP) sRelAbs = pel->IsRelative ? "[]" : "{}"; if (pel->type == etColourConstant) - fprintf (fh, " %i: %s vals=%.*Lg,%.*Lg,%.*Lg '%s%s' nArgs=%i ndx=%i %s", - i, sElementTypes[pel->type], - pfx->precision, pel->val, pfx->precision, pel->val1, pfx->precision, pel->val2, - str, sRelAbs, pel->nArgs, pel->EleNdx, - pel->DoPush ? "push" : "NO push"); + fprintf(fh, " %i: %s vals=%.*Lg,%.*Lg,%.*Lg '%s%s' nArgs=%i ndx=%i %s", + i, sElementTypes[pel->type], pfx->precision, pel->val, + pfx->precision, pel->val1, pfx->precision, pel->val2, str, + sRelAbs, pel->nArgs, pel->EleNdx, + pel->DoPush ? "push" : "NO push"); else - fprintf (fh, " %i: %s val=%.*Lg '%s%s' nArgs=%i ndx=%i %s", - i, sElementTypes[pel->type], pfx->precision, pel->val, str, sRelAbs, - pel->nArgs, pel->EleNdx, - pel->DoPush ? "push" : "NO push"); + fprintf(fh, " %i: %s val=%.*Lg '%s%s' nArgs=%i ndx=%i %s", i, + sElementTypes[pel->type], pfx->precision, pel->val, str, sRelAbs, + pel->nArgs, pel->EleNdx, pel->DoPush ? "push" : "NO push"); if (pel->ImgAttrQual != aNull) - fprintf (fh, " ia=%s", OprStr(pel->ImgAttrQual)); - - if (pel->ChannelQual != ((PixelChannel) (-1))) { - if (pel->ChannelQual == ((PixelChannel) (-2))) fprintf ( - stderr - , " ch=this"); - else fprintf ( - stderr - , " ch=%i", pel->ChannelQual); + fprintf(fh, " ia=%s", OprStr(pel->ImgAttrQual)); + + if (pel->ChannelQual != ((PixelChannel)(-1))) { + if (pel->ChannelQual == ((PixelChannel)(-2))) + fprintf(stderr, " ch=this"); + else + fprintf(stderr, " ch=%i", pel->ChannelQual); } if (pel->oprNum == rCopyTo) { - fprintf (fh, " CopyTo ==> %s", NameOfUserSym (pfx, pel->EleNdx, UserSym)); + fprintf(fh, " CopyTo ==> %s", NameOfUserSym(pfx, pel->EleNdx, UserSym)); } else if (pel->oprNum == rCopyFrom) { - fprintf (fh, " CopyFrom <== %s", NameOfUserSym (pfx, pel->EleNdx, UserSym)); - } else if (OprInPlace (pel->oprNum)) { - fprintf (fh, " <==> %s", NameOfUserSym (pfx, pel->EleNdx, UserSym)); + fprintf(fh, " CopyFrom <== %s", + NameOfUserSym(pfx, pel->EleNdx, UserSym)); + } else if (OprInPlace(pel->oprNum)) { + fprintf(fh, " <==> %s", NameOfUserSym(pfx, pel->EleNdx, UserSym)); } - if (pel->nDest > 0) fprintf (fh, " <==dest(%i)", pel->nDest); - fprintf (fh, "\n"); + if (pel->nDest > 0) + fprintf(fh, " <==dest(%i)", pel->nDest); + fprintf(fh, "\n"); } return MagickTrue; } -static void DestroyRPN (FxInfo * pfx) -{ +static void DestroyRPN(FxInfo *pfx) { pfx->numOprStack = 0; pfx->usedOprStack = 0; - if (pfx->OperatorStack) pfx->OperatorStack = (OperatorE*) RelinquishMagickMemory (pfx->OperatorStack); + if (pfx->OperatorStack) + pfx->OperatorStack = + (OperatorE *)RelinquishMagickMemory(pfx->OperatorStack); pfx->numElements = 0; pfx->usedElements = 0; - if (pfx->Elements) pfx->Elements = (ElementT*) RelinquishMagickMemory (pfx->Elements); + if (pfx->Elements) + pfx->Elements = (ElementT *)RelinquishMagickMemory(pfx->Elements); pfx->usedUserSymbols = 0; - if (pfx->UserSymbols) pfx->UserSymbols = (UserSymbolT*) RelinquishMagickMemory (pfx->UserSymbols); + if (pfx->UserSymbols) + pfx->UserSymbols = (UserSymbolT *)RelinquishMagickMemory(pfx->UserSymbols); } -static void DestroyFxRt (fxRtT * pfxrt) -{ +static void DestroyFxRt(fxRtT *pfxrt) { pfxrt->usedValStack = 0; - if (pfxrt->ValStack) pfxrt->ValStack = (fxFltType*) RelinquishMagickMemory (pfxrt->ValStack); - if (pfxrt->UserSymVals) pfxrt->UserSymVals = (fxFltType*) RelinquishMagickMemory (pfxrt->UserSymVals); + if (pfxrt->ValStack) + pfxrt->ValStack = (fxFltType *)RelinquishMagickMemory(pfxrt->ValStack); + if (pfxrt->UserSymVals) + pfxrt->UserSymVals = + (fxFltType *)RelinquishMagickMemory(pfxrt->UserSymVals); - pfxrt->random_info = DestroyRandomInfo (pfxrt->random_info); + pfxrt->random_info = DestroyRandomInfo(pfxrt->random_info); } -static size_t GetToken (FxInfo * pfx) -{ +static size_t GetToken(FxInfo *pfx) { - char * p = pfx->pex; + char *p = pfx->pex; size_t len = 0; *pfx->token = '\0'; pfx->lenToken = 0; - if (! - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) return 0; - - - - - + if (!((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) + return 0; - if (LocaleNCompare (p, "icc-", 4) == 0) { + if (LocaleNCompare(p, "icc-", 4) == 0) { len = 4; p += 4; while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) { len++; p++; } - } else if (LocaleNCompare (p, "device-", 7) == 0) { + ((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) { + len++; + p++; + } + } else if (LocaleNCompare(p, "device-", 7) == 0) { len = 7; p += 7; while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) { len++; p++; } + ((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) { + len++; + p++; + } } else { while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) { len++; p++; } - if (*p == '_') { len++; p++; } + ((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) { + len++; + p++; + } + if (*p == '_') { + len++; + p++; + } while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) { len++; p++; } + ((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) { + len++; + p++; + } while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISdigit) - ) { len++; p++; } + ((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISdigit)) { + len++; + p++; + } } if (len >= 100) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1169, OptionError, - "GetToken: too long", "%g at '%s'", - (double) len, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1169, OptionError, + "GetToken: too long", "%g at '%s'", (double)len, + SetShortExp(pfx)); len = 100; } if (len) { - (void) CopyMagickString (pfx->token, pfx->pex, (len+1<100)?len+1:100); + (void)CopyMagickString(pfx->token, pfx->pex, + (len + 1 < 100) ? len + 1 : 100); } - pfx->lenToken = strlen (pfx->token); + pfx->lenToken = strlen(pfx->token); return len; } -static MagickBooleanType TokenMaybeUserSymbol (FxInfo * pfx) -{ - char * p = pfx->token; +static MagickBooleanType TokenMaybeUserSymbol(FxInfo *pfx) { + char *p = pfx->token; int i = 0; while (*p) { - if (! - ((*__ctype_b_loc ())[(int) (( - (int)*p++ - ))] & (unsigned short int) _ISalpha) - ) return MagickFalse; + if (!((*__ctype_b_loc())[(int)(((int)*p++))] & + (unsigned short int)_ISalpha)) + return MagickFalse; i++; } - if (i < 2) return MagickFalse; + if (i < 2) + return MagickFalse; return MagickTrue; } -static MagickBooleanType AddElement (FxInfo * pfx, fxFltType val, int oprNum) -{ - ElementT * pel; - - - ((void) sizeof (( - oprNum <= rNull - ) ? 1 : 0), __extension__ ({ if ( - oprNum <= rNull - ) ; else __assert_fail ( - "oprNum <= rNull" - , "MagickCore/fx.c", 1198, __extension__ __PRETTY_FUNCTION__); })) - ; +static MagickBooleanType AddElement(FxInfo *pfx, fxFltType val, int oprNum) { + ElementT *pel; + + ((void)sizeof((oprNum <= rNull) ? 1 : 0), __extension__({ + if (oprNum <= rNull) + ; + else + __assert_fail("oprNum <= rNull", "MagickCore/fx.c", 1198, + __extension__ __PRETTY_FUNCTION__); + })); if (++pfx->usedElements >= pfx->numElements) { - if (!ExtendRPN (pfx)) return MagickFalse; + if (!ExtendRPN(pfx)) + return MagickFalse; } - pel = &pfx->Elements[pfx->usedElements-1]; - pel->type = TypeOfOpr (oprNum); + pel = &pfx->Elements[pfx->usedElements - 1]; + pel->type = TypeOfOpr(oprNum); pel->val = val; - pel->val1 = (fxFltType) 0; - pel->val2 = (fxFltType) 0; + pel->val1 = (fxFltType)0; + pel->val2 = (fxFltType)0; pel->oprNum = oprNum; pel->DoPush = MagickTrue; pel->EleNdx = 0; - pel->ChannelQual = ((PixelChannel) (-1)); + pel->ChannelQual = ((PixelChannel)(-1)); pel->ImgAttrQual = aNull; pel->nDest = 0; - pel->pExpStart = - ((void *)0) - ; + pel->pExpStart = ((void *)0); pel->lenExp = 0; - if (oprNum <= oNull) pel->nArgs = Operators[oprNum].nArgs; - else if (oprNum <= fNull) pel->nArgs = Functions[oprNum-((FunctionE) (oNull+1))].nArgs; - else if (oprNum <= aNull) pel->nArgs = 0; - else if (oprNum <= sNull) pel->nArgs = 0; - else pel->nArgs = Controls[oprNum-(sNull+1)].nArgs; + if (oprNum <= oNull) + pel->nArgs = Operators[oprNum].nArgs; + else if (oprNum <= fNull) + pel->nArgs = Functions[oprNum - ((FunctionE)(oNull + 1))].nArgs; + else if (oprNum <= aNull) + pel->nArgs = 0; + else if (oprNum <= sNull) + pel->nArgs = 0; + else + pel->nArgs = Controls[oprNum - (sNull + 1)].nArgs; return MagickTrue; } -static MagickBooleanType AddAddressingElement (FxInfo * pfx, int oprNum, int EleNdx) -{ - ElementT * pel; - if (!AddElement (pfx, (fxFltType) 0, oprNum)) return MagickFalse; - pel = &pfx->Elements[pfx->usedElements-1]; +static MagickBooleanType AddAddressingElement(FxInfo *pfx, int oprNum, + int EleNdx) { + ElementT *pel; + if (!AddElement(pfx, (fxFltType)0, oprNum)) + return MagickFalse; + pel = &pfx->Elements[pfx->usedElements - 1]; pel->EleNdx = EleNdx; - if (oprNum == rGoto || oprNum == rIfZeroGoto || oprNum == rIfNotZeroGoto - || oprNum == rZerStk) - { + if (oprNum == rGoto || oprNum == rIfZeroGoto || oprNum == rIfNotZeroGoto || + oprNum == rZerStk) { pel->DoPush = MagickFalse; } - - - - return MagickTrue; } -static MagickBooleanType AddColourElement (FxInfo * pfx, fxFltType val0, fxFltType val1, fxFltType val2) -{ - ElementT * pel; - if (!AddElement (pfx, val0, oNull)) return MagickFalse; - pel = &pfx->Elements[pfx->usedElements-1]; +static MagickBooleanType AddColourElement(FxInfo *pfx, fxFltType val0, + fxFltType val1, fxFltType val2) { + ElementT *pel; + if (!AddElement(pfx, val0, oNull)) + return MagickFalse; + pel = &pfx->Elements[pfx->usedElements - 1]; pel->val1 = val1; pel->val2 = val2; pel->type = etColourConstant; return MagickTrue; } -static void inline SkipSpaces (FxInfo * pfx) -{ - while ( - ((*__ctype_b_loc ())[(int) (( - (int)*pfx->pex - ))] & (unsigned short int) _ISspace) - ) pfx->pex++; +static void inline SkipSpaces(FxInfo *pfx) { + while (((*__ctype_b_loc())[(int)(((int)*pfx->pex))] & + (unsigned short int)_ISspace)) + pfx->pex++; } -static char inline PeekChar (FxInfo * pfx) -{ - SkipSpaces (pfx); +static char inline PeekChar(FxInfo *pfx) { + SkipSpaces(pfx); return *pfx->pex; } -static MagickBooleanType inline PeekStr (FxInfo * pfx, const char * str) -{ - SkipSpaces (pfx); +static MagickBooleanType inline PeekStr(FxInfo *pfx, const char *str) { + SkipSpaces(pfx); - return (LocaleNCompare (pfx->pex, str, strlen(str))==0 ? MagickTrue : MagickFalse); + return (LocaleNCompare(pfx->pex, str, strlen(str)) == 0 ? MagickTrue + : MagickFalse); } -static MagickBooleanType ExpectChar (FxInfo * pfx, char c) -{ - if (PeekChar (pfx) != c) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1279, OptionError, - "Expected char", "'%c' at '%s'", c, SetShortExp (pfx)); +static MagickBooleanType ExpectChar(FxInfo *pfx, char c) { + if (PeekChar(pfx) != c) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1279, + OptionError, "Expected char", "'%c' at '%s'", c, SetShortExp(pfx)); return MagickFalse; } pfx->pex++; return MagickTrue; } -static int MaybeXYWH (FxInfo * pfx, ImgAttrE * pop) - - +static int MaybeXYWH(FxInfo *pfx, ImgAttrE *pop) { - int ret=0; + int ret = 0; - if (*pop != aPage && *pop != aPrintsize && *pop != aRes) return 0; + if (*pop != aPage && *pop != aPrintsize && *pop != aRes) + return 0; - if (PeekChar (pfx) != '.') return 0; + if (PeekChar(pfx) != '.') + return 0; - if (!ExpectChar (pfx, '.')) return 0; + if (!ExpectChar(pfx, '.')) + return 0; - (void) GetToken (pfx); - if (LocaleCompare ("x", pfx->token)==0) ret=1; - else if (LocaleCompare ("y", pfx->token)==0) ret=2; - else if (LocaleCompare ("width", pfx->token)==0) ret=3; - else if (LocaleCompare ("height", pfx->token)==0) ret=4; + (void)GetToken(pfx); + if (LocaleCompare("x", pfx->token) == 0) + ret = 1; + else if (LocaleCompare("y", pfx->token) == 0) + ret = 2; + else if (LocaleCompare("width", pfx->token) == 0) + ret = 3; + else if (LocaleCompare("height", pfx->token) == 0) + ret = 4; if (!ret) - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1308, OptionError, - "Invalid 'x' or 'y' or 'width' or 'height' token=", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1308, + OptionError, + "Invalid 'x' or 'y' or 'width' or 'height' token=", "'%s' at '%s'", + pfx->token, SetShortExp(pfx)); - if (*pop == aPage) (*pop) = (ImgAttrE) (*pop + ret); + if (*pop == aPage) + (*pop) = (ImgAttrE)(*pop + ret); else { if (ret > 2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1316, OptionError, - "Invalid 'width' or 'height' token=", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1316, + OptionError, "Invalid 'width' or 'height' token=", "'%s' at '%s'", + pfx->token, SetShortExp(pfx)); } else { - (*pop) = (ImgAttrE) (*pop + ret); + (*pop) = (ImgAttrE)(*pop + ret); } } - pfx->pex+=pfx->lenToken; + pfx->pex += pfx->lenToken; return ret; } -static MagickBooleanType ExtendOperatorStack (FxInfo * pfx) -{ - pfx->numOprStack = (int) ceil (pfx->numOprStack * (1 + 0.1)); - pfx->OperatorStack = (OperatorE*) ResizeMagickMemory (pfx->OperatorStack, pfx->numOprStack * sizeof(OperatorE)); +static MagickBooleanType ExtendOperatorStack(FxInfo *pfx) { + pfx->numOprStack = (int)ceil(pfx->numOprStack * (1 + 0.1)); + pfx->OperatorStack = (OperatorE *)ResizeMagickMemory( + pfx->OperatorStack, pfx->numOprStack * sizeof(OperatorE)); if (!pfx->OperatorStack) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1334, ResourceLimitFatalError, - "OprStack", "%i", - pfx->numOprStack); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1334, ResourceLimitFatalError, + "OprStack", "%i", pfx->numOprStack); return MagickFalse; } return MagickTrue; } -static MagickBooleanType PushOperatorStack (FxInfo * pfx, int op) -{ +static MagickBooleanType PushOperatorStack(FxInfo *pfx, int op) { if (++pfx->usedOprStack >= pfx->numOprStack) { - if (!ExtendOperatorStack (pfx)) + if (!ExtendOperatorStack(pfx)) return MagickFalse; } - pfx->OperatorStack[pfx->usedOprStack-1] = (OperatorE) op; + pfx->OperatorStack[pfx->usedOprStack - 1] = (OperatorE)op; if (pfx->maxUsedOprStack < pfx->usedOprStack) pfx->maxUsedOprStack = pfx->usedOprStack; return MagickTrue; } -static OperatorE GetLeadingOp (FxInfo * pfx) -{ +static OperatorE GetLeadingOp(FxInfo *pfx) { OperatorE op = oNull; - if (*pfx->pex == '-') op = oUnaryMinus; - else if (*pfx->pex == '+') op = oUnaryPlus; - else if (*pfx->pex == '~') op = oBitNot; - else if (*pfx->pex == '!') op = oLogNot; - else if (*pfx->pex == '(') op = oOpenParen; + if (*pfx->pex == '-') + op = oUnaryMinus; + else if (*pfx->pex == '+') + op = oUnaryPlus; + else if (*pfx->pex == '~') + op = oBitNot; + else if (*pfx->pex == '!') + op = oLogNot; + else if (*pfx->pex == '(') + op = oOpenParen; return op; } -static MagickBooleanType inline OprIsUnaryPrefix (OperatorE op) -{ - return (op == oUnaryMinus || op == oUnaryPlus || op == oBitNot || op == oLogNot ? MagickTrue : MagickFalse); +static MagickBooleanType inline OprIsUnaryPrefix(OperatorE op) { + return (op == oUnaryMinus || op == oUnaryPlus || op == oBitNot || + op == oLogNot + ? MagickTrue + : MagickFalse); } -static MagickBooleanType TopOprIsUnaryPrefix (FxInfo * pfx) -{ - if (!pfx->usedOprStack) return MagickFalse; +static MagickBooleanType TopOprIsUnaryPrefix(FxInfo *pfx) { + if (!pfx->usedOprStack) + return MagickFalse; - return OprIsUnaryPrefix (pfx->OperatorStack[pfx->usedOprStack-1]); + return OprIsUnaryPrefix(pfx->OperatorStack[pfx->usedOprStack - 1]); } -static MagickBooleanType PopOprOpenParen (FxInfo * pfx, OperatorE op) -{ +static MagickBooleanType PopOprOpenParen(FxInfo *pfx, OperatorE op) { - if (!pfx->usedOprStack) return MagickFalse; + if (!pfx->usedOprStack) + return MagickFalse; - if (pfx->OperatorStack[pfx->usedOprStack-1] != op) return MagickFalse; + if (pfx->OperatorStack[pfx->usedOprStack - 1] != op) + return MagickFalse; pfx->usedOprStack--; return MagickTrue; } -static int GetCoordQualifier (FxInfo * pfx, int op) - +static int GetCoordQualifier(FxInfo *pfx, int op) { - if (op != fU && op != fV && op != fS) return -1; + if (op != fU && op != fV && op != fS) + return -1; - (void) GetToken (pfx); + (void)GetToken(pfx); if (pfx->lenToken != 1) { return -1; } - if (*pfx->token != 'p' && *pfx->token != 'P') return -1; - if (!GetFunction (pfx, fP)) return -1; + if (*pfx->token != 'p' && *pfx->token != 'P') + return -1; + if (!GetFunction(pfx, fP)) + return -1; return 1; } -static PixelChannel GetChannelQualifier (FxInfo * pfx, int op) -{ - if (op == fU || op == fV || op == fP || - op == fUP || op == fVP || - op == fS || (op >= ((ImgAttrE) (fNull+1)) && op <= aNull) - ) - { - const ChannelT * pch = &Channels[0]; - (void) GetToken (pfx); +static PixelChannel GetChannelQualifier(FxInfo *pfx, int op) { + if (op == fU || op == fV || op == fP || op == fUP || op == fVP || op == fS || + (op >= ((ImgAttrE)(fNull + 1)) && op <= aNull)) { + const ChannelT *pch = &Channels[0]; + (void)GetToken(pfx); while (*pch->str) { - if (LocaleCompare (pch->str, pfx->token)==0) { - - if (op >= ((ImgAttrE) (fNull+1)) && op <= (OperatorE)aNull && - ChanIsVirtual (pch->pixChan) - ) - { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1427, OptionError, - "Can't have image attribute with channel qualifier at", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); - return ((PixelChannel) (-1)); + if (LocaleCompare(pch->str, pfx->token) == 0) { + + if (op >= ((ImgAttrE)(fNull + 1)) && op <= (OperatorE)aNull && + ChanIsVirtual(pch->pixChan)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1427, + OptionError, + "Can't have image attribute with channel qualifier at", + "'%s' at '%s'", pfx->token, SetShortExp(pfx)); + return ((PixelChannel)(-1)); } pfx->pex += pfx->lenToken; @@ -18734,212 +15033,200 @@ static PixelChannel GetChannelQualifier (FxInfo * pfx, int op) pch++; } } - return ((PixelChannel) (-1)); + return ((PixelChannel)(-1)); } -static ImgAttrE GetImgAttrToken (FxInfo * pfx) -{ +static ImgAttrE GetImgAttrToken(FxInfo *pfx) { ImgAttrE ia = aNull; - const char * iaStr; - for (ia = ((ImgAttrE) (fNull+1)); ia < aNull; ia=(ImgAttrE) (ia+1)) { - iaStr = ImgAttrs[ia-((ImgAttrE) (fNull+1))].str; - if (LocaleCompare (iaStr, pfx->token)==0) { + const char *iaStr; + for (ia = ((ImgAttrE)(fNull + 1)); ia < aNull; ia = (ImgAttrE)(ia + 1)) { + iaStr = ImgAttrs[ia - ((ImgAttrE)(fNull + 1))].str; + if (LocaleCompare(iaStr, pfx->token) == 0) { pfx->pex += strlen(pfx->token); - if (ImgAttrs[ia-((ImgAttrE) (fNull+1))].NeedStats == 1) pfx->NeedStats = MagickTrue; - MaybeXYWH (pfx, &ia); + if (ImgAttrs[ia - ((ImgAttrE)(fNull + 1))].NeedStats == 1) + pfx->NeedStats = MagickTrue; + MaybeXYWH(pfx, &ia); break; } } if (ia == aPage || ia == aPrintsize || ia == aRes) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1458, OptionError, - "Attribute", "'%s' needs qualifier at '%s'", - iaStr, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1458, OptionError, "Attribute", + "'%s' needs qualifier at '%s'", iaStr, + SetShortExp(pfx)); } return ia; } -static ImgAttrE GetImgAttrQualifier (FxInfo * pfx, int op) -{ +static ImgAttrE GetImgAttrQualifier(FxInfo *pfx, int op) { ImgAttrE ia = aNull; - if (op == (OperatorE)fU || op == (OperatorE)fV || op == (OperatorE)fP || op == (OperatorE)fS) { - (void) GetToken (pfx); + if (op == (OperatorE)fU || op == (OperatorE)fV || op == (OperatorE)fP || + op == (OperatorE)fS) { + (void)GetToken(pfx); if (pfx->lenToken == 0) { return aNull; } - ia = GetImgAttrToken (pfx); + ia = GetImgAttrToken(pfx); } return ia; } -static MagickBooleanType IsQualifier (FxInfo * pfx) -{ - if (PeekChar (pfx) == '.') { +static MagickBooleanType IsQualifier(FxInfo *pfx) { + if (PeekChar(pfx) == '.') { pfx->pex++; return MagickTrue; } return MagickFalse; } -static ssize_t GetProperty (FxInfo * pfx, fxFltType *val) - - - +static ssize_t GetProperty(FxInfo *pfx, fxFltType *val) { - if (PeekStr (pfx, "%[")) { + if (PeekStr(pfx, "%[")) { int level = 0; size_t len; - char sProperty [4096]; - char * p = pfx->pex + 2; + char sProperty[4096]; + char *p = pfx->pex + 2; while (*p) { - if (*p == '[') level++; + if (*p == '[') + level++; else if (*p == ']') { - if (level == 0) break; + if (level == 0) + break; level--; } p++; } if (!*p || level != 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1511, OptionError, - "After '%[' expected ']' at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1511, + OptionError, "After '%[' expected ']' at", "'%s'", SetShortExp(pfx)); return -1; } - len = (size_t) (p - pfx->pex + 1); + len = (size_t)(p - pfx->pex + 1); if (len > 100) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1520, OptionError, - "Too much text between '%[' and ']' at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1520, OptionError, + "Too much text between '%[' and ']' at", + "'%s'", SetShortExp(pfx)); return -1; } - (void) CopyMagickString (sProperty, pfx->pex, len+1); + (void)CopyMagickString(sProperty, pfx->pex, len + 1); sProperty[len] = '\0'; { - char * tailptr; - char * text; - text = InterpretImageProperties (pfx->image->image_info, pfx->image, - sProperty, pfx->exception); + char *tailptr; + char *text; + text = InterpretImageProperties(pfx->image->image_info, pfx->image, + sProperty, pfx->exception); if (!text || !*text) { text = DestroyString(text); - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1536, OptionError, - "Unknown property", "'%s' at '%s'", - sProperty, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1536, OptionError, + "Unknown property", "'%s' at '%s'", + sProperty, SetShortExp(pfx)); return -1; } - *val = strtold (text, &tailptr); + *val = strtold(text, &tailptr); if (text == tailptr) { text = DestroyString(text); - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1546, OptionError, - "Property", "'%s' text '%s' is not a number at '%s'", - sProperty, text, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1546, OptionError, "Property", + "'%s' text '%s' is not a number at '%s'", + sProperty, text, SetShortExp(pfx)); return -1; } text = DestroyString(text); } - return ((ssize_t) len); - } - - return 0; -} - -static ssize_t inline GetConstantColour (FxInfo * pfx, fxFltType *v0, fxFltType *v1, fxFltType *v2) - - + return ((ssize_t)len); + } + return 0; +} +static ssize_t inline GetConstantColour(FxInfo *pfx, fxFltType *v0, + fxFltType *v1, fxFltType *v2) { - PixelInfo - colour; + PixelInfo colour; - ExceptionInfo - *dummy_exception = AcquireExceptionInfo (); + ExceptionInfo *dummy_exception = AcquireExceptionInfo(); - char - *p; + char *p; - MagickBooleanType - IsGray, - IsIcc, - IsDev; + MagickBooleanType IsGray, IsIcc, IsDev; char ColSp[4096]; - (void) CopyMagickString (ColSp, pfx->token, 100); + (void)CopyMagickString(ColSp, pfx->token, 100); p = ColSp + pfx->lenToken - 1; - if (*p == 'a' || *p == 'A') *p = '\0'; - - (void) GetPixelInfo (pfx->image, &colour); - - - - IsGray = (LocaleCompare (ColSp, "gray") == 0) ? MagickTrue : MagickFalse; - IsIcc = (LocaleCompare (ColSp, "icc-color") == 0) ? MagickTrue : MagickFalse; - IsDev = (LocaleNCompare (ColSp, "device-", 7) == 0) ? MagickTrue : MagickFalse; + if (*p == 'a' || *p == 'A') + *p = '\0'; + (void)GetPixelInfo(pfx->image, &colour); + IsGray = (LocaleCompare(ColSp, "gray") == 0) ? MagickTrue : MagickFalse; + IsIcc = (LocaleCompare(ColSp, "icc-color") == 0) ? MagickTrue : MagickFalse; + IsDev = (LocaleNCompare(ColSp, "device-", 7) == 0) ? MagickTrue : MagickFalse; - if (!QueryColorCompliance (pfx->token, AllCompliance, &colour, dummy_exception) || IsGray) { - ssize_t type = ParseCommandOption (MagickColorspaceOptions, MagickFalse, ColSp); + if (!QueryColorCompliance(pfx->token, AllCompliance, &colour, + dummy_exception) || + IsGray) { + ssize_t type = + ParseCommandOption(MagickColorspaceOptions, MagickFalse, ColSp); if (type >= 0 || IsIcc || IsDev) { - char * q = pfx->pex + pfx->lenToken; - while ( - ((*__ctype_b_loc ())[(int) (( - (int) ((unsigned char) *q) - ))] & (unsigned short int) _ISspace) - ) q++; + char *q = pfx->pex + pfx->lenToken; + while (((*__ctype_b_loc())[(int)(((int)((unsigned char)*q)))] & + (unsigned short int)_ISspace)) + q++; if (*q == '(') { size_t lenfun; char sFunc[4096]; - while (*q && *q != ')') q++; + while (*q && *q != ')') + q++; if (!*q) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1607, OptionError, - "constant color missing ')'", "at '%s'", - SetShortExp(pfx)); - dummy_exception = DestroyExceptionInfo (dummy_exception); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)1607, OptionError, + "constant color missing ')'", "at '%s'", + SetShortExp(pfx)); + dummy_exception = DestroyExceptionInfo(dummy_exception); return -1; } - lenfun = (size_t) (q - pfx->pex + 1); + lenfun = (size_t)(q - pfx->pex + 1); if (lenfun > 100) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1616, OptionError, - "lenfun too long", "'%lu' at '%s'", - (unsigned long) lenfun, SetShortExp(pfx)); - dummy_exception = DestroyExceptionInfo (dummy_exception); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)1616, OptionError, + "lenfun too long", "'%lu' at '%s'", + (unsigned long)lenfun, SetShortExp(pfx)); + dummy_exception = DestroyExceptionInfo(dummy_exception); return -1; } - (void) CopyMagickString (sFunc, pfx->pex, lenfun+1); - if (QueryColorCompliance (sFunc, AllCompliance, &colour, dummy_exception)) { + (void)CopyMagickString(sFunc, pfx->pex, lenfun + 1); + if (QueryColorCompliance(sFunc, AllCompliance, &colour, + dummy_exception)) { *v0 = colour.red / 65535.0f; *v1 = colour.green / 65535.0f; *v2 = colour.blue / 65535.0f; - dummy_exception = DestroyExceptionInfo (dummy_exception); + dummy_exception = DestroyExceptionInfo(dummy_exception); return (ssize_t)lenfun; } } else { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1632, OptionError, - "colorspace but not a valid color with '(...)' at", "'%s'", - SetShortExp(pfx)); - dummy_exception = DestroyExceptionInfo (dummy_exception); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1632, + OptionError, "colorspace but not a valid color with '(...)' at", + "'%s'", SetShortExp(pfx)); + dummy_exception = DestroyExceptionInfo(dummy_exception); return -1; } } if (!IsGray) { - dummy_exception = DestroyExceptionInfo (dummy_exception); + dummy_exception = DestroyExceptionInfo(dummy_exception); return 0; } } @@ -18948,58 +15235,50 @@ static ssize_t inline GetConstantColour (FxInfo * pfx, fxFltType *v0, fxFltType *v1 = colour.green / 65535.0f; *v2 = colour.blue / 65535.0f; - dummy_exception = DestroyExceptionInfo (dummy_exception); - return (ssize_t)strlen (pfx->token); + dummy_exception = DestroyExceptionInfo(dummy_exception); + return (ssize_t)strlen(pfx->token); } -static ssize_t inline GetHexColour (FxInfo * pfx, fxFltType *v0, fxFltType *v1, fxFltType *v2) - - +static ssize_t inline GetHexColour(FxInfo *pfx, fxFltType *v0, fxFltType *v1, + fxFltType *v2) { - char * p; + char *p; size_t len; PixelInfo colour; - if (*pfx->pex != '#') return 0; - + if (*pfx->pex != '#') + return 0; p = pfx->pex + 1; - while ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISxdigit) - ) p++; - if ( - ((*__ctype_b_loc ())[(int) (( - (int)*p - ))] & (unsigned short int) _ISalpha) - ) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1669, OptionError, - "Bad hex number at", "'%s'", - SetShortExp(pfx)); + while (((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISxdigit)) + p++; + if (((*__ctype_b_loc())[(int)(((int)*p))] & (unsigned short int)_ISalpha)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1669, OptionError, + "Bad hex number at", "'%s'", SetShortExp(pfx)); return -1; } - len = (size_t) (p - pfx->pex); - if (len < 1) return 0; + len = (size_t)(p - pfx->pex); + if (len < 1) + return 0; if (len >= 100) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1679, OptionError, - "Hex colour too long at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1679, + OptionError, "Hex colour too long at", "'%s'", SetShortExp(pfx)); return -1; } - (void) CopyMagickString (pfx->token, pfx->pex, len+1); + (void)CopyMagickString(pfx->token, pfx->pex, len + 1); - (void) GetPixelInfo (pfx->image, &colour); + (void)GetPixelInfo(pfx->image, &colour); - if (!QueryColorCompliance (pfx->token, AllCompliance, &colour, pfx->exception)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1690, OptionError, - "QueryColorCompliance rejected", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + if (!QueryColorCompliance(pfx->token, AllCompliance, &colour, + pfx->exception)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1690, OptionError, + "QueryColorCompliance rejected", "'%s' at '%s'", + pfx->token, SetShortExp(pfx)); return -1; } @@ -19007,21 +15286,19 @@ static ssize_t inline GetHexColour (FxInfo * pfx, fxFltType *v0, fxFltType *v1, *v1 = colour.green / 65535.0f; *v2 = colour.blue / 65535.0f; - return (ssize_t) len; + return (ssize_t)len; } -static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) -{ - +static MagickBooleanType GetFunction(FxInfo *pfx, FunctionE fe) { - const char * funStr = Functions[fe-((FunctionE) (oNull+1))].str; - int nArgs = Functions[fe-((FunctionE) (oNull+1))].nArgs; + const char *funStr = Functions[fe - ((FunctionE)(oNull + 1))].str; + int nArgs = Functions[fe - ((FunctionE)(oNull + 1))].nArgs; char chLimit = ')'; char expChLimit = ')'; const char *strLimit = ",)"; OperatorE pushOp = oOpenParen; - char * pExpStart; + char *pExpStart; int lenExp = 0; @@ -19029,21 +15306,21 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) int ndx0 = -2, ndx1 = -2, ndx2 = -2, ndx3 = -2; MagickBooleanType coordQual = MagickFalse; - PixelChannel chQual = ((PixelChannel) (-1)); + PixelChannel chQual = ((PixelChannel)(-1)); ImgAttrE iaQual = aNull; pfx->pex += pfx->lenToken; if (fe == fP) { - char p = PeekChar (pfx); - if (p=='{') { - (void) ExpectChar (pfx, '{'); + char p = PeekChar(pfx); + if (p == '{') { + (void)ExpectChar(pfx, '{'); pushOp = oOpenBrace; strLimit = ",}"; chLimit = '}'; expChLimit = '}'; - } else if (p=='[') { - (void) ExpectChar (pfx, '['); + } else if (p == '[') { + (void)ExpectChar(pfx, '['); pushOp = oOpenBracket; strLimit = ",]"; chLimit = ']'; @@ -19054,9 +15331,9 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) expChLimit = ']'; } } else if (fe == fU) { - char p = PeekChar (pfx); - if (p=='[') { - (void) ExpectChar (pfx, '['); + char p = PeekChar(pfx); + if (p == '[') { + (void)ExpectChar(pfx, '['); pushOp = oOpenBracket; strLimit = ",]"; chLimit = ']'; @@ -19067,40 +15344,42 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) expChLimit = ']'; } } else if (fe == fV || fe == fS) { - nArgs = 0; - pushOp = oOpenBracket; - chLimit = ']'; - expChLimit = ']'; + nArgs = 0; + pushOp = oOpenBracket; + chLimit = ']'; + expChLimit = ']'; } else { - if (!ExpectChar (pfx, '(')) return MagickFalse; + if (!ExpectChar(pfx, '(')) + return MagickFalse; } - if (!PushOperatorStack (pfx, pushOp)) return MagickFalse; + if (!PushOperatorStack(pfx, pushOp)) + return MagickFalse; pExpStart = pfx->pex; ndx0 = pfx->usedElements; - if (fe==fDo) { - (void) AddAddressingElement (pfx, rGoto, -2); + if (fe == fDo) { + (void)AddAddressingElement(pfx, rGoto, -2); } while (nArgs > 0) { int FndOne = 0; - if (TranslateStatementList (pfx, strLimit, &chLimit)) { + if (TranslateStatementList(pfx, strLimit, &chLimit)) { FndOne = 1; } else { - if (!chLimit) break; - if (fe == fP || fe == fS|| fe == fIf) { - (void) AddElement (pfx, (fxFltType) 0, oNull); + if (!chLimit) + break; + if (fe == fP || fe == fS || fe == fIf) { + (void)AddElement(pfx, (fxFltType)0, oNull); FndOne = 1; } } - if (strchr (strLimit, chLimit)== - ((void *)0) - ) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1789, OptionError, - "For function", "'%s' expected one of '%s' after expression but found '%c' at '%s'", - funStr, strLimit, chLimit ? chLimit : ' ', SetShortExp(pfx)); + if (strchr(strLimit, chLimit) == ((void *)0)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1789, + OptionError, "For function", + "'%s' expected one of '%s' after expression but found '%c' at '%s'", + funStr, strLimit, chLimit ? chLimit : ' ', SetShortExp(pfx)); return MagickFalse; } if (FndOne) { @@ -19108,250 +15387,266 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) nArgs--; } switch (FndArgs) { - case 1: - if (ndx1 != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1802, OptionError, - "For function", "'%s' required argument is missing at '%s'", - funStr, SetShortExp(pfx)); - return MagickFalse; - } - ndx1 = pfx->usedElements; - if (fe==fWhile) { - (void) AddAddressingElement (pfx, rIfZeroGoto, -2); - } else if (fe==fDo) { - (void) AddAddressingElement (pfx, rIfZeroGoto, -2); - } else if (fe==fFor) { - pfx->Elements[pfx->usedElements-1].DoPush = MagickFalse; - } else if (fe==fIf) { - (void) AddAddressingElement (pfx, rIfZeroGoto, -2); - pfx->Elements[pfx->usedElements-1].DoPush = MagickTrue; - } - break; - case 2: - if (ndx2 != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1822, OptionError, - "For function", "'%s' required argument is missing at '%s'", - funStr, SetShortExp(pfx)); - return MagickFalse; - } - ndx2 = pfx->usedElements; - if (fe==fWhile) { - pfx->Elements[pfx->usedElements-1].DoPush = MagickFalse; - (void) AddAddressingElement (pfx, rGoto, ndx0); - } else if (fe==fDo) { - pfx->Elements[pfx->usedElements-1].DoPush = MagickFalse; - (void) AddAddressingElement (pfx, rGoto, ndx0 + 1); - } else if (fe==fFor) { - (void) AddAddressingElement (pfx, rIfZeroGoto, -2); - pfx->Elements[pfx->usedElements-1].DoPush = MagickTrue; - (void) AddAddressingElement (pfx, rZerStk, -2); - } else if (fe==fIf) { - (void) AddAddressingElement (pfx, rGoto, -2); - } - break; - case 3: - if (ndx3 != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1845, OptionError, - "For function", "'%s' required argument is missing at '%s'", - funStr, SetShortExp(pfx)); - return MagickFalse; - } - if (fe==fFor) { - pfx->Elements[pfx->usedElements-1].DoPush = MagickFalse; - (void) AddAddressingElement (pfx, rGoto, ndx1); - } - ndx3 = pfx->usedElements; - break; - default: - break; + case 1: + if (ndx1 != -2) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1802, OptionError, + "For function", + "'%s' required argument is missing at '%s'", + funStr, SetShortExp(pfx)); + return MagickFalse; + } + ndx1 = pfx->usedElements; + if (fe == fWhile) { + (void)AddAddressingElement(pfx, rIfZeroGoto, -2); + } else if (fe == fDo) { + (void)AddAddressingElement(pfx, rIfZeroGoto, -2); + } else if (fe == fFor) { + pfx->Elements[pfx->usedElements - 1].DoPush = MagickFalse; + } else if (fe == fIf) { + (void)AddAddressingElement(pfx, rIfZeroGoto, -2); + pfx->Elements[pfx->usedElements - 1].DoPush = MagickTrue; + } + break; + case 2: + if (ndx2 != -2) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1822, OptionError, + "For function", + "'%s' required argument is missing at '%s'", + funStr, SetShortExp(pfx)); + return MagickFalse; + } + ndx2 = pfx->usedElements; + if (fe == fWhile) { + pfx->Elements[pfx->usedElements - 1].DoPush = MagickFalse; + (void)AddAddressingElement(pfx, rGoto, ndx0); + } else if (fe == fDo) { + pfx->Elements[pfx->usedElements - 1].DoPush = MagickFalse; + (void)AddAddressingElement(pfx, rGoto, ndx0 + 1); + } else if (fe == fFor) { + (void)AddAddressingElement(pfx, rIfZeroGoto, -2); + pfx->Elements[pfx->usedElements - 1].DoPush = MagickTrue; + (void)AddAddressingElement(pfx, rZerStk, -2); + } else if (fe == fIf) { + (void)AddAddressingElement(pfx, rGoto, -2); + } + break; + case 3: + if (ndx3 != -2) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1845, OptionError, + "For function", + "'%s' required argument is missing at '%s'", + funStr, SetShortExp(pfx)); + return MagickFalse; + } + if (fe == fFor) { + pfx->Elements[pfx->usedElements - 1].DoPush = MagickFalse; + (void)AddAddressingElement(pfx, rGoto, ndx1); + } + ndx3 = pfx->usedElements; + break; + default: + break; } if (chLimit == expChLimit) { lenExp = pfx->pex - pExpStart - 1; break; } } - if (chLimit && chLimit != expChLimit && chLimit != ',' ) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1866, OptionError, - "For function", "'%s' expected '%c', found '%c' at '%s'", - funStr, expChLimit, chLimit ? chLimit : ' ', SetShortExp(pfx)); + if (chLimit && chLimit != expChLimit && chLimit != ',') { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1866, + OptionError, "For function", "'%s' expected '%c', found '%c' at '%s'", + funStr, expChLimit, chLimit ? chLimit : ' ', SetShortExp(pfx)); return MagickFalse; } if (fe == fP || fe == fS || fe == fU || fe == fChannel) { - while (FndArgs < Functions[fe-((FunctionE) (oNull+1))].nArgs) { - (void) AddElement (pfx, (fxFltType) 0, oNull); + while (FndArgs < Functions[fe - ((FunctionE)(oNull + 1))].nArgs) { + (void)AddElement(pfx, (fxFltType)0, oNull); FndArgs++; } } - if (FndArgs > Functions[fe-((FunctionE) (oNull+1))].nArgs) - { - if (fe==fChannel) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1883, OptionError, - "For function", "'%s' expected up to %i arguments, found '%i' at '%s'", - funStr, Functions[fe-((FunctionE) (oNull+1))].nArgs, FndArgs, SetShortExp(pfx)); + if (FndArgs > Functions[fe - ((FunctionE)(oNull + 1))].nArgs) { + if (fe == fChannel) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1883, + OptionError, "For function", + "'%s' expected up to %i arguments, found '%i' at '%s'", funStr, + Functions[fe - ((FunctionE)(oNull + 1))].nArgs, FndArgs, + SetShortExp(pfx)); } else { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1888, OptionError, - "For function", "'%s' expected %i arguments, found '%i' at '%s'", - funStr, Functions[fe-((FunctionE) (oNull+1))].nArgs, FndArgs, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1888, + OptionError, "For function", + "'%s' expected %i arguments, found '%i' at '%s'", funStr, + Functions[fe - ((FunctionE)(oNull + 1))].nArgs, FndArgs, + SetShortExp(pfx)); } return MagickFalse; } - if (FndArgs < Functions[fe-((FunctionE) (oNull+1))].nArgs) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1896, OptionError, - "For function", "'%s' expected %i arguments, found too few (%i) at '%s'", - funStr, Functions[fe-((FunctionE) (oNull+1))].nArgs, FndArgs, SetShortExp(pfx)); + if (FndArgs < Functions[fe - ((FunctionE)(oNull + 1))].nArgs) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1896, + OptionError, "For function", + "'%s' expected %i arguments, found too few (%i) at '%s'", funStr, + Functions[fe - ((FunctionE)(oNull + 1))].nArgs, FndArgs, + SetShortExp(pfx)); return MagickFalse; } - if (fe != fS && fe != fV && FndArgs == 0 && Functions[fe-((FunctionE) (oNull+1))].nArgs == 0) { + if (fe != fS && fe != fV && FndArgs == 0 && + Functions[fe - ((FunctionE)(oNull + 1))].nArgs == 0) { chLimit = expChLimit; - if (!ExpectChar (pfx, ')')) return MagickFalse; + if (!ExpectChar(pfx, ')')) + return MagickFalse; } if (chLimit != expChLimit) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1909, OptionError, - "For function", "'%s', arguments don't end with '%c' at '%s'", - funStr, expChLimit, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1909, OptionError, "For function", + "'%s', arguments don't end with '%c' at '%s'", + funStr, expChLimit, SetShortExp(pfx)); return MagickFalse; } - if (!PopOprOpenParen (pfx, pushOp)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1916, OptionError, - "Bug: For function", "'%s' tos not '%s' at '%s'", - funStr, Operators[pushOp].str, SetShortExp(pfx)); + if (!PopOprOpenParen(pfx, pushOp)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1916, OptionError, + "Bug: For function", "'%s' tos not '%s' at '%s'", + funStr, Operators[pushOp].str, SetShortExp(pfx)); return MagickFalse; } - if (IsQualifier (pfx)) { + if (IsQualifier(pfx)) { if (fe == fU || fe == fV || fe == fS) { - coordQual = (GetCoordQualifier (pfx, fe) == 1) ? MagickTrue : MagickFalse; + coordQual = (GetCoordQualifier(pfx, fe) == 1) ? MagickTrue : MagickFalse; if (coordQual) { - - ElementT * pel = &pfx->Elements[pfx->usedElements-1]; + ElementT *pel = &pfx->Elements[pfx->usedElements - 1]; if (pel->oprNum != fP) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1934, OptionError, - "Bug: For function", "'%s' last element not 'p' at '%s'", - funStr, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1934, + OptionError, "Bug: For function", + "'%s' last element not 'p' at '%s'", funStr, SetShortExp(pfx)); return MagickFalse; } chQual = pel->ChannelQual; expChLimit = (pel->IsRelative) ? ']' : '}'; pfx->usedElements--; - if (fe == fU) fe = fUP; - else if (fe == fV) fe = fVP; - else if (fe == fS) fe = fSP; - funStr = Functions[fe-((FunctionE) (oNull+1))].str; + if (fe == fU) + fe = fUP; + else if (fe == fV) + fe = fVP; + else if (fe == fS) + fe = fSP; + funStr = Functions[fe - ((FunctionE)(oNull + 1))].str; } } - if ( chQual == ((PixelChannel) (-1)) && - (fe == fP || fe == fS || fe == fSP || fe == fU || fe == fUP || fe == fV || fe == fVP) - ) - { - chQual = GetChannelQualifier (pfx, fe); + if (chQual == ((PixelChannel)(-1)) && + (fe == fP || fe == fS || fe == fSP || fe == fU || fe == fUP || + fe == fV || fe == fVP)) { + chQual = GetChannelQualifier(pfx, fe); } - if (chQual == ((PixelChannel) (-1)) && (fe == fU || fe == fV || fe == fS)) { + if (chQual == ((PixelChannel)(-1)) && (fe == fU || fe == fV || fe == fS)) { - iaQual = GetImgAttrQualifier (pfx, fe); + iaQual = GetImgAttrQualifier(pfx, fe); } - if (IsQualifier (pfx) && chQual == ((PixelChannel) (-1)) && iaQual != aNull) { - chQual = GetChannelQualifier (pfx, fe); + if (IsQualifier(pfx) && chQual == ((PixelChannel)(-1)) && iaQual != aNull) { + chQual = GetChannelQualifier(pfx, fe); } if (coordQual && iaQual != aNull) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1965, OptionError, - "For function", "'%s', can't have qualifiers 'p' and image attribute '%s' at '%s'", - funStr, pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1965, + OptionError, "For function", + "'%s', can't have qualifiers 'p' and image attribute '%s' at '%s'", + funStr, pfx->token, SetShortExp(pfx)); return MagickFalse; } - if (!coordQual && chQual == ((PixelChannel) (-1)) && iaQual == aNull) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1972, OptionError, - "For function", "'%s', bad qualifier '%s' at '%s'", - funStr, pfx->token, SetShortExp(pfx)); + if (!coordQual && chQual == ((PixelChannel)(-1)) && iaQual == aNull) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1972, + OptionError, "For function", "'%s', bad qualifier '%s' at '%s'", + funStr, pfx->token, SetShortExp(pfx)); return MagickFalse; } if (!coordQual && chQual == CompositePixelChannel && iaQual == aNull) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1979, OptionError, - "For function", "'%s', bad composite qualifier '%s' at '%s'", - funStr, pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)1979, OptionError, + "For function", + "'%s', bad composite qualifier '%s' at '%s'", + funStr, pfx->token, SetShortExp(pfx)); return MagickFalse; } - if (chQual == ((PixelChannel) (-3)) || chQual == ((PixelChannel) (-4)) || chQual == ((PixelChannel) (-5))) { + if (chQual == ((PixelChannel)(-3)) || chQual == ((PixelChannel)(-4)) || + chQual == ((PixelChannel)(-5))) { pfx->NeedHsl = MagickTrue; - if (iaQual >= ((ImgAttrE) (fNull+1)) && iaQual < aNull) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 1990, OptionError, - "Can't have image attribute with HLS qualifier at", "'%s'", - SetShortExp(pfx)); + if (iaQual >= ((ImgAttrE)(fNull + 1)) && iaQual < aNull) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)1990, + OptionError, "Can't have image attribute with HLS qualifier at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } } } - if (iaQual != aNull && chQual != ((PixelChannel) (-1))) { - if (ImgAttrs[iaQual-((ImgAttrE) (fNull+1))].NeedStats==0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2001, OptionError, - "Can't have image attribute ", "'%s' with channel qualifier '%s' at '%s'", - ImgAttrs[iaQual-((ImgAttrE) (fNull+1))].str, - pfx->token, SetShortExp(pfx)); + if (iaQual != aNull && chQual != ((PixelChannel)(-1))) { + if (ImgAttrs[iaQual - ((ImgAttrE)(fNull + 1))].NeedStats == 0) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2001, OptionError, + "Can't have image attribute ", + "'%s' with channel qualifier '%s' at '%s'", + ImgAttrs[iaQual - ((ImgAttrE)(fNull + 1))].str, + pfx->token, SetShortExp(pfx)); return MagickFalse; } else { - if (ChanIsVirtual (chQual)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2009, OptionError, - "Can't have statistical image attribute ", "'%s' with virtual channel qualifier '%s' at '%s'", - ImgAttrs[iaQual-((ImgAttrE) (fNull+1))].str, - pfx->token, SetShortExp(pfx)); + if (ChanIsVirtual(chQual)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2009, + OptionError, "Can't have statistical image attribute ", + "'%s' with virtual channel qualifier '%s' at '%s'", + ImgAttrs[iaQual - ((ImgAttrE)(fNull + 1))].str, pfx->token, + SetShortExp(pfx)); return MagickFalse; } } } - if (fe==fWhile) { - pfx->Elements[ndx1].EleNdx = ndx2+1; - } else if (fe==fDo) { - pfx->Elements[ndx0].EleNdx = ndx1+1; - pfx->Elements[ndx1].EleNdx = ndx2+1; - } else if (fe==fFor) { + if (fe == fWhile) { + pfx->Elements[ndx1].EleNdx = ndx2 + 1; + } else if (fe == fDo) { + pfx->Elements[ndx0].EleNdx = ndx1 + 1; + pfx->Elements[ndx1].EleNdx = ndx2 + 1; + } else if (fe == fFor) { pfx->Elements[ndx2].EleNdx = ndx3; - } else if (fe==fIf) { + } else if (fe == fIf) { pfx->Elements[ndx1].EleNdx = ndx2 + 1; pfx->Elements[ndx2].EleNdx = ndx3; } else { if (fe == fU && iaQual == aNull) { - ElementT * pel = &pfx->Elements[pfx->usedElements-1]; + ElementT *pel = &pfx->Elements[pfx->usedElements - 1]; if (pel->type == etConstant && pel->val == 0.0) { pfx->usedElements--; fe = fU0; } } - (void) AddElement (pfx, (fxFltType) 0, fe); - if (fe == fP || fe == fU || fe == fU0 || fe == fUP || - fe == fV || fe == fVP || fe == fS || fe == fSP) - { - ElementT * pel = &pfx->Elements[pfx->usedElements-1]; + (void)AddElement(pfx, (fxFltType)0, fe); + if (fe == fP || fe == fU || fe == fU0 || fe == fUP || fe == fV || + fe == fVP || fe == fS || fe == fSP) { + ElementT *pel = &pfx->Elements[pfx->usedElements - 1]; pel->IsRelative = (expChLimit == ']' ? MagickTrue : MagickFalse); - if (chQual >= 0) pel->ChannelQual = chQual; + if (chQual >= 0) + pel->ChannelQual = chQual; if (iaQual != aNull && (fe == fU || fe == fV || fe == fS)) { pel->ImgAttrQual = iaQual; @@ -19360,7 +15655,7 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) } if (pExpStart && lenExp) { - ElementT * pel = &pfx->Elements[pfx->usedElements-1]; + ElementT *pel = &pfx->Elements[pfx->usedElements - 1]; pel->pExpStart = pExpStart; pel->lenExp = lenExp; } @@ -19371,223 +15666,218 @@ static MagickBooleanType GetFunction (FxInfo * pfx, FunctionE fe) return MagickTrue; } -static MagickBooleanType IsStealth (int op) -{ +static MagickBooleanType IsStealth(int op) { return (op == fU0 || op == fUP || op == fSP || op == fVP || - (op >= (sNull+1) && op <= rNull) ? MagickTrue : MagickFalse - ); + (op >= (sNull + 1) && op <= rNull) + ? MagickTrue + : MagickFalse); } -static MagickBooleanType GetOperand ( - FxInfo * pfx, MagickBooleanType * UserSymbol, MagickBooleanType * NewUserSymbol, int * UserSymNdx, - MagickBooleanType * needPopAll) -{ +static MagickBooleanType GetOperand(FxInfo *pfx, MagickBooleanType *UserSymbol, + MagickBooleanType *NewUserSymbol, + int *UserSymNdx, + MagickBooleanType *needPopAll) { *NewUserSymbol = *UserSymbol = MagickFalse; *UserSymNdx = -2; - SkipSpaces (pfx); - if (!*pfx->pex) return MagickFalse; - (void) GetToken (pfx); - - if (pfx->lenToken==0) { - + SkipSpaces(pfx); + if (!*pfx->pex) + return MagickFalse; + (void)GetToken(pfx); + if (pfx->lenToken == 0) { - OperatorE op = GetLeadingOp (pfx); - if (op==oOpenParen) { + OperatorE op = GetLeadingOp(pfx); + if (op == oOpenParen) { char chLimit = '\0'; - if (!PushOperatorStack (pfx, op)) return MagickFalse; + if (!PushOperatorStack(pfx, op)) + return MagickFalse; pfx->pex++; - if (!TranslateExpression (pfx, ")", &chLimit, needPopAll)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2092, OptionError, - "Empty expression in parentheses at", "'%s'", - SetShortExp(pfx)); + if (!TranslateExpression(pfx, ")", &chLimit, needPopAll)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2092, OptionError, + "Empty expression in parentheses at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } if (chLimit != ')') { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2099, OptionError, - "'(' but no ')' at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2099, + OptionError, "'(' but no ')' at", "'%s'", SetShortExp(pfx)); return MagickFalse; } - if (!PopOprOpenParen (pfx, oOpenParen)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2107, OptionError, - "Bug: tos not '(' at", "'%s'", - SetShortExp(pfx)); + if (!PopOprOpenParen(pfx, oOpenParen)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2107, + OptionError, "Bug: tos not '(' at", "'%s'", SetShortExp(pfx)); return MagickFalse; } return MagickTrue; - } else if (OprIsUnaryPrefix (op)) { - if (!PushOperatorStack (pfx, op)) return MagickFalse; + } else if (OprIsUnaryPrefix(op)) { + if (!PushOperatorStack(pfx, op)) + return MagickFalse; pfx->pex++; - SkipSpaces (pfx); - if (!*pfx->pex) return MagickFalse; + SkipSpaces(pfx); + if (!*pfx->pex) + return MagickFalse; - if (!GetOperand (pfx, UserSymbol, NewUserSymbol, UserSymNdx, needPopAll)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2121, OptionError, - "After unary, bad operand at", "'%s'", - SetShortExp(pfx)); + if (!GetOperand(pfx, UserSymbol, NewUserSymbol, UserSymNdx, needPopAll)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2121, OptionError, + "After unary, bad operand at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } if (*NewUserSymbol) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2129, OptionError, - "After unary, NewUserSymbol at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2129, OptionError, + "After unary, NewUserSymbol at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } if (*UserSymbol) { - (void) AddAddressingElement (pfx, rCopyFrom, *UserSymNdx); + (void)AddAddressingElement(pfx, rCopyFrom, *UserSymNdx); *UserSymNdx = -2; *UserSymbol = MagickFalse; *NewUserSymbol = MagickFalse; } - (void) GetToken (pfx); + (void)GetToken(pfx); return MagickTrue; } else if (*pfx->pex == '#') { - fxFltType v0=0, v1=0, v2=0; - ssize_t lenToken = GetHexColour (pfx, &v0, &v1, &v2); + fxFltType v0 = 0, v1 = 0, v2 = 0; + ssize_t lenToken = GetHexColour(pfx, &v0, &v1, &v2); if (lenToken < 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2150, OptionError, - "Bad hex number at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2150, + OptionError, "Bad hex number at", "'%s'", SetShortExp(pfx)); return MagickFalse; } else if (lenToken > 0) { - (void) AddColourElement (pfx, v0, v1, v2); - pfx->pex+=lenToken; + (void)AddColourElement(pfx, v0, v1, v2); + pfx->pex += lenToken; } return MagickTrue; } - - { - char * tailptr; + char *tailptr; ssize_t lenOptArt; - fxFltType val = strtold (pfx->pex, &tailptr); + fxFltType val = strtold(pfx->pex, &tailptr); if (pfx->pex != tailptr) { pfx->pex = tailptr; if (*tailptr) { - - - double Pow = 0.0; const char Prefixes[] = "yzafpnum.kMGTPEZY"; - const char * pSi = strchr (Prefixes, *tailptr); - if (pSi && *pSi != '.') Pow = (pSi - Prefixes) * 3 - 24; - else if (*tailptr == 'c') Pow = -2; - else if (*tailptr == 'h') Pow = 2; - else if (*tailptr == 'k') Pow = 3; + const char *pSi = strchr(Prefixes, *tailptr); + if (pSi && *pSi != '.') + Pow = (pSi - Prefixes) * 3 - 24; + else if (*tailptr == 'c') + Pow = -2; + else if (*tailptr == 'h') + Pow = 2; + else if (*tailptr == 'k') + Pow = 3; if (Pow != 0.0) { if (*(++pfx->pex) == 'i') { - val *= pow (2.0, Pow/0.3); + val *= pow(2.0, Pow / 0.3); pfx->pex++; } else { - val *= pow (10.0, Pow); + val *= pow(10.0, Pow); } } } - (void) AddElement (pfx, val, oNull); + (void)AddElement(pfx, val, oNull); return MagickTrue; } - val = (fxFltType) 0; - lenOptArt = GetProperty (pfx, &val); - if (lenOptArt < 0) return MagickFalse; + val = (fxFltType)0; + lenOptArt = GetProperty(pfx, &val); + if (lenOptArt < 0) + return MagickFalse; if (lenOptArt > 0) { - (void) AddElement (pfx, val, oNull); + (void)AddElement(pfx, val, oNull); pfx->pex += lenOptArt; return MagickTrue; } } - } if (pfx->lenToken > 0) { - { ConstantE ce; - for (ce = (ConstantE)0; ce < cNull; ce=(ConstantE) (ce+1)) { - const char * ceStr = Constants[ce].str; - if (LocaleCompare (ceStr, pfx->token)==0) { + for (ce = (ConstantE)0; ce < cNull; ce = (ConstantE)(ce + 1)) { + const char *ceStr = Constants[ce].str; + if (LocaleCompare(ceStr, pfx->token) == 0) { break; } } if (ce != cNull) { - (void) AddElement (pfx, Constants[ce].val, oNull); + (void)AddElement(pfx, Constants[ce].val, oNull); pfx->pex += pfx->lenToken; return MagickTrue; } } - - { FunctionE fe; - for (fe = ((FunctionE) (oNull+1)); fe < fNull; fe=(FunctionE) (fe+1)) { - const char * feStr = Functions[fe-((FunctionE) (oNull+1))].str; - if (LocaleCompare (feStr, pfx->token)==0) { + for (fe = ((FunctionE)(oNull + 1)); fe < fNull; + fe = (FunctionE)(fe + 1)) { + const char *feStr = Functions[fe - ((FunctionE)(oNull + 1))].str; + if (LocaleCompare(feStr, pfx->token) == 0) { break; } } if (fe == fV && pfx->ImgListLen < 2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2238, OptionError, - "Symbol 'v' but fewer than two images at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2238, OptionError, + "Symbol 'v' but fewer than two images at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } - if (IsStealth (fe)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2246, OptionError, - "Function", "'%s' not permitted at '%s'", - pfx->token, SetShortExp(pfx)); + if (IsStealth(fe)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2246, OptionError, "Function", + "'%s' not permitted at '%s'", pfx->token, + SetShortExp(pfx)); } if (fe == fDo || fe == fFor || fe == fIf || fe == fWhile) { *needPopAll = MagickTrue; } - if (fe != fNull) return (GetFunction (pfx, fe)); + if (fe != fNull) + return (GetFunction(pfx, fe)); } - - { - ImgAttrE ia = GetImgAttrToken (pfx); + ImgAttrE ia = GetImgAttrToken(pfx); if (ia != aNull) { fxFltType val = 0; - (void) AddElement (pfx, val, ia); - - if (ImgAttrs[ia-((ImgAttrE) (fNull+1))].NeedStats==1) { - if (IsQualifier (pfx)) { - PixelChannel chQual = GetChannelQualifier (pfx, ia); - ElementT * pel; - if (chQual == ((PixelChannel) (-1))) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2272, OptionError, - "Bad channel qualifier at", "'%s'", - SetShortExp(pfx)); + (void)AddElement(pfx, val, ia); + + if (ImgAttrs[ia - ((ImgAttrE)(fNull + 1))].NeedStats == 1) { + if (IsQualifier(pfx)) { + PixelChannel chQual = GetChannelQualifier(pfx, ia); + ElementT *pel; + if (chQual == ((PixelChannel)(-1))) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2272, OptionError, "Bad channel qualifier at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } - pel = &pfx->Elements[pfx->usedElements-1]; + pel = &pfx->Elements[pfx->usedElements - 1]; pel->ChannelQual = chQual; } } @@ -19595,69 +15885,62 @@ static MagickBooleanType GetOperand ( } } - - { SymbolE se; - for (se = ((SymbolE) (aNull+1)); se < sNull; se=(SymbolE) (se+1)) { - const char * seStr = Symbols[se-((SymbolE) (aNull+1))].str; - if (LocaleCompare (seStr, pfx->token)==0) { + for (se = ((SymbolE)(aNull + 1)); se < sNull; se = (SymbolE)(se + 1)) { + const char *seStr = Symbols[se - ((SymbolE)(aNull + 1))].str; + if (LocaleCompare(seStr, pfx->token) == 0) { break; } } if (se != sNull) { fxFltType val = 0; - (void) AddElement (pfx, val, se); + (void)AddElement(pfx, val, se); pfx->pex += pfx->lenToken; - if (se==sHue || se==sSaturation || se==sLightness) pfx->NeedHsl = MagickTrue; + if (se == sHue || se == sSaturation || se == sLightness) + pfx->NeedHsl = MagickTrue; return MagickTrue; } } - - { fxFltType v0, v1, v2; - ssize_t ColLen = GetConstantColour (pfx, &v0, &v1, &v2); - if (ColLen < 0) return MagickFalse; + ssize_t ColLen = GetConstantColour(pfx, &v0, &v1, &v2); + if (ColLen < 0) + return MagickFalse; if (ColLen > 0) { - (void) AddColourElement (pfx, v0, v1, v2); - pfx->pex+=ColLen; + (void)AddColourElement(pfx, v0, v1, v2); + pfx->pex += ColLen; return MagickTrue; } } - - { const char *artifact; - artifact = GetImageArtifact (pfx->image, pfx->token); - if (artifact != (const char *) - ((void *)0) - ) { - char * tailptr; - fxFltType val = strtold (artifact, &tailptr); + artifact = GetImageArtifact(pfx->image, pfx->token); + if (artifact != (const char *)((void *)0)) { + char *tailptr; + fxFltType val = strtold(artifact, &tailptr); if (pfx->token == tailptr) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2329, OptionError, - "Artifact", "'%s' has value '%s', not a number, at '%s'", - pfx->token, artifact, SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2329, + OptionError, "Artifact", + "'%s' has value '%s', not a number, at '%s'", pfx->token, + artifact, SetShortExp(pfx)); return MagickFalse; } - (void) AddElement (pfx, val, oNull); - pfx->pex+=pfx->lenToken; + (void)AddElement(pfx, val, oNull); + pfx->pex += pfx->lenToken; return MagickTrue; } } - - - if (TokenMaybeUserSymbol (pfx)) { + if (TokenMaybeUserSymbol(pfx)) { *UserSymbol = MagickTrue; - *UserSymNdx = FindUserSymbol (pfx, pfx->token); + *UserSymNdx = FindUserSymbol(pfx, pfx->token); if (*UserSymNdx == -2) { - *UserSymNdx = AddUserSymbol (pfx, pfx->pex, pfx->lenToken); + *UserSymNdx = AddUserSymbol(pfx, pfx->pex, pfx->lenToken); *NewUserSymbol = MagickTrue; } else { } @@ -19667,142 +15950,125 @@ static MagickBooleanType GetOperand ( } } - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2357, OptionError, - "Expected operand at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2357, OptionError, + "Expected operand at", "'%s'", SetShortExp(pfx)); return MagickFalse; } -static MagickBooleanType inline IsRealOperator (OperatorE op) -{ +static MagickBooleanType inline IsRealOperator(OperatorE op) { return (op < oOpenParen || op > oCloseBrace) ? MagickTrue : MagickFalse; } -static MagickBooleanType inline ProcessTernaryOpr (FxInfo * pfx, TernaryT * ptern) - - +static MagickBooleanType inline ProcessTernaryOpr(FxInfo *pfx, TernaryT *ptern) { if (pfx->usedOprStack == 0) return MagickFalse; - if (pfx->OperatorStack[pfx->usedOprStack-1] == oQuery) { + if (pfx->OperatorStack[pfx->usedOprStack - 1] == oQuery) { if (ptern->addrQuery != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2379, OptionError, - "Already have '?' in sub-expression at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2379, OptionError, + "Already have '?' in sub-expression at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } if (ptern->addrColon != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2386, OptionError, - "Already have ':' in sub-expression at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2386, OptionError, + "Already have ':' in sub-expression at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } pfx->usedOprStack--; ptern->addrQuery = pfx->usedElements; - (void) AddAddressingElement (pfx, rIfZeroGoto, -2); + (void)AddAddressingElement(pfx, rIfZeroGoto, -2); - } - else if (pfx->OperatorStack[pfx->usedOprStack-1] == oColon) { + } else if (pfx->OperatorStack[pfx->usedOprStack - 1] == oColon) { if (ptern->addrQuery == -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2399, OptionError, - "Need '?' in sub-expression at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2399, OptionError, + "Need '?' in sub-expression at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } if (ptern->addrColon != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2406, OptionError, - "Already have ':' in sub-expression at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2406, OptionError, + "Already have ':' in sub-expression at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } pfx->usedOprStack--; ptern->addrColon = pfx->usedElements; - pfx->Elements[pfx->usedElements-1].DoPush = MagickTrue; - (void) AddAddressingElement (pfx, rGoto, -2); - + pfx->Elements[pfx->usedElements - 1].DoPush = MagickTrue; + (void)AddAddressingElement(pfx, rGoto, -2); } return MagickTrue; } -static MagickBooleanType GetOperator ( - FxInfo * pfx, - MagickBooleanType * Assign, MagickBooleanType * Update, MagickBooleanType * IncrDecr) -{ +static MagickBooleanType GetOperator(FxInfo *pfx, MagickBooleanType *Assign, + MagickBooleanType *Update, + MagickBooleanType *IncrDecr) { OperatorE op; size_t len = 0; MagickBooleanType DoneIt = MagickFalse; - SkipSpaces (pfx); - for (op = (OperatorE)0; op != oNull; op=(OperatorE) (op+1)) { - const char * opStr = Operators[op].str; + SkipSpaces(pfx); + for (op = (OperatorE)0; op != oNull; op = (OperatorE)(op + 1)) { + const char *opStr = Operators[op].str; len = strlen(opStr); - if (LocaleNCompare (opStr, pfx->pex, len)==0) { + if (LocaleNCompare(opStr, pfx->pex, len) == 0) { break; } } - if (!IsRealOperator (op)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2438, OptionError, - "Not a real operator at", "'%s'", - SetShortExp(pfx)); + if (!IsRealOperator(op)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2438, + OptionError, "Not a real operator at", "'%s'", SetShortExp(pfx)); return MagickFalse; } - if (op==oNull) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2446, OptionError, - "Expected operator at", "'%s'", - SetShortExp(pfx)); + if (op == oNull) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2446, + OptionError, "Expected operator at", "'%s'", SetShortExp(pfx)); return MagickFalse; } - *Assign = (op==oAssign) ? MagickTrue : MagickFalse; - *Update = OprInPlace (op); + *Assign = (op == oAssign) ? MagickTrue : MagickFalse; + *Update = OprInPlace(op); *IncrDecr = (op == oPlusPlus || op == oSubSub) ? MagickTrue : MagickFalse; - - - - - while (pfx->usedOprStack > 0) { - OperatorE top = pfx->OperatorStack[pfx->usedOprStack-1]; + OperatorE top = pfx->OperatorStack[pfx->usedOprStack - 1]; int precTop, precNew; - if (top == oOpenParen || top == oAssign || OprInPlace (top)) break; + if (top == oOpenParen || top == oAssign || OprInPlace(top)) + break; precTop = Operators[top].precedence; precNew = Operators[op].precedence; - - - if (precTop < precNew) break; - (void) AddElement (pfx, (fxFltType) 0, top); + if (precTop < precNew) + break; + (void)AddElement(pfx, (fxFltType)0, top); pfx->usedOprStack--; } - - - - if (op==oCloseParen) { + if (op == oCloseParen) { if (pfx->usedOprStack == 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2481, OptionError, - "Found ')' but nothing on stack at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2481, OptionError, + "Found ')' but nothing on stack at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } - if (pfx->OperatorStack[pfx->usedOprStack-1] != oOpenParen) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2489, OptionError, - "Found ')' but no '(' on stack at", "'%s'", - SetShortExp(pfx)); + if (pfx->OperatorStack[pfx->usedOprStack - 1] != oOpenParen) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2489, OptionError, + "Found ')' but no '(' on stack at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } pfx->usedOprStack--; @@ -19810,7 +16076,8 @@ static MagickBooleanType GetOperator ( } if (!DoneIt) { - if (!PushOperatorStack (pfx, op)) return MagickFalse; + if (!PushOperatorStack(pfx, op)) + return MagickFalse; } pfx->pex += len; @@ -19818,8 +16085,7 @@ static MagickBooleanType GetOperator ( return MagickTrue; } -static MagickBooleanType ResolveTernaryAddresses (FxInfo * pfx, TernaryT * ptern) -{ +static MagickBooleanType ResolveTernaryAddresses(FxInfo *pfx, TernaryT *ptern) { if (ptern->addrQuery == -2 && ptern->addrColon == -2) return MagickTrue; @@ -19829,33 +16095,30 @@ static MagickBooleanType ResolveTernaryAddresses (FxInfo * pfx, TernaryT * ptern ptern->addrQuery = -2; ptern->addrColon = -2; } else if (ptern->addrQuery != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2519, OptionError, - "'?' with no corresponding ':'", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); - return MagickFalse; + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2519, OptionError, + "'?' with no corresponding ':'", "'%s' at '%s'", + pfx->token, SetShortExp(pfx)); + return MagickFalse; } else if (ptern->addrColon != -2) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2525, OptionError, - "':' with no corresponding '?'", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); - return MagickFalse; + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2525, OptionError, + "':' with no corresponding '?'", "'%s' at '%s'", + pfx->token, SetShortExp(pfx)); + return MagickFalse; } return MagickTrue; } -static MagickBooleanType TranslateExpression ( - FxInfo * pfx, const char * strLimit, char * chLimit, MagickBooleanType * needPopAll) -{ - +static MagickBooleanType TranslateExpression(FxInfo *pfx, const char *strLimit, + char *chLimit, + MagickBooleanType *needPopAll) { MagickBooleanType UserSymbol, NewUserSymbol; int UserSymNdx0, UserSymNdx1; - MagickBooleanType - Assign = MagickFalse, - Update = MagickFalse, - IncrDecr = MagickFalse; + MagickBooleanType Assign = MagickFalse, Update = MagickFalse, + IncrDecr = MagickFalse; int StartEleNdx; @@ -19867,19 +16130,18 @@ static MagickBooleanType TranslateExpression ( *chLimit = '\0'; - StartEleNdx = pfx->usedElements-1; - if (StartEleNdx < 0) StartEleNdx = 0; + StartEleNdx = pfx->usedElements - 1; + if (StartEleNdx < 0) + StartEleNdx = 0; - SkipSpaces (pfx); + SkipSpaces(pfx); if (!*pfx->pex) { pfx->teDepth--; return MagickFalse; } - if (strchr(strLimit,*pfx->pex)!= - ((void *)0) - ) { + if (strchr(strLimit, *pfx->pex) != ((void *)0)) { *chLimit = *pfx->pex; pfx->pex++; pfx->teDepth--; @@ -19887,180 +16149,182 @@ static MagickBooleanType TranslateExpression ( return MagickFalse; } - if (!GetOperand (pfx, &UserSymbol, &NewUserSymbol, &UserSymNdx0, needPopAll)) return MagickFalse; - SkipSpaces (pfx); - - + if (!GetOperand(pfx, &UserSymbol, &NewUserSymbol, &UserSymNdx0, needPopAll)) + return MagickFalse; + SkipSpaces(pfx); - while (*pfx->pex && (!*strLimit || (strchr(strLimit,*pfx->pex)== - ((void *)0) - ))) { - if (!GetOperator (pfx, &Assign, &Update, &IncrDecr)) return MagickFalse; - SkipSpaces (pfx); + while (*pfx->pex && + (!*strLimit || (strchr(strLimit, *pfx->pex) == ((void *)0)))) { + if (!GetOperator(pfx, &Assign, &Update, &IncrDecr)) + return MagickFalse; + SkipSpaces(pfx); if (NewUserSymbol && !Assign) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2584, OptionError, - "Expected assignment after new UserSymbol", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2584, OptionError, + "Expected assignment after new UserSymbol", + "'%s' at '%s'", pfx->token, SetShortExp(pfx)); return MagickFalse; } if (!UserSymbol && Assign) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2591, OptionError, - "Attempted assignment to non-UserSymbol", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2591, OptionError, + "Attempted assignment to non-UserSymbol", + "'%s' at '%s'", pfx->token, SetShortExp(pfx)); return MagickFalse; } if (!UserSymbol && Update) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2598, OptionError, - "Attempted update to non-UserSymbol", "'%s' at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2598, OptionError, + "Attempted update to non-UserSymbol", + "'%s' at '%s'", pfx->token, SetShortExp(pfx)); return MagickFalse; } if (UserSymbol && (Assign || Update) && !IncrDecr) { - if (!TranslateExpression (pfx, strLimit, chLimit, needPopAll)) return MagickFalse; - if (!*pfx->pex) break; - if (!*strLimit) break; - if (strchr(strLimit,*chLimit)!= - ((void *)0) - ) break; + if (!TranslateExpression(pfx, strLimit, chLimit, needPopAll)) + return MagickFalse; + if (!*pfx->pex) + break; + if (!*strLimit) + break; + if (strchr(strLimit, *chLimit) != ((void *)0)) + break; } if (UserSymbol && !Assign && !Update && UserSymNdx0 != -2) { - ElementT * pel; - (void) AddAddressingElement (pfx, rCopyFrom, UserSymNdx0); + ElementT *pel; + (void)AddAddressingElement(pfx, rCopyFrom, UserSymNdx0); UserSymNdx0 = -2; - pel = &pfx->Elements[pfx->usedElements-1]; + pel = &pfx->Elements[pfx->usedElements - 1]; pel->DoPush = MagickTrue; } if (UserSymbol) { - while (TopOprIsUnaryPrefix (pfx)) { - OperatorE op = pfx->OperatorStack[pfx->usedOprStack-1]; - (void) AddElement (pfx, (fxFltType) 0, op); + while (TopOprIsUnaryPrefix(pfx)) { + OperatorE op = pfx->OperatorStack[pfx->usedOprStack - 1]; + (void)AddElement(pfx, (fxFltType)0, op); pfx->usedOprStack--; } } - if (!ProcessTernaryOpr (pfx, &ternary)) return MagickFalse; + if (!ProcessTernaryOpr(pfx, &ternary)) + return MagickFalse; if (ternary.addrColon != -2) { - if (!TranslateExpression (pfx, ",);", chLimit, needPopAll)) return MagickFalse; + if (!TranslateExpression(pfx, ",);", chLimit, needPopAll)) + return MagickFalse; break; } UserSymbol = NewUserSymbol = MagickFalse; - if ( (!*pfx->pex) || (*strLimit && (strchr(strLimit,*pfx->pex)!= - ((void *)0) - ) ) ) - { - if (IncrDecr) break; + if ((!*pfx->pex) || + (*strLimit && (strchr(strLimit, *pfx->pex) != ((void *)0)))) { + if (IncrDecr) + break; - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2640, OptionError, - "Expected operand after operator", "at '%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2640, OptionError, + "Expected operand after operator", "at '%s'", + SetShortExp(pfx)); return MagickFalse; } if (IncrDecr) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2648, OptionError, - "'++' and '--' must be the final operators in an expression at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2648, + OptionError, + "'++' and '--' must be the final operators in an expression at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } - if (!GetOperand (pfx, &UserSymbol, &NewUserSymbol, &UserSymNdx1, needPopAll)) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2656, OptionError, - "Expected operand at", "'%s'", - SetShortExp(pfx)); + if (!GetOperand(pfx, &UserSymbol, &NewUserSymbol, &UserSymNdx1, + needPopAll)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2656, + OptionError, "Expected operand at", "'%s'", SetShortExp(pfx)); return MagickFalse; } - SkipSpaces (pfx); + SkipSpaces(pfx); if (NewUserSymbol && !Assign) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2664, OptionError, - "NewUserSymbol", "'%s' after non-assignment operator at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2664, OptionError, + "NewUserSymbol", + "'%s' after non-assignment operator at '%s'", + pfx->token, SetShortExp(pfx)); return MagickFalse; } if (UserSymbol && !NewUserSymbol) { - (void) AddAddressingElement (pfx, rCopyFrom, UserSymNdx1); + (void)AddAddressingElement(pfx, rCopyFrom, UserSymNdx1); UserSymNdx1 = -2; } UserSymNdx0 = UserSymNdx1; } if (UserSymbol && !Assign && !Update && UserSymNdx0 != -2) { - ElementT * pel; + ElementT *pel; if (NewUserSymbol) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2680, OptionError, - "NewUserSymbol", "'%s' needs assignment operator at '%s'", - pfx->token, SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2680, OptionError, + "NewUserSymbol", + "'%s' needs assignment operator at '%s'", + pfx->token, SetShortExp(pfx)); return MagickFalse; } - (void) AddAddressingElement (pfx, rCopyFrom, UserSymNdx0); - pel = &pfx->Elements[pfx->usedElements-1]; + (void)AddAddressingElement(pfx, rCopyFrom, UserSymNdx0); + pel = &pfx->Elements[pfx->usedElements - 1]; pel->DoPush = MagickTrue; } - if (*pfx->pex && !*chLimit && (strchr(strLimit,*pfx->pex)!= - ((void *)0) - )) { + if (*pfx->pex && !*chLimit && (strchr(strLimit, *pfx->pex) != ((void *)0))) { *chLimit = *pfx->pex; pfx->pex++; } while (pfx->usedOprStack) { - OperatorE op = pfx->OperatorStack[pfx->usedOprStack-1]; + OperatorE op = pfx->OperatorStack[pfx->usedOprStack - 1]; if (op == oOpenParen || op == oOpenBracket || op == oOpenBrace) { break; } - if ( (op==oAssign && !Assign) || (OprInPlace(op) && !Update) ) { + if ((op == oAssign && !Assign) || (OprInPlace(op) && !Update)) { break; } pfx->usedOprStack--; - (void) AddElement (pfx, (fxFltType) 0, op); + (void)AddElement(pfx, (fxFltType)0, op); if (op == oAssign) { if (UserSymNdx0 < 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2707, OptionError, - "Assignment to unknown user symbol at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2707, OptionError, + "Assignment to unknown user symbol at", + "'%s'", SetShortExp(pfx)); return MagickFalse; } - pfx->usedElements--; - (void) AddAddressingElement (pfx, rCopyTo, UserSymNdx0); + (void)AddAddressingElement(pfx, rCopyTo, UserSymNdx0); break; - } else if (OprInPlace (op)) { + } else if (OprInPlace(op)) { if (UserSymNdx0 < 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2720, OptionError, - "Operator-in-place to unknown user symbol at", "'%s'", - SetShortExp(pfx)); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)2720, + OptionError, "Operator-in-place to unknown user symbol at", "'%s'", + SetShortExp(pfx)); return MagickFalse; } - - pfx->Elements[pfx->usedElements-1].EleNdx = UserSymNdx0; + pfx->Elements[pfx->usedElements - 1].EleNdx = UserSymNdx0; break; } } - if (ternary.addrQuery != -2) *needPopAll = MagickTrue; + if (ternary.addrQuery != -2) + *needPopAll = MagickTrue; - (void) ResolveTernaryAddresses (pfx, &ternary); + (void)ResolveTernaryAddresses(pfx, &ternary); pfx->teDepth--; if (!pfx->teDepth && *needPopAll) { - (void) AddAddressingElement (pfx, rZerStk, -2); + (void)AddAddressingElement(pfx, rZerStk, -2); *needPopAll = MagickFalse; } @@ -20070,48 +16334,47 @@ static MagickBooleanType TranslateExpression ( return MagickTrue; } - -static MagickBooleanType TranslateStatement (FxInfo * pfx, char * strLimit, char * chLimit) -{ +static MagickBooleanType TranslateStatement(FxInfo *pfx, char *strLimit, + char *chLimit) { MagickBooleanType NeedPopAll = MagickFalse; - SkipSpaces (pfx); + SkipSpaces(pfx); - if (!*pfx->pex) return MagickFalse; + if (!*pfx->pex) + return MagickFalse; - if (!TranslateExpression (pfx, strLimit, chLimit, &NeedPopAll)) { + if (!TranslateExpression(pfx, strLimit, chLimit, &NeedPopAll)) { return MagickFalse; } - if (pfx->usedElements && *chLimit==';') { + if (pfx->usedElements && *chLimit == ';') { - - - - ElementT * pel = &pfx->Elements[pfx->usedElements-1]; - if (pel->DoPush) pel->DoPush = MagickFalse; + ElementT *pel = &pfx->Elements[pfx->usedElements - 1]; + if (pel->DoPush) + pel->DoPush = MagickFalse; } return MagickTrue; } -static MagickBooleanType TranslateStatementList (FxInfo * pfx, const char * strLimit, char * chLimit) -{ +static MagickBooleanType +TranslateStatementList(FxInfo *pfx, const char *strLimit, char *chLimit) { char sLimits[10]; - SkipSpaces (pfx); + SkipSpaces(pfx); - if (!*pfx->pex) return MagickFalse; - (void) CopyMagickString (sLimits, strLimit, 10 -1); + if (!*pfx->pex) + return MagickFalse; + (void)CopyMagickString(sLimits, strLimit, 10 - 1); - if (strchr(strLimit,';')== - ((void *)0) - ) - (void) ConcatenateMagickString (sLimits, ";", 10); + if (strchr(strLimit, ';') == ((void *)0)) + (void)ConcatenateMagickString(sLimits, ";", 10); for (;;) { - if (!TranslateStatement (pfx, sLimits, chLimit)) return MagickFalse; + if (!TranslateStatement(pfx, sLimits, chLimit)) + return MagickFalse; - if (!*pfx->pex) break; + if (!*pfx->pex) + break; if (*chLimit != ';') { break; @@ -20124,79 +16387,68 @@ static MagickBooleanType TranslateStatementList (FxInfo * pfx, const char * strL return MagickTrue; } - - - - -static ChannelStatistics *CollectOneImgStats (FxInfo * pfx, Image * img) -{ +static ChannelStatistics *CollectOneImgStats(FxInfo *pfx, Image *img) { int ch; - ChannelStatistics * cs = GetImageStatistics (img, pfx->exception); - - - if (cs == (ChannelStatistics *) - ((void *)0) - ) - return((ChannelStatistics *) - ((void *)0) - ); - - for (ch=0; ch <= (int) 64; ch++) { - cs[ch].mean *= ((double) 1.0/(double) 65535.0f); - cs[ch].median *= ((double) 1.0/(double) 65535.0f); - cs[ch].maxima *= ((double) 1.0/(double) 65535.0f); - cs[ch].minima *= ((double) 1.0/(double) 65535.0f); - cs[ch].standard_deviation *= ((double) 1.0/(double) 65535.0f); - cs[ch].kurtosis *= ((double) 1.0/(double) 65535.0f); - cs[ch].skewness *= ((double) 1.0/(double) 65535.0f); - cs[ch].entropy *= ((double) 1.0/(double) 65535.0f); + ChannelStatistics *cs = GetImageStatistics(img, pfx->exception); + + if (cs == (ChannelStatistics *)((void *)0)) + return ((ChannelStatistics *)((void *)0)); + + for (ch = 0; ch <= (int)64; ch++) { + cs[ch].mean *= ((double)1.0 / (double)65535.0f); + cs[ch].median *= ((double)1.0 / (double)65535.0f); + cs[ch].maxima *= ((double)1.0 / (double)65535.0f); + cs[ch].minima *= ((double)1.0 / (double)65535.0f); + cs[ch].standard_deviation *= ((double)1.0 / (double)65535.0f); + cs[ch].kurtosis *= ((double)1.0 / (double)65535.0f); + cs[ch].skewness *= ((double)1.0 / (double)65535.0f); + cs[ch].entropy *= ((double)1.0 / (double)65535.0f); } return cs; } -static MagickBooleanType CollectStatistics (FxInfo * pfx) -{ - Image * img = GetFirstImageInList (pfx->image); +static MagickBooleanType CollectStatistics(FxInfo *pfx) { + Image *img = GetFirstImageInList(pfx->image); - size_t imgNum=0; + size_t imgNum = 0; - pfx->statistics = (ChannelStatistics**) AcquireMagickMemory (pfx->ImgListLen * sizeof (ChannelStatistics *)); + pfx->statistics = (ChannelStatistics **)AcquireMagickMemory( + pfx->ImgListLen * sizeof(ChannelStatistics *)); if (!pfx->statistics) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2837, ResourceLimitFatalError, - "Statistics", "%lu", - (unsigned long) pfx->ImgListLen); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2837, ResourceLimitFatalError, + "Statistics", "%lu", + (unsigned long)pfx->ImgListLen); return MagickFalse; } for (;;) { - pfx->statistics[imgNum] = CollectOneImgStats (pfx, img); - - if (++imgNum == pfx->ImgListLen) break; - img = GetNextImageInList (img); - - ((void) sizeof (( - img != (Image *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - img != (Image *) - ((void *)0)) ; else __assert_fail ( - "img != (Image *) NULL" - , "MagickCore/fx.c", 2848, __extension__ __PRETTY_FUNCTION__); })) - ; + pfx->statistics[imgNum] = CollectOneImgStats(pfx, img); + + if (++imgNum == pfx->ImgListLen) + break; + img = GetNextImageInList(img); + + ((void)sizeof((img != (Image *)((void *)0)) ? 1 : 0), __extension__({ + if (img != (Image *)((void *)0)) + ; + else + __assert_fail("img != (Image *) NULL", "MagickCore/fx.c", 2848, + __extension__ __PRETTY_FUNCTION__); + })); } pfx->GotStats = MagickTrue; return MagickTrue; } -static MagickBooleanType inline PushVal (FxInfo * pfx, fxRtT * pfxrt, fxFltType val, int addr) -{ - if (pfxrt->usedValStack >=pfxrt->numValStack) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2859, OptionError, - "ValStack overflow at addr=", "%i", - addr); +static MagickBooleanType inline PushVal(FxInfo *pfx, fxRtT *pfxrt, + fxFltType val, int addr) { + if (pfxrt->usedValStack >= pfxrt->numValStack) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2859, OptionError, + "ValStack overflow at addr=", "%i", addr); return MagickFalse; } @@ -20204,1731 +16456,1762 @@ static MagickBooleanType inline PushVal (FxInfo * pfx, fxRtT * pfxrt, fxFltType return MagickTrue; } -static inline fxFltType PopVal (FxInfo * pfx, fxRtT * pfxrt, int addr) -{ +static inline fxFltType PopVal(FxInfo *pfx, fxRtT *pfxrt, int addr) { if (pfxrt->usedValStack <= 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 2873, OptionError, - "ValStack underflow at addr=", "%i", - addr); - return (fxFltType) 0; + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2873, OptionError, + "ValStack underflow at addr=", "%i", addr); + return (fxFltType)0; } return pfxrt->ValStack[--pfxrt->usedValStack]; } -static inline fxFltType ImageStat ( - FxInfo * pfx, ssize_t ImgNum, PixelChannel channel, ImgAttrE ia) -{ - ChannelStatistics * cs = - ((void *)0) - ; +static inline fxFltType ImageStat(FxInfo *pfx, ssize_t ImgNum, + PixelChannel channel, ImgAttrE ia) { + ChannelStatistics *cs = ((void *)0); fxFltType ret = 0; - MagickBooleanType NeedRelinq = MagickFalse; - - if (ImgNum < 0) - { - (void) ThrowMagickException(pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 2891, - OptionError,"NoSuchImage","%lu",(unsigned long) ImgNum); - ImgNum=0; - } - - if (pfx->GotStats) { - if ((channel < 0) || (channel > 64)) - { - (void) ThrowMagickException(pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 2899, - OptionError,"NoSuchImageChannel","%i",channel); - channel=(PixelChannel) 0; - } - cs = pfx->statistics[ImgNum]; - } else if (pfx->NeedStats) { - - if ((channel < 0) || (channel > 64)) - { - (void) ThrowMagickException(pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 2908, - OptionError,"NoSuchImageChannel","%i",channel); - channel=(PixelChannel) 0; - } - cs = CollectOneImgStats (pfx, pfx->Images[ImgNum]); - NeedRelinq = MagickTrue; - } - - switch (ia) { - case aDepth: - ret = (fxFltType) GetImageDepth (pfx->Images[ImgNum], pfx->exception); - break; - case aExtent: - ret = (fxFltType) GetBlobSize (pfx->image); - break; - case aKurtosis: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].kurtosis; - break; - case aMaxima: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].maxima; - break; - case aMean: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].mean; - break; - case aMedian: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].median; - break; - case aMinima: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].minima; - break; - case aPage: - - break; - case aPageX: - ret = (fxFltType) pfx->Images[ImgNum]->page.x; - break; - case aPageY: - ret = (fxFltType) pfx->Images[ImgNum]->page.y; - break; - case aPageWid: - ret = (fxFltType) pfx->Images[ImgNum]->page.width; - break; - case aPageHt: - ret = (fxFltType) pfx->Images[ImgNum]->page.height; - break; - case aPrintsize: - - break; - case aPrintsizeX: - ret = (fxFltType) PerceptibleReciprocal (pfx->Images[ImgNum]->resolution.x) - * pfx->Images[ImgNum]->columns; - break; - case aPrintsizeY: - ret = (fxFltType) PerceptibleReciprocal (pfx->Images[ImgNum]->resolution.y) - * pfx->Images[ImgNum]->rows; - break; - case aQuality: - ret = (fxFltType) pfx->Images[ImgNum]->quality; - break; - case aRes: - - break; - case aResX: - ret = pfx->Images[ImgNum]->resolution.x; - break; - case aResY: - ret = pfx->Images[ImgNum]->resolution.y; - break; - case aSkewness: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].skewness; - break; - case aStdDev: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - ret = cs[channel].standard_deviation; - break; - case aH: - ret = (fxFltType) pfx->Images[ImgNum]->rows; - break; - case aN: - ret = (fxFltType) pfx->ImgListLen; - break; - case aT: - ret = (fxFltType) ImgNum; - break; - case aW: - ret = (fxFltType) pfx->Images[ImgNum]->columns; - break; - case aZ: - ret = (fxFltType) GetImageDepth (pfx->Images[ImgNum], pfx->exception); - break; - default: - (void) ThrowMagickException (pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 3005,OptionError, - "Unknown ia=","%i",ia); + MagickBooleanType NeedRelinq = MagickFalse; + + if (ImgNum < 0) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2891, OptionError, "NoSuchImage", + "%lu", (unsigned long)ImgNum); + ImgNum = 0; + } + + if (pfx->GotStats) { + if ((channel < 0) || (channel > 64)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2899, OptionError, + "NoSuchImageChannel", "%i", channel); + channel = (PixelChannel)0; + } + cs = pfx->statistics[ImgNum]; + } else if (pfx->NeedStats) { + + if ((channel < 0) || (channel > 64)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)2908, OptionError, + "NoSuchImageChannel", "%i", channel); + channel = (PixelChannel)0; + } + cs = CollectOneImgStats(pfx, pfx->Images[ImgNum]); + NeedRelinq = MagickTrue; + } + + switch (ia) { + case aDepth: + ret = (fxFltType)GetImageDepth(pfx->Images[ImgNum], pfx->exception); + break; + case aExtent: + ret = (fxFltType)GetBlobSize(pfx->image); + break; + case aKurtosis: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].kurtosis; + break; + case aMaxima: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].maxima; + break; + case aMean: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].mean; + break; + case aMedian: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].median; + break; + case aMinima: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].minima; + break; + case aPage: + + break; + case aPageX: + ret = (fxFltType)pfx->Images[ImgNum]->page.x; + break; + case aPageY: + ret = (fxFltType)pfx->Images[ImgNum]->page.y; + break; + case aPageWid: + ret = (fxFltType)pfx->Images[ImgNum]->page.width; + break; + case aPageHt: + ret = (fxFltType)pfx->Images[ImgNum]->page.height; + break; + case aPrintsize: + + break; + case aPrintsizeX: + ret = (fxFltType)PerceptibleReciprocal(pfx->Images[ImgNum]->resolution.x) * + pfx->Images[ImgNum]->columns; + break; + case aPrintsizeY: + ret = (fxFltType)PerceptibleReciprocal(pfx->Images[ImgNum]->resolution.y) * + pfx->Images[ImgNum]->rows; + break; + case aQuality: + ret = (fxFltType)pfx->Images[ImgNum]->quality; + break; + case aRes: + + break; + case aResX: + ret = pfx->Images[ImgNum]->resolution.x; + break; + case aResY: + ret = pfx->Images[ImgNum]->resolution.y; + break; + case aSkewness: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].skewness; + break; + case aStdDev: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + ret = cs[channel].standard_deviation; + break; + case aH: + ret = (fxFltType)pfx->Images[ImgNum]->rows; + break; + case aN: + ret = (fxFltType)pfx->ImgListLen; + break; + case aT: + ret = (fxFltType)ImgNum; + break; + case aW: + ret = (fxFltType)pfx->Images[ImgNum]->columns; + break; + case aZ: + ret = (fxFltType)GetImageDepth(pfx->Images[ImgNum], pfx->exception); + break; + default: + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3005, OptionError, + "Unknown ia=", "%i", ia); } - if (NeedRelinq) cs = (ChannelStatistics *)RelinquishMagickMemory (cs); + if (NeedRelinq) + cs = (ChannelStatistics *)RelinquishMagickMemory(cs); return ret; } -static fxFltType inline FxGcd (fxFltType x, fxFltType y, const size_t depth) -{ - +static fxFltType inline FxGcd(fxFltType x, fxFltType y, const size_t depth) { if (x < y) - return (FxGcd (y, x, depth+1)); - if ((fabs((double) y) < 0.001) || (depth >= 200)) + return (FxGcd(y, x, depth + 1)); + if ((fabs((double)y) < 0.001) || (depth >= 200)) return (x); - return (FxGcd (y, x-y*floor((double) (x/y)), depth+1)); + return (FxGcd(y, x - y * floor((double)(x / y)), depth + 1)); } -static ssize_t inline ChkImgNum (FxInfo * pfx, fxFltType f) +static ssize_t inline ChkImgNum(FxInfo *pfx, fxFltType f) { - ssize_t i = (ssize_t) floor ((double) f + 0.5); - if (i < 0) i += pfx->ImgListLen; + ssize_t i = (ssize_t)floor((double)f + 0.5); + if (i < 0) + i += pfx->ImgListLen; if (i < 0 || i >= (ssize_t)pfx->ImgListLen) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3031, OptionError, - "ImgNum", "%lu bad for ImgListLen %lu", - (unsigned long) i, (unsigned long) pfx->ImgListLen); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3031, OptionError, "ImgNum", + "%lu bad for ImgListLen %lu", (unsigned long)i, + (unsigned long)pfx->ImgListLen); i = -1; } return i; } -static fxFltType GetHslFlt (FxInfo * pfx, ssize_t ImgNum, const fxFltType fx, const fxFltType fy, - int channel) -{ - Image * img = pfx->Images[ImgNum]; +static fxFltType GetHslFlt(FxInfo *pfx, ssize_t ImgNum, const fxFltType fx, + const fxFltType fy, int channel) { + Image *img = pfx->Images[ImgNum]; double red, green, blue; - double hue=0, saturation=0, lightness=0; + double hue = 0, saturation = 0, lightness = 0; MagickBooleanType okay = MagickTrue; - if(!InterpolatePixelChannel (img, pfx->Imgs[ImgNum].View, RedPixelChannel, img->interpolate, - (double) fx, (double) fy, &red, pfx->exception)) okay = MagickFalse; - if(!InterpolatePixelChannel (img, pfx->Imgs[ImgNum].View, GreenPixelChannel, img->interpolate, - (double) fx, (double) fy, &green, pfx->exception)) okay = MagickFalse; - if(!InterpolatePixelChannel (img, pfx->Imgs[ImgNum].View, BluePixelChannel, img->interpolate, - (double) fx, (double) fy, &blue, pfx->exception)) okay = MagickFalse; + if (!InterpolatePixelChannel(img, pfx->Imgs[ImgNum].View, RedPixelChannel, + img->interpolate, (double)fx, (double)fy, &red, + pfx->exception)) + okay = MagickFalse; + if (!InterpolatePixelChannel(img, pfx->Imgs[ImgNum].View, GreenPixelChannel, + img->interpolate, (double)fx, (double)fy, &green, + pfx->exception)) + okay = MagickFalse; + if (!InterpolatePixelChannel(img, pfx->Imgs[ImgNum].View, BluePixelChannel, + img->interpolate, (double)fx, (double)fy, &blue, + pfx->exception)) + okay = MagickFalse; if (!okay) - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3068, OptionError, - "GetHslFlt failure", "%lu %g,%g %i", (unsigned long) ImgNum, - (double) fx, (double) fy, channel); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)3068, + OptionError, "GetHslFlt failure", "%lu %g,%g %i", (unsigned long)ImgNum, + (double)fx, (double)fy, channel); - ConvertRGBToHSL ( - red, green, blue, - &hue, &saturation, &lightness); + ConvertRGBToHSL(red, green, blue, &hue, &saturation, &lightness); - if (channel == ((PixelChannel) (-3))) return hue; - if (channel == ((PixelChannel) (-4))) return saturation; - if (channel == ((PixelChannel) (-5))) return lightness; + if (channel == ((PixelChannel)(-3))) + return hue; + if (channel == ((PixelChannel)(-4))) + return saturation; + if (channel == ((PixelChannel)(-5))) + return lightness; return 0.0; } -static fxFltType GetHslInt (FxInfo * pfx, ssize_t ImgNum, const ssize_t imgx, const ssize_t imgy, int channel) -{ - Image * img = pfx->Images[ImgNum]; +static fxFltType GetHslInt(FxInfo *pfx, ssize_t ImgNum, const ssize_t imgx, + const ssize_t imgy, int channel) { + Image *img = pfx->Images[ImgNum]; - double hue=0, saturation=0, lightness=0; + double hue = 0, saturation = 0, lightness = 0; - const Quantum * p = GetCacheViewVirtualPixels (pfx->Imgs[ImgNum].View, imgx, imgy, 1, 1, pfx->exception); - if (p == (const Quantum *) - ((void *)0) - ) - { - (void) ThrowMagickException (pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 3092, - OptionError,"GetHslInt failure","%lu %li,%li %i",(unsigned long) ImgNum, - (long) imgx,(long) imgy,channel); - return(0.0); - } + const Quantum *p = GetCacheViewVirtualPixels(pfx->Imgs[ImgNum].View, imgx, + imgy, 1, 1, pfx->exception); + if (p == (const Quantum *)((void *)0)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)3092, + OptionError, "GetHslInt failure", "%lu %li,%li %i", + (unsigned long)ImgNum, (long)imgx, (long)imgy, channel); + return (0.0); + } - ConvertRGBToHSL ( - GetPixelRed (img, p), GetPixelGreen (img, p), GetPixelBlue (img, p), - &hue, &saturation, &lightness); + ConvertRGBToHSL(GetPixelRed(img, p), GetPixelGreen(img, p), + GetPixelBlue(img, p), &hue, &saturation, &lightness); - if (channel == ((PixelChannel) (-3))) return hue; - if (channel == ((PixelChannel) (-4))) return saturation; - if (channel == ((PixelChannel) (-5))) return lightness; + if (channel == ((PixelChannel)(-3))) + return hue; + if (channel == ((PixelChannel)(-4))) + return saturation; + if (channel == ((PixelChannel)(-5))) + return lightness; return 0.0; } -static fxFltType inline GetIntensity (FxInfo * pfx, ssize_t ImgNum, const fxFltType fx, const fxFltType fy) -{ - Quantum - quantum_pixel[64]; +static fxFltType inline GetIntensity(FxInfo *pfx, ssize_t ImgNum, + const fxFltType fx, const fxFltType fy) { + Quantum quantum_pixel[64]; - PixelInfo - pixelinf; + PixelInfo pixelinf; - Image * img = pfx->Images[ImgNum]; + Image *img = pfx->Images[ImgNum]; - (void) GetPixelInfo (img, &pixelinf); + (void)GetPixelInfo(img, &pixelinf); - if (!InterpolatePixelInfo (img, pfx->Imgs[pfx->ImgNum].View, img->interpolate, - (double) fx, (double) fy, &pixelinf, pfx->exception)) - { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3125, OptionError, - "GetIntensity failure", "%lu %g,%g", (unsigned long) ImgNum, - (double) fx, (double) fy); + if (!InterpolatePixelInfo(img, pfx->Imgs[pfx->ImgNum].View, img->interpolate, + (double)fx, (double)fy, &pixelinf, + pfx->exception)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3125, OptionError, + "GetIntensity failure", "%lu %g,%g", + (unsigned long)ImgNum, (double)fx, (double)fy); } - SetPixelViaPixelInfo (img, &pixelinf, quantum_pixel); - return ((double) 1.0/(double) 65535.0f) * GetPixelIntensity (img, quantum_pixel); + SetPixelViaPixelInfo(img, &pixelinf, quantum_pixel); + return ((double)1.0 / (double)65535.0f) * + GetPixelIntensity(img, quantum_pixel); } -static MagickBooleanType ExecuteRPN (FxInfo * pfx, fxRtT * pfxrt, fxFltType *result, - const PixelChannel channel, const ssize_t imgx, const ssize_t imgy) -{ - const Quantum * p = pfxrt->thisPixel; - fxFltType regA=0, regB=0, regC=0, regD=0, regE=0; - Image * img = pfx->image; - ChannelStatistics * cs = - ((void *)0) - ; +static MagickBooleanType ExecuteRPN(FxInfo *pfx, fxRtT *pfxrt, + fxFltType *result, + const PixelChannel channel, + const ssize_t imgx, const ssize_t imgy) { + const Quantum *p = pfxrt->thisPixel; + fxFltType regA = 0, regB = 0, regC = 0, regD = 0, regE = 0; + Image *img = pfx->image; + ChannelStatistics *cs = ((void *)0); MagickBooleanType NeedRelinq = MagickFalse; - double hue=0, saturation=0, lightness=0; + double hue = 0, saturation = 0, lightness = 0; int i; + if (!p) + p = GetCacheViewVirtualPixels(pfx->Imgs[pfx->ImgNum].View, imgx, imgy, 1, 1, + pfx->exception); - - - - if (!p) p = GetCacheViewVirtualPixels ( - pfx->Imgs[pfx->ImgNum].View, imgx, imgy, 1, 1, pfx->exception); - - if (p == (const Quantum *) - ((void *)0) - ) - { - (void) ThrowMagickException (pfx->exception,"MagickCore/fx.c",__func__,(unsigned long) 3154, - OptionError,"GetHslInt failure","%lu %li,%li",(unsigned long) - pfx->ImgNum,(long) imgx,(long) imgy); - return(MagickFalse); - } + if (p == (const Quantum *)((void *)0)) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)3154, + OptionError, "GetHslInt failure", "%lu %li,%li", + (unsigned long)pfx->ImgNum, (long)imgx, (long)imgy); + return (MagickFalse); + } if (pfx->GotStats) { cs = pfx->statistics[pfx->ImgNum]; } else if (pfx->NeedStats) { - cs = CollectOneImgStats (pfx, pfx->Images[pfx->ImgNum]); + cs = CollectOneImgStats(pfx, pfx->Images[pfx->ImgNum]); NeedRelinq = MagickTrue; } - - if (pfx->NeedHsl) { - ConvertRGBToHSL ( - GetPixelRed (img, p), GetPixelGreen (img, p), GetPixelBlue (img, p), - &hue, &saturation, &lightness); + ConvertRGBToHSL(GetPixelRed(img, p), GetPixelGreen(img, p), + GetPixelBlue(img, p), &hue, &saturation, &lightness); } - for (i=0; i < pfx->usedElements; i++) { + for (i = 0; i < pfx->usedElements; i++) { ElementT *pel = &pfx->Elements[i]; - switch (pel->nArgs) { - case 0: - break; - case 1: - regA = PopVal (pfx, pfxrt, i); - break; - case 2: - regB = PopVal (pfx, pfxrt, i); - regA = PopVal (pfx, pfxrt, i); - break; - case 3: - regC = PopVal (pfx, pfxrt, i); - regB = PopVal (pfx, pfxrt, i); - regA = PopVal (pfx, pfxrt, i); - break; - case 4: - regD = PopVal (pfx, pfxrt, i); - regC = PopVal (pfx, pfxrt, i); - regB = PopVal (pfx, pfxrt, i); - regA = PopVal (pfx, pfxrt, i); - break; - case 5: - regE = PopVal (pfx, pfxrt, i); - regD = PopVal (pfx, pfxrt, i); - regC = PopVal (pfx, pfxrt, i); - regB = PopVal (pfx, pfxrt, i); - regA = PopVal (pfx, pfxrt, i); - break; - default: - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3207, OptionError, - "Too many args:", "%i", pel->nArgs); - break; - } + switch (pel->nArgs) { + case 0: + break; + case 1: + regA = PopVal(pfx, pfxrt, i); + break; + case 2: + regB = PopVal(pfx, pfxrt, i); + regA = PopVal(pfx, pfxrt, i); + break; + case 3: + regC = PopVal(pfx, pfxrt, i); + regB = PopVal(pfx, pfxrt, i); + regA = PopVal(pfx, pfxrt, i); + break; + case 4: + regD = PopVal(pfx, pfxrt, i); + regC = PopVal(pfx, pfxrt, i); + regB = PopVal(pfx, pfxrt, i); + regA = PopVal(pfx, pfxrt, i); + break; + case 5: + regE = PopVal(pfx, pfxrt, i); + regD = PopVal(pfx, pfxrt, i); + regC = PopVal(pfx, pfxrt, i); + regB = PopVal(pfx, pfxrt, i); + regA = PopVal(pfx, pfxrt, i); + break; + default: + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3207, OptionError, + "Too many args:", "%i", pel->nArgs); + break; + } - switch (pel->oprNum) { - case oAddEq: - regA = (pfxrt->UserSymVals[pel->EleNdx] += regA); - break; - case oSubtractEq: - regA = (pfxrt->UserSymVals[pel->EleNdx] -= regA); - break; - case oMultiplyEq: - regA = (pfxrt->UserSymVals[pel->EleNdx] *= regA); - break; - case oDivideEq: - regA = (pfxrt->UserSymVals[pel->EleNdx] *= PerceptibleReciprocal((double)regA)); - break; - case oPlusPlus: - regA = pfxrt->UserSymVals[pel->EleNdx]++; - break; - case oSubSub: - regA = pfxrt->UserSymVals[pel->EleNdx]--; - break; - case oAdd: - regA += regB; - break; - case oSubtract: - regA -= regB; - break; - case oMultiply: - regA *= regB; - break; - case oDivide: - regA *= PerceptibleReciprocal((double)regB); - break; - case oModulus: - regA = fmod ((double) regA, fabs(floor((double) regB+0.5))); - break; - case oUnaryPlus: + switch (pel->oprNum) { + case oAddEq: + regA = (pfxrt->UserSymVals[pel->EleNdx] += regA); + break; + case oSubtractEq: + regA = (pfxrt->UserSymVals[pel->EleNdx] -= regA); + break; + case oMultiplyEq: + regA = (pfxrt->UserSymVals[pel->EleNdx] *= regA); + break; + case oDivideEq: + regA = (pfxrt->UserSymVals[pel->EleNdx] *= + PerceptibleReciprocal((double)regA)); + break; + case oPlusPlus: + regA = pfxrt->UserSymVals[pel->EleNdx]++; + break; + case oSubSub: + regA = pfxrt->UserSymVals[pel->EleNdx]--; + break; + case oAdd: + regA += regB; + break; + case oSubtract: + regA -= regB; + break; + case oMultiply: + regA *= regB; + break; + case oDivide: + regA *= PerceptibleReciprocal((double)regB); + break; + case oModulus: + regA = fmod((double)regA, fabs(floor((double)regB + 0.5))); + break; + case oUnaryPlus: - break; - case oUnaryMinus: - regA = -regA; - break; - case oLshift: - if ((size_t) (regB+0.5) >= (8*sizeof(size_t))) - { - (void) ThrowMagickException ( pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3255, - OptionError, "undefined shift", "%g", (double) regB); - regA = (fxFltType) 0.0; - break; - } - regA = (fxFltType) ((size_t)(regA+0.5) << (size_t)(regB+0.5)); - break; - case oRshift: - if ((size_t) (regB+0.5) >= (8*sizeof(size_t))) - { - (void) ThrowMagickException ( pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3265, - OptionError, "undefined shift", "%g", (double) regB); - regA = (fxFltType) 0.0; - break; - } - regA = (fxFltType) ((size_t)(regA+0.5) >> (size_t)(regB+0.5)); - break; - case oEq: - regA = fabs((double) (regA-regB)) < 1.0e-12 ? 1.0 : 0.0; - break; - case oNotEq: - regA = fabs((double) (regA-regB)) >= 1.0e-12 ? 1.0 : 0.0; - break; - case oLtEq: - regA = (regA <= regB) ? 1.0 : 0.0; - break; - case oGtEq: - regA = (regA >= regB) ? 1.0 : 0.0; - break; - case oLt: - regA = (regA < regB) ? 1.0 : 0.0; - break; - case oGt: - regA = (regA > regB) ? 1.0 : 0.0; - break; - case oLogAnd: - regA = (regA<=0) ? 0.0 : (regB > 0) ? 1.0 : 0.0; - break; - case oLogOr: - regA = (regA>0) ? 1.0 : (regB > 0.0) ? 1.0 : 0.0; - break; - case oLogNot: - regA = (regA==0) ? 1.0 : 0.0; - break; - case oBitAnd: - regA = (fxFltType) ((size_t)(regA+0.5) & (size_t)(regB+0.5)); - break; - case oBitOr: - regA = (fxFltType) ((size_t)(regA+0.5) | (size_t)(regB+0.5)); - break; - case oBitNot: + break; + case oUnaryMinus: + regA = -regA; + break; + case oLshift: + if ((size_t)(regB + 0.5) >= (8 * sizeof(size_t))) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3255, OptionError, + "undefined shift", "%g", (double)regB); + regA = (fxFltType)0.0; + break; + } + regA = (fxFltType)((size_t)(regA + 0.5) << (size_t)(regB + 0.5)); + break; + case oRshift: + if ((size_t)(regB + 0.5) >= (8 * sizeof(size_t))) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3265, OptionError, + "undefined shift", "%g", (double)regB); + regA = (fxFltType)0.0; + break; + } + regA = (fxFltType)((size_t)(regA + 0.5) >> (size_t)(regB + 0.5)); + break; + case oEq: + regA = fabs((double)(regA - regB)) < 1.0e-12 ? 1.0 : 0.0; + break; + case oNotEq: + regA = fabs((double)(regA - regB)) >= 1.0e-12 ? 1.0 : 0.0; + break; + case oLtEq: + regA = (regA <= regB) ? 1.0 : 0.0; + break; + case oGtEq: + regA = (regA >= regB) ? 1.0 : 0.0; + break; + case oLt: + regA = (regA < regB) ? 1.0 : 0.0; + break; + case oGt: + regA = (regA > regB) ? 1.0 : 0.0; + break; + case oLogAnd: + regA = (regA <= 0) ? 0.0 : (regB > 0) ? 1.0 : 0.0; + break; + case oLogOr: + regA = (regA > 0) ? 1.0 : (regB > 0.0) ? 1.0 : 0.0; + break; + case oLogNot: + regA = (regA == 0) ? 1.0 : 0.0; + break; + case oBitAnd: + regA = (fxFltType)((size_t)(regA + 0.5) & (size_t)(regB + 0.5)); + break; + case oBitOr: + regA = (fxFltType)((size_t)(regA + 0.5) | (size_t)(regB + 0.5)); + break; + case oBitNot: - regA = (fxFltType) (~(size_t)(regA+0.5)); - break; - case oPow: - regA = pow ((double) regA, (double) regB); - break; - case oQuery: - case oColon: - break; - case oOpenParen: - case oCloseParen: - case oOpenBracket: - case oCloseBracket: - case oOpenBrace: - case oCloseBrace: + regA = (fxFltType)(~(size_t)(regA + 0.5)); + break; + case oPow: + regA = pow((double)regA, (double)regB); + break; + case oQuery: + case oColon: + break; + case oOpenParen: + case oCloseParen: + case oOpenBracket: + case oCloseBracket: + case oOpenBrace: + case oCloseBrace: + break; + case oAssign: + pel->val = regA; + break; + case oNull: { + if (pel->type == etColourConstant) { + switch (channel) { + default: + case (PixelChannel)0: + regA = pel->val; break; - case oAssign: - pel->val = regA; + case (PixelChannel)1: + regA = pel->val1; break; - case oNull: { - if (pel->type == etColourConstant) { - switch (channel) { default: - case (PixelChannel) 0: - regA = pel->val; - break; - case (PixelChannel) 1: - regA = pel->val1; - break; - case (PixelChannel) 2: - regA = pel->val2; - break; - } - } else { - regA = pel->val; - } + case (PixelChannel)2: + regA = pel->val2; break; } - case fAbs: - regA = fabs ((double) regA); - break; - - case fAcosh: - regA = acosh ((double) regA); - break; - - case fAcos: - regA = acos ((double) regA); - break; - - case fAiry: - if (regA==0) regA = 1.0; - else { - fxFltType gamma = 2.0 * j1 ((3.14159265358979323846264338327950288419716939937510*regA)) / (3.14159265358979323846264338327950288419716939937510*regA); - regA = gamma * gamma; - } - break; - - case fAlt: - regA = (fxFltType) (((ssize_t) regA) & 0x01 ? -1.0 : 1.0); - break; - - case fAsinh: - regA = asinh ((double) regA); - break; - - case fAsin: - regA = asin ((double) regA); - break; - - case fAtanh: - regA = atanh ((double) regA); - break; - - case fAtan2: - regA = atan2 ((double) regA, (double) regB); - break; - case fAtan: - regA = atan ((double) regA); - break; - case fCeil: - regA = ceil ((double) regA); - break; - case fChannel: - switch (channel) { - case (PixelChannel) 0: break; - case (PixelChannel) 1: regA = regB; break; - case (PixelChannel) 2: regA = regC; break; - case (PixelChannel) 3: regA = regD; break; - case (PixelChannel) 4: regA = regE; break; - default: regA = 0.0; - } - break; - case fClamp: - if (regA < 0) regA = 0.0; - else if (regA > 1.0) regA = 1.0; - break; - case fCosh: - regA = cosh ((double) regA); - break; - case fCos: - regA = cos ((double) regA); - break; - case fDebug: - + } else { + regA = pel->val; + } + break; + } + case fAbs: + regA = fabs((double)regA); + break; - (void) fprintf ( - stderr - , "%s[%g,%g].[%i]: %s=%.*g\n", - img->filename, (double) imgx, (double) imgy, - channel, SetPtrShortExp (pfx, pel->pExpStart, (size_t) (pel->lenExp+1)), - pfx->precision, (double) regA); - break; - case fDrc: - regA = regA / (regB*(regA-1.0) + 1.0); - break; + case fAcosh: + regA = acosh((double)regA); + break; - case fErf: - regA = erf ((double) regA); - break; + case fAcos: + regA = acos((double)regA); + break; - case fExp: - regA = exp ((double) regA); - break; - case fFloor: - regA = floor ((double) regA); - break; - case fGauss: - regA = exp((double) (-regA*regA/2.0))/sqrt(2.0*3.14159265358979323846264338327950288419716939937510); - break; - case fGcd: - if (! - __builtin_isnan ( - regA - ) - ) - regA = FxGcd (regA, regB, 0); - break; - case fHypot: - regA = hypot ((double) regA, (double) regB); - break; - case fInt: - regA = floor ((double) regA); - break; - case fIsnan: - regA = (fxFltType) (!! - __builtin_isnan ( - regA - ) - ); - break; + case fAiry: + if (regA == 0) + regA = 1.0; + else { + fxFltType gamma = + 2.0 * + j1((3.14159265358979323846264338327950288419716939937510 * regA)) / + (3.14159265358979323846264338327950288419716939937510 * regA); + regA = gamma * gamma; + } + break; - case fJ0: - regA = j0 ((double) regA); - break; + case fAlt: + regA = (fxFltType)(((ssize_t)regA) & 0x01 ? -1.0 : 1.0); + break; + case fAsinh: + regA = asinh((double)regA); + break; - case fJ1: - regA = j1 ((double) regA); - break; + case fAsin: + regA = asin((double)regA); + break; + case fAtanh: + regA = atanh((double)regA); + break; - case fJinc: - if (regA==0) regA = 1.0; - else regA = 2.0 * j1 ((3.14159265358979323846264338327950288419716939937510*regA))/(3.14159265358979323846264338327950288419716939937510*regA); - break; + case fAtan2: + regA = atan2((double)regA, (double)regB); + break; + case fAtan: + regA = atan((double)regA); + break; + case fCeil: + regA = ceil((double)regA); + break; + case fChannel: + switch (channel) { + case (PixelChannel)0: + break; + case (PixelChannel)1: + regA = regB; + break; + case (PixelChannel)2: + regA = regC; + break; + case (PixelChannel)3: + regA = regD; + break; + case (PixelChannel)4: + regA = regE; + break; + default: + regA = 0.0; + } + break; + case fClamp: + if (regA < 0) + regA = 0.0; + else if (regA > 1.0) + regA = 1.0; + break; + case fCosh: + regA = cosh((double)regA); + break; + case fCos: + regA = cos((double)regA); + break; + case fDebug: - case fLn: - regA = log ((double) regA); - break; - case fLogtwo: - regA = MagickLog10((double) regA) / log10(2.0); - break; - case fLog: - regA = MagickLog10 ((double) regA); - break; - case fMax: - regA = (regA > regB) ? regA : regB; - break; - case fMin: - regA = (regA < regB) ? regA : regB; - break; - case fMod: - regA = regA - floor((double) (regA*PerceptibleReciprocal((double) regB)))*regB; - break; - case fNot: - regA = (fxFltType) (regA < 1.0e-12); - break; - case fPow: - regA = pow ((double) regA, (double) regB); - break; - case fRand: { + (void)fprintf( + stderr, "%s[%g,%g].[%i]: %s=%.*g\n", img->filename, (double)imgx, + (double)imgy, channel, + SetPtrShortExp(pfx, pel->pExpStart, (size_t)(pel->lenExp + 1)), + pfx->precision, (double)regA); + break; + case fDrc: + regA = regA / (regB * (regA - 1.0) + 1.0); + break; + case fErf: + regA = erf((double)regA); + break; - regA = GetPseudoRandomValue (pfxrt->random_info); - break; - } - case fRound: - regA = floor ((double) regA + 0.5); - break; - case fSign: - regA = (regA < 0) ? -1.0 : 1.0; - break; - case fSinc: - regA = sin ((double) (3.14159265358979323846264338327950288419716939937510*regA)) / (3.14159265358979323846264338327950288419716939937510*regA); - break; - case fSinh: - regA = sinh ((double) regA); - break; - case fSin: - regA = sin ((double) regA); - break; - case fSqrt: - regA = sqrt ((double) regA); - break; - case fSquish: - regA = 1.0 / (1.0 + exp ((double) -regA)); - break; - case fTanh: - regA = tanh ((double) regA); - break; - case fTan: - regA = tan ((double) regA); - break; - case fTrunc: - if (regA >= 0) regA = floor ((double) regA); - else regA = ceil ((double) regA); - break; + case fExp: + regA = exp((double)regA); + break; + case fFloor: + regA = floor((double)regA); + break; + case fGauss: + regA = exp((double)(-regA * regA / 2.0)) / + sqrt(2.0 * 3.14159265358979323846264338327950288419716939937510); + break; + case fGcd: + if (!__builtin_isnan(regA)) + regA = FxGcd(regA, regB, 0); + break; + case fHypot: + regA = hypot((double)regA, (double)regB); + break; + case fInt: + regA = floor((double)regA); + break; + case fIsnan: + regA = (fxFltType)(!!__builtin_isnan(regA)); + break; - case fDo: - case fFor: - case fIf: - case fWhile: - break; - case fU: { - - - - ssize_t ImgNum = ChkImgNum (pfx, regA); - if (ImgNum < 0) break; - regA = (fxFltType) 0; - if (ImgNum == 0) { - Image * pimg = pfx->Images[0]; - int pech = (int)pel->ChannelQual; - if (pel->ImgAttrQual == aNull) { - if (pech < 0) { - if (pech == ((PixelChannel) (-1)) || pech == ((PixelChannel) (-2))) { - if (pfx->ImgNum==0) { - regA = ((double) 1.0/(double) 65535.0f) * p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } else { - const Quantum * pv = GetCacheViewVirtualPixels ( - pfx->Imgs[0].View, imgx, imgy, 1,1, pfx->exception); - if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3550, OptionError, - "fU can't get cache", "%lu", (unsigned long) ImgNum); - break; - } - regA = ((double) 1.0/(double) 65535.0f) * pv[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } - } else if (pech == ((PixelChannel) (-3)) || pech == ((PixelChannel) (-4)) || - pech == ((PixelChannel) (-5))) { - regA = GetHslInt (pfx, ImgNum, imgx, imgy, pech); - break; - } else if (pech == ((PixelChannel) (-6))) { - regA = GetIntensity (pfx, 0, (double) imgx, (double) imgy); - break; - } - } else { - if (pfx->ImgNum==0) { - regA = ((double) 1.0/(double) 65535.0f) * p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } else { - const Quantum * pv = GetCacheViewVirtualPixels ( - pfx->Imgs[0].View, imgx, imgy, 1,1, pfx->exception); - if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3572, OptionError, - "fU can't get cache", "%lu", (unsigned long) ImgNum); - break; - } - regA = ((double) 1.0/(double) 65535.0f) * pv[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } - } - } else { + case fJ0: + regA = j0((double)regA); + break; - regA = ImageStat (pfx, 0, (pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual, pel->ImgAttrQual); - } - } else { + case fJ1: + regA = j1((double)regA); + break; - if (pel->ImgAttrQual == aNull) { - const Quantum * pv; - if ((int)pel->ChannelQual < 0) { - if (pel->ChannelQual == ((PixelChannel) (-3)) || pel->ChannelQual == ((PixelChannel) (-4)) || - pel->ChannelQual == ((PixelChannel) (-5))) - { - regA = GetHslInt (pfx, ImgNum, imgx, imgy, pel->ChannelQual); - break; - } else if (pel->ChannelQual == ((PixelChannel) (-6))) - { - regA = GetIntensity (pfx, ImgNum, (fxFltType) imgx, (fxFltType) imgy); - break; - } - } + case fJinc: + if (regA == 0) + regA = 1.0; + else + regA = + 2.0 * + j1((3.14159265358979323846264338327950288419716939937510 * regA)) / + (3.14159265358979323846264338327950288419716939937510 * regA); + break; - pv = GetCacheViewVirtualPixels ( - pfx->Imgs[ImgNum].View, imgx, imgy, 1,1, pfx->exception); - if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3604, OptionError, - "fU can't get cache", "%lu", (unsigned long) ImgNum); - break; - } - regA = ((double) 1.0/(double) 65535.0f) * - pv[pfx->Images[ImgNum]->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } else { - regA = ImageStat (pfx, ImgNum, (pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual, pel->ImgAttrQual); - } - } - break; - } - case fU0: { + case fLn: + regA = log((double)regA); + break; + case fLogtwo: + regA = MagickLog10((double)regA) / log10(2.0); + break; + case fLog: + regA = MagickLog10((double)regA); + break; + case fMax: + regA = (regA > regB) ? regA : regB; + break; + case fMin: + regA = (regA < regB) ? regA : regB; + break; + case fMod: + regA = regA - + floor((double)(regA * PerceptibleReciprocal((double)regB))) * regB; + break; + case fNot: + regA = (fxFltType)(regA < 1.0e-12); + break; + case fPow: + regA = pow((double)regA, (double)regB); + break; + case fRand: { + regA = GetPseudoRandomValue(pfxrt->random_info); + break; + } + case fRound: + regA = floor((double)regA + 0.5); + break; + case fSign: + regA = (regA < 0) ? -1.0 : 1.0; + break; + case fSinc: + regA = sin((double)(3.14159265358979323846264338327950288419716939937510 * + regA)) / + (3.14159265358979323846264338327950288419716939937510 * regA); + break; + case fSinh: + regA = sinh((double)regA); + break; + case fSin: + regA = sin((double)regA); + break; + case fSqrt: + regA = sqrt((double)regA); + break; + case fSquish: + regA = 1.0 / (1.0 + exp((double)-regA)); + break; + case fTanh: + regA = tanh((double)regA); + break; + case fTan: + regA = tan((double)regA); + break; + case fTrunc: + if (regA >= 0) + regA = floor((double)regA); + else + regA = ceil((double)regA); + break; + case fDo: + case fFor: + case fIf: + case fWhile: + break; + case fU: { - Image * pimg = pfx->Images[0]; - int pech = (int)pel->ChannelQual; + ssize_t ImgNum = ChkImgNum(pfx, regA); + if (ImgNum < 0) + break; + regA = (fxFltType)0; + if (ImgNum == 0) { + Image *pimg = pfx->Images[0]; + int pech = (int)pel->ChannelQual; + if (pel->ImgAttrQual == aNull) { if (pech < 0) { - if (pech == ((PixelChannel) (-1)) || pech == ((PixelChannel) (-2))) { - - if (pfx->ImgNum==0) { - regA = ((double) 1.0/(double) 65535.0f) * p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; + if (pech == ((PixelChannel)(-1)) || pech == ((PixelChannel)(-2))) { + if (pfx->ImgNum == 0) { + regA = ((double)1.0 / (double)65535.0f) * + p[pimg->channel_map + [(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; } else { - const Quantum * pv = GetCacheViewVirtualPixels ( - pfx->Imgs[0].View, imgx, imgy, 1,1, pfx->exception); + const Quantum *pv = GetCacheViewVirtualPixels( + pfx->Imgs[0].View, imgx, imgy, 1, 1, pfx->exception); if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3632, OptionError, - "fU0 can't get cache", "%i", 0); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3550, + OptionError, "fU can't get cache", + "%lu", (unsigned long)ImgNum); break; } - regA = ((double) 1.0/(double) 65535.0f) * pv[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; + regA = ((double)1.0 / (double)65535.0f) * + pv[pimg->channel_map + [(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; } - - } else if (pel->ChannelQual == ((PixelChannel) (-3)) || pel->ChannelQual == ((PixelChannel) (-4)) || - pel->ChannelQual == ((PixelChannel) (-5))) { - regA = GetHslInt (pfx, 0, imgx, imgy, pel->ChannelQual); + } else if (pech == ((PixelChannel)(-3)) || + pech == ((PixelChannel)(-4)) || + pech == ((PixelChannel)(-5))) { + regA = GetHslInt(pfx, ImgNum, imgx, imgy, pech); + break; + } else if (pech == ((PixelChannel)(-6))) { + regA = GetIntensity(pfx, 0, (double)imgx, (double)imgy); break; - } else if (pel->ChannelQual == ((PixelChannel) (-6))) { - regA = GetIntensity (pfx, 0, (fxFltType) imgx, (fxFltType) imgy); } } else { - if (pfx->ImgNum==0) { - regA = ((double) 1.0/(double) 65535.0f) * p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; + if (pfx->ImgNum == 0) { + regA = ((double)1.0 / (double)65535.0f) * + p[pimg->channel_map + [(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; } else { - const Quantum * pv = GetCacheViewVirtualPixels ( - pfx->Imgs[0].View, imgx, imgy, 1,1, pfx->exception); + const Quantum *pv = GetCacheViewVirtualPixels( + pfx->Imgs[0].View, imgx, imgy, 1, 1, pfx->exception); if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3654, OptionError, - "fU0 can't get cache", "%i", 0); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3572, + OptionError, "fU can't get cache", + "%lu", (unsigned long)ImgNum); break; } - regA = ((double) 1.0/(double) 65535.0f) * pv[pimg->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; + regA = ((double)1.0 / (double)65535.0f) * + pv[pimg->channel_map + [(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; } } - break; + } else { + + regA = ImageStat(pfx, 0, + (pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual, + pel->ImgAttrQual); } - case fUP: { - - ssize_t ImgNum = ChkImgNum (pfx, regA); - fxFltType fx, fy; - - if (ImgNum < 0) break; - - if (pel->IsRelative) { - fx = imgx + regB; - fy = imgy + regC; - } else { - fx = regB; - fy = regC; - } + } else { + if (pel->ImgAttrQual == aNull) { + const Quantum *pv; if ((int)pel->ChannelQual < 0) { - if (pel->ChannelQual == ((PixelChannel) (-3)) || pel->ChannelQual == ((PixelChannel) (-4)) - || pel->ChannelQual == ((PixelChannel) (-5))) { - regA = GetHslFlt (pfx, ImgNum, fx, fy, pel->ChannelQual); + if (pel->ChannelQual == ((PixelChannel)(-3)) || + pel->ChannelQual == ((PixelChannel)(-4)) || + pel->ChannelQual == ((PixelChannel)(-5))) { + regA = GetHslInt(pfx, ImgNum, imgx, imgy, pel->ChannelQual); break; - } else if (pel->ChannelQual == ((PixelChannel) (-6))) { - regA = GetIntensity (pfx, ImgNum, fx, fy); + } else if (pel->ChannelQual == ((PixelChannel)(-6))) { + regA = + GetIntensity(pfx, ImgNum, (fxFltType)imgx, (fxFltType)imgy); break; } } - { - double v; - Image * imUP = pfx->Images[ImgNum]; - if (! InterpolatePixelChannel (imUP, pfx->Imgs[ImgNum].View, (pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual, - imUP->interpolate, (double) fx, (double) fy, &v, pfx->exception)) - { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3696, OptionError, - "fUP can't get interpolate", "%lu", (unsigned long) ImgNum); - break; - } - regA = v * ((double) 1.0/(double) 65535.0f); + pv = GetCacheViewVirtualPixels(pfx->Imgs[ImgNum].View, imgx, imgy, 1, + 1, pfx->exception); + if (!pv) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3604, + OptionError, "fU can't get cache", "%lu", + (unsigned long)ImgNum); + break; } - - break; + regA = + ((double)1.0 / (double)65535.0f) * + pv[pfx->Images[ImgNum] + ->channel_map[(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; + } else { + regA = ImageStat(pfx, ImgNum, + (pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual, + pel->ImgAttrQual); } - case fS: - case fV: { - - ssize_t ImgNum = 1; - if (pel->oprNum == fS) ImgNum = pfx->ImgNum; - - if (pel->ImgAttrQual == aNull) { - const Quantum * pv = GetCacheViewVirtualPixels ( - pfx->Imgs[ImgNum].View, imgx, imgy, 1,1, pfx->exception); + } + break; + } + case fU0: { + + Image *pimg = pfx->Images[0]; + int pech = (int)pel->ChannelQual; + if (pech < 0) { + if (pech == ((PixelChannel)(-1)) || pech == ((PixelChannel)(-2))) { + + if (pfx->ImgNum == 0) { + regA = + ((double)1.0 / (double)65535.0f) * + p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; + } else { + const Quantum *pv = GetCacheViewVirtualPixels( + pfx->Imgs[0].View, imgx, imgy, 1, 1, pfx->exception); if (!pv) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3716, OptionError, - "fV can't get cache", "%lu", (unsigned long) ImgNum); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3632, + OptionError, "fU0 can't get cache", + "%i", 0); break; } - - if ((int)pel->ChannelQual < 0) { - if (pel->ChannelQual == ((PixelChannel) (-3)) || pel->ChannelQual == ((PixelChannel) (-4)) || - pel->ChannelQual == ((PixelChannel) (-5))) { - regA = GetHslInt (pfx, ImgNum, imgx, imgy, pel->ChannelQual); - break; - } else if (pel->ChannelQual == ((PixelChannel) (-6))) { - regA = GetIntensity (pfx, ImgNum, (double) imgx, (double) imgy); - break; - } - } - - regA = ((double) 1.0/(double) 65535.0f) * - pv[pfx->Images[ImgNum]->channel_map[(pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual].offset]; - } else { - regA = ImageStat (pfx, ImgNum, (pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual, pel->ImgAttrQual); + regA = ((double)1.0 / (double)65535.0f) * + pv[pimg->channel_map + [(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; } + } else if (pel->ChannelQual == ((PixelChannel)(-3)) || + pel->ChannelQual == ((PixelChannel)(-4)) || + pel->ChannelQual == ((PixelChannel)(-5))) { + regA = GetHslInt(pfx, 0, imgx, imgy, pel->ChannelQual); break; + } else if (pel->ChannelQual == ((PixelChannel)(-6))) { + regA = GetIntensity(pfx, 0, (fxFltType)imgx, (fxFltType)imgy); } - case fP: - case fSP: - case fVP: { - - fxFltType fx, fy; - ssize_t ImgNum = pfx->ImgNum; - if (pel->oprNum == fVP) ImgNum = 1; - if (pel->IsRelative) { - fx = imgx + regA; - fy = imgy + regB; - } else { - fx = regA; - fy = regB; - } - if ((int)pel->ChannelQual < 0) { - if (pel->ChannelQual == ((PixelChannel) (-3)) || pel->ChannelQual == ((PixelChannel) (-4)) || - pel->ChannelQual == ((PixelChannel) (-5))) { - regA = GetHslFlt (pfx, ImgNum, fx, fy, pel->ChannelQual); - break; - } else if (pel->ChannelQual == ((PixelChannel) (-6))) { - regA = GetIntensity (pfx, ImgNum, fx, fy); - break; - } + } else { + if (pfx->ImgNum == 0) { + regA = + ((double)1.0 / (double)65535.0f) * + p[pimg->channel_map[(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; + } else { + const Quantum *pv = GetCacheViewVirtualPixels( + pfx->Imgs[0].View, imgx, imgy, 1, 1, pfx->exception); + if (!pv) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3654, + OptionError, "fU0 can't get cache", "%i", + 0); + break; } + regA = + ((double)1.0 / (double)65535.0f) * + pv[pimg->channel_map[(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; + } + } + break; + } + case fUP: { - { - double v; - - if (! InterpolatePixelChannel (pfx->Images[ImgNum], pfx->Imgs[ImgNum].View, - (pel->ChannelQual == ((PixelChannel) (-1)) || pel->ChannelQual == ((PixelChannel) (-2)) || pel->ChannelQual == CompositePixelChannel ) ? (channel == CompositePixelChannel ? RedPixelChannel: channel) : pel->ChannelQual, pfx->Images[ImgNum]->interpolate, - (double) fx, (double) fy, &v, pfx->exception) - ) - { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3774, OptionError, - "fSP or fVP can't get interp", "%lu", (unsigned long) ImgNum); - break; - } - regA = v * (fxFltType)((double) 1.0/(double) 65535.0f); - } + ssize_t ImgNum = ChkImgNum(pfx, regA); + fxFltType fx, fy; - break; - } - case fNull: - break; - case aDepth: - regA = (fxFltType) GetImageDepth (img, pfx->exception); - break; - case aExtent: - regA = (fxFltType) img->extent; - break; - case aKurtosis: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].kurtosis; - break; - case aMaxima: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].maxima; - break; - case aMean: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].mean; - break; - case aMedian: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].median; - break; - case aMinima: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].minima; - break; - case aPage: - break; - case aPageX: - regA = (fxFltType) img->page.x; - break; - case aPageY: - regA = (fxFltType) img->page.y; - break; - case aPageWid: - regA = (fxFltType) img->page.width; - break; - case aPageHt: - regA = (fxFltType) img->page.height; - break; - case aPrintsize: - break; - case aPrintsizeX: - regA = (fxFltType) PerceptibleReciprocal (img->resolution.x) * img->columns; - break; - case aPrintsizeY: - regA = (fxFltType) PerceptibleReciprocal (img->resolution.y) * img->rows; - break; - case aQuality: - regA = (fxFltType) img->quality; - break; - case aRes: - break; - case aResX: - regA = (fxFltType) img->resolution.x; - break; - case aResY: - regA = (fxFltType) img->resolution.y; - break; - case aSkewness: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].skewness; - break; - case aStdDev: - if ((cs != (ChannelStatistics *) - ((void *)0) - ) && (channel > 0)) - regA = cs[(pel->ChannelQual == ((PixelChannel) (-1))) ? CompositePixelChannel : (pel->ChannelQual == ((PixelChannel) (-2))) ? channel : pel->ChannelQual].standard_deviation; - break; - case aH: - regA = (fxFltType) img->rows; - break; - case aN: - regA = (fxFltType) pfx->ImgListLen; - break; - case aT: - regA = (fxFltType) pfx->ImgNum; - break; - case aW: - regA = (fxFltType) img->columns; - break; - case aZ: - regA = (fxFltType) GetImageDepth (img, pfx->exception); - break; - case aNull: - break; - case sHue: - regA = hue; - break; - case sIntensity: - regA = GetIntensity (pfx, pfx->ImgNum, (double) imgx, (double) imgy); - break; - case sLightness: - regA = lightness; - break; - case sLuma: - case sLuminance: - regA = ((double) 1.0/(double) 65535.0f) * (0.212656 * GetPixelRed (img,p) + - 0.715158 * GetPixelGreen (img,p) + - 0.072186 * GetPixelBlue (img,p)); - break; - case sSaturation: - regA = saturation; - break; - case sA: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelAlpha (img, p); - break; - case sB: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelBlue (img, p); - break; - case sC: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelCyan (img, p); - break; - case sG: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelGreen (img, p); - break; - case sI: - regA = (fxFltType) imgx; - break; - case sJ: - regA = (fxFltType) imgy; - break; - case sK: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelBlack (img, p); - break; - case sM: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelGreen (img, p); - break; - case sO: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelAlpha (img, p); - break; - case sR: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelRed (img, p); - break; - case sY: - regA = ((double) 1.0/(double) 65535.0f) * GetPixelYellow (img, p); - break; - case sNull: - break; + if (ImgNum < 0) + break; - case rGoto: - - ((void) sizeof (( - pel->EleNdx >= 0 - ) ? 1 : 0), __extension__ ({ if ( - pel->EleNdx >= 0 - ) ; else __assert_fail ( - "pel->EleNdx >= 0" - , "MagickCore/fx.c", 3924, __extension__ __PRETTY_FUNCTION__); })) - ; - i = pel->EleNdx-1; - break; - case rIfZeroGoto: - - ((void) sizeof (( - pel->EleNdx >= 0 - ) ? 1 : 0), __extension__ ({ if ( - pel->EleNdx >= 0 - ) ; else __assert_fail ( - "pel->EleNdx >= 0" - , "MagickCore/fx.c", 3928, __extension__ __PRETTY_FUNCTION__); })) - ; - if (fabs((double) regA) < 1.0e-12) i = pel->EleNdx-1; + if (pel->IsRelative) { + fx = imgx + regB; + fy = imgy + regC; + } else { + fx = regB; + fy = regC; + } + + if ((int)pel->ChannelQual < 0) { + if (pel->ChannelQual == ((PixelChannel)(-3)) || + pel->ChannelQual == ((PixelChannel)(-4)) || + pel->ChannelQual == ((PixelChannel)(-5))) { + regA = GetHslFlt(pfx, ImgNum, fx, fy, pel->ChannelQual); break; - case rIfNotZeroGoto: - - ((void) sizeof (( - pel->EleNdx >= 0 - ) ? 1 : 0), __extension__ ({ if ( - pel->EleNdx >= 0 - ) ; else __assert_fail ( - "pel->EleNdx >= 0" - , "MagickCore/fx.c", 3932, __extension__ __PRETTY_FUNCTION__); })) - ; - if (fabs((double) regA) > 1.0e-12) i = pel->EleNdx-1; + } else if (pel->ChannelQual == ((PixelChannel)(-6))) { + regA = GetIntensity(pfx, ImgNum, fx, fy); break; - case rCopyFrom: - - ((void) sizeof (( - pel->EleNdx >= 0 - ) ? 1 : 0), __extension__ ({ if ( - pel->EleNdx >= 0 - ) ; else __assert_fail ( - "pel->EleNdx >= 0" - , "MagickCore/fx.c", 3936, __extension__ __PRETTY_FUNCTION__); })) - ; - regA = pfxrt->UserSymVals[pel->EleNdx]; + } + } + + { + double v; + Image *imUP = pfx->Images[ImgNum]; + if (!InterpolatePixelChannel( + imUP, pfx->Imgs[ImgNum].View, + (pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel ? RedPixelChannel + : channel) + : pel->ChannelQual, + imUP->interpolate, (double)fx, (double)fy, &v, + pfx->exception)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3696, OptionError, + "fUP can't get interpolate", "%lu", + (unsigned long)ImgNum); break; - case rCopyTo: - - ((void) sizeof (( - pel->EleNdx >= 0 - ) ? 1 : 0), __extension__ ({ if ( - pel->EleNdx >= 0 - ) ; else __assert_fail ( - "pel->EleNdx >= 0" - , "MagickCore/fx.c", 3940, __extension__ __PRETTY_FUNCTION__); })) - ; - pfxrt->UserSymVals[pel->EleNdx] = regA; + } + regA = v * ((double)1.0 / (double)65535.0f); + } + + break; + } + case fS: + case fV: { + + ssize_t ImgNum = 1; + if (pel->oprNum == fS) + ImgNum = pfx->ImgNum; + + if (pel->ImgAttrQual == aNull) { + const Quantum *pv = GetCacheViewVirtualPixels( + pfx->Imgs[ImgNum].View, imgx, imgy, 1, 1, pfx->exception); + if (!pv) { + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)3716, + OptionError, "fV can't get cache", "%lu", (unsigned long)ImgNum); break; - case rZerStk: - pfxrt->usedValStack = 0; + } + + if ((int)pel->ChannelQual < 0) { + if (pel->ChannelQual == ((PixelChannel)(-3)) || + pel->ChannelQual == ((PixelChannel)(-4)) || + pel->ChannelQual == ((PixelChannel)(-5))) { + regA = GetHslInt(pfx, ImgNum, imgx, imgy, pel->ChannelQual); + break; + } else if (pel->ChannelQual == ((PixelChannel)(-6))) { + regA = GetIntensity(pfx, ImgNum, (double)imgx, (double)imgy); + break; + } + } + + regA = ((double)1.0 / (double)65535.0f) * + pv[pfx->Images[ImgNum] + ->channel_map[(pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel + ? RedPixelChannel + : channel) + : pel->ChannelQual] + .offset]; + } else { + regA = ImageStat(pfx, ImgNum, + (pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual, + pel->ImgAttrQual); + } + + break; + } + case fP: + case fSP: + case fVP: { + + fxFltType fx, fy; + ssize_t ImgNum = pfx->ImgNum; + if (pel->oprNum == fVP) + ImgNum = 1; + if (pel->IsRelative) { + fx = imgx + regA; + fy = imgy + regB; + } else { + fx = regA; + fy = regB; + } + if ((int)pel->ChannelQual < 0) { + if (pel->ChannelQual == ((PixelChannel)(-3)) || + pel->ChannelQual == ((PixelChannel)(-4)) || + pel->ChannelQual == ((PixelChannel)(-5))) { + regA = GetHslFlt(pfx, ImgNum, fx, fy, pel->ChannelQual); break; - case rNull: + } else if (pel->ChannelQual == ((PixelChannel)(-6))) { + regA = GetIntensity(pfx, ImgNum, fx, fy); break; + } + } - default: - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3951, OptionError, - "pel->oprNum", "%i '%s' not yet implemented", - (int)pel->oprNum, OprStr(pel->oprNum)); + { + double v; + + if (!InterpolatePixelChannel( + pfx->Images[ImgNum], pfx->Imgs[ImgNum].View, + (pel->ChannelQual == ((PixelChannel)(-1)) || + pel->ChannelQual == ((PixelChannel)(-2)) || + pel->ChannelQual == CompositePixelChannel) + ? (channel == CompositePixelChannel ? RedPixelChannel + : channel) + : pel->ChannelQual, + pfx->Images[ImgNum]->interpolate, (double)fx, (double)fy, &v, + pfx->exception)) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", + __func__, (unsigned long)3774, OptionError, + "fSP or fVP can't get interp", "%lu", + (unsigned long)ImgNum); break; + } + regA = v * (fxFltType)((double)1.0 / (double)65535.0f); + } + + break; + } + case fNull: + break; + case aDepth: + regA = (fxFltType)GetImageDepth(img, pfx->exception); + break; + case aExtent: + regA = (fxFltType)img->extent; + break; + case aKurtosis: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .kurtosis; + break; + case aMaxima: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .maxima; + break; + case aMean: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .mean; + break; + case aMedian: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .median; + break; + case aMinima: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .minima; + break; + case aPage: + break; + case aPageX: + regA = (fxFltType)img->page.x; + break; + case aPageY: + regA = (fxFltType)img->page.y; + break; + case aPageWid: + regA = (fxFltType)img->page.width; + break; + case aPageHt: + regA = (fxFltType)img->page.height; + break; + case aPrintsize: + break; + case aPrintsizeX: + regA = (fxFltType)PerceptibleReciprocal(img->resolution.x) * img->columns; + break; + case aPrintsizeY: + regA = (fxFltType)PerceptibleReciprocal(img->resolution.y) * img->rows; + break; + case aQuality: + regA = (fxFltType)img->quality; + break; + case aRes: + break; + case aResX: + regA = (fxFltType)img->resolution.x; + break; + case aResY: + regA = (fxFltType)img->resolution.y; + break; + case aSkewness: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .skewness; + break; + case aStdDev: + if ((cs != (ChannelStatistics *)((void *)0)) && (channel > 0)) + regA = cs[(pel->ChannelQual == ((PixelChannel)(-1))) + ? CompositePixelChannel + : (pel->ChannelQual == ((PixelChannel)(-2))) + ? channel + : pel->ChannelQual] + .standard_deviation; + break; + case aH: + regA = (fxFltType)img->rows; + break; + case aN: + regA = (fxFltType)pfx->ImgListLen; + break; + case aT: + regA = (fxFltType)pfx->ImgNum; + break; + case aW: + regA = (fxFltType)img->columns; + break; + case aZ: + regA = (fxFltType)GetImageDepth(img, pfx->exception); + break; + case aNull: + break; + case sHue: + regA = hue; + break; + case sIntensity: + regA = GetIntensity(pfx, pfx->ImgNum, (double)imgx, (double)imgy); + break; + case sLightness: + regA = lightness; + break; + case sLuma: + case sLuminance: + regA = + ((double)1.0 / (double)65535.0f) * + (0.212656 * GetPixelRed(img, p) + 0.715158 * GetPixelGreen(img, p) + + 0.072186 * GetPixelBlue(img, p)); + break; + case sSaturation: + regA = saturation; + break; + case sA: + regA = ((double)1.0 / (double)65535.0f) * GetPixelAlpha(img, p); + break; + case sB: + regA = ((double)1.0 / (double)65535.0f) * GetPixelBlue(img, p); + break; + case sC: + regA = ((double)1.0 / (double)65535.0f) * GetPixelCyan(img, p); + break; + case sG: + regA = ((double)1.0 / (double)65535.0f) * GetPixelGreen(img, p); + break; + case sI: + regA = (fxFltType)imgx; + break; + case sJ: + regA = (fxFltType)imgy; + break; + case sK: + regA = ((double)1.0 / (double)65535.0f) * GetPixelBlack(img, p); + break; + case sM: + regA = ((double)1.0 / (double)65535.0f) * GetPixelGreen(img, p); + break; + case sO: + regA = ((double)1.0 / (double)65535.0f) * GetPixelAlpha(img, p); + break; + case sR: + regA = ((double)1.0 / (double)65535.0f) * GetPixelRed(img, p); + break; + case sY: + regA = ((double)1.0 / (double)65535.0f) * GetPixelYellow(img, p); + break; + case sNull: + break; + + case rGoto: + + ((void)sizeof((pel->EleNdx >= 0) ? 1 : 0), __extension__({ + if (pel->EleNdx >= 0) + ; + else + __assert_fail("pel->EleNdx >= 0", "MagickCore/fx.c", 3924, + __extension__ __PRETTY_FUNCTION__); + })); + i = pel->EleNdx - 1; + break; + case rIfZeroGoto: + + ((void)sizeof((pel->EleNdx >= 0) ? 1 : 0), __extension__({ + if (pel->EleNdx >= 0) + ; + else + __assert_fail("pel->EleNdx >= 0", "MagickCore/fx.c", 3928, + __extension__ __PRETTY_FUNCTION__); + })); + if (fabs((double)regA) < 1.0e-12) + i = pel->EleNdx - 1; + break; + case rIfNotZeroGoto: + + ((void)sizeof((pel->EleNdx >= 0) ? 1 : 0), __extension__({ + if (pel->EleNdx >= 0) + ; + else + __assert_fail("pel->EleNdx >= 0", "MagickCore/fx.c", 3932, + __extension__ __PRETTY_FUNCTION__); + })); + if (fabs((double)regA) > 1.0e-12) + i = pel->EleNdx - 1; + break; + case rCopyFrom: + + ((void)sizeof((pel->EleNdx >= 0) ? 1 : 0), __extension__({ + if (pel->EleNdx >= 0) + ; + else + __assert_fail("pel->EleNdx >= 0", "MagickCore/fx.c", 3936, + __extension__ __PRETTY_FUNCTION__); + })); + regA = pfxrt->UserSymVals[pel->EleNdx]; + break; + case rCopyTo: + + ((void)sizeof((pel->EleNdx >= 0) ? 1 : 0), __extension__({ + if (pel->EleNdx >= 0) + ; + else + __assert_fail("pel->EleNdx >= 0", "MagickCore/fx.c", 3940, + __extension__ __PRETTY_FUNCTION__); + })); + pfxrt->UserSymVals[pel->EleNdx] = regA; + break; + case rZerStk: + pfxrt->usedValStack = 0; + break; + case rNull: + break; + + default: + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3951, OptionError, + "pel->oprNum", "%i '%s' not yet implemented", + (int)pel->oprNum, OprStr(pel->oprNum)); + break; } if (i < 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3958, OptionError, - "Bad run-time address", "%i", i); + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)3958, OptionError, + "Bad run-time address", "%i", i); } if (pel->DoPush) - if (!PushVal (pfx, pfxrt, regA, i)) break; + if (!PushVal(pfx, pfxrt, regA, i)) + break; } - if (pfxrt->usedValStack > 0) regA = PopVal (pfx, pfxrt, 9999); + if (pfxrt->usedValStack > 0) + regA = PopVal(pfx, pfxrt, 9999); *result = regA; - if (NeedRelinq) cs = (ChannelStatistics *)RelinquishMagickMemory (cs); + if (NeedRelinq) + cs = (ChannelStatistics *)RelinquishMagickMemory(cs); if (pfx->exception->severity != UndefinedException) { return MagickFalse; } if (pfxrt->usedValStack != 0) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 3977, OptionError, - "ValStack not empty", "(%i)", pfxrt->usedValStack); + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)3977, + OptionError, "ValStack not empty", "(%i)", pfxrt->usedValStack); return MagickFalse; } return MagickTrue; } - - -__attribute__ ((visibility ("hidden"))) MagickBooleanType FxEvaluateChannelExpression ( - FxInfo *pfx, - const PixelChannel channel, const ssize_t x, const ssize_t y, - double *result, ExceptionInfo *exception) -{ - const int - id = GetOpenMPThreadId(); +__attribute__((visibility("hidden"))) MagickBooleanType +FxEvaluateChannelExpression(FxInfo *pfx, const PixelChannel channel, + const ssize_t x, const ssize_t y, double *result, + ExceptionInfo *exception) { + const int id = GetOpenMPThreadId(); fxFltType ret; - - ((void) sizeof (( - pfx != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx != - ((void *)0)) ; else __assert_fail ( - "pfx != NULL" - , "MagickCore/fx.c", 3997, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->image != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->image != - ((void *)0)) ; else __assert_fail ( - "pfx->image != NULL" - , "MagickCore/fx.c", 3998, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Images != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Images != - ((void *)0)) ; else __assert_fail ( - "pfx->Images != NULL" - , "MagickCore/fx.c", 3999, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Imgs != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Imgs != - ((void *)0)) ; else __assert_fail ( - "pfx->Imgs != NULL" - , "MagickCore/fx.c", 4000, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->fxrts != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->fxrts != - ((void *)0)) ; else __assert_fail ( - "pfx->fxrts != NULL" - , "MagickCore/fx.c", 4001, __extension__ __PRETTY_FUNCTION__); })) - ; - - pfx->fxrts[id].thisPixel = - ((void *)0) - ; - - if (!ExecuteRPN (pfx, &pfx->fxrts[id], &ret, channel, x, y)) { - (void) ThrowMagickException ( - exception, "MagickCore/fx.c",__func__,(unsigned long) 4007, OptionError, - "ExecuteRPN failed", " "); + ((void)sizeof((pfx != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx != ((void *)0)) + ; + else + __assert_fail("pfx != NULL", "MagickCore/fx.c", 3997, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->image != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->image != ((void *)0)) + ; + else + __assert_fail("pfx->image != NULL", "MagickCore/fx.c", 3998, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Images != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Images != ((void *)0)) + ; + else + __assert_fail("pfx->Images != NULL", "MagickCore/fx.c", 3999, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Imgs != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Imgs != ((void *)0)) + ; + else + __assert_fail("pfx->Imgs != NULL", "MagickCore/fx.c", 4000, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->fxrts != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->fxrts != ((void *)0)) + ; + else + __assert_fail("pfx->fxrts != NULL", "MagickCore/fx.c", 4001, + __extension__ __PRETTY_FUNCTION__); + })); + + pfx->fxrts[id].thisPixel = ((void *)0); + + if (!ExecuteRPN(pfx, &pfx->fxrts[id], &ret, channel, x, y)) { + (void)ThrowMagickException(exception, "MagickCore/fx.c", __func__, + (unsigned long)4007, OptionError, + "ExecuteRPN failed", " "); return MagickFalse; } - *result = (double) ret; + *result = (double)ret; return MagickTrue; } -static FxInfo *AcquireFxInfoPrivate (const Image * images, const char * expression, - MagickBooleanType CalcAllStats, ExceptionInfo *exception) -{ +static FxInfo *AcquireFxInfoPrivate(const Image *images, const char *expression, + MagickBooleanType CalcAllStats, + ExceptionInfo *exception) { char chLimit; - FxInfo * pfx = (FxInfo*) AcquireCriticalMemory (sizeof (*pfx)); + FxInfo *pfx = (FxInfo *)AcquireCriticalMemory(sizeof(*pfx)); - memset (pfx, 0, sizeof (*pfx)); + memset(pfx, 0, sizeof(*pfx)); - if (!InitFx (pfx, images, CalcAllStats, exception)) { - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + if (!InitFx(pfx, images, CalcAllStats, exception)) { + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } - if (!BuildRPN (pfx)) { - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return((FxInfo *) - ((void *)0) - ); + if (!BuildRPN(pfx)) { + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((FxInfo *)((void *)0)); } - if ((*expression == '@') && (strlen(expression) > 1)) - { - MagickBooleanType - status; - + if ((*expression == '@') && (strlen(expression) > 1)) { + MagickBooleanType status; + status = IsRightsAuthorized(PathPolicyDomain, ReadPolicyRights, expression); + if (status != MagickFalse) + pfx->expression = FileToString(expression + 1, ~0UL, exception); + else { - - status=IsRightsAuthorized(PathPolicyDomain,ReadPolicyRights,expression); - if (status != MagickFalse) - pfx->expression=FileToString(expression+1,~0UL,exception); - else - { - - (*__errno_location ()) - = - 1 - ; - (void) ThrowMagickException(exception,"MagickCore/fx.c",__func__,(unsigned long) 4051,PolicyError, - "NotAuthorized","`%s'",expression); - } + (*__errno_location()) = 1; + (void)ThrowMagickException(exception, "MagickCore/fx.c", __func__, + (unsigned long)4051, PolicyError, + "NotAuthorized", "`%s'", expression); } - if (pfx->expression == (char *) - ((void *)0) - ) - pfx->expression=ConstantString(expression); - pfx->pex = (char *) pfx->expression; + } + if (pfx->expression == (char *)((void *)0)) + pfx->expression = ConstantString(expression); + pfx->pex = (char *)pfx->expression; pfx->teDepth = 0; - if (!TranslateStatementList (pfx, ";", &chLimit)) { - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + if (!TranslateStatementList(pfx, ";", &chLimit)) { + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } if (pfx->teDepth) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 4071, OptionError, - "Translate expression depth", "(%i) not 0", - pfx->teDepth); - - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)4071, + OptionError, "Translate expression depth", "(%i) not 0", pfx->teDepth); + + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } if (chLimit != '\0' && chLimit != ';') { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 4085, OptionError, - "AcquireFxInfo: TranslateExpression did not exhaust input", "(chLimit=%i) at'%s'", - (int)chLimit, pfx->pex); - - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + (void)ThrowMagickException( + pfx->exception, "MagickCore/fx.c", __func__, (unsigned long)4085, + OptionError, "AcquireFxInfo: TranslateExpression did not exhaust input", + "(chLimit=%i) at'%s'", (int)chLimit, pfx->pex); + + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } if (pfx->NeedStats && pfx->runType == rtEntireImage && !pfx->statistics) { - if (!CollectStatistics (pfx)) { - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + if (!CollectStatistics(pfx)) { + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } } if (pfx->DebugOpt) { - DumpTables ( - stderr - ); - DumpUserSymbols (pfx, - stderr - ); - (void) DumpRPN (pfx, - stderr - ); + DumpTables(stderr); + DumpUserSymbols(pfx, stderr); + (void)DumpRPN(pfx, stderr); } { - size_t number_threads=(size_t) GetMagickResourceLimit(ThreadResource); + size_t number_threads = (size_t)GetMagickResourceLimit(ThreadResource); ssize_t t; - pfx->fxrts = (fxRtT *)AcquireQuantumMemory (number_threads, sizeof(fxRtT)); + pfx->fxrts = (fxRtT *)AcquireQuantumMemory(number_threads, sizeof(fxRtT)); if (!pfx->fxrts) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 4121, ResourceLimitFatalError, - "fxrts", "%lu", - (unsigned long) number_threads); - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)4121, ResourceLimitFatalError, + "fxrts", "%lu", (unsigned long)number_threads); + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } - for (t=0; t < (ssize_t) number_threads; t++) { - if (!AllocFxRt (pfx, &pfx->fxrts[t])) { - (void) ThrowMagickException ( - pfx->exception, "MagickCore/fx.c",__func__,(unsigned long) 4134, ResourceLimitFatalError, - "AllocFxRt t=", "%g", - (double) t); + for (t = 0; t < (ssize_t)number_threads; t++) { + if (!AllocFxRt(pfx, &pfx->fxrts[t])) { + (void)ThrowMagickException(pfx->exception, "MagickCore/fx.c", __func__, + (unsigned long)4134, ResourceLimitFatalError, + "AllocFxRt t=", "%g", (double)t); { ssize_t t2; - for (t2 = t-1; t2 >= 0; t2--) { - DestroyFxRt (&pfx->fxrts[t]); + for (t2 = t - 1; t2 >= 0; t2--) { + DestroyFxRt(&pfx->fxrts[t]); } } - pfx->fxrts = (fxRtT *) RelinquishMagickMemory (pfx->fxrts); - (void) DestroyRPN (pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; - (void) DeInitFx (pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + pfx->fxrts = (fxRtT *)RelinquishMagickMemory(pfx->fxrts); + (void)DestroyRPN(pfx); + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); + (void)DeInitFx(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); + return ((void *)0); } } } return pfx; } -FxInfo *AcquireFxInfo (const Image * images, const char * expression, ExceptionInfo *exception) -{ - return AcquireFxInfoPrivate (images, expression, MagickFalse, exception); +FxInfo *AcquireFxInfo(const Image *images, const char *expression, + ExceptionInfo *exception) { + return AcquireFxInfoPrivate(images, expression, MagickFalse, exception); } -FxInfo *DestroyFxInfo (FxInfo * pfx) -{ +FxInfo *DestroyFxInfo(FxInfo *pfx) { ssize_t t; - - ((void) sizeof (( - pfx != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx != - ((void *)0)) ; else __assert_fail ( - "pfx != NULL" - , "MagickCore/fx.c", 4165, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->image != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->image != - ((void *)0)) ; else __assert_fail ( - "pfx->image != NULL" - , "MagickCore/fx.c", 4166, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Images != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Images != - ((void *)0)) ; else __assert_fail ( - "pfx->Images != NULL" - , "MagickCore/fx.c", 4167, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Imgs != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Imgs != - ((void *)0)) ; else __assert_fail ( - "pfx->Imgs != NULL" - , "MagickCore/fx.c", 4168, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->fxrts != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->fxrts != - ((void *)0)) ; else __assert_fail ( - "pfx->fxrts != NULL" - , "MagickCore/fx.c", 4169, __extension__ __PRETTY_FUNCTION__); })) - ; - - for (t=0; t < (ssize_t) GetMagickResourceLimit(ThreadResource); t++) { - DestroyFxRt (&pfx->fxrts[t]); + ((void)sizeof((pfx != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx != ((void *)0)) + ; + else + __assert_fail("pfx != NULL", "MagickCore/fx.c", 4165, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->image != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->image != ((void *)0)) + ; + else + __assert_fail("pfx->image != NULL", "MagickCore/fx.c", 4166, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Images != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Images != ((void *)0)) + ; + else + __assert_fail("pfx->Images != NULL", "MagickCore/fx.c", 4167, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Imgs != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Imgs != ((void *)0)) + ; + else + __assert_fail("pfx->Imgs != NULL", "MagickCore/fx.c", 4168, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->fxrts != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->fxrts != ((void *)0)) + ; + else + __assert_fail("pfx->fxrts != NULL", "MagickCore/fx.c", 4169, + __extension__ __PRETTY_FUNCTION__); + })); + + for (t = 0; t < (ssize_t)GetMagickResourceLimit(ThreadResource); t++) { + DestroyFxRt(&pfx->fxrts[t]); } - pfx->fxrts = (fxRtT *) RelinquishMagickMemory (pfx->fxrts); + pfx->fxrts = (fxRtT *)RelinquishMagickMemory(pfx->fxrts); - DestroyRPN (pfx); + DestroyRPN(pfx); - pfx->expression = DestroyString (pfx->expression); - pfx->pex = - ((void *)0) - ; + pfx->expression = DestroyString(pfx->expression); + pfx->pex = ((void *)0); - (void) DeInitFx (pfx); + (void)DeInitFx(pfx); - pfx = (FxInfo*) RelinquishMagickMemory(pfx); + pfx = (FxInfo *)RelinquishMagickMemory(pfx); - return - ((void *)0) - ; + return ((void *)0); } +__attribute__((visibility("default"))) Image * +FxImage(const Image *image, const char *expression, ExceptionInfo *exception) { + CacheView *fx_view, *image_view; -__attribute__ ((visibility ("default"))) Image *FxImage(const Image *image,const char *expression, - ExceptionInfo *exception) -{ + Image *fx_image; + MagickBooleanType status; - CacheView - *fx_view, - *image_view; - - Image - *fx_image; - - MagickBooleanType - status; - - MagickOffsetType - progress; - - ssize_t - y; - - FxInfo - *pfx; - - - ((void) sizeof (( - image != (Image *) - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - image != (Image *) - ((void *)0)) ; else __assert_fail ( - "image != (Image *) NULL" - , "MagickCore/fx.c", 4214, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - image->signature == 0xabacadabUL - ) ? 1 : 0), __extension__ ({ if ( - image->signature == 0xabacadabUL - ) ; else __assert_fail ( - "image->signature == MagickCoreSignature" - , "MagickCore/fx.c", 4215, __extension__ __PRETTY_FUNCTION__); })) - ; - if (IsEventLogging() != MagickFalse) - (void) LogMagickEvent(TraceEvent,"MagickCore/fx.c",__func__,(unsigned long) 4217,"%s",image->filename); - if (expression == (const char *) - ((void *)0) - ) - return(CloneImage(image,0,0,MagickTrue,exception)); - fx_image=CloneImage(image,0,0,MagickTrue,exception); - if (!fx_image) return - ((void *)0) - ; - if (SetImageStorageClass(fx_image,DirectClass,exception) == MagickFalse) { - fx_image=DestroyImage(fx_image); - return - ((void *)0) - ; - } + MagickOffsetType progress; - pfx = AcquireFxInfoPrivate (image, expression, MagickTrue, exception); + ssize_t y; - if (!pfx) { - fx_image=DestroyImage(fx_image); - return - ((void *)0) - ; - } + FxInfo *pfx; - - ((void) sizeof (( - pfx->image != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->image != - ((void *)0)) ; else __assert_fail ( - "pfx->image != NULL" - , "MagickCore/fx.c", 4234, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Images != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Images != - ((void *)0)) ; else __assert_fail ( - "pfx->Images != NULL" - , "MagickCore/fx.c", 4235, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->Imgs != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->Imgs != - ((void *)0)) ; else __assert_fail ( - "pfx->Imgs != NULL" - , "MagickCore/fx.c", 4236, __extension__ __PRETTY_FUNCTION__); })) - ; - - ((void) sizeof (( - pfx->fxrts != - ((void *)0)) ? 1 : 0), __extension__ ({ if ( - pfx->fxrts != - ((void *)0)) ; else __assert_fail ( - "pfx->fxrts != NULL" - , "MagickCore/fx.c", 4237, __extension__ __PRETTY_FUNCTION__); })) - ; - - status=MagickTrue; - progress=0; - image_view = AcquireVirtualCacheView (image, pfx->exception); - fx_view = AcquireAuthenticCacheView (fx_image, pfx->exception); - - - - - for (y=0; y < (ssize_t) fx_image->rows; y++) - { - const int - id = GetOpenMPThreadId(); + ((void)sizeof((image != (Image *)((void *)0)) ? 1 : 0), __extension__({ + if (image != (Image *)((void *)0)) + ; + else + __assert_fail("image != (Image *) NULL", "MagickCore/fx.c", 4214, + __extension__ __PRETTY_FUNCTION__); + })); - const Quantum - *__restrict__ p; + ((void)sizeof((image->signature == 0xabacadabUL) ? 1 : 0), __extension__({ + if (image->signature == 0xabacadabUL) + ; + else + __assert_fail("image->signature == MagickCoreSignature", + "MagickCore/fx.c", 4215, + __extension__ __PRETTY_FUNCTION__); + })); + if (IsEventLogging() != MagickFalse) + (void)LogMagickEvent(TraceEvent, "MagickCore/fx.c", __func__, + (unsigned long)4217, "%s", image->filename); + if (expression == (const char *)((void *)0)) + return (CloneImage(image, 0, 0, MagickTrue, exception)); + fx_image = CloneImage(image, 0, 0, MagickTrue, exception); + if (!fx_image) + return ((void *)0); + if (SetImageStorageClass(fx_image, DirectClass, exception) == MagickFalse) { + fx_image = DestroyImage(fx_image); + return ((void *)0); + } - Quantum - *__restrict__ q; + pfx = AcquireFxInfoPrivate(image, expression, MagickTrue, exception); - ssize_t - x; + if (!pfx) { + fx_image = DestroyImage(fx_image); + return ((void *)0); + } - fxFltType - result = 0.0; + ((void)sizeof((pfx->image != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->image != ((void *)0)) + ; + else + __assert_fail("pfx->image != NULL", "MagickCore/fx.c", 4234, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Images != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Images != ((void *)0)) + ; + else + __assert_fail("pfx->Images != NULL", "MagickCore/fx.c", 4235, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->Imgs != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->Imgs != ((void *)0)) + ; + else + __assert_fail("pfx->Imgs != NULL", "MagickCore/fx.c", 4236, + __extension__ __PRETTY_FUNCTION__); + })); + + ((void)sizeof((pfx->fxrts != ((void *)0)) ? 1 : 0), __extension__({ + if (pfx->fxrts != ((void *)0)) + ; + else + __assert_fail("pfx->fxrts != NULL", "MagickCore/fx.c", 4237, + __extension__ __PRETTY_FUNCTION__); + })); + + status = MagickTrue; + progress = 0; + image_view = AcquireVirtualCacheView(image, pfx->exception); + fx_view = AcquireAuthenticCacheView(fx_image, pfx->exception); + + for (y = 0; y < (ssize_t)fx_image->rows; y++) { + const int id = GetOpenMPThreadId(); + + const Quantum *__restrict__ p; + + Quantum *__restrict__ q; + + ssize_t x; + + fxFltType result = 0.0; if (status == MagickFalse) continue; - p = GetCacheViewVirtualPixels (image_view, 0, y, image->columns, 1, pfx->exception); - q = QueueCacheViewAuthenticPixels (fx_view, 0, y, fx_image->columns, 1, pfx->exception); - if ((p == (const Quantum *) - ((void *)0) - ) || (q == (Quantum *) - ((void *)0) - )) { - status=MagickFalse; - continue; + p = GetCacheViewVirtualPixels(image_view, 0, y, image->columns, 1, + pfx->exception); + q = QueueCacheViewAuthenticPixels(fx_view, 0, y, fx_image->columns, 1, + pfx->exception); + if ((p == (const Quantum *)((void *)0)) || (q == (Quantum *)((void *)0))) { + status = MagickFalse; + continue; } - for (x=0; x < (ssize_t) fx_image->columns; x++) { + for (x = 0; x < (ssize_t)fx_image->columns; x++) { ssize_t i; pfx->fxrts[id].thisPixel = (Quantum *)p; - for (i=0; i < (ssize_t) GetPixelChannels(image); i++) - { - PixelChannel channel = GetPixelChannelChannel (image, i); - PixelTrait traits = GetPixelChannelTraits (image, channel); - PixelTrait fx_traits = GetPixelChannelTraits (fx_image, channel); + for (i = 0; i < (ssize_t)GetPixelChannels(image); i++) { + PixelChannel channel = GetPixelChannelChannel(image, i); + PixelTrait traits = GetPixelChannelTraits(image, channel); + PixelTrait fx_traits = GetPixelChannelTraits(fx_image, channel); if ((traits == UndefinedPixelTrait) || (fx_traits == UndefinedPixelTrait)) continue; if ((fx_traits & CopyPixelTrait) != 0) { - SetPixelChannel (fx_image, channel, p[i], q); - continue; + SetPixelChannel(fx_image, channel, p[i], q); + continue; } - if (!ExecuteRPN (pfx, &pfx->fxrts[id], &result, channel, x, y)) { - status=MagickFalse; + if (!ExecuteRPN(pfx, &pfx->fxrts[id], &result, channel, x, y)) { + status = MagickFalse; break; } - q[i] = ClampToQuantum ((MagickRealType) (65535.0f*result)); + q[i] = ClampToQuantum((MagickRealType)(65535.0f * result)); } - p+=GetPixelChannels (image); - q+=GetPixelChannels (fx_image); + p += GetPixelChannels(image); + q += GetPixelChannels(fx_image); } if (SyncCacheViewAuthenticPixels(fx_view, pfx->exception) == MagickFalse) - status=MagickFalse; - if (image->progress_monitor != (MagickProgressMonitor) - ((void *)0) - ) - { - MagickBooleanType - proceed; - - - - progress++; - proceed = SetImageProgress (image, "FxNew/Image", progress, image->rows); - if (proceed == MagickFalse) - status=MagickFalse; - } + status = MagickFalse; + if (image->progress_monitor != (MagickProgressMonitor)((void *)0)) { + MagickBooleanType proceed; + + progress++; + proceed = SetImageProgress(image, "FxNew/Image", progress, image->rows); + if (proceed == MagickFalse) + status = MagickFalse; + } } - fx_view = DestroyCacheView (fx_view); - image_view = DestroyCacheView (image_view); - - + fx_view = DestroyCacheView(fx_view); + image_view = DestroyCacheView(image_view); if (pfx->DebugOpt && pfx->usedUserSymbols) { int t, i; char UserSym[4096]; - fprintf ( - stderr - , "User symbols (%i):\n", pfx->usedUserSymbols); - for (t=0; t < (int) GetMagickResourceLimit(ThreadResource); t++) { - for (i = 0; i < (int) pfx->usedUserSymbols; i++) { - fprintf ( - stderr - , "th=%i us=%i '%s': %.*Lg\n", - t, i, NameOfUserSym (pfx, i, UserSym), pfx->precision, pfx->fxrts[t].UserSymVals[i]); + fprintf(stderr, "User symbols (%i):\n", pfx->usedUserSymbols); + for (t = 0; t < (int)GetMagickResourceLimit(ThreadResource); t++) { + for (i = 0; i < (int)pfx->usedUserSymbols; i++) { + fprintf(stderr, "th=%i us=%i '%s': %.*Lg\n", t, i, + NameOfUserSym(pfx, i, UserSym), pfx->precision, + pfx->fxrts[t].UserSymVals[i]); } } } @@ -21938,9 +18221,9 @@ __attribute__ ((visibility ("default"))) Image *FxImage(const Image *image,const } if (status == MagickFalse) - fx_image = DestroyImage (fx_image); + fx_image = DestroyImage(fx_image); - pfx = DestroyFxInfo (pfx); + pfx = DestroyFxInfo(pfx); - return(fx_image); + return (fx_image); } -- 2.49.0