From 37122df2cbc7630a13a293a544a88404a6e5d71e Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 25 Oct 2023 14:08:17 -0400 Subject: [PATCH 01/43] make api.h to support wasm64 --- libc-bottom-half/headers/public/wasi/api.h | 28 ++++++++-------------- 1 file changed, 10 insertions(+), 18 deletions(-) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 45a6506e2..43d942043 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -23,10 +23,6 @@ #error is only supported on WASI platforms. #endif -#ifndef __wasm32__ -#error only supports wasm32; doesn't yet support wasm64 -#endif - #include #include @@ -38,7 +34,6 @@ _Static_assert(_Alignof(int32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(uint32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(int64_t) == 8, "non-wasi data layout"); _Static_assert(_Alignof(uint64_t) == 8, "non-wasi data layout"); -_Static_assert(_Alignof(void*) == 4, "non-wasi data layout"); #ifdef __cplusplus extern "C" { @@ -48,9 +43,6 @@ extern "C" { #define __WASI_DIRCOOKIE_START (UINT64_C(0)) typedef __SIZE_TYPE__ __wasi_size_t; -_Static_assert(sizeof(__wasi_size_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_size_t) == 4, "witx calculated align"); - /** * Non-negative file size or length of a region within a file. */ @@ -686,10 +678,10 @@ typedef struct __wasi_iovec_t { } __wasi_iovec_t; -_Static_assert(sizeof(__wasi_iovec_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_iovec_t) == 4, "witx calculated align"); +_Static_assert(sizeof(__wasi_iovec_t) == sizeof(uint8_t*)*2, "witx calculated size"); +_Static_assert(_Alignof(__wasi_iovec_t) == sizeof(uint8_t*), "witx calculated align"); _Static_assert(offsetof(__wasi_iovec_t, buf) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_iovec_t, buf_len) == 4, "witx calculated offset"); +_Static_assert(offsetof(__wasi_iovec_t, buf_len) == sizeof(uint8_t*), "witx calculated offset"); /** * A region of memory for scatter/gather writes. @@ -707,10 +699,10 @@ typedef struct __wasi_ciovec_t { } __wasi_ciovec_t; -_Static_assert(sizeof(__wasi_ciovec_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_ciovec_t) == 4, "witx calculated align"); +_Static_assert(sizeof(__wasi_ciovec_t) == sizeof(uint8_t*)*2, "witx calculated size"); +_Static_assert(_Alignof(__wasi_ciovec_t) == sizeof(uint8_t*), "witx calculated align"); _Static_assert(offsetof(__wasi_ciovec_t, buf) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_ciovec_t, buf_len) == 4, "witx calculated offset"); +_Static_assert(offsetof(__wasi_ciovec_t, buf_len) == sizeof(uint8_t*), "witx calculated offset"); /** * Relative offset within a file. @@ -1374,8 +1366,8 @@ typedef struct __wasi_prestat_dir_t { } __wasi_prestat_dir_t; -_Static_assert(sizeof(__wasi_prestat_dir_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_prestat_dir_t) == 4, "witx calculated align"); +_Static_assert(sizeof(__wasi_prestat_dir_t) == sizeof(__wasi_size_t), "witx calculated size"); +_Static_assert(_Alignof(__wasi_prestat_dir_t) == sizeof(__wasi_size_t), "witx calculated align"); _Static_assert(offsetof(__wasi_prestat_dir_t, pr_name_len) == 0, "witx calculated offset"); /** @@ -1389,8 +1381,8 @@ typedef struct __wasi_prestat_t { __wasi_prestat_u_t u; } __wasi_prestat_t; -_Static_assert(sizeof(__wasi_prestat_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_prestat_t) == 4, "witx calculated align"); +_Static_assert(sizeof(__wasi_prestat_t) == sizeof(__wasi_size_t)*2, "witx calculated size"); +_Static_assert(_Alignof(__wasi_prestat_t) == sizeof(__wasi_size_t), "witx calculated align"); /** * @defgroup wasi_snapshot_preview1 From 8d11df762e7f60d0f38c547c1ec7712419b4d848 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 25 Oct 2023 17:11:35 -0400 Subject: [PATCH 02/43] wasilibc_real support wasm64 --- libc-bottom-half/sources/__wasilibc_real.c | 214 +++++++++++---------- tools/wasi-headers/src/c_header.rs | 53 ++--- 2 files changed, 137 insertions(+), 130 deletions(-) diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 186de0183..3afecc1da 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -13,7 +13,7 @@ #include #include -int32_t __imported_wasi_snapshot_preview1_args_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_get") )); @@ -22,11 +22,11 @@ __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf ){ - int32_t ret = __imported_wasi_snapshot_preview1_args_get((int32_t) argv, (int32_t) argv_buf); + int32_t ret = __imported_wasi_snapshot_preview1_args_get((uintptr_t) argv, (uintptr_t) argv_buf); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_args_sizes_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_sizes_get") )); @@ -35,11 +35,11 @@ __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_args_sizes_get((int32_t) retptr0, (int32_t) retptr1); + int32_t ret = __imported_wasi_snapshot_preview1_args_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_environ_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_get") )); @@ -48,11 +48,11 @@ __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf ){ - int32_t ret = __imported_wasi_snapshot_preview1_environ_get((int32_t) environ, (int32_t) environ_buf); + int32_t ret = __imported_wasi_snapshot_preview1_environ_get((uintptr_t) environ, (uintptr_t) environ_buf); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_sizes_get") )); @@ -61,11 +61,11 @@ __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_environ_sizes_get((int32_t) retptr0, (int32_t) retptr1); + int32_t ret = __imported_wasi_snapshot_preview1_environ_sizes_get((uintptr_t)retptr0, (uintptr_t)retptr1); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_clock_res_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_clock_res_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_res_get") )); @@ -74,11 +74,11 @@ __wasi_errno_t __wasi_clock_res_get( __wasi_clockid_t id, __wasi_timestamp_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_clock_time_get(int32_t arg0, int64_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_clock_time_get(uintptr_t arg0, int64_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_time_get") )); @@ -88,11 +88,11 @@ __wasi_errno_t __wasi_clock_time_get( __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_advise(int32_t arg0, int64_t arg1, int64_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_advise(uintptr_t arg0, int64_t arg1, int64_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_advise") )); @@ -107,7 +107,7 @@ __wasi_errno_t __wasi_fd_advise( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_allocate(int32_t arg0, int64_t arg1, int64_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_allocate(uintptr_t arg0, int64_t arg1, int64_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_allocate") )); @@ -121,7 +121,7 @@ __wasi_errno_t __wasi_fd_allocate( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_close(int32_t arg0) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_close(uintptr_t arg0) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_close") )); @@ -133,7 +133,7 @@ __wasi_errno_t __wasi_fd_close( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_datasync(int32_t arg0) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_datasync(uintptr_t arg0) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_datasync") )); @@ -145,7 +145,7 @@ __wasi_errno_t __wasi_fd_datasync( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_get") )); @@ -154,11 +154,11 @@ __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_flags") )); @@ -171,7 +171,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(int32_t arg0, int64_t arg1, int64_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uintptr_t arg0, int64_t arg1, int64_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_rights") )); @@ -185,7 +185,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_get") )); @@ -194,11 +194,11 @@ __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(int32_t arg0, int64_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uintptr_t arg0, int64_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_size") )); @@ -211,7 +211,7 @@ __wasi_errno_t __wasi_fd_filestat_set_size( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(int32_t arg0, int64_t arg1, int64_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uintptr_t arg0, int64_t arg1, int64_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_times") )); @@ -226,23 +226,23 @@ __wasi_errno_t __wasi_fd_filestat_set_times( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_pread(int32_t arg0, int32_t arg1, int32_t arg2, int64_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_pread(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pread") )); __wasi_errno_t __wasi_fd_pread( __wasi_fd_t fd, - const __wasi_iovec_t *iovs, + __wasi_iovec_t const *iovs, size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (int32_t) iovs, (int32_t) iovs_len, (int64_t) offset, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (uintptr_t) iovs, iovs_len, (int64_t) offset, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_get") )); @@ -251,11 +251,11 @@ __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(int32_t arg0, int32_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_dir_name") )); @@ -265,42 +265,42 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( uint8_t * path, __wasi_size_t path_len ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (int32_t) path, (int32_t) path_len); + int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (uintptr_t) path, path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_pwrite(int32_t arg0, int32_t arg1, int32_t arg2, int64_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_pwrite(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pwrite") )); __wasi_errno_t __wasi_fd_pwrite( __wasi_fd_t fd, - const __wasi_ciovec_t *iovs, + __wasi_ciovec_t const *iovs, size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (int32_t) iovs, (int32_t) iovs_len, (int64_t) offset, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (uintptr_t) iovs, iovs_len, (int64_t) offset, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_read(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_read(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_read") )); __wasi_errno_t __wasi_fd_read( __wasi_fd_t fd, - const __wasi_iovec_t *iovs, + __wasi_iovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (int32_t) iovs, (int32_t) iovs_len, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (uintptr_t) iovs, iovs_len, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_readdir(int32_t arg0, int32_t arg1, int32_t arg2, int64_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_readdir(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_readdir") )); @@ -312,11 +312,11 @@ __wasi_errno_t __wasi_fd_readdir( __wasi_dircookie_t cookie, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (int32_t) buf, (int32_t) buf_len, (int64_t) cookie, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (uintptr_t) buf, buf_len, (int64_t) cookie, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_renumber(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_renumber(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_renumber") )); @@ -329,7 +329,7 @@ __wasi_errno_t __wasi_fd_renumber( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_seek(int32_t arg0, int64_t arg1, int32_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_seek(uintptr_t arg0, int64_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_seek") )); @@ -340,11 +340,11 @@ __wasi_errno_t __wasi_fd_seek( __wasi_whence_t whence, __wasi_filesize_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, offset, (int32_t) whence, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, offset, whence, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_sync(int32_t arg0) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_sync(uintptr_t arg0) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_sync") )); @@ -356,7 +356,7 @@ __wasi_errno_t __wasi_fd_sync( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_tell(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_tell(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_tell") )); @@ -365,40 +365,40 @@ __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_fd_write(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_write(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_write") )); __wasi_errno_t __wasi_fd_write( __wasi_fd_t fd, - const __wasi_ciovec_t *iovs, + __wasi_ciovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (int32_t) iovs, (int32_t) iovs_len, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (uintptr_t) iovs, iovs_len, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_create_directory(int32_t arg0, int32_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_create_directory(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_create_directory") )); __wasi_errno_t __wasi_path_create_directory( __wasi_fd_t fd, - const char *path + char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (int32_t) path, (int32_t) path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (uintptr_t)path, path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_filestat_get(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_filestat_get(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_get") )); @@ -406,15 +406,15 @@ int32_t __imported_wasi_snapshot_preview1_path_filestat_get(int32_t arg0, int32_ __wasi_errno_t __wasi_path_filestat_get( __wasi_fd_t fd, __wasi_lookupflags_t flags, - const char *path, + char const *path, __wasi_filestat_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, flags, (int32_t) path, (int32_t) path_len, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, flags, (uintptr_t)path, path_len, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int64_t arg4, int64_t arg5, int32_t arg6) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, int64_t arg4, int64_t arg5, uintptr_t arg6) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_set_times") )); @@ -422,17 +422,17 @@ int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(int32_t arg0, __wasi_errno_t __wasi_path_filestat_set_times( __wasi_fd_t fd, __wasi_lookupflags_t flags, - const char *path, + char const *path, __wasi_timestamp_t atim, __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, flags, (int32_t) path, (int32_t) path_len, (int64_t) atim, (int64_t) mtim, fst_flags); + int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, flags, (uintptr_t)path, path_len, (int64_t) atim, (int64_t) mtim, fst_flags); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_link(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4, int32_t arg5, int32_t arg6) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_link(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5, uintptr_t arg6) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_link") )); @@ -440,17 +440,17 @@ int32_t __imported_wasi_snapshot_preview1_path_link(int32_t arg0, int32_t arg1, __wasi_errno_t __wasi_path_link( __wasi_fd_t old_fd, __wasi_lookupflags_t old_flags, - const char *old_path, + char const *old_path, __wasi_fd_t new_fd, - const char *new_path + char const *new_path ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, old_flags, (int32_t) old_path, (int32_t) old_path_len, (int32_t) new_fd, (int32_t) new_path, (int32_t) new_path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, old_flags, (uintptr_t)old_path, old_path_len, (int32_t) new_fd, (uintptr_t)new_path, new_path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_open(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4, int64_t arg5, int64_t arg6, int32_t arg7, int32_t arg8) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_open(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, int64_t arg5, int64_t arg6, uintptr_t arg7, uintptr_t arg8) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_open") )); @@ -458,7 +458,7 @@ int32_t __imported_wasi_snapshot_preview1_path_open(int32_t arg0, int32_t arg1, __wasi_errno_t __wasi_path_open( __wasi_fd_t fd, __wasi_lookupflags_t dirflags, - const char *path, + char const *path, __wasi_oflags_t oflags, __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting, @@ -466,104 +466,104 @@ __wasi_errno_t __wasi_path_open( __wasi_fd_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_open((int32_t) fd, dirflags, (int32_t) path, (int32_t) path_len, oflags, fs_rights_base, fs_rights_inheriting, fdflags, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_path_open((int32_t) fd, dirflags, (uintptr_t)path, path_len, oflags, fs_rights_base, fs_rights_inheriting, fdflags, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_readlink(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4, int32_t arg5) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_readlink(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_readlink") )); __wasi_errno_t __wasi_path_readlink( __wasi_fd_t fd, - const char *path, + char const *path, uint8_t * buf, __wasi_size_t buf_len, __wasi_size_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (int32_t) path, (int32_t) path_len, (int32_t) buf, (int32_t) buf_len, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (uintptr_t)path, path_len, (uintptr_t) buf, buf_len, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_remove_directory(int32_t arg0, int32_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_remove_directory(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_remove_directory") )); __wasi_errno_t __wasi_path_remove_directory( __wasi_fd_t fd, - const char *path + char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (int32_t) path, (int32_t) path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (uintptr_t)path, path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_rename(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4, int32_t arg5) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_rename(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_rename") )); __wasi_errno_t __wasi_path_rename( __wasi_fd_t fd, - const char *old_path, + char const *old_path, __wasi_fd_t new_fd, - const char *new_path + char const *new_path ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (int32_t) old_path, (int32_t) old_path_len, (int32_t) new_fd, (int32_t) new_path, (int32_t) new_path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (uintptr_t)old_path, old_path_len, (int32_t) new_fd, (uintptr_t)new_path, new_path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_symlink(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_symlink") )); __wasi_errno_t __wasi_path_symlink( - const char *old_path, + char const *old_path, __wasi_fd_t fd, - const char *new_path + char const *new_path ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_symlink((int32_t) old_path, (int32_t) old_path_len, (int32_t) fd, (int32_t) new_path, (int32_t) new_path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_symlink((uintptr_t)old_path, old_path_len, (int32_t) fd, (uintptr_t)new_path, new_path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_path_unlink_file(int32_t arg0, int32_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_unlink_file(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_unlink_file") )); __wasi_errno_t __wasi_path_unlink_file( __wasi_fd_t fd, - const char *path + char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (int32_t) path, (int32_t) path_len); + int32_t ret = __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (uintptr_t)path, path_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_poll_oneoff(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("poll_oneoff") )); __wasi_errno_t __wasi_poll_oneoff( - const __wasi_subscription_t * in, + __wasi_subscription_t const * in, __wasi_event_t * out, __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_poll_oneoff((int32_t) in, (int32_t) out, (int32_t) nsubscriptions, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_poll_oneoff((uintptr_t) in, (uintptr_t) out, nsubscriptions, (uintptr_t) retptr0); return (uint16_t) ret; } -_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t arg0) __attribute__(( +_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uintptr_t arg0) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("proc_exit") )); @@ -574,6 +574,18 @@ _Noreturn void __wasi_proc_exit( __imported_wasi_snapshot_preview1_proc_exit((int32_t) rval); } +int32_t __imported_wasi_snapshot_preview1_proc_raise(uintptr_t arg0) __attribute__(( + __import_module__("wasi_snapshot_preview1"), + __import_name__("proc_raise") +)); + +__wasi_errno_t __wasi_proc_raise( + __wasi_signal_t sig +){ + int32_t ret = __imported_wasi_snapshot_preview1_proc_raise((int32_t) sig); + return (uint16_t) ret; +} + int32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sched_yield") @@ -586,7 +598,7 @@ __wasi_errno_t __wasi_sched_yield( return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_random_get(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("random_get") )); @@ -595,11 +607,11 @@ __wasi_errno_t __wasi_random_get( uint8_t * buf, __wasi_size_t buf_len ){ - int32_t ret = __imported_wasi_snapshot_preview1_random_get((int32_t) buf, (int32_t) buf_len); + int32_t ret = __imported_wasi_snapshot_preview1_random_get((uintptr_t) buf, buf_len); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_sock_accept(int32_t arg0, int32_t arg1, int32_t arg2) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_accept(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_accept") )); @@ -609,44 +621,44 @@ __wasi_errno_t __wasi_sock_accept( __wasi_fdflags_t flags, __wasi_fd_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, flags, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, flags, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_sock_recv(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4, int32_t arg5) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_recv(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_recv") )); __wasi_errno_t __wasi_sock_recv( __wasi_fd_t fd, - const __wasi_iovec_t *ri_data, + __wasi_iovec_t const *ri_data, size_t ri_data_len, __wasi_riflags_t ri_flags, __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (int32_t) ri_data, (int32_t) ri_data_len, ri_flags, (int32_t) retptr0, (int32_t) retptr1); + int32_t ret = __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (uintptr_t)ri_data, ri_data_len, ri_flags, (uintptr_t) retptr0, (uintptr_t)retptr1); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_sock_send(int32_t arg0, int32_t arg1, int32_t arg2, int32_t arg3, int32_t arg4) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_send(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_send") )); __wasi_errno_t __wasi_sock_send( __wasi_fd_t fd, - const __wasi_ciovec_t *si_data, + __wasi_ciovec_t const *si_data, size_t si_data_len, __wasi_siflags_t si_flags, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (int32_t) si_data, (int32_t) si_data_len, (int32_t) si_flags, (int32_t) retptr0); + int32_t ret = __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (uintptr_t)si_data, si_data_len, (int32_t) si_flags, (uintptr_t) retptr0); return (uint16_t) ret; } -int32_t __imported_wasi_snapshot_preview1_sock_shutdown(int32_t arg0, int32_t arg1) __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_shutdown(uintptr_t arg0, uintptr_t arg1) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_shutdown") )); @@ -659,13 +671,3 @@ __wasi_errno_t __wasi_sock_shutdown( return (uint16_t) ret; } -#ifdef _REENTRANT -int32_t __imported_wasi_thread_spawn(int32_t arg0) __attribute__(( - __import_module__("wasi"), - __import_name__("thread-spawn") -)); - -int32_t __wasi_thread_spawn(void* start_arg) { - return __imported_wasi_thread_spawn((int32_t) start_arg); -} -#endif diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 15b64ee6e..2697af5fb 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -41,10 +41,6 @@ pub fn to_c(doc: &Document, inputs_str: &str) -> Generated { #error is only supported on WASI platforms. #endif -#ifndef __wasm32__ -#error only supports wasm32; doesn't yet support wasm64 -#endif - #include #include @@ -56,7 +52,7 @@ _Static_assert(_Alignof(int32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(uint32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(int64_t) == 8, "non-wasi data layout"); _Static_assert(_Alignof(uint64_t) == 8, "non-wasi data layout"); -_Static_assert(_Alignof(void*) == 4, "non-wasi data layout"); +_Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); #ifdef __cplusplus extern "C" {{ @@ -165,7 +161,7 @@ fn print_alias(ret: &mut String, name: &Id, dest: &TypeRef) { )); } ret.push_str("\n"); - +/* ret.push_str(&format!( "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), @@ -176,7 +172,7 @@ fn print_alias(ret: &mut String, name: &Id, dest: &TypeRef) { ident_name(name), dest.mem_size_align().align )); - +*/ ret.push_str("\n"); } } @@ -207,7 +203,7 @@ fn print_enum(ret: &mut String, name: &Id, v: &Variant) { )); ret.push_str("\n"); } - +/* ret.push_str(&format!( "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), @@ -218,7 +214,7 @@ fn print_enum(ret: &mut String, name: &Id, v: &Variant) { ident_name(name), v.tag_repr.mem_align() )); - +*/ ret.push_str("\n"); } @@ -289,7 +285,7 @@ fn print_record(ret: &mut String, name: &Id, s: &RecordDatatype) { ret.push_str(&format!("}} __wasi_{}_t;\n", ident_name(name))); ret.push_str("\n"); - +/* ret.push_str(&format!( "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), @@ -309,7 +305,7 @@ fn print_record(ret: &mut String, name: &Id, s: &RecordDatatype) { layout.offset )); } - +*/ ret.push_str("\n"); } @@ -350,7 +346,7 @@ fn print_variant(ret: &mut String, name: &Id, v: &Variant) { ret.push_str(&format!("}} __wasi_{}_t;\n", ident_name(name))); ret.push_str("\n"); - +/* ret.push_str(&format!( "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), @@ -361,13 +357,13 @@ fn print_variant(ret: &mut String, name: &Id, v: &Variant) { ident_name(name), v.mem_align() )); - +*/ ret.push_str("\n"); } -fn print_handle(ret: &mut String, name: &Id, h: &HandleDatatype) { +fn print_handle(ret: &mut String, name: &Id, _h: &HandleDatatype) { ret.push_str(&format!("typedef int __wasi_{}_t;\n\n", ident_name(name))); - +/* ret.push_str(&format!( "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), @@ -378,7 +374,7 @@ fn print_handle(ret: &mut String, name: &Id, h: &HandleDatatype) { ident_name(name), h.mem_align() )); - +*/ ret.push_str("\n"); } @@ -501,7 +497,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { if i > 0 { ret.push_str(", "); } - ret.push_str(wasm_type(param)); + ret.push_str(wasm_arg_type(param)); ret.push_str(&format!(" arg{}", i)); } ret.push_str(") __attribute__((\n"); @@ -633,15 +629,15 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { Instruction::ListPointerLength => { let list = operands.pop().unwrap(); - results.push(format!("(int32_t) {}", list)); - results.push(format!("(int32_t) {}_len", list)); + results.push(format!("(intptr_t) {}", list)); + results.push(format!("(intptr_t) {}_len", list)); } Instruction::ReturnPointerGet { n } => { // We currently match the wasi ABI with the actual // function's API signature in C, this means when a return // pointer is asked for we can simply forward our parameter // that's a return pointer. - results.push(format!("(int32_t) retptr{}", n)); + results.push(format!("(intptr_t) retptr{}", n)); } Instruction::Load { .. } => { @@ -771,10 +767,10 @@ fn add_params(params: &mut Vec<(Option, String)>, name: &str, tref: &Typ match &**tref.type_() { Type::List(element) => match &**element.type_() { Type::Builtin(BuiltinType::Char) => { - params.push((docs, format!("const char *{}", name))); + params.push((docs, format!("char const *{}", name))); } _ => { - params.push((docs, format!("const {} *{}", typeref_name(&element), name))); + params.push((docs, format!("{} const *{}", typeref_name(&element), name))); params.push(( Some(format!("The length of the array pointed to by `{}`.", name,)), format!("size_t {}_len", name), @@ -829,7 +825,7 @@ fn typeref_name(tref: &TypeRef) -> String { Type::List(_) => unreachable!("arrays excluded above"), Type::Builtin(b) => builtin_type_name(*b).to_string(), Type::Pointer(p) => format!("{} *", typeref_name(&*p)), - Type::ConstPointer(p) => format!("const {} *", typeref_name(&*p)), + Type::ConstPointer(p) => format!("{} const *", typeref_name(&*p)), Type::Record { .. } | Type::Variant { .. } | Type::Handle { .. } => unreachable!( "wasi should not have anonymous structs, unions, enums, flags, handles" ), @@ -840,7 +836,7 @@ fn typeref_name(tref: &TypeRef) -> String { fn namedtype_name(named_type: &NamedType) -> String { match &**named_type.type_() { Type::Pointer(p) => format!("{} *", typeref_name(&*p)), - Type::ConstPointer(p) => format!("const {} *", typeref_name(&*p)), + Type::ConstPointer(p) => format!("{} const *", typeref_name(&*p)), Type::List(_) => unreachable!("arrays excluded above"), _ => format!("__wasi_{}_t", named_type.name.as_str()), } @@ -872,3 +868,12 @@ fn wasm_type(wasm: &WasmType) -> &'static str { WasmType::F64 => "double", } } + +fn wasm_arg_type(wasm: &WasmType) -> &'static str { + match wasm { + WasmType::I32 => "intptr_t", + WasmType::I64 => "int64_t", + WasmType::F32 => "float", + WasmType::F64 => "double", + } +} From 37702e73dbf5373710ce6025315568dc697442f5 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 25 Oct 2023 17:12:28 -0400 Subject: [PATCH 03/43] fix api.h --- libc-bottom-half/headers/public/wasi/api.h | 377 +++++++++++++-------- 1 file changed, 234 insertions(+), 143 deletions(-) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 43d942043..c534d6f03 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -1,9 +1,13 @@ /** - * . This file contains declarations describing the WASI ABI - * as of "snapshot preview1". It was originally auto-generated from - * wasi_snapshot_preview1.witx, however WASI is in the process of - * transitioning to a new IDL and header file generator, and this file - * is temporarily being manually maintained. + * THIS FILE IS AUTO-GENERATED from the following files: + * wasi_snapshot_preview1.witx + * + * To regenerate this file execute: + * + * cargo run --manifest-path tools/wasi-headers/Cargo.toml generate-libc + * + * Modifications to this file will cause CI to fail, the code generator tool + * must be modified to change this file. * * @file * This file describes the [WASI] interface, consisting of functions, types, @@ -34,6 +38,7 @@ _Static_assert(_Alignof(int32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(uint32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(int64_t) == 8, "non-wasi data layout"); _Static_assert(_Alignof(uint64_t) == 8, "non-wasi data layout"); +_Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); #ifdef __cplusplus extern "C" { @@ -43,21 +48,18 @@ extern "C" { #define __WASI_DIRCOOKIE_START (UINT64_C(0)) typedef __SIZE_TYPE__ __wasi_size_t; + /** * Non-negative file size or length of a region within a file. */ typedef uint64_t __wasi_filesize_t; -_Static_assert(sizeof(__wasi_filesize_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_filesize_t) == 8, "witx calculated align"); /** * Timestamp in nanoseconds. */ typedef uint64_t __wasi_timestamp_t; -_Static_assert(sizeof(__wasi_timestamp_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_timestamp_t) == 8, "witx calculated align"); /** * Identifiers for clocks. @@ -88,8 +90,6 @@ typedef uint32_t __wasi_clockid_t; */ #define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) -_Static_assert(sizeof(__wasi_clockid_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_clockid_t) == 4, "witx calculated align"); /** * Error codes returned by functions. @@ -484,8 +484,6 @@ typedef uint16_t __wasi_errno_t; */ #define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) -_Static_assert(sizeof(__wasi_errno_t) == 2, "witx calculated size"); -_Static_assert(_Alignof(__wasi_errno_t) == 2, "witx calculated align"); /** * File descriptor rights, determining which actions may be performed. @@ -659,8 +657,6 @@ typedef uint64_t __wasi_rights_t; */ typedef int __wasi_fd_t; -_Static_assert(sizeof(__wasi_fd_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_fd_t) == 4, "witx calculated align"); /** * A region of memory for scatter/gather reads. @@ -678,10 +674,6 @@ typedef struct __wasi_iovec_t { } __wasi_iovec_t; -_Static_assert(sizeof(__wasi_iovec_t) == sizeof(uint8_t*)*2, "witx calculated size"); -_Static_assert(_Alignof(__wasi_iovec_t) == sizeof(uint8_t*), "witx calculated align"); -_Static_assert(offsetof(__wasi_iovec_t, buf) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_iovec_t, buf_len) == sizeof(uint8_t*), "witx calculated offset"); /** * A region of memory for scatter/gather writes. @@ -690,7 +682,7 @@ typedef struct __wasi_ciovec_t { /** * The address of the buffer to be written. */ - const uint8_t * buf; + uint8_t const * buf; /** * The length of the buffer to be written. @@ -699,18 +691,12 @@ typedef struct __wasi_ciovec_t { } __wasi_ciovec_t; -_Static_assert(sizeof(__wasi_ciovec_t) == sizeof(uint8_t*)*2, "witx calculated size"); -_Static_assert(_Alignof(__wasi_ciovec_t) == sizeof(uint8_t*), "witx calculated align"); -_Static_assert(offsetof(__wasi_ciovec_t, buf) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_ciovec_t, buf_len) == sizeof(uint8_t*), "witx calculated offset"); /** * Relative offset within a file. */ typedef int64_t __wasi_filedelta_t; -_Static_assert(sizeof(__wasi_filedelta_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_filedelta_t) == 8, "witx calculated align"); /** * The position relative to which to set the offset of the file descriptor. @@ -732,8 +718,6 @@ typedef uint8_t __wasi_whence_t; */ #define __WASI_WHENCE_END (UINT8_C(2)) -_Static_assert(sizeof(__wasi_whence_t) == 1, "witx calculated size"); -_Static_assert(_Alignof(__wasi_whence_t) == 1, "witx calculated align"); /** * A reference to the offset of a directory entry. @@ -742,24 +726,18 @@ _Static_assert(_Alignof(__wasi_whence_t) == 1, "witx calculated align"); */ typedef uint64_t __wasi_dircookie_t; -_Static_assert(sizeof(__wasi_dircookie_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_dircookie_t) == 8, "witx calculated align"); /** * The type for the `dirent::d_namlen` field of `dirent` struct. */ typedef uint32_t __wasi_dirnamlen_t; -_Static_assert(sizeof(__wasi_dirnamlen_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_dirnamlen_t) == 4, "witx calculated align"); /** * File serial number that is unique within its file system. */ typedef uint64_t __wasi_inode_t; -_Static_assert(sizeof(__wasi_inode_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_inode_t) == 8, "witx calculated align"); /** * The type of a file descriptor or file. @@ -806,8 +784,6 @@ typedef uint8_t __wasi_filetype_t; */ #define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) -_Static_assert(sizeof(__wasi_filetype_t) == 1, "witx calculated size"); -_Static_assert(_Alignof(__wasi_filetype_t) == 1, "witx calculated align"); /** * A directory entry. @@ -835,12 +811,6 @@ typedef struct __wasi_dirent_t { } __wasi_dirent_t; -_Static_assert(sizeof(__wasi_dirent_t) == 24, "witx calculated size"); -_Static_assert(_Alignof(__wasi_dirent_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_dirent_t, d_next) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_dirent_t, d_ino) == 8, "witx calculated offset"); -_Static_assert(offsetof(__wasi_dirent_t, d_namlen) == 16, "witx calculated offset"); -_Static_assert(offsetof(__wasi_dirent_t, d_type) == 20, "witx calculated offset"); /** * File or memory access pattern advisory information. @@ -877,8 +847,6 @@ typedef uint8_t __wasi_advice_t; */ #define __WASI_ADVICE_NOREUSE (UINT8_C(5)) -_Static_assert(sizeof(__wasi_advice_t) == 1, "witx calculated size"); -_Static_assert(_Alignof(__wasi_advice_t) == 1, "witx calculated align"); /** * File descriptor flags. @@ -939,12 +907,6 @@ typedef struct __wasi_fdstat_t { } __wasi_fdstat_t; -_Static_assert(sizeof(__wasi_fdstat_t) == 24, "witx calculated size"); -_Static_assert(_Alignof(__wasi_fdstat_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_fdstat_t, fs_filetype) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_fdstat_t, fs_flags) == 2, "witx calculated offset"); -_Static_assert(offsetof(__wasi_fdstat_t, fs_rights_base) == 8, "witx calculated offset"); -_Static_assert(offsetof(__wasi_fdstat_t, fs_rights_inheriting) == 16, "witx calculated offset"); /** * Identifier for a device containing a file system. Can be used in combination @@ -952,8 +914,6 @@ _Static_assert(offsetof(__wasi_fdstat_t, fs_rights_inheriting) == 16, "witx calc */ typedef uint64_t __wasi_device_t; -_Static_assert(sizeof(__wasi_device_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_device_t) == 8, "witx calculated align"); /** * Which file time attributes to adjust. @@ -1020,8 +980,6 @@ typedef uint16_t __wasi_oflags_t; */ typedef uint64_t __wasi_linkcount_t; -_Static_assert(sizeof(__wasi_linkcount_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_linkcount_t) == 8, "witx calculated align"); /** * File attributes. @@ -1069,16 +1027,6 @@ typedef struct __wasi_filestat_t { } __wasi_filestat_t; -_Static_assert(sizeof(__wasi_filestat_t) == 64, "witx calculated size"); -_Static_assert(_Alignof(__wasi_filestat_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_filestat_t, dev) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, ino) == 8, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, filetype) == 16, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, nlink) == 24, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, size) == 32, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, atim) == 40, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, mtim) == 48, "witx calculated offset"); -_Static_assert(offsetof(__wasi_filestat_t, ctim) == 56, "witx calculated offset"); /** * User-provided value that may be attached to objects that is retained when @@ -1086,8 +1034,6 @@ _Static_assert(offsetof(__wasi_filestat_t, ctim) == 56, "witx calculated offset" */ typedef uint64_t __wasi_userdata_t; -_Static_assert(sizeof(__wasi_userdata_t) == 8, "witx calculated size"); -_Static_assert(_Alignof(__wasi_userdata_t) == 8, "witx calculated align"); /** * Type of a subscription to an event or its occurrence. @@ -1112,8 +1058,6 @@ typedef uint8_t __wasi_eventtype_t; */ #define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) -_Static_assert(sizeof(__wasi_eventtype_t) == 1, "witx calculated size"); -_Static_assert(_Alignof(__wasi_eventtype_t) == 1, "witx calculated align"); /** * The state of the file descriptor subscribed to with @@ -1143,10 +1087,6 @@ typedef struct __wasi_event_fd_readwrite_t { } __wasi_event_fd_readwrite_t; -_Static_assert(sizeof(__wasi_event_fd_readwrite_t) == 16, "witx calculated size"); -_Static_assert(_Alignof(__wasi_event_fd_readwrite_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_event_fd_readwrite_t, nbytes) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_event_fd_readwrite_t, flags) == 8, "witx calculated offset"); /** * An event that occurred. @@ -1175,12 +1115,6 @@ typedef struct __wasi_event_t { } __wasi_event_t; -_Static_assert(sizeof(__wasi_event_t) == 32, "witx calculated size"); -_Static_assert(_Alignof(__wasi_event_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_event_t, userdata) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_event_t, error) == 8, "witx calculated offset"); -_Static_assert(offsetof(__wasi_event_t, type) == 10, "witx calculated offset"); -_Static_assert(offsetof(__wasi_event_t, fd_readwrite) == 16, "witx calculated offset"); /** * Flags determining how to interpret the timestamp provided in @@ -1224,12 +1158,6 @@ typedef struct __wasi_subscription_clock_t { } __wasi_subscription_clock_t; -_Static_assert(sizeof(__wasi_subscription_clock_t) == 32, "witx calculated size"); -_Static_assert(_Alignof(__wasi_subscription_clock_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_subscription_clock_t, id) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_subscription_clock_t, timeout) == 8, "witx calculated offset"); -_Static_assert(offsetof(__wasi_subscription_clock_t, precision) == 16, "witx calculated offset"); -_Static_assert(offsetof(__wasi_subscription_clock_t, flags) == 24, "witx calculated offset"); /** * The contents of a `subscription` when type is type is @@ -1243,9 +1171,6 @@ typedef struct __wasi_subscription_fd_readwrite_t { } __wasi_subscription_fd_readwrite_t; -_Static_assert(sizeof(__wasi_subscription_fd_readwrite_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_subscription_fd_readwrite_t) == 4, "witx calculated align"); -_Static_assert(offsetof(__wasi_subscription_fd_readwrite_t, file_descriptor) == 0, "witx calculated offset"); /** * The contents of a `subscription`. @@ -1260,8 +1185,6 @@ typedef struct __wasi_subscription_u_t { __wasi_subscription_u_u_t u; } __wasi_subscription_u_t; -_Static_assert(sizeof(__wasi_subscription_u_t) == 40, "witx calculated size"); -_Static_assert(_Alignof(__wasi_subscription_u_t) == 8, "witx calculated align"); /** * Subscription to an event. @@ -1280,18 +1203,204 @@ typedef struct __wasi_subscription_t { } __wasi_subscription_t; -_Static_assert(sizeof(__wasi_subscription_t) == 48, "witx calculated size"); -_Static_assert(_Alignof(__wasi_subscription_t) == 8, "witx calculated align"); -_Static_assert(offsetof(__wasi_subscription_t, userdata) == 0, "witx calculated offset"); -_Static_assert(offsetof(__wasi_subscription_t, u) == 8, "witx calculated offset"); /** * Exit code generated by a process when exiting. */ typedef uint32_t __wasi_exitcode_t; -_Static_assert(sizeof(__wasi_exitcode_t) == 4, "witx calculated size"); -_Static_assert(_Alignof(__wasi_exitcode_t) == 4, "witx calculated align"); + +/** + * Signal condition. + */ +typedef uint8_t __wasi_signal_t; + +/** + * No signal. Note that POSIX has special semantics for `kill(pid, 0)`, + * so this value is reserved. + */ +#define __WASI_SIGNAL_NONE (UINT8_C(0)) + +/** + * Hangup. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_HUP (UINT8_C(1)) + +/** + * Terminate interrupt signal. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_INT (UINT8_C(2)) + +/** + * Terminal quit signal. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_QUIT (UINT8_C(3)) + +/** + * Illegal instruction. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_ILL (UINT8_C(4)) + +/** + * Trace/breakpoint trap. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_TRAP (UINT8_C(5)) + +/** + * Process abort signal. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_ABRT (UINT8_C(6)) + +/** + * Access to an undefined portion of a memory object. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_BUS (UINT8_C(7)) + +/** + * Erroneous arithmetic operation. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_FPE (UINT8_C(8)) + +/** + * Kill. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_KILL (UINT8_C(9)) + +/** + * User-defined signal 1. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_USR1 (UINT8_C(10)) + +/** + * Invalid memory reference. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_SEGV (UINT8_C(11)) + +/** + * User-defined signal 2. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_USR2 (UINT8_C(12)) + +/** + * Write on a pipe with no one to read it. + * Action: Ignored. + */ +#define __WASI_SIGNAL_PIPE (UINT8_C(13)) + +/** + * Alarm clock. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_ALRM (UINT8_C(14)) + +/** + * Termination signal. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_TERM (UINT8_C(15)) + +/** + * Child process terminated, stopped, or continued. + * Action: Ignored. + */ +#define __WASI_SIGNAL_CHLD (UINT8_C(16)) + +/** + * Continue executing, if stopped. + * Action: Continues executing, if stopped. + */ +#define __WASI_SIGNAL_CONT (UINT8_C(17)) + +/** + * Stop executing. + * Action: Stops executing. + */ +#define __WASI_SIGNAL_STOP (UINT8_C(18)) + +/** + * Terminal stop signal. + * Action: Stops executing. + */ +#define __WASI_SIGNAL_TSTP (UINT8_C(19)) + +/** + * Background process attempting read. + * Action: Stops executing. + */ +#define __WASI_SIGNAL_TTIN (UINT8_C(20)) + +/** + * Background process attempting write. + * Action: Stops executing. + */ +#define __WASI_SIGNAL_TTOU (UINT8_C(21)) + +/** + * High bandwidth data is available at a socket. + * Action: Ignored. + */ +#define __WASI_SIGNAL_URG (UINT8_C(22)) + +/** + * CPU time limit exceeded. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_XCPU (UINT8_C(23)) + +/** + * File size limit exceeded. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) + +/** + * Virtual timer expired. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) + +/** + * Profiling timer expired. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_PROF (UINT8_C(26)) + +/** + * Window changed. + * Action: Ignored. + */ +#define __WASI_SIGNAL_WINCH (UINT8_C(27)) + +/** + * I/O possible. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_POLL (UINT8_C(28)) + +/** + * Power failure. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_PWR (UINT8_C(29)) + +/** + * Bad system call. + * Action: Terminates the process. + */ +#define __WASI_SIGNAL_SYS (UINT8_C(30)) + /** * Flags provided to `sock_recv`. @@ -1324,8 +1433,6 @@ typedef uint16_t __wasi_roflags_t; */ typedef uint16_t __wasi_siflags_t; -_Static_assert(sizeof(__wasi_siflags_t) == 2, "witx calculated size"); -_Static_assert(_Alignof(__wasi_siflags_t) == 2, "witx calculated align"); /** * Which channels on a socket to shut down. @@ -1352,8 +1459,6 @@ typedef uint8_t __wasi_preopentype_t; */ #define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) -_Static_assert(sizeof(__wasi_preopentype_t) == 1, "witx calculated size"); -_Static_assert(_Alignof(__wasi_preopentype_t) == 1, "witx calculated align"); /** * The contents of a $prestat when type is `preopentype::dir`. @@ -1366,9 +1471,6 @@ typedef struct __wasi_prestat_dir_t { } __wasi_prestat_dir_t; -_Static_assert(sizeof(__wasi_prestat_dir_t) == sizeof(__wasi_size_t), "witx calculated size"); -_Static_assert(_Alignof(__wasi_prestat_dir_t) == sizeof(__wasi_size_t), "witx calculated align"); -_Static_assert(offsetof(__wasi_prestat_dir_t, pr_name_len) == 0, "witx calculated offset"); /** * Information about a pre-opened capability. @@ -1381,8 +1483,6 @@ typedef struct __wasi_prestat_t { __wasi_prestat_u_t u; } __wasi_prestat_t; -_Static_assert(sizeof(__wasi_prestat_t) == sizeof(__wasi_size_t)*2, "witx calculated size"); -_Static_assert(_Alignof(__wasi_prestat_t) == sizeof(__wasi_size_t), "witx calculated align"); /** * @defgroup wasi_snapshot_preview1 @@ -1590,7 +1690,7 @@ __wasi_errno_t __wasi_fd_pread( /** * List of scatter/gather vectors in which to store data. */ - const __wasi_iovec_t *iovs, + __wasi_iovec_t const *iovs, /** * The length of the array pointed to by `iovs`. */ @@ -1632,7 +1732,7 @@ __wasi_errno_t __wasi_fd_pwrite( /** * List of scatter/gather vectors from which to retrieve data. */ - const __wasi_ciovec_t *iovs, + __wasi_ciovec_t const *iovs, /** * The length of the array pointed to by `iovs`. */ @@ -1654,7 +1754,7 @@ __wasi_errno_t __wasi_fd_read( /** * List of scatter/gather vectors to which to store data. */ - const __wasi_iovec_t *iovs, + __wasi_iovec_t const *iovs, /** * The length of the array pointed to by `iovs`. */ @@ -1748,7 +1848,7 @@ __wasi_errno_t __wasi_fd_write( /** * List of scatter/gather vectors from which to retrieve data. */ - const __wasi_ciovec_t *iovs, + __wasi_ciovec_t const *iovs, /** * The length of the array pointed to by `iovs`. */ @@ -1764,7 +1864,7 @@ __wasi_errno_t __wasi_path_create_directory( /** * The path at which to create the directory. */ - const char *path + char const *path ) __attribute__((__warn_unused_result__)); /** * Return the attributes of a file or directory. @@ -1781,7 +1881,7 @@ __wasi_errno_t __wasi_path_filestat_get( /** * The path of the file or directory to inspect. */ - const char *path, + char const *path, __wasi_filestat_t *retptr0 ) __attribute__((__warn_unused_result__)); /** @@ -1797,7 +1897,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( /** * The path of the file or directory to operate on. */ - const char *path, + char const *path, /** * The desired values of the data access timestamp. */ @@ -1824,7 +1924,7 @@ __wasi_errno_t __wasi_path_link( /** * The source path from which to link. */ - const char *old_path, + char const *old_path, /** * The working directory at which the resolution of the new path starts. */ @@ -1832,7 +1932,7 @@ __wasi_errno_t __wasi_path_link( /** * The destination path at which to create the hard link. */ - const char *new_path + char const *new_path ) __attribute__((__warn_unused_result__)); /** * Open a file or directory. @@ -1855,7 +1955,7 @@ __wasi_errno_t __wasi_path_open( * The relative path of the file or directory to open, relative to the * `path_open::fd` directory. */ - const char *path, + char const *path, /** * The method by which to open the file. */ @@ -1885,7 +1985,7 @@ __wasi_errno_t __wasi_path_readlink( /** * The path of the symbolic link from which to read. */ - const char *path, + char const *path, /** * The buffer to which to write the contents of the symbolic link. */ @@ -1903,7 +2003,7 @@ __wasi_errno_t __wasi_path_remove_directory( /** * The path to a directory to remove. */ - const char *path + char const *path ) __attribute__((__warn_unused_result__)); /** * Rename a file or directory. @@ -1914,7 +2014,7 @@ __wasi_errno_t __wasi_path_rename( /** * The source path of the file or directory to rename. */ - const char *old_path, + char const *old_path, /** * The working directory at which the resolution of the new path starts. */ @@ -1922,7 +2022,7 @@ __wasi_errno_t __wasi_path_rename( /** * The destination path to which to rename the file or directory. */ - const char *new_path + char const *new_path ) __attribute__((__warn_unused_result__)); /** * Create a symbolic link. @@ -1932,12 +2032,12 @@ __wasi_errno_t __wasi_path_symlink( /** * The contents of the symbolic link. */ - const char *old_path, + char const *old_path, __wasi_fd_t fd, /** * The destination path at which to create the symbolic link. */ - const char *new_path + char const *new_path ) __attribute__((__warn_unused_result__)); /** * Unlink a file. @@ -1949,7 +2049,7 @@ __wasi_errno_t __wasi_path_unlink_file( /** * The path to a file to unlink. */ - const char *path + char const *path ) __attribute__((__warn_unused_result__)); /** * Concurrently poll for the occurrence of a set of events. @@ -1960,7 +2060,7 @@ __wasi_errno_t __wasi_poll_oneoff( /** * The events to which to subscribe. */ - const __wasi_subscription_t * in, + __wasi_subscription_t const * in, /** * The events that have occurred. */ @@ -1982,6 +2082,16 @@ _Noreturn void __wasi_proc_exit( */ __wasi_exitcode_t rval ); +/** + * Send a signal to the process of the calling thread. + * Note: This is similar to `raise` in POSIX. + */ +__wasi_errno_t __wasi_proc_raise( + /** + * The signal condition to trigger. + */ + __wasi_signal_t sig +) __attribute__((__warn_unused_result__)); /** * Temporarily yield execution of the calling thread. * Note: This is similar to `sched_yield` in POSIX. @@ -2033,7 +2143,7 @@ __wasi_errno_t __wasi_sock_recv( /** * List of scatter/gather vectors to which to store data. */ - const __wasi_iovec_t *ri_data, + __wasi_iovec_t const *ri_data, /** * The length of the array pointed to by `ri_data`. */ @@ -2057,7 +2167,7 @@ __wasi_errno_t __wasi_sock_send( /** * List of scatter/gather vectors to which to retrieve data */ - const __wasi_ciovec_t *si_data, + __wasi_ciovec_t const *si_data, /** * The length of the array pointed to by `si_data`. */ @@ -2081,25 +2191,6 @@ __wasi_errno_t __wasi_sock_shutdown( ) __attribute__((__warn_unused_result__)); /** @} */ -#ifdef _REENTRANT -/** - * Request a new thread to be created by the host. - * - * The host will create a new instance of the current module sharing its - * memory, find an exported entry function--`wasi_thread_start`--, and call the - * entry function with `start_arg` in the new thread. - * - * @see https://github.com/WebAssembly/wasi-threads/#readme - */ -int32_t __wasi_thread_spawn( - /** - * A pointer to an opaque struct to be passed to the module's entry - * function. - */ - void *start_arg -) __attribute__((__warn_unused_result__)); -#endif - #ifdef __cplusplus } #endif From 59a8228d4d8e51b55cb36cc8186caaac782c3f75 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 25 Oct 2023 18:02:27 -0400 Subject: [PATCH 04/43] fix atomic_arch for wasm64 --- libc-top-half/musl/arch/wasm32/atomic_arch.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/libc-top-half/musl/arch/wasm32/atomic_arch.h b/libc-top-half/musl/arch/wasm32/atomic_arch.h index c24ce2d7b..f561ad374 100644 --- a/libc-top-half/musl/arch/wasm32/atomic_arch.h +++ b/libc-top-half/musl/arch/wasm32/atomic_arch.h @@ -4,3 +4,12 @@ #define a_clz_64 __builtin_clzll #define a_ctz_32 __builtin_ctz #define a_ctz_64 __builtin_ctzll + +#ifdef __wasm64__ +#define a_cas_p a_cas_p +static inline void *a_cas_p(volatile void *p, void *t, void *s) +{ + __atomic_compare_exchange(&p,(volatile void **)&t,s,0,__ATOMIC_SEQ_CST,__ATOMIC_SEQ_CST); + return t; +} +#endif From 10dd8a727301e13d6893a8196028fe24d1eca2c0 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 25 Oct 2023 22:12:45 -0400 Subject: [PATCH 05/43] initial attempt to fix c_header.rs --- tools/wasi-headers/src/c_header.rs | 112 +++++++++++++++++++++++------ 1 file changed, 92 insertions(+), 20 deletions(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 2697af5fb..53a0c6363 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -473,8 +473,94 @@ fn print_func_signature(ret: &mut String, func: &InterfaceFunc, header: bool) { ret.push_str(")"); } +fn c_typeref_name(tref: &TypeRef) -> String { + match &**tref.type_() { + Type::List(_)=> { + return "__wasi_size_t,__wasi_size_t".to_string(); + }, + _ => {} + } + + match tref { + TypeRef::Name(named_type) => namedtype_name(&named_type), + TypeRef::Value(anon_type) => match &**anon_type { + Type::List(_) => unreachable!("arrays excluded above"), + Type::Builtin(b) => builtin_type_name(*b).to_string(), + Type::Pointer(_) => "__wasi_size_t".to_string(), + Type::ConstPointer(_) => "__wasi_size_t".to_string(), + Type::Record { .. } | Type::Variant { .. } | Type::Handle { .. } => unreachable!( + "wasi should not have anonymous structs, unions, enums, flags, handles" + ), + }, + } +} + +fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc) +{ + let mut params = Vec::new(); + for param in func.params.iter() { + add_params( + &mut params, + &ident_name(¶m.name), + ¶m.tref, + ¶m.docs, + ); + } + let mut iszero = true; + for param in func.params.iter() { + if iszero { + iszero = false + } + else { + ret.push_str(", "); + } + ret.push_str(&c_typeref_name(¶m.tref)); + } + match func.results.len() { + 0 => { + } + 1 => { + assert!(!func.noreturn); + + match &**func.results[0].tref.type_() { + Type::Variant(v) => { + let _err = match &v.cases[1].tref { + Some(ty) => ty, + None => panic!("unsupported type as a return value"), + }; + let ok = match &v.cases[0].tref { + Some(ty) => ty, + None => return, + }; + match &**ok.type_() { + Type::Record(r) if r.is_tuple() => { + for _ in r.members.iter() { + if iszero { + iszero = false + } + else { + ret.push_str(", "); + } + ret.push_str("__wasi_size_t"); + } + } + _ => { + if !iszero { + ret.push_str(", "); + } + ret.push_str("__wasi_size_t"); + } + } + } + _ => panic!("unsupported type as a return value"), + } + } + _ => panic!("unsupported number of return values"), + } +} + fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { - let (params, results) = func.wasm_signature(); + let (_, results) = func.wasm_signature(); if func.noreturn { ret.push_str("_Noreturn "); @@ -493,13 +579,8 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { ret.push_str("_"); ret.push_str(&ident_name(&func.name)); ret.push_str("("); - for (i, param) in params.iter().enumerate() { - if i > 0 { - ret.push_str(", "); - } - ret.push_str(wasm_arg_type(param)); - ret.push_str(&format!(" arg{}", i)); - } + print_c_typeref_names(ret, func); + ret.push_str(") __attribute__((\n"); ret.push_str(&format!( " __import_module__(\"{}\"),\n", @@ -629,15 +710,15 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { Instruction::ListPointerLength => { let list = operands.pop().unwrap(); - results.push(format!("(intptr_t) {}", list)); - results.push(format!("(intptr_t) {}_len", list)); + results.push(format!("{}", list)); + results.push(format!("{}_len", list)); } Instruction::ReturnPointerGet { n } => { // We currently match the wasi ABI with the actual // function's API signature in C, this means when a return // pointer is asked for we can simply forward our parameter // that's a return pointer. - results.push(format!("(intptr_t) retptr{}", n)); + results.push(format!("retptr{}", n)); } Instruction::Load { .. } => { @@ -868,12 +949,3 @@ fn wasm_type(wasm: &WasmType) -> &'static str { WasmType::F64 => "double", } } - -fn wasm_arg_type(wasm: &WasmType) -> &'static str { - match wasm { - WasmType::I32 => "intptr_t", - WasmType::I64 => "int64_t", - WasmType::F32 => "float", - WasmType::F64 => "double", - } -} From d14643258c20c5857b49976f564c8810214a5790 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Thu, 26 Oct 2023 16:09:13 -0400 Subject: [PATCH 06/43] Add support for 64 bits --- Makefile | 23 +- README.md | 12 + .../wasm64-wasi-threads/defined-symbols.txt | 1362 +++++++ expected/wasm64-wasi-threads/include-all.c | 171 + .../wasm64-wasi-threads/predefined-macros.txt | 3428 +++++++++++++++++ .../wasm64-wasi-threads/undefined-symbols.txt | 77 + expected/wasm64-wasi/defined-symbols.txt | 1207 ++++++ expected/wasm64-wasi/include-all.c | 170 + expected/wasm64-wasi/predefined-macros.txt | 3386 ++++++++++++++++ expected/wasm64-wasi/undefined-symbols.txt | 70 + libc-bottom-half/headers/public/wasi/api.h | 19 + libc-bottom-half/sources/__wasilibc_real.c | 239 +- .../src/thread/wasm64/wasi_thread_start.s | 48 + tools/wasi-headers/src/c_header.rs | 344 +- 14 files changed, 10193 insertions(+), 363 deletions(-) create mode 100644 expected/wasm64-wasi-threads/defined-symbols.txt create mode 100644 expected/wasm64-wasi-threads/include-all.c create mode 100644 expected/wasm64-wasi-threads/predefined-macros.txt create mode 100644 expected/wasm64-wasi-threads/undefined-symbols.txt create mode 100644 expected/wasm64-wasi/defined-symbols.txt create mode 100644 expected/wasm64-wasi/include-all.c create mode 100644 expected/wasm64-wasi/predefined-macros.txt create mode 100644 expected/wasm64-wasi/undefined-symbols.txt create mode 100644 libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s diff --git a/Makefile b/Makefile index 548c5cace..0400e0f12 100644 --- a/Makefile +++ b/Makefile @@ -22,6 +22,8 @@ BUILD_LIBC_TOP_HALF ?= yes # The directory where we will store intermediate artifacts. OBJDIR ?= build/$(TARGET_TRIPLE) +BUILD_WASI64 ?= no + # When the length is no larger than this threshold, we consider the # overhead of bulk memory opcodes to outweigh the performance benefit, # and fall back to the original musl implementation. See @@ -33,12 +35,20 @@ BULK_MEMORY_THRESHOLD ?= 32 # make command-line. # Set the default WASI target triple. +ifeq (${BUILD_WASI64}, yes) +TARGET_TRIPLE = wasm64-wasi +else TARGET_TRIPLE = wasm32-wasi +endif # Threaded version necessitates a different traget, as objects from different # targets can't be mixed together while linking. ifeq ($(THREAD_MODEL), posix) -TARGET_TRIPLE = wasm32-wasi-threads + ifeq (${BUILD_WASI64}, yes) + TARGET_TRIPLE = wasm64-wasi-threads + else + TARGET_TRIPLE = wasm32-wasi-threads + endif endif BUILTINS_LIB ?= $(shell ${CC} --print-libgcc-file-name) @@ -197,6 +207,15 @@ LIBC_TOP_HALF_MUSL_SOURCES = \ $(wildcard $(LIBC_TOP_HALF_MUSL_SRC_DIR)/crypt/*.c) ifeq ($(THREAD_MODEL), posix) + + +ifeq (${BUILD_WASI64}, yes) +WASM_THREAD_ASM_FILE = thread/wasm64/wasi_thread_start.s +else +WASM_THREAD_ASM_FILE = thread/wasm32/wasi_thread_start.s +endif + + LIBC_TOP_HALF_MUSL_SOURCES += \ $(addprefix $(LIBC_TOP_HALF_MUSL_SRC_DIR)/, \ env/__init_tls.c \ @@ -277,7 +296,7 @@ LIBC_TOP_HALF_MUSL_SOURCES += \ thread/sem_timedwait.c \ thread/sem_trywait.c \ thread/sem_wait.c \ - thread/wasm32/wasi_thread_start.s \ + ${WASM_THREAD_ASM_FILE} \ ) endif diff --git a/README.md b/README.md index ca5d15406..236e6d9f7 100644 --- a/README.md +++ b/README.md @@ -53,6 +53,18 @@ build directions with one addition: `make ... THREAD_MODEL=posix`. This creates additional artifacts in `sysroot/lib/wasm32-wasi-threads` to support `--target wasm32-wasi-threads`. +## 64 bits support + +To enable 64 bits support, follow the above +build directions with one addition: `make ... BUILD_WASI64=yes`. This creates +artifacts in `sysroot/lib/wasm64-wasi` to support `--target +wasm64-wasi`. + +You can build 64 bits with pthread support together with +'make ... BUILD_WASI64=yes THREAD_MODEL=posix'. This creates +artifacts in `sysroot/lib/wasm64-wasi-threads` to support `--target +wasm64-wasi-threads`. + ## Arch Linux AUR package For Arch Linux users, there's an official [wasi-libc] package tracking this Git diff --git a/expected/wasm64-wasi-threads/defined-symbols.txt b/expected/wasm64-wasi-threads/defined-symbols.txt new file mode 100644 index 000000000..ff2aa835a --- /dev/null +++ b/expected/wasm64-wasi-threads/defined-symbols.txt @@ -0,0 +1,1362 @@ +_CLOCK_MONOTONIC +_CLOCK_REALTIME +_Exit +_IO_feof_unlocked +_IO_ferror_unlocked +_IO_getc +_IO_getc_unlocked +_IO_putc +_IO_putc_unlocked +__EINVAL +__ENOMEM +__SIG_ERR +__SIG_IGN +__acquire_ptc +__aio_close +__asctime_r +__assert_fail +__at_quick_exit_lockptr +__atexit_lockptr +__c_dot_utf8 +__c_dot_utf8_locale +__c_locale +__clock +__clock_gettime +__clock_nanosleep +__copy_tls +__cos +__cosdf +__cosl +__crypt_blowfish +__crypt_des +__crypt_md5 +__crypt_r +__crypt_sha256 +__crypt_sha512 +__ctype_b_loc +__ctype_get_mb_cur_max +__ctype_tolower_loc +__ctype_toupper_loc +__cxa_atexit +__cxa_finalize +__default_guardsize +__default_stacksize +__des_setkey +__do_cleanup_pop +__do_cleanup_push +__do_des +__do_orphaned_stdio_locks +__dummy_reference +__duplocale +__env_rm_add +__errno_location +__exp2f_data +__exp_data +__expo2 +__expo2f +__fbufsize +__fclose_ca +__fdopen +__fesetround +__fgetwc_unlocked +__flbf +__floatscan +__fmodeflags +__fopen_rb_ca +__fpending +__fpurge +__fputwc_unlocked +__freadable +__freadahead +__freading +__freadptr +__freadptrinc +__freelocale +__fseeko +__fseeko_unlocked +__fseterr +__fsetlocking +__fsmu8 +__ftello +__ftello_unlocked +__funcs_on_exit +__funcs_on_quick_exit +__futimesat +__fwritable +__fwritex +__fwriting +__get_locale +__getdelim +__getentropy +__getopt_msg +__gmtime_r +__hwcap +__inet_aton +__init_ssp +__init_tp +__intscan +__invtrigl_R +__isalnum_l +__isalpha_l +__isatty +__isblank_l +__iscntrl_l +__isdigit_l +__isgraph_l +__islower_l +__isoc99_fscanf +__isoc99_fwscanf +__isoc99_scanf +__isoc99_sscanf +__isoc99_swscanf +__isoc99_vfscanf +__isoc99_vfwscanf +__isoc99_vscanf +__isoc99_vsscanf +__isoc99_vswscanf +__isoc99_vwscanf +__isoc99_wscanf +__isprint_l +__ispunct_l +__isspace_l +__isupper_l +__iswalnum_l +__iswalpha_l +__iswblank_l +__iswcntrl_l +__iswctype_l +__iswdigit_l +__iswgraph_l +__iswlower_l +__iswprint_l +__iswpunct_l +__iswspace_l +__iswupper_l +__iswxdigit_l +__isxdigit_l +__lctrans +__lctrans_cur +__lctrans_impl +__ldexp_cexp +__ldexp_cexpf +__lgamma_r +__lgammaf_r +__lgammal_r +__libc +__libc_calloc +__libc_free +__libc_malloc +__loc_is_allocated +__locale_lock +__locale_lockptr +__localtime_r +__lock +__lockfile +__log2_data +__log2f_data +__log_data +__logf_data +__lseek +__main_void +__math_divzero +__math_divzerof +__math_invalid +__math_invalidf +__math_invalidl +__math_oflow +__math_oflowf +__math_uflow +__math_uflowf +__math_xflow +__math_xflowf +__memrchr +__mo_lookup +__month_to_secs +__newlocale +__nl_langinfo +__nl_langinfo_l +__ofl_add +__ofl_lock +__ofl_unlock +__optpos +__optreset +__overflow +__p1evll +__pio2_hi +__pio2_lo +__pleval +__polevll +__posix_getopt +__pow_log_data +__powf_log2_data +__private_cond_signal +__progname +__progname_full +__pthread_cond_timedwait +__pthread_create +__pthread_join +__pthread_key_create +__pthread_key_delete +__pthread_mutex_lock +__pthread_mutex_timedlock +__pthread_mutex_trylock +__pthread_mutex_trylock_owner +__pthread_mutex_unlock +__pthread_once +__pthread_once_full +__pthread_rwlock_rdlock +__pthread_rwlock_timedrdlock +__pthread_rwlock_timedwrlock +__pthread_rwlock_tryrdlock +__pthread_rwlock_trywrlock +__pthread_rwlock_unlock +__pthread_rwlock_wrlock +__pthread_setcancelstate +__pthread_testcancel +__pthread_tsd_main +__pthread_tsd_run_dtors +__pthread_tsd_size +__putenv +__qsort_r +__rand48_step +__random_lockptr +__reallocarray +__register_locked_file +__release_ptc +__rem_pio2 +__rem_pio2_large +__rem_pio2f +__rem_pio2l +__rsqrt_tab +__secs_to_tm +__secs_to_zone +__seed48 +__shgetc +__shlim +__signgam +__sin +__sindf +__sinl +__small_printf +__stack_chk_fail +__stack_chk_fail_local +__stack_chk_guard +__stderr_FILE +__stderr_used +__stdin_FILE +__stdin_used +__stdio_close +__stdio_exit +__stdio_exit_needed +__stdio_ofl_lockptr +__stdio_read +__stdio_seek +__stdio_write +__stdout_FILE +__stdout_used +__stdout_write +__stpcpy +__stpncpy +__strcasecmp_l +__strchrnul +__strcoll_l +__strerror_l +__strftime_fmt_1 +__strftime_l +__strncasecmp_l +__strtod_l +__strtof_l +__strtoimax_internal +__strtol_internal +__strtold_l +__strtoll_internal +__strtoul_internal +__strtoull_internal +__strtoumax_internal +__strxfrm_l +__sysinfo +__sysv_signal +__tan +__tandf +__tanl +__testcancel +__thread_list_lock +__timedwait +__timedwait_cp +__tl_lock +__tl_sync +__tl_unlock +__tm_to_secs +__tm_to_tzname +__tolower_l +__toread +__toread_needs_stdio_exit +__toupper_l +__towctrans_l +__towlower_l +__towrite +__towrite_needs_stdio_exit +__towupper_l +__tre_mem_alloc_impl +__tre_mem_destroy +__tre_mem_new_impl +__tsearch_balance +__uflow +__unlist_locked_file +__unlock +__unlockfile +__uselocale +__utc +__wait +__wasi_args_get +__wasi_args_sizes_get +__wasi_clock_res_get +__wasi_clock_time_get +__wasi_environ_get +__wasi_environ_sizes_get +__wasi_fd_advise +__wasi_fd_allocate +__wasi_fd_close +__wasi_fd_datasync +__wasi_fd_fdstat_get +__wasi_fd_fdstat_set_flags +__wasi_fd_fdstat_set_rights +__wasi_fd_filestat_get +__wasi_fd_filestat_set_size +__wasi_fd_filestat_set_times +__wasi_fd_pread +__wasi_fd_prestat_dir_name +__wasi_fd_prestat_get +__wasi_fd_pwrite +__wasi_fd_read +__wasi_fd_readdir +__wasi_fd_renumber +__wasi_fd_seek +__wasi_fd_sync +__wasi_fd_tell +__wasi_fd_write +__wasi_init_tp +__wasi_path_create_directory +__wasi_path_filestat_get +__wasi_path_filestat_set_times +__wasi_path_link +__wasi_path_open +__wasi_path_readlink +__wasi_path_remove_directory +__wasi_path_rename +__wasi_path_symlink +__wasi_path_unlink_file +__wasi_poll_oneoff +__wasi_proc_exit +__wasi_proc_raise +__wasi_random_get +__wasi_sched_yield +__wasi_sock_accept +__wasi_sock_recv +__wasi_sock_send +__wasi_sock_shutdown +__wasi_thread_spawn +__wasi_thread_start_C +__wasilibc_access +__wasilibc_cwd +__wasilibc_cwd_lock +__wasilibc_cwd_unlock +__wasilibc_deinitialize_environ +__wasilibc_dttoif +__wasilibc_ensure_environ +__wasilibc_environ +__wasilibc_fd_renumber +__wasilibc_find_abspath +__wasilibc_find_relpath +__wasilibc_find_relpath_alloc +__wasilibc_futex_wait +__wasilibc_get_environ +__wasilibc_iftodt +__wasilibc_initialize_environ +__wasilibc_link +__wasilibc_link_newat +__wasilibc_link_oldat +__wasilibc_maybe_reinitialize_environ_eagerly +__wasilibc_nocwd___wasilibc_rmdirat +__wasilibc_nocwd___wasilibc_unlinkat +__wasilibc_nocwd_faccessat +__wasilibc_nocwd_fstatat +__wasilibc_nocwd_linkat +__wasilibc_nocwd_mkdirat_nomode +__wasilibc_nocwd_openat_nomode +__wasilibc_nocwd_opendirat +__wasilibc_nocwd_readlinkat +__wasilibc_nocwd_renameat +__wasilibc_nocwd_scandirat +__wasilibc_nocwd_symlinkat +__wasilibc_nocwd_utimensat +__wasilibc_open_nomode +__wasilibc_populate_preopens +__wasilibc_pthread_self +__wasilibc_register_preopened_fd +__wasilibc_rename_newat +__wasilibc_rename_oldat +__wasilibc_rmdirat +__wasilibc_stat +__wasilibc_tell +__wasilibc_unlinkat +__wasilibc_utimens +__wasm_call_dtors +__wcscoll_l +__wcsftime_l +__wcsxfrm_l +__wctrans_l +__wctype_l +__xpg_basename +__xpg_strerror_r +__year_to_secs +_environ +_exit +_flushlbf +_initialize +_pthread_cleanup_pop +_pthread_cleanup_push +_start +a64l +abort +abs +accept +accept4 +access +acos +acosf +acosh +acoshf +acoshl +acosl +aligned_alloc +alphasort +alphasort64 +arc4random +arc4random_buf +arc4random_uniform +asctime +asctime_r +asin +asinf +asinh +asinhf +asinhl +asinl +asprintf +at_quick_exit +atan +atan2 +atan2f +atan2l +atanf +atanh +atanhf +atanhl +atanl +atexit +atof +atoi +atol +atoll +basename +bcmp +bcopy +bsd_signal +bsearch +btowc +bzero +c16rtomb +c32rtomb +cabs +cabsf +cabsl +cacos +cacosf +cacosh +cacoshf +cacoshl +cacosl +calloc +carg +cargf +cargl +casin +casinf +casinh +casinhf +casinhl +casinl +catan +catanf +catanh +catanhf +catanhl +catanl +catclose +catgets +catopen +cbrt +cbrtf +cbrtl +ccos +ccosf +ccosh +ccoshf +ccoshl +ccosl +ceil +ceilf +ceill +cexp +cexpf +cexpl +chdir +cimag +cimagf +cimagl +clearenv +clearerr +clearerr_unlocked +clock +clock_getres +clock_gettime +clock_nanosleep +clog +clogf +clogl +close +closedir +confstr +conj +conjf +conjl +copysign +copysignf +copysignl +cos +cosf +cosh +coshf +coshl +cosl +cpow +cpowf +cpowl +cproj +cprojf +cprojl +creal +crealf +creall +creat +creat64 +crypt +crypt_r +csin +csinf +csinh +csinhf +csinhl +csinl +csqrt +csqrtf +csqrtl +ctan +ctanf +ctanh +ctanhf +ctanhl +ctanl +ctime +ctime_r +difftime +dirfd +dirname +div +dprintf +drand48 +drem +dremf +duplocale +ecvt +encrypt +environ +erand48 +erf +erfc +erfcf +erfcl +erff +erfl +errno +exit +exp +exp10 +exp10f +exp10l +exp2 +exp2f +exp2l +expf +expl +explicit_bzero +expm1 +expm1f +expm1l +fabs +fabsf +fabsl +faccessat +fclose +fcntl +fcvt +fdatasync +fdclosedir +fdim +fdimf +fdiml +fdopen +fdopendir +feclearexcept +fegetenv +fegetexceptflag +fegetround +feholdexcept +feof +feof_unlocked +feraiseexcept +ferror +ferror_unlocked +fesetenv +fesetexceptflag +fesetround +fetestexcept +feupdateenv +fflush +fflush_unlocked +ffs +ffsl +ffsll +fgetc +fgetc_unlocked +fgetln +fgetpos +fgetpos64 +fgets +fgets_unlocked +fgetwc +fgetwc_unlocked +fgetws +fgetws_unlocked +fileno +fileno_unlocked +finite +finitef +flockfile +floor +floorf +floorl +fma +fmaf +fmal +fmax +fmaxf +fmaxl +fmemopen +fmin +fminf +fminl +fmod +fmodf +fmodl +fmtmsg +fnmatch +fopen +fopen64 +fopencookie +fpathconf +fprintf +fpurge +fputc +fputc_unlocked +fputs +fputs_unlocked +fputwc +fputwc_unlocked +fputws +fputws_unlocked +fread +fread_unlocked +free +freelocale +freopen +freopen64 +frexp +frexpf +frexpl +fscanf +fseek +fseeko +fseeko64 +fsetpos +fsetpos64 +fstat +fstatat +fsync +ftell +ftello +ftello64 +ftime +ftruncate +ftrylockfile +funlockfile +futimens +futimesat +fwide +fwprintf +fwrite +fwrite_unlocked +fwscanf +gcvt +get_avphys_pages +get_nprocs +get_nprocs_conf +get_phys_pages +getc +getc_unlocked +getchar +getchar_unlocked +getcwd +getdate +getdate_err +getdelim +getdomainname +getentropy +getenv +gethostid +getline +getopt +getopt_long +getopt_long_only +getpagesize +getpid +getrusage +getsockopt +getsubopt +gettimeofday +getw +getwc +getwc_unlocked +getwchar +getwchar_unlocked +glob +glob64 +globfree +globfree64 +gmtime +gmtime_r +hcreate +hcreate_r +hdestroy +hdestroy_r +hsearch +hsearch_r +htonl +htons +hypot +hypotf +hypotl +iconv +iconv_close +iconv_open +ilogb +ilogbf +ilogbl +imaxabs +imaxdiv +in6addr_any +in6addr_loopback +index +inet_aton +inet_ntop +inet_pton +initstate +insque +ioctl +iprintf +isalnum +isalnum_l +isalpha +isalpha_l +isascii +isatty +isblank +isblank_l +iscntrl +iscntrl_l +isdigit +isdigit_l +isgraph +isgraph_l +islower +islower_l +isprint +isprint_l +ispunct +ispunct_l +isspace +isspace_l +isupper +isupper_l +iswalnum +iswalnum_l +iswalpha +iswalpha_l +iswblank +iswblank_l +iswcntrl +iswcntrl_l +iswctype +iswctype_l +iswdigit +iswdigit_l +iswgraph +iswgraph_l +iswlower +iswlower_l +iswprint +iswprint_l +iswpunct +iswpunct_l +iswspace +iswspace_l +iswupper +iswupper_l +iswxdigit +iswxdigit_l +isxdigit +isxdigit_l +j0 +j0f +j1 +j1f +jn +jnf +jrand48 +l64a +labs +lcong48 +ldexp +ldexpf +ldexpl +ldiv +lfind +lgamma +lgamma_r +lgammaf +lgammaf_r +lgammal +lgammal_r +link +linkat +llabs +lldiv +llrint +llrintf +llrintl +llround +llroundf +llroundl +localeconv +localtime +localtime_r +log +log10 +log10f +log10l +log1p +log1pf +log1pl +log2 +log2f +log2l +logb +logbf +logbl +logf +logl +lrand48 +lrint +lrintf +lrintl +lround +lroundf +lroundl +lsearch +lseek +lstat +malloc +malloc_usable_size +mblen +mbrlen +mbrtoc16 +mbrtoc32 +mbrtowc +mbsinit +mbsnrtowcs +mbsrtowcs +mbstowcs +mbtowc +memccpy +memchr +memcmp +memcpy +memmem +memmove +mempcpy +memrchr +memset +mkdir +mkdirat +mktime +mmap +modf +modff +modfl +mrand48 +munmap +nan +nanf +nanl +nanosleep +nearbyint +nearbyintf +nearbyintl +newlocale +nextafter +nextafterf +nextafterl +nexttoward +nexttowardf +nexttowardl +nftw +nftw64 +nl_langinfo +nl_langinfo_l +nrand48 +ntohl +ntohs +open +open_memstream +open_wmemstream +openat +opendir +opendirat +optarg +opterr +optind +optopt +optreset +pathconf +perror +poll +posix_close +posix_fadvise +posix_fallocate +posix_memalign +pow +pow10 +pow10f +pow10l +powf +powl +pread +preadv +printf +program_invocation_name +program_invocation_short_name +pselect +psignal +pthread_attr_destroy +pthread_attr_getdetachstate +pthread_attr_getguardsize +pthread_attr_getinheritsched +pthread_attr_getscope +pthread_attr_getstack +pthread_attr_getstacksize +pthread_attr_init +pthread_attr_setdetachstate +pthread_attr_setstack +pthread_attr_setstacksize +pthread_barrier_destroy +pthread_barrier_init +pthread_barrier_wait +pthread_barrierattr_getpshared +pthread_cond_broadcast +pthread_cond_destroy +pthread_cond_init +pthread_cond_signal +pthread_cond_timedwait +pthread_cond_wait +pthread_condattr_destroy +pthread_condattr_getpshared +pthread_condattr_init +pthread_condattr_setclock +pthread_condattr_setpshared +pthread_create +pthread_detach +pthread_equal +pthread_getspecific +pthread_join +pthread_key_create +pthread_key_delete +pthread_mutex_consistent +pthread_mutex_destroy +pthread_mutex_getprioceiling +pthread_mutex_init +pthread_mutex_lock +pthread_mutex_timedlock +pthread_mutex_trylock +pthread_mutex_unlock +pthread_mutexattr_destroy +pthread_mutexattr_getprotocol +pthread_mutexattr_getpshared +pthread_mutexattr_getrobust +pthread_mutexattr_gettype +pthread_mutexattr_init +pthread_mutexattr_setprotocol +pthread_mutexattr_setpshared +pthread_mutexattr_setrobust +pthread_mutexattr_settype +pthread_once +pthread_rwlock_destroy +pthread_rwlock_init +pthread_rwlock_rdlock +pthread_rwlock_timedrdlock +pthread_rwlock_timedwrlock +pthread_rwlock_tryrdlock +pthread_rwlock_trywrlock +pthread_rwlock_unlock +pthread_rwlock_wrlock +pthread_rwlockattr_destroy +pthread_rwlockattr_getpshared +pthread_rwlockattr_init +pthread_rwlockattr_setpshared +pthread_self +pthread_setcancelstate +pthread_setspecific +pthread_spin_destroy +pthread_spin_init +pthread_spin_lock +pthread_spin_trylock +pthread_spin_unlock +pthread_testcancel +pthread_timedjoin_np +pthread_tryjoin_np +putc +putc_unlocked +putchar +putchar_unlocked +putenv +puts +putw +putwc +putwc_unlocked +putwchar +putwchar_unlocked +pwrite +pwritev +qsort +qsort_r +quick_exit +raise +rand +rand_r +random +read +readdir +readlink +readlinkat +readv +realloc +reallocarray +recv +regcomp +regerror +regexec +regfree +remainder +remainderf +remainderl +remove +remque +remquo +remquof +remquol +rename +renameat +rewind +rewinddir +rindex +rint +rintf +rintl +rmdir +round +roundf +roundl +sbrk +scalb +scalbf +scalbln +scalblnf +scalblnl +scalbn +scalbnf +scalbnl +scandir +scandirat +scanf +sched_yield +seed48 +seekdir +select +sem_destroy +sem_getvalue +sem_init +sem_post +sem_timedwait +sem_trywait +sem_wait +send +setbuf +setbuffer +setenv +setkey +setlinebuf +setlocale +setstate +setvbuf +shutdown +signal +signgam +significand +significandf +sin +sincos +sincosf +sincosl +sinf +sinh +sinhf +sinhl +sinl +sleep +snprintf +sprintf +sqrt +sqrtf +sqrtl +srand +srand48 +srandom +sscanf +stat +stderr +stdin +stdout +stpcpy +stpncpy +strcasecmp +strcasecmp_l +strcasestr +strcat +strchr +strchrnul +strcmp +strcoll +strcoll_l +strcpy +strcspn +strdup +strerror +strerror_l +strerror_r +strfmon +strfmon_l +strftime +strftime_l +strlcat +strlcpy +strlen +strncasecmp +strncasecmp_l +strncat +strncmp +strncpy +strndup +strnlen +strpbrk +strptime +strrchr +strsep +strsignal +strspn +strstr +strtod +strtod_l +strtof +strtof_l +strtoimax +strtok +strtok_r +strtol +strtold +strtold_l +strtoll +strtoul +strtoull +strtoumax +strverscmp +strxfrm +strxfrm_l +swab +swprintf +swscanf +symlink +symlinkat +sysconf +tan +tanf +tanh +tanhf +tanhl +tanl +tdelete +tdestroy +telldir +tfind +tgamma +tgammaf +tgammal +thrd_current +thrd_detach +thrd_equal +thrd_sleep +time +timegm +times +timespec_get +toascii +tolower +tolower_l +toupper +toupper_l +towctrans +towctrans_l +towlower +towlower_l +towupper +towupper_l +trunc +truncate +truncf +truncl +tsearch +tss_get +twalk +uname +ungetc +ungetwc +unlink +unlinkat +unsetenv +uselocale +usleep +utime +utimensat +utimes +vasprintf +vdprintf +versionsort +versionsort64 +vfprintf +vfscanf +vfwprintf +vfwscanf +vprintf +vscanf +vsnprintf +vsprintf +vsscanf +vswprintf +vswscanf +vwprintf +vwscanf +wasi_thread_start +wcpcpy +wcpncpy +wcrtomb +wcscasecmp +wcscasecmp_l +wcscat +wcschr +wcscmp +wcscoll +wcscoll_l +wcscpy +wcscspn +wcsdup +wcsftime +wcsftime_l +wcslen +wcsncasecmp +wcsncasecmp_l +wcsncat +wcsncmp +wcsncpy +wcsnlen +wcsnrtombs +wcspbrk +wcsrchr +wcsrtombs +wcsspn +wcsstr +wcstod +wcstof +wcstoimax +wcstok +wcstol +wcstold +wcstoll +wcstombs +wcstoul +wcstoull +wcstoumax +wcswcs +wcswidth +wcsxfrm +wcsxfrm_l +wctob +wctomb +wctrans +wctrans_l +wctype +wctype_l +wcwidth +wmemchr +wmemcmp +wmemcpy +wmemmove +wmemset +wprintf +write +writev +wscanf +y0 +y0f +y1 +y1f +yn +ynf diff --git a/expected/wasm64-wasi-threads/include-all.c b/expected/wasm64-wasi-threads/include-all.c new file mode 100644 index 000000000..0b43b07d2 --- /dev/null +++ b/expected/wasm64-wasi-threads/include-all.c @@ -0,0 +1,171 @@ +#include <__errno.h> +#include <__errno_values.h> +#include <__fd_set.h> +#include <__function___isatty.h> +#include <__functions_malloc.h> +#include <__functions_memcpy.h> +#include <__header_dirent.h> +#include <__header_fcntl.h> +#include <__header_inttypes.h> +#include <__header_netinet_in.h> +#include <__header_poll.h> +#include <__header_stdlib.h> +#include <__header_string.h> +#include <__header_sys_ioctl.h> +#include <__header_sys_resource.h> +#include <__header_sys_socket.h> +#include <__header_sys_stat.h> +#include <__header_time.h> +#include <__header_unistd.h> +#include <__macro_FD_SETSIZE.h> +#include <__macro_PAGESIZE.h> +#include <__mode_t.h> +#include <__seek.h> +#include <__struct_dirent.h> +#include <__struct_in6_addr.h> +#include <__struct_in_addr.h> +#include <__struct_iovec.h> +#include <__struct_msghdr.h> +#include <__struct_pollfd.h> +#include <__struct_rusage.h> +#include <__struct_sockaddr.h> +#include <__struct_sockaddr_in.h> +#include <__struct_sockaddr_in6.h> +#include <__struct_sockaddr_storage.h> +#include <__struct_sockaddr_un.h> +#include <__struct_stat.h> +#include <__struct_timespec.h> +#include <__struct_timeval.h> +#include <__struct_tm.h> +#include <__struct_tms.h> +#include <__typedef_DIR.h> +#include <__typedef_blkcnt_t.h> +#include <__typedef_blksize_t.h> +#include <__typedef_clock_t.h> +#include <__typedef_clockid_t.h> +#include <__typedef_dev_t.h> +#include <__typedef_fd_set.h> +#include <__typedef_gid_t.h> +#include <__typedef_in_addr_t.h> +#include <__typedef_in_port_t.h> +#include <__typedef_ino_t.h> +#include <__typedef_mode_t.h> +#include <__typedef_nfds_t.h> +#include <__typedef_nlink_t.h> +#include <__typedef_off_t.h> +#include <__typedef_sa_family_t.h> +#include <__typedef_sigset_t.h> +#include <__typedef_socklen_t.h> +#include <__typedef_ssize_t.h> +#include <__typedef_suseconds_t.h> +#include <__typedef_time_t.h> +#include <__typedef_uid_t.h> +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt new file mode 100644 index 000000000..ecc94b942 --- /dev/null +++ b/expected/wasm64-wasi-threads/predefined-macros.txt @@ -0,0 +1,3428 @@ +#define ABDAY_1 0x20000 +#define ABDAY_2 0x20001 +#define ABDAY_3 0x20002 +#define ABDAY_4 0x20003 +#define ABDAY_5 0x20004 +#define ABDAY_6 0x20005 +#define ABDAY_7 0x20006 +#define ABMON_1 0x2000E +#define ABMON_10 0x20017 +#define ABMON_11 0x20018 +#define ABMON_12 0x20019 +#define ABMON_2 0x2000F +#define ABMON_3 0x20010 +#define ABMON_4 0x20011 +#define ABMON_5 0x20012 +#define ABMON_6 0x20013 +#define ABMON_7 0x20014 +#define ABMON_8 0x20015 +#define ABMON_9 0x20016 +#define ABORT 238 +#define ACK 04 +#define ADD ns_uop_add +#define ADJ_ESTERROR 0x0008 +#define ADJ_FREQUENCY 0x0002 +#define ADJ_MAXERROR 0x0004 +#define ADJ_MICRO 0x1000 +#define ADJ_NANO 0x2000 +#define ADJ_OFFSET 0x0001 +#define ADJ_OFFSET_SINGLESHOT 0x8001 +#define ADJ_OFFSET_SS_READ 0xa001 +#define ADJ_SETOFFSET 0x0100 +#define ADJ_STATUS 0x0010 +#define ADJ_TAI 0x0080 +#define ADJ_TICK 0x4000 +#define ADJ_TIMECONST 0x0020 +#define AF_INET PF_INET +#define AF_INET6 PF_INET6 +#define AF_UNIX 3 +#define AF_UNSPEC PF_UNSPEC +#define ALT_DIGITS 0x2002F +#define AM_STR 0x20026 +#define ANYMARK 0x01 +#define AO 245 +#define AREGTYPE '\0' +#define ARFMAG "`\n" +#define ARG_MAX 131072 +#define ARMAG "!\n" +#define AT_EACCESS (0x0) +#define AT_FDCWD (-2) +#define AT_REMOVEDIR (0x4) +#define AT_SYMLINK_FOLLOW (0x2) +#define AT_SYMLINK_NOFOLLOW (0x1) +#define AUTHTYPE_CNT 5 +#define AUTHTYPE_KERBEROS_V4 1 +#define AUTHTYPE_KERBEROS_V5 2 +#define AUTHTYPE_MINK 4 +#define AUTHTYPE_NAME(x) authtype_names[x] +#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) +#define AUTHTYPE_NULL 0 +#define AUTHTYPE_SPX 3 +#define AUTHTYPE_TEST 99 +#define AUTH_HOW_MASK 2 +#define AUTH_HOW_MUTUAL 2 +#define AUTH_HOW_ONE_WAY 0 +#define AUTH_WHO_CLIENT 0 +#define AUTH_WHO_MASK 1 +#define AUTH_WHO_SERVER 1 +#define AYT 246 +#define BIG_ENDIAN __BIG_ENDIAN +#define BITSPERBYTE CHAR_BIT +#define BLKTYPE '4' +#define BLK_BYTECOUNT 2 +#define BLK_EOF 0x40 +#define BLK_EOR 0x80 +#define BLK_ERRORS 0x20 +#define BLK_RESTART 0x10 +#define BREAK 243 +#define BUFSIZ 1024 +#define BYTE_ORDER __BYTE_ORDER +#define CANBSIZ 255 +#define CBRK CEOL +#define CDISCARD CTRL('o') +#define CDSUSP CTRL('y') +#define CEOF CTRL('d') +#define CEOL '\0' +#define CEOT CEOF +#define CERASE 0177 +#define CFLUSH CDISCARD +#define CHARBITS (sizeof(char) * 8) +#define CHARCLASS_NAME_MAX 14 +#define CHAR_BIT 8 +#define CHAR_MAX 127 +#define CHAR_MIN (-128) +#define CHRTYPE '3' +#define CINTR CTRL('c') +#define CKILL CTRL('u') +#define CLNEXT CTRL('v') +#define CLOCKS_PER_SEC ((clock_t)1000000000) +#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) +#define CLOCK_REALTIME (&_CLOCK_REALTIME) +#define CMIN 1 +#define CMPLX(x,y) __CMPLX(x, y, double) +#define CMPLXF(x,y) __CMPLX(x, y, float) +#define CMPLXL(x,y) __CMPLX(x, y, long double) +#define CODESET 14 +#define COLL_WEIGHTS_MAX 2 +#define COMPLETE 2 +#define CONTINUE 3 +#define CONTTYPE '7' +#define CQUIT 034 +#define CREPRINT CTRL('r') +#define CRNCYSTR 0x4000F +#define CRPRNT CREPRINT +#define CSTART CTRL('q') +#define CSTATUS '\0' +#define CSTOP CTRL('s') +#define CSUSP CTRL('z') +#define CTIME 0 +#define CTRL(x) ((x)&037) +#define CWERASE CTRL('w') +#define C_ANY ns_c_any +#define C_CHAOS ns_c_chaos +#define C_HS ns_c_hs +#define C_IN ns_c_in +#define C_IRGRP 000040 +#define C_IROTH 000004 +#define C_IRUSR 000400 +#define C_ISBLK 060000 +#define C_ISCHR 020000 +#define C_ISCTG 0110000 +#define C_ISDIR 040000 +#define C_ISFIFO 010000 +#define C_ISGID 002000 +#define C_ISLNK 0120000 +#define C_ISREG 0100000 +#define C_ISSOCK 0140000 +#define C_ISUID 004000 +#define C_ISVTX 001000 +#define C_IWGRP 000020 +#define C_IWOTH 000002 +#define C_IWUSR 000200 +#define C_IXGRP 000010 +#define C_IXOTH 000001 +#define C_IXUSR 000100 +#define C_NONE ns_c_none +#define DATA 03 +#define DAY_1 0x20007 +#define DAY_2 0x20008 +#define DAY_3 0x20009 +#define DAY_4 0x2000A +#define DAY_5 0x2000B +#define DAY_6 0x2000C +#define DAY_7 0x2000D +#define DBL_DECIMAL_DIG 17 +#define DBL_DIG 15 +#define DBL_EPSILON 2.22044604925031308085e-16 +#define DBL_HAS_SUBNORM 1 +#define DBL_MANT_DIG 53 +#define DBL_MAX 1.79769313486231570815e+308 +#define DBL_MAX_10_EXP 308 +#define DBL_MAX_EXP 1024 +#define DBL_MIN 2.22507385850720138309e-308 +#define DBL_MIN_10_EXP (-307) +#define DBL_MIN_EXP (-1021) +#define DBL_TRUE_MIN 4.94065645841246544177e-324 +#define DECIMAL_DIG 36 +#define DELAYTIMER_MAX 0x7fffffff +#define DELETE ns_uop_delete +#define DEV_BSIZE 512 +#define DIRTYPE '5' +#define DM 242 +#define DMAXEXP DBL_MAX_EXP +#define DMINEXP DBL_MIN_EXP +#define DO 253 +#define DONT 254 +#define DOUBLEBITS (sizeof(double) * 8) +#define DTTOIF(x) (__wasilibc_dttoif(x)) +#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE +#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE +#define DT_DIR __WASI_FILETYPE_DIRECTORY +#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM +#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK +#define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN +#define D_FMT 0x20029 +#define D_T_FMT 0x20028 +#define E2BIG __WASI_ERRNO_2BIG +#define EACCES __WASI_ERRNO_ACCES +#define EACCESS 2 +#define EADDRINUSE __WASI_ERRNO_ADDRINUSE +#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL +#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT +#define EAGAIN __WASI_ERRNO_AGAIN +#define EALREADY __WASI_ERRNO_ALREADY +#define EBADF __WASI_ERRNO_BADF +#define EBADID 5 +#define EBADMSG __WASI_ERRNO_BADMSG +#define EBADOP 4 +#define EBUSY __WASI_ERRNO_BUSY +#define EC 247 +#define ECANCELED __WASI_ERRNO_CANCELED +#define ECHILD __WASI_ERRNO_CHILD +#define ECONNABORTED __WASI_ERRNO_CONNABORTED +#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED +#define ECONNRESET __WASI_ERRNO_CONNRESET +#define EDEADLK __WASI_ERRNO_DEADLK +#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ +#define EDOM __WASI_ERRNO_DOM +#define EDQUOT __WASI_ERRNO_DQUOT +#define EEXIST __WASI_ERRNO_EXIST +#define EEXISTS 6 +#define EFAULT __WASI_ERRNO_FAULT +#define EFBIG __WASI_ERRNO_FBIG +#define EFD_CLOEXEC O_CLOEXEC +#define EFD_NONBLOCK O_NONBLOCK +#define EFD_SEMAPHORE 1 +#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH +#define EIDRM __WASI_ERRNO_IDRM +#define EILSEQ __WASI_ERRNO_ILSEQ +#define EINPROGRESS __WASI_ERRNO_INPROGRESS +#define EINTR __WASI_ERRNO_INTR +#define EINVAL __WASI_ERRNO_INVAL +#define EIO __WASI_ERRNO_IO +#define EISCONN __WASI_ERRNO_ISCONN +#define EISDIR __WASI_ERRNO_ISDIR +#define EL 248 +#define ELOOP __WASI_ERRNO_LOOP +#define EMFILE __WASI_ERRNO_MFILE +#define EMLINK __WASI_ERRNO_MLINK +#define EMSGSIZE __WASI_ERRNO_MSGSIZE +#define EMULTIHOP __WASI_ERRNO_MULTIHOP +#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG +#define ENCRYPT_CNT 9 +#define ENCRYPT_DEC_KEYID 8 +#define ENCRYPT_ENC_KEYID 7 +#define ENCRYPT_END 4 +#define ENCRYPT_IS 0 +#define ENCRYPT_NAME(x) encrypt_names[x] +#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) +#define ENCRYPT_REPLY 2 +#define ENCRYPT_REQEND 6 +#define ENCRYPT_REQSTART 5 +#define ENCRYPT_START 3 +#define ENCRYPT_SUPPORT 1 +#define ENCTYPE_ANY 0 +#define ENCTYPE_CNT 3 +#define ENCTYPE_DES_CFB64 1 +#define ENCTYPE_DES_OFB64 2 +#define ENCTYPE_NAME(x) enctype_names[x] +#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) +#define ENETDOWN __WASI_ERRNO_NETDOWN +#define ENETRESET __WASI_ERRNO_NETRESET +#define ENETUNREACH __WASI_ERRNO_NETUNREACH +#define ENFILE __WASI_ERRNO_NFILE +#define ENOBUFS __WASI_ERRNO_NOBUFS +#define ENODEV __WASI_ERRNO_NODEV +#define ENOENT __WASI_ERRNO_NOENT +#define ENOEXEC __WASI_ERRNO_NOEXEC +#define ENOLCK __WASI_ERRNO_NOLCK +#define ENOLINK __WASI_ERRNO_NOLINK +#define ENOMEM __WASI_ERRNO_NOMEM +#define ENOMSG __WASI_ERRNO_NOMSG +#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT +#define ENOSPACE 3 +#define ENOSPC __WASI_ERRNO_NOSPC +#define ENOSYS __WASI_ERRNO_NOSYS +#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE +#define ENOTCONN __WASI_ERRNO_NOTCONN +#define ENOTDIR __WASI_ERRNO_NOTDIR +#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY +#define ENOTFOUND 1 +#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE +#define ENOTSOCK __WASI_ERRNO_NOTSOCK +#define ENOTSUP __WASI_ERRNO_NOTSUP +#define ENOTTY __WASI_ERRNO_NOTTY +#define ENOUSER 7 +#define ENV_ESC 2 +#define ENV_USERVAR 3 +#define ENXIO __WASI_ERRNO_NXIO +#define EOF (-1) +#define EOPNOTSUPP ENOTSUP +#define EOR 239 +#define EOVERFLOW __WASI_ERRNO_OVERFLOW +#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD +#define EPERM __WASI_ERRNO_PERM +#define EPIPE __WASI_ERRNO_PIPE +#define EPROTO __WASI_ERRNO_PROTO +#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT +#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE +#define ERA 0x2002C +#define ERANGE __WASI_ERRNO_RANGE +#define ERA_D_FMT 0x2002E +#define ERA_D_T_FMT 0x20030 +#define ERA_T_FMT 0x20031 +#define EROFS __WASI_ERRNO_ROFS +#define ERROR 05 +#define ESPIPE __WASI_ERRNO_SPIPE +#define ESRCH __WASI_ERRNO_SRCH +#define ESTALE __WASI_ERRNO_STALE +#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT +#define ETXTBSY __WASI_ERRNO_TXTBSY +#define EUNDEF 0 +#define EWOULDBLOCK EAGAIN +#define EXDEV __WASI_ERRNO_XDEV +#define EXIT_FAILURE 1 +#define EXIT_SUCCESS 0 +#define EX_CANTCREAT 73 +#define EX_CONFIG 78 +#define EX_DATAERR 65 +#define EX_IOERR 74 +#define EX_NOHOST 68 +#define EX_NOINPUT 66 +#define EX_NOPERM 77 +#define EX_NOUSER 67 +#define EX_OK 0 +#define EX_OSERR 71 +#define EX_OSFILE 72 +#define EX_PROTOCOL 76 +#define EX_SOFTWARE 70 +#define EX_TEMPFAIL 75 +#define EX_UNAVAILABLE 69 +#define EX_USAGE 64 +#define EX__BASE 64 +#define EX__MAX 78 +#define FD_CLOEXEC (1) +#define FD_CLR(fd,set) (FD_CLR((fd), (set))) +#define FD_COPY(from,to) (FD_COPY((from), (to))) +#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) +#define FD_SET(fd,set) (FD_SET((fd), (set))) +#define FD_SETSIZE 1024 +#define FD_ZERO(set) (FD_ZERO((set))) +#define FE_ALL_EXCEPT 0 +#define FE_DFL_ENV ((const fenv_t *) -1) +#define FE_TONEAREST 0 +#define FIFOTYPE '6' +#define FILENAME_MAX 4096 +#define FILESIZEBITS 64 +#define FIONBIO 2 +#define FIONREAD 1 +#define FLOATBITS (sizeof(float) * 8) +#define FLT_DECIMAL_DIG 9 +#define FLT_DIG 6 +#define FLT_EPSILON 1.1920928955078125e-07F +#define FLT_EVAL_METHOD 0 +#define FLT_HAS_SUBNORM 1 +#define FLT_MANT_DIG 24 +#define FLT_MAX 3.40282346638528859812e+38F +#define FLT_MAX_10_EXP 38 +#define FLT_MAX_EXP 128 +#define FLT_MIN 1.17549435082228750797e-38F +#define FLT_MIN_10_EXP (-37) +#define FLT_MIN_EXP (-125) +#define FLT_RADIX 2 +#define FLT_ROUNDS (__builtin_flt_rounds()) +#define FLT_TRUE_MIN 1.40129846432481707092e-45F +#define FLUSHBAND 0x04 +#define FLUSHR 0x01 +#define FLUSHRW 0x03 +#define FLUSHW 0x02 +#define FMAXEXP FLT_MAX_EXP +#define FMINEXP FLT_MIN_EXP +#define FMNAMESZ 8 +#define FNM_CASEFOLD 0x10 +#define FNM_FILE_NAME FNM_PATHNAME +#define FNM_LEADING_DIR 0x8 +#define FNM_NOESCAPE 0x2 +#define FNM_NOMATCH 1 +#define FNM_NOSYS (-1) +#define FNM_PATHNAME 0x1 +#define FNM_PERIOD 0x4 +#define FOPEN_MAX 1000 +#define FORMERR ns_r_formerr +#define FORM_C 3 +#define FORM_N 1 +#define FORM_T 2 +#define FP_ILOGB0 FP_ILOGBNAN +#define FP_ILOGBNAN (-1-0x7fffffff) +#define FP_INFINITE 1 +#define FP_NAN 0 +#define FP_NORMAL 4 +#define FP_SUBNORMAL 3 +#define FP_ZERO 2 +#define FSETLOCKING_BYCALLER 2 +#define FSETLOCKING_INTERNAL 1 +#define FSETLOCKING_QUERY 0 +#define FTW_CHDIR 4 +#define FTW_D 2 +#define FTW_DEPTH 8 +#define FTW_DNR 3 +#define FTW_DP 6 +#define FTW_F 1 +#define FTW_MOUNT 2 +#define FTW_NS 4 +#define FTW_PHYS 1 +#define FTW_SL 5 +#define FTW_SLN 7 +#define F_GETFD (1) +#define F_GETFL (3) +#define F_LOCK 1 +#define F_OK (0) +#define F_SETFD (2) +#define F_SETFL (4) +#define F_TEST 3 +#define F_TLOCK 2 +#define F_ULOCK 0 +#define GA 249 +#define GETLONG NS_GET32 +#define GETSHORT NS_GET16 +#define GLOB_ABORTED 2 +#define GLOB_APPEND 0x20 +#define GLOB_DOOFFS 0x08 +#define GLOB_ERR 0x01 +#define GLOB_MARK 0x02 +#define GLOB_NOCHECK 0x10 +#define GLOB_NOESCAPE 0x40 +#define GLOB_NOMATCH 3 +#define GLOB_NOSORT 0x04 +#define GLOB_NOSPACE 1 +#define GLOB_NOSYS 4 +#define GLOB_PERIOD 0x80 +#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) +#define HFIXEDSZ NS_HFIXEDSZ +#define HIBITL MINLONG +#define HIBITS MINSHORT +#define HOST_NAME_MAX 255 +#define HUGE 3.40282346638528859812e+38F +#define HUGE_VAL ((double)INFINITY) +#define HUGE_VALF INFINITY +#define HUGE_VALL ((long double)INFINITY) +#define I _Complex_I +#define IAC 255 +#define ICMP6_DST_UNREACH 1 +#define ICMP6_DST_UNREACH_ADDR 3 +#define ICMP6_DST_UNREACH_ADMIN 1 +#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 +#define ICMP6_DST_UNREACH_NOPORT 4 +#define ICMP6_DST_UNREACH_NOROUTE 0 +#define ICMP6_ECHO_REPLY 129 +#define ICMP6_ECHO_REQUEST 128 +#define ICMP6_FILTER 1 +#define ICMP6_FILTER_BLOCK 1 +#define ICMP6_FILTER_BLOCKOTHERS 3 +#define ICMP6_FILTER_PASS 2 +#define ICMP6_FILTER_PASSONLY 4 +#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) +#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) +#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) +#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) +#define ICMP6_INFOMSG_MASK 0x80 +#define ICMP6_PACKET_TOO_BIG 2 +#define ICMP6_PARAMPROB_HEADER 0 +#define ICMP6_PARAMPROB_NEXTHEADER 1 +#define ICMP6_PARAMPROB_OPTION 2 +#define ICMP6_PARAM_PROB 4 +#define ICMP6_ROUTER_RENUMBERING 138 +#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 +#define ICMP6_RR_FLAGS_PREVDONE 0x08 +#define ICMP6_RR_FLAGS_REQRESULT 0x40 +#define ICMP6_RR_FLAGS_SPECSITE 0x10 +#define ICMP6_RR_FLAGS_TEST 0x80 +#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 +#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 +#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 +#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 +#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 +#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 +#define ICMP6_TIME_EXCEEDED 3 +#define ICMP6_TIME_EXCEED_REASSEMBLY 1 +#define ICMP6_TIME_EXCEED_TRANSIT 0 +#define ICMP_ADDRESS 17 +#define ICMP_ADDRESSREPLY 18 +#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) +#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) +#define ICMP_DEST_UNREACH 3 +#define ICMP_ECHO 8 +#define ICMP_ECHOREPLY 0 +#define ICMP_EXC_FRAGTIME 1 +#define ICMP_EXC_TTL 0 +#define ICMP_FRAG_NEEDED 4 +#define ICMP_HOST_ANO 10 +#define ICMP_HOST_ISOLATED 8 +#define ICMP_HOST_UNKNOWN 7 +#define ICMP_HOST_UNREACH 1 +#define ICMP_HOST_UNR_TOS 12 +#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) +#define ICMP_INFO_REPLY 16 +#define ICMP_INFO_REQUEST 15 +#define ICMP_IREQ 15 +#define ICMP_IREQREPLY 16 +#define ICMP_MASKLEN 12 +#define ICMP_MASKREPLY 18 +#define ICMP_MASKREQ 17 +#define ICMP_MAXTYPE 18 +#define ICMP_MINLEN 8 +#define ICMP_NET_ANO 9 +#define ICMP_NET_UNKNOWN 6 +#define ICMP_NET_UNREACH 0 +#define ICMP_NET_UNR_TOS 11 +#define ICMP_PARAMETERPROB 12 +#define ICMP_PARAMPROB 12 +#define ICMP_PARAMPROB_OPTABSENT 1 +#define ICMP_PKT_FILTERED 13 +#define ICMP_PORT_UNREACH 3 +#define ICMP_PREC_CUTOFF 15 +#define ICMP_PREC_VIOLATION 14 +#define ICMP_PROT_UNREACH 2 +#define ICMP_REDIRECT 5 +#define ICMP_REDIRECT_HOST 1 +#define ICMP_REDIRECT_NET 0 +#define ICMP_REDIRECT_TOSHOST 3 +#define ICMP_REDIRECT_TOSNET 2 +#define ICMP_REDIR_HOST 1 +#define ICMP_REDIR_HOSTTOS 3 +#define ICMP_REDIR_NET 0 +#define ICMP_REDIR_NETTOS 2 +#define ICMP_ROUTERADVERT 9 +#define ICMP_ROUTERSOLICIT 10 +#define ICMP_SOURCEQUENCH 4 +#define ICMP_SOURCE_QUENCH 4 +#define ICMP_SR_FAILED 5 +#define ICMP_TIMESTAMP 13 +#define ICMP_TIMESTAMPREPLY 14 +#define ICMP_TIME_EXCEEDED 11 +#define ICMP_TIMXCEED 11 +#define ICMP_TIMXCEED_INTRANS 0 +#define ICMP_TIMXCEED_REASS 1 +#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) +#define ICMP_TSTAMP 13 +#define ICMP_TSTAMPREPLY 14 +#define ICMP_UNREACH 3 +#define ICMP_UNREACH_FILTER_PROHIB 13 +#define ICMP_UNREACH_HOST 1 +#define ICMP_UNREACH_HOST_PRECEDENCE 14 +#define ICMP_UNREACH_HOST_PROHIB 10 +#define ICMP_UNREACH_HOST_UNKNOWN 7 +#define ICMP_UNREACH_ISOLATED 8 +#define ICMP_UNREACH_NEEDFRAG 4 +#define ICMP_UNREACH_NET 0 +#define ICMP_UNREACH_NET_PROHIB 9 +#define ICMP_UNREACH_NET_UNKNOWN 6 +#define ICMP_UNREACH_PORT 3 +#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 +#define ICMP_UNREACH_PROTOCOL 2 +#define ICMP_UNREACH_SRCFAIL 5 +#define ICMP_UNREACH_TOSHOST 12 +#define ICMP_UNREACH_TOSNET 11 +#define IFTODT(x) (__wasilibc_iftodt(x)) +#define IGMP_AWAKENING_MEMBER 5 +#define IGMP_DELAYING_MEMBER 1 +#define IGMP_DVMRP 0x13 +#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP +#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY +#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT +#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT +#define IGMP_IDLE_MEMBER 2 +#define IGMP_LAZY_MEMBER 3 +#define IGMP_MAX_HOST_REPORT_DELAY 10 +#define IGMP_MEMBERSHIP_QUERY 0x11 +#define IGMP_MINLEN 8 +#define IGMP_MTRACE 0x1f +#define IGMP_MTRACE_RESP 0x1e +#define IGMP_PIM 0x14 +#define IGMP_SLEEPING_MEMBER 4 +#define IGMP_TIMER_SCALE 10 +#define IGMP_TRACE 0x15 +#define IGMP_V1_MEMBERSHIP_REPORT 0x12 +#define IGMP_V2_LEAVE_GROUP 0x17 +#define IGMP_V2_MEMBERSHIP_REPORT 0x16 +#define IGMP_v1_ROUTER 1 +#define IGMP_v2_ROUTER 2 +#define IN6ADDRSZ NS_IN6ADDRSZ +#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } +#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } +#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) +#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) +#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) +#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) +#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) +#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) +#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) +#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) +#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) +#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) +#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) +#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) +#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) +#define INADDRSZ NS_INADDRSZ +#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) +#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) +#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) +#define INADDR_ANY ((in_addr_t) 0x00000000) +#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) +#define INADDR_DUMMY ((in_addr_t) 0xc0000008) +#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) +#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) +#define INADDR_NONE ((in_addr_t) 0xffffffff) +#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) +#define INDIR_MASK NS_CMPRSFLGS +#define INET6_ADDRSTRLEN 46 +#define INET_ADDRSTRLEN 16 +#define INFINITY 1e5000f +#define INT16SZ NS_INT16SZ +#define INT16_C(c) c +#define INT16_MAX (0x7fff) +#define INT16_MIN (-1-0x7fff) +#define INT32SZ NS_INT32SZ +#define INT32_C(c) c +#define INT32_MAX (0x7fffffff) +#define INT32_MIN (-1-0x7fffffff) +#define INT64_C(c) c ## LL +#define INT64_MAX (0x7fffffffffffffff) +#define INT64_MIN (-1-0x7fffffffffffffff) +#define INT8SZ NS_INT8SZ +#define INT8_C(c) c +#define INT8_MAX (0x7f) +#define INT8_MIN (-1-0x7f) +#define INTBITS (sizeof(int) * 8) +#define INTMAX_C(c) c ## LL +#define INTMAX_MAX INT64_MAX +#define INTMAX_MIN INT64_MIN +#define INTPTR_MAX INT32_MAX +#define INTPTR_MIN INT32_MIN +#define INT_FAST16_MAX INT16_MAX +#define INT_FAST16_MIN INT16_MIN +#define INT_FAST32_MAX INT32_MAX +#define INT_FAST32_MIN INT32_MIN +#define INT_FAST64_MAX INT64_MAX +#define INT_FAST64_MIN INT64_MIN +#define INT_FAST8_MAX INT8_MAX +#define INT_FAST8_MIN INT8_MIN +#define INT_LEAST16_MAX INT16_MAX +#define INT_LEAST16_MIN INT16_MIN +#define INT_LEAST32_MAX INT32_MAX +#define INT_LEAST32_MIN INT32_MIN +#define INT_LEAST64_MAX INT64_MAX +#define INT_LEAST64_MIN INT64_MIN +#define INT_LEAST8_MAX INT8_MAX +#define INT_LEAST8_MIN INT8_MIN +#define INT_MAX 0x7fffffff +#define INT_MIN (-1-0x7fffffff) +#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) +#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) +#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) +#define IN_CLASSA_MAX 128 +#define IN_CLASSA_NET 0xff000000 +#define IN_CLASSA_NSHIFT 24 +#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) +#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) +#define IN_CLASSB_MAX 65536 +#define IN_CLASSB_NET 0xffff0000 +#define IN_CLASSB_NSHIFT 16 +#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) +#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) +#define IN_CLASSC_NET 0xffffff00 +#define IN_CLASSC_NSHIFT 8 +#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) +#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) +#define IN_LOOPBACKNET 127 +#define IN_MULTICAST(a) IN_CLASSD(a) +#define IOV_MAX 1024 +#define IP 244 +#define IP6F_MORE_FRAG 0x0100 +#define IP6F_OFF_MASK 0xf8ff +#define IP6F_RESERVED_MASK 0x0600 +#define IP6OPT_JUMBO 0xc2 +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_NSAP_ADDR 0xc3 +#define IP6OPT_PAD1 0 +#define IP6OPT_PADN 1 +#define IP6OPT_ROUTER_ALERT 0x05 +#define IP6OPT_TUNNEL_LIMIT 0x04 +#define IP6OPT_TYPE(o) ((o) & 0xc0) +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xc0 +#define IP6OPT_TYPE_MUTABLE 0x20 +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6_ALERT_AN 0x0200 +#define IP6_ALERT_MLD 0x0000 +#define IP6_ALERT_RSVP 0x0100 +#define IPDEFTTL 64 +#define IPFRAGTTL 60 +#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) +#define IPOPT_CLASS_MASK 0x60 +#define IPOPT_CONTROL 0x00 +#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) +#define IPOPT_COPY 0x80 +#define IPOPT_DEBMEAS 0x40 +#define IPOPT_END IPOPT_EOL +#define IPOPT_EOL 0 +#define IPOPT_LSRR 131 +#define IPOPT_MEASUREMENT IPOPT_DEBMEAS +#define IPOPT_MINOFF 4 +#define IPOPT_NOOP IPOPT_NOP +#define IPOPT_NOP 1 +#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) +#define IPOPT_NUMBER_MASK 0x1f +#define IPOPT_OFFSET 2 +#define IPOPT_OLEN 1 +#define IPOPT_OPTVAL 0 +#define IPOPT_RA 148 +#define IPOPT_RESERVED1 0x20 +#define IPOPT_RESERVED2 0x60 +#define IPOPT_RR 7 +#define IPOPT_SATID 136 +#define IPOPT_SEC IPOPT_SECURITY +#define IPOPT_SECURITY 130 +#define IPOPT_SECUR_CONFID 0xf135 +#define IPOPT_SECUR_EFTO 0x789a +#define IPOPT_SECUR_MMMM 0xbc4d +#define IPOPT_SECUR_RESTR 0xaf13 +#define IPOPT_SECUR_SECRET 0xd788 +#define IPOPT_SECUR_TOPSECRET 0x6bc5 +#define IPOPT_SECUR_UNCLASS 0x0000 +#define IPOPT_SID IPOPT_SATID +#define IPOPT_SSRR 137 +#define IPOPT_TIMESTAMP IPOPT_TS +#define IPOPT_TS 68 +#define IPOPT_TS_PRESPEC 3 +#define IPOPT_TS_TSANDADDR 1 +#define IPOPT_TS_TSONLY 0 +#define IPPORT_RESERVED 1024 +#define IPPROTO_ICMP 1 +#define IPPROTO_IP 0 +#define IPPROTO_IPV6 41 +#define IPPROTO_RAW 255 +#define IPPROTO_TCP 6 +#define IPPROTO_UDP 17 +#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) +#define IPTOS_CLASS_CS0 0x00 +#define IPTOS_CLASS_CS1 0x20 +#define IPTOS_CLASS_CS2 0x40 +#define IPTOS_CLASS_CS3 0x60 +#define IPTOS_CLASS_CS4 0x80 +#define IPTOS_CLASS_CS5 0xa0 +#define IPTOS_CLASS_CS6 0xc0 +#define IPTOS_CLASS_CS7 0xe0 +#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 +#define IPTOS_CLASS_MASK 0xe0 +#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) +#define IPTOS_DSCP_AF11 0x28 +#define IPTOS_DSCP_AF12 0x30 +#define IPTOS_DSCP_AF13 0x38 +#define IPTOS_DSCP_AF21 0x48 +#define IPTOS_DSCP_AF22 0x50 +#define IPTOS_DSCP_AF23 0x58 +#define IPTOS_DSCP_AF31 0x68 +#define IPTOS_DSCP_AF32 0x70 +#define IPTOS_DSCP_AF33 0x78 +#define IPTOS_DSCP_AF41 0x88 +#define IPTOS_DSCP_AF42 0x90 +#define IPTOS_DSCP_AF43 0x98 +#define IPTOS_DSCP_EF 0xb8 +#define IPTOS_DSCP_MASK 0xfc +#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) +#define IPTOS_ECN_CE 0x03 +#define IPTOS_ECN_ECT0 0x02 +#define IPTOS_ECN_ECT1 0x01 +#define IPTOS_ECN_MASK 0x03 +#define IPTOS_ECN_NOT_ECT 0x00 +#define IPTOS_LOWCOST 0x02 +#define IPTOS_LOWDELAY 0x10 +#define IPTOS_MINCOST IPTOS_LOWCOST +#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) +#define IPTOS_PREC_CRITIC_ECP 0xa0 +#define IPTOS_PREC_FLASH 0x60 +#define IPTOS_PREC_FLASHOVERRIDE 0x80 +#define IPTOS_PREC_IMMEDIATE 0x40 +#define IPTOS_PREC_INTERNETCONTROL 0xc0 +#define IPTOS_PREC_MASK 0xe0 +#define IPTOS_PREC_NETCONTROL 0xe0 +#define IPTOS_PREC_PRIORITY 0x20 +#define IPTOS_PREC_ROUTINE 0x00 +#define IPTOS_RELIABILITY 0x04 +#define IPTOS_THROUGHPUT 0x08 +#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) +#define IPTOS_TOS_MASK 0x1E +#define IPTTLDEC 1 +#define IPV6_2292DSTOPTS 4 +#define IPV6_2292HOPLIMIT 8 +#define IPV6_2292HOPOPTS 3 +#define IPV6_2292PKTINFO 2 +#define IPV6_2292PKTOPTIONS 6 +#define IPV6_2292RTHDR 5 +#define IPV6_ADDRFORM 1 +#define IPV6_ADDR_PREFERENCES 72 +#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP +#define IPV6_AUTHHDR 10 +#define IPV6_AUTOFLOWLABEL 70 +#define IPV6_CHECKSUM 7 +#define IPV6_DONTFRAG 62 +#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP +#define IPV6_DSTOPTS 59 +#define IPV6_FREEBIND 78 +#define IPV6_HDRINCL 36 +#define IPV6_HOPLIMIT 52 +#define IPV6_HOPOPTS 54 +#define IPV6_IPSEC_POLICY 34 +#define IPV6_JOIN_ANYCAST 27 +#define IPV6_JOIN_GROUP 20 +#define IPV6_LEAVE_ANYCAST 28 +#define IPV6_LEAVE_GROUP 21 +#define IPV6_MINHOPCOUNT 73 +#define IPV6_MTU 24 +#define IPV6_MTU_DISCOVER 23 +#define IPV6_MULTICAST_ALL 29 +#define IPV6_MULTICAST_HOPS 18 +#define IPV6_MULTICAST_IF 17 +#define IPV6_MULTICAST_LOOP 19 +#define IPV6_NEXTHOP 9 +#define IPV6_ORIGDSTADDR 74 +#define IPV6_PATHMTU 61 +#define IPV6_PKTINFO 50 +#define IPV6_PMTUDISC_DO 2 +#define IPV6_PMTUDISC_DONT 0 +#define IPV6_PMTUDISC_INTERFACE 4 +#define IPV6_PMTUDISC_OMIT 5 +#define IPV6_PMTUDISC_PROBE 3 +#define IPV6_PMTUDISC_WANT 1 +#define IPV6_PREFER_SRC_CGA 0x0008 +#define IPV6_PREFER_SRC_COA 0x0004 +#define IPV6_PREFER_SRC_HOME 0x0400 +#define IPV6_PREFER_SRC_NONCGA 0x0800 +#define IPV6_PREFER_SRC_PUBLIC 0x0002 +#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 +#define IPV6_PREFER_SRC_TMP 0x0001 +#define IPV6_RECVDSTOPTS 58 +#define IPV6_RECVERR 25 +#define IPV6_RECVFRAGSIZE 77 +#define IPV6_RECVHOPLIMIT 51 +#define IPV6_RECVHOPOPTS 53 +#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR +#define IPV6_RECVPATHMTU 60 +#define IPV6_RECVPKTINFO 49 +#define IPV6_RECVRTHDR 56 +#define IPV6_RECVTCLASS 66 +#define IPV6_ROUTER_ALERT 22 +#define IPV6_ROUTER_ALERT_ISOLATE 30 +#define IPV6_RTHDR 57 +#define IPV6_RTHDRDSTOPTS 55 +#define IPV6_RTHDR_LOOSE 0 +#define IPV6_RTHDR_STRICT 1 +#define IPV6_RTHDR_TYPE_0 0 +#define IPV6_RXDSTOPTS IPV6_DSTOPTS +#define IPV6_RXHOPOPTS IPV6_HOPOPTS +#define IPV6_TCLASS 67 +#define IPV6_TRANSPARENT 75 +#define IPV6_UNICAST_HOPS 16 +#define IPV6_UNICAST_IF 76 +#define IPV6_V6ONLY 26 +#define IPV6_XFRM_POLICY 35 +#define IPVERSION 4 +#define IP_ADD_MEMBERSHIP 35 +#define IP_ADD_SOURCE_MEMBERSHIP 39 +#define IP_BIND_ADDRESS_NO_PORT 24 +#define IP_BLOCK_SOURCE 38 +#define IP_CHECKSUM 23 +#define IP_DEFAULT_MULTICAST_LOOP 1 +#define IP_DEFAULT_MULTICAST_TTL 1 +#define IP_DF 0x4000 +#define IP_DROP_MEMBERSHIP 36 +#define IP_DROP_SOURCE_MEMBERSHIP 40 +#define IP_FREEBIND 15 +#define IP_HDRINCL 3 +#define IP_IPSEC_POLICY 16 +#define IP_MAXPACKET 65535 +#define IP_MAX_MEMBERSHIPS 20 +#define IP_MF 0x2000 +#define IP_MINTTL 21 +#define IP_MSFILTER 41 +#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) +#define IP_MSS 576 +#define IP_MTU 14 +#define IP_MTU_DISCOVER 10 +#define IP_MULTICAST_ALL 49 +#define IP_MULTICAST_IF 32 +#define IP_MULTICAST_LOOP 34 +#define IP_MULTICAST_TTL 33 +#define IP_NODEFRAG 22 +#define IP_OFFMASK 0x1fff +#define IP_OPTIONS 4 +#define IP_ORIGDSTADDR 20 +#define IP_PASSSEC 18 +#define IP_PKTINFO 8 +#define IP_PKTOPTIONS 9 +#define IP_PMTUDISC 10 +#define IP_PMTUDISC_DO 2 +#define IP_PMTUDISC_DONT 0 +#define IP_PMTUDISC_INTERFACE 4 +#define IP_PMTUDISC_OMIT 5 +#define IP_PMTUDISC_PROBE 3 +#define IP_PMTUDISC_WANT 1 +#define IP_RECVERR 11 +#define IP_RECVERR_RFC4884 26 +#define IP_RECVFRAGSIZE 25 +#define IP_RECVOPTS 6 +#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR +#define IP_RECVRETOPTS IP_RETOPTS +#define IP_RECVTOS 13 +#define IP_RECVTTL 12 +#define IP_RETOPTS 7 +#define IP_RF 0x8000 +#define IP_ROUTER_ALERT 5 +#define IP_TOS 1 +#define IP_TRANSPARENT 19 +#define IP_TTL 2 +#define IP_UNBLOCK_SOURCE 37 +#define IP_UNICAST_IF 50 +#define IP_XFRM_POLICY 17 +#define IQUERY ns_o_iquery +#define I_ATMARK (__SID |31) +#define I_CANPUT (__SID |34) +#define I_CKBAND (__SID |29) +#define I_FDINSERT (__SID |16) +#define I_FIND (__SID |11) +#define I_FLUSH (__SID | 5) +#define I_FLUSHBAND (__SID |28) +#define I_GETBAND (__SID |30) +#define I_GETCLTIME (__SID |33) +#define I_GETSIG (__SID |10) +#define I_GRDOPT (__SID | 7) +#define I_GWROPT (__SID |20) +#define I_LINK (__SID |12) +#define I_LIST (__SID |21) +#define I_LOOK (__SID | 4) +#define I_NREAD (__SID | 1) +#define I_PEEK (__SID |15) +#define I_PLINK (__SID |22) +#define I_POP (__SID | 3) +#define I_PUNLINK (__SID |23) +#define I_PUSH (__SID | 2) +#define I_RECVFD (__SID |14) +#define I_SENDFD (__SID |17) +#define I_SETCLTIME (__SID |32) +#define I_SETSIG (__SID | 9) +#define I_SRDOPT (__SID | 6) +#define I_STR (__SID | 8) +#define I_SWROPT (__SID |19) +#define I_UNLINK (__SID |13) +#define LASTMARK 0x02 +#define LC_ALL 6 +#define LC_ALL_MASK 0x7fffffff +#define LC_COLLATE 3 +#define LC_COLLATE_MASK (1<(b))?(a):(b)) +#define MAXCDNAME NS_MAXCDNAME +#define MAXDNAME NS_MAXDNAME +#define MAXDOUBLE DBL_MAX +#define MAXFLOAT FLT_MAX +#define MAXHOSTNAMELEN 64 +#define MAXINT INT_MAX +#define MAXLABEL NS_MAXLABEL +#define MAXLONG LONG_MAX +#define MAXNAMLEN 255 +#define MAXPATHLEN 4096 +#define MAXSHORT SHRT_MAX +#define MAXSYMLINKS 20 +#define MAXTC 6 +#define MAXTTL 255 +#define MAX_IPOPTLEN 40 +#define MB_CUR_MAX (__ctype_get_mb_cur_max()) +#define MB_LEN_MAX 4 +#define MCAST_BLOCK_SOURCE 43 +#define MCAST_EXCLUDE 0 +#define MCAST_INCLUDE 1 +#define MCAST_JOIN_GROUP 42 +#define MCAST_JOIN_SOURCE_GROUP 46 +#define MCAST_LEAVE_GROUP 45 +#define MCAST_LEAVE_SOURCE_GROUP 47 +#define MCAST_MSFILTER 48 +#define MCAST_UNBLOCK_SOURCE 44 +#define MIN(a,b) (((a)<(b))?(a):(b)) +#define MINDOUBLE DBL_MIN +#define MINFLOAT FLT_MIN +#define MININT INT_MIN +#define MINLONG LONG_MIN +#define MINSHORT SHRT_MIN +#define MLD_LISTENER_QUERY 130 +#define MLD_LISTENER_REDUCTION 132 +#define MLD_LISTENER_REPORT 131 +#define MM_APPL 8 +#define MM_CONSOLE 512 +#define MM_ERROR 2 +#define MM_FIRM 4 +#define MM_HALT 1 +#define MM_HARD 1 +#define MM_INFO 4 +#define MM_NOCON 4 +#define MM_NOMSG 1 +#define MM_NOSEV 0 +#define MM_NOTOK (-1) +#define MM_NRECOV 128 +#define MM_NULLACT ((char*)0) +#define MM_NULLLBL ((char*)0) +#define MM_NULLMC 0L +#define MM_NULLSEV 0 +#define MM_NULLTAG ((char*)0) +#define MM_NULLTXT ((char*)0) +#define MM_OK 0 +#define MM_OPSYS 32 +#define MM_PRINT 256 +#define MM_RECOVER 64 +#define MM_SOFT 2 +#define MM_UTIL 16 +#define MM_WARNING 3 +#define MODE_ACK 0x04 +#define MODE_B 2 +#define MODE_C 3 +#define MODE_ECHO 0x0200 +#define MODE_EDIT 0x01 +#define MODE_FLOW 0x0100 +#define MODE_FORCE 0x1000 +#define MODE_INBIN 0x0400 +#define MODE_LIT_ECHO 0x10 +#define MODE_MASK 0x1f +#define MODE_OUTBIN 0x0800 +#define MODE_S 1 +#define MODE_SOFT_TAB 0x08 +#define MODE_TRAPSIG 0x02 +#define MOD_CLKA ADJ_OFFSET_SINGLESHOT +#define MOD_CLKB ADJ_TICK +#define MOD_ESTERROR ADJ_ESTERROR +#define MOD_FREQUENCY ADJ_FREQUENCY +#define MOD_MAXERROR ADJ_MAXERROR +#define MOD_MICRO ADJ_MICRO +#define MOD_NANO ADJ_NANO +#define MOD_OFFSET ADJ_OFFSET +#define MOD_STATUS ADJ_STATUS +#define MOD_TAI ADJ_TAI +#define MOD_TIMECONST ADJ_TIMECONST +#define MON_1 0x2001A +#define MON_10 0x20023 +#define MON_11 0x20024 +#define MON_12 0x20025 +#define MON_2 0x2001B +#define MON_3 0x2001C +#define MON_4 0x2001D +#define MON_5 0x2001E +#define MON_6 0x2001F +#define MON_7 0x20020 +#define MON_8 0x20021 +#define MON_9 0x20022 +#define MORECTL 1 +#define MOREDATA 2 +#define MSG_ANY 0x02 +#define MSG_BAND 0x04 +#define MSG_HIPRI 0x01 +#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK +#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED +#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL +#define MUXID_ALL (-1) +#define M_1_PI 0.31830988618379067154 +#define M_2_PI 0.63661977236758134308 +#define M_2_SQRTPI 1.12837916709551257390 +#define M_E 2.7182818284590452354 +#define M_LN10 2.30258509299404568402 +#define M_LN2 0.69314718055994530942 +#define M_LOG10E 0.43429448190325182765 +#define M_LOG2E 1.4426950408889634074 +#define M_PI 3.14159265358979323846 +#define M_PI_2 1.57079632679489661923 +#define M_PI_4 0.78539816339744830962 +#define M_SQRT1_2 0.70710678118654752440 +#define M_SQRT2 1.41421356237309504880 +#define NAMESERVER_PORT NS_DEFAULTPORT +#define NAME_MAX 255 +#define NAN (0.0f/0.0f) +#define NBBY 8 +#define NCARGS 131072 +#define ND_NA_FLAG_OVERRIDE 0x00000020 +#define ND_NA_FLAG_ROUTER 0x00000080 +#define ND_NA_FLAG_SOLICITED 0x00000040 +#define ND_NEIGHBOR_ADVERT 136 +#define ND_NEIGHBOR_SOLICIT 135 +#define ND_OPT_HOME_AGENT_INFO 8 +#define ND_OPT_MTU 5 +#define ND_OPT_PI_FLAG_AUTO 0x40 +#define ND_OPT_PI_FLAG_ONLINK 0x80 +#define ND_OPT_PI_FLAG_RADDR 0x20 +#define ND_OPT_PREFIX_INFORMATION 3 +#define ND_OPT_REDIRECTED_HEADER 4 +#define ND_OPT_RTR_ADV_INTERVAL 7 +#define ND_OPT_SOURCE_LINKADDR 1 +#define ND_OPT_TARGET_LINKADDR 2 +#define ND_RA_FLAG_HOME_AGENT 0x20 +#define ND_RA_FLAG_MANAGED 0x80 +#define ND_RA_FLAG_OTHER 0x40 +#define ND_REDIRECT 137 +#define ND_ROUTER_ADVERT 134 +#define ND_ROUTER_SOLICIT 133 +#define NEW_ENV_VALUE 1 +#define NEW_ENV_VAR 0 +#define NGROUPS 32 +#define NGROUPS_MAX 32 +#define NL_ARGMAX 9 +#define NL_CAT_LOCALE 1 +#define NL_LANGMAX 32 +#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) +#define NL_MSGMAX 32767 +#define NL_NMAX 16 +#define NL_SETD 1 +#define NL_SETMAX 255 +#define NL_TEXTMAX 2048 +#define NOERROR ns_r_noerror +#define NOEXPR 0x50001 +#define NOFILE 256 +#define NOGROUP (-1) +#define NOP 241 +#define NOSTR 0x50003 +#define NOTAUTH ns_r_notauth +#define NOTIMP ns_r_notimpl +#define NOTZONE ns_r_notzone +#define NR_ICMP_TYPES 18 +#define NR_ICMP_UNREACH 15 +#define NSLC 18 +#define NS_ALG_DH 2 +#define NS_ALG_DSA 3 +#define NS_ALG_DSS NS_ALG_DSA +#define NS_ALG_EXPIRE_ONLY 253 +#define NS_ALG_MD5RSA 1 +#define NS_ALG_PRIVATE_OID 254 +#define NS_CMPRSFLGS 0xc0 +#define NS_DEFAULTPORT 53 +#define NS_DSA_MAX_BYTES 405 +#define NS_DSA_MIN_SIZE 213 +#define NS_DSA_SIG_SIZE 41 +#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) +#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) +#define NS_HFIXEDSZ 12 +#define NS_IN6ADDRSZ 16 +#define NS_INADDRSZ 4 +#define NS_INT16SZ 2 +#define NS_INT32SZ 4 +#define NS_INT8SZ 1 +#define NS_KEY_EXTENDED_FLAGS 0x1000 +#define NS_KEY_NAME_ENTITY 0x0200 +#define NS_KEY_NAME_RESERVED 0x0300 +#define NS_KEY_NAME_TYPE 0x0300 +#define NS_KEY_NAME_USER 0x0000 +#define NS_KEY_NAME_ZONE 0x0100 +#define NS_KEY_NO_AUTH 0x8000 +#define NS_KEY_NO_CONF 0x4000 +#define NS_KEY_PROT_ANY 255 +#define NS_KEY_PROT_DNSSEC 3 +#define NS_KEY_PROT_EMAIL 2 +#define NS_KEY_PROT_IPSEC 4 +#define NS_KEY_PROT_TLS 1 +#define NS_KEY_RESERVED10 0x0020 +#define NS_KEY_RESERVED11 0x0010 +#define NS_KEY_RESERVED2 0x2000 +#define NS_KEY_RESERVED4 0x0800 +#define NS_KEY_RESERVED5 0x0400 +#define NS_KEY_RESERVED8 0x0080 +#define NS_KEY_RESERVED9 0x0040 +#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) +#define NS_KEY_RESERVED_BITMASK2 0xFFFF +#define NS_KEY_SIGNATORYMASK 0x000F +#define NS_KEY_TYPEMASK 0xC000 +#define NS_KEY_TYPE_AUTH_CONF 0x0000 +#define NS_KEY_TYPE_AUTH_ONLY 0x4000 +#define NS_KEY_TYPE_CONF_ONLY 0x8000 +#define NS_KEY_TYPE_NO_KEY 0xC000 +#define NS_MAXCDNAME 255 +#define NS_MAXDNAME 1025 +#define NS_MAXLABEL 63 +#define NS_MAXMSG 65535 +#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) +#define NS_MD5RSA_MAX_BITS 4096 +#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) +#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) +#define NS_MD5RSA_MIN_BITS 512 +#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) +#define NS_NOTIFY_OP ns_o_notify +#define NS_NXT_BITS 8 +#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_MAX 127 +#define NS_OPT_DNSSEC_OK 0x8000U +#define NS_OPT_NSID 3 +#define NS_PACKETSZ 512 +#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) +#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) +#define NS_QFIXEDSZ 4 +#define NS_RRFIXEDSZ 10 +#define NS_SIG_ALG 2 +#define NS_SIG_EXPIR 8 +#define NS_SIG_FOOT 16 +#define NS_SIG_LABELS 3 +#define NS_SIG_OTTL 4 +#define NS_SIG_SIGNED 12 +#define NS_SIG_SIGNER 18 +#define NS_SIG_TYPE 0 +#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" +#define NS_TSIG_ERROR_FORMERR -12 +#define NS_TSIG_ERROR_NO_SPACE -11 +#define NS_TSIG_ERROR_NO_TSIG -10 +#define NS_TSIG_FUDGE 300 +#define NS_TSIG_TCP_COUNT 100 +#define NS_UPDATE_OP ns_o_update +#define NTELOPTS (1+TELOPT_NEW_ENVIRON) +#define NULL ((void*)0) +#define NXDOMAIN ns_r_nxdomain +#define NXRRSET ns_r_nxrrset +#define NZERO 20 +#define OLD_ENV_VALUE 0 +#define OLD_ENV_VAR 1 +#define ONCE_FLAG_INIT 0 +#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) +#define O_APPEND __WASI_FDFLAGS_APPEND +#define O_CLOEXEC (0) +#define O_CREAT (__WASI_OFLAGS_CREAT << 12) +#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) +#define O_DSYNC __WASI_FDFLAGS_DSYNC +#define O_EXCL (__WASI_OFLAGS_EXCL << 12) +#define O_EXEC (0x02000000) +#define O_NOCTTY (0) +#define O_NOFOLLOW (0x01000000) +#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK +#define O_RDONLY (0x04000000) +#define O_RDWR (O_RDONLY | O_WRONLY) +#define O_RSYNC __WASI_FDFLAGS_RSYNC +#define O_SEARCH (0x08000000) +#define O_SYNC __WASI_FDFLAGS_SYNC +#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) +#define O_TTY_INIT (0) +#define O_WRONLY (0x10000000) +#define PACKETSZ NS_PACKETSZ +#define PACKET_ADD_MEMBERSHIP 1 +#define PACKET_AUXDATA 8 +#define PACKET_BROADCAST 1 +#define PACKET_COPY_THRESH 7 +#define PACKET_DROP_MEMBERSHIP 2 +#define PACKET_FANOUT 18 +#define PACKET_FANOUT_DATA 22 +#define PACKET_FASTROUTE 6 +#define PACKET_HDRLEN 11 +#define PACKET_HOST 0 +#define PACKET_IGNORE_OUTGOING 23 +#define PACKET_LOOPBACK 5 +#define PACKET_LOSS 14 +#define PACKET_MR_ALLMULTI 2 +#define PACKET_MR_MULTICAST 0 +#define PACKET_MR_PROMISC 1 +#define PACKET_MR_UNICAST 3 +#define PACKET_MULTICAST 2 +#define PACKET_ORIGDEV 9 +#define PACKET_OTHERHOST 3 +#define PACKET_OUTGOING 4 +#define PACKET_QDISC_BYPASS 20 +#define PACKET_RECV_OUTPUT 3 +#define PACKET_RESERVE 12 +#define PACKET_ROLLOVER_STATS 21 +#define PACKET_RX_RING 5 +#define PACKET_STATISTICS 6 +#define PACKET_TIMESTAMP 17 +#define PACKET_TX_HAS_OFF 19 +#define PACKET_TX_RING 13 +#define PACKET_TX_TIMESTAMP 16 +#define PACKET_VERSION 10 +#define PACKET_VNET_HDR 15 +#define PAGESIZE (0x10000) +#define PAGE_SIZE PAGESIZE +#define PATH_MAX 4096 +#define PDP_ENDIAN __PDP_ENDIAN +#define PF_INET 1 +#define PF_INET6 2 +#define PF_UNSPEC 0 +#define PM_STR 0x20027 +#define POLLERR 0x1000 +#define POLLHUP 0x2000 +#define POLLIN POLLRDNORM +#define POLLNVAL 0x4000 +#define POLLOUT POLLWRNORM +#define POLLRDNORM 0x1 +#define POLLWRNORM 0x2 +#define POSIX_CLOSE_RESTART 0 +#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED +#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE +#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL +#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM +#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL +#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED +#define PRELIM 1 +#define PRIX16 __UINT16_FMTX__ +#define PRIX32 __UINT32_FMTX__ +#define PRIX64 __UINT64_FMTX__ +#define PRIX8 __UINT8_FMTX__ +#define PRIXFAST16 __UINT_FAST16_FMTX__ +#define PRIXFAST32 __UINT_FAST32_FMTX__ +#define PRIXFAST64 __UINT_FAST64_FMTX__ +#define PRIXFAST8 __UINT_FAST8_FMTX__ +#define PRIXLEAST16 __UINT_LEAST16_FMTX__ +#define PRIXLEAST32 __UINT_LEAST32_FMTX__ +#define PRIXLEAST64 __UINT_LEAST64_FMTX__ +#define PRIXLEAST8 __UINT_LEAST8_FMTX__ +#define PRIXMAX __UINTMAX_FMTX__ +#define PRIXPTR __UINTPTR_FMTX__ +#define PRId16 __INT16_FMTd__ +#define PRId32 __INT32_FMTd__ +#define PRId64 __INT64_FMTd__ +#define PRId8 __INT8_FMTd__ +#define PRIdFAST16 __INT_FAST16_FMTd__ +#define PRIdFAST32 __INT_FAST32_FMTd__ +#define PRIdFAST64 __INT_FAST64_FMTd__ +#define PRIdFAST8 __INT_FAST8_FMTd__ +#define PRIdLEAST16 __INT_LEAST16_FMTd__ +#define PRIdLEAST32 __INT_LEAST32_FMTd__ +#define PRIdLEAST64 __INT_LEAST64_FMTd__ +#define PRIdLEAST8 __INT_LEAST8_FMTd__ +#define PRIdMAX __INTMAX_FMTd__ +#define PRIdPTR __INTPTR_FMTd__ +#define PRIi16 __INT16_FMTi__ +#define PRIi32 __INT32_FMTi__ +#define PRIi64 __INT64_FMTi__ +#define PRIi8 __INT8_FMTi__ +#define PRIiFAST16 __INT_FAST16_FMTi__ +#define PRIiFAST32 __INT_FAST32_FMTi__ +#define PRIiFAST64 __INT_FAST64_FMTi__ +#define PRIiFAST8 __INT_FAST8_FMTi__ +#define PRIiLEAST16 __INT_LEAST16_FMTi__ +#define PRIiLEAST32 __INT_LEAST32_FMTi__ +#define PRIiLEAST64 __INT_LEAST64_FMTi__ +#define PRIiLEAST8 __INT_LEAST8_FMTi__ +#define PRIiMAX __INTMAX_FMTi__ +#define PRIiPTR __INTPTR_FMTi__ +#define PRIo16 __UINT16_FMTo__ +#define PRIo32 __UINT32_FMTo__ +#define PRIo64 __UINT64_FMTo__ +#define PRIo8 __UINT8_FMTo__ +#define PRIoFAST16 __UINT_FAST16_FMTo__ +#define PRIoFAST32 __UINT_FAST32_FMTo__ +#define PRIoFAST64 __UINT_FAST64_FMTo__ +#define PRIoFAST8 __UINT_FAST8_FMTo__ +#define PRIoLEAST16 __UINT_LEAST16_FMTo__ +#define PRIoLEAST32 __UINT_LEAST32_FMTo__ +#define PRIoLEAST64 __UINT_LEAST64_FMTo__ +#define PRIoLEAST8 __UINT_LEAST8_FMTo__ +#define PRIoMAX __UINTMAX_FMTo__ +#define PRIoPTR __UINTPTR_FMTo__ +#define PRIu16 __UINT16_FMTu__ +#define PRIu32 __UINT32_FMTu__ +#define PRIu64 __UINT64_FMTu__ +#define PRIu8 __UINT8_FMTu__ +#define PRIuFAST16 __UINT_FAST16_FMTu__ +#define PRIuFAST32 __UINT_FAST32_FMTu__ +#define PRIuFAST64 __UINT_FAST64_FMTu__ +#define PRIuFAST8 __UINT_FAST8_FMTu__ +#define PRIuLEAST16 __UINT_LEAST16_FMTu__ +#define PRIuLEAST32 __UINT_LEAST32_FMTu__ +#define PRIuLEAST64 __UINT_LEAST64_FMTu__ +#define PRIuLEAST8 __UINT_LEAST8_FMTu__ +#define PRIuMAX __UINTMAX_FMTu__ +#define PRIuPTR __UINTPTR_FMTu__ +#define PRIx16 __UINT16_FMTx__ +#define PRIx32 __UINT32_FMTx__ +#define PRIx64 __UINT64_FMTx__ +#define PRIx8 __UINT8_FMTx__ +#define PRIxFAST16 __UINT_FAST16_FMTx__ +#define PRIxFAST32 __UINT_FAST32_FMTx__ +#define PRIxFAST64 __UINT_FAST64_FMTx__ +#define PRIxFAST8 __UINT_FAST8_FMTx__ +#define PRIxLEAST16 __UINT_LEAST16_FMTx__ +#define PRIxLEAST32 __UINT_LEAST32_FMTx__ +#define PRIxLEAST64 __UINT_LEAST64_FMTx__ +#define PRIxLEAST8 __UINT_LEAST8_FMTx__ +#define PRIxMAX __UINTMAX_FMTx__ +#define PRIxPTR __UINTPTR_FMTx__ +#define PTHREAD_BARRIER_SERIAL_THREAD (-1) +#define PTHREAD_CANCELED ((void *)-1) +#define PTHREAD_CANCEL_ASYNCHRONOUS 1 +#define PTHREAD_CANCEL_DEFERRED 0 +#define PTHREAD_CANCEL_DISABLE 1 +#define PTHREAD_CANCEL_ENABLE 0 +#define PTHREAD_CANCEL_MASKED 2 +#define PTHREAD_COND_INITIALIZER {{{0}}} +#define PTHREAD_CREATE_DETACHED 1 +#define PTHREAD_CREATE_JOINABLE 0 +#define PTHREAD_DESTRUCTOR_ITERATIONS 4 +#define PTHREAD_EXPLICIT_SCHED 1 +#define PTHREAD_INHERIT_SCHED 0 +#define PTHREAD_KEYS_MAX 128 +#define PTHREAD_MUTEX_DEFAULT 0 +#define PTHREAD_MUTEX_ERRORCHECK 2 +#define PTHREAD_MUTEX_INITIALIZER {{{0}}} +#define PTHREAD_MUTEX_NORMAL 0 +#define PTHREAD_MUTEX_RECURSIVE 1 +#define PTHREAD_MUTEX_ROBUST 1 +#define PTHREAD_MUTEX_STALLED 0 +#define PTHREAD_NULL ((pthread_t)0) +#define PTHREAD_ONCE_INIT 0 +#define PTHREAD_PRIO_INHERIT 1 +#define PTHREAD_PRIO_NONE 0 +#define PTHREAD_PRIO_PROTECT 2 +#define PTHREAD_PROCESS_PRIVATE 0 +#define PTHREAD_PROCESS_SHARED 1 +#define PTHREAD_RWLOCK_INITIALIZER {{{0}}} +#define PTHREAD_SCOPE_PROCESS 1 +#define PTHREAD_SCOPE_SYSTEM 0 +#define PTHREAD_STACK_MIN 2048 +#define PTRBITS (sizeof(char *) * 8) +#define PTRDIFF_MAX INT32_MAX +#define PTRDIFF_MIN INT32_MIN +#define PUTLONG NS_PUT32 +#define PUTSHORT NS_PUT16 +#define QFIXEDSZ NS_QFIXEDSZ +#define QUERY ns_o_query +#define RADIXCHAR 0x10000 +#define RAND_MAX (0x7fffffff) +#define REC_EOF '\002' +#define REC_EOR '\001' +#define REC_ESC '\377' +#define REFUSED ns_r_refused +#define REGTYPE '0' +#define REG_BADBR 10 +#define REG_BADPAT 2 +#define REG_BADRPT 13 +#define REG_EBRACE 9 +#define REG_EBRACK 7 +#define REG_ECOLLATE 3 +#define REG_ECTYPE 4 +#define REG_EESCAPE 5 +#define REG_ENOSYS -1 +#define REG_EPAREN 8 +#define REG_ERANGE 11 +#define REG_ESPACE 12 +#define REG_ESUBREG 6 +#define REG_EXTENDED 1 +#define REG_ICASE 2 +#define REG_NEWLINE 4 +#define REG_NOMATCH 1 +#define REG_NOSUB 8 +#define REG_NOTBOL 1 +#define REG_NOTEOL 2 +#define REG_OK 0 +#define RE_DUP_MAX 255 +#define RMSGD 0x0001 +#define RMSGN 0x0002 +#define RNORM 0x0000 +#define RPM_PCO_ADD 1 +#define RPM_PCO_CHANGE 2 +#define RPM_PCO_SETGLOBAL 3 +#define RPROTDAT 0x0004 +#define RPROTDIS 0x0008 +#define RPROTMASK 0x001C +#define RPROTNORM 0x0010 +#define RRFIXEDSZ NS_RRFIXEDSZ +#define RRQ 01 +#define RS_HIPRI 0x01 +#define RUSAGE_CHILDREN 2 +#define RUSAGE_SELF 1 +#define R_OK (4) +#define SARMAG 8 +#define SB 250 +#define SCHAR_MAX 127 +#define SCHAR_MIN (-128) +#define SCNd16 __INT16_FMTd__ +#define SCNd32 __INT32_FMTd__ +#define SCNd64 __INT64_FMTd__ +#define SCNd8 __INT8_FMTd__ +#define SCNdFAST16 __INT_FAST16_FMTd__ +#define SCNdFAST32 __INT_FAST32_FMTd__ +#define SCNdFAST64 __INT_FAST64_FMTd__ +#define SCNdFAST8 __INT_FAST8_FMTd__ +#define SCNdLEAST16 __INT_LEAST16_FMTd__ +#define SCNdLEAST32 __INT_LEAST32_FMTd__ +#define SCNdLEAST64 __INT_LEAST64_FMTd__ +#define SCNdLEAST8 __INT_LEAST8_FMTd__ +#define SCNdMAX __INTMAX_FMTd__ +#define SCNdPTR __INTPTR_FMTd__ +#define SCNi16 __INT16_FMTi__ +#define SCNi32 __INT32_FMTi__ +#define SCNi64 __INT64_FMTi__ +#define SCNi8 __INT8_FMTi__ +#define SCNiFAST16 __INT_FAST16_FMTi__ +#define SCNiFAST32 __INT_FAST32_FMTi__ +#define SCNiFAST64 __INT_FAST64_FMTi__ +#define SCNiFAST8 __INT_FAST8_FMTi__ +#define SCNiLEAST16 __INT_LEAST16_FMTi__ +#define SCNiLEAST32 __INT_LEAST32_FMTi__ +#define SCNiLEAST64 __INT_LEAST64_FMTi__ +#define SCNiLEAST8 __INT_LEAST8_FMTi__ +#define SCNiMAX __INTMAX_FMTi__ +#define SCNiPTR __INTPTR_FMTi__ +#define SCNo16 __UINT16_FMTo__ +#define SCNo32 __UINT32_FMTo__ +#define SCNo64 __UINT64_FMTo__ +#define SCNo8 __UINT8_FMTo__ +#define SCNoFAST16 __UINT_FAST16_FMTo__ +#define SCNoFAST32 __UINT_FAST32_FMTo__ +#define SCNoFAST64 __UINT_FAST64_FMTo__ +#define SCNoFAST8 __UINT_FAST8_FMTo__ +#define SCNoLEAST16 __UINT_LEAST16_FMTo__ +#define SCNoLEAST32 __UINT_LEAST32_FMTo__ +#define SCNoLEAST64 __UINT_LEAST64_FMTo__ +#define SCNoLEAST8 __UINT_LEAST8_FMTo__ +#define SCNoMAX __UINTMAX_FMTo__ +#define SCNoPTR __UINTPTR_FMTo__ +#define SCNu16 __UINT16_FMTu__ +#define SCNu32 __UINT32_FMTu__ +#define SCNu64 __UINT64_FMTu__ +#define SCNu8 __UINT8_FMTu__ +#define SCNuFAST16 __UINT_FAST16_FMTu__ +#define SCNuFAST32 __UINT_FAST32_FMTu__ +#define SCNuFAST64 __UINT_FAST64_FMTu__ +#define SCNuFAST8 __UINT_FAST8_FMTu__ +#define SCNuLEAST16 __UINT_LEAST16_FMTu__ +#define SCNuLEAST32 __UINT_LEAST32_FMTu__ +#define SCNuLEAST64 __UINT_LEAST64_FMTu__ +#define SCNuLEAST8 __UINT_LEAST8_FMTu__ +#define SCNuMAX __UINTMAX_FMTu__ +#define SCNuPTR __UINTPTR_FMTu__ +#define SCNx16 __UINT16_FMTx__ +#define SCNx32 __UINT32_FMTx__ +#define SCNx64 __UINT64_FMTx__ +#define SCNx8 __UINT8_FMTx__ +#define SCNxFAST16 __UINT_FAST16_FMTx__ +#define SCNxFAST32 __UINT_FAST32_FMTx__ +#define SCNxFAST64 __UINT_FAST64_FMTx__ +#define SCNxFAST8 __UINT_FAST8_FMTx__ +#define SCNxLEAST16 __UINT_LEAST16_FMTx__ +#define SCNxLEAST32 __UINT_LEAST32_FMTx__ +#define SCNxLEAST64 __UINT_LEAST64_FMTx__ +#define SCNxLEAST8 __UINT_LEAST8_FMTx__ +#define SCNxMAX __UINTMAX_FMTx__ +#define SCNxPTR __UINTPTR_FMTx__ +#define SE 240 +#define SEEK_CUR __WASI_WHENCE_CUR +#define SEEK_END __WASI_WHENCE_END +#define SEEK_SET __WASI_WHENCE_SET +#define SEGSIZE 512 +#define SEM_FAILED ((sem_t *)0) +#define SEM_NSEMS_MAX 256 +#define SEM_VALUE_MAX 0x7fffffff +#define SERVFAIL ns_r_servfail +#define SHORTBITS (sizeof(short) * 8) +#define SHRT_MAX 0x7fff +#define SHRT_MIN (-1-0x7fff) +#define SHUT_RD __WASI_SDFLAGS_RD +#define SHUT_RDWR (SHUT_RD | SHUT_WR) +#define SHUT_WR __WASI_SDFLAGS_WR +#define SIG_ATOMIC_MAX INT32_MAX +#define SIG_ATOMIC_MIN INT32_MIN +#define SIZE_MAX UINT32_MAX +#define SI_LOAD_SHIFT 16 +#define SLC_ABORT 7 +#define SLC_ACK 0x80 +#define SLC_AO 4 +#define SLC_AYT 5 +#define SLC_BRK 2 +#define SLC_CANTCHANGE 1 +#define SLC_DEFAULT 3 +#define SLC_EC 10 +#define SLC_EL 11 +#define SLC_EOF 8 +#define SLC_EOR 6 +#define SLC_EW 12 +#define SLC_FLAGS 1 +#define SLC_FLUSHIN 0x40 +#define SLC_FLUSHOUT 0x20 +#define SLC_FORW1 17 +#define SLC_FORW2 18 +#define SLC_FUNC 0 +#define SLC_IP 3 +#define SLC_LEVELBITS 0x03 +#define SLC_LNEXT 14 +#define SLC_NAME(x) slc_names[x] +#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, +#define SLC_NAMES SLC_NAMELIST +#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) +#define SLC_NOSUPPORT 0 +#define SLC_RP 13 +#define SLC_SUSP 9 +#define SLC_SYNCH 1 +#define SLC_VALUE 2 +#define SLC_VARIABLE 2 +#define SLC_XOFF 16 +#define SLC_XON 15 +#define SNDPIPE 0x002 +#define SNDZERO 0x001 +#define SOCK_CLOEXEC (0x00002000) +#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM +#define SOCK_NONBLOCK (0x00004000) +#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM +#define SOL_SOCKET 0x7fffffff +#define SOL_TCP 6 +#define SOL_UDP 17 +#define SO_TYPE 3 +#define SSIZE_MAX LONG_MAX +#define STATUS ns_o_status +#define STA_CLK 0x8000 +#define STA_CLOCKERR 0x1000 +#define STA_DEL 0x0020 +#define STA_FLL 0x0008 +#define STA_FREQHOLD 0x0080 +#define STA_INS 0x0010 +#define STA_MODE 0x4000 +#define STA_NANO 0x2000 +#define STA_PLL 0x0001 +#define STA_PPSERROR 0x0800 +#define STA_PPSFREQ 0x0002 +#define STA_PPSJITTER 0x0200 +#define STA_PPSSIGNAL 0x0100 +#define STA_PPSTIME 0x0004 +#define STA_PPSWANDER 0x0400 +#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) +#define STA_UNSYNC 0x0040 +#define STDERR_FILENO 2 +#define STDIN_FILENO 0 +#define STDOUT_FILENO 1 +#define STRU_F 1 +#define STRU_P 3 +#define STRU_R 2 +#define SUN_LEN(s) (2+strlen((s)->sun_path)) +#define SUSP 237 +#define SYMLOOP_MAX 40 +#define SYMTYPE '2' +#define SYNCH 242 +#define S_ADDT ns_s_ar +#define S_BANDURG 0x0200 +#define S_ERROR 0x0010 +#define S_HANGUP 0x0020 +#define S_HIPRI 0x0002 +#define S_IEXEC S_IXUSR +#define S_IFBLK (0x6000) +#define S_IFCHR (0x2000) +#define S_IFDIR (0x4000) +#define S_IFIFO (0xc000) +#define S_IFLNK (0xa000) +#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) +#define S_IFREG (0x8000) +#define S_IFSOCK (0xc000) +#define S_INPUT 0x0001 +#define S_IREAD S_IRUSR +#define S_IRGRP (0x20) +#define S_IROTH (0x4) +#define S_IRUSR (0x100) +#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) +#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) +#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) +#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) +#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) +#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) +#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) +#define S_ISGID (0x400) +#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) +#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) +#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) +#define S_ISUID (0x800) +#define S_ISVTX (0x200) +#define S_IWGRP (0x10) +#define S_IWOTH (0x2) +#define S_IWRITE S_IWUSR +#define S_IWUSR (0x80) +#define S_IXGRP (0x8) +#define S_IXOTH (0x1) +#define S_IXUSR (0x40) +#define S_MSG 0x0008 +#define S_OUTPUT 0x0004 +#define S_PREREQ ns_s_pr +#define S_RDBAND 0x0080 +#define S_RDNORM 0x0040 +#define S_UPDATE ns_s_ud +#define S_WRBAND 0x0100 +#define S_WRNORM S_OUTPUT +#define S_ZONE ns_s_zn +#define TCPI_OPT_ECN 8 +#define TCPI_OPT_SACK 2 +#define TCPI_OPT_TIMESTAMPS 1 +#define TCPI_OPT_WSCALE 4 +#define TCPOLEN_MAXSEG 4 +#define TCPOLEN_SACK_PERMITTED 2 +#define TCPOLEN_TIMESTAMP 10 +#define TCPOLEN_WINDOW 3 +#define TCPOPT_EOL 0 +#define TCPOPT_MAXSEG 2 +#define TCPOPT_NOP 1 +#define TCPOPT_SACK 5 +#define TCPOPT_SACK_PERMITTED 4 +#define TCPOPT_TIMESTAMP 8 +#define TCPOPT_WINDOW 3 +#define TCP_CA_CWR 2 +#define TCP_CA_Disorder 1 +#define TCP_CA_Loss 4 +#define TCP_CA_Open 0 +#define TCP_CA_Recovery 3 +#define TCP_CC_INFO 26 +#define TCP_CLOSE 7 +#define TCP_CLOSE_WAIT 8 +#define TCP_CLOSING 11 +#define TCP_CM_INQ TCP_INQ +#define TCP_CONGESTION 13 +#define TCP_CORK 3 +#define TCP_DEFER_ACCEPT 9 +#define TCP_ENCAP_ESPINTCP 7 +#define TCP_ESTABLISHED 1 +#define TCP_FASTOPEN 23 +#define TCP_FASTOPEN_CONNECT 30 +#define TCP_FASTOPEN_KEY 33 +#define TCP_FASTOPEN_NO_COOKIE 34 +#define TCP_FIN_WAIT1 4 +#define TCP_FIN_WAIT2 5 +#define TCP_INFO 11 +#define TCP_INQ 36 +#define TCP_KEEPCNT 6 +#define TCP_KEEPIDLE 4 +#define TCP_KEEPINTVL 5 +#define TCP_LAST_ACK 9 +#define TCP_LINGER2 8 +#define TCP_LISTEN 10 +#define TCP_MAXSEG 2 +#define TCP_MD5SIG 14 +#define TCP_MD5SIG_EXT 32 +#define TCP_MD5SIG_FLAG_IFINDEX 0x2 +#define TCP_MD5SIG_FLAG_PREFIX 0x1 +#define TCP_MD5SIG_MAXKEYLEN 80 +#define TCP_NODELAY 1 +#define TCP_NOTSENT_LOWAT 25 +#define TCP_QUEUE_SEQ 21 +#define TCP_QUICKACK 12 +#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 +#define TCP_REPAIR 19 +#define TCP_REPAIR_OFF 0 +#define TCP_REPAIR_OFF_NO_WP -1 +#define TCP_REPAIR_ON 1 +#define TCP_REPAIR_OPTIONS 22 +#define TCP_REPAIR_QUEUE 20 +#define TCP_REPAIR_WINDOW 29 +#define TCP_SAVED_SYN 28 +#define TCP_SAVE_SYN 27 +#define TCP_SYNCNT 7 +#define TCP_SYN_RECV 3 +#define TCP_SYN_SENT 2 +#define TCP_THIN_DUPACK 17 +#define TCP_THIN_LINEAR_TIMEOUTS 16 +#define TCP_TIMESTAMP 24 +#define TCP_TIME_WAIT 6 +#define TCP_TX_DELAY 37 +#define TCP_ULP 31 +#define TCP_USER_TIMEOUT 18 +#define TCP_WINDOW_CLAMP 10 +#define TCP_ZEROCOPY_RECEIVE 35 +#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] +#define TELCMD_FIRST xEOF +#define TELCMD_LAST IAC +#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) +#define TELOPT_3270REGIME 29 +#define TELOPT_AUTHENTICATION 37 +#define TELOPT_BINARY 0 +#define TELOPT_BM 19 +#define TELOPT_DET 20 +#define TELOPT_ECHO 1 +#define TELOPT_ENCRYPT 38 +#define TELOPT_EOR 25 +#define TELOPT_EXOPL 255 +#define TELOPT_LFLOW 33 +#define TELOPT_LINEMODE 34 +#define TELOPT_LOGOUT 18 +#define TELOPT_NAMS 4 +#define TELOPT_NAOCRD 10 +#define TELOPT_NAOFFD 13 +#define TELOPT_NAOHTD 12 +#define TELOPT_NAOHTS 11 +#define TELOPT_NAOL 8 +#define TELOPT_NAOLFD 16 +#define TELOPT_NAOP 9 +#define TELOPT_NAOVTD 15 +#define TELOPT_NAOVTS 14 +#define TELOPT_NAWS 31 +#define TELOPT_NEW_ENVIRON 39 +#define TELOPT_OLD_ENVIRON 36 +#define TELOPT_OUTMRK 27 +#define TELOPT_RCP 2 +#define TELOPT_RCTE 7 +#define TELOPT_SGA 3 +#define TELOPT_SNDLOC 23 +#define TELOPT_STATUS 5 +#define TELOPT_SUPDUP 21 +#define TELOPT_SUPDUPOUTPUT 22 +#define TELOPT_TM 6 +#define TELOPT_TSPEED 32 +#define TELOPT_TTYLOC 28 +#define TELOPT_TTYPE 24 +#define TELOPT_TUID 26 +#define TELOPT_X3PAD 30 +#define TELOPT_XASCII 17 +#define TELOPT_XDISPLOC 35 +#define TELQUAL_INFO 2 +#define TELQUAL_IS 0 +#define TELQUAL_NAME 3 +#define TELQUAL_REPLY 2 +#define TELQUAL_SEND 1 +#define TGEXEC 00010 +#define TGREAD 00040 +#define TGWRITE 00020 +#define THOUSEP 0x10001 +#define TH_ACK 0x10 +#define TH_FIN 0x01 +#define TH_PUSH 0x08 +#define TH_RST 0x04 +#define TH_SYN 0x02 +#define TH_URG 0x20 +#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME +#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) +#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) +#define TIME_BAD TIME_ERROR +#define TIME_DEL 2 +#define TIME_ERROR 5 +#define TIME_INS 1 +#define TIME_OK 0 +#define TIME_OOP 3 +#define TIME_UTC 1 +#define TIME_WAIT 4 +#define TMAGIC "ustar" +#define TMAGLEN 6 +#define TOEXEC 00001 +#define TOREAD 00004 +#define TOWRITE 00002 +#define TRANSIENT 4 +#define TSGID 02000 +#define TSS_DTOR_ITERATIONS 4 +#define TSUID 04000 +#define TSVTX 01000 +#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) +#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) +#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) +#define TTYDEF_SPEED (B9600) +#define TTY_NAME_MAX 32 +#define TUEXEC 00100 +#define TUREAD 00400 +#define TUWRITE 00200 +#define TVERSION "00" +#define TVERSLEN 2 +#define TYPE_A 1 +#define TYPE_E 2 +#define TYPE_I 3 +#define TYPE_L 4 +#define TZNAME_MAX 6 +#define T_A ns_t_a +#define T_A6 ns_t_a6 +#define T_AAAA ns_t_aaaa +#define T_AFSDB ns_t_afsdb +#define T_ANY ns_t_any +#define T_ATMA ns_t_atma +#define T_AXFR ns_t_axfr +#define T_CNAME ns_t_cname +#define T_DNAME ns_t_dname +#define T_EID ns_t_eid +#define T_FMT 0x2002A +#define T_FMT_AMPM 0x2002B +#define T_GPOS ns_t_gpos +#define T_HINFO ns_t_hinfo +#define T_ISDN ns_t_isdn +#define T_IXFR ns_t_ixfr +#define T_KEY ns_t_key +#define T_LOC ns_t_loc +#define T_MAILA ns_t_maila +#define T_MAILB ns_t_mailb +#define T_MB ns_t_mb +#define T_MD ns_t_md +#define T_MF ns_t_mf +#define T_MG ns_t_mg +#define T_MINFO ns_t_minfo +#define T_MR ns_t_mr +#define T_MX ns_t_mx +#define T_NAPTR ns_t_naptr +#define T_NIMLOC ns_t_nimloc +#define T_NS ns_t_ns +#define T_NSAP ns_t_nsap +#define T_NSAP_PTR ns_t_nsap_ptr +#define T_NULL ns_t_null +#define T_NXT ns_t_nxt +#define T_PTR ns_t_ptr +#define T_PX ns_t_px +#define T_RP ns_t_rp +#define T_RT ns_t_rt +#define T_SIG ns_t_sig +#define T_SOA ns_t_soa +#define T_SRV ns_t_srv +#define T_TSIG ns_t_tsig +#define T_TXT ns_t_txt +#define T_WKS ns_t_wks +#define T_X25 ns_t_x25 +#define UCHAR_MAX 255 +#define UDP_CORK 1 +#define UDP_ENCAP 100 +#define UDP_ENCAP_ESPINUDP 2 +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 +#define UDP_ENCAP_GTP0 4 +#define UDP_ENCAP_GTP1U 5 +#define UDP_ENCAP_L2TPINUDP 3 +#define UDP_ENCAP_RXRPC 6 +#define UDP_GRO 104 +#define UDP_NO_CHECK6_RX 102 +#define UDP_NO_CHECK6_TX 101 +#define UDP_SEGMENT 103 +#define UINT16_C(c) c +#define UINT16_MAX (0xffff) +#define UINT32_C(c) c ## U +#define UINT32_MAX (0xffffffffu) +#define UINT64_C(c) c ## ULL +#define UINT64_MAX (0xffffffffffffffffu) +#define UINT8_C(c) c +#define UINT8_MAX (0xff) +#define UINTMAX_C(c) c ## ULL +#define UINTMAX_MAX UINT64_MAX +#define UINTPTR_MAX UINT32_MAX +#define UINT_FAST16_MAX UINT16_MAX +#define UINT_FAST32_MAX UINT32_MAX +#define UINT_FAST64_MAX UINT64_MAX +#define UINT_FAST8_MAX UINT8_MAX +#define UINT_LEAST16_MAX UINT16_MAX +#define UINT_LEAST32_MAX UINT32_MAX +#define UINT_LEAST64_MAX UINT64_MAX +#define UINT_LEAST8_MAX UINT8_MAX +#define UINT_MAX 0xffffffffU +#define UIO_MAXIOV 1024 +#define ULLONG_MAX (2ULL*LLONG_MAX+1) +#define ULONG_MAX (2UL*LONG_MAX+1) +#define USHRT_MAX 0xffff +#define UTIME_NOW (-1) +#define UTIME_OMIT (-2) +#define WCHAR_MAX (0x7fffffff+L'\0') +#define WCHAR_MIN (-1-0x7fffffff+L'\0') +#define WEOF 0xffffffffU +#define WILL 251 +#define WINT_MAX UINT32_MAX +#define WINT_MIN 0U +#define WONT 252 +#define WORD_BIT 32 +#define WRQ 02 +#define W_OK (2) +#define X_OK (1) +#define YESEXPR 0x50000 +#define YESSTR 0x50002 +#define YXDOMAIN ns_r_yxdomain +#define YXRRSET ns_r_yxrrset +#define _ALLOCA_H +#define _ALL_SOURCE 1 +#define _ARPA_FTP_H +#define _ARPA_INET_H +#define _ARPA_NAMESER_H +#define _ARPA_TELNET_H +#define _ARPA_TFTP_H +#define _AR_H +#define _BYTESWAP_H +#define _COMPLEX_H +#define _CPIO_H +#define _CRYPT_H +#define _CS_GNU_LIBC_VERSION 2 +#define _CS_GNU_LIBPTHREAD_VERSION 3 +#define _CS_PATH 0 +#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 +#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 +#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 +#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 +#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 +#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 +#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 +#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 +#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 +#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 +#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 +#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 +#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 +#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 +#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 +#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 +#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 +#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 +#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 +#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 +#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 +#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 +#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 +#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 +#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 +#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 +#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 +#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 +#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 +#define _CS_V6_ENV 1148 +#define _CS_V7_ENV 1149 +#define _CTYPE_H +#define _Complex_I (0.0f+1.0fi) +#define _DIRENT_H +#define _DIRENT_HAVE_D_TYPE +#define _ENDIAN_H +#define _ERRNO_H +#define _ERR_H +#define _FCNTL_H +#define _FEATURES_H +#define _FENV_H +#define _FLOAT_H +#define _FMTMSG_H +#define _FNMATCH_H +#define _FTW_H +#define _GETOPT_H +#define _GLOB_H +#define _GNU_SOURCE 1 +#define _ICONV_H +#define _IFADDRS_H +#define _INTTYPES_H +#define _IOFBF 0 +#define _IOLBF 1 +#define _IONBF 2 +#define _ISO646_H +#define _LANGINFO_H +#define _LIBGEN_H +#define _LIMITS_H +#define _LOCALE_H +#define _LP64 1 +#define _MALLOC_H +#define _MATH_H +#define _MONETARY_H +#define _MQUEUE_H +#define _NETINET_ICMP6_H +#define _NETINET_IGMP_H +#define _NETINET_IN_H +#define _NETINET_IN_SYSTM_H +#define _NETINET_IP6_H +#define _NETINET_IP_H +#define _NETINET_IP_ICMP_H +#define _NETINET_TCP_H +#define _NETINET_UDP_H +#define _NETPACKET_PACKET_H +#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) +#define _NL_TYPES_H +#define _PC_2_SYMLINKS 20 +#define _PC_ALLOC_SIZE_MIN 18 +#define _PC_ASYNC_IO 10 +#define _PC_CHOWN_RESTRICTED 6 +#define _PC_FILESIZEBITS 13 +#define _PC_LINK_MAX 0 +#define _PC_MAX_CANON 1 +#define _PC_MAX_INPUT 2 +#define _PC_NAME_MAX 3 +#define _PC_NO_TRUNC 7 +#define _PC_PATH_MAX 4 +#define _PC_PIPE_BUF 5 +#define _PC_PRIO_IO 11 +#define _PC_REC_INCR_XFER_SIZE 14 +#define _PC_REC_MAX_XFER_SIZE 15 +#define _PC_REC_MIN_XFER_SIZE 16 +#define _PC_REC_XFER_ALIGN 17 +#define _PC_SOCK_MAXBUF 12 +#define _PC_SYMLINK_MAX 19 +#define _PC_SYNC_IO 9 +#define _PC_VDISABLE 8 +#define _POLL_H +#define _POSIX2_BC_BASE_MAX 99 +#define _POSIX2_BC_DIM_MAX 2048 +#define _POSIX2_BC_SCALE_MAX 99 +#define _POSIX2_BC_STRING_MAX 1000 +#define _POSIX2_CHARCLASS_NAME_MAX 14 +#define _POSIX2_COLL_WEIGHTS_MAX 2 +#define _POSIX2_C_BIND _POSIX_VERSION +#define _POSIX2_EXPR_NEST_MAX 32 +#define _POSIX2_LINE_MAX 2048 +#define _POSIX2_RE_DUP_MAX 255 +#define _POSIX2_VERSION _POSIX_VERSION +#define _POSIX_ADVISORY_INFO _POSIX_VERSION +#define _POSIX_AIO_LISTIO_MAX 2 +#define _POSIX_AIO_MAX 1 +#define _POSIX_ARG_MAX 4096 +#define _POSIX_BARRIERS _POSIX_VERSION +#define _POSIX_CHILD_MAX 25 +#define _POSIX_CHOWN_RESTRICTED 1 +#define _POSIX_CLOCKRES_MIN 20000000 +#define _POSIX_CLOCK_SELECTION _POSIX_VERSION +#define _POSIX_CPUTIME _POSIX_VERSION +#define _POSIX_DELAYTIMER_MAX 32 +#define _POSIX_FSYNC _POSIX_VERSION +#define _POSIX_HOST_NAME_MAX 255 +#define _POSIX_IPV6 _POSIX_VERSION +#define _POSIX_LINK_MAX 8 +#define _POSIX_LOGIN_NAME_MAX 9 +#define _POSIX_MAX_CANON 255 +#define _POSIX_MAX_INPUT 255 +#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION +#define _POSIX_MQ_OPEN_MAX 8 +#define _POSIX_MQ_PRIO_MAX 32 +#define _POSIX_NAME_MAX 14 +#define _POSIX_NGROUPS_MAX 8 +#define _POSIX_NO_TRUNC 1 +#define _POSIX_OPEN_MAX 20 +#define _POSIX_PATH_MAX 256 +#define _POSIX_PIPE_BUF 512 +#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION +#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION +#define _POSIX_REGEXP 1 +#define _POSIX_RE_DUP_MAX 255 +#define _POSIX_RTSIG_MAX 8 +#define _POSIX_SEM_NSEMS_MAX 256 +#define _POSIX_SEM_VALUE_MAX 32767 +#define _POSIX_SIGQUEUE_MAX 32 +#define _POSIX_SPIN_LOCKS _POSIX_VERSION +#define _POSIX_SSIZE_MAX 32767 +#define _POSIX_SS_REPL_MAX 4 +#define _POSIX_STREAM_MAX 8 +#define _POSIX_SYMLINK_MAX 255 +#define _POSIX_SYMLOOP_MAX 8 +#define _POSIX_THREADS _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION +#define _POSIX_THREAD_CPUTIME _POSIX_VERSION +#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 +#define _POSIX_THREAD_KEYS_MAX 128 +#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION +#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION +#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION +#define _POSIX_THREAD_THREADS_MAX 64 +#define _POSIX_TIMEOUTS _POSIX_VERSION +#define _POSIX_TIMERS _POSIX_VERSION +#define _POSIX_TIMER_MAX 32 +#define _POSIX_TRACE_EVENT_NAME_MAX 30 +#define _POSIX_TRACE_NAME_MAX 8 +#define _POSIX_TRACE_SYS_MAX 8 +#define _POSIX_TRACE_USER_EVENT_MAX 32 +#define _POSIX_TTY_NAME_MAX 9 +#define _POSIX_TZNAME_MAX 6 +#define _POSIX_V6_ILP32_OFFBIG (1) +#define _POSIX_V7_ILP32_OFFBIG (1) +#define _POSIX_VDISABLE 0 +#define _POSIX_VERSION 200809L +#define _PTHREAD_H +#define _PTRDIFF_T +#define _REENTRANT 1 +#define _REGEX_H +#define _SCHED_H +#define _SC_2_CHAR_TERM 95 +#define _SC_2_C_BIND 47 +#define _SC_2_C_DEV 48 +#define _SC_2_FORT_DEV 49 +#define _SC_2_FORT_RUN 50 +#define _SC_2_LOCALEDEF 52 +#define _SC_2_PBS 168 +#define _SC_2_PBS_ACCOUNTING 169 +#define _SC_2_PBS_CHECKPOINT 175 +#define _SC_2_PBS_LOCATE 170 +#define _SC_2_PBS_MESSAGE 171 +#define _SC_2_PBS_TRACK 172 +#define _SC_2_SW_DEV 51 +#define _SC_2_UPE 97 +#define _SC_2_VERSION 46 +#define _SC_ADVISORY_INFO 132 +#define _SC_AIO_LISTIO_MAX 23 +#define _SC_AIO_MAX 24 +#define _SC_AIO_PRIO_DELTA_MAX 25 +#define _SC_ARG_MAX 0 +#define _SC_ASYNCHRONOUS_IO 12 +#define _SC_ATEXIT_MAX 87 +#define _SC_AVPHYS_PAGES 86 +#define _SC_BARRIERS 133 +#define _SC_BC_BASE_MAX 36 +#define _SC_BC_DIM_MAX 37 +#define _SC_BC_SCALE_MAX 38 +#define _SC_BC_STRING_MAX 39 +#define _SC_CHILD_MAX 1 +#define _SC_CLK_TCK 2 +#define _SC_CLOCK_SELECTION 137 +#define _SC_COLL_WEIGHTS_MAX 40 +#define _SC_CPUTIME 138 +#define _SC_DELAYTIMER_MAX 26 +#define _SC_EXPR_NEST_MAX 42 +#define _SC_FSYNC 15 +#define _SC_GETGR_R_SIZE_MAX 69 +#define _SC_GETPW_R_SIZE_MAX 70 +#define _SC_HOST_NAME_MAX 180 +#define _SC_IOV_MAX 60 +#define _SC_IPV6 235 +#define _SC_JOB_CONTROL 7 +#define _SC_LINE_MAX 43 +#define _SC_LOGIN_NAME_MAX 71 +#define _SC_MAPPED_FILES 16 +#define _SC_MEMLOCK 17 +#define _SC_MEMLOCK_RANGE 18 +#define _SC_MEMORY_PROTECTION 19 +#define _SC_MESSAGE_PASSING 20 +#define _SC_MONOTONIC_CLOCK 149 +#define _SC_MQ_OPEN_MAX 27 +#define _SC_MQ_PRIO_MAX 28 +#define _SC_NGROUPS_MAX 3 +#define _SC_NPROCESSORS_CONF 83 +#define _SC_NPROCESSORS_ONLN 84 +#define _SC_NZERO 109 +#define _SC_OPEN_MAX 4 +#define _SC_PAGESIZE 30 +#define _SC_PAGE_SIZE 30 +#define _SC_PASS_MAX 88 +#define _SC_PHYS_PAGES 85 +#define _SC_PRIORITIZED_IO 13 +#define _SC_PRIORITY_SCHEDULING 10 +#define _SC_RAW_SOCKETS 236 +#define _SC_READER_WRITER_LOCKS 153 +#define _SC_REALTIME_SIGNALS 9 +#define _SC_REGEXP 155 +#define _SC_RE_DUP_MAX 44 +#define _SC_RTSIG_MAX 31 +#define _SC_SAVED_IDS 8 +#define _SC_SEMAPHORES 21 +#define _SC_SEM_NSEMS_MAX 32 +#define _SC_SEM_VALUE_MAX 33 +#define _SC_SHARED_MEMORY_OBJECTS 22 +#define _SC_SHELL 157 +#define _SC_SIGQUEUE_MAX 34 +#define _SC_SPAWN 159 +#define _SC_SPIN_LOCKS 154 +#define _SC_SPORADIC_SERVER 160 +#define _SC_SS_REPL_MAX 241 +#define _SC_STREAMS 174 +#define _SC_STREAM_MAX 5 +#define _SC_SYMLOOP_MAX 173 +#define _SC_SYNCHRONIZED_IO 14 +#define _SC_THREADS 67 +#define _SC_THREAD_ATTR_STACKADDR 77 +#define _SC_THREAD_ATTR_STACKSIZE 78 +#define _SC_THREAD_CPUTIME 139 +#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 +#define _SC_THREAD_KEYS_MAX 74 +#define _SC_THREAD_PRIORITY_SCHEDULING 79 +#define _SC_THREAD_PRIO_INHERIT 80 +#define _SC_THREAD_PRIO_PROTECT 81 +#define _SC_THREAD_PROCESS_SHARED 82 +#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 +#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 +#define _SC_THREAD_SAFE_FUNCTIONS 68 +#define _SC_THREAD_SPORADIC_SERVER 161 +#define _SC_THREAD_STACK_MIN 75 +#define _SC_THREAD_THREADS_MAX 76 +#define _SC_TIMEOUTS 164 +#define _SC_TIMERS 11 +#define _SC_TIMER_MAX 35 +#define _SC_TRACE 181 +#define _SC_TRACE_EVENT_FILTER 182 +#define _SC_TRACE_EVENT_NAME_MAX 242 +#define _SC_TRACE_INHERIT 183 +#define _SC_TRACE_LOG 184 +#define _SC_TRACE_NAME_MAX 243 +#define _SC_TRACE_SYS_MAX 244 +#define _SC_TRACE_USER_EVENT_MAX 245 +#define _SC_TTY_NAME_MAX 72 +#define _SC_TYPED_MEMORY_OBJECTS 165 +#define _SC_TZNAME_MAX 6 +#define _SC_UIO_MAXIOV 60 +#define _SC_V6_ILP32_OFF32 176 +#define _SC_V6_ILP32_OFFBIG 177 +#define _SC_V6_LP64_OFF64 178 +#define _SC_V6_LPBIG_OFFBIG 179 +#define _SC_V7_ILP32_OFF32 237 +#define _SC_V7_ILP32_OFFBIG 238 +#define _SC_V7_LP64_OFF64 239 +#define _SC_V7_LPBIG_OFFBIG 240 +#define _SC_VERSION 29 +#define _SC_XBS5_ILP32_OFF32 125 +#define _SC_XBS5_ILP32_OFFBIG 126 +#define _SC_XBS5_LP64_OFF64 127 +#define _SC_XBS5_LPBIG_OFFBIG 128 +#define _SC_XOPEN_CRYPT 92 +#define _SC_XOPEN_ENH_I18N 93 +#define _SC_XOPEN_LEGACY 129 +#define _SC_XOPEN_REALTIME 130 +#define _SC_XOPEN_REALTIME_THREADS 131 +#define _SC_XOPEN_SHM 94 +#define _SC_XOPEN_STREAMS 246 +#define _SC_XOPEN_UNIX 91 +#define _SC_XOPEN_VERSION 89 +#define _SC_XOPEN_XCU_VERSION 90 +#define _SC_XOPEN_XPG2 98 +#define _SC_XOPEN_XPG3 99 +#define _SC_XOPEN_XPG4 100 +#define _SEARCH_H +#define _SEMAPHORE_H +#define _SIZE_T +#define _STDALIGN_H +#define _STDBOOL_H +#define _STDC_PREDEF_H +#define _STDINT_H +#define _STDIO_EXT_H +#define _STDIO_H +#define _STDLIB_H +#define _STDNORETURN_H +#define _STRINGS_H +#define _STRING_H +#define _STROPTS_H +#define _SYSEXITS_H +#define _SYS_EVENTFD_H +#define _SYS_FILE_H +#define _SYS_IOCTL_H +#define _SYS_PARAM_H +#define _SYS_RANDOM_H +#define _SYS_REG_H +#define _SYS_SELECT_H +#define _SYS_SOCKET_H +#define _SYS_STAT_H +#define _SYS_SYSCALL_H +#define _SYS_SYSINFO_H +#define _SYS_TIMEB_H +#define _SYS_TIMEX_H +#define _SYS_TIME_H +#define _SYS_TTYDEFAULTS_H +#define _SYS_TYPES_H +#define _SYS_UIO_H +#define _SYS_UN_H +#define _SYS_UTSNAME_H +#define _TAR_H +#define _TGMATH_H +#define _THREADS_H +#define _TIME_H +#define _UCHAR_H +#define _UNISTD_H +#define _UTIME_H +#define _VALUES_H +#define _VA_LIST +#define _WCHAR_H +#define _WCHAR_T +#define _WCTYPE_H +#define _WINT_T +#define _XOPEN_ENH_I18N 1 +#define _XOPEN_IOV_MAX 16 +#define _XOPEN_NAME_MAX 255 +#define _XOPEN_PATH_MAX 1024 +#define _XOPEN_UNIX 1 +#define _XOPEN_VERSION 700 +#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) +#define __ATOMIC_ACQUIRE 2 +#define __ATOMIC_ACQ_REL 4 +#define __ATOMIC_CONSUME 1 +#define __ATOMIC_RELAXED 0 +#define __ATOMIC_RELEASE 3 +#define __ATOMIC_SEQ_CST 5 +#define __BIGGEST_ALIGNMENT__ 16 +#define __BIG_ENDIAN 4321 +#define __BIND 19950621 +#define __BYTE_ORDER __BYTE_ORDER__ +#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ +#define __CHAR16_TYPE__ unsigned short +#define __CHAR32_TYPE__ unsigned int +#define __CHAR_BIT__ 8 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __CLANG_MAX_ALIGN_T_DEFINED +#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) +#define __CONSTANT_CFSTRINGS__ 1 +#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) +#define __DBL_DECIMAL_DIG__ 17 +#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 +#define __DBL_DIG__ 15 +#define __DBL_EPSILON__ 2.2204460492503131e-16 +#define __DBL_HAS_DENORM__ 1 +#define __DBL_HAS_INFINITY__ 1 +#define __DBL_HAS_QUIET_NAN__ 1 +#define __DBL_MANT_DIG__ 53 +#define __DBL_MAX_10_EXP__ 308 +#define __DBL_MAX_EXP__ 1024 +#define __DBL_MAX__ 1.7976931348623157e+308 +#define __DBL_MIN_10_EXP__ (-307) +#define __DBL_MIN_EXP__ (-1021) +#define __DBL_MIN__ 2.2250738585072014e-308 +#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ +#define __DEFINED_FILE +#define __DEFINED___isoc_va_list +#define __DEFINED_blkcnt_t +#define __DEFINED_blksize_t +#define __DEFINED_clock_t +#define __DEFINED_clockid_t +#define __DEFINED_cnd_t +#define __DEFINED_dev_t +#define __DEFINED_double_t +#define __DEFINED_float_t +#define __DEFINED_fsblkcnt_t +#define __DEFINED_fsfilcnt_t +#define __DEFINED_gid_t +#define __DEFINED_id_t +#define __DEFINED_ino_t +#define __DEFINED_int16_t +#define __DEFINED_int32_t +#define __DEFINED_int64_t +#define __DEFINED_int8_t +#define __DEFINED_intmax_t +#define __DEFINED_intptr_t +#define __DEFINED_key_t +#define __DEFINED_locale_t +#define __DEFINED_mbstate_t +#define __DEFINED_mode_t +#define __DEFINED_mtx_t +#define __DEFINED_nlink_t +#define __DEFINED_off_t +#define __DEFINED_pid_t +#define __DEFINED_pthread_attr_t +#define __DEFINED_pthread_barrier_t +#define __DEFINED_pthread_barrierattr_t +#define __DEFINED_pthread_cond_t +#define __DEFINED_pthread_condattr_t +#define __DEFINED_pthread_key_t +#define __DEFINED_pthread_mutex_t +#define __DEFINED_pthread_mutexattr_t +#define __DEFINED_pthread_once_t +#define __DEFINED_pthread_rwlock_t +#define __DEFINED_pthread_rwlockattr_t +#define __DEFINED_pthread_spinlock_t +#define __DEFINED_pthread_t +#define __DEFINED_register_t +#define __DEFINED_regoff_t +#define __DEFINED_sa_family_t +#define __DEFINED_sigset_t +#define __DEFINED_size_t +#define __DEFINED_socklen_t +#define __DEFINED_ssize_t +#define __DEFINED_suseconds_t +#define __DEFINED_time_t +#define __DEFINED_timer_t +#define __DEFINED_u_int64_t +#define __DEFINED_uid_t +#define __DEFINED_uint16_t +#define __DEFINED_uint32_t +#define __DEFINED_uint64_t +#define __DEFINED_uint8_t +#define __DEFINED_uintmax_t +#define __DEFINED_uintptr_t +#define __DEFINED_useconds_t +#define __DEFINED_va_list +#define __DEFINED_wchar_t +#define __DEFINED_wctype_t +#define __DEFINED_wint_t +#define __FINITE_MATH_ONLY__ 0 +#define __FLOAT128__ 1 +#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) +#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) +#define __FLT_DECIMAL_DIG__ 9 +#define __FLT_DENORM_MIN__ 1.40129846e-45F +#define __FLT_DIG__ 6 +#define __FLT_EPSILON__ 1.19209290e-7F +#define __FLT_HAS_DENORM__ 1 +#define __FLT_HAS_INFINITY__ 1 +#define __FLT_HAS_QUIET_NAN__ 1 +#define __FLT_MANT_DIG__ 24 +#define __FLT_MAX_10_EXP__ 38 +#define __FLT_MAX_EXP__ 128 +#define __FLT_MAX__ 3.40282347e+38F +#define __FLT_MIN_10_EXP__ (-37) +#define __FLT_MIN_EXP__ (-125) +#define __FLT_MIN__ 1.17549435e-38F +#define __FLT_RADIX__ 2 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __GNUC_STDC_INLINE__ 1 +#define __GNUC_VA_LIST 1 +#define __GXX_ABI_VERSION 1002 +#define __INT16_C_SUFFIX__ +#define __INT16_FMTd__ "hd" +#define __INT16_FMTi__ "hi" +#define __INT16_MAX__ 32767 +#define __INT16_TYPE__ short +#define __INT32_C_SUFFIX__ +#define __INT32_FMTd__ "d" +#define __INT32_FMTi__ "i" +#define __INT32_MAX__ 2147483647 +#define __INT32_TYPE__ int +#define __INT64_C_SUFFIX__ LL +#define __INT64_FMTd__ "lld" +#define __INT64_FMTi__ "lli" +#define __INT64_MAX__ 9223372036854775807LL +#define __INT64_TYPE__ long long int +#define __INT8_C_SUFFIX__ +#define __INT8_FMTd__ "hhd" +#define __INT8_FMTi__ "hhi" +#define __INT8_MAX__ 127 +#define __INT8_TYPE__ signed char +#define __INTMAX_C_SUFFIX__ LL +#define __INTMAX_FMTd__ "lld" +#define __INTMAX_FMTi__ "lli" +#define __INTMAX_MAX__ 9223372036854775807LL +#define __INTMAX_TYPE__ long long int +#define __INTMAX_WIDTH__ 64 +#define __INTPTR_FMTd__ "ld" +#define __INTPTR_FMTi__ "li" +#define __INTPTR_MAX__ 9223372036854775807L +#define __INTPTR_TYPE__ long int +#define __INTPTR_WIDTH__ 64 +#define __INT_FAST16_FMTd__ "hd" +#define __INT_FAST16_FMTi__ "hi" +#define __INT_FAST16_MAX__ 32767 +#define __INT_FAST16_TYPE__ short +#define __INT_FAST32_FMTd__ "d" +#define __INT_FAST32_FMTi__ "i" +#define __INT_FAST32_MAX__ 2147483647 +#define __INT_FAST32_TYPE__ int +#define __INT_FAST64_FMTd__ "lld" +#define __INT_FAST64_FMTi__ "lli" +#define __INT_FAST64_MAX__ 9223372036854775807LL +#define __INT_FAST64_TYPE__ long long int +#define __INT_FAST8_FMTd__ "hhd" +#define __INT_FAST8_FMTi__ "hhi" +#define __INT_FAST8_MAX__ 127 +#define __INT_FAST8_TYPE__ signed char +#define __INT_LEAST16_FMTd__ "hd" +#define __INT_LEAST16_FMTi__ "hi" +#define __INT_LEAST16_MAX__ 32767 +#define __INT_LEAST16_TYPE__ short +#define __INT_LEAST32_FMTd__ "d" +#define __INT_LEAST32_FMTi__ "i" +#define __INT_LEAST32_MAX__ 2147483647 +#define __INT_LEAST32_TYPE__ int +#define __INT_LEAST64_FMTd__ "lld" +#define __INT_LEAST64_FMTi__ "lli" +#define __INT_LEAST64_MAX__ 9223372036854775807LL +#define __INT_LEAST64_TYPE__ long long int +#define __INT_LEAST8_FMTd__ "hhd" +#define __INT_LEAST8_FMTi__ "hhi" +#define __INT_LEAST8_MAX__ 127 +#define __INT_LEAST8_TYPE__ signed char +#define __INT_MAX__ 2147483647 +#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) +#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) +#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) +#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) +#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) +#define __LDBL_DECIMAL_DIG__ 36 +#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L +#define __LDBL_DIG__ 33 +#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L +#define __LDBL_HAS_DENORM__ 1 +#define __LDBL_HAS_INFINITY__ 1 +#define __LDBL_HAS_QUIET_NAN__ 1 +#define __LDBL_MANT_DIG__ 113 +#define __LDBL_MAX_10_EXP__ 4932 +#define __LDBL_MAX_EXP__ 16384 +#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L +#define __LDBL_MIN_10_EXP__ (-4931) +#define __LDBL_MIN_EXP__ (-16381) +#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L +#define __LITTLE_ENDIAN 1234 +#define __LITTLE_ENDIAN__ 1 +#define __LONG_LONG_MAX__ 9223372036854775807LL +#define __LONG_MAX __LONG_MAX__ +#define __LONG_MAX__ 9223372036854775807L +#define __LP64__ 1 +#define __NAMESER 19991006 +#define __NEED_FILE +#define __NEED___isoc_va_list +#define __NEED_blkcnt_t +#define __NEED_blksize_t +#define __NEED_clock_t +#define __NEED_clockid_t +#define __NEED_cnd_t +#define __NEED_dev_t +#define __NEED_double_t +#define __NEED_float_t +#define __NEED_fsblkcnt_t +#define __NEED_fsfilcnt_t +#define __NEED_gid_t +#define __NEED_id_t +#define __NEED_ino_t +#define __NEED_int16_t +#define __NEED_int32_t +#define __NEED_int64_t +#define __NEED_int8_t +#define __NEED_intmax_t +#define __NEED_intptr_t +#define __NEED_key_t +#define __NEED_locale_t +#define __NEED_mbstate_t +#define __NEED_mode_t +#define __NEED_mtx_t +#define __NEED_nlink_t +#define __NEED_off_t +#define __NEED_pid_t +#define __NEED_pthread_attr_t +#define __NEED_pthread_barrier_t +#define __NEED_pthread_barrierattr_t +#define __NEED_pthread_cond_t +#define __NEED_pthread_condattr_t +#define __NEED_pthread_key_t +#define __NEED_pthread_mutex_t +#define __NEED_pthread_mutexattr_t +#define __NEED_pthread_once_t +#define __NEED_pthread_rwlock_t +#define __NEED_pthread_rwlockattr_t +#define __NEED_pthread_spinlock_t +#define __NEED_pthread_t +#define __NEED_register_t +#define __NEED_regoff_t +#define __NEED_sa_family_t +#define __NEED_sigset_t +#define __NEED_size_t +#define __NEED_socklen_t +#define __NEED_ssize_t +#define __NEED_struct_iovec +#define __NEED_struct_timespec +#define __NEED_struct_timeval +#define __NEED_suseconds_t +#define __NEED_time_t +#define __NEED_timer_t +#define __NEED_u_int64_t +#define __NEED_uid_t +#define __NEED_uint16_t +#define __NEED_uint32_t +#define __NEED_uint64_t +#define __NEED_uint8_t +#define __NEED_uintmax_t +#define __NEED_uintptr_t +#define __NEED_useconds_t +#define __NEED_va_list +#define __NEED_wchar_t +#define __NEED_wctype_t +#define __NEED_wint_t +#define __OBJC_BOOL_IS_BOOL 0 +#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 +#define __OPENCL_MEMORY_SCOPE_DEVICE 2 +#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 +#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 +#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 +#define __ORDER_BIG_ENDIAN__ 4321 +#define __ORDER_LITTLE_ENDIAN__ 1234 +#define __ORDER_PDP_ENDIAN__ 3412 +#define __PDP_ENDIAN 3412 +#define __POINTER_WIDTH__ 64 +#define __PRAGMA_REDEFINE_EXTNAME 1 +#define __PTRDIFF_FMTd__ "ld" +#define __PTRDIFF_FMTi__ "li" +#define __PTRDIFF_MAX__ 9223372036854775807L +#define __PTRDIFF_TYPE__ long int +#define __PTRDIFF_WIDTH__ 64 +#define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#define __RETCAST(x) +#define __RETCAST_2(x,y) +#define __RETCAST_3(x,y,z) +#define __RETCAST_CX(x) +#define __RETCAST_REAL(x) +#define __SCHAR_MAX__ 127 +#define __SHRT_MAX__ 32767 +#define __SID ('S' << 8) +#define __SIG_ATOMIC_MAX__ 9223372036854775807L +#define __SIG_ATOMIC_WIDTH__ 64 +#define __SIZEOF_DOUBLE__ 8 +#define __SIZEOF_FLOAT__ 4 +#define __SIZEOF_INT128__ 16 +#define __SIZEOF_INT__ 4 +#define __SIZEOF_LONG_DOUBLE__ 16 +#define __SIZEOF_LONG_LONG__ 8 +#define __SIZEOF_LONG__ 8 +#define __SIZEOF_POINTER__ 8 +#define __SIZEOF_PTRDIFF_T__ 8 +#define __SIZEOF_SHORT__ 2 +#define __SIZEOF_SIZE_T__ 8 +#define __SIZEOF_WCHAR_T__ 4 +#define __SIZEOF_WINT_T__ 4 +#define __SIZE_FMTX__ "lX" +#define __SIZE_FMTo__ "lo" +#define __SIZE_FMTu__ "lu" +#define __SIZE_FMTx__ "lx" +#define __SIZE_MAX__ 18446744073709551615UL +#define __SIZE_TYPE__ long unsigned int +#define __SIZE_WIDTH__ 64 +#define __STDARG_H +#define __STDC_HOSTED__ 1 +#define __STDC_IEC_559__ 1 +#define __STDC_ISO_10646__ 201206L +#define __STDC_UTF_16__ 1 +#define __STDC_UTF_32__ 1 +#define __STDC_VERSION__ 201710L +#define __STDC__ 1 +#define __STDDEF_H +#define __UAPI_DEF_IN6_ADDR 0 +#define __UAPI_DEF_IN6_ADDR_ALT 0 +#define __UAPI_DEF_IN6_PKTINFO 0 +#define __UAPI_DEF_IN_ADDR 0 +#define __UAPI_DEF_IN_CLASS 0 +#define __UAPI_DEF_IN_IPPROTO 0 +#define __UAPI_DEF_IN_PKTINFO 0 +#define __UAPI_DEF_IP6_MTUINFO 0 +#define __UAPI_DEF_IPHDR 0 +#define __UAPI_DEF_IPPROTO_V6 0 +#define __UAPI_DEF_IPV6_MREQ 0 +#define __UAPI_DEF_IPV6_OPTIONS 0 +#define __UAPI_DEF_IP_MREQ 0 +#define __UAPI_DEF_SOCKADDR_IN 0 +#define __UAPI_DEF_SOCKADDR_IN6 0 +#define __UINT16_C_SUFFIX__ +#define __UINT16_FMTX__ "hX" +#define __UINT16_FMTo__ "ho" +#define __UINT16_FMTu__ "hu" +#define __UINT16_FMTx__ "hx" +#define __UINT16_MAX__ 65535 +#define __UINT16_TYPE__ unsigned short +#define __UINT32_C_SUFFIX__ U +#define __UINT32_FMTX__ "X" +#define __UINT32_FMTo__ "o" +#define __UINT32_FMTu__ "u" +#define __UINT32_FMTx__ "x" +#define __UINT32_MAX__ 4294967295U +#define __UINT32_TYPE__ unsigned int +#define __UINT64_C_SUFFIX__ ULL +#define __UINT64_FMTX__ "llX" +#define __UINT64_FMTo__ "llo" +#define __UINT64_FMTu__ "llu" +#define __UINT64_FMTx__ "llx" +#define __UINT64_MAX__ 18446744073709551615ULL +#define __UINT64_TYPE__ long long unsigned int +#define __UINT8_C_SUFFIX__ +#define __UINT8_FMTX__ "hhX" +#define __UINT8_FMTo__ "hho" +#define __UINT8_FMTu__ "hhu" +#define __UINT8_FMTx__ "hhx" +#define __UINT8_MAX__ 255 +#define __UINT8_TYPE__ unsigned char +#define __UINTMAX_C_SUFFIX__ ULL +#define __UINTMAX_FMTX__ "llX" +#define __UINTMAX_FMTo__ "llo" +#define __UINTMAX_FMTu__ "llu" +#define __UINTMAX_FMTx__ "llx" +#define __UINTMAX_MAX__ 18446744073709551615ULL +#define __UINTMAX_TYPE__ long long unsigned int +#define __UINTMAX_WIDTH__ 64 +#define __UINTPTR_FMTX__ "lX" +#define __UINTPTR_FMTo__ "lo" +#define __UINTPTR_FMTu__ "lu" +#define __UINTPTR_FMTx__ "lx" +#define __UINTPTR_MAX__ 18446744073709551615UL +#define __UINTPTR_TYPE__ long unsigned int +#define __UINTPTR_WIDTH__ 64 +#define __UINT_FAST16_FMTX__ "hX" +#define __UINT_FAST16_FMTo__ "ho" +#define __UINT_FAST16_FMTu__ "hu" +#define __UINT_FAST16_FMTx__ "hx" +#define __UINT_FAST16_MAX__ 65535 +#define __UINT_FAST16_TYPE__ unsigned short +#define __UINT_FAST32_FMTX__ "X" +#define __UINT_FAST32_FMTo__ "o" +#define __UINT_FAST32_FMTu__ "u" +#define __UINT_FAST32_FMTx__ "x" +#define __UINT_FAST32_MAX__ 4294967295U +#define __UINT_FAST32_TYPE__ unsigned int +#define __UINT_FAST64_FMTX__ "llX" +#define __UINT_FAST64_FMTo__ "llo" +#define __UINT_FAST64_FMTu__ "llu" +#define __UINT_FAST64_FMTx__ "llx" +#define __UINT_FAST64_MAX__ 18446744073709551615ULL +#define __UINT_FAST64_TYPE__ long long unsigned int +#define __UINT_FAST8_FMTX__ "hhX" +#define __UINT_FAST8_FMTo__ "hho" +#define __UINT_FAST8_FMTu__ "hhu" +#define __UINT_FAST8_FMTx__ "hhx" +#define __UINT_FAST8_MAX__ 255 +#define __UINT_FAST8_TYPE__ unsigned char +#define __UINT_LEAST16_FMTX__ "hX" +#define __UINT_LEAST16_FMTo__ "ho" +#define __UINT_LEAST16_FMTu__ "hu" +#define __UINT_LEAST16_FMTx__ "hx" +#define __UINT_LEAST16_MAX__ 65535 +#define __UINT_LEAST16_TYPE__ unsigned short +#define __UINT_LEAST32_FMTX__ "X" +#define __UINT_LEAST32_FMTo__ "o" +#define __UINT_LEAST32_FMTu__ "u" +#define __UINT_LEAST32_FMTx__ "x" +#define __UINT_LEAST32_MAX__ 4294967295U +#define __UINT_LEAST32_TYPE__ unsigned int +#define __UINT_LEAST64_FMTX__ "llX" +#define __UINT_LEAST64_FMTo__ "llo" +#define __UINT_LEAST64_FMTu__ "llu" +#define __UINT_LEAST64_FMTx__ "llx" +#define __UINT_LEAST64_MAX__ 18446744073709551615ULL +#define __UINT_LEAST64_TYPE__ long long unsigned int +#define __UINT_LEAST8_FMTX__ "hhX" +#define __UINT_LEAST8_FMTo__ "hho" +#define __UINT_LEAST8_FMTu__ "hhu" +#define __UINT_LEAST8_FMTx__ "hhx" +#define __UINT_LEAST8_MAX__ 255 +#define __UINT_LEAST8_TYPE__ unsigned char +#define __USER_LABEL_PREFIX__ +#define __USE_TIME_BITS64 1 +#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) +#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) +#define __WASI_ADVICE_NORMAL (UINT8_C(0)) +#define __WASI_ADVICE_RANDOM (UINT8_C(2)) +#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) +#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) +#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) +#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) +#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) +#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) +#define __WASI_DIRCOOKIE_START (UINT64_C(0)) +#define __WASI_ERRNO_2BIG (UINT16_C(1)) +#define __WASI_ERRNO_ACCES (UINT16_C(2)) +#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) +#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) +#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) +#define __WASI_ERRNO_AGAIN (UINT16_C(6)) +#define __WASI_ERRNO_ALREADY (UINT16_C(7)) +#define __WASI_ERRNO_BADF (UINT16_C(8)) +#define __WASI_ERRNO_BADMSG (UINT16_C(9)) +#define __WASI_ERRNO_BUSY (UINT16_C(10)) +#define __WASI_ERRNO_CANCELED (UINT16_C(11)) +#define __WASI_ERRNO_CHILD (UINT16_C(12)) +#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) +#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) +#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) +#define __WASI_ERRNO_DEADLK (UINT16_C(16)) +#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) +#define __WASI_ERRNO_DOM (UINT16_C(18)) +#define __WASI_ERRNO_DQUOT (UINT16_C(19)) +#define __WASI_ERRNO_EXIST (UINT16_C(20)) +#define __WASI_ERRNO_FAULT (UINT16_C(21)) +#define __WASI_ERRNO_FBIG (UINT16_C(22)) +#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) +#define __WASI_ERRNO_IDRM (UINT16_C(24)) +#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) +#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) +#define __WASI_ERRNO_INTR (UINT16_C(27)) +#define __WASI_ERRNO_INVAL (UINT16_C(28)) +#define __WASI_ERRNO_IO (UINT16_C(29)) +#define __WASI_ERRNO_ISCONN (UINT16_C(30)) +#define __WASI_ERRNO_ISDIR (UINT16_C(31)) +#define __WASI_ERRNO_LOOP (UINT16_C(32)) +#define __WASI_ERRNO_MFILE (UINT16_C(33)) +#define __WASI_ERRNO_MLINK (UINT16_C(34)) +#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) +#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) +#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) +#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) +#define __WASI_ERRNO_NETRESET (UINT16_C(39)) +#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) +#define __WASI_ERRNO_NFILE (UINT16_C(41)) +#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) +#define __WASI_ERRNO_NODEV (UINT16_C(43)) +#define __WASI_ERRNO_NOENT (UINT16_C(44)) +#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) +#define __WASI_ERRNO_NOLCK (UINT16_C(46)) +#define __WASI_ERRNO_NOLINK (UINT16_C(47)) +#define __WASI_ERRNO_NOMEM (UINT16_C(48)) +#define __WASI_ERRNO_NOMSG (UINT16_C(49)) +#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) +#define __WASI_ERRNO_NOSPC (UINT16_C(51)) +#define __WASI_ERRNO_NOSYS (UINT16_C(52)) +#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) +#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) +#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) +#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) +#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) +#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) +#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) +#define __WASI_ERRNO_NOTTY (UINT16_C(59)) +#define __WASI_ERRNO_NXIO (UINT16_C(60)) +#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) +#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) +#define __WASI_ERRNO_PERM (UINT16_C(63)) +#define __WASI_ERRNO_PIPE (UINT16_C(64)) +#define __WASI_ERRNO_PROTO (UINT16_C(65)) +#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) +#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) +#define __WASI_ERRNO_RANGE (UINT16_C(68)) +#define __WASI_ERRNO_ROFS (UINT16_C(69)) +#define __WASI_ERRNO_SPIPE (UINT16_C(70)) +#define __WASI_ERRNO_SRCH (UINT16_C(71)) +#define __WASI_ERRNO_STALE (UINT16_C(72)) +#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) +#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) +#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) +#define __WASI_ERRNO_XDEV (UINT16_C(75)) +#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) +#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) +#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) +#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) +#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) +#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) +#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) +#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) +#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) +#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) +#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) +#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) +#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) +#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) +#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) +#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) +#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) +#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) +#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) +#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) +#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) +#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) +#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) +#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) +#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) +#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) +#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) +#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) +#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) +#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) +#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) +#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) +#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) +#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) +#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) +#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) +#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) +#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) +#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) +#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) +#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) +#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) +#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) +#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) +#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) +#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) +#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) +#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) +#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) +#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) +#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) +#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) +#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) +#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) +#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) +#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) +#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) +#define __WASI_SIGNAL_ABRT (UINT8_C(6)) +#define __WASI_SIGNAL_ALRM (UINT8_C(14)) +#define __WASI_SIGNAL_BUS (UINT8_C(7)) +#define __WASI_SIGNAL_CHLD (UINT8_C(16)) +#define __WASI_SIGNAL_CONT (UINT8_C(17)) +#define __WASI_SIGNAL_FPE (UINT8_C(8)) +#define __WASI_SIGNAL_HUP (UINT8_C(1)) +#define __WASI_SIGNAL_ILL (UINT8_C(4)) +#define __WASI_SIGNAL_INT (UINT8_C(2)) +#define __WASI_SIGNAL_KILL (UINT8_C(9)) +#define __WASI_SIGNAL_NONE (UINT8_C(0)) +#define __WASI_SIGNAL_PIPE (UINT8_C(13)) +#define __WASI_SIGNAL_POLL (UINT8_C(28)) +#define __WASI_SIGNAL_PROF (UINT8_C(26)) +#define __WASI_SIGNAL_PWR (UINT8_C(29)) +#define __WASI_SIGNAL_QUIT (UINT8_C(3)) +#define __WASI_SIGNAL_SEGV (UINT8_C(11)) +#define __WASI_SIGNAL_STOP (UINT8_C(18)) +#define __WASI_SIGNAL_SYS (UINT8_C(30)) +#define __WASI_SIGNAL_TERM (UINT8_C(15)) +#define __WASI_SIGNAL_TRAP (UINT8_C(5)) +#define __WASI_SIGNAL_TSTP (UINT8_C(19)) +#define __WASI_SIGNAL_TTIN (UINT8_C(20)) +#define __WASI_SIGNAL_TTOU (UINT8_C(21)) +#define __WASI_SIGNAL_URG (UINT8_C(22)) +#define __WASI_SIGNAL_USR1 (UINT8_C(10)) +#define __WASI_SIGNAL_USR2 (UINT8_C(12)) +#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) +#define __WASI_SIGNAL_WINCH (UINT8_C(27)) +#define __WASI_SIGNAL_XCPU (UINT8_C(23)) +#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) +#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) +#define __WASI_WHENCE_CUR (UINT8_C(1)) +#define __WASI_WHENCE_END (UINT8_C(2)) +#define __WASI_WHENCE_SET (UINT8_C(0)) +#define __WCHAR_MAX__ 2147483647 +#define __WCHAR_TYPE__ int +#define __WCHAR_WIDTH__ 32 +#define __WINT_MAX__ 2147483647 +#define __WINT_TYPE__ int +#define __WINT_WIDTH__ 32 +#define __WORDSIZE 64 +#define __alignas_is_defined 1 +#define __alignof_is_defined 1 +#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) +#define __bool_true_false_are_defined 1 +#define __inline inline +#define __restrict restrict +#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) +#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) +#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) +#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) +#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) +#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) +#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) +#define __tm_gmtoff tm_gmtoff +#define __tm_zone tm_zone +#define __va_copy(d,s) __builtin_va_copy(d, s) +#define __wasi__ 1 +#define __wasi_api_h +#define __wasi_libc_environ_h +#define __wasi_libc_find_relpath_h +#define __wasi_libc_h +#define __wasi_libc_nocwd_h +#define __wasilibc___errno_h +#define __wasilibc___errno_values_h +#define __wasilibc___fd_set_h +#define __wasilibc___function___isatty_h +#define __wasilibc___functions_malloc_h +#define __wasilibc___functions_memcpy_h +#define __wasilibc___header_dirent_h +#define __wasilibc___header_fcntl_h +#define __wasilibc___header_netinet_in_h +#define __wasilibc___header_poll_h +#define __wasilibc___header_stdlib_h +#define __wasilibc___header_string_h +#define __wasilibc___header_sys_ioctl_h +#define __wasilibc___header_sys_resource_h +#define __wasilibc___header_sys_socket_h +#define __wasilibc___header_sys_stat_h +#define __wasilibc___header_time_h +#define __wasilibc___header_unistd_h +#define __wasilibc___include_inttypes_h +#define __wasilibc___macro_FD_SETSIZE_h +#define __wasilibc___macro_PAGESIZE_h +#define __wasilibc___mode_t_h +#define __wasilibc___seek_h +#define __wasilibc___struct_dirent_h +#define __wasilibc___struct_in6_addr_h +#define __wasilibc___struct_in_addr_h +#define __wasilibc___struct_iovec_h +#define __wasilibc___struct_msghdr_h +#define __wasilibc___struct_pollfd_h +#define __wasilibc___struct_rusage_h +#define __wasilibc___struct_sockaddr_h +#define __wasilibc___struct_sockaddr_in6_h +#define __wasilibc___struct_sockaddr_in_h +#define __wasilibc___struct_sockaddr_storage_h +#define __wasilibc___struct_sockaddr_un_h +#define __wasilibc___struct_stat_h +#define __wasilibc___struct_timespec_h +#define __wasilibc___struct_timeval_h +#define __wasilibc___struct_tm_h +#define __wasilibc___struct_tms_h +#define __wasilibc___typedef_DIR_h +#define __wasilibc___typedef_blkcnt_t_h +#define __wasilibc___typedef_blksize_t_h +#define __wasilibc___typedef_clock_t_h +#define __wasilibc___typedef_clockid_t_h +#define __wasilibc___typedef_dev_t_h +#define __wasilibc___typedef_fd_set_h +#define __wasilibc___typedef_gid_t_h +#define __wasilibc___typedef_in_addr_t_h +#define __wasilibc___typedef_in_port_t_h +#define __wasilibc___typedef_ino_t_h +#define __wasilibc___typedef_mode_t_h +#define __wasilibc___typedef_nfds_t_h +#define __wasilibc___typedef_nlink_t_h +#define __wasilibc___typedef_off_t_h +#define __wasilibc___typedef_sa_family_t_h +#define __wasilibc___typedef_sigset_t_h +#define __wasilibc___typedef_socklen_t_h +#define __wasilibc___typedef_ssize_t_h +#define __wasilibc___typedef_suseconds_t_h +#define __wasilibc___typedef_time_t_h +#define __wasilibc___typedef_uid_t_h +#define __wasm 1 +#define __wasm64 1 +#define __wasm64__ 1 +#define __wasm__ 1 +#define __wasm_atomics__ 1 +#define __wasm_bulk_memory__ 1 +#define _tolower(a) ((a)|0x20) +#define _toupper(a) ((a)&0x5f) +#define acos(x) __tg_real_complex(acos, (x)) +#define acosh(x) __tg_real_complex(acosh, (x)) +#define alignas _Alignas +#define alignof _Alignof +#define alloca __builtin_alloca +#define alphasort64 alphasort +#define and && +#define and_eq &= +#define asin(x) __tg_real_complex(asin, (x)) +#define asinh(x) __tg_real_complex(asinh, (x)) +#define atan(x) __tg_real_complex(atan, (x)) +#define atan2(x,y) __tg_real_2(atan2, (x), (y)) +#define atanh(x) __tg_real_complex(atanh, (x)) +#define be16toh(x) __bswap16(x) +#define be32toh(x) __bswap32(x) +#define be64toh(x) __bswap64(x) +#define betoh16(x) __bswap16(x) +#define betoh32(x) __bswap32(x) +#define betoh64(x) __bswap64(x) +#define bitand & +#define bitor | +#define blkcnt64_t blkcnt_t +#define bool _Bool +#define bswap_16(x) __bswap_16(x) +#define bswap_32(x) __bswap_32(x) +#define bswap_64(x) __bswap_64(x) +#define carg(x) __tg_complex_retreal(carg, (x)) +#define cbrt(x) __tg_real(cbrt, (x)) +#define ceil(x) __tg_real(ceil, (x)) +#define cimag(x) __tg_complex_retreal(cimag, (x)) +#define cimagf(x) (__builtin_cimagf(x)) +#define cimagl(x) (__builtin_cimagl(x)) +#define clrbit(x,i) __bitop(x,i,&=~) +#define compl ~ +#define complex _Complex +#define conj(x) __tg_complex(conj, (x)) +#define copysign(x,y) __tg_real_2(copysign, (x), (y)) +#define cos(x) __tg_real_complex(cos, (x)) +#define cosh(x) __tg_real_complex(cosh, (x)) +#define cproj(x) __tg_complex(cproj, (x)) +#define creal(x) __tg_complex_retreal(creal, (x)) +#define crealf(x) (__builtin_crealf(x)) +#define creall(x) (__builtin_creall(x)) +#define creat64 creat +#define d_fileno d_ino +#define direct dirent +#define dirent64 dirent +#define erf(x) __tg_real(erf, (x)) +#define erfc(x) __tg_real(erfc, (x)) +#define errno errno +#define exp(x) __tg_real_complex(exp, (x)) +#define exp2(x) __tg_real(exp2, (x)) +#define expm1(x) __tg_real(expm1, (x)) +#define fabs(x) __tg_real_complex_fabs(x) +#define false 0 +#define fdim(x,y) __tg_real_2(fdim, (x), (y)) +#define fgetpos64 fgetpos +#define floor(x) __tg_real(floor, (x)) +#define fma(x,y,z) __tg_real_fma((x), (y), (z)) +#define fmax(x,y) __tg_real_2(fmax, (x), (y)) +#define fmin(x,y) __tg_real_2(fmin, (x), (y)) +#define fmod(x,y) __tg_real_2(fmod, (x), (y)) +#define fopen64 fopen +#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) +#define fpos64_t fpos_t +#define freopen64 freopen +#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) +#define fsblkcnt64_t fsblkcnt_t +#define fseeko64 fseeko +#define fsetpos64 fsetpos +#define fsfilcnt64_t fsfilcnt_t +#define fstat64 fstat +#define fstatat64 fstatat +#define ftello64 ftello +#define ftruncate64 ftruncate +#define getdents64 getdents +#define glob64 glob +#define glob64_t glob_t +#define globfree64 globfree +#define howmany(n,d) (((n)+((d)-1))/(d)) +#define htobe16(x) __bswap16(x) +#define htobe32(x) __bswap32(x) +#define htobe64(x) __bswap64(x) +#define htole16(x) (uint16_t)(x) +#define htole32(x) (uint32_t)(x) +#define htole64(x) (uint64_t)(x) +#define hypot(x,y) __tg_real_2(hypot, (x), (y)) +#define icmp6_data16 icmp6_dataun.icmp6_un_data16 +#define icmp6_data32 icmp6_dataun.icmp6_un_data32 +#define icmp6_data8 icmp6_dataun.icmp6_un_data8 +#define icmp6_id icmp6_data16[0] +#define icmp6_maxdelay icmp6_data16[0] +#define icmp6_mtu icmp6_data32[0] +#define icmp6_pptr icmp6_data32[0] +#define icmp6_seq icmp6_data16[1] +#define icmp_data icmp_dun.id_data +#define icmp_gwaddr icmp_hun.ih_gwaddr +#define icmp_id icmp_hun.ih_idseq.icd_id +#define icmp_ip icmp_dun.id_ip.idi_ip +#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime +#define icmp_mask icmp_dun.id_mask +#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu +#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs +#define icmp_otime icmp_dun.id_ts.its_otime +#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void +#define icmp_pptr icmp_hun.ih_pptr +#define icmp_radv icmp_dun.id_radv +#define icmp_rtime icmp_dun.id_ts.its_rtime +#define icmp_seq icmp_hun.ih_idseq.icd_seq +#define icmp_ttime icmp_dun.id_ts.its_ttime +#define icmp_void icmp_hun.ih_void +#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa +#define ifa_broadaddr ifa_ifu.ifu_broadaddr +#define ifa_dstaddr ifa_ifu.ifu_dstaddr +#define ilogb(x) __tg_real_nocast(ilogb, (x)) +#define ino64_t ino_t +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) +#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) +#define isclr(x,i) !isset(x,i) +#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) +#define isfinite(x) (__builtin_isfinite(x)) +#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) +#define isgreater(x,y) (__builtin_isgreater(x, y)) +#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) +#define isinf(x) (__builtin_isinf(x)) +#define isless(x,y) (__builtin_isless(x, y)) +#define islessequal(x,y) (__builtin_islessequal(x, y)) +#define islessgreater(x,y) (__builtin_islessgreater(x, y)) +#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) +#define isnan(x) (__builtin_isnan(x)) +#define isnormal(x) (__builtin_isnormal(x)) +#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) +#define isset(x,i) __bitop(x,i,&) +#define isspace(a) __isspace(a) +#define isunordered(x,y) (__builtin_isunordered(x, y)) +#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) +#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) +#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) +#define le16toh(x) (uint16_t)(x) +#define le32toh(x) (uint32_t)(x) +#define le64toh(x) (uint64_t)(x) +#define letoh16(x) (uint16_t)(x) +#define letoh32(x) (uint32_t)(x) +#define letoh64(x) (uint64_t)(x) +#define lgamma(x) __tg_real(lgamma, (x)) +#define llrint(x) __tg_real_nocast(llrint, (x)) +#define llround(x) __tg_real_nocast(llround, (x)) +#define loff_t off_t +#define log(x) __tg_real_complex(log, (x)) +#define log10(x) __tg_real(log10, (x)) +#define log1p(x) __tg_real(log1p, (x)) +#define log2(x) __tg_real(log2, (x)) +#define logb(x) __tg_real(logb, (x)) +#define lrint(x) __tg_real_nocast(lrint, (x)) +#define lround(x) __tg_real_nocast(lround, (x)) +#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) +#define lseek64 lseek +#define lstat64 lstat +#define math_errhandling 2 +#define mld_cksum mld_icmp6_hdr.icmp6_cksum +#define mld_code mld_icmp6_hdr.icmp6_code +#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] +#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] +#define mld_type mld_icmp6_hdr.icmp6_type +#define nd_na_cksum nd_na_hdr.icmp6_cksum +#define nd_na_code nd_na_hdr.icmp6_code +#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] +#define nd_na_type nd_na_hdr.icmp6_type +#define nd_ns_cksum nd_ns_hdr.icmp6_cksum +#define nd_ns_code nd_ns_hdr.icmp6_code +#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] +#define nd_ns_type nd_ns_hdr.icmp6_type +#define nd_ra_cksum nd_ra_hdr.icmp6_cksum +#define nd_ra_code nd_ra_hdr.icmp6_code +#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] +#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] +#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] +#define nd_ra_type nd_ra_hdr.icmp6_type +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rs_cksum nd_rs_hdr.icmp6_cksum +#define nd_rs_code nd_rs_hdr.icmp6_code +#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] +#define nd_rs_type nd_rs_hdr.icmp6_type +#define nearbyint(x) __tg_real(nearbyint, (x)) +#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) +#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) +#define nftw64 nftw +#define no_argument 0 +#define noreturn _Noreturn +#define not ! +#define not_eq != +#define ns_msg_base(handle) ((handle)._msg + 0) +#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) +#define ns_msg_end(handle) ((handle)._eom + 0) +#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) +#define ns_msg_id(handle) ((handle)._id + 0) +#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) +#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) +#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") +#define ns_rr_rdata(rr) ((rr).rdata + 0) +#define ns_rr_rdlen(rr) ((rr).rdlength + 0) +#define ns_rr_ttl(rr) ((rr).ttl + 0) +#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) +#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) +#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) +#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) +#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) +#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) +#define off64_t off_t +#define offsetof(t,d) __builtin_offsetof(t, d) +#define open64 open +#define openat64 openat +#define optional_argument 2 +#define or || +#define or_eq |= +#define posix_fadvise64 posix_fadvise +#define posix_fallocate64 posix_fallocate +#define pow(x,y) __tg_real_complex_pow((x), (y)) +#define powerof2(n) !(((n)-1) & (n)) +#define pread64 pread +#define preadv64 preadv +#define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) +#define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); +#define pthread_equal(x,y) ((x)==(y)) +#define pwrite64 pwrite +#define pwritev64 pwritev +#define readdir64 readdir +#define remainder(x,y) __tg_real_2(remainder, (x), (y)) +#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) +#define required_argument 1 +#define rint(x) __tg_real(rint, (x)) +#define round(x) __tg_real(round, (x)) +#define roundup(n,d) (howmany(n,d)*(d)) +#define rr_cksum rr_hdr.icmp6_cksum +#define rr_code rr_hdr.icmp6_code +#define rr_seqnum rr_hdr.icmp6_data32[0] +#define rr_type rr_hdr.icmp6_type +#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) +#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) +#define scandir64 scandir +#define setbit(x,i) __bitop(x,i,|=) +#define signbit(x) (__builtin_signbit(x)) +#define sin(x) __tg_real_complex(sin, (x)) +#define sinh(x) __tg_real_complex(sinh, (x)) +#define sqrt(x) __tg_real_complex(sqrt, (x)) +#define st_atime st_atim.tv_sec +#define st_ctime st_ctim.tv_sec +#define st_mtime st_mtim.tv_sec +#define stat64 stat +#define static_assert _Static_assert +#define stderr (stderr) +#define stdin (stdin) +#define stdout (stdout) +#define strdupa(x) strcpy(alloca(strlen(x)+1),x) +#define tan(x) __tg_real_complex(tan, (x)) +#define tanh(x) __tg_real_complex(tanh, (x)) +#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) +#define tgamma(x) __tg_real(tgamma, (x)) +#define th_block th_u.tu_block +#define th_code th_u.tu_code +#define th_msg th_data +#define th_stuff th_u.tu_stuff +#define thrd_equal(A,B) ((A) == (B)) +#define thread_local _Thread_local +#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) +#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) +#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) +#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) +#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) +#define true 1 +#define trunc(x) __tg_real(trunc, (x)) +#define uh_dport dest +#define uh_sport source +#define uh_sum check +#define uh_ulen len +#define va_arg(ap,type) __builtin_va_arg(ap, type) +#define va_copy(dest,src) __builtin_va_copy(dest, src) +#define va_end(ap) __builtin_va_end(ap) +#define va_start(ap,param) __builtin_va_start(ap, param) +#define versionsort64 versionsort +#define xEOF 236 +#define xor ^ +#define xor_eq ^= diff --git a/expected/wasm64-wasi-threads/undefined-symbols.txt b/expected/wasm64-wasi-threads/undefined-symbols.txt new file mode 100644 index 000000000..f58bcd069 --- /dev/null +++ b/expected/wasm64-wasi-threads/undefined-symbols.txt @@ -0,0 +1,77 @@ +__addtf3 +__data_end +__divtf3 +__eqtf2 +__extenddftf2 +__extendsftf2 +__fixtfdi +__fixtfsi +__fixunstfsi +__floatditf +__floatsitf +__floatunsitf +__getf2 +__global_base +__gttf2 +__heap_base +__heap_end +__imported_wasi_snapshot_preview1_args_get +__imported_wasi_snapshot_preview1_args_sizes_get +__imported_wasi_snapshot_preview1_clock_res_get +__imported_wasi_snapshot_preview1_clock_time_get +__imported_wasi_snapshot_preview1_environ_get +__imported_wasi_snapshot_preview1_environ_sizes_get +__imported_wasi_snapshot_preview1_fd_advise +__imported_wasi_snapshot_preview1_fd_allocate +__imported_wasi_snapshot_preview1_fd_close +__imported_wasi_snapshot_preview1_fd_datasync +__imported_wasi_snapshot_preview1_fd_fdstat_get +__imported_wasi_snapshot_preview1_fd_fdstat_set_flags +__imported_wasi_snapshot_preview1_fd_fdstat_set_rights +__imported_wasi_snapshot_preview1_fd_filestat_get +__imported_wasi_snapshot_preview1_fd_filestat_set_size +__imported_wasi_snapshot_preview1_fd_filestat_set_times +__imported_wasi_snapshot_preview1_fd_pread +__imported_wasi_snapshot_preview1_fd_prestat_dir_name +__imported_wasi_snapshot_preview1_fd_prestat_get +__imported_wasi_snapshot_preview1_fd_pwrite +__imported_wasi_snapshot_preview1_fd_read +__imported_wasi_snapshot_preview1_fd_readdir +__imported_wasi_snapshot_preview1_fd_renumber +__imported_wasi_snapshot_preview1_fd_seek +__imported_wasi_snapshot_preview1_fd_sync +__imported_wasi_snapshot_preview1_fd_tell +__imported_wasi_snapshot_preview1_fd_write +__imported_wasi_snapshot_preview1_path_create_directory +__imported_wasi_snapshot_preview1_path_filestat_get +__imported_wasi_snapshot_preview1_path_filestat_set_times +__imported_wasi_snapshot_preview1_path_link +__imported_wasi_snapshot_preview1_path_open +__imported_wasi_snapshot_preview1_path_readlink +__imported_wasi_snapshot_preview1_path_remove_directory +__imported_wasi_snapshot_preview1_path_rename +__imported_wasi_snapshot_preview1_path_symlink +__imported_wasi_snapshot_preview1_path_unlink_file +__imported_wasi_snapshot_preview1_poll_oneoff +__imported_wasi_snapshot_preview1_proc_exit +__imported_wasi_snapshot_preview1_proc_raise +__imported_wasi_snapshot_preview1_random_get +__imported_wasi_snapshot_preview1_sched_yield +__imported_wasi_snapshot_preview1_sock_accept +__imported_wasi_snapshot_preview1_sock_recv +__imported_wasi_snapshot_preview1_sock_send +__imported_wasi_snapshot_preview1_sock_shutdown +__imported_wasi_snapshot_preview2_thread_spawn +__letf2 +__lttf2 +__netf2 +__stack_pointer +__subtf3 +__tls_align +__tls_base +__tls_size +__trunctfdf2 +__trunctfsf2 +__unordtf2 +__wasm_call_ctors +__wasm_init_tls diff --git a/expected/wasm64-wasi/defined-symbols.txt b/expected/wasm64-wasi/defined-symbols.txt new file mode 100644 index 000000000..7e3836c71 --- /dev/null +++ b/expected/wasm64-wasi/defined-symbols.txt @@ -0,0 +1,1207 @@ +_CLOCK_MONOTONIC +_CLOCK_REALTIME +_Exit +_IO_feof_unlocked +_IO_ferror_unlocked +_IO_getc +_IO_getc_unlocked +_IO_putc +_IO_putc_unlocked +__EINVAL +__ENOMEM +__SIG_ERR +__SIG_IGN +__asctime_r +__assert_fail +__c_dot_utf8 +__c_dot_utf8_locale +__c_locale +__clock +__clock_gettime +__clock_nanosleep +__cos +__cosdf +__cosl +__crypt_blowfish +__crypt_des +__crypt_md5 +__crypt_r +__crypt_sha256 +__crypt_sha512 +__ctype_b_loc +__ctype_get_mb_cur_max +__ctype_tolower_loc +__ctype_toupper_loc +__cxa_atexit +__cxa_finalize +__des_setkey +__do_des +__duplocale +__env_rm_add +__errno_location +__exp2f_data +__exp_data +__expo2 +__expo2f +__fbufsize +__fclose_ca +__fdopen +__fesetround +__fgetwc_unlocked +__flbf +__floatscan +__fmodeflags +__fopen_rb_ca +__fpending +__fpurge +__fputwc_unlocked +__freadable +__freadahead +__freading +__freadptr +__freadptrinc +__freelocale +__fseeko +__fseeko_unlocked +__fseterr +__fsetlocking +__fsmu8 +__ftello +__ftello_unlocked +__funcs_on_exit +__funcs_on_quick_exit +__futimesat +__fwritable +__fwritex +__fwriting +__get_locale +__getdelim +__getentropy +__getopt_msg +__gmtime_r +__hwcap +__inet_aton +__init_ssp +__intscan +__invtrigl_R +__isalnum_l +__isalpha_l +__isatty +__isblank_l +__iscntrl_l +__isdigit_l +__isgraph_l +__islower_l +__isoc99_fscanf +__isoc99_fwscanf +__isoc99_scanf +__isoc99_sscanf +__isoc99_swscanf +__isoc99_vfscanf +__isoc99_vfwscanf +__isoc99_vscanf +__isoc99_vsscanf +__isoc99_vswscanf +__isoc99_vwscanf +__isoc99_wscanf +__isprint_l +__ispunct_l +__isspace_l +__isupper_l +__iswalnum_l +__iswalpha_l +__iswblank_l +__iswcntrl_l +__iswctype_l +__iswdigit_l +__iswgraph_l +__iswlower_l +__iswprint_l +__iswpunct_l +__iswspace_l +__iswupper_l +__iswxdigit_l +__isxdigit_l +__lctrans +__lctrans_cur +__lctrans_impl +__ldexp_cexp +__ldexp_cexpf +__lgamma_r +__lgammaf_r +__lgammal_r +__libc +__libc_calloc +__libc_free +__libc_malloc +__loc_is_allocated +__localtime_r +__log2_data +__log2f_data +__log_data +__logf_data +__lseek +__main_void +__math_divzero +__math_divzerof +__math_invalid +__math_invalidf +__math_invalidl +__math_oflow +__math_oflowf +__math_uflow +__math_uflowf +__math_xflow +__math_xflowf +__memrchr +__mo_lookup +__month_to_secs +__newlocale +__nl_langinfo +__nl_langinfo_l +__ofl_add +__ofl_lock +__ofl_unlock +__optpos +__optreset +__overflow +__p1evll +__pio2_hi +__pio2_lo +__pleval +__polevll +__posix_getopt +__pow_log_data +__powf_log2_data +__progname +__progname_full +__putenv +__qsort_r +__rand48_step +__reallocarray +__rem_pio2 +__rem_pio2_large +__rem_pio2f +__rem_pio2l +__rsqrt_tab +__secs_to_tm +__secs_to_zone +__seed48 +__shgetc +__shlim +__signgam +__sin +__sindf +__sinl +__small_printf +__stack_chk_fail +__stack_chk_fail_local +__stack_chk_guard +__stderr_FILE +__stderr_used +__stdin_FILE +__stdin_used +__stdio_close +__stdio_exit +__stdio_exit_needed +__stdio_read +__stdio_seek +__stdio_write +__stdout_FILE +__stdout_used +__stdout_write +__stpcpy +__stpncpy +__strcasecmp_l +__strchrnul +__strcoll_l +__strerror_l +__strftime_fmt_1 +__strftime_l +__strncasecmp_l +__strtod_l +__strtof_l +__strtoimax_internal +__strtol_internal +__strtold_l +__strtoll_internal +__strtoul_internal +__strtoull_internal +__strtoumax_internal +__strxfrm_l +__sysinfo +__sysv_signal +__tan +__tandf +__tanl +__tm_to_secs +__tm_to_tzname +__tolower_l +__toread +__toread_needs_stdio_exit +__toupper_l +__towctrans_l +__towlower_l +__towrite +__towrite_needs_stdio_exit +__towupper_l +__tre_mem_alloc_impl +__tre_mem_destroy +__tre_mem_new_impl +__tsearch_balance +__uflow +__unlist_locked_file +__uselocale +__utc +__wasi_args_get +__wasi_args_sizes_get +__wasi_clock_res_get +__wasi_clock_time_get +__wasi_environ_get +__wasi_environ_sizes_get +__wasi_fd_advise +__wasi_fd_allocate +__wasi_fd_close +__wasi_fd_datasync +__wasi_fd_fdstat_get +__wasi_fd_fdstat_set_flags +__wasi_fd_fdstat_set_rights +__wasi_fd_filestat_get +__wasi_fd_filestat_set_size +__wasi_fd_filestat_set_times +__wasi_fd_pread +__wasi_fd_prestat_dir_name +__wasi_fd_prestat_get +__wasi_fd_pwrite +__wasi_fd_read +__wasi_fd_readdir +__wasi_fd_renumber +__wasi_fd_seek +__wasi_fd_sync +__wasi_fd_tell +__wasi_fd_write +__wasi_path_create_directory +__wasi_path_filestat_get +__wasi_path_filestat_set_times +__wasi_path_link +__wasi_path_open +__wasi_path_readlink +__wasi_path_remove_directory +__wasi_path_rename +__wasi_path_symlink +__wasi_path_unlink_file +__wasi_poll_oneoff +__wasi_proc_exit +__wasi_proc_raise +__wasi_random_get +__wasi_sched_yield +__wasi_sock_accept +__wasi_sock_recv +__wasi_sock_send +__wasi_sock_shutdown +__wasilibc_access +__wasilibc_cwd +__wasilibc_deinitialize_environ +__wasilibc_dttoif +__wasilibc_ensure_environ +__wasilibc_environ +__wasilibc_fd_renumber +__wasilibc_find_abspath +__wasilibc_find_relpath +__wasilibc_find_relpath_alloc +__wasilibc_get_environ +__wasilibc_iftodt +__wasilibc_initialize_environ +__wasilibc_link +__wasilibc_link_newat +__wasilibc_link_oldat +__wasilibc_maybe_reinitialize_environ_eagerly +__wasilibc_nocwd___wasilibc_rmdirat +__wasilibc_nocwd___wasilibc_unlinkat +__wasilibc_nocwd_faccessat +__wasilibc_nocwd_fstatat +__wasilibc_nocwd_linkat +__wasilibc_nocwd_mkdirat_nomode +__wasilibc_nocwd_openat_nomode +__wasilibc_nocwd_opendirat +__wasilibc_nocwd_readlinkat +__wasilibc_nocwd_renameat +__wasilibc_nocwd_scandirat +__wasilibc_nocwd_symlinkat +__wasilibc_nocwd_utimensat +__wasilibc_open_nomode +__wasilibc_populate_preopens +__wasilibc_register_preopened_fd +__wasilibc_rename_newat +__wasilibc_rename_oldat +__wasilibc_rmdirat +__wasilibc_stat +__wasilibc_tell +__wasilibc_unlinkat +__wasilibc_utimens +__wasm_call_dtors +__wcscoll_l +__wcsftime_l +__wcsxfrm_l +__wctrans_l +__wctype_l +__xpg_basename +__xpg_strerror_r +__year_to_secs +_environ +_exit +_flushlbf +_initialize +_start +a64l +abort +abs +accept +accept4 +access +acos +acosf +acosh +acoshf +acoshl +acosl +aligned_alloc +alphasort +alphasort64 +arc4random +arc4random_buf +arc4random_uniform +asctime +asctime_r +asin +asinf +asinh +asinhf +asinhl +asinl +asprintf +at_quick_exit +atan +atan2 +atan2f +atan2l +atanf +atanh +atanhf +atanhl +atanl +atexit +atof +atoi +atol +atoll +basename +bcmp +bcopy +bsd_signal +bsearch +btowc +bzero +c16rtomb +c32rtomb +cabs +cabsf +cabsl +cacos +cacosf +cacosh +cacoshf +cacoshl +cacosl +calloc +carg +cargf +cargl +casin +casinf +casinh +casinhf +casinhl +casinl +catan +catanf +catanh +catanhf +catanhl +catanl +catclose +catgets +catopen +cbrt +cbrtf +cbrtl +ccos +ccosf +ccosh +ccoshf +ccoshl +ccosl +ceil +ceilf +ceill +cexp +cexpf +cexpl +chdir +cimag +cimagf +cimagl +clearenv +clearerr +clearerr_unlocked +clock +clock_getres +clock_gettime +clock_nanosleep +clog +clogf +clogl +close +closedir +confstr +conj +conjf +conjl +copysign +copysignf +copysignl +cos +cosf +cosh +coshf +coshl +cosl +cpow +cpowf +cpowl +cproj +cprojf +cprojl +creal +crealf +creall +creat +creat64 +crypt +crypt_r +csin +csinf +csinh +csinhf +csinhl +csinl +csqrt +csqrtf +csqrtl +ctan +ctanf +ctanh +ctanhf +ctanhl +ctanl +ctime +ctime_r +difftime +dirfd +dirname +div +dprintf +drand48 +drem +dremf +duplocale +ecvt +encrypt +environ +erand48 +erf +erfc +erfcf +erfcl +erff +erfl +errno +exit +exp +exp10 +exp10f +exp10l +exp2 +exp2f +exp2l +expf +expl +explicit_bzero +expm1 +expm1f +expm1l +fabs +fabsf +fabsl +faccessat +fclose +fcntl +fcvt +fdatasync +fdclosedir +fdim +fdimf +fdiml +fdopen +fdopendir +feclearexcept +fegetenv +fegetexceptflag +fegetround +feholdexcept +feof +feof_unlocked +feraiseexcept +ferror +ferror_unlocked +fesetenv +fesetexceptflag +fesetround +fetestexcept +feupdateenv +fflush +fflush_unlocked +ffs +ffsl +ffsll +fgetc +fgetc_unlocked +fgetln +fgetpos +fgetpos64 +fgets +fgets_unlocked +fgetwc +fgetwc_unlocked +fgetws +fgetws_unlocked +fileno +fileno_unlocked +finite +finitef +floor +floorf +floorl +fma +fmaf +fmal +fmax +fmaxf +fmaxl +fmemopen +fmin +fminf +fminl +fmod +fmodf +fmodl +fmtmsg +fnmatch +fopen +fopen64 +fopencookie +fpathconf +fprintf +fpurge +fputc +fputc_unlocked +fputs +fputs_unlocked +fputwc +fputwc_unlocked +fputws +fputws_unlocked +fread +fread_unlocked +free +freelocale +freopen +freopen64 +frexp +frexpf +frexpl +fscanf +fseek +fseeko +fseeko64 +fsetpos +fsetpos64 +fstat +fstatat +fsync +ftell +ftello +ftello64 +ftime +ftruncate +futimens +futimesat +fwide +fwprintf +fwrite +fwrite_unlocked +fwscanf +gcvt +get_avphys_pages +get_nprocs +get_nprocs_conf +get_phys_pages +getc +getc_unlocked +getchar +getchar_unlocked +getcwd +getdate +getdate_err +getdelim +getdomainname +getentropy +getenv +gethostid +getline +getopt +getopt_long +getopt_long_only +getpagesize +getpid +getrusage +getsockopt +getsubopt +gettimeofday +getw +getwc +getwc_unlocked +getwchar +getwchar_unlocked +glob +glob64 +globfree +globfree64 +gmtime +gmtime_r +hcreate +hcreate_r +hdestroy +hdestroy_r +hsearch +hsearch_r +htonl +htons +hypot +hypotf +hypotl +iconv +iconv_close +iconv_open +ilogb +ilogbf +ilogbl +imaxabs +imaxdiv +in6addr_any +in6addr_loopback +index +inet_aton +inet_ntop +inet_pton +initstate +insque +ioctl +iprintf +isalnum +isalnum_l +isalpha +isalpha_l +isascii +isatty +isblank +isblank_l +iscntrl +iscntrl_l +isdigit +isdigit_l +isgraph +isgraph_l +islower +islower_l +isprint +isprint_l +ispunct +ispunct_l +isspace +isspace_l +isupper +isupper_l +iswalnum +iswalnum_l +iswalpha +iswalpha_l +iswblank +iswblank_l +iswcntrl +iswcntrl_l +iswctype +iswctype_l +iswdigit +iswdigit_l +iswgraph +iswgraph_l +iswlower +iswlower_l +iswprint +iswprint_l +iswpunct +iswpunct_l +iswspace +iswspace_l +iswupper +iswupper_l +iswxdigit +iswxdigit_l +isxdigit +isxdigit_l +j0 +j0f +j1 +j1f +jn +jnf +jrand48 +l64a +labs +lcong48 +ldexp +ldexpf +ldexpl +ldiv +lfind +lgamma +lgamma_r +lgammaf +lgammaf_r +lgammal +lgammal_r +link +linkat +llabs +lldiv +llrint +llrintf +llrintl +llround +llroundf +llroundl +localeconv +localtime +localtime_r +log +log10 +log10f +log10l +log1p +log1pf +log1pl +log2 +log2f +log2l +logb +logbf +logbl +logf +logl +lrand48 +lrint +lrintf +lrintl +lround +lroundf +lroundl +lsearch +lseek +lstat +malloc +malloc_usable_size +mblen +mbrlen +mbrtoc16 +mbrtoc32 +mbrtowc +mbsinit +mbsnrtowcs +mbsrtowcs +mbstowcs +mbtowc +memccpy +memchr +memcmp +memcpy +memmem +memmove +mempcpy +memrchr +memset +mkdir +mkdirat +mktime +mmap +modf +modff +modfl +mrand48 +munmap +nan +nanf +nanl +nanosleep +nearbyint +nearbyintf +nearbyintl +newlocale +nextafter +nextafterf +nextafterl +nexttoward +nexttowardf +nexttowardl +nftw +nftw64 +nl_langinfo +nl_langinfo_l +nrand48 +ntohl +ntohs +open +open_memstream +open_wmemstream +openat +opendir +opendirat +optarg +opterr +optind +optopt +optreset +pathconf +perror +poll +posix_close +posix_fadvise +posix_fallocate +posix_memalign +pow +pow10 +pow10f +pow10l +powf +powl +pread +preadv +printf +program_invocation_name +program_invocation_short_name +pselect +psignal +putc +putc_unlocked +putchar +putchar_unlocked +putenv +puts +putw +putwc +putwc_unlocked +putwchar +putwchar_unlocked +pwrite +pwritev +qsort +qsort_r +quick_exit +raise +rand +rand_r +random +read +readdir +readlink +readlinkat +readv +realloc +reallocarray +recv +regcomp +regerror +regexec +regfree +remainder +remainderf +remainderl +remove +remque +remquo +remquof +remquol +rename +renameat +rewind +rewinddir +rindex +rint +rintf +rintl +rmdir +round +roundf +roundl +sbrk +scalb +scalbf +scalbln +scalblnf +scalblnl +scalbn +scalbnf +scalbnl +scandir +scandirat +scanf +sched_yield +seed48 +seekdir +select +send +setbuf +setbuffer +setenv +setkey +setlinebuf +setlocale +setstate +setvbuf +shutdown +signal +signgam +significand +significandf +sin +sincos +sincosf +sincosl +sinf +sinh +sinhf +sinhl +sinl +sleep +snprintf +sprintf +sqrt +sqrtf +sqrtl +srand +srand48 +srandom +sscanf +stat +stderr +stdin +stdout +stpcpy +stpncpy +strcasecmp +strcasecmp_l +strcasestr +strcat +strchr +strchrnul +strcmp +strcoll +strcoll_l +strcpy +strcspn +strdup +strerror +strerror_l +strerror_r +strfmon +strfmon_l +strftime +strftime_l +strlcat +strlcpy +strlen +strncasecmp +strncasecmp_l +strncat +strncmp +strncpy +strndup +strnlen +strpbrk +strptime +strrchr +strsep +strsignal +strspn +strstr +strtod +strtod_l +strtof +strtof_l +strtoimax +strtok +strtok_r +strtol +strtold +strtold_l +strtoll +strtoul +strtoull +strtoumax +strverscmp +strxfrm +strxfrm_l +swab +swprintf +swscanf +symlink +symlinkat +sysconf +tan +tanf +tanh +tanhf +tanhl +tanl +tdelete +tdestroy +telldir +tfind +tgamma +tgammaf +tgammal +thrd_sleep +time +timegm +times +timespec_get +toascii +tolower +tolower_l +toupper +toupper_l +towctrans +towctrans_l +towlower +towlower_l +towupper +towupper_l +trunc +truncate +truncf +truncl +tsearch +twalk +uname +ungetc +ungetwc +unlink +unlinkat +unsetenv +uselocale +usleep +utime +utimensat +utimes +vasprintf +vdprintf +versionsort +versionsort64 +vfprintf +vfscanf +vfwprintf +vfwscanf +vprintf +vscanf +vsnprintf +vsprintf +vsscanf +vswprintf +vswscanf +vwprintf +vwscanf +wcpcpy +wcpncpy +wcrtomb +wcscasecmp +wcscasecmp_l +wcscat +wcschr +wcscmp +wcscoll +wcscoll_l +wcscpy +wcscspn +wcsdup +wcsftime +wcsftime_l +wcslen +wcsncasecmp +wcsncasecmp_l +wcsncat +wcsncmp +wcsncpy +wcsnlen +wcsnrtombs +wcspbrk +wcsrchr +wcsrtombs +wcsspn +wcsstr +wcstod +wcstof +wcstoimax +wcstok +wcstol +wcstold +wcstoll +wcstombs +wcstoul +wcstoull +wcstoumax +wcswcs +wcswidth +wcsxfrm +wcsxfrm_l +wctob +wctomb +wctrans +wctrans_l +wctype +wctype_l +wcwidth +wmemchr +wmemcmp +wmemcpy +wmemmove +wmemset +wprintf +write +writev +wscanf +y0 +y0f +y1 +y1f +yn +ynf diff --git a/expected/wasm64-wasi/include-all.c b/expected/wasm64-wasi/include-all.c new file mode 100644 index 000000000..86297f3ef --- /dev/null +++ b/expected/wasm64-wasi/include-all.c @@ -0,0 +1,170 @@ +#include <__errno.h> +#include <__errno_values.h> +#include <__fd_set.h> +#include <__function___isatty.h> +#include <__functions_malloc.h> +#include <__functions_memcpy.h> +#include <__header_dirent.h> +#include <__header_fcntl.h> +#include <__header_inttypes.h> +#include <__header_netinet_in.h> +#include <__header_poll.h> +#include <__header_stdlib.h> +#include <__header_string.h> +#include <__header_sys_ioctl.h> +#include <__header_sys_resource.h> +#include <__header_sys_socket.h> +#include <__header_sys_stat.h> +#include <__header_time.h> +#include <__header_unistd.h> +#include <__macro_FD_SETSIZE.h> +#include <__macro_PAGESIZE.h> +#include <__mode_t.h> +#include <__seek.h> +#include <__struct_dirent.h> +#include <__struct_in6_addr.h> +#include <__struct_in_addr.h> +#include <__struct_iovec.h> +#include <__struct_msghdr.h> +#include <__struct_pollfd.h> +#include <__struct_rusage.h> +#include <__struct_sockaddr.h> +#include <__struct_sockaddr_in.h> +#include <__struct_sockaddr_in6.h> +#include <__struct_sockaddr_storage.h> +#include <__struct_sockaddr_un.h> +#include <__struct_stat.h> +#include <__struct_timespec.h> +#include <__struct_timeval.h> +#include <__struct_tm.h> +#include <__struct_tms.h> +#include <__typedef_DIR.h> +#include <__typedef_blkcnt_t.h> +#include <__typedef_blksize_t.h> +#include <__typedef_clock_t.h> +#include <__typedef_clockid_t.h> +#include <__typedef_dev_t.h> +#include <__typedef_fd_set.h> +#include <__typedef_gid_t.h> +#include <__typedef_in_addr_t.h> +#include <__typedef_in_port_t.h> +#include <__typedef_ino_t.h> +#include <__typedef_mode_t.h> +#include <__typedef_nfds_t.h> +#include <__typedef_nlink_t.h> +#include <__typedef_off_t.h> +#include <__typedef_sa_family_t.h> +#include <__typedef_sigset_t.h> +#include <__typedef_socklen_t.h> +#include <__typedef_ssize_t.h> +#include <__typedef_suseconds_t.h> +#include <__typedef_time_t.h> +#include <__typedef_uid_t.h> +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt new file mode 100644 index 000000000..a94cfd2ee --- /dev/null +++ b/expected/wasm64-wasi/predefined-macros.txt @@ -0,0 +1,3386 @@ +#define ABDAY_1 0x20000 +#define ABDAY_2 0x20001 +#define ABDAY_3 0x20002 +#define ABDAY_4 0x20003 +#define ABDAY_5 0x20004 +#define ABDAY_6 0x20005 +#define ABDAY_7 0x20006 +#define ABMON_1 0x2000E +#define ABMON_10 0x20017 +#define ABMON_11 0x20018 +#define ABMON_12 0x20019 +#define ABMON_2 0x2000F +#define ABMON_3 0x20010 +#define ABMON_4 0x20011 +#define ABMON_5 0x20012 +#define ABMON_6 0x20013 +#define ABMON_7 0x20014 +#define ABMON_8 0x20015 +#define ABMON_9 0x20016 +#define ABORT 238 +#define ACK 04 +#define ADD ns_uop_add +#define ADJ_ESTERROR 0x0008 +#define ADJ_FREQUENCY 0x0002 +#define ADJ_MAXERROR 0x0004 +#define ADJ_MICRO 0x1000 +#define ADJ_NANO 0x2000 +#define ADJ_OFFSET 0x0001 +#define ADJ_OFFSET_SINGLESHOT 0x8001 +#define ADJ_OFFSET_SS_READ 0xa001 +#define ADJ_SETOFFSET 0x0100 +#define ADJ_STATUS 0x0010 +#define ADJ_TAI 0x0080 +#define ADJ_TICK 0x4000 +#define ADJ_TIMECONST 0x0020 +#define AF_INET PF_INET +#define AF_INET6 PF_INET6 +#define AF_UNIX 3 +#define AF_UNSPEC PF_UNSPEC +#define ALT_DIGITS 0x2002F +#define AM_STR 0x20026 +#define ANYMARK 0x01 +#define AO 245 +#define AREGTYPE '\0' +#define ARFMAG "`\n" +#define ARG_MAX 131072 +#define ARMAG "!\n" +#define AT_EACCESS (0x0) +#define AT_FDCWD (-2) +#define AT_REMOVEDIR (0x4) +#define AT_SYMLINK_FOLLOW (0x2) +#define AT_SYMLINK_NOFOLLOW (0x1) +#define AUTHTYPE_CNT 5 +#define AUTHTYPE_KERBEROS_V4 1 +#define AUTHTYPE_KERBEROS_V5 2 +#define AUTHTYPE_MINK 4 +#define AUTHTYPE_NAME(x) authtype_names[x] +#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) +#define AUTHTYPE_NULL 0 +#define AUTHTYPE_SPX 3 +#define AUTHTYPE_TEST 99 +#define AUTH_HOW_MASK 2 +#define AUTH_HOW_MUTUAL 2 +#define AUTH_HOW_ONE_WAY 0 +#define AUTH_WHO_CLIENT 0 +#define AUTH_WHO_MASK 1 +#define AUTH_WHO_SERVER 1 +#define AYT 246 +#define BIG_ENDIAN __BIG_ENDIAN +#define BITSPERBYTE CHAR_BIT +#define BLKTYPE '4' +#define BLK_BYTECOUNT 2 +#define BLK_EOF 0x40 +#define BLK_EOR 0x80 +#define BLK_ERRORS 0x20 +#define BLK_RESTART 0x10 +#define BREAK 243 +#define BUFSIZ 1024 +#define BYTE_ORDER __BYTE_ORDER +#define CANBSIZ 255 +#define CBRK CEOL +#define CDISCARD CTRL('o') +#define CDSUSP CTRL('y') +#define CEOF CTRL('d') +#define CEOL '\0' +#define CEOT CEOF +#define CERASE 0177 +#define CFLUSH CDISCARD +#define CHARBITS (sizeof(char) * 8) +#define CHARCLASS_NAME_MAX 14 +#define CHAR_BIT 8 +#define CHAR_MAX 127 +#define CHAR_MIN (-128) +#define CHRTYPE '3' +#define CINTR CTRL('c') +#define CKILL CTRL('u') +#define CLNEXT CTRL('v') +#define CLOCKS_PER_SEC ((clock_t)1000000000) +#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) +#define CLOCK_REALTIME (&_CLOCK_REALTIME) +#define CMIN 1 +#define CMPLX(x,y) __CMPLX(x, y, double) +#define CMPLXF(x,y) __CMPLX(x, y, float) +#define CMPLXL(x,y) __CMPLX(x, y, long double) +#define CODESET 14 +#define COLL_WEIGHTS_MAX 2 +#define COMPLETE 2 +#define CONTINUE 3 +#define CONTTYPE '7' +#define CQUIT 034 +#define CREPRINT CTRL('r') +#define CRNCYSTR 0x4000F +#define CRPRNT CREPRINT +#define CSTART CTRL('q') +#define CSTATUS '\0' +#define CSTOP CTRL('s') +#define CSUSP CTRL('z') +#define CTIME 0 +#define CTRL(x) ((x)&037) +#define CWERASE CTRL('w') +#define C_ANY ns_c_any +#define C_CHAOS ns_c_chaos +#define C_HS ns_c_hs +#define C_IN ns_c_in +#define C_IRGRP 000040 +#define C_IROTH 000004 +#define C_IRUSR 000400 +#define C_ISBLK 060000 +#define C_ISCHR 020000 +#define C_ISCTG 0110000 +#define C_ISDIR 040000 +#define C_ISFIFO 010000 +#define C_ISGID 002000 +#define C_ISLNK 0120000 +#define C_ISREG 0100000 +#define C_ISSOCK 0140000 +#define C_ISUID 004000 +#define C_ISVTX 001000 +#define C_IWGRP 000020 +#define C_IWOTH 000002 +#define C_IWUSR 000200 +#define C_IXGRP 000010 +#define C_IXOTH 000001 +#define C_IXUSR 000100 +#define C_NONE ns_c_none +#define DATA 03 +#define DAY_1 0x20007 +#define DAY_2 0x20008 +#define DAY_3 0x20009 +#define DAY_4 0x2000A +#define DAY_5 0x2000B +#define DAY_6 0x2000C +#define DAY_7 0x2000D +#define DBL_DECIMAL_DIG 17 +#define DBL_DIG 15 +#define DBL_EPSILON 2.22044604925031308085e-16 +#define DBL_HAS_SUBNORM 1 +#define DBL_MANT_DIG 53 +#define DBL_MAX 1.79769313486231570815e+308 +#define DBL_MAX_10_EXP 308 +#define DBL_MAX_EXP 1024 +#define DBL_MIN 2.22507385850720138309e-308 +#define DBL_MIN_10_EXP (-307) +#define DBL_MIN_EXP (-1021) +#define DBL_TRUE_MIN 4.94065645841246544177e-324 +#define DECIMAL_DIG 36 +#define DELAYTIMER_MAX 0x7fffffff +#define DELETE ns_uop_delete +#define DEV_BSIZE 512 +#define DIRTYPE '5' +#define DM 242 +#define DMAXEXP DBL_MAX_EXP +#define DMINEXP DBL_MIN_EXP +#define DO 253 +#define DONT 254 +#define DOUBLEBITS (sizeof(double) * 8) +#define DTTOIF(x) (__wasilibc_dttoif(x)) +#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE +#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE +#define DT_DIR __WASI_FILETYPE_DIRECTORY +#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM +#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK +#define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN +#define D_FMT 0x20029 +#define D_T_FMT 0x20028 +#define E2BIG __WASI_ERRNO_2BIG +#define EACCES __WASI_ERRNO_ACCES +#define EACCESS 2 +#define EADDRINUSE __WASI_ERRNO_ADDRINUSE +#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL +#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT +#define EAGAIN __WASI_ERRNO_AGAIN +#define EALREADY __WASI_ERRNO_ALREADY +#define EBADF __WASI_ERRNO_BADF +#define EBADID 5 +#define EBADMSG __WASI_ERRNO_BADMSG +#define EBADOP 4 +#define EBUSY __WASI_ERRNO_BUSY +#define EC 247 +#define ECANCELED __WASI_ERRNO_CANCELED +#define ECHILD __WASI_ERRNO_CHILD +#define ECONNABORTED __WASI_ERRNO_CONNABORTED +#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED +#define ECONNRESET __WASI_ERRNO_CONNRESET +#define EDEADLK __WASI_ERRNO_DEADLK +#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ +#define EDOM __WASI_ERRNO_DOM +#define EDQUOT __WASI_ERRNO_DQUOT +#define EEXIST __WASI_ERRNO_EXIST +#define EEXISTS 6 +#define EFAULT __WASI_ERRNO_FAULT +#define EFBIG __WASI_ERRNO_FBIG +#define EFD_CLOEXEC O_CLOEXEC +#define EFD_NONBLOCK O_NONBLOCK +#define EFD_SEMAPHORE 1 +#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH +#define EIDRM __WASI_ERRNO_IDRM +#define EILSEQ __WASI_ERRNO_ILSEQ +#define EINPROGRESS __WASI_ERRNO_INPROGRESS +#define EINTR __WASI_ERRNO_INTR +#define EINVAL __WASI_ERRNO_INVAL +#define EIO __WASI_ERRNO_IO +#define EISCONN __WASI_ERRNO_ISCONN +#define EISDIR __WASI_ERRNO_ISDIR +#define EL 248 +#define ELOOP __WASI_ERRNO_LOOP +#define EMFILE __WASI_ERRNO_MFILE +#define EMLINK __WASI_ERRNO_MLINK +#define EMSGSIZE __WASI_ERRNO_MSGSIZE +#define EMULTIHOP __WASI_ERRNO_MULTIHOP +#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG +#define ENCRYPT_CNT 9 +#define ENCRYPT_DEC_KEYID 8 +#define ENCRYPT_ENC_KEYID 7 +#define ENCRYPT_END 4 +#define ENCRYPT_IS 0 +#define ENCRYPT_NAME(x) encrypt_names[x] +#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) +#define ENCRYPT_REPLY 2 +#define ENCRYPT_REQEND 6 +#define ENCRYPT_REQSTART 5 +#define ENCRYPT_START 3 +#define ENCRYPT_SUPPORT 1 +#define ENCTYPE_ANY 0 +#define ENCTYPE_CNT 3 +#define ENCTYPE_DES_CFB64 1 +#define ENCTYPE_DES_OFB64 2 +#define ENCTYPE_NAME(x) enctype_names[x] +#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) +#define ENETDOWN __WASI_ERRNO_NETDOWN +#define ENETRESET __WASI_ERRNO_NETRESET +#define ENETUNREACH __WASI_ERRNO_NETUNREACH +#define ENFILE __WASI_ERRNO_NFILE +#define ENOBUFS __WASI_ERRNO_NOBUFS +#define ENODEV __WASI_ERRNO_NODEV +#define ENOENT __WASI_ERRNO_NOENT +#define ENOEXEC __WASI_ERRNO_NOEXEC +#define ENOLCK __WASI_ERRNO_NOLCK +#define ENOLINK __WASI_ERRNO_NOLINK +#define ENOMEM __WASI_ERRNO_NOMEM +#define ENOMSG __WASI_ERRNO_NOMSG +#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT +#define ENOSPACE 3 +#define ENOSPC __WASI_ERRNO_NOSPC +#define ENOSYS __WASI_ERRNO_NOSYS +#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE +#define ENOTCONN __WASI_ERRNO_NOTCONN +#define ENOTDIR __WASI_ERRNO_NOTDIR +#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY +#define ENOTFOUND 1 +#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE +#define ENOTSOCK __WASI_ERRNO_NOTSOCK +#define ENOTSUP __WASI_ERRNO_NOTSUP +#define ENOTTY __WASI_ERRNO_NOTTY +#define ENOUSER 7 +#define ENV_ESC 2 +#define ENV_USERVAR 3 +#define ENXIO __WASI_ERRNO_NXIO +#define EOF (-1) +#define EOPNOTSUPP ENOTSUP +#define EOR 239 +#define EOVERFLOW __WASI_ERRNO_OVERFLOW +#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD +#define EPERM __WASI_ERRNO_PERM +#define EPIPE __WASI_ERRNO_PIPE +#define EPROTO __WASI_ERRNO_PROTO +#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT +#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE +#define ERA 0x2002C +#define ERANGE __WASI_ERRNO_RANGE +#define ERA_D_FMT 0x2002E +#define ERA_D_T_FMT 0x20030 +#define ERA_T_FMT 0x20031 +#define EROFS __WASI_ERRNO_ROFS +#define ERROR 05 +#define ESPIPE __WASI_ERRNO_SPIPE +#define ESRCH __WASI_ERRNO_SRCH +#define ESTALE __WASI_ERRNO_STALE +#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT +#define ETXTBSY __WASI_ERRNO_TXTBSY +#define EUNDEF 0 +#define EWOULDBLOCK EAGAIN +#define EXDEV __WASI_ERRNO_XDEV +#define EXIT_FAILURE 1 +#define EXIT_SUCCESS 0 +#define EX_CANTCREAT 73 +#define EX_CONFIG 78 +#define EX_DATAERR 65 +#define EX_IOERR 74 +#define EX_NOHOST 68 +#define EX_NOINPUT 66 +#define EX_NOPERM 77 +#define EX_NOUSER 67 +#define EX_OK 0 +#define EX_OSERR 71 +#define EX_OSFILE 72 +#define EX_PROTOCOL 76 +#define EX_SOFTWARE 70 +#define EX_TEMPFAIL 75 +#define EX_UNAVAILABLE 69 +#define EX_USAGE 64 +#define EX__BASE 64 +#define EX__MAX 78 +#define FD_CLOEXEC (1) +#define FD_CLR(fd,set) (FD_CLR((fd), (set))) +#define FD_COPY(from,to) (FD_COPY((from), (to))) +#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) +#define FD_SET(fd,set) (FD_SET((fd), (set))) +#define FD_SETSIZE 1024 +#define FD_ZERO(set) (FD_ZERO((set))) +#define FE_ALL_EXCEPT 0 +#define FE_DFL_ENV ((const fenv_t *) -1) +#define FE_TONEAREST 0 +#define FIFOTYPE '6' +#define FILENAME_MAX 4096 +#define FILESIZEBITS 64 +#define FIONBIO 2 +#define FIONREAD 1 +#define FLOATBITS (sizeof(float) * 8) +#define FLT_DECIMAL_DIG 9 +#define FLT_DIG 6 +#define FLT_EPSILON 1.1920928955078125e-07F +#define FLT_EVAL_METHOD 0 +#define FLT_HAS_SUBNORM 1 +#define FLT_MANT_DIG 24 +#define FLT_MAX 3.40282346638528859812e+38F +#define FLT_MAX_10_EXP 38 +#define FLT_MAX_EXP 128 +#define FLT_MIN 1.17549435082228750797e-38F +#define FLT_MIN_10_EXP (-37) +#define FLT_MIN_EXP (-125) +#define FLT_RADIX 2 +#define FLT_ROUNDS (__builtin_flt_rounds()) +#define FLT_TRUE_MIN 1.40129846432481707092e-45F +#define FLUSHBAND 0x04 +#define FLUSHR 0x01 +#define FLUSHRW 0x03 +#define FLUSHW 0x02 +#define FMAXEXP FLT_MAX_EXP +#define FMINEXP FLT_MIN_EXP +#define FMNAMESZ 8 +#define FNM_CASEFOLD 0x10 +#define FNM_FILE_NAME FNM_PATHNAME +#define FNM_LEADING_DIR 0x8 +#define FNM_NOESCAPE 0x2 +#define FNM_NOMATCH 1 +#define FNM_NOSYS (-1) +#define FNM_PATHNAME 0x1 +#define FNM_PERIOD 0x4 +#define FOPEN_MAX 1000 +#define FORMERR ns_r_formerr +#define FORM_C 3 +#define FORM_N 1 +#define FORM_T 2 +#define FP_ILOGB0 FP_ILOGBNAN +#define FP_ILOGBNAN (-1-0x7fffffff) +#define FP_INFINITE 1 +#define FP_NAN 0 +#define FP_NORMAL 4 +#define FP_SUBNORMAL 3 +#define FP_ZERO 2 +#define FSETLOCKING_BYCALLER 2 +#define FSETLOCKING_INTERNAL 1 +#define FSETLOCKING_QUERY 0 +#define FTW_CHDIR 4 +#define FTW_D 2 +#define FTW_DEPTH 8 +#define FTW_DNR 3 +#define FTW_DP 6 +#define FTW_F 1 +#define FTW_MOUNT 2 +#define FTW_NS 4 +#define FTW_PHYS 1 +#define FTW_SL 5 +#define FTW_SLN 7 +#define F_GETFD (1) +#define F_GETFL (3) +#define F_LOCK 1 +#define F_OK (0) +#define F_SETFD (2) +#define F_SETFL (4) +#define F_TEST 3 +#define F_TLOCK 2 +#define F_ULOCK 0 +#define GA 249 +#define GETLONG NS_GET32 +#define GETSHORT NS_GET16 +#define GLOB_ABORTED 2 +#define GLOB_APPEND 0x20 +#define GLOB_DOOFFS 0x08 +#define GLOB_ERR 0x01 +#define GLOB_MARK 0x02 +#define GLOB_NOCHECK 0x10 +#define GLOB_NOESCAPE 0x40 +#define GLOB_NOMATCH 3 +#define GLOB_NOSORT 0x04 +#define GLOB_NOSPACE 1 +#define GLOB_NOSYS 4 +#define GLOB_PERIOD 0x80 +#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) +#define HFIXEDSZ NS_HFIXEDSZ +#define HIBITL MINLONG +#define HIBITS MINSHORT +#define HOST_NAME_MAX 255 +#define HUGE 3.40282346638528859812e+38F +#define HUGE_VAL ((double)INFINITY) +#define HUGE_VALF INFINITY +#define HUGE_VALL ((long double)INFINITY) +#define I _Complex_I +#define IAC 255 +#define ICMP6_DST_UNREACH 1 +#define ICMP6_DST_UNREACH_ADDR 3 +#define ICMP6_DST_UNREACH_ADMIN 1 +#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 +#define ICMP6_DST_UNREACH_NOPORT 4 +#define ICMP6_DST_UNREACH_NOROUTE 0 +#define ICMP6_ECHO_REPLY 129 +#define ICMP6_ECHO_REQUEST 128 +#define ICMP6_FILTER 1 +#define ICMP6_FILTER_BLOCK 1 +#define ICMP6_FILTER_BLOCKOTHERS 3 +#define ICMP6_FILTER_PASS 2 +#define ICMP6_FILTER_PASSONLY 4 +#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) +#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) +#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) +#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) +#define ICMP6_INFOMSG_MASK 0x80 +#define ICMP6_PACKET_TOO_BIG 2 +#define ICMP6_PARAMPROB_HEADER 0 +#define ICMP6_PARAMPROB_NEXTHEADER 1 +#define ICMP6_PARAMPROB_OPTION 2 +#define ICMP6_PARAM_PROB 4 +#define ICMP6_ROUTER_RENUMBERING 138 +#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 +#define ICMP6_RR_FLAGS_PREVDONE 0x08 +#define ICMP6_RR_FLAGS_REQRESULT 0x40 +#define ICMP6_RR_FLAGS_SPECSITE 0x10 +#define ICMP6_RR_FLAGS_TEST 0x80 +#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 +#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 +#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 +#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 +#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 +#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 +#define ICMP6_TIME_EXCEEDED 3 +#define ICMP6_TIME_EXCEED_REASSEMBLY 1 +#define ICMP6_TIME_EXCEED_TRANSIT 0 +#define ICMP_ADDRESS 17 +#define ICMP_ADDRESSREPLY 18 +#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) +#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) +#define ICMP_DEST_UNREACH 3 +#define ICMP_ECHO 8 +#define ICMP_ECHOREPLY 0 +#define ICMP_EXC_FRAGTIME 1 +#define ICMP_EXC_TTL 0 +#define ICMP_FRAG_NEEDED 4 +#define ICMP_HOST_ANO 10 +#define ICMP_HOST_ISOLATED 8 +#define ICMP_HOST_UNKNOWN 7 +#define ICMP_HOST_UNREACH 1 +#define ICMP_HOST_UNR_TOS 12 +#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) +#define ICMP_INFO_REPLY 16 +#define ICMP_INFO_REQUEST 15 +#define ICMP_IREQ 15 +#define ICMP_IREQREPLY 16 +#define ICMP_MASKLEN 12 +#define ICMP_MASKREPLY 18 +#define ICMP_MASKREQ 17 +#define ICMP_MAXTYPE 18 +#define ICMP_MINLEN 8 +#define ICMP_NET_ANO 9 +#define ICMP_NET_UNKNOWN 6 +#define ICMP_NET_UNREACH 0 +#define ICMP_NET_UNR_TOS 11 +#define ICMP_PARAMETERPROB 12 +#define ICMP_PARAMPROB 12 +#define ICMP_PARAMPROB_OPTABSENT 1 +#define ICMP_PKT_FILTERED 13 +#define ICMP_PORT_UNREACH 3 +#define ICMP_PREC_CUTOFF 15 +#define ICMP_PREC_VIOLATION 14 +#define ICMP_PROT_UNREACH 2 +#define ICMP_REDIRECT 5 +#define ICMP_REDIRECT_HOST 1 +#define ICMP_REDIRECT_NET 0 +#define ICMP_REDIRECT_TOSHOST 3 +#define ICMP_REDIRECT_TOSNET 2 +#define ICMP_REDIR_HOST 1 +#define ICMP_REDIR_HOSTTOS 3 +#define ICMP_REDIR_NET 0 +#define ICMP_REDIR_NETTOS 2 +#define ICMP_ROUTERADVERT 9 +#define ICMP_ROUTERSOLICIT 10 +#define ICMP_SOURCEQUENCH 4 +#define ICMP_SOURCE_QUENCH 4 +#define ICMP_SR_FAILED 5 +#define ICMP_TIMESTAMP 13 +#define ICMP_TIMESTAMPREPLY 14 +#define ICMP_TIME_EXCEEDED 11 +#define ICMP_TIMXCEED 11 +#define ICMP_TIMXCEED_INTRANS 0 +#define ICMP_TIMXCEED_REASS 1 +#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) +#define ICMP_TSTAMP 13 +#define ICMP_TSTAMPREPLY 14 +#define ICMP_UNREACH 3 +#define ICMP_UNREACH_FILTER_PROHIB 13 +#define ICMP_UNREACH_HOST 1 +#define ICMP_UNREACH_HOST_PRECEDENCE 14 +#define ICMP_UNREACH_HOST_PROHIB 10 +#define ICMP_UNREACH_HOST_UNKNOWN 7 +#define ICMP_UNREACH_ISOLATED 8 +#define ICMP_UNREACH_NEEDFRAG 4 +#define ICMP_UNREACH_NET 0 +#define ICMP_UNREACH_NET_PROHIB 9 +#define ICMP_UNREACH_NET_UNKNOWN 6 +#define ICMP_UNREACH_PORT 3 +#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 +#define ICMP_UNREACH_PROTOCOL 2 +#define ICMP_UNREACH_SRCFAIL 5 +#define ICMP_UNREACH_TOSHOST 12 +#define ICMP_UNREACH_TOSNET 11 +#define IFTODT(x) (__wasilibc_iftodt(x)) +#define IGMP_AWAKENING_MEMBER 5 +#define IGMP_DELAYING_MEMBER 1 +#define IGMP_DVMRP 0x13 +#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP +#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY +#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT +#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT +#define IGMP_IDLE_MEMBER 2 +#define IGMP_LAZY_MEMBER 3 +#define IGMP_MAX_HOST_REPORT_DELAY 10 +#define IGMP_MEMBERSHIP_QUERY 0x11 +#define IGMP_MINLEN 8 +#define IGMP_MTRACE 0x1f +#define IGMP_MTRACE_RESP 0x1e +#define IGMP_PIM 0x14 +#define IGMP_SLEEPING_MEMBER 4 +#define IGMP_TIMER_SCALE 10 +#define IGMP_TRACE 0x15 +#define IGMP_V1_MEMBERSHIP_REPORT 0x12 +#define IGMP_V2_LEAVE_GROUP 0x17 +#define IGMP_V2_MEMBERSHIP_REPORT 0x16 +#define IGMP_v1_ROUTER 1 +#define IGMP_v2_ROUTER 2 +#define IN6ADDRSZ NS_IN6ADDRSZ +#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } +#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } +#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) +#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) +#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) +#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) +#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) +#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) +#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) +#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) +#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) +#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) +#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) +#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) +#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) +#define INADDRSZ NS_INADDRSZ +#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) +#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) +#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) +#define INADDR_ANY ((in_addr_t) 0x00000000) +#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) +#define INADDR_DUMMY ((in_addr_t) 0xc0000008) +#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) +#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) +#define INADDR_NONE ((in_addr_t) 0xffffffff) +#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) +#define INDIR_MASK NS_CMPRSFLGS +#define INET6_ADDRSTRLEN 46 +#define INET_ADDRSTRLEN 16 +#define INFINITY 1e5000f +#define INT16SZ NS_INT16SZ +#define INT16_C(c) c +#define INT16_MAX (0x7fff) +#define INT16_MIN (-1-0x7fff) +#define INT32SZ NS_INT32SZ +#define INT32_C(c) c +#define INT32_MAX (0x7fffffff) +#define INT32_MIN (-1-0x7fffffff) +#define INT64_C(c) c ## LL +#define INT64_MAX (0x7fffffffffffffff) +#define INT64_MIN (-1-0x7fffffffffffffff) +#define INT8SZ NS_INT8SZ +#define INT8_C(c) c +#define INT8_MAX (0x7f) +#define INT8_MIN (-1-0x7f) +#define INTBITS (sizeof(int) * 8) +#define INTMAX_C(c) c ## LL +#define INTMAX_MAX INT64_MAX +#define INTMAX_MIN INT64_MIN +#define INTPTR_MAX INT32_MAX +#define INTPTR_MIN INT32_MIN +#define INT_FAST16_MAX INT16_MAX +#define INT_FAST16_MIN INT16_MIN +#define INT_FAST32_MAX INT32_MAX +#define INT_FAST32_MIN INT32_MIN +#define INT_FAST64_MAX INT64_MAX +#define INT_FAST64_MIN INT64_MIN +#define INT_FAST8_MAX INT8_MAX +#define INT_FAST8_MIN INT8_MIN +#define INT_LEAST16_MAX INT16_MAX +#define INT_LEAST16_MIN INT16_MIN +#define INT_LEAST32_MAX INT32_MAX +#define INT_LEAST32_MIN INT32_MIN +#define INT_LEAST64_MAX INT64_MAX +#define INT_LEAST64_MIN INT64_MIN +#define INT_LEAST8_MAX INT8_MAX +#define INT_LEAST8_MIN INT8_MIN +#define INT_MAX 0x7fffffff +#define INT_MIN (-1-0x7fffffff) +#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) +#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) +#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) +#define IN_CLASSA_MAX 128 +#define IN_CLASSA_NET 0xff000000 +#define IN_CLASSA_NSHIFT 24 +#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) +#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) +#define IN_CLASSB_MAX 65536 +#define IN_CLASSB_NET 0xffff0000 +#define IN_CLASSB_NSHIFT 16 +#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) +#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) +#define IN_CLASSC_NET 0xffffff00 +#define IN_CLASSC_NSHIFT 8 +#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) +#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) +#define IN_LOOPBACKNET 127 +#define IN_MULTICAST(a) IN_CLASSD(a) +#define IOV_MAX 1024 +#define IP 244 +#define IP6F_MORE_FRAG 0x0100 +#define IP6F_OFF_MASK 0xf8ff +#define IP6F_RESERVED_MASK 0x0600 +#define IP6OPT_JUMBO 0xc2 +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_NSAP_ADDR 0xc3 +#define IP6OPT_PAD1 0 +#define IP6OPT_PADN 1 +#define IP6OPT_ROUTER_ALERT 0x05 +#define IP6OPT_TUNNEL_LIMIT 0x04 +#define IP6OPT_TYPE(o) ((o) & 0xc0) +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xc0 +#define IP6OPT_TYPE_MUTABLE 0x20 +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6_ALERT_AN 0x0200 +#define IP6_ALERT_MLD 0x0000 +#define IP6_ALERT_RSVP 0x0100 +#define IPDEFTTL 64 +#define IPFRAGTTL 60 +#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) +#define IPOPT_CLASS_MASK 0x60 +#define IPOPT_CONTROL 0x00 +#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) +#define IPOPT_COPY 0x80 +#define IPOPT_DEBMEAS 0x40 +#define IPOPT_END IPOPT_EOL +#define IPOPT_EOL 0 +#define IPOPT_LSRR 131 +#define IPOPT_MEASUREMENT IPOPT_DEBMEAS +#define IPOPT_MINOFF 4 +#define IPOPT_NOOP IPOPT_NOP +#define IPOPT_NOP 1 +#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) +#define IPOPT_NUMBER_MASK 0x1f +#define IPOPT_OFFSET 2 +#define IPOPT_OLEN 1 +#define IPOPT_OPTVAL 0 +#define IPOPT_RA 148 +#define IPOPT_RESERVED1 0x20 +#define IPOPT_RESERVED2 0x60 +#define IPOPT_RR 7 +#define IPOPT_SATID 136 +#define IPOPT_SEC IPOPT_SECURITY +#define IPOPT_SECURITY 130 +#define IPOPT_SECUR_CONFID 0xf135 +#define IPOPT_SECUR_EFTO 0x789a +#define IPOPT_SECUR_MMMM 0xbc4d +#define IPOPT_SECUR_RESTR 0xaf13 +#define IPOPT_SECUR_SECRET 0xd788 +#define IPOPT_SECUR_TOPSECRET 0x6bc5 +#define IPOPT_SECUR_UNCLASS 0x0000 +#define IPOPT_SID IPOPT_SATID +#define IPOPT_SSRR 137 +#define IPOPT_TIMESTAMP IPOPT_TS +#define IPOPT_TS 68 +#define IPOPT_TS_PRESPEC 3 +#define IPOPT_TS_TSANDADDR 1 +#define IPOPT_TS_TSONLY 0 +#define IPPORT_RESERVED 1024 +#define IPPROTO_ICMP 1 +#define IPPROTO_IP 0 +#define IPPROTO_IPV6 41 +#define IPPROTO_RAW 255 +#define IPPROTO_TCP 6 +#define IPPROTO_UDP 17 +#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) +#define IPTOS_CLASS_CS0 0x00 +#define IPTOS_CLASS_CS1 0x20 +#define IPTOS_CLASS_CS2 0x40 +#define IPTOS_CLASS_CS3 0x60 +#define IPTOS_CLASS_CS4 0x80 +#define IPTOS_CLASS_CS5 0xa0 +#define IPTOS_CLASS_CS6 0xc0 +#define IPTOS_CLASS_CS7 0xe0 +#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 +#define IPTOS_CLASS_MASK 0xe0 +#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) +#define IPTOS_DSCP_AF11 0x28 +#define IPTOS_DSCP_AF12 0x30 +#define IPTOS_DSCP_AF13 0x38 +#define IPTOS_DSCP_AF21 0x48 +#define IPTOS_DSCP_AF22 0x50 +#define IPTOS_DSCP_AF23 0x58 +#define IPTOS_DSCP_AF31 0x68 +#define IPTOS_DSCP_AF32 0x70 +#define IPTOS_DSCP_AF33 0x78 +#define IPTOS_DSCP_AF41 0x88 +#define IPTOS_DSCP_AF42 0x90 +#define IPTOS_DSCP_AF43 0x98 +#define IPTOS_DSCP_EF 0xb8 +#define IPTOS_DSCP_MASK 0xfc +#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) +#define IPTOS_ECN_CE 0x03 +#define IPTOS_ECN_ECT0 0x02 +#define IPTOS_ECN_ECT1 0x01 +#define IPTOS_ECN_MASK 0x03 +#define IPTOS_ECN_NOT_ECT 0x00 +#define IPTOS_LOWCOST 0x02 +#define IPTOS_LOWDELAY 0x10 +#define IPTOS_MINCOST IPTOS_LOWCOST +#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) +#define IPTOS_PREC_CRITIC_ECP 0xa0 +#define IPTOS_PREC_FLASH 0x60 +#define IPTOS_PREC_FLASHOVERRIDE 0x80 +#define IPTOS_PREC_IMMEDIATE 0x40 +#define IPTOS_PREC_INTERNETCONTROL 0xc0 +#define IPTOS_PREC_MASK 0xe0 +#define IPTOS_PREC_NETCONTROL 0xe0 +#define IPTOS_PREC_PRIORITY 0x20 +#define IPTOS_PREC_ROUTINE 0x00 +#define IPTOS_RELIABILITY 0x04 +#define IPTOS_THROUGHPUT 0x08 +#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) +#define IPTOS_TOS_MASK 0x1E +#define IPTTLDEC 1 +#define IPV6_2292DSTOPTS 4 +#define IPV6_2292HOPLIMIT 8 +#define IPV6_2292HOPOPTS 3 +#define IPV6_2292PKTINFO 2 +#define IPV6_2292PKTOPTIONS 6 +#define IPV6_2292RTHDR 5 +#define IPV6_ADDRFORM 1 +#define IPV6_ADDR_PREFERENCES 72 +#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP +#define IPV6_AUTHHDR 10 +#define IPV6_AUTOFLOWLABEL 70 +#define IPV6_CHECKSUM 7 +#define IPV6_DONTFRAG 62 +#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP +#define IPV6_DSTOPTS 59 +#define IPV6_FREEBIND 78 +#define IPV6_HDRINCL 36 +#define IPV6_HOPLIMIT 52 +#define IPV6_HOPOPTS 54 +#define IPV6_IPSEC_POLICY 34 +#define IPV6_JOIN_ANYCAST 27 +#define IPV6_JOIN_GROUP 20 +#define IPV6_LEAVE_ANYCAST 28 +#define IPV6_LEAVE_GROUP 21 +#define IPV6_MINHOPCOUNT 73 +#define IPV6_MTU 24 +#define IPV6_MTU_DISCOVER 23 +#define IPV6_MULTICAST_ALL 29 +#define IPV6_MULTICAST_HOPS 18 +#define IPV6_MULTICAST_IF 17 +#define IPV6_MULTICAST_LOOP 19 +#define IPV6_NEXTHOP 9 +#define IPV6_ORIGDSTADDR 74 +#define IPV6_PATHMTU 61 +#define IPV6_PKTINFO 50 +#define IPV6_PMTUDISC_DO 2 +#define IPV6_PMTUDISC_DONT 0 +#define IPV6_PMTUDISC_INTERFACE 4 +#define IPV6_PMTUDISC_OMIT 5 +#define IPV6_PMTUDISC_PROBE 3 +#define IPV6_PMTUDISC_WANT 1 +#define IPV6_PREFER_SRC_CGA 0x0008 +#define IPV6_PREFER_SRC_COA 0x0004 +#define IPV6_PREFER_SRC_HOME 0x0400 +#define IPV6_PREFER_SRC_NONCGA 0x0800 +#define IPV6_PREFER_SRC_PUBLIC 0x0002 +#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 +#define IPV6_PREFER_SRC_TMP 0x0001 +#define IPV6_RECVDSTOPTS 58 +#define IPV6_RECVERR 25 +#define IPV6_RECVFRAGSIZE 77 +#define IPV6_RECVHOPLIMIT 51 +#define IPV6_RECVHOPOPTS 53 +#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR +#define IPV6_RECVPATHMTU 60 +#define IPV6_RECVPKTINFO 49 +#define IPV6_RECVRTHDR 56 +#define IPV6_RECVTCLASS 66 +#define IPV6_ROUTER_ALERT 22 +#define IPV6_ROUTER_ALERT_ISOLATE 30 +#define IPV6_RTHDR 57 +#define IPV6_RTHDRDSTOPTS 55 +#define IPV6_RTHDR_LOOSE 0 +#define IPV6_RTHDR_STRICT 1 +#define IPV6_RTHDR_TYPE_0 0 +#define IPV6_RXDSTOPTS IPV6_DSTOPTS +#define IPV6_RXHOPOPTS IPV6_HOPOPTS +#define IPV6_TCLASS 67 +#define IPV6_TRANSPARENT 75 +#define IPV6_UNICAST_HOPS 16 +#define IPV6_UNICAST_IF 76 +#define IPV6_V6ONLY 26 +#define IPV6_XFRM_POLICY 35 +#define IPVERSION 4 +#define IP_ADD_MEMBERSHIP 35 +#define IP_ADD_SOURCE_MEMBERSHIP 39 +#define IP_BIND_ADDRESS_NO_PORT 24 +#define IP_BLOCK_SOURCE 38 +#define IP_CHECKSUM 23 +#define IP_DEFAULT_MULTICAST_LOOP 1 +#define IP_DEFAULT_MULTICAST_TTL 1 +#define IP_DF 0x4000 +#define IP_DROP_MEMBERSHIP 36 +#define IP_DROP_SOURCE_MEMBERSHIP 40 +#define IP_FREEBIND 15 +#define IP_HDRINCL 3 +#define IP_IPSEC_POLICY 16 +#define IP_MAXPACKET 65535 +#define IP_MAX_MEMBERSHIPS 20 +#define IP_MF 0x2000 +#define IP_MINTTL 21 +#define IP_MSFILTER 41 +#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) +#define IP_MSS 576 +#define IP_MTU 14 +#define IP_MTU_DISCOVER 10 +#define IP_MULTICAST_ALL 49 +#define IP_MULTICAST_IF 32 +#define IP_MULTICAST_LOOP 34 +#define IP_MULTICAST_TTL 33 +#define IP_NODEFRAG 22 +#define IP_OFFMASK 0x1fff +#define IP_OPTIONS 4 +#define IP_ORIGDSTADDR 20 +#define IP_PASSSEC 18 +#define IP_PKTINFO 8 +#define IP_PKTOPTIONS 9 +#define IP_PMTUDISC 10 +#define IP_PMTUDISC_DO 2 +#define IP_PMTUDISC_DONT 0 +#define IP_PMTUDISC_INTERFACE 4 +#define IP_PMTUDISC_OMIT 5 +#define IP_PMTUDISC_PROBE 3 +#define IP_PMTUDISC_WANT 1 +#define IP_RECVERR 11 +#define IP_RECVERR_RFC4884 26 +#define IP_RECVFRAGSIZE 25 +#define IP_RECVOPTS 6 +#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR +#define IP_RECVRETOPTS IP_RETOPTS +#define IP_RECVTOS 13 +#define IP_RECVTTL 12 +#define IP_RETOPTS 7 +#define IP_RF 0x8000 +#define IP_ROUTER_ALERT 5 +#define IP_TOS 1 +#define IP_TRANSPARENT 19 +#define IP_TTL 2 +#define IP_UNBLOCK_SOURCE 37 +#define IP_UNICAST_IF 50 +#define IP_XFRM_POLICY 17 +#define IQUERY ns_o_iquery +#define I_ATMARK (__SID |31) +#define I_CANPUT (__SID |34) +#define I_CKBAND (__SID |29) +#define I_FDINSERT (__SID |16) +#define I_FIND (__SID |11) +#define I_FLUSH (__SID | 5) +#define I_FLUSHBAND (__SID |28) +#define I_GETBAND (__SID |30) +#define I_GETCLTIME (__SID |33) +#define I_GETSIG (__SID |10) +#define I_GRDOPT (__SID | 7) +#define I_GWROPT (__SID |20) +#define I_LINK (__SID |12) +#define I_LIST (__SID |21) +#define I_LOOK (__SID | 4) +#define I_NREAD (__SID | 1) +#define I_PEEK (__SID |15) +#define I_PLINK (__SID |22) +#define I_POP (__SID | 3) +#define I_PUNLINK (__SID |23) +#define I_PUSH (__SID | 2) +#define I_RECVFD (__SID |14) +#define I_SENDFD (__SID |17) +#define I_SETCLTIME (__SID |32) +#define I_SETSIG (__SID | 9) +#define I_SRDOPT (__SID | 6) +#define I_STR (__SID | 8) +#define I_SWROPT (__SID |19) +#define I_UNLINK (__SID |13) +#define LASTMARK 0x02 +#define LC_ALL 6 +#define LC_ALL_MASK 0x7fffffff +#define LC_COLLATE 3 +#define LC_COLLATE_MASK (1<(b))?(a):(b)) +#define MAXCDNAME NS_MAXCDNAME +#define MAXDNAME NS_MAXDNAME +#define MAXDOUBLE DBL_MAX +#define MAXFLOAT FLT_MAX +#define MAXHOSTNAMELEN 64 +#define MAXINT INT_MAX +#define MAXLABEL NS_MAXLABEL +#define MAXLONG LONG_MAX +#define MAXNAMLEN 255 +#define MAXPATHLEN 4096 +#define MAXSHORT SHRT_MAX +#define MAXSYMLINKS 20 +#define MAXTC 6 +#define MAXTTL 255 +#define MAX_IPOPTLEN 40 +#define MB_CUR_MAX (__ctype_get_mb_cur_max()) +#define MB_LEN_MAX 4 +#define MCAST_BLOCK_SOURCE 43 +#define MCAST_EXCLUDE 0 +#define MCAST_INCLUDE 1 +#define MCAST_JOIN_GROUP 42 +#define MCAST_JOIN_SOURCE_GROUP 46 +#define MCAST_LEAVE_GROUP 45 +#define MCAST_LEAVE_SOURCE_GROUP 47 +#define MCAST_MSFILTER 48 +#define MCAST_UNBLOCK_SOURCE 44 +#define MIN(a,b) (((a)<(b))?(a):(b)) +#define MINDOUBLE DBL_MIN +#define MINFLOAT FLT_MIN +#define MININT INT_MIN +#define MINLONG LONG_MIN +#define MINSHORT SHRT_MIN +#define MLD_LISTENER_QUERY 130 +#define MLD_LISTENER_REDUCTION 132 +#define MLD_LISTENER_REPORT 131 +#define MM_APPL 8 +#define MM_CONSOLE 512 +#define MM_ERROR 2 +#define MM_FIRM 4 +#define MM_HALT 1 +#define MM_HARD 1 +#define MM_INFO 4 +#define MM_NOCON 4 +#define MM_NOMSG 1 +#define MM_NOSEV 0 +#define MM_NOTOK (-1) +#define MM_NRECOV 128 +#define MM_NULLACT ((char*)0) +#define MM_NULLLBL ((char*)0) +#define MM_NULLMC 0L +#define MM_NULLSEV 0 +#define MM_NULLTAG ((char*)0) +#define MM_NULLTXT ((char*)0) +#define MM_OK 0 +#define MM_OPSYS 32 +#define MM_PRINT 256 +#define MM_RECOVER 64 +#define MM_SOFT 2 +#define MM_UTIL 16 +#define MM_WARNING 3 +#define MODE_ACK 0x04 +#define MODE_B 2 +#define MODE_C 3 +#define MODE_ECHO 0x0200 +#define MODE_EDIT 0x01 +#define MODE_FLOW 0x0100 +#define MODE_FORCE 0x1000 +#define MODE_INBIN 0x0400 +#define MODE_LIT_ECHO 0x10 +#define MODE_MASK 0x1f +#define MODE_OUTBIN 0x0800 +#define MODE_S 1 +#define MODE_SOFT_TAB 0x08 +#define MODE_TRAPSIG 0x02 +#define MOD_CLKA ADJ_OFFSET_SINGLESHOT +#define MOD_CLKB ADJ_TICK +#define MOD_ESTERROR ADJ_ESTERROR +#define MOD_FREQUENCY ADJ_FREQUENCY +#define MOD_MAXERROR ADJ_MAXERROR +#define MOD_MICRO ADJ_MICRO +#define MOD_NANO ADJ_NANO +#define MOD_OFFSET ADJ_OFFSET +#define MOD_STATUS ADJ_STATUS +#define MOD_TAI ADJ_TAI +#define MOD_TIMECONST ADJ_TIMECONST +#define MON_1 0x2001A +#define MON_10 0x20023 +#define MON_11 0x20024 +#define MON_12 0x20025 +#define MON_2 0x2001B +#define MON_3 0x2001C +#define MON_4 0x2001D +#define MON_5 0x2001E +#define MON_6 0x2001F +#define MON_7 0x20020 +#define MON_8 0x20021 +#define MON_9 0x20022 +#define MORECTL 1 +#define MOREDATA 2 +#define MSG_ANY 0x02 +#define MSG_BAND 0x04 +#define MSG_HIPRI 0x01 +#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK +#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED +#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL +#define MUXID_ALL (-1) +#define M_1_PI 0.31830988618379067154 +#define M_2_PI 0.63661977236758134308 +#define M_2_SQRTPI 1.12837916709551257390 +#define M_E 2.7182818284590452354 +#define M_LN10 2.30258509299404568402 +#define M_LN2 0.69314718055994530942 +#define M_LOG10E 0.43429448190325182765 +#define M_LOG2E 1.4426950408889634074 +#define M_PI 3.14159265358979323846 +#define M_PI_2 1.57079632679489661923 +#define M_PI_4 0.78539816339744830962 +#define M_SQRT1_2 0.70710678118654752440 +#define M_SQRT2 1.41421356237309504880 +#define NAMESERVER_PORT NS_DEFAULTPORT +#define NAME_MAX 255 +#define NAN (0.0f/0.0f) +#define NBBY 8 +#define NCARGS 131072 +#define ND_NA_FLAG_OVERRIDE 0x00000020 +#define ND_NA_FLAG_ROUTER 0x00000080 +#define ND_NA_FLAG_SOLICITED 0x00000040 +#define ND_NEIGHBOR_ADVERT 136 +#define ND_NEIGHBOR_SOLICIT 135 +#define ND_OPT_HOME_AGENT_INFO 8 +#define ND_OPT_MTU 5 +#define ND_OPT_PI_FLAG_AUTO 0x40 +#define ND_OPT_PI_FLAG_ONLINK 0x80 +#define ND_OPT_PI_FLAG_RADDR 0x20 +#define ND_OPT_PREFIX_INFORMATION 3 +#define ND_OPT_REDIRECTED_HEADER 4 +#define ND_OPT_RTR_ADV_INTERVAL 7 +#define ND_OPT_SOURCE_LINKADDR 1 +#define ND_OPT_TARGET_LINKADDR 2 +#define ND_RA_FLAG_HOME_AGENT 0x20 +#define ND_RA_FLAG_MANAGED 0x80 +#define ND_RA_FLAG_OTHER 0x40 +#define ND_REDIRECT 137 +#define ND_ROUTER_ADVERT 134 +#define ND_ROUTER_SOLICIT 133 +#define NEW_ENV_VALUE 1 +#define NEW_ENV_VAR 0 +#define NGROUPS 32 +#define NGROUPS_MAX 32 +#define NL_ARGMAX 9 +#define NL_CAT_LOCALE 1 +#define NL_LANGMAX 32 +#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) +#define NL_MSGMAX 32767 +#define NL_NMAX 16 +#define NL_SETD 1 +#define NL_SETMAX 255 +#define NL_TEXTMAX 2048 +#define NOERROR ns_r_noerror +#define NOEXPR 0x50001 +#define NOFILE 256 +#define NOGROUP (-1) +#define NOP 241 +#define NOSTR 0x50003 +#define NOTAUTH ns_r_notauth +#define NOTIMP ns_r_notimpl +#define NOTZONE ns_r_notzone +#define NR_ICMP_TYPES 18 +#define NR_ICMP_UNREACH 15 +#define NSLC 18 +#define NS_ALG_DH 2 +#define NS_ALG_DSA 3 +#define NS_ALG_DSS NS_ALG_DSA +#define NS_ALG_EXPIRE_ONLY 253 +#define NS_ALG_MD5RSA 1 +#define NS_ALG_PRIVATE_OID 254 +#define NS_CMPRSFLGS 0xc0 +#define NS_DEFAULTPORT 53 +#define NS_DSA_MAX_BYTES 405 +#define NS_DSA_MIN_SIZE 213 +#define NS_DSA_SIG_SIZE 41 +#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) +#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) +#define NS_HFIXEDSZ 12 +#define NS_IN6ADDRSZ 16 +#define NS_INADDRSZ 4 +#define NS_INT16SZ 2 +#define NS_INT32SZ 4 +#define NS_INT8SZ 1 +#define NS_KEY_EXTENDED_FLAGS 0x1000 +#define NS_KEY_NAME_ENTITY 0x0200 +#define NS_KEY_NAME_RESERVED 0x0300 +#define NS_KEY_NAME_TYPE 0x0300 +#define NS_KEY_NAME_USER 0x0000 +#define NS_KEY_NAME_ZONE 0x0100 +#define NS_KEY_NO_AUTH 0x8000 +#define NS_KEY_NO_CONF 0x4000 +#define NS_KEY_PROT_ANY 255 +#define NS_KEY_PROT_DNSSEC 3 +#define NS_KEY_PROT_EMAIL 2 +#define NS_KEY_PROT_IPSEC 4 +#define NS_KEY_PROT_TLS 1 +#define NS_KEY_RESERVED10 0x0020 +#define NS_KEY_RESERVED11 0x0010 +#define NS_KEY_RESERVED2 0x2000 +#define NS_KEY_RESERVED4 0x0800 +#define NS_KEY_RESERVED5 0x0400 +#define NS_KEY_RESERVED8 0x0080 +#define NS_KEY_RESERVED9 0x0040 +#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) +#define NS_KEY_RESERVED_BITMASK2 0xFFFF +#define NS_KEY_SIGNATORYMASK 0x000F +#define NS_KEY_TYPEMASK 0xC000 +#define NS_KEY_TYPE_AUTH_CONF 0x0000 +#define NS_KEY_TYPE_AUTH_ONLY 0x4000 +#define NS_KEY_TYPE_CONF_ONLY 0x8000 +#define NS_KEY_TYPE_NO_KEY 0xC000 +#define NS_MAXCDNAME 255 +#define NS_MAXDNAME 1025 +#define NS_MAXLABEL 63 +#define NS_MAXMSG 65535 +#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) +#define NS_MD5RSA_MAX_BITS 4096 +#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) +#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) +#define NS_MD5RSA_MIN_BITS 512 +#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) +#define NS_NOTIFY_OP ns_o_notify +#define NS_NXT_BITS 8 +#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_MAX 127 +#define NS_OPT_DNSSEC_OK 0x8000U +#define NS_OPT_NSID 3 +#define NS_PACKETSZ 512 +#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) +#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) +#define NS_QFIXEDSZ 4 +#define NS_RRFIXEDSZ 10 +#define NS_SIG_ALG 2 +#define NS_SIG_EXPIR 8 +#define NS_SIG_FOOT 16 +#define NS_SIG_LABELS 3 +#define NS_SIG_OTTL 4 +#define NS_SIG_SIGNED 12 +#define NS_SIG_SIGNER 18 +#define NS_SIG_TYPE 0 +#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" +#define NS_TSIG_ERROR_FORMERR -12 +#define NS_TSIG_ERROR_NO_SPACE -11 +#define NS_TSIG_ERROR_NO_TSIG -10 +#define NS_TSIG_FUDGE 300 +#define NS_TSIG_TCP_COUNT 100 +#define NS_UPDATE_OP ns_o_update +#define NTELOPTS (1+TELOPT_NEW_ENVIRON) +#define NULL ((void*)0) +#define NXDOMAIN ns_r_nxdomain +#define NXRRSET ns_r_nxrrset +#define NZERO 20 +#define OLD_ENV_VALUE 0 +#define OLD_ENV_VAR 1 +#define ONCE_FLAG_INIT 0 +#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) +#define O_APPEND __WASI_FDFLAGS_APPEND +#define O_CLOEXEC (0) +#define O_CREAT (__WASI_OFLAGS_CREAT << 12) +#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) +#define O_DSYNC __WASI_FDFLAGS_DSYNC +#define O_EXCL (__WASI_OFLAGS_EXCL << 12) +#define O_EXEC (0x02000000) +#define O_NOCTTY (0) +#define O_NOFOLLOW (0x01000000) +#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK +#define O_RDONLY (0x04000000) +#define O_RDWR (O_RDONLY | O_WRONLY) +#define O_RSYNC __WASI_FDFLAGS_RSYNC +#define O_SEARCH (0x08000000) +#define O_SYNC __WASI_FDFLAGS_SYNC +#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) +#define O_TTY_INIT (0) +#define O_WRONLY (0x10000000) +#define PACKETSZ NS_PACKETSZ +#define PACKET_ADD_MEMBERSHIP 1 +#define PACKET_AUXDATA 8 +#define PACKET_BROADCAST 1 +#define PACKET_COPY_THRESH 7 +#define PACKET_DROP_MEMBERSHIP 2 +#define PACKET_FANOUT 18 +#define PACKET_FANOUT_DATA 22 +#define PACKET_FASTROUTE 6 +#define PACKET_HDRLEN 11 +#define PACKET_HOST 0 +#define PACKET_IGNORE_OUTGOING 23 +#define PACKET_LOOPBACK 5 +#define PACKET_LOSS 14 +#define PACKET_MR_ALLMULTI 2 +#define PACKET_MR_MULTICAST 0 +#define PACKET_MR_PROMISC 1 +#define PACKET_MR_UNICAST 3 +#define PACKET_MULTICAST 2 +#define PACKET_ORIGDEV 9 +#define PACKET_OTHERHOST 3 +#define PACKET_OUTGOING 4 +#define PACKET_QDISC_BYPASS 20 +#define PACKET_RECV_OUTPUT 3 +#define PACKET_RESERVE 12 +#define PACKET_ROLLOVER_STATS 21 +#define PACKET_RX_RING 5 +#define PACKET_STATISTICS 6 +#define PACKET_TIMESTAMP 17 +#define PACKET_TX_HAS_OFF 19 +#define PACKET_TX_RING 13 +#define PACKET_TX_TIMESTAMP 16 +#define PACKET_VERSION 10 +#define PACKET_VNET_HDR 15 +#define PAGESIZE (0x10000) +#define PAGE_SIZE PAGESIZE +#define PATH_MAX 4096 +#define PDP_ENDIAN __PDP_ENDIAN +#define PF_INET 1 +#define PF_INET6 2 +#define PF_UNSPEC 0 +#define PM_STR 0x20027 +#define POLLERR 0x1000 +#define POLLHUP 0x2000 +#define POLLIN POLLRDNORM +#define POLLNVAL 0x4000 +#define POLLOUT POLLWRNORM +#define POLLRDNORM 0x1 +#define POLLWRNORM 0x2 +#define POSIX_CLOSE_RESTART 0 +#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED +#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE +#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL +#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM +#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL +#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED +#define PRELIM 1 +#define PRIX16 __UINT16_FMTX__ +#define PRIX32 __UINT32_FMTX__ +#define PRIX64 __UINT64_FMTX__ +#define PRIX8 __UINT8_FMTX__ +#define PRIXFAST16 __UINT_FAST16_FMTX__ +#define PRIXFAST32 __UINT_FAST32_FMTX__ +#define PRIXFAST64 __UINT_FAST64_FMTX__ +#define PRIXFAST8 __UINT_FAST8_FMTX__ +#define PRIXLEAST16 __UINT_LEAST16_FMTX__ +#define PRIXLEAST32 __UINT_LEAST32_FMTX__ +#define PRIXLEAST64 __UINT_LEAST64_FMTX__ +#define PRIXLEAST8 __UINT_LEAST8_FMTX__ +#define PRIXMAX __UINTMAX_FMTX__ +#define PRIXPTR __UINTPTR_FMTX__ +#define PRId16 __INT16_FMTd__ +#define PRId32 __INT32_FMTd__ +#define PRId64 __INT64_FMTd__ +#define PRId8 __INT8_FMTd__ +#define PRIdFAST16 __INT_FAST16_FMTd__ +#define PRIdFAST32 __INT_FAST32_FMTd__ +#define PRIdFAST64 __INT_FAST64_FMTd__ +#define PRIdFAST8 __INT_FAST8_FMTd__ +#define PRIdLEAST16 __INT_LEAST16_FMTd__ +#define PRIdLEAST32 __INT_LEAST32_FMTd__ +#define PRIdLEAST64 __INT_LEAST64_FMTd__ +#define PRIdLEAST8 __INT_LEAST8_FMTd__ +#define PRIdMAX __INTMAX_FMTd__ +#define PRIdPTR __INTPTR_FMTd__ +#define PRIi16 __INT16_FMTi__ +#define PRIi32 __INT32_FMTi__ +#define PRIi64 __INT64_FMTi__ +#define PRIi8 __INT8_FMTi__ +#define PRIiFAST16 __INT_FAST16_FMTi__ +#define PRIiFAST32 __INT_FAST32_FMTi__ +#define PRIiFAST64 __INT_FAST64_FMTi__ +#define PRIiFAST8 __INT_FAST8_FMTi__ +#define PRIiLEAST16 __INT_LEAST16_FMTi__ +#define PRIiLEAST32 __INT_LEAST32_FMTi__ +#define PRIiLEAST64 __INT_LEAST64_FMTi__ +#define PRIiLEAST8 __INT_LEAST8_FMTi__ +#define PRIiMAX __INTMAX_FMTi__ +#define PRIiPTR __INTPTR_FMTi__ +#define PRIo16 __UINT16_FMTo__ +#define PRIo32 __UINT32_FMTo__ +#define PRIo64 __UINT64_FMTo__ +#define PRIo8 __UINT8_FMTo__ +#define PRIoFAST16 __UINT_FAST16_FMTo__ +#define PRIoFAST32 __UINT_FAST32_FMTo__ +#define PRIoFAST64 __UINT_FAST64_FMTo__ +#define PRIoFAST8 __UINT_FAST8_FMTo__ +#define PRIoLEAST16 __UINT_LEAST16_FMTo__ +#define PRIoLEAST32 __UINT_LEAST32_FMTo__ +#define PRIoLEAST64 __UINT_LEAST64_FMTo__ +#define PRIoLEAST8 __UINT_LEAST8_FMTo__ +#define PRIoMAX __UINTMAX_FMTo__ +#define PRIoPTR __UINTPTR_FMTo__ +#define PRIu16 __UINT16_FMTu__ +#define PRIu32 __UINT32_FMTu__ +#define PRIu64 __UINT64_FMTu__ +#define PRIu8 __UINT8_FMTu__ +#define PRIuFAST16 __UINT_FAST16_FMTu__ +#define PRIuFAST32 __UINT_FAST32_FMTu__ +#define PRIuFAST64 __UINT_FAST64_FMTu__ +#define PRIuFAST8 __UINT_FAST8_FMTu__ +#define PRIuLEAST16 __UINT_LEAST16_FMTu__ +#define PRIuLEAST32 __UINT_LEAST32_FMTu__ +#define PRIuLEAST64 __UINT_LEAST64_FMTu__ +#define PRIuLEAST8 __UINT_LEAST8_FMTu__ +#define PRIuMAX __UINTMAX_FMTu__ +#define PRIuPTR __UINTPTR_FMTu__ +#define PRIx16 __UINT16_FMTx__ +#define PRIx32 __UINT32_FMTx__ +#define PRIx64 __UINT64_FMTx__ +#define PRIx8 __UINT8_FMTx__ +#define PRIxFAST16 __UINT_FAST16_FMTx__ +#define PRIxFAST32 __UINT_FAST32_FMTx__ +#define PRIxFAST64 __UINT_FAST64_FMTx__ +#define PRIxFAST8 __UINT_FAST8_FMTx__ +#define PRIxLEAST16 __UINT_LEAST16_FMTx__ +#define PRIxLEAST32 __UINT_LEAST32_FMTx__ +#define PRIxLEAST64 __UINT_LEAST64_FMTx__ +#define PRIxLEAST8 __UINT_LEAST8_FMTx__ +#define PRIxMAX __UINTMAX_FMTx__ +#define PRIxPTR __UINTPTR_FMTx__ +#define PTRBITS (sizeof(char *) * 8) +#define PTRDIFF_MAX INT32_MAX +#define PTRDIFF_MIN INT32_MIN +#define PUTLONG NS_PUT32 +#define PUTSHORT NS_PUT16 +#define QFIXEDSZ NS_QFIXEDSZ +#define QUERY ns_o_query +#define RADIXCHAR 0x10000 +#define RAND_MAX (0x7fffffff) +#define REC_EOF '\002' +#define REC_EOR '\001' +#define REC_ESC '\377' +#define REFUSED ns_r_refused +#define REGTYPE '0' +#define REG_BADBR 10 +#define REG_BADPAT 2 +#define REG_BADRPT 13 +#define REG_EBRACE 9 +#define REG_EBRACK 7 +#define REG_ECOLLATE 3 +#define REG_ECTYPE 4 +#define REG_EESCAPE 5 +#define REG_ENOSYS -1 +#define REG_EPAREN 8 +#define REG_ERANGE 11 +#define REG_ESPACE 12 +#define REG_ESUBREG 6 +#define REG_EXTENDED 1 +#define REG_ICASE 2 +#define REG_NEWLINE 4 +#define REG_NOMATCH 1 +#define REG_NOSUB 8 +#define REG_NOTBOL 1 +#define REG_NOTEOL 2 +#define REG_OK 0 +#define RE_DUP_MAX 255 +#define RMSGD 0x0001 +#define RMSGN 0x0002 +#define RNORM 0x0000 +#define RPM_PCO_ADD 1 +#define RPM_PCO_CHANGE 2 +#define RPM_PCO_SETGLOBAL 3 +#define RPROTDAT 0x0004 +#define RPROTDIS 0x0008 +#define RPROTMASK 0x001C +#define RPROTNORM 0x0010 +#define RRFIXEDSZ NS_RRFIXEDSZ +#define RRQ 01 +#define RS_HIPRI 0x01 +#define RUSAGE_CHILDREN 2 +#define RUSAGE_SELF 1 +#define R_OK (4) +#define SARMAG 8 +#define SB 250 +#define SCHAR_MAX 127 +#define SCHAR_MIN (-128) +#define SCNd16 __INT16_FMTd__ +#define SCNd32 __INT32_FMTd__ +#define SCNd64 __INT64_FMTd__ +#define SCNd8 __INT8_FMTd__ +#define SCNdFAST16 __INT_FAST16_FMTd__ +#define SCNdFAST32 __INT_FAST32_FMTd__ +#define SCNdFAST64 __INT_FAST64_FMTd__ +#define SCNdFAST8 __INT_FAST8_FMTd__ +#define SCNdLEAST16 __INT_LEAST16_FMTd__ +#define SCNdLEAST32 __INT_LEAST32_FMTd__ +#define SCNdLEAST64 __INT_LEAST64_FMTd__ +#define SCNdLEAST8 __INT_LEAST8_FMTd__ +#define SCNdMAX __INTMAX_FMTd__ +#define SCNdPTR __INTPTR_FMTd__ +#define SCNi16 __INT16_FMTi__ +#define SCNi32 __INT32_FMTi__ +#define SCNi64 __INT64_FMTi__ +#define SCNi8 __INT8_FMTi__ +#define SCNiFAST16 __INT_FAST16_FMTi__ +#define SCNiFAST32 __INT_FAST32_FMTi__ +#define SCNiFAST64 __INT_FAST64_FMTi__ +#define SCNiFAST8 __INT_FAST8_FMTi__ +#define SCNiLEAST16 __INT_LEAST16_FMTi__ +#define SCNiLEAST32 __INT_LEAST32_FMTi__ +#define SCNiLEAST64 __INT_LEAST64_FMTi__ +#define SCNiLEAST8 __INT_LEAST8_FMTi__ +#define SCNiMAX __INTMAX_FMTi__ +#define SCNiPTR __INTPTR_FMTi__ +#define SCNo16 __UINT16_FMTo__ +#define SCNo32 __UINT32_FMTo__ +#define SCNo64 __UINT64_FMTo__ +#define SCNo8 __UINT8_FMTo__ +#define SCNoFAST16 __UINT_FAST16_FMTo__ +#define SCNoFAST32 __UINT_FAST32_FMTo__ +#define SCNoFAST64 __UINT_FAST64_FMTo__ +#define SCNoFAST8 __UINT_FAST8_FMTo__ +#define SCNoLEAST16 __UINT_LEAST16_FMTo__ +#define SCNoLEAST32 __UINT_LEAST32_FMTo__ +#define SCNoLEAST64 __UINT_LEAST64_FMTo__ +#define SCNoLEAST8 __UINT_LEAST8_FMTo__ +#define SCNoMAX __UINTMAX_FMTo__ +#define SCNoPTR __UINTPTR_FMTo__ +#define SCNu16 __UINT16_FMTu__ +#define SCNu32 __UINT32_FMTu__ +#define SCNu64 __UINT64_FMTu__ +#define SCNu8 __UINT8_FMTu__ +#define SCNuFAST16 __UINT_FAST16_FMTu__ +#define SCNuFAST32 __UINT_FAST32_FMTu__ +#define SCNuFAST64 __UINT_FAST64_FMTu__ +#define SCNuFAST8 __UINT_FAST8_FMTu__ +#define SCNuLEAST16 __UINT_LEAST16_FMTu__ +#define SCNuLEAST32 __UINT_LEAST32_FMTu__ +#define SCNuLEAST64 __UINT_LEAST64_FMTu__ +#define SCNuLEAST8 __UINT_LEAST8_FMTu__ +#define SCNuMAX __UINTMAX_FMTu__ +#define SCNuPTR __UINTPTR_FMTu__ +#define SCNx16 __UINT16_FMTx__ +#define SCNx32 __UINT32_FMTx__ +#define SCNx64 __UINT64_FMTx__ +#define SCNx8 __UINT8_FMTx__ +#define SCNxFAST16 __UINT_FAST16_FMTx__ +#define SCNxFAST32 __UINT_FAST32_FMTx__ +#define SCNxFAST64 __UINT_FAST64_FMTx__ +#define SCNxFAST8 __UINT_FAST8_FMTx__ +#define SCNxLEAST16 __UINT_LEAST16_FMTx__ +#define SCNxLEAST32 __UINT_LEAST32_FMTx__ +#define SCNxLEAST64 __UINT_LEAST64_FMTx__ +#define SCNxLEAST8 __UINT_LEAST8_FMTx__ +#define SCNxMAX __UINTMAX_FMTx__ +#define SCNxPTR __UINTPTR_FMTx__ +#define SE 240 +#define SEEK_CUR __WASI_WHENCE_CUR +#define SEEK_END __WASI_WHENCE_END +#define SEEK_SET __WASI_WHENCE_SET +#define SEGSIZE 512 +#define SEM_FAILED ((sem_t *)0) +#define SERVFAIL ns_r_servfail +#define SHORTBITS (sizeof(short) * 8) +#define SHRT_MAX 0x7fff +#define SHRT_MIN (-1-0x7fff) +#define SHUT_RD __WASI_SDFLAGS_RD +#define SHUT_RDWR (SHUT_RD | SHUT_WR) +#define SHUT_WR __WASI_SDFLAGS_WR +#define SIG_ATOMIC_MAX INT32_MAX +#define SIG_ATOMIC_MIN INT32_MIN +#define SIZE_MAX UINT32_MAX +#define SI_LOAD_SHIFT 16 +#define SLC_ABORT 7 +#define SLC_ACK 0x80 +#define SLC_AO 4 +#define SLC_AYT 5 +#define SLC_BRK 2 +#define SLC_CANTCHANGE 1 +#define SLC_DEFAULT 3 +#define SLC_EC 10 +#define SLC_EL 11 +#define SLC_EOF 8 +#define SLC_EOR 6 +#define SLC_EW 12 +#define SLC_FLAGS 1 +#define SLC_FLUSHIN 0x40 +#define SLC_FLUSHOUT 0x20 +#define SLC_FORW1 17 +#define SLC_FORW2 18 +#define SLC_FUNC 0 +#define SLC_IP 3 +#define SLC_LEVELBITS 0x03 +#define SLC_LNEXT 14 +#define SLC_NAME(x) slc_names[x] +#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, +#define SLC_NAMES SLC_NAMELIST +#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) +#define SLC_NOSUPPORT 0 +#define SLC_RP 13 +#define SLC_SUSP 9 +#define SLC_SYNCH 1 +#define SLC_VALUE 2 +#define SLC_VARIABLE 2 +#define SLC_XOFF 16 +#define SLC_XON 15 +#define SNDPIPE 0x002 +#define SNDZERO 0x001 +#define SOCK_CLOEXEC (0x00002000) +#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM +#define SOCK_NONBLOCK (0x00004000) +#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM +#define SOL_SOCKET 0x7fffffff +#define SOL_TCP 6 +#define SOL_UDP 17 +#define SO_TYPE 3 +#define SSIZE_MAX LONG_MAX +#define STATUS ns_o_status +#define STA_CLK 0x8000 +#define STA_CLOCKERR 0x1000 +#define STA_DEL 0x0020 +#define STA_FLL 0x0008 +#define STA_FREQHOLD 0x0080 +#define STA_INS 0x0010 +#define STA_MODE 0x4000 +#define STA_NANO 0x2000 +#define STA_PLL 0x0001 +#define STA_PPSERROR 0x0800 +#define STA_PPSFREQ 0x0002 +#define STA_PPSJITTER 0x0200 +#define STA_PPSSIGNAL 0x0100 +#define STA_PPSTIME 0x0004 +#define STA_PPSWANDER 0x0400 +#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) +#define STA_UNSYNC 0x0040 +#define STDERR_FILENO 2 +#define STDIN_FILENO 0 +#define STDOUT_FILENO 1 +#define STRU_F 1 +#define STRU_P 3 +#define STRU_R 2 +#define SUN_LEN(s) (2+strlen((s)->sun_path)) +#define SUSP 237 +#define SYMLOOP_MAX 40 +#define SYMTYPE '2' +#define SYNCH 242 +#define S_ADDT ns_s_ar +#define S_BANDURG 0x0200 +#define S_ERROR 0x0010 +#define S_HANGUP 0x0020 +#define S_HIPRI 0x0002 +#define S_IEXEC S_IXUSR +#define S_IFBLK (0x6000) +#define S_IFCHR (0x2000) +#define S_IFDIR (0x4000) +#define S_IFIFO (0xc000) +#define S_IFLNK (0xa000) +#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) +#define S_IFREG (0x8000) +#define S_IFSOCK (0xc000) +#define S_INPUT 0x0001 +#define S_IREAD S_IRUSR +#define S_IRGRP (0x20) +#define S_IROTH (0x4) +#define S_IRUSR (0x100) +#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) +#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) +#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) +#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) +#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) +#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) +#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) +#define S_ISGID (0x400) +#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) +#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) +#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) +#define S_ISUID (0x800) +#define S_ISVTX (0x200) +#define S_IWGRP (0x10) +#define S_IWOTH (0x2) +#define S_IWRITE S_IWUSR +#define S_IWUSR (0x80) +#define S_IXGRP (0x8) +#define S_IXOTH (0x1) +#define S_IXUSR (0x40) +#define S_MSG 0x0008 +#define S_OUTPUT 0x0004 +#define S_PREREQ ns_s_pr +#define S_RDBAND 0x0080 +#define S_RDNORM 0x0040 +#define S_UPDATE ns_s_ud +#define S_WRBAND 0x0100 +#define S_WRNORM S_OUTPUT +#define S_ZONE ns_s_zn +#define TCPI_OPT_ECN 8 +#define TCPI_OPT_SACK 2 +#define TCPI_OPT_TIMESTAMPS 1 +#define TCPI_OPT_WSCALE 4 +#define TCPOLEN_MAXSEG 4 +#define TCPOLEN_SACK_PERMITTED 2 +#define TCPOLEN_TIMESTAMP 10 +#define TCPOLEN_WINDOW 3 +#define TCPOPT_EOL 0 +#define TCPOPT_MAXSEG 2 +#define TCPOPT_NOP 1 +#define TCPOPT_SACK 5 +#define TCPOPT_SACK_PERMITTED 4 +#define TCPOPT_TIMESTAMP 8 +#define TCPOPT_WINDOW 3 +#define TCP_CA_CWR 2 +#define TCP_CA_Disorder 1 +#define TCP_CA_Loss 4 +#define TCP_CA_Open 0 +#define TCP_CA_Recovery 3 +#define TCP_CC_INFO 26 +#define TCP_CLOSE 7 +#define TCP_CLOSE_WAIT 8 +#define TCP_CLOSING 11 +#define TCP_CM_INQ TCP_INQ +#define TCP_CONGESTION 13 +#define TCP_CORK 3 +#define TCP_DEFER_ACCEPT 9 +#define TCP_ENCAP_ESPINTCP 7 +#define TCP_ESTABLISHED 1 +#define TCP_FASTOPEN 23 +#define TCP_FASTOPEN_CONNECT 30 +#define TCP_FASTOPEN_KEY 33 +#define TCP_FASTOPEN_NO_COOKIE 34 +#define TCP_FIN_WAIT1 4 +#define TCP_FIN_WAIT2 5 +#define TCP_INFO 11 +#define TCP_INQ 36 +#define TCP_KEEPCNT 6 +#define TCP_KEEPIDLE 4 +#define TCP_KEEPINTVL 5 +#define TCP_LAST_ACK 9 +#define TCP_LINGER2 8 +#define TCP_LISTEN 10 +#define TCP_MAXSEG 2 +#define TCP_MD5SIG 14 +#define TCP_MD5SIG_EXT 32 +#define TCP_MD5SIG_FLAG_IFINDEX 0x2 +#define TCP_MD5SIG_FLAG_PREFIX 0x1 +#define TCP_MD5SIG_MAXKEYLEN 80 +#define TCP_NODELAY 1 +#define TCP_NOTSENT_LOWAT 25 +#define TCP_QUEUE_SEQ 21 +#define TCP_QUICKACK 12 +#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 +#define TCP_REPAIR 19 +#define TCP_REPAIR_OFF 0 +#define TCP_REPAIR_OFF_NO_WP -1 +#define TCP_REPAIR_ON 1 +#define TCP_REPAIR_OPTIONS 22 +#define TCP_REPAIR_QUEUE 20 +#define TCP_REPAIR_WINDOW 29 +#define TCP_SAVED_SYN 28 +#define TCP_SAVE_SYN 27 +#define TCP_SYNCNT 7 +#define TCP_SYN_RECV 3 +#define TCP_SYN_SENT 2 +#define TCP_THIN_DUPACK 17 +#define TCP_THIN_LINEAR_TIMEOUTS 16 +#define TCP_TIMESTAMP 24 +#define TCP_TIME_WAIT 6 +#define TCP_TX_DELAY 37 +#define TCP_ULP 31 +#define TCP_USER_TIMEOUT 18 +#define TCP_WINDOW_CLAMP 10 +#define TCP_ZEROCOPY_RECEIVE 35 +#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] +#define TELCMD_FIRST xEOF +#define TELCMD_LAST IAC +#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) +#define TELOPT_3270REGIME 29 +#define TELOPT_AUTHENTICATION 37 +#define TELOPT_BINARY 0 +#define TELOPT_BM 19 +#define TELOPT_DET 20 +#define TELOPT_ECHO 1 +#define TELOPT_ENCRYPT 38 +#define TELOPT_EOR 25 +#define TELOPT_EXOPL 255 +#define TELOPT_LFLOW 33 +#define TELOPT_LINEMODE 34 +#define TELOPT_LOGOUT 18 +#define TELOPT_NAMS 4 +#define TELOPT_NAOCRD 10 +#define TELOPT_NAOFFD 13 +#define TELOPT_NAOHTD 12 +#define TELOPT_NAOHTS 11 +#define TELOPT_NAOL 8 +#define TELOPT_NAOLFD 16 +#define TELOPT_NAOP 9 +#define TELOPT_NAOVTD 15 +#define TELOPT_NAOVTS 14 +#define TELOPT_NAWS 31 +#define TELOPT_NEW_ENVIRON 39 +#define TELOPT_OLD_ENVIRON 36 +#define TELOPT_OUTMRK 27 +#define TELOPT_RCP 2 +#define TELOPT_RCTE 7 +#define TELOPT_SGA 3 +#define TELOPT_SNDLOC 23 +#define TELOPT_STATUS 5 +#define TELOPT_SUPDUP 21 +#define TELOPT_SUPDUPOUTPUT 22 +#define TELOPT_TM 6 +#define TELOPT_TSPEED 32 +#define TELOPT_TTYLOC 28 +#define TELOPT_TTYPE 24 +#define TELOPT_TUID 26 +#define TELOPT_X3PAD 30 +#define TELOPT_XASCII 17 +#define TELOPT_XDISPLOC 35 +#define TELQUAL_INFO 2 +#define TELQUAL_IS 0 +#define TELQUAL_NAME 3 +#define TELQUAL_REPLY 2 +#define TELQUAL_SEND 1 +#define TGEXEC 00010 +#define TGREAD 00040 +#define TGWRITE 00020 +#define THOUSEP 0x10001 +#define TH_ACK 0x10 +#define TH_FIN 0x01 +#define TH_PUSH 0x08 +#define TH_RST 0x04 +#define TH_SYN 0x02 +#define TH_URG 0x20 +#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME +#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) +#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) +#define TIME_BAD TIME_ERROR +#define TIME_DEL 2 +#define TIME_ERROR 5 +#define TIME_INS 1 +#define TIME_OK 0 +#define TIME_OOP 3 +#define TIME_UTC 1 +#define TIME_WAIT 4 +#define TMAGIC "ustar" +#define TMAGLEN 6 +#define TOEXEC 00001 +#define TOREAD 00004 +#define TOWRITE 00002 +#define TRANSIENT 4 +#define TSGID 02000 +#define TSS_DTOR_ITERATIONS 4 +#define TSUID 04000 +#define TSVTX 01000 +#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) +#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) +#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) +#define TTYDEF_SPEED (B9600) +#define TTY_NAME_MAX 32 +#define TUEXEC 00100 +#define TUREAD 00400 +#define TUWRITE 00200 +#define TVERSION "00" +#define TVERSLEN 2 +#define TYPE_A 1 +#define TYPE_E 2 +#define TYPE_I 3 +#define TYPE_L 4 +#define TZNAME_MAX 6 +#define T_A ns_t_a +#define T_A6 ns_t_a6 +#define T_AAAA ns_t_aaaa +#define T_AFSDB ns_t_afsdb +#define T_ANY ns_t_any +#define T_ATMA ns_t_atma +#define T_AXFR ns_t_axfr +#define T_CNAME ns_t_cname +#define T_DNAME ns_t_dname +#define T_EID ns_t_eid +#define T_FMT 0x2002A +#define T_FMT_AMPM 0x2002B +#define T_GPOS ns_t_gpos +#define T_HINFO ns_t_hinfo +#define T_ISDN ns_t_isdn +#define T_IXFR ns_t_ixfr +#define T_KEY ns_t_key +#define T_LOC ns_t_loc +#define T_MAILA ns_t_maila +#define T_MAILB ns_t_mailb +#define T_MB ns_t_mb +#define T_MD ns_t_md +#define T_MF ns_t_mf +#define T_MG ns_t_mg +#define T_MINFO ns_t_minfo +#define T_MR ns_t_mr +#define T_MX ns_t_mx +#define T_NAPTR ns_t_naptr +#define T_NIMLOC ns_t_nimloc +#define T_NS ns_t_ns +#define T_NSAP ns_t_nsap +#define T_NSAP_PTR ns_t_nsap_ptr +#define T_NULL ns_t_null +#define T_NXT ns_t_nxt +#define T_PTR ns_t_ptr +#define T_PX ns_t_px +#define T_RP ns_t_rp +#define T_RT ns_t_rt +#define T_SIG ns_t_sig +#define T_SOA ns_t_soa +#define T_SRV ns_t_srv +#define T_TSIG ns_t_tsig +#define T_TXT ns_t_txt +#define T_WKS ns_t_wks +#define T_X25 ns_t_x25 +#define UCHAR_MAX 255 +#define UDP_CORK 1 +#define UDP_ENCAP 100 +#define UDP_ENCAP_ESPINUDP 2 +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 +#define UDP_ENCAP_GTP0 4 +#define UDP_ENCAP_GTP1U 5 +#define UDP_ENCAP_L2TPINUDP 3 +#define UDP_ENCAP_RXRPC 6 +#define UDP_GRO 104 +#define UDP_NO_CHECK6_RX 102 +#define UDP_NO_CHECK6_TX 101 +#define UDP_SEGMENT 103 +#define UINT16_C(c) c +#define UINT16_MAX (0xffff) +#define UINT32_C(c) c ## U +#define UINT32_MAX (0xffffffffu) +#define UINT64_C(c) c ## ULL +#define UINT64_MAX (0xffffffffffffffffu) +#define UINT8_C(c) c +#define UINT8_MAX (0xff) +#define UINTMAX_C(c) c ## ULL +#define UINTMAX_MAX UINT64_MAX +#define UINTPTR_MAX UINT32_MAX +#define UINT_FAST16_MAX UINT16_MAX +#define UINT_FAST32_MAX UINT32_MAX +#define UINT_FAST64_MAX UINT64_MAX +#define UINT_FAST8_MAX UINT8_MAX +#define UINT_LEAST16_MAX UINT16_MAX +#define UINT_LEAST32_MAX UINT32_MAX +#define UINT_LEAST64_MAX UINT64_MAX +#define UINT_LEAST8_MAX UINT8_MAX +#define UINT_MAX 0xffffffffU +#define UIO_MAXIOV 1024 +#define ULLONG_MAX (2ULL*LLONG_MAX+1) +#define ULONG_MAX (2UL*LONG_MAX+1) +#define USHRT_MAX 0xffff +#define UTIME_NOW (-1) +#define UTIME_OMIT (-2) +#define WCHAR_MAX (0x7fffffff+L'\0') +#define WCHAR_MIN (-1-0x7fffffff+L'\0') +#define WEOF 0xffffffffU +#define WILL 251 +#define WINT_MAX UINT32_MAX +#define WINT_MIN 0U +#define WONT 252 +#define WORD_BIT 32 +#define WRQ 02 +#define W_OK (2) +#define X_OK (1) +#define YESEXPR 0x50000 +#define YESSTR 0x50002 +#define YXDOMAIN ns_r_yxdomain +#define YXRRSET ns_r_yxrrset +#define _ALLOCA_H +#define _ALL_SOURCE 1 +#define _ARPA_FTP_H +#define _ARPA_INET_H +#define _ARPA_NAMESER_H +#define _ARPA_TELNET_H +#define _ARPA_TFTP_H +#define _AR_H +#define _BYTESWAP_H +#define _COMPLEX_H +#define _CPIO_H +#define _CRYPT_H +#define _CS_GNU_LIBC_VERSION 2 +#define _CS_GNU_LIBPTHREAD_VERSION 3 +#define _CS_PATH 0 +#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 +#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 +#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 +#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 +#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 +#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 +#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 +#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 +#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 +#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 +#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 +#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 +#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 +#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 +#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 +#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 +#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 +#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 +#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 +#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 +#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 +#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 +#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 +#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 +#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 +#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 +#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 +#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 +#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 +#define _CS_V6_ENV 1148 +#define _CS_V7_ENV 1149 +#define _CTYPE_H +#define _Complex_I (0.0f+1.0fi) +#define _DIRENT_H +#define _DIRENT_HAVE_D_TYPE +#define _ENDIAN_H +#define _ERRNO_H +#define _ERR_H +#define _FCNTL_H +#define _FEATURES_H +#define _FENV_H +#define _FLOAT_H +#define _FMTMSG_H +#define _FNMATCH_H +#define _FTW_H +#define _GETOPT_H +#define _GLOB_H +#define _GNU_SOURCE 1 +#define _ICONV_H +#define _IFADDRS_H +#define _INTTYPES_H +#define _IOFBF 0 +#define _IOLBF 1 +#define _IONBF 2 +#define _ISO646_H +#define _LANGINFO_H +#define _LIBGEN_H +#define _LIMITS_H +#define _LOCALE_H +#define _LP64 1 +#define _MALLOC_H +#define _MATH_H +#define _MONETARY_H +#define _MQUEUE_H +#define _NETINET_ICMP6_H +#define _NETINET_IGMP_H +#define _NETINET_IN_H +#define _NETINET_IN_SYSTM_H +#define _NETINET_IP6_H +#define _NETINET_IP_H +#define _NETINET_IP_ICMP_H +#define _NETINET_TCP_H +#define _NETINET_UDP_H +#define _NETPACKET_PACKET_H +#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) +#define _NL_TYPES_H +#define _PC_2_SYMLINKS 20 +#define _PC_ALLOC_SIZE_MIN 18 +#define _PC_ASYNC_IO 10 +#define _PC_CHOWN_RESTRICTED 6 +#define _PC_FILESIZEBITS 13 +#define _PC_LINK_MAX 0 +#define _PC_MAX_CANON 1 +#define _PC_MAX_INPUT 2 +#define _PC_NAME_MAX 3 +#define _PC_NO_TRUNC 7 +#define _PC_PATH_MAX 4 +#define _PC_PIPE_BUF 5 +#define _PC_PRIO_IO 11 +#define _PC_REC_INCR_XFER_SIZE 14 +#define _PC_REC_MAX_XFER_SIZE 15 +#define _PC_REC_MIN_XFER_SIZE 16 +#define _PC_REC_XFER_ALIGN 17 +#define _PC_SOCK_MAXBUF 12 +#define _PC_SYMLINK_MAX 19 +#define _PC_SYNC_IO 9 +#define _PC_VDISABLE 8 +#define _POLL_H +#define _POSIX2_BC_BASE_MAX 99 +#define _POSIX2_BC_DIM_MAX 2048 +#define _POSIX2_BC_SCALE_MAX 99 +#define _POSIX2_BC_STRING_MAX 1000 +#define _POSIX2_CHARCLASS_NAME_MAX 14 +#define _POSIX2_COLL_WEIGHTS_MAX 2 +#define _POSIX2_C_BIND _POSIX_VERSION +#define _POSIX2_EXPR_NEST_MAX 32 +#define _POSIX2_LINE_MAX 2048 +#define _POSIX2_RE_DUP_MAX 255 +#define _POSIX2_VERSION _POSIX_VERSION +#define _POSIX_ADVISORY_INFO _POSIX_VERSION +#define _POSIX_AIO_LISTIO_MAX 2 +#define _POSIX_AIO_MAX 1 +#define _POSIX_ARG_MAX 4096 +#define _POSIX_BARRIERS _POSIX_VERSION +#define _POSIX_CHILD_MAX 25 +#define _POSIX_CHOWN_RESTRICTED 1 +#define _POSIX_CLOCKRES_MIN 20000000 +#define _POSIX_CLOCK_SELECTION _POSIX_VERSION +#define _POSIX_CPUTIME _POSIX_VERSION +#define _POSIX_DELAYTIMER_MAX 32 +#define _POSIX_FSYNC _POSIX_VERSION +#define _POSIX_HOST_NAME_MAX 255 +#define _POSIX_IPV6 _POSIX_VERSION +#define _POSIX_LINK_MAX 8 +#define _POSIX_LOGIN_NAME_MAX 9 +#define _POSIX_MAX_CANON 255 +#define _POSIX_MAX_INPUT 255 +#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION +#define _POSIX_MQ_OPEN_MAX 8 +#define _POSIX_MQ_PRIO_MAX 32 +#define _POSIX_NAME_MAX 14 +#define _POSIX_NGROUPS_MAX 8 +#define _POSIX_NO_TRUNC 1 +#define _POSIX_OPEN_MAX 20 +#define _POSIX_PATH_MAX 256 +#define _POSIX_PIPE_BUF 512 +#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION +#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION +#define _POSIX_REGEXP 1 +#define _POSIX_RE_DUP_MAX 255 +#define _POSIX_RTSIG_MAX 8 +#define _POSIX_SEM_NSEMS_MAX 256 +#define _POSIX_SEM_VALUE_MAX 32767 +#define _POSIX_SIGQUEUE_MAX 32 +#define _POSIX_SPIN_LOCKS _POSIX_VERSION +#define _POSIX_SSIZE_MAX 32767 +#define _POSIX_SS_REPL_MAX 4 +#define _POSIX_STREAM_MAX 8 +#define _POSIX_SYMLINK_MAX 255 +#define _POSIX_SYMLOOP_MAX 8 +#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION +#define _POSIX_THREAD_CPUTIME _POSIX_VERSION +#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 +#define _POSIX_THREAD_KEYS_MAX 128 +#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION +#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION +#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION +#define _POSIX_THREAD_THREADS_MAX 64 +#define _POSIX_TIMEOUTS _POSIX_VERSION +#define _POSIX_TIMERS _POSIX_VERSION +#define _POSIX_TIMER_MAX 32 +#define _POSIX_TRACE_EVENT_NAME_MAX 30 +#define _POSIX_TRACE_NAME_MAX 8 +#define _POSIX_TRACE_SYS_MAX 8 +#define _POSIX_TRACE_USER_EVENT_MAX 32 +#define _POSIX_TTY_NAME_MAX 9 +#define _POSIX_TZNAME_MAX 6 +#define _POSIX_V6_ILP32_OFFBIG (1) +#define _POSIX_V7_ILP32_OFFBIG (1) +#define _POSIX_VDISABLE 0 +#define _POSIX_VERSION 200809L +#define _PTRDIFF_T +#define _REGEX_H +#define _SCHED_H +#define _SC_2_CHAR_TERM 95 +#define _SC_2_C_BIND 47 +#define _SC_2_C_DEV 48 +#define _SC_2_FORT_DEV 49 +#define _SC_2_FORT_RUN 50 +#define _SC_2_LOCALEDEF 52 +#define _SC_2_PBS 168 +#define _SC_2_PBS_ACCOUNTING 169 +#define _SC_2_PBS_CHECKPOINT 175 +#define _SC_2_PBS_LOCATE 170 +#define _SC_2_PBS_MESSAGE 171 +#define _SC_2_PBS_TRACK 172 +#define _SC_2_SW_DEV 51 +#define _SC_2_UPE 97 +#define _SC_2_VERSION 46 +#define _SC_ADVISORY_INFO 132 +#define _SC_AIO_LISTIO_MAX 23 +#define _SC_AIO_MAX 24 +#define _SC_AIO_PRIO_DELTA_MAX 25 +#define _SC_ARG_MAX 0 +#define _SC_ASYNCHRONOUS_IO 12 +#define _SC_ATEXIT_MAX 87 +#define _SC_AVPHYS_PAGES 86 +#define _SC_BARRIERS 133 +#define _SC_BC_BASE_MAX 36 +#define _SC_BC_DIM_MAX 37 +#define _SC_BC_SCALE_MAX 38 +#define _SC_BC_STRING_MAX 39 +#define _SC_CHILD_MAX 1 +#define _SC_CLK_TCK 2 +#define _SC_CLOCK_SELECTION 137 +#define _SC_COLL_WEIGHTS_MAX 40 +#define _SC_CPUTIME 138 +#define _SC_DELAYTIMER_MAX 26 +#define _SC_EXPR_NEST_MAX 42 +#define _SC_FSYNC 15 +#define _SC_GETGR_R_SIZE_MAX 69 +#define _SC_GETPW_R_SIZE_MAX 70 +#define _SC_HOST_NAME_MAX 180 +#define _SC_IOV_MAX 60 +#define _SC_IPV6 235 +#define _SC_JOB_CONTROL 7 +#define _SC_LINE_MAX 43 +#define _SC_LOGIN_NAME_MAX 71 +#define _SC_MAPPED_FILES 16 +#define _SC_MEMLOCK 17 +#define _SC_MEMLOCK_RANGE 18 +#define _SC_MEMORY_PROTECTION 19 +#define _SC_MESSAGE_PASSING 20 +#define _SC_MONOTONIC_CLOCK 149 +#define _SC_MQ_OPEN_MAX 27 +#define _SC_MQ_PRIO_MAX 28 +#define _SC_NGROUPS_MAX 3 +#define _SC_NPROCESSORS_CONF 83 +#define _SC_NPROCESSORS_ONLN 84 +#define _SC_NZERO 109 +#define _SC_OPEN_MAX 4 +#define _SC_PAGESIZE 30 +#define _SC_PAGE_SIZE 30 +#define _SC_PASS_MAX 88 +#define _SC_PHYS_PAGES 85 +#define _SC_PRIORITIZED_IO 13 +#define _SC_PRIORITY_SCHEDULING 10 +#define _SC_RAW_SOCKETS 236 +#define _SC_READER_WRITER_LOCKS 153 +#define _SC_REALTIME_SIGNALS 9 +#define _SC_REGEXP 155 +#define _SC_RE_DUP_MAX 44 +#define _SC_RTSIG_MAX 31 +#define _SC_SAVED_IDS 8 +#define _SC_SEMAPHORES 21 +#define _SC_SEM_NSEMS_MAX 32 +#define _SC_SEM_VALUE_MAX 33 +#define _SC_SHARED_MEMORY_OBJECTS 22 +#define _SC_SHELL 157 +#define _SC_SIGQUEUE_MAX 34 +#define _SC_SPAWN 159 +#define _SC_SPIN_LOCKS 154 +#define _SC_SPORADIC_SERVER 160 +#define _SC_SS_REPL_MAX 241 +#define _SC_STREAMS 174 +#define _SC_STREAM_MAX 5 +#define _SC_SYMLOOP_MAX 173 +#define _SC_SYNCHRONIZED_IO 14 +#define _SC_THREADS 67 +#define _SC_THREAD_ATTR_STACKADDR 77 +#define _SC_THREAD_ATTR_STACKSIZE 78 +#define _SC_THREAD_CPUTIME 139 +#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 +#define _SC_THREAD_KEYS_MAX 74 +#define _SC_THREAD_PRIORITY_SCHEDULING 79 +#define _SC_THREAD_PRIO_INHERIT 80 +#define _SC_THREAD_PRIO_PROTECT 81 +#define _SC_THREAD_PROCESS_SHARED 82 +#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 +#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 +#define _SC_THREAD_SAFE_FUNCTIONS 68 +#define _SC_THREAD_SPORADIC_SERVER 161 +#define _SC_THREAD_STACK_MIN 75 +#define _SC_THREAD_THREADS_MAX 76 +#define _SC_TIMEOUTS 164 +#define _SC_TIMERS 11 +#define _SC_TIMER_MAX 35 +#define _SC_TRACE 181 +#define _SC_TRACE_EVENT_FILTER 182 +#define _SC_TRACE_EVENT_NAME_MAX 242 +#define _SC_TRACE_INHERIT 183 +#define _SC_TRACE_LOG 184 +#define _SC_TRACE_NAME_MAX 243 +#define _SC_TRACE_SYS_MAX 244 +#define _SC_TRACE_USER_EVENT_MAX 245 +#define _SC_TTY_NAME_MAX 72 +#define _SC_TYPED_MEMORY_OBJECTS 165 +#define _SC_TZNAME_MAX 6 +#define _SC_UIO_MAXIOV 60 +#define _SC_V6_ILP32_OFF32 176 +#define _SC_V6_ILP32_OFFBIG 177 +#define _SC_V6_LP64_OFF64 178 +#define _SC_V6_LPBIG_OFFBIG 179 +#define _SC_V7_ILP32_OFF32 237 +#define _SC_V7_ILP32_OFFBIG 238 +#define _SC_V7_LP64_OFF64 239 +#define _SC_V7_LPBIG_OFFBIG 240 +#define _SC_VERSION 29 +#define _SC_XBS5_ILP32_OFF32 125 +#define _SC_XBS5_ILP32_OFFBIG 126 +#define _SC_XBS5_LP64_OFF64 127 +#define _SC_XBS5_LPBIG_OFFBIG 128 +#define _SC_XOPEN_CRYPT 92 +#define _SC_XOPEN_ENH_I18N 93 +#define _SC_XOPEN_LEGACY 129 +#define _SC_XOPEN_REALTIME 130 +#define _SC_XOPEN_REALTIME_THREADS 131 +#define _SC_XOPEN_SHM 94 +#define _SC_XOPEN_STREAMS 246 +#define _SC_XOPEN_UNIX 91 +#define _SC_XOPEN_VERSION 89 +#define _SC_XOPEN_XCU_VERSION 90 +#define _SC_XOPEN_XPG2 98 +#define _SC_XOPEN_XPG3 99 +#define _SC_XOPEN_XPG4 100 +#define _SEARCH_H +#define _SEMAPHORE_H +#define _SIZE_T +#define _STDALIGN_H +#define _STDBOOL_H +#define _STDC_PREDEF_H +#define _STDINT_H +#define _STDIO_EXT_H +#define _STDIO_H +#define _STDLIB_H +#define _STDNORETURN_H +#define _STRINGS_H +#define _STRING_H +#define _STROPTS_H +#define _SYSEXITS_H +#define _SYS_EVENTFD_H +#define _SYS_FILE_H +#define _SYS_IOCTL_H +#define _SYS_PARAM_H +#define _SYS_RANDOM_H +#define _SYS_REG_H +#define _SYS_SELECT_H +#define _SYS_SOCKET_H +#define _SYS_STAT_H +#define _SYS_SYSCALL_H +#define _SYS_SYSINFO_H +#define _SYS_TIMEB_H +#define _SYS_TIMEX_H +#define _SYS_TIME_H +#define _SYS_TTYDEFAULTS_H +#define _SYS_TYPES_H +#define _SYS_UIO_H +#define _SYS_UN_H +#define _SYS_UTSNAME_H +#define _TAR_H +#define _TGMATH_H +#define _THREADS_H +#define _TIME_H +#define _UCHAR_H +#define _UNISTD_H +#define _UTIME_H +#define _VALUES_H +#define _VA_LIST +#define _WCHAR_H +#define _WCHAR_T +#define _WCTYPE_H +#define _WINT_T +#define _XOPEN_ENH_I18N 1 +#define _XOPEN_IOV_MAX 16 +#define _XOPEN_NAME_MAX 255 +#define _XOPEN_PATH_MAX 1024 +#define _XOPEN_UNIX 1 +#define _XOPEN_VERSION 700 +#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) +#define __ATOMIC_ACQUIRE 2 +#define __ATOMIC_ACQ_REL 4 +#define __ATOMIC_CONSUME 1 +#define __ATOMIC_RELAXED 0 +#define __ATOMIC_RELEASE 3 +#define __ATOMIC_SEQ_CST 5 +#define __BIGGEST_ALIGNMENT__ 16 +#define __BIG_ENDIAN 4321 +#define __BIND 19950621 +#define __BYTE_ORDER __BYTE_ORDER__ +#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ +#define __CHAR16_TYPE__ unsigned short +#define __CHAR32_TYPE__ unsigned int +#define __CHAR_BIT__ 8 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __CLANG_MAX_ALIGN_T_DEFINED +#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) +#define __CONSTANT_CFSTRINGS__ 1 +#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) +#define __DBL_DECIMAL_DIG__ 17 +#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 +#define __DBL_DIG__ 15 +#define __DBL_EPSILON__ 2.2204460492503131e-16 +#define __DBL_HAS_DENORM__ 1 +#define __DBL_HAS_INFINITY__ 1 +#define __DBL_HAS_QUIET_NAN__ 1 +#define __DBL_MANT_DIG__ 53 +#define __DBL_MAX_10_EXP__ 308 +#define __DBL_MAX_EXP__ 1024 +#define __DBL_MAX__ 1.7976931348623157e+308 +#define __DBL_MIN_10_EXP__ (-307) +#define __DBL_MIN_EXP__ (-1021) +#define __DBL_MIN__ 2.2250738585072014e-308 +#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ +#define __DEFINED_FILE +#define __DEFINED___isoc_va_list +#define __DEFINED_blkcnt_t +#define __DEFINED_blksize_t +#define __DEFINED_clock_t +#define __DEFINED_clockid_t +#define __DEFINED_cnd_t +#define __DEFINED_dev_t +#define __DEFINED_double_t +#define __DEFINED_float_t +#define __DEFINED_fsblkcnt_t +#define __DEFINED_fsfilcnt_t +#define __DEFINED_gid_t +#define __DEFINED_id_t +#define __DEFINED_ino_t +#define __DEFINED_int16_t +#define __DEFINED_int32_t +#define __DEFINED_int64_t +#define __DEFINED_int8_t +#define __DEFINED_intmax_t +#define __DEFINED_intptr_t +#define __DEFINED_key_t +#define __DEFINED_locale_t +#define __DEFINED_mbstate_t +#define __DEFINED_mode_t +#define __DEFINED_mtx_t +#define __DEFINED_nlink_t +#define __DEFINED_off_t +#define __DEFINED_pid_t +#define __DEFINED_pthread_attr_t +#define __DEFINED_pthread_barrier_t +#define __DEFINED_pthread_barrierattr_t +#define __DEFINED_pthread_cond_t +#define __DEFINED_pthread_condattr_t +#define __DEFINED_pthread_key_t +#define __DEFINED_pthread_mutex_t +#define __DEFINED_pthread_mutexattr_t +#define __DEFINED_pthread_once_t +#define __DEFINED_pthread_rwlock_t +#define __DEFINED_pthread_rwlockattr_t +#define __DEFINED_pthread_spinlock_t +#define __DEFINED_pthread_t +#define __DEFINED_register_t +#define __DEFINED_regoff_t +#define __DEFINED_sa_family_t +#define __DEFINED_sigset_t +#define __DEFINED_size_t +#define __DEFINED_socklen_t +#define __DEFINED_ssize_t +#define __DEFINED_suseconds_t +#define __DEFINED_time_t +#define __DEFINED_timer_t +#define __DEFINED_u_int64_t +#define __DEFINED_uid_t +#define __DEFINED_uint16_t +#define __DEFINED_uint32_t +#define __DEFINED_uint64_t +#define __DEFINED_uint8_t +#define __DEFINED_uintmax_t +#define __DEFINED_uintptr_t +#define __DEFINED_useconds_t +#define __DEFINED_va_list +#define __DEFINED_wchar_t +#define __DEFINED_wctype_t +#define __DEFINED_wint_t +#define __FINITE_MATH_ONLY__ 0 +#define __FLOAT128__ 1 +#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) +#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) +#define __FLT_DECIMAL_DIG__ 9 +#define __FLT_DENORM_MIN__ 1.40129846e-45F +#define __FLT_DIG__ 6 +#define __FLT_EPSILON__ 1.19209290e-7F +#define __FLT_HAS_DENORM__ 1 +#define __FLT_HAS_INFINITY__ 1 +#define __FLT_HAS_QUIET_NAN__ 1 +#define __FLT_MANT_DIG__ 24 +#define __FLT_MAX_10_EXP__ 38 +#define __FLT_MAX_EXP__ 128 +#define __FLT_MAX__ 3.40282347e+38F +#define __FLT_MIN_10_EXP__ (-37) +#define __FLT_MIN_EXP__ (-125) +#define __FLT_MIN__ 1.17549435e-38F +#define __FLT_RADIX__ 2 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __GNUC_STDC_INLINE__ 1 +#define __GNUC_VA_LIST 1 +#define __GXX_ABI_VERSION 1002 +#define __INT16_C_SUFFIX__ +#define __INT16_FMTd__ "hd" +#define __INT16_FMTi__ "hi" +#define __INT16_MAX__ 32767 +#define __INT16_TYPE__ short +#define __INT32_C_SUFFIX__ +#define __INT32_FMTd__ "d" +#define __INT32_FMTi__ "i" +#define __INT32_MAX__ 2147483647 +#define __INT32_TYPE__ int +#define __INT64_C_SUFFIX__ LL +#define __INT64_FMTd__ "lld" +#define __INT64_FMTi__ "lli" +#define __INT64_MAX__ 9223372036854775807LL +#define __INT64_TYPE__ long long int +#define __INT8_C_SUFFIX__ +#define __INT8_FMTd__ "hhd" +#define __INT8_FMTi__ "hhi" +#define __INT8_MAX__ 127 +#define __INT8_TYPE__ signed char +#define __INTMAX_C_SUFFIX__ LL +#define __INTMAX_FMTd__ "lld" +#define __INTMAX_FMTi__ "lli" +#define __INTMAX_MAX__ 9223372036854775807LL +#define __INTMAX_TYPE__ long long int +#define __INTMAX_WIDTH__ 64 +#define __INTPTR_FMTd__ "ld" +#define __INTPTR_FMTi__ "li" +#define __INTPTR_MAX__ 9223372036854775807L +#define __INTPTR_TYPE__ long int +#define __INTPTR_WIDTH__ 64 +#define __INT_FAST16_FMTd__ "hd" +#define __INT_FAST16_FMTi__ "hi" +#define __INT_FAST16_MAX__ 32767 +#define __INT_FAST16_TYPE__ short +#define __INT_FAST32_FMTd__ "d" +#define __INT_FAST32_FMTi__ "i" +#define __INT_FAST32_MAX__ 2147483647 +#define __INT_FAST32_TYPE__ int +#define __INT_FAST64_FMTd__ "lld" +#define __INT_FAST64_FMTi__ "lli" +#define __INT_FAST64_MAX__ 9223372036854775807LL +#define __INT_FAST64_TYPE__ long long int +#define __INT_FAST8_FMTd__ "hhd" +#define __INT_FAST8_FMTi__ "hhi" +#define __INT_FAST8_MAX__ 127 +#define __INT_FAST8_TYPE__ signed char +#define __INT_LEAST16_FMTd__ "hd" +#define __INT_LEAST16_FMTi__ "hi" +#define __INT_LEAST16_MAX__ 32767 +#define __INT_LEAST16_TYPE__ short +#define __INT_LEAST32_FMTd__ "d" +#define __INT_LEAST32_FMTi__ "i" +#define __INT_LEAST32_MAX__ 2147483647 +#define __INT_LEAST32_TYPE__ int +#define __INT_LEAST64_FMTd__ "lld" +#define __INT_LEAST64_FMTi__ "lli" +#define __INT_LEAST64_MAX__ 9223372036854775807LL +#define __INT_LEAST64_TYPE__ long long int +#define __INT_LEAST8_FMTd__ "hhd" +#define __INT_LEAST8_FMTi__ "hhi" +#define __INT_LEAST8_MAX__ 127 +#define __INT_LEAST8_TYPE__ signed char +#define __INT_MAX__ 2147483647 +#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) +#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) +#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) +#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) +#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) +#define __LDBL_DECIMAL_DIG__ 36 +#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L +#define __LDBL_DIG__ 33 +#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L +#define __LDBL_HAS_DENORM__ 1 +#define __LDBL_HAS_INFINITY__ 1 +#define __LDBL_HAS_QUIET_NAN__ 1 +#define __LDBL_MANT_DIG__ 113 +#define __LDBL_MAX_10_EXP__ 4932 +#define __LDBL_MAX_EXP__ 16384 +#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L +#define __LDBL_MIN_10_EXP__ (-4931) +#define __LDBL_MIN_EXP__ (-16381) +#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L +#define __LITTLE_ENDIAN 1234 +#define __LITTLE_ENDIAN__ 1 +#define __LONG_LONG_MAX__ 9223372036854775807LL +#define __LONG_MAX __LONG_MAX__ +#define __LONG_MAX__ 9223372036854775807L +#define __LP64__ 1 +#define __NAMESER 19991006 +#define __NEED_FILE +#define __NEED___isoc_va_list +#define __NEED_blkcnt_t +#define __NEED_blksize_t +#define __NEED_clock_t +#define __NEED_clockid_t +#define __NEED_cnd_t +#define __NEED_dev_t +#define __NEED_double_t +#define __NEED_float_t +#define __NEED_fsblkcnt_t +#define __NEED_fsfilcnt_t +#define __NEED_gid_t +#define __NEED_id_t +#define __NEED_ino_t +#define __NEED_int16_t +#define __NEED_int32_t +#define __NEED_int64_t +#define __NEED_int8_t +#define __NEED_intmax_t +#define __NEED_intptr_t +#define __NEED_key_t +#define __NEED_locale_t +#define __NEED_mbstate_t +#define __NEED_mode_t +#define __NEED_mtx_t +#define __NEED_nlink_t +#define __NEED_off_t +#define __NEED_pid_t +#define __NEED_pthread_attr_t +#define __NEED_pthread_barrier_t +#define __NEED_pthread_barrierattr_t +#define __NEED_pthread_cond_t +#define __NEED_pthread_condattr_t +#define __NEED_pthread_key_t +#define __NEED_pthread_mutex_t +#define __NEED_pthread_mutexattr_t +#define __NEED_pthread_once_t +#define __NEED_pthread_rwlock_t +#define __NEED_pthread_rwlockattr_t +#define __NEED_pthread_spinlock_t +#define __NEED_pthread_t +#define __NEED_register_t +#define __NEED_regoff_t +#define __NEED_sa_family_t +#define __NEED_sigset_t +#define __NEED_size_t +#define __NEED_socklen_t +#define __NEED_ssize_t +#define __NEED_struct_iovec +#define __NEED_struct_timespec +#define __NEED_struct_timeval +#define __NEED_suseconds_t +#define __NEED_time_t +#define __NEED_timer_t +#define __NEED_u_int64_t +#define __NEED_uid_t +#define __NEED_uint16_t +#define __NEED_uint32_t +#define __NEED_uint64_t +#define __NEED_uint8_t +#define __NEED_uintmax_t +#define __NEED_uintptr_t +#define __NEED_useconds_t +#define __NEED_va_list +#define __NEED_wchar_t +#define __NEED_wctype_t +#define __NEED_wint_t +#define __OBJC_BOOL_IS_BOOL 0 +#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 +#define __OPENCL_MEMORY_SCOPE_DEVICE 2 +#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 +#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 +#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 +#define __ORDER_BIG_ENDIAN__ 4321 +#define __ORDER_LITTLE_ENDIAN__ 1234 +#define __ORDER_PDP_ENDIAN__ 3412 +#define __PDP_ENDIAN 3412 +#define __POINTER_WIDTH__ 64 +#define __PRAGMA_REDEFINE_EXTNAME 1 +#define __PTRDIFF_FMTd__ "ld" +#define __PTRDIFF_FMTi__ "li" +#define __PTRDIFF_MAX__ 9223372036854775807L +#define __PTRDIFF_TYPE__ long int +#define __PTRDIFF_WIDTH__ 64 +#define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#define __RETCAST(x) +#define __RETCAST_2(x,y) +#define __RETCAST_3(x,y,z) +#define __RETCAST_CX(x) +#define __RETCAST_REAL(x) +#define __SCHAR_MAX__ 127 +#define __SHRT_MAX__ 32767 +#define __SID ('S' << 8) +#define __SIG_ATOMIC_MAX__ 9223372036854775807L +#define __SIG_ATOMIC_WIDTH__ 64 +#define __SIZEOF_DOUBLE__ 8 +#define __SIZEOF_FLOAT__ 4 +#define __SIZEOF_INT128__ 16 +#define __SIZEOF_INT__ 4 +#define __SIZEOF_LONG_DOUBLE__ 16 +#define __SIZEOF_LONG_LONG__ 8 +#define __SIZEOF_LONG__ 8 +#define __SIZEOF_POINTER__ 8 +#define __SIZEOF_PTRDIFF_T__ 8 +#define __SIZEOF_SHORT__ 2 +#define __SIZEOF_SIZE_T__ 8 +#define __SIZEOF_WCHAR_T__ 4 +#define __SIZEOF_WINT_T__ 4 +#define __SIZE_FMTX__ "lX" +#define __SIZE_FMTo__ "lo" +#define __SIZE_FMTu__ "lu" +#define __SIZE_FMTx__ "lx" +#define __SIZE_MAX__ 18446744073709551615UL +#define __SIZE_TYPE__ long unsigned int +#define __SIZE_WIDTH__ 64 +#define __STDARG_H +#define __STDC_HOSTED__ 1 +#define __STDC_IEC_559__ 1 +#define __STDC_ISO_10646__ 201206L +#define __STDC_UTF_16__ 1 +#define __STDC_UTF_32__ 1 +#define __STDC_VERSION__ 201710L +#define __STDC__ 1 +#define __STDDEF_H +#define __UAPI_DEF_IN6_ADDR 0 +#define __UAPI_DEF_IN6_ADDR_ALT 0 +#define __UAPI_DEF_IN6_PKTINFO 0 +#define __UAPI_DEF_IN_ADDR 0 +#define __UAPI_DEF_IN_CLASS 0 +#define __UAPI_DEF_IN_IPPROTO 0 +#define __UAPI_DEF_IN_PKTINFO 0 +#define __UAPI_DEF_IP6_MTUINFO 0 +#define __UAPI_DEF_IPHDR 0 +#define __UAPI_DEF_IPPROTO_V6 0 +#define __UAPI_DEF_IPV6_MREQ 0 +#define __UAPI_DEF_IPV6_OPTIONS 0 +#define __UAPI_DEF_IP_MREQ 0 +#define __UAPI_DEF_SOCKADDR_IN 0 +#define __UAPI_DEF_SOCKADDR_IN6 0 +#define __UINT16_C_SUFFIX__ +#define __UINT16_FMTX__ "hX" +#define __UINT16_FMTo__ "ho" +#define __UINT16_FMTu__ "hu" +#define __UINT16_FMTx__ "hx" +#define __UINT16_MAX__ 65535 +#define __UINT16_TYPE__ unsigned short +#define __UINT32_C_SUFFIX__ U +#define __UINT32_FMTX__ "X" +#define __UINT32_FMTo__ "o" +#define __UINT32_FMTu__ "u" +#define __UINT32_FMTx__ "x" +#define __UINT32_MAX__ 4294967295U +#define __UINT32_TYPE__ unsigned int +#define __UINT64_C_SUFFIX__ ULL +#define __UINT64_FMTX__ "llX" +#define __UINT64_FMTo__ "llo" +#define __UINT64_FMTu__ "llu" +#define __UINT64_FMTx__ "llx" +#define __UINT64_MAX__ 18446744073709551615ULL +#define __UINT64_TYPE__ long long unsigned int +#define __UINT8_C_SUFFIX__ +#define __UINT8_FMTX__ "hhX" +#define __UINT8_FMTo__ "hho" +#define __UINT8_FMTu__ "hhu" +#define __UINT8_FMTx__ "hhx" +#define __UINT8_MAX__ 255 +#define __UINT8_TYPE__ unsigned char +#define __UINTMAX_C_SUFFIX__ ULL +#define __UINTMAX_FMTX__ "llX" +#define __UINTMAX_FMTo__ "llo" +#define __UINTMAX_FMTu__ "llu" +#define __UINTMAX_FMTx__ "llx" +#define __UINTMAX_MAX__ 18446744073709551615ULL +#define __UINTMAX_TYPE__ long long unsigned int +#define __UINTMAX_WIDTH__ 64 +#define __UINTPTR_FMTX__ "lX" +#define __UINTPTR_FMTo__ "lo" +#define __UINTPTR_FMTu__ "lu" +#define __UINTPTR_FMTx__ "lx" +#define __UINTPTR_MAX__ 18446744073709551615UL +#define __UINTPTR_TYPE__ long unsigned int +#define __UINTPTR_WIDTH__ 64 +#define __UINT_FAST16_FMTX__ "hX" +#define __UINT_FAST16_FMTo__ "ho" +#define __UINT_FAST16_FMTu__ "hu" +#define __UINT_FAST16_FMTx__ "hx" +#define __UINT_FAST16_MAX__ 65535 +#define __UINT_FAST16_TYPE__ unsigned short +#define __UINT_FAST32_FMTX__ "X" +#define __UINT_FAST32_FMTo__ "o" +#define __UINT_FAST32_FMTu__ "u" +#define __UINT_FAST32_FMTx__ "x" +#define __UINT_FAST32_MAX__ 4294967295U +#define __UINT_FAST32_TYPE__ unsigned int +#define __UINT_FAST64_FMTX__ "llX" +#define __UINT_FAST64_FMTo__ "llo" +#define __UINT_FAST64_FMTu__ "llu" +#define __UINT_FAST64_FMTx__ "llx" +#define __UINT_FAST64_MAX__ 18446744073709551615ULL +#define __UINT_FAST64_TYPE__ long long unsigned int +#define __UINT_FAST8_FMTX__ "hhX" +#define __UINT_FAST8_FMTo__ "hho" +#define __UINT_FAST8_FMTu__ "hhu" +#define __UINT_FAST8_FMTx__ "hhx" +#define __UINT_FAST8_MAX__ 255 +#define __UINT_FAST8_TYPE__ unsigned char +#define __UINT_LEAST16_FMTX__ "hX" +#define __UINT_LEAST16_FMTo__ "ho" +#define __UINT_LEAST16_FMTu__ "hu" +#define __UINT_LEAST16_FMTx__ "hx" +#define __UINT_LEAST16_MAX__ 65535 +#define __UINT_LEAST16_TYPE__ unsigned short +#define __UINT_LEAST32_FMTX__ "X" +#define __UINT_LEAST32_FMTo__ "o" +#define __UINT_LEAST32_FMTu__ "u" +#define __UINT_LEAST32_FMTx__ "x" +#define __UINT_LEAST32_MAX__ 4294967295U +#define __UINT_LEAST32_TYPE__ unsigned int +#define __UINT_LEAST64_FMTX__ "llX" +#define __UINT_LEAST64_FMTo__ "llo" +#define __UINT_LEAST64_FMTu__ "llu" +#define __UINT_LEAST64_FMTx__ "llx" +#define __UINT_LEAST64_MAX__ 18446744073709551615ULL +#define __UINT_LEAST64_TYPE__ long long unsigned int +#define __UINT_LEAST8_FMTX__ "hhX" +#define __UINT_LEAST8_FMTo__ "hho" +#define __UINT_LEAST8_FMTu__ "hhu" +#define __UINT_LEAST8_FMTx__ "hhx" +#define __UINT_LEAST8_MAX__ 255 +#define __UINT_LEAST8_TYPE__ unsigned char +#define __USER_LABEL_PREFIX__ +#define __USE_TIME_BITS64 1 +#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) +#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) +#define __WASI_ADVICE_NORMAL (UINT8_C(0)) +#define __WASI_ADVICE_RANDOM (UINT8_C(2)) +#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) +#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) +#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) +#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) +#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) +#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) +#define __WASI_DIRCOOKIE_START (UINT64_C(0)) +#define __WASI_ERRNO_2BIG (UINT16_C(1)) +#define __WASI_ERRNO_ACCES (UINT16_C(2)) +#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) +#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) +#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) +#define __WASI_ERRNO_AGAIN (UINT16_C(6)) +#define __WASI_ERRNO_ALREADY (UINT16_C(7)) +#define __WASI_ERRNO_BADF (UINT16_C(8)) +#define __WASI_ERRNO_BADMSG (UINT16_C(9)) +#define __WASI_ERRNO_BUSY (UINT16_C(10)) +#define __WASI_ERRNO_CANCELED (UINT16_C(11)) +#define __WASI_ERRNO_CHILD (UINT16_C(12)) +#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) +#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) +#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) +#define __WASI_ERRNO_DEADLK (UINT16_C(16)) +#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) +#define __WASI_ERRNO_DOM (UINT16_C(18)) +#define __WASI_ERRNO_DQUOT (UINT16_C(19)) +#define __WASI_ERRNO_EXIST (UINT16_C(20)) +#define __WASI_ERRNO_FAULT (UINT16_C(21)) +#define __WASI_ERRNO_FBIG (UINT16_C(22)) +#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) +#define __WASI_ERRNO_IDRM (UINT16_C(24)) +#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) +#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) +#define __WASI_ERRNO_INTR (UINT16_C(27)) +#define __WASI_ERRNO_INVAL (UINT16_C(28)) +#define __WASI_ERRNO_IO (UINT16_C(29)) +#define __WASI_ERRNO_ISCONN (UINT16_C(30)) +#define __WASI_ERRNO_ISDIR (UINT16_C(31)) +#define __WASI_ERRNO_LOOP (UINT16_C(32)) +#define __WASI_ERRNO_MFILE (UINT16_C(33)) +#define __WASI_ERRNO_MLINK (UINT16_C(34)) +#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) +#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) +#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) +#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) +#define __WASI_ERRNO_NETRESET (UINT16_C(39)) +#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) +#define __WASI_ERRNO_NFILE (UINT16_C(41)) +#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) +#define __WASI_ERRNO_NODEV (UINT16_C(43)) +#define __WASI_ERRNO_NOENT (UINT16_C(44)) +#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) +#define __WASI_ERRNO_NOLCK (UINT16_C(46)) +#define __WASI_ERRNO_NOLINK (UINT16_C(47)) +#define __WASI_ERRNO_NOMEM (UINT16_C(48)) +#define __WASI_ERRNO_NOMSG (UINT16_C(49)) +#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) +#define __WASI_ERRNO_NOSPC (UINT16_C(51)) +#define __WASI_ERRNO_NOSYS (UINT16_C(52)) +#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) +#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) +#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) +#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) +#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) +#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) +#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) +#define __WASI_ERRNO_NOTTY (UINT16_C(59)) +#define __WASI_ERRNO_NXIO (UINT16_C(60)) +#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) +#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) +#define __WASI_ERRNO_PERM (UINT16_C(63)) +#define __WASI_ERRNO_PIPE (UINT16_C(64)) +#define __WASI_ERRNO_PROTO (UINT16_C(65)) +#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) +#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) +#define __WASI_ERRNO_RANGE (UINT16_C(68)) +#define __WASI_ERRNO_ROFS (UINT16_C(69)) +#define __WASI_ERRNO_SPIPE (UINT16_C(70)) +#define __WASI_ERRNO_SRCH (UINT16_C(71)) +#define __WASI_ERRNO_STALE (UINT16_C(72)) +#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) +#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) +#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) +#define __WASI_ERRNO_XDEV (UINT16_C(75)) +#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) +#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) +#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) +#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) +#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) +#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) +#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) +#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) +#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) +#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) +#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) +#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) +#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) +#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) +#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) +#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) +#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) +#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) +#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) +#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) +#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) +#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) +#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) +#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) +#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) +#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) +#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) +#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) +#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) +#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) +#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) +#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) +#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) +#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) +#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) +#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) +#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) +#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) +#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) +#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) +#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) +#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) +#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) +#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) +#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) +#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) +#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) +#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) +#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) +#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) +#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) +#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) +#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) +#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) +#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) +#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) +#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) +#define __WASI_SIGNAL_ABRT (UINT8_C(6)) +#define __WASI_SIGNAL_ALRM (UINT8_C(14)) +#define __WASI_SIGNAL_BUS (UINT8_C(7)) +#define __WASI_SIGNAL_CHLD (UINT8_C(16)) +#define __WASI_SIGNAL_CONT (UINT8_C(17)) +#define __WASI_SIGNAL_FPE (UINT8_C(8)) +#define __WASI_SIGNAL_HUP (UINT8_C(1)) +#define __WASI_SIGNAL_ILL (UINT8_C(4)) +#define __WASI_SIGNAL_INT (UINT8_C(2)) +#define __WASI_SIGNAL_KILL (UINT8_C(9)) +#define __WASI_SIGNAL_NONE (UINT8_C(0)) +#define __WASI_SIGNAL_PIPE (UINT8_C(13)) +#define __WASI_SIGNAL_POLL (UINT8_C(28)) +#define __WASI_SIGNAL_PROF (UINT8_C(26)) +#define __WASI_SIGNAL_PWR (UINT8_C(29)) +#define __WASI_SIGNAL_QUIT (UINT8_C(3)) +#define __WASI_SIGNAL_SEGV (UINT8_C(11)) +#define __WASI_SIGNAL_STOP (UINT8_C(18)) +#define __WASI_SIGNAL_SYS (UINT8_C(30)) +#define __WASI_SIGNAL_TERM (UINT8_C(15)) +#define __WASI_SIGNAL_TRAP (UINT8_C(5)) +#define __WASI_SIGNAL_TSTP (UINT8_C(19)) +#define __WASI_SIGNAL_TTIN (UINT8_C(20)) +#define __WASI_SIGNAL_TTOU (UINT8_C(21)) +#define __WASI_SIGNAL_URG (UINT8_C(22)) +#define __WASI_SIGNAL_USR1 (UINT8_C(10)) +#define __WASI_SIGNAL_USR2 (UINT8_C(12)) +#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) +#define __WASI_SIGNAL_WINCH (UINT8_C(27)) +#define __WASI_SIGNAL_XCPU (UINT8_C(23)) +#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) +#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) +#define __WASI_WHENCE_CUR (UINT8_C(1)) +#define __WASI_WHENCE_END (UINT8_C(2)) +#define __WASI_WHENCE_SET (UINT8_C(0)) +#define __WCHAR_MAX__ 2147483647 +#define __WCHAR_TYPE__ int +#define __WCHAR_WIDTH__ 32 +#define __WINT_MAX__ 2147483647 +#define __WINT_TYPE__ int +#define __WINT_WIDTH__ 32 +#define __WORDSIZE 64 +#define __alignas_is_defined 1 +#define __alignof_is_defined 1 +#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) +#define __bool_true_false_are_defined 1 +#define __inline inline +#define __restrict restrict +#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) +#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) +#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) +#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) +#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) +#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) +#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) +#define __tm_gmtoff tm_gmtoff +#define __tm_zone tm_zone +#define __va_copy(d,s) __builtin_va_copy(d, s) +#define __wasi__ 1 +#define __wasi_api_h +#define __wasi_libc_environ_h +#define __wasi_libc_find_relpath_h +#define __wasi_libc_h +#define __wasi_libc_nocwd_h +#define __wasilibc___errno_h +#define __wasilibc___errno_values_h +#define __wasilibc___fd_set_h +#define __wasilibc___function___isatty_h +#define __wasilibc___functions_malloc_h +#define __wasilibc___functions_memcpy_h +#define __wasilibc___header_dirent_h +#define __wasilibc___header_fcntl_h +#define __wasilibc___header_netinet_in_h +#define __wasilibc___header_poll_h +#define __wasilibc___header_stdlib_h +#define __wasilibc___header_string_h +#define __wasilibc___header_sys_ioctl_h +#define __wasilibc___header_sys_resource_h +#define __wasilibc___header_sys_socket_h +#define __wasilibc___header_sys_stat_h +#define __wasilibc___header_time_h +#define __wasilibc___header_unistd_h +#define __wasilibc___include_inttypes_h +#define __wasilibc___macro_FD_SETSIZE_h +#define __wasilibc___macro_PAGESIZE_h +#define __wasilibc___mode_t_h +#define __wasilibc___seek_h +#define __wasilibc___struct_dirent_h +#define __wasilibc___struct_in6_addr_h +#define __wasilibc___struct_in_addr_h +#define __wasilibc___struct_iovec_h +#define __wasilibc___struct_msghdr_h +#define __wasilibc___struct_pollfd_h +#define __wasilibc___struct_rusage_h +#define __wasilibc___struct_sockaddr_h +#define __wasilibc___struct_sockaddr_in6_h +#define __wasilibc___struct_sockaddr_in_h +#define __wasilibc___struct_sockaddr_storage_h +#define __wasilibc___struct_sockaddr_un_h +#define __wasilibc___struct_stat_h +#define __wasilibc___struct_timespec_h +#define __wasilibc___struct_timeval_h +#define __wasilibc___struct_tm_h +#define __wasilibc___struct_tms_h +#define __wasilibc___typedef_DIR_h +#define __wasilibc___typedef_blkcnt_t_h +#define __wasilibc___typedef_blksize_t_h +#define __wasilibc___typedef_clock_t_h +#define __wasilibc___typedef_clockid_t_h +#define __wasilibc___typedef_dev_t_h +#define __wasilibc___typedef_fd_set_h +#define __wasilibc___typedef_gid_t_h +#define __wasilibc___typedef_in_addr_t_h +#define __wasilibc___typedef_in_port_t_h +#define __wasilibc___typedef_ino_t_h +#define __wasilibc___typedef_mode_t_h +#define __wasilibc___typedef_nfds_t_h +#define __wasilibc___typedef_nlink_t_h +#define __wasilibc___typedef_off_t_h +#define __wasilibc___typedef_sa_family_t_h +#define __wasilibc___typedef_sigset_t_h +#define __wasilibc___typedef_socklen_t_h +#define __wasilibc___typedef_ssize_t_h +#define __wasilibc___typedef_suseconds_t_h +#define __wasilibc___typedef_time_t_h +#define __wasilibc___typedef_uid_t_h +#define __wasm 1 +#define __wasm64 1 +#define __wasm64__ 1 +#define __wasm__ 1 +#define _tolower(a) ((a)|0x20) +#define _toupper(a) ((a)&0x5f) +#define acos(x) __tg_real_complex(acos, (x)) +#define acosh(x) __tg_real_complex(acosh, (x)) +#define alignas _Alignas +#define alignof _Alignof +#define alloca __builtin_alloca +#define alphasort64 alphasort +#define and && +#define and_eq &= +#define asin(x) __tg_real_complex(asin, (x)) +#define asinh(x) __tg_real_complex(asinh, (x)) +#define atan(x) __tg_real_complex(atan, (x)) +#define atan2(x,y) __tg_real_2(atan2, (x), (y)) +#define atanh(x) __tg_real_complex(atanh, (x)) +#define be16toh(x) __bswap16(x) +#define be32toh(x) __bswap32(x) +#define be64toh(x) __bswap64(x) +#define betoh16(x) __bswap16(x) +#define betoh32(x) __bswap32(x) +#define betoh64(x) __bswap64(x) +#define bitand & +#define bitor | +#define blkcnt64_t blkcnt_t +#define bool _Bool +#define bswap_16(x) __bswap_16(x) +#define bswap_32(x) __bswap_32(x) +#define bswap_64(x) __bswap_64(x) +#define carg(x) __tg_complex_retreal(carg, (x)) +#define cbrt(x) __tg_real(cbrt, (x)) +#define ceil(x) __tg_real(ceil, (x)) +#define cimag(x) __tg_complex_retreal(cimag, (x)) +#define cimagf(x) (__builtin_cimagf(x)) +#define cimagl(x) (__builtin_cimagl(x)) +#define clrbit(x,i) __bitop(x,i,&=~) +#define compl ~ +#define complex _Complex +#define conj(x) __tg_complex(conj, (x)) +#define copysign(x,y) __tg_real_2(copysign, (x), (y)) +#define cos(x) __tg_real_complex(cos, (x)) +#define cosh(x) __tg_real_complex(cosh, (x)) +#define cproj(x) __tg_complex(cproj, (x)) +#define creal(x) __tg_complex_retreal(creal, (x)) +#define crealf(x) (__builtin_crealf(x)) +#define creall(x) (__builtin_creall(x)) +#define creat64 creat +#define d_fileno d_ino +#define direct dirent +#define dirent64 dirent +#define erf(x) __tg_real(erf, (x)) +#define erfc(x) __tg_real(erfc, (x)) +#define errno errno +#define exp(x) __tg_real_complex(exp, (x)) +#define exp2(x) __tg_real(exp2, (x)) +#define expm1(x) __tg_real(expm1, (x)) +#define fabs(x) __tg_real_complex_fabs(x) +#define false 0 +#define fdim(x,y) __tg_real_2(fdim, (x), (y)) +#define fgetpos64 fgetpos +#define floor(x) __tg_real(floor, (x)) +#define fma(x,y,z) __tg_real_fma((x), (y), (z)) +#define fmax(x,y) __tg_real_2(fmax, (x), (y)) +#define fmin(x,y) __tg_real_2(fmin, (x), (y)) +#define fmod(x,y) __tg_real_2(fmod, (x), (y)) +#define fopen64 fopen +#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) +#define fpos64_t fpos_t +#define freopen64 freopen +#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) +#define fsblkcnt64_t fsblkcnt_t +#define fseeko64 fseeko +#define fsetpos64 fsetpos +#define fsfilcnt64_t fsfilcnt_t +#define fstat64 fstat +#define fstatat64 fstatat +#define ftello64 ftello +#define ftruncate64 ftruncate +#define getdents64 getdents +#define glob64 glob +#define glob64_t glob_t +#define globfree64 globfree +#define howmany(n,d) (((n)+((d)-1))/(d)) +#define htobe16(x) __bswap16(x) +#define htobe32(x) __bswap32(x) +#define htobe64(x) __bswap64(x) +#define htole16(x) (uint16_t)(x) +#define htole32(x) (uint32_t)(x) +#define htole64(x) (uint64_t)(x) +#define hypot(x,y) __tg_real_2(hypot, (x), (y)) +#define icmp6_data16 icmp6_dataun.icmp6_un_data16 +#define icmp6_data32 icmp6_dataun.icmp6_un_data32 +#define icmp6_data8 icmp6_dataun.icmp6_un_data8 +#define icmp6_id icmp6_data16[0] +#define icmp6_maxdelay icmp6_data16[0] +#define icmp6_mtu icmp6_data32[0] +#define icmp6_pptr icmp6_data32[0] +#define icmp6_seq icmp6_data16[1] +#define icmp_data icmp_dun.id_data +#define icmp_gwaddr icmp_hun.ih_gwaddr +#define icmp_id icmp_hun.ih_idseq.icd_id +#define icmp_ip icmp_dun.id_ip.idi_ip +#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime +#define icmp_mask icmp_dun.id_mask +#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu +#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs +#define icmp_otime icmp_dun.id_ts.its_otime +#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void +#define icmp_pptr icmp_hun.ih_pptr +#define icmp_radv icmp_dun.id_radv +#define icmp_rtime icmp_dun.id_ts.its_rtime +#define icmp_seq icmp_hun.ih_idseq.icd_seq +#define icmp_ttime icmp_dun.id_ts.its_ttime +#define icmp_void icmp_hun.ih_void +#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa +#define ifa_broadaddr ifa_ifu.ifu_broadaddr +#define ifa_dstaddr ifa_ifu.ifu_dstaddr +#define ilogb(x) __tg_real_nocast(ilogb, (x)) +#define ino64_t ino_t +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) +#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) +#define isclr(x,i) !isset(x,i) +#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) +#define isfinite(x) (__builtin_isfinite(x)) +#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) +#define isgreater(x,y) (__builtin_isgreater(x, y)) +#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) +#define isinf(x) (__builtin_isinf(x)) +#define isless(x,y) (__builtin_isless(x, y)) +#define islessequal(x,y) (__builtin_islessequal(x, y)) +#define islessgreater(x,y) (__builtin_islessgreater(x, y)) +#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) +#define isnan(x) (__builtin_isnan(x)) +#define isnormal(x) (__builtin_isnormal(x)) +#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) +#define isset(x,i) __bitop(x,i,&) +#define isspace(a) __isspace(a) +#define isunordered(x,y) (__builtin_isunordered(x, y)) +#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) +#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) +#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) +#define le16toh(x) (uint16_t)(x) +#define le32toh(x) (uint32_t)(x) +#define le64toh(x) (uint64_t)(x) +#define letoh16(x) (uint16_t)(x) +#define letoh32(x) (uint32_t)(x) +#define letoh64(x) (uint64_t)(x) +#define lgamma(x) __tg_real(lgamma, (x)) +#define llrint(x) __tg_real_nocast(llrint, (x)) +#define llround(x) __tg_real_nocast(llround, (x)) +#define loff_t off_t +#define log(x) __tg_real_complex(log, (x)) +#define log10(x) __tg_real(log10, (x)) +#define log1p(x) __tg_real(log1p, (x)) +#define log2(x) __tg_real(log2, (x)) +#define logb(x) __tg_real(logb, (x)) +#define lrint(x) __tg_real_nocast(lrint, (x)) +#define lround(x) __tg_real_nocast(lround, (x)) +#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) +#define lseek64 lseek +#define lstat64 lstat +#define math_errhandling 2 +#define mld_cksum mld_icmp6_hdr.icmp6_cksum +#define mld_code mld_icmp6_hdr.icmp6_code +#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] +#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] +#define mld_type mld_icmp6_hdr.icmp6_type +#define nd_na_cksum nd_na_hdr.icmp6_cksum +#define nd_na_code nd_na_hdr.icmp6_code +#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] +#define nd_na_type nd_na_hdr.icmp6_type +#define nd_ns_cksum nd_ns_hdr.icmp6_cksum +#define nd_ns_code nd_ns_hdr.icmp6_code +#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] +#define nd_ns_type nd_ns_hdr.icmp6_type +#define nd_ra_cksum nd_ra_hdr.icmp6_cksum +#define nd_ra_code nd_ra_hdr.icmp6_code +#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] +#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] +#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] +#define nd_ra_type nd_ra_hdr.icmp6_type +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rs_cksum nd_rs_hdr.icmp6_cksum +#define nd_rs_code nd_rs_hdr.icmp6_code +#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] +#define nd_rs_type nd_rs_hdr.icmp6_type +#define nearbyint(x) __tg_real(nearbyint, (x)) +#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) +#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) +#define nftw64 nftw +#define no_argument 0 +#define noreturn _Noreturn +#define not ! +#define not_eq != +#define ns_msg_base(handle) ((handle)._msg + 0) +#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) +#define ns_msg_end(handle) ((handle)._eom + 0) +#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) +#define ns_msg_id(handle) ((handle)._id + 0) +#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) +#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) +#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") +#define ns_rr_rdata(rr) ((rr).rdata + 0) +#define ns_rr_rdlen(rr) ((rr).rdlength + 0) +#define ns_rr_ttl(rr) ((rr).ttl + 0) +#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) +#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) +#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) +#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) +#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) +#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) +#define off64_t off_t +#define offsetof(t,d) __builtin_offsetof(t, d) +#define open64 open +#define openat64 openat +#define optional_argument 2 +#define or || +#define or_eq |= +#define posix_fadvise64 posix_fadvise +#define posix_fallocate64 posix_fallocate +#define pow(x,y) __tg_real_complex_pow((x), (y)) +#define powerof2(n) !(((n)-1) & (n)) +#define pread64 pread +#define preadv64 preadv +#define pwrite64 pwrite +#define pwritev64 pwritev +#define readdir64 readdir +#define remainder(x,y) __tg_real_2(remainder, (x), (y)) +#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) +#define required_argument 1 +#define rint(x) __tg_real(rint, (x)) +#define round(x) __tg_real(round, (x)) +#define roundup(n,d) (howmany(n,d)*(d)) +#define rr_cksum rr_hdr.icmp6_cksum +#define rr_code rr_hdr.icmp6_code +#define rr_seqnum rr_hdr.icmp6_data32[0] +#define rr_type rr_hdr.icmp6_type +#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) +#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) +#define scandir64 scandir +#define setbit(x,i) __bitop(x,i,|=) +#define signbit(x) (__builtin_signbit(x)) +#define sin(x) __tg_real_complex(sin, (x)) +#define sinh(x) __tg_real_complex(sinh, (x)) +#define sqrt(x) __tg_real_complex(sqrt, (x)) +#define st_atime st_atim.tv_sec +#define st_ctime st_ctim.tv_sec +#define st_mtime st_mtim.tv_sec +#define stat64 stat +#define static_assert _Static_assert +#define stderr (stderr) +#define stdin (stdin) +#define stdout (stdout) +#define strdupa(x) strcpy(alloca(strlen(x)+1),x) +#define tan(x) __tg_real_complex(tan, (x)) +#define tanh(x) __tg_real_complex(tanh, (x)) +#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) +#define tgamma(x) __tg_real(tgamma, (x)) +#define th_block th_u.tu_block +#define th_code th_u.tu_code +#define th_msg th_data +#define th_stuff th_u.tu_stuff +#define thrd_equal(A,B) ((A) == (B)) +#define thread_local _Thread_local +#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) +#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) +#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) +#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) +#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) +#define true 1 +#define trunc(x) __tg_real(trunc, (x)) +#define uh_dport dest +#define uh_sport source +#define uh_sum check +#define uh_ulen len +#define va_arg(ap,type) __builtin_va_arg(ap, type) +#define va_copy(dest,src) __builtin_va_copy(dest, src) +#define va_end(ap) __builtin_va_end(ap) +#define va_start(ap,param) __builtin_va_start(ap, param) +#define versionsort64 versionsort +#define xEOF 236 +#define xor ^ +#define xor_eq ^= diff --git a/expected/wasm64-wasi/undefined-symbols.txt b/expected/wasm64-wasi/undefined-symbols.txt new file mode 100644 index 000000000..0890c5217 --- /dev/null +++ b/expected/wasm64-wasi/undefined-symbols.txt @@ -0,0 +1,70 @@ +__addtf3 +__divtf3 +__eqtf2 +__extenddftf2 +__extendsftf2 +__fixtfdi +__fixtfsi +__fixunstfsi +__floatditf +__floatsitf +__floatunsitf +__getf2 +__gttf2 +__heap_base +__heap_end +__imported_wasi_snapshot_preview1_args_get +__imported_wasi_snapshot_preview1_args_sizes_get +__imported_wasi_snapshot_preview1_clock_res_get +__imported_wasi_snapshot_preview1_clock_time_get +__imported_wasi_snapshot_preview1_environ_get +__imported_wasi_snapshot_preview1_environ_sizes_get +__imported_wasi_snapshot_preview1_fd_advise +__imported_wasi_snapshot_preview1_fd_allocate +__imported_wasi_snapshot_preview1_fd_close +__imported_wasi_snapshot_preview1_fd_datasync +__imported_wasi_snapshot_preview1_fd_fdstat_get +__imported_wasi_snapshot_preview1_fd_fdstat_set_flags +__imported_wasi_snapshot_preview1_fd_fdstat_set_rights +__imported_wasi_snapshot_preview1_fd_filestat_get +__imported_wasi_snapshot_preview1_fd_filestat_set_size +__imported_wasi_snapshot_preview1_fd_filestat_set_times +__imported_wasi_snapshot_preview1_fd_pread +__imported_wasi_snapshot_preview1_fd_prestat_dir_name +__imported_wasi_snapshot_preview1_fd_prestat_get +__imported_wasi_snapshot_preview1_fd_pwrite +__imported_wasi_snapshot_preview1_fd_read +__imported_wasi_snapshot_preview1_fd_readdir +__imported_wasi_snapshot_preview1_fd_renumber +__imported_wasi_snapshot_preview1_fd_seek +__imported_wasi_snapshot_preview1_fd_sync +__imported_wasi_snapshot_preview1_fd_tell +__imported_wasi_snapshot_preview1_fd_write +__imported_wasi_snapshot_preview1_path_create_directory +__imported_wasi_snapshot_preview1_path_filestat_get +__imported_wasi_snapshot_preview1_path_filestat_set_times +__imported_wasi_snapshot_preview1_path_link +__imported_wasi_snapshot_preview1_path_open +__imported_wasi_snapshot_preview1_path_readlink +__imported_wasi_snapshot_preview1_path_remove_directory +__imported_wasi_snapshot_preview1_path_rename +__imported_wasi_snapshot_preview1_path_symlink +__imported_wasi_snapshot_preview1_path_unlink_file +__imported_wasi_snapshot_preview1_poll_oneoff +__imported_wasi_snapshot_preview1_proc_exit +__imported_wasi_snapshot_preview1_proc_raise +__imported_wasi_snapshot_preview1_random_get +__imported_wasi_snapshot_preview1_sched_yield +__imported_wasi_snapshot_preview1_sock_accept +__imported_wasi_snapshot_preview1_sock_recv +__imported_wasi_snapshot_preview1_sock_send +__imported_wasi_snapshot_preview1_sock_shutdown +__letf2 +__lttf2 +__netf2 +__stack_pointer +__subtf3 +__trunctfdf2 +__trunctfsf2 +__unordtf2 +__wasm_call_ctors diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index c534d6f03..0e2cd7237 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -2191,6 +2191,25 @@ __wasi_errno_t __wasi_sock_shutdown( ) __attribute__((__warn_unused_result__)); /** @} */ +#ifdef _REENTRANT +/** + * Request a new thread to be created by the host. + * + * The host will create a new instance of the current module sharing its + * memory, find an exported entry function--`wasi_thread_start`--, and call the + * entry function with `start_arg` in the new thread. + * + * @see https://github.com/WebAssembly/wasi-threads/#readme + */ +__wasi_errno_t __wasi_thread_spawn( + /** + * A pointer to an opaque struct to be passed to the module's entry + * function. + */ + void *start_arg +) __attribute__((__warn_unused_result__)); +#endif + #ifdef __cplusplus } #endif diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 3afecc1da..8356e2bc2 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -13,7 +13,7 @@ #include #include -int32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_get") )); @@ -22,11 +22,10 @@ __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf ){ - int32_t ret = __imported_wasi_snapshot_preview1_args_get((uintptr_t) argv, (uintptr_t) argv_buf); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((uintptr_t) argv, (uintptr_t) argv_buf); } -int32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_sizes_get") )); @@ -35,11 +34,10 @@ __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_args_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); } -int32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_get") )); @@ -48,11 +46,10 @@ __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf ){ - int32_t ret = __imported_wasi_snapshot_preview1_environ_get((uintptr_t) environ, (uintptr_t) environ_buf); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((uintptr_t) environ, (uintptr_t) environ_buf); } -int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_sizes_get") )); @@ -61,11 +58,10 @@ __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_environ_sizes_get((uintptr_t)retptr0, (uintptr_t)retptr1); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); } -int32_t __imported_wasi_snapshot_preview1_clock_res_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_clock_res_get(uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_res_get") )); @@ -74,11 +70,10 @@ __wasi_errno_t __wasi_clock_res_get( __wasi_clockid_t id, __wasi_timestamp_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((uint32_t) id, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_clock_time_get(uintptr_t arg0, int64_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_clock_time_get(uint32_t, uint64_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_time_get") )); @@ -88,11 +83,10 @@ __wasi_errno_t __wasi_clock_time_get( __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((uint32_t) id, (uint64_t) precision, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_advise(uintptr_t arg0, int64_t arg1, int64_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_advise(uint32_t, uint64_t, uint64_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_advise") )); @@ -103,11 +97,10 @@ __wasi_errno_t __wasi_fd_advise( __wasi_filesize_t len, __wasi_advice_t advice ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_advise((int32_t) fd, (int64_t) offset, (int64_t) len, (int32_t) advice); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((uint32_t) fd, (uint64_t) offset, (uint64_t) len, (uint32_t) advice); } -int32_t __imported_wasi_snapshot_preview1_fd_allocate(uintptr_t arg0, int64_t arg1, int64_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_allocate(uint32_t, uint64_t, uint64_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_allocate") )); @@ -117,11 +110,10 @@ __wasi_errno_t __wasi_fd_allocate( __wasi_filesize_t offset, __wasi_filesize_t len ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_allocate((int32_t) fd, (int64_t) offset, (int64_t) len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((uint32_t) fd, (uint64_t) offset, (uint64_t) len); } -int32_t __imported_wasi_snapshot_preview1_fd_close(uintptr_t arg0) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_close(uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_close") )); @@ -129,11 +121,10 @@ int32_t __imported_wasi_snapshot_preview1_fd_close(uintptr_t arg0) __attribute__ __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_close((int32_t) fd); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((uint32_t) fd); } -int32_t __imported_wasi_snapshot_preview1_fd_datasync(uintptr_t arg0) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_datasync(uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_datasync") )); @@ -141,11 +132,10 @@ int32_t __imported_wasi_snapshot_preview1_fd_datasync(uintptr_t arg0) __attribut __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_datasync((int32_t) fd); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((uint32_t) fd); } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_get") )); @@ -154,11 +144,10 @@ __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((uint32_t) fd, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uint32_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_flags") )); @@ -167,11 +156,10 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( __wasi_fd_t fd, __wasi_fdflags_t flags ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((int32_t) fd, flags); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((uint32_t) fd, (uint32_t) flags); } -int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uintptr_t arg0, int64_t arg1, int64_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uint32_t, uint64_t, uint64_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_rights") )); @@ -181,11 +169,10 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((int32_t) fd, fs_rights_base, fs_rights_inheriting); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((uint32_t) fd, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting); } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_get") )); @@ -194,11 +181,10 @@ __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((uint32_t) fd, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uintptr_t arg0, int64_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uint32_t, uint64_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_size") )); @@ -207,11 +193,10 @@ __wasi_errno_t __wasi_fd_filestat_set_size( __wasi_fd_t fd, __wasi_filesize_t size ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_filestat_set_size((int32_t) fd, (int64_t) size); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((uint32_t) fd, (uint64_t) size); } -int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uintptr_t arg0, int64_t arg1, int64_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uint32_t, uint64_t, uint64_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_times") )); @@ -222,11 +207,10 @@ __wasi_errno_t __wasi_fd_filestat_set_times( __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_filestat_set_times((int32_t) fd, (int64_t) atim, (int64_t) mtim, fst_flags); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((uint32_t) fd, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); } -int32_t __imported_wasi_snapshot_preview1_fd_pread(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_pread(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pread") )); @@ -238,11 +222,10 @@ __wasi_errno_t __wasi_fd_pread( __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (uintptr_t) iovs, iovs_len, (int64_t) offset, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_get") )); @@ -251,11 +234,10 @@ __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((uint32_t) fd, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_dir_name") )); @@ -265,11 +247,10 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( uint8_t * path, __wasi_size_t path_len ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (uintptr_t) path, path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -int32_t __imported_wasi_snapshot_preview1_fd_pwrite(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_pwrite(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pwrite") )); @@ -281,11 +262,10 @@ __wasi_errno_t __wasi_fd_pwrite( __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (uintptr_t) iovs, iovs_len, (int64_t) offset, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_read(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_read(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_read") )); @@ -296,11 +276,10 @@ __wasi_errno_t __wasi_fd_read( size_t iovs_len, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (uintptr_t) iovs, iovs_len, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_readdir(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, int64_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_readdir(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_readdir") )); @@ -312,11 +291,10 @@ __wasi_errno_t __wasi_fd_readdir( __wasi_dircookie_t cookie, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (uintptr_t) buf, buf_len, (int64_t) cookie, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((uint32_t) fd, (uintptr_t) buf, (__wasi_size_t) buf_len, (uint64_t) cookie, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_renumber(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_renumber(uint32_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_renumber") )); @@ -325,11 +303,10 @@ __wasi_errno_t __wasi_fd_renumber( __wasi_fd_t fd, __wasi_fd_t to ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_renumber((int32_t) fd, (int32_t) to); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((uint32_t) fd, (uint32_t) to); } -int32_t __imported_wasi_snapshot_preview1_fd_seek(uintptr_t arg0, int64_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_seek(uint32_t, uint64_t, uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_seek") )); @@ -340,11 +317,10 @@ __wasi_errno_t __wasi_fd_seek( __wasi_whence_t whence, __wasi_filesize_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, offset, whence, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((uint32_t) fd, (uint64_t) offset, (uint32_t) whence, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_sync(uintptr_t arg0) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_sync(uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_sync") )); @@ -352,11 +328,10 @@ int32_t __imported_wasi_snapshot_preview1_fd_sync(uintptr_t arg0) __attribute__( __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_sync((int32_t) fd); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((uint32_t) fd); } -int32_t __imported_wasi_snapshot_preview1_fd_tell(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_tell(uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_tell") )); @@ -365,11 +340,10 @@ __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((uint32_t) fd, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_fd_write(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_write(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_write") )); @@ -380,11 +354,10 @@ __wasi_errno_t __wasi_fd_write( size_t iovs_len, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (uintptr_t) iovs, iovs_len, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_path_create_directory(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_create_directory(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_create_directory") )); @@ -394,11 +367,10 @@ __wasi_errno_t __wasi_path_create_directory( char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (uintptr_t)path, path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -int32_t __imported_wasi_snapshot_preview1_path_filestat_get(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_filestat_get(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_get") )); @@ -410,11 +382,10 @@ __wasi_errno_t __wasi_path_filestat_get( __wasi_filestat_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, flags, (uintptr_t)path, path_len, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, int64_t arg4, int64_t arg5, uintptr_t arg6) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint64_t, uint64_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_set_times") )); @@ -428,11 +399,10 @@ __wasi_errno_t __wasi_path_filestat_set_times( __wasi_fstflags_t fst_flags ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, flags, (uintptr_t)path, path_len, (int64_t) atim, (int64_t) mtim, fst_flags); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); } -int32_t __imported_wasi_snapshot_preview1_path_link(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5, uintptr_t arg6) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_link(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_link") )); @@ -446,11 +416,10 @@ __wasi_errno_t __wasi_path_link( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, old_flags, (uintptr_t)old_path, old_path_len, (int32_t) new_fd, (uintptr_t)new_path, new_path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((uint32_t) old_fd, (uint32_t) old_flags, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -int32_t __imported_wasi_snapshot_preview1_path_open(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, int64_t arg5, int64_t arg6, uintptr_t arg7, uintptr_t arg8) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_open(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uint64_t, uint64_t, uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_open") )); @@ -466,11 +435,10 @@ __wasi_errno_t __wasi_path_open( __wasi_fd_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_open((int32_t) fd, dirflags, (uintptr_t)path, path_len, oflags, fs_rights_base, fs_rights_inheriting, fdflags, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((uint32_t) fd, (uint32_t) dirflags, (uintptr_t) path, (__wasi_size_t) path_len, (uint32_t) oflags, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting, (uint32_t) fdflags, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_path_readlink(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_readlink(uint32_t, uintptr_t, __wasi_size_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_readlink") )); @@ -483,11 +451,10 @@ __wasi_errno_t __wasi_path_readlink( __wasi_size_t *retptr0 ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (uintptr_t)path, path_len, (uintptr_t) buf, buf_len, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) buf, (__wasi_size_t) buf_len, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_path_remove_directory(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_remove_directory(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_remove_directory") )); @@ -497,11 +464,10 @@ __wasi_errno_t __wasi_path_remove_directory( char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (uintptr_t)path, path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -int32_t __imported_wasi_snapshot_preview1_path_rename(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_rename(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_rename") )); @@ -514,11 +480,10 @@ __wasi_errno_t __wasi_path_rename( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (uintptr_t)old_path, old_path_len, (int32_t) new_fd, (uintptr_t)new_path, new_path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((uint32_t) fd, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -int32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_symlink") )); @@ -530,11 +495,10 @@ __wasi_errno_t __wasi_path_symlink( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - int32_t ret = __imported_wasi_snapshot_preview1_path_symlink((uintptr_t)old_path, old_path_len, (int32_t) fd, (uintptr_t)new_path, new_path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -int32_t __imported_wasi_snapshot_preview1_path_unlink_file(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_unlink_file(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_unlink_file") )); @@ -544,11 +508,10 @@ __wasi_errno_t __wasi_path_unlink_file( char const *path ){ size_t path_len = strlen(path); - int32_t ret = __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (uintptr_t)path, path_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -int32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t, uintptr_t, uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("poll_oneoff") )); @@ -559,11 +522,10 @@ __wasi_errno_t __wasi_poll_oneoff( __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_poll_oneoff((uintptr_t) in, (uintptr_t) out, nsubscriptions, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((uintptr_t) in, (uintptr_t) out, (uint32_t) nsubscriptions, (uintptr_t) retptr0); } -_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uintptr_t arg0) __attribute__(( +_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("proc_exit") )); @@ -571,10 +533,10 @@ _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uintptr_t arg0) __att _Noreturn void __wasi_proc_exit( __wasi_exitcode_t rval ){ - __imported_wasi_snapshot_preview1_proc_exit((int32_t) rval); + __imported_wasi_snapshot_preview1_proc_exit((uint32_t) rval); } -int32_t __imported_wasi_snapshot_preview1_proc_raise(uintptr_t arg0) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_proc_raise(uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("proc_raise") )); @@ -582,11 +544,10 @@ int32_t __imported_wasi_snapshot_preview1_proc_raise(uintptr_t arg0) __attribute __wasi_errno_t __wasi_proc_raise( __wasi_signal_t sig ){ - int32_t ret = __imported_wasi_snapshot_preview1_proc_raise((int32_t) sig); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_proc_raise((uint32_t) sig); } -int32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sched_yield") )); @@ -594,11 +555,10 @@ int32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( __wasi_errno_t __wasi_sched_yield( void ){ - int32_t ret = __imported_wasi_snapshot_preview1_sched_yield(); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sched_yield(); } -int32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t, __wasi_size_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("random_get") )); @@ -607,11 +567,10 @@ __wasi_errno_t __wasi_random_get( uint8_t * buf, __wasi_size_t buf_len ){ - int32_t ret = __imported_wasi_snapshot_preview1_random_get((uintptr_t) buf, buf_len); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((uintptr_t) buf, (__wasi_size_t) buf_len); } -int32_t __imported_wasi_snapshot_preview1_sock_accept(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_accept(uint32_t, uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_accept") )); @@ -621,11 +580,10 @@ __wasi_errno_t __wasi_sock_accept( __wasi_fdflags_t flags, __wasi_fd_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, flags, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((uint32_t) fd, (uint32_t) flags, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_sock_recv(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4, uintptr_t arg5) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_recv(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_recv") )); @@ -638,11 +596,10 @@ __wasi_errno_t __wasi_sock_recv( __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (uintptr_t)ri_data, ri_data_len, ri_flags, (uintptr_t) retptr0, (uintptr_t)retptr1); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((uint32_t) fd, (uintptr_t) ri_data, (__wasi_size_t) ri_data_len, (uint32_t) ri_flags, (uintptr_t) retptr0, (uintptr_t) retptr1); } -int32_t __imported_wasi_snapshot_preview1_sock_send(uintptr_t arg0, uintptr_t arg1, uintptr_t arg2, uintptr_t arg3, uintptr_t arg4) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_send(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_send") )); @@ -654,11 +611,10 @@ __wasi_errno_t __wasi_sock_send( __wasi_siflags_t si_flags, __wasi_size_t *retptr0 ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (uintptr_t)si_data, si_data_len, (int32_t) si_flags, (uintptr_t) retptr0); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((uint32_t) fd, (uintptr_t) si_data, (__wasi_size_t) si_data_len, (uint32_t) si_flags, (uintptr_t) retptr0); } -int32_t __imported_wasi_snapshot_preview1_sock_shutdown(uintptr_t arg0, uintptr_t arg1) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_shutdown(uint32_t, uint32_t) __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_shutdown") )); @@ -667,7 +623,16 @@ __wasi_errno_t __wasi_sock_shutdown( __wasi_fd_t fd, __wasi_sdflags_t how ){ - int32_t ret = __imported_wasi_snapshot_preview1_sock_shutdown((int32_t) fd, how); - return (uint16_t) ret; + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_shutdown((uint32_t) fd, (uint32_t) how); } +#ifdef _REENTRANT +uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attribute__(( + __import_module__("wasi_snapshot_preview2"), + __import_name__("thread_spawn") +)); + +__wasi_errno_t __wasi_thread_spawn(void* start_arg) { + return (__wasi_errno_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +} +#endif diff --git a/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s b/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s new file mode 100644 index 000000000..22ba21692 --- /dev/null +++ b/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s @@ -0,0 +1,48 @@ + .text + + .export_name wasi_thread_start, wasi_thread_start + + .globaltype __stack_pointer, i64 + .globaltype __tls_base, i64 + .functype __wasi_thread_start_C (i64, i64) -> () + + .hidden wasi_thread_start + .globl wasi_thread_start + .type wasi_thread_start,@function + +wasi_thread_start: + .functype wasi_thread_start (i64, i64) -> () + + # Set up the minimum C environment. + # Note: offsetof(start_arg, stack) == 0 + local.get 1 # start_arg + i64.load 0 # stack + global.set __stack_pointer + + local.get 1 # start_arg + i64.load 8 # tls_base + global.set __tls_base + + # Make the C function do the rest of work. + local.get 0 # tid + local.get 1 # start_arg + call __wasi_thread_start_C + + # Unlock thread list. (as CLONE_CHILD_CLEARTID would do for Linux) + # + # Note: once we unlock the thread list, our "map_base" can be freed + # by a joining thread. It's safe as we are in ASM and no longer use + # our C stack or pthread_t. It's impossible to do this safely in C + # because there is no way to tell the C compiler not to use C stack. + i64.const __thread_list_lock + i64.const 0 + i64.atomic.store 0 + # As an optimization, we can check tl_lock_waiters here. + # But for now, simply wake up unconditionally as + # CLONE_CHILD_CLEARTID does. + i64.const __thread_list_lock + i32.const 1 + memory.atomic.notify 0 + drop + + end_function diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 53a0c6363..924643a21 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -1,6 +1,5 @@ use heck::ShoutySnakeCase; use std::collections::HashMap; -use std::mem; use witx::*; pub struct Generated { @@ -105,12 +104,45 @@ extern "C" {{ } header.push_str( - r#"#ifdef __cplusplus + r#"#ifdef _REENTRANT +/** + * Request a new thread to be created by the host. + * + * The host will create a new instance of the current module sharing its + * memory, find an exported entry function--`wasi_thread_start`--, and call the + * entry function with `start_arg` in the new thread. + * + * @see https://github.com/WebAssembly/wasi-threads/#readme + */ +__wasi_errno_t __wasi_thread_spawn( + /** + * A pointer to an opaque struct to be passed to the module's entry + * function. + */ + void *start_arg +) __attribute__((__warn_unused_result__)); +#endif + +#ifdef __cplusplus } #endif #endif -"#, +"# + ); + + source.push_str( + r#"#ifdef _REENTRANT +uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attribute__(( + __import_module__("wasi_snapshot_preview2"), + __import_name__("thread_spawn") +)); + +__wasi_errno_t __wasi_thread_spawn(void* start_arg) { + return (__wasi_errno_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +} +#endif +"# ); Generated { header, source } @@ -473,21 +505,14 @@ fn print_func_signature(ret: &mut String, func: &InterfaceFunc, header: bool) { ret.push_str(")"); } -fn c_typeref_name(tref: &TypeRef) -> String { - match &**tref.type_() { - Type::List(_)=> { - return "__wasi_size_t,__wasi_size_t".to_string(); - }, - _ => {} - } - +fn c_typeref_name(tref: &TypeRef, wtp: &witx::WasmType) -> String { match tref { - TypeRef::Name(named_type) => namedtype_name(&named_type), + TypeRef::Name(_) => c_wasm_type(wtp).to_string(), TypeRef::Value(anon_type) => match &**anon_type { Type::List(_) => unreachable!("arrays excluded above"), Type::Builtin(b) => builtin_type_name(*b).to_string(), - Type::Pointer(_) => "__wasi_size_t".to_string(), - Type::ConstPointer(_) => "__wasi_size_t".to_string(), + Type::Pointer(_) => "uintptr_t".to_string(), + Type::ConstPointer(_) => "uintptr_t".to_string(), Type::Record { .. } | Type::Variant { .. } | Type::Handle { .. } => unreachable!( "wasi should not have anonymous structs, unions, enums, flags, handles" ), @@ -495,18 +520,9 @@ fn c_typeref_name(tref: &TypeRef) -> String { } } -fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc) -{ - let mut params = Vec::new(); - for param in func.params.iter() { - add_params( - &mut params, - &ident_name(¶m.name), - ¶m.tref, - ¶m.docs, - ); - } +fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec, casting: bool) { let mut iszero = true; + let mut j = 0; for param in func.params.iter() { if iszero { iszero = false @@ -514,7 +530,39 @@ fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc) else { ret.push_str(", "); } - ret.push_str(&c_typeref_name(¶m.tref)); + let identifiername = ident_name(¶m.name); + match &**param.tref.type_() { + Type::List(_)=> { + if casting { + ret.push_str(&format!("(uintptr_t) {0}, (__wasi_size_t) {0}_len",&identifiername)); + } + else { + ret.push_str("uintptr_t, __wasi_size_t"); + } + j = j + 2; + }, + _ => { + // Fix around buf_len which is incorrectly marked uint32_t in metadata + if identifiername.ends_with("_len") { + if casting { + ret.push_str(&format!("(__wasi_size_t) {}",&identifiername)); + } + else { + ret.push_str("__wasi_size_t"); + } + } + else + { + if casting { + ret.push_str(&format!("({}) {}",c_typeref_name(¶m.tref,&signparams[j]),&identifiername)); + } + else { + ret.push_str(&c_typeref_name(¶m.tref,&signparams[j])); + } + } + j = j + 1; + } + } } match func.results.len() { 0 => { @@ -534,21 +582,32 @@ fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc) }; match &**ok.type_() { Type::Record(r) if r.is_tuple() => { - for _ in r.members.iter() { + for (i,_) in r.members.iter().enumerate() { if iszero { iszero = false } else { ret.push_str(", "); } - ret.push_str("__wasi_size_t"); + if casting { + ret.push_str(&format!("(uintptr_t) retptr{}",i)); + } + else { + ret.push_str("uintptr_t"); + } } } _ => { if !iszero { ret.push_str(", "); } - ret.push_str("__wasi_size_t"); + if casting { + ret.push_str("(uintptr_t) retptr0"); + } + else { + ret.push_str("uintptr_t"); + } + } } } @@ -559,8 +618,16 @@ fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc) } } +fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec) { + (print_c_typeref_casting_names(ret, func, signparams, false)); +} + +fn print_c_casting_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec) { + (print_c_typeref_casting_names(ret, func, signparams, true)); +} + fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { - let (_, results) = func.wasm_signature(); + let (params, results) = func.wasm_signature(); if func.noreturn { ret.push_str("_Noreturn "); @@ -568,7 +635,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { match results.len() { 0 => ret.push_str("void "), 1 => { - ret.push_str(wasm_type(&results[0])); + ret.push_str(c_wasm_type(&results[0])); ret.push_str(" "); } _ => unimplemented!(), @@ -579,7 +646,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { ret.push_str("_"); ret.push_str(&ident_name(&func.name)); ret.push_str("("); - print_c_typeref_names(ret, func); + print_c_typeref_names(ret, func, ¶ms); ret.push_str(") __attribute__((\n"); ret.push_str(&format!( @@ -607,198 +674,17 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { } } } - - func.call_wasm( - module_name, - &mut C { - src: ret, - params: &func.params, - block_storage: Vec::new(), - blocks: Vec::new(), - }, - ); - - ret.push_str("}\n\n"); - - /// This is a structure which implements the glue necessary to translate - /// between the C API of a function and the desired WASI ABI we're being - /// told it has. - /// - /// It's worth nothing that this will, in the long run, get much fancier. - /// For now this is extremely simple and entirely assumes that the WASI ABI - /// matches our C ABI. This means it will only really generate valid code - /// as-is *today* and won't work for any updates to the WASI ABI in the - /// future. - /// - /// It's hoped that this situation will improve as interface types and witx - /// continue to evolve and there's a more clear path forward for how to - /// translate an interface types signature to a C API. - struct C<'a> { - src: &'a mut String, - params: &'a [InterfaceFuncParam], - block_storage: Vec, - blocks: Vec, - } - - impl Bindgen for C<'_> { - type Operand = String; - - fn push_block(&mut self) { - let prev = mem::replace(self.src, String::new()); - self.block_storage.push(prev); - } - - fn finish_block(&mut self, operand: Option) { - let to_restore = self.block_storage.pop().unwrap(); - let src = mem::replace(self.src, to_restore); - assert!(src.is_empty()); - match operand { - None => self.blocks.push(String::new()), - Some(s) => self.blocks.push(s), - } - } - - fn allocate_space(&mut self, _: usize, _: &NamedType) { - // not necessary due to us taking parameters as pointers - } - - fn emit( - &mut self, - inst: &Instruction<'_>, - operands: &mut Vec, - results: &mut Vec, - ) { - let mut top_as = |cvt: &str| { - let s = operands.pop().unwrap(); - results.push(format!("({}) {}", cvt, s)); - }; - - match inst { - Instruction::GetArg { nth } => { - results.push(ident_name(&self.params[*nth].name)); - } - // For the C bindings right now any parameter which needs its - // address taken is already taken as a pointer, so we can just - // forward the operand to the result. - Instruction::AddrOf => results.push(operands.pop().unwrap()), - - Instruction::I64FromU64 => top_as("int64_t"), - Instruction::I32FromPointer - | Instruction::I32FromConstPointer - | Instruction::I32FromHandle { .. } - | Instruction::I32FromUsize - | Instruction::I32FromChar - | Instruction::I32FromU8 - | Instruction::I32FromS8 - | Instruction::I32FromChar8 - | Instruction::I32FromU16 - | Instruction::I32FromS16 - | Instruction::I32FromU32 => top_as("int32_t"), - - Instruction::I32FromBitflags { .. } | Instruction::I64FromBitflags { .. } => { - // Rely on C's casting for this - results.push(operands.pop().unwrap()); - } - - // No conversion necessary - Instruction::F32FromIf32 - | Instruction::F64FromIf64 - | Instruction::If32FromF32 - | Instruction::If64FromF64 - | Instruction::I64FromS64 - | Instruction::I32FromS32 => results.push(operands.pop().unwrap()), - - Instruction::ListPointerLength => { - let list = operands.pop().unwrap(); - results.push(format!("{}", list)); - results.push(format!("{}_len", list)); - } - Instruction::ReturnPointerGet { n } => { - // We currently match the wasi ABI with the actual - // function's API signature in C, this means when a return - // pointer is asked for we can simply forward our parameter - // that's a return pointer. - results.push(format!("retptr{}", n)); - } - - Instruction::Load { .. } => { - // this is currently skipped because return pointers are - // already evident in parameters and so we don't need to - // load/store from them again - results.push("dummy".to_string()); - } - - Instruction::ReuseReturn => { - results.push("ret".to_string()); - } - - Instruction::TupleLift { .. } => { - // this is currently skipped because tuples are only used - // as return values and those are always returned through - // out-ptrs, so the values have already been passed through - // at this point. - results.push("dummy".to_string()); - } - - Instruction::ResultLift => { - let err = self.blocks.pop().unwrap(); - - // Our ok block should either have done nothing (meaning - // there's no "ok" payload) or it loaded a return pointer - // and/or tuple some values. In all these cases we discard - // the results since out pointers have already been written - // to and we only return the discriminant from the - // function. - let ok = self.blocks.pop().unwrap(); - assert!(ok == "dummy" || ok == ""); - - // Note that we just push the result of the error block. - // Our block management asserts that it's an expression, - // which in this case will basically always be casting the - // error code to an error code variant, which we return. - results.push(err); - } - - // Enums are represented in C simply as the integral tag type - Instruction::EnumLift { ty } => match &**ty.type_() { - Type::Variant(v) => top_as(intrepr_name(v.tag_repr)), - _ => unreachable!(), - }, - Instruction::EnumLower { .. } => top_as("int32_t"), - - Instruction::CallWasm { - module, - name, - params: _, - results: func_results, - } => { - assert!(func_results.len() < 2); - self.src.push_str(" "); - if func_results.len() > 0 { - self.src.push_str(wasm_type(&func_results[0])); - self.src.push_str(" ret = "); - results.push("ret".to_string()); - } - self.src.push_str("__imported_"); - self.src.push_str(module); - self.src.push_str("_"); - self.src.push_str(name); - self.src.push_str("("); - self.src.push_str(&operands.join(", ")); - self.src.push_str(");\n"); - } - - Instruction::Return { amt: 0 } => {} - Instruction::Return { amt: 1 } => { - self.src.push_str(" return "); - self.src.push_str(&operands[0]); - self.src.push_str(";\n"); - } - - other => panic!("unimplemented instruction {:?}", other), - } - } + ret.push_str(" "); + if !func.noreturn { + ret.push_str("return (__wasi_errno_t) "); } + ret.push_str("__imported_"); + ret.push_str(&ident_name(module_name)); + ret.push_str("_"); + ret.push_str(&ident_name(&func.name)); + ret.push_str("("); + print_c_casting_names(ret,func,¶ms); + ret.push_str(");\n}\n\n"); } fn push_return_type(ret: &mut String, params: &mut Vec<(Option, String)>, tref: &TypeRef) { @@ -940,7 +826,7 @@ fn intrepr_const(i: IntRepr) -> &'static str { IntRepr::U64 => "UINT64_C", } } - +/* fn wasm_type(wasm: &WasmType) -> &'static str { match wasm { WasmType::I32 => "int32_t", @@ -949,3 +835,13 @@ fn wasm_type(wasm: &WasmType) -> &'static str { WasmType::F64 => "double", } } +*/ + +fn c_wasm_type(wasm: &WasmType) -> &'static str { + match wasm { + WasmType::I32 => "uint32_t", + WasmType::I64 => "uint64_t", + WasmType::F32 => "float", + WasmType::F64 => "double", + } +} From 2659f2abb7160b6ab2371ff801f9b65a51cc28e7 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Thu, 26 Oct 2023 16:16:32 -0400 Subject: [PATCH 07/43] fix __wasi_thread_spawn's return type --- libc-bottom-half/headers/public/wasi/api.h | 2 +- libc-bottom-half/sources/__wasilibc_real.c | 4 ++-- tools/wasi-headers/src/c_header.rs | 6 +++--- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 0e2cd7237..c19facf56 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -2201,7 +2201,7 @@ __wasi_errno_t __wasi_sock_shutdown( * * @see https://github.com/WebAssembly/wasi-threads/#readme */ -__wasi_errno_t __wasi_thread_spawn( +int32_t __wasi_thread_spawn( /** * A pointer to an opaque struct to be passed to the module's entry * function. diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 8356e2bc2..8c42516ad 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -632,7 +632,7 @@ uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attrib __import_name__("thread_spawn") )); -__wasi_errno_t __wasi_thread_spawn(void* start_arg) { - return (__wasi_errno_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +int32_t __wasi_thread_spawn(void* start_arg) { + return (int32_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); } #endif diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 924643a21..e22e0b177 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -114,7 +114,7 @@ extern "C" {{ * * @see https://github.com/WebAssembly/wasi-threads/#readme */ -__wasi_errno_t __wasi_thread_spawn( +int32_t __wasi_thread_spawn( /** * A pointer to an opaque struct to be passed to the module's entry * function. @@ -138,8 +138,8 @@ uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attrib __import_name__("thread_spawn") )); -__wasi_errno_t __wasi_thread_spawn(void* start_arg) { - return (__wasi_errno_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +int32_t __wasi_thread_spawn(void* start_arg) { + return (int32_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); } #endif "# From 3b15bd140d3581700c31b354387e1db436347355 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Thu, 26 Oct 2023 16:24:04 -0400 Subject: [PATCH 08/43] change header of api.h to temporarily manually maintained --- libc-bottom-half/headers/public/wasi/api.h | 14 +++++--------- tools/wasi-headers/src/c_header.rs | 14 +++++--------- 2 files changed, 10 insertions(+), 18 deletions(-) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index c19facf56..1afffbd27 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -1,13 +1,9 @@ /** - * THIS FILE IS AUTO-GENERATED from the following files: - * wasi_snapshot_preview1.witx - * - * To regenerate this file execute: - * - * cargo run --manifest-path tools/wasi-headers/Cargo.toml generate-libc - * - * Modifications to this file will cause CI to fail, the code generator tool - * must be modified to change this file. + * . This file contains declarations describing the WASI ABI + * as of "snapshot preview1". It was originally auto-generated from + * wasi_snapshot_preview1.witx, however WASI is in the process of + * transitioning to a new IDL and header file generator, and this file + * is temporarily being manually maintained. * * @file * This file describes the [WASI] interface, consisting of functions, types, diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index e22e0b177..b79705e0e 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -12,15 +12,11 @@ pub fn to_c(doc: &Document, inputs_str: &str) -> Generated { header.push_str(&format!( r#"/** - * THIS FILE IS AUTO-GENERATED from the following files: - * {} - * - * To regenerate this file execute: - * - * cargo run --manifest-path tools/wasi-headers/Cargo.toml generate-libc - * - * Modifications to this file will cause CI to fail, the code generator tool - * must be modified to change this file. + * . This file contains declarations describing the WASI ABI + * as of "snapshot preview1". It was originally auto-generated from + * {}, however WASI is in the process of + * transitioning to a new IDL and header file generator, and this file + * is temporarily being manually maintained. * * @file * This file describes the [WASI] interface, consisting of functions, types, From 48e8b257725d12ea26a3dab4866746d30d5e5f7e Mon Sep 17 00:00:00 2001 From: trcrsired Date: Thu, 26 Oct 2023 19:58:04 -0400 Subject: [PATCH 09/43] Fix formatting issue for rustfmt --- tools/wasi-headers/src/c_header.rs | 209 +++++++++++++++-------------- 1 file changed, 109 insertions(+), 100 deletions(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index b79705e0e..89436083c 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -124,7 +124,7 @@ int32_t __wasi_thread_spawn( #endif #endif -"# +"#, ); source.push_str( @@ -138,7 +138,7 @@ int32_t __wasi_thread_spawn(void* start_arg) { return (int32_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); } #endif -"# +"#, ); Generated { header, source } @@ -189,18 +189,18 @@ fn print_alias(ret: &mut String, name: &Id, dest: &TypeRef) { )); } ret.push_str("\n"); -/* - ret.push_str(&format!( - "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", - ident_name(name), - dest.mem_size_align().size - )); - ret.push_str(&format!( - "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", - ident_name(name), - dest.mem_size_align().align - )); -*/ + /* + ret.push_str(&format!( + "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", + ident_name(name), + dest.mem_size_align().size + )); + ret.push_str(&format!( + "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", + ident_name(name), + dest.mem_size_align().align + )); + */ ret.push_str("\n"); } } @@ -231,18 +231,18 @@ fn print_enum(ret: &mut String, name: &Id, v: &Variant) { )); ret.push_str("\n"); } -/* - ret.push_str(&format!( - "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", - ident_name(name), - v.tag_repr.mem_size() - )); - ret.push_str(&format!( - "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", - ident_name(name), - v.tag_repr.mem_align() - )); -*/ + /* + ret.push_str(&format!( + "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", + ident_name(name), + v.tag_repr.mem_size() + )); + ret.push_str(&format!( + "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", + ident_name(name), + v.tag_repr.mem_align() + )); + */ ret.push_str("\n"); } @@ -313,27 +313,27 @@ fn print_record(ret: &mut String, name: &Id, s: &RecordDatatype) { ret.push_str(&format!("}} __wasi_{}_t;\n", ident_name(name))); ret.push_str("\n"); -/* - ret.push_str(&format!( - "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", - ident_name(name), - s.mem_size() - )); - ret.push_str(&format!( - "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", - ident_name(name), - s.mem_align() - )); - - for layout in s.member_layout() { + /* ret.push_str(&format!( - "_Static_assert(offsetof(__wasi_{}_t, {}) == {}, \"witx calculated offset\");\n", + "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", ident_name(name), - ident_name(&layout.member.name), - layout.offset + s.mem_size() )); - } -*/ + ret.push_str(&format!( + "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", + ident_name(name), + s.mem_align() + )); + + for layout in s.member_layout() { + ret.push_str(&format!( + "_Static_assert(offsetof(__wasi_{}_t, {}) == {}, \"witx calculated offset\");\n", + ident_name(name), + ident_name(&layout.member.name), + layout.offset + )); + } + */ ret.push_str("\n"); } @@ -374,35 +374,35 @@ fn print_variant(ret: &mut String, name: &Id, v: &Variant) { ret.push_str(&format!("}} __wasi_{}_t;\n", ident_name(name))); ret.push_str("\n"); -/* - ret.push_str(&format!( - "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", - ident_name(name), - v.mem_size() - )); - ret.push_str(&format!( - "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", - ident_name(name), - v.mem_align() - )); -*/ + /* + ret.push_str(&format!( + "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", + ident_name(name), + v.mem_size() + )); + ret.push_str(&format!( + "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", + ident_name(name), + v.mem_align() + )); + */ ret.push_str("\n"); } fn print_handle(ret: &mut String, name: &Id, _h: &HandleDatatype) { ret.push_str(&format!("typedef int __wasi_{}_t;\n\n", ident_name(name))); -/* - ret.push_str(&format!( - "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", - ident_name(name), - h.mem_size() - )); - ret.push_str(&format!( - "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", - ident_name(name), - h.mem_align() - )); -*/ + /* + ret.push_str(&format!( + "_Static_assert(sizeof(__wasi_{}_t) == {}, \"witx calculated size\");\n", + ident_name(name), + h.mem_size() + )); + ret.push_str(&format!( + "_Static_assert(_Alignof(__wasi_{}_t) == {}, \"witx calculated align\");\n", + ident_name(name), + h.mem_align() + )); + */ ret.push_str("\n"); } @@ -516,44 +516,50 @@ fn c_typeref_name(tref: &TypeRef, wtp: &witx::WasmType) -> String { } } -fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec, casting: bool) { +fn print_c_typeref_casting_names( + ret: &mut String, + func: &InterfaceFunc, + signparams: &std::vec::Vec, + casting: bool, +) { let mut iszero = true; let mut j = 0; for param in func.params.iter() { if iszero { iszero = false - } - else { + } else { ret.push_str(", "); } let identifiername = ident_name(¶m.name); match &**param.tref.type_() { - Type::List(_)=> { + Type::List(_) => { if casting { - ret.push_str(&format!("(uintptr_t) {0}, (__wasi_size_t) {0}_len",&identifiername)); - } - else { + ret.push_str(&format!( + "(uintptr_t) {0}, (__wasi_size_t) {0}_len", + &identifiername + )); + } else { ret.push_str("uintptr_t, __wasi_size_t"); } j = j + 2; - }, + } _ => { // Fix around buf_len which is incorrectly marked uint32_t in metadata if identifiername.ends_with("_len") { if casting { - ret.push_str(&format!("(__wasi_size_t) {}",&identifiername)); - } - else { + ret.push_str(&format!("(__wasi_size_t) {}", &identifiername)); + } else { ret.push_str("__wasi_size_t"); } - } - else - { + } else { if casting { - ret.push_str(&format!("({}) {}",c_typeref_name(¶m.tref,&signparams[j]),&identifiername)); - } - else { - ret.push_str(&c_typeref_name(¶m.tref,&signparams[j])); + ret.push_str(&format!( + "({}) {}", + c_typeref_name(¶m.tref, &signparams[j]), + &identifiername + )); + } else { + ret.push_str(&c_typeref_name(¶m.tref, &signparams[j])); } } j = j + 1; @@ -561,8 +567,7 @@ fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signpar } } match func.results.len() { - 0 => { - } + 0 => {} 1 => { assert!(!func.noreturn); @@ -578,17 +583,15 @@ fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signpar }; match &**ok.type_() { Type::Record(r) if r.is_tuple() => { - for (i,_) in r.members.iter().enumerate() { + for (i, _) in r.members.iter().enumerate() { if iszero { iszero = false - } - else { + } else { ret.push_str(", "); } if casting { - ret.push_str(&format!("(uintptr_t) retptr{}",i)); - } - else { + ret.push_str(&format!("(uintptr_t) retptr{}", i)); + } else { ret.push_str("uintptr_t"); } } @@ -599,11 +602,9 @@ fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signpar } if casting { ret.push_str("(uintptr_t) retptr0"); - } - else { + } else { ret.push_str("uintptr_t"); } - } } } @@ -614,11 +615,19 @@ fn print_c_typeref_casting_names(ret: &mut String, func: &InterfaceFunc, signpar } } -fn print_c_typeref_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec) { +fn print_c_typeref_names( + ret: &mut String, + func: &InterfaceFunc, + signparams: &std::vec::Vec, +) { (print_c_typeref_casting_names(ret, func, signparams, false)); } -fn print_c_casting_names(ret: &mut String, func: &InterfaceFunc, signparams: &std::vec::Vec) { +fn print_c_casting_names( + ret: &mut String, + func: &InterfaceFunc, + signparams: &std::vec::Vec, +) { (print_c_typeref_casting_names(ret, func, signparams, true)); } @@ -679,7 +688,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { ret.push_str("_"); ret.push_str(&ident_name(&func.name)); ret.push_str("("); - print_c_casting_names(ret,func,¶ms); + print_c_casting_names(ret, func, ¶ms); ret.push_str(");\n}\n\n"); } From a5ad6846894df028804bc00b6c6eadffa895c9e3 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Mon, 30 Oct 2023 17:47:03 -0400 Subject: [PATCH 10/43] Remove all signal apis --- .../wasm64-wasi-threads/defined-symbols.txt | 1 - .../wasm64-wasi-threads/predefined-macros.txt | 31 --- .../wasm64-wasi-threads/undefined-symbols.txt | 1 - expected/wasm64-wasi/defined-symbols.txt | 1 - expected/wasm64-wasi/predefined-macros.txt | 31 --- expected/wasm64-wasi/undefined-symbols.txt | 1 - libc-bottom-half/headers/public/wasi/api.h | 202 ------------------ libc-bottom-half/sources/__wasilibc_real.c | 11 - 8 files changed, 279 deletions(-) diff --git a/expected/wasm64-wasi-threads/defined-symbols.txt b/expected/wasm64-wasi-threads/defined-symbols.txt index ff2aa835a..c913f1620 100644 --- a/expected/wasm64-wasi-threads/defined-symbols.txt +++ b/expected/wasm64-wasi-threads/defined-symbols.txt @@ -348,7 +348,6 @@ __wasi_path_symlink __wasi_path_unlink_file __wasi_poll_oneoff __wasi_proc_exit -__wasi_proc_raise __wasi_random_get __wasi_sched_yield __wasi_sock_accept diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt index ecc94b942..e509232da 100644 --- a/expected/wasm64-wasi-threads/predefined-macros.txt +++ b/expected/wasm64-wasi-threads/predefined-macros.txt @@ -2996,37 +2996,6 @@ #define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) #define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) #define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) -#define __WASI_SIGNAL_ABRT (UINT8_C(6)) -#define __WASI_SIGNAL_ALRM (UINT8_C(14)) -#define __WASI_SIGNAL_BUS (UINT8_C(7)) -#define __WASI_SIGNAL_CHLD (UINT8_C(16)) -#define __WASI_SIGNAL_CONT (UINT8_C(17)) -#define __WASI_SIGNAL_FPE (UINT8_C(8)) -#define __WASI_SIGNAL_HUP (UINT8_C(1)) -#define __WASI_SIGNAL_ILL (UINT8_C(4)) -#define __WASI_SIGNAL_INT (UINT8_C(2)) -#define __WASI_SIGNAL_KILL (UINT8_C(9)) -#define __WASI_SIGNAL_NONE (UINT8_C(0)) -#define __WASI_SIGNAL_PIPE (UINT8_C(13)) -#define __WASI_SIGNAL_POLL (UINT8_C(28)) -#define __WASI_SIGNAL_PROF (UINT8_C(26)) -#define __WASI_SIGNAL_PWR (UINT8_C(29)) -#define __WASI_SIGNAL_QUIT (UINT8_C(3)) -#define __WASI_SIGNAL_SEGV (UINT8_C(11)) -#define __WASI_SIGNAL_STOP (UINT8_C(18)) -#define __WASI_SIGNAL_SYS (UINT8_C(30)) -#define __WASI_SIGNAL_TERM (UINT8_C(15)) -#define __WASI_SIGNAL_TRAP (UINT8_C(5)) -#define __WASI_SIGNAL_TSTP (UINT8_C(19)) -#define __WASI_SIGNAL_TTIN (UINT8_C(20)) -#define __WASI_SIGNAL_TTOU (UINT8_C(21)) -#define __WASI_SIGNAL_URG (UINT8_C(22)) -#define __WASI_SIGNAL_USR1 (UINT8_C(10)) -#define __WASI_SIGNAL_USR2 (UINT8_C(12)) -#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) -#define __WASI_SIGNAL_WINCH (UINT8_C(27)) -#define __WASI_SIGNAL_XCPU (UINT8_C(23)) -#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) #define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) #define __WASI_WHENCE_CUR (UINT8_C(1)) #define __WASI_WHENCE_END (UINT8_C(2)) diff --git a/expected/wasm64-wasi-threads/undefined-symbols.txt b/expected/wasm64-wasi-threads/undefined-symbols.txt index f58bcd069..cef3741a8 100644 --- a/expected/wasm64-wasi-threads/undefined-symbols.txt +++ b/expected/wasm64-wasi-threads/undefined-symbols.txt @@ -54,7 +54,6 @@ __imported_wasi_snapshot_preview1_path_symlink __imported_wasi_snapshot_preview1_path_unlink_file __imported_wasi_snapshot_preview1_poll_oneoff __imported_wasi_snapshot_preview1_proc_exit -__imported_wasi_snapshot_preview1_proc_raise __imported_wasi_snapshot_preview1_random_get __imported_wasi_snapshot_preview1_sched_yield __imported_wasi_snapshot_preview1_sock_accept diff --git a/expected/wasm64-wasi/defined-symbols.txt b/expected/wasm64-wasi/defined-symbols.txt index 7e3836c71..6e743228b 100644 --- a/expected/wasm64-wasi/defined-symbols.txt +++ b/expected/wasm64-wasi/defined-symbols.txt @@ -292,7 +292,6 @@ __wasi_path_symlink __wasi_path_unlink_file __wasi_poll_oneoff __wasi_proc_exit -__wasi_proc_raise __wasi_random_get __wasi_sched_yield __wasi_sock_accept diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt index a94cfd2ee..abeaa52a9 100644 --- a/expected/wasm64-wasi/predefined-macros.txt +++ b/expected/wasm64-wasi/predefined-macros.txt @@ -2959,37 +2959,6 @@ #define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) #define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) #define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) -#define __WASI_SIGNAL_ABRT (UINT8_C(6)) -#define __WASI_SIGNAL_ALRM (UINT8_C(14)) -#define __WASI_SIGNAL_BUS (UINT8_C(7)) -#define __WASI_SIGNAL_CHLD (UINT8_C(16)) -#define __WASI_SIGNAL_CONT (UINT8_C(17)) -#define __WASI_SIGNAL_FPE (UINT8_C(8)) -#define __WASI_SIGNAL_HUP (UINT8_C(1)) -#define __WASI_SIGNAL_ILL (UINT8_C(4)) -#define __WASI_SIGNAL_INT (UINT8_C(2)) -#define __WASI_SIGNAL_KILL (UINT8_C(9)) -#define __WASI_SIGNAL_NONE (UINT8_C(0)) -#define __WASI_SIGNAL_PIPE (UINT8_C(13)) -#define __WASI_SIGNAL_POLL (UINT8_C(28)) -#define __WASI_SIGNAL_PROF (UINT8_C(26)) -#define __WASI_SIGNAL_PWR (UINT8_C(29)) -#define __WASI_SIGNAL_QUIT (UINT8_C(3)) -#define __WASI_SIGNAL_SEGV (UINT8_C(11)) -#define __WASI_SIGNAL_STOP (UINT8_C(18)) -#define __WASI_SIGNAL_SYS (UINT8_C(30)) -#define __WASI_SIGNAL_TERM (UINT8_C(15)) -#define __WASI_SIGNAL_TRAP (UINT8_C(5)) -#define __WASI_SIGNAL_TSTP (UINT8_C(19)) -#define __WASI_SIGNAL_TTIN (UINT8_C(20)) -#define __WASI_SIGNAL_TTOU (UINT8_C(21)) -#define __WASI_SIGNAL_URG (UINT8_C(22)) -#define __WASI_SIGNAL_USR1 (UINT8_C(10)) -#define __WASI_SIGNAL_USR2 (UINT8_C(12)) -#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) -#define __WASI_SIGNAL_WINCH (UINT8_C(27)) -#define __WASI_SIGNAL_XCPU (UINT8_C(23)) -#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) #define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) #define __WASI_WHENCE_CUR (UINT8_C(1)) #define __WASI_WHENCE_END (UINT8_C(2)) diff --git a/expected/wasm64-wasi/undefined-symbols.txt b/expected/wasm64-wasi/undefined-symbols.txt index 0890c5217..e7c62031f 100644 --- a/expected/wasm64-wasi/undefined-symbols.txt +++ b/expected/wasm64-wasi/undefined-symbols.txt @@ -52,7 +52,6 @@ __imported_wasi_snapshot_preview1_path_symlink __imported_wasi_snapshot_preview1_path_unlink_file __imported_wasi_snapshot_preview1_poll_oneoff __imported_wasi_snapshot_preview1_proc_exit -__imported_wasi_snapshot_preview1_proc_raise __imported_wasi_snapshot_preview1_random_get __imported_wasi_snapshot_preview1_sched_yield __imported_wasi_snapshot_preview1_sock_accept diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 1afffbd27..830a6839f 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -1206,198 +1206,6 @@ typedef struct __wasi_subscription_t { typedef uint32_t __wasi_exitcode_t; -/** - * Signal condition. - */ -typedef uint8_t __wasi_signal_t; - -/** - * No signal. Note that POSIX has special semantics for `kill(pid, 0)`, - * so this value is reserved. - */ -#define __WASI_SIGNAL_NONE (UINT8_C(0)) - -/** - * Hangup. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_HUP (UINT8_C(1)) - -/** - * Terminate interrupt signal. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_INT (UINT8_C(2)) - -/** - * Terminal quit signal. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_QUIT (UINT8_C(3)) - -/** - * Illegal instruction. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_ILL (UINT8_C(4)) - -/** - * Trace/breakpoint trap. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_TRAP (UINT8_C(5)) - -/** - * Process abort signal. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_ABRT (UINT8_C(6)) - -/** - * Access to an undefined portion of a memory object. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_BUS (UINT8_C(7)) - -/** - * Erroneous arithmetic operation. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_FPE (UINT8_C(8)) - -/** - * Kill. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_KILL (UINT8_C(9)) - -/** - * User-defined signal 1. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_USR1 (UINT8_C(10)) - -/** - * Invalid memory reference. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_SEGV (UINT8_C(11)) - -/** - * User-defined signal 2. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_USR2 (UINT8_C(12)) - -/** - * Write on a pipe with no one to read it. - * Action: Ignored. - */ -#define __WASI_SIGNAL_PIPE (UINT8_C(13)) - -/** - * Alarm clock. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_ALRM (UINT8_C(14)) - -/** - * Termination signal. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_TERM (UINT8_C(15)) - -/** - * Child process terminated, stopped, or continued. - * Action: Ignored. - */ -#define __WASI_SIGNAL_CHLD (UINT8_C(16)) - -/** - * Continue executing, if stopped. - * Action: Continues executing, if stopped. - */ -#define __WASI_SIGNAL_CONT (UINT8_C(17)) - -/** - * Stop executing. - * Action: Stops executing. - */ -#define __WASI_SIGNAL_STOP (UINT8_C(18)) - -/** - * Terminal stop signal. - * Action: Stops executing. - */ -#define __WASI_SIGNAL_TSTP (UINT8_C(19)) - -/** - * Background process attempting read. - * Action: Stops executing. - */ -#define __WASI_SIGNAL_TTIN (UINT8_C(20)) - -/** - * Background process attempting write. - * Action: Stops executing. - */ -#define __WASI_SIGNAL_TTOU (UINT8_C(21)) - -/** - * High bandwidth data is available at a socket. - * Action: Ignored. - */ -#define __WASI_SIGNAL_URG (UINT8_C(22)) - -/** - * CPU time limit exceeded. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_XCPU (UINT8_C(23)) - -/** - * File size limit exceeded. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_XFSZ (UINT8_C(24)) - -/** - * Virtual timer expired. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_VTALRM (UINT8_C(25)) - -/** - * Profiling timer expired. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_PROF (UINT8_C(26)) - -/** - * Window changed. - * Action: Ignored. - */ -#define __WASI_SIGNAL_WINCH (UINT8_C(27)) - -/** - * I/O possible. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_POLL (UINT8_C(28)) - -/** - * Power failure. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_PWR (UINT8_C(29)) - -/** - * Bad system call. - * Action: Terminates the process. - */ -#define __WASI_SIGNAL_SYS (UINT8_C(30)) - - /** * Flags provided to `sock_recv`. */ @@ -2078,16 +1886,6 @@ _Noreturn void __wasi_proc_exit( */ __wasi_exitcode_t rval ); -/** - * Send a signal to the process of the calling thread. - * Note: This is similar to `raise` in POSIX. - */ -__wasi_errno_t __wasi_proc_raise( - /** - * The signal condition to trigger. - */ - __wasi_signal_t sig -) __attribute__((__warn_unused_result__)); /** * Temporarily yield execution of the calling thread. * Note: This is similar to `sched_yield` in POSIX. diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 8c42516ad..d758cb09f 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -536,17 +536,6 @@ _Noreturn void __wasi_proc_exit( __imported_wasi_snapshot_preview1_proc_exit((uint32_t) rval); } -uint32_t __imported_wasi_snapshot_preview1_proc_raise(uint32_t) __attribute__(( - __import_module__("wasi_snapshot_preview1"), - __import_name__("proc_raise") -)); - -__wasi_errno_t __wasi_proc_raise( - __wasi_signal_t sig -){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_proc_raise((uint32_t) sig); -} - uint32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sched_yield") From b9d273807a04c53ecfd95be974a2d721c674fe3b Mon Sep 17 00:00:00 2001 From: trcrsired Date: Mon, 30 Oct 2023 23:33:22 -0400 Subject: [PATCH 11/43] Fix symbol of thread_spawn Add noexcept to wasi header to avoid abi bugs with C++ --- .../wasm32-wasi-threads/predefined-macros.txt | 1 + expected/wasm32-wasi/predefined-macros.txt | 1 + .../wasm64-wasi-threads/predefined-macros.txt | 1 + .../wasm64-wasi-threads/undefined-symbols.txt | 2 +- expected/wasm64-wasi/predefined-macros.txt | 1 + libc-bottom-half/headers/public/wasi/api.h | 102 ++++++++++-------- libc-bottom-half/sources/__wasilibc_real.c | 100 ++++++++--------- tools/wasi-headers/src/c_header.rs | 26 +++-- 8 files changed, 129 insertions(+), 105 deletions(-) diff --git a/expected/wasm32-wasi-threads/predefined-macros.txt b/expected/wasm32-wasi-threads/predefined-macros.txt index 820f84911..7acb3ea91 100644 --- a/expected/wasm32-wasi-threads/predefined-macros.txt +++ b/expected/wasm32-wasi-threads/predefined-macros.txt @@ -2956,6 +2956,7 @@ #define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) #define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) #define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT #define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) #define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) #define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) diff --git a/expected/wasm32-wasi/predefined-macros.txt b/expected/wasm32-wasi/predefined-macros.txt index 2f2ca8fdb..9f5bc6404 100644 --- a/expected/wasm32-wasi/predefined-macros.txt +++ b/expected/wasm32-wasi/predefined-macros.txt @@ -2919,6 +2919,7 @@ #define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) #define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) #define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT #define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) #define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) #define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt index e509232da..ef26687d8 100644 --- a/expected/wasm64-wasi-threads/predefined-macros.txt +++ b/expected/wasm64-wasi-threads/predefined-macros.txt @@ -2956,6 +2956,7 @@ #define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) #define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) #define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT #define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) #define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) #define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) diff --git a/expected/wasm64-wasi-threads/undefined-symbols.txt b/expected/wasm64-wasi-threads/undefined-symbols.txt index cef3741a8..938e64776 100644 --- a/expected/wasm64-wasi-threads/undefined-symbols.txt +++ b/expected/wasm64-wasi-threads/undefined-symbols.txt @@ -60,7 +60,7 @@ __imported_wasi_snapshot_preview1_sock_accept __imported_wasi_snapshot_preview1_sock_recv __imported_wasi_snapshot_preview1_sock_send __imported_wasi_snapshot_preview1_sock_shutdown -__imported_wasi_snapshot_preview2_thread_spawn +__imported_wasi_thread_spawn __letf2 __lttf2 __netf2 diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt index abeaa52a9..f0d687b74 100644 --- a/expected/wasm64-wasi/predefined-macros.txt +++ b/expected/wasm64-wasi/predefined-macros.txt @@ -2919,6 +2919,7 @@ #define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) #define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) #define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT #define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) #define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) #define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 830a6839f..bd96361d2 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -40,6 +40,16 @@ _Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); extern "C" { #endif +#ifdef __cplusplus +#if __cplusplus >= 201103L +#define __WASI_NOEXCEPT noexcept +#else +#define __WASI_NOEXCEPT throw() +#endif +#else +#define __WASI_NOEXCEPT +#endif + // TODO: Encoding this in witx. #define __WASI_DIRCOOKIE_START (UINT64_C(0)) typedef __SIZE_TYPE__ __wasi_size_t; @@ -1301,7 +1311,7 @@ typedef struct __wasi_prestat_t { __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return command-line argument data sizes. * @return @@ -1311,7 +1321,7 @@ __wasi_errno_t __wasi_args_get( __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read environment variable data. * The sizes of the buffers should match that returned by `environ_sizes_get`. @@ -1320,7 +1330,7 @@ __wasi_errno_t __wasi_args_sizes_get( __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return environment variable data sizes. * @return @@ -1330,7 +1340,7 @@ __wasi_errno_t __wasi_environ_get( __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the resolution of a clock. * Implementations are required to provide a non-zero value for supported clocks. For unsupported clocks, @@ -1345,7 +1355,7 @@ __wasi_errno_t __wasi_clock_res_get( */ __wasi_clockid_t id, __wasi_timestamp_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the time value of a clock. * Note: This is similar to `clock_gettime` in POSIX. @@ -1362,7 +1372,7 @@ __wasi_errno_t __wasi_clock_time_get( */ __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Provide file advisory information on a file descriptor. * Note: This is similar to `posix_fadvise` in POSIX. @@ -1381,7 +1391,7 @@ __wasi_errno_t __wasi_fd_advise( * The advice. */ __wasi_advice_t advice -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Force the allocation of space in a file. * Note: This is similar to `posix_fallocate` in POSIX. @@ -1396,21 +1406,21 @@ __wasi_errno_t __wasi_fd_allocate( * The length of the area that is allocated. */ __wasi_filesize_t len -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Close a file descriptor. * Note: This is similar to `close` in POSIX. */ __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Synchronize the data of a file to disk. * Note: This is similar to `fdatasync` in POSIX. */ __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Get the attributes of a file descriptor. * Note: This returns similar flags to `fsync(fd, F_GETFL)` in POSIX, as well as additional fields. @@ -1420,7 +1430,7 @@ __wasi_errno_t __wasi_fd_datasync( __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the flags associated with a file descriptor. * Note: This is similar to `fcntl(fd, F_SETFL, flags)` in POSIX. @@ -1431,7 +1441,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( * The desired values of the file descriptor flags. */ __wasi_fdflags_t flags -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the rights associated with a file descriptor. * This can only be used to remove rights, and returns `errno::notcapable` if called in a way that would attempt to add rights @@ -1443,7 +1453,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( */ __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the attributes of an open file. * @return @@ -1452,7 +1462,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the size of an open file. If this increases the file's size, the extra bytes are filled with zeros. * Note: This is similar to `ftruncate` in POSIX. @@ -1463,7 +1473,7 @@ __wasi_errno_t __wasi_fd_filestat_set_size( * The desired file size. */ __wasi_filesize_t size -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the timestamps of an open file or directory. * Note: This is similar to `futimens` in POSIX. @@ -1482,7 +1492,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( * A bitmask indicating which timestamps to adjust. */ __wasi_fstflags_t fst_flags -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read from a file descriptor, without using and updating the file descriptor's offset. * Note: This is similar to `preadv` in POSIX. @@ -1504,7 +1514,7 @@ __wasi_errno_t __wasi_fd_pread( */ __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return a description of the given preopened file descriptor. * @return @@ -1513,7 +1523,7 @@ __wasi_errno_t __wasi_fd_pread( __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return a description of the given preopened file descriptor. */ @@ -1524,7 +1534,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( */ uint8_t * path, __wasi_size_t path_len -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write to a file descriptor, without using and updating the file descriptor's offset. * Note: This is similar to `pwritev` in POSIX. @@ -1546,7 +1556,7 @@ __wasi_errno_t __wasi_fd_pwrite( */ __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read from a file descriptor. * Note: This is similar to `readv` in POSIX. @@ -1564,7 +1574,7 @@ __wasi_errno_t __wasi_fd_read( */ size_t iovs_len, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read directory entries from a directory. * When successful, the contents of the output buffer consist of a sequence of @@ -1590,7 +1600,7 @@ __wasi_errno_t __wasi_fd_readdir( */ __wasi_dircookie_t cookie, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Atomically replace a file descriptor by renumbering another file descriptor. * Due to the strong focus on thread safety, this environment does not provide @@ -1607,7 +1617,7 @@ __wasi_errno_t __wasi_fd_renumber( * The file descriptor to overwrite. */ __wasi_fd_t to -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Move the offset of a file descriptor. * Note: This is similar to `lseek` in POSIX. @@ -1625,14 +1635,14 @@ __wasi_errno_t __wasi_fd_seek( */ __wasi_whence_t whence, __wasi_filesize_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Synchronize the data and metadata of a file to disk. * Note: This is similar to `fsync` in POSIX. */ __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the current offset of a file descriptor. * Note: This is similar to `lseek(fd, 0, SEEK_CUR)` in POSIX. @@ -1642,7 +1652,7 @@ __wasi_errno_t __wasi_fd_sync( __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write to a file descriptor. * Note: This is similar to `writev` in POSIX. @@ -1658,7 +1668,7 @@ __wasi_errno_t __wasi_fd_write( */ size_t iovs_len, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a directory. * Note: This is similar to `mkdirat` in POSIX. @@ -1669,7 +1679,7 @@ __wasi_errno_t __wasi_path_create_directory( * The path at which to create the directory. */ char const *path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the attributes of a file or directory. * Note: This is similar to `stat` in POSIX. @@ -1687,7 +1697,7 @@ __wasi_errno_t __wasi_path_filestat_get( */ char const *path, __wasi_filestat_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the timestamps of a file or directory. * Note: This is similar to `utimensat` in POSIX. @@ -1714,7 +1724,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( * A bitmask indicating which timestamps to adjust. */ __wasi_fstflags_t fst_flags -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a hard link. * Note: This is similar to `linkat` in POSIX. @@ -1737,7 +1747,7 @@ __wasi_errno_t __wasi_path_link( * The destination path at which to create the hard link. */ char const *new_path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Open a file or directory. * The returned file descriptor is not guaranteed to be the lowest-numbered @@ -1777,7 +1787,7 @@ __wasi_errno_t __wasi_path_open( __wasi_rights_t fs_rights_inheriting, __wasi_fdflags_t fdflags, __wasi_fd_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read the contents of a symbolic link. * Note: This is similar to `readlinkat` in POSIX. @@ -1796,7 +1806,7 @@ __wasi_errno_t __wasi_path_readlink( uint8_t * buf, __wasi_size_t buf_len, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Remove a directory. * Return `errno::notempty` if the directory is not empty. @@ -1808,7 +1818,7 @@ __wasi_errno_t __wasi_path_remove_directory( * The path to a directory to remove. */ char const *path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Rename a file or directory. * Note: This is similar to `renameat` in POSIX. @@ -1827,7 +1837,7 @@ __wasi_errno_t __wasi_path_rename( * The destination path to which to rename the file or directory. */ char const *new_path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a symbolic link. * Note: This is similar to `symlinkat` in POSIX. @@ -1842,7 +1852,7 @@ __wasi_errno_t __wasi_path_symlink( * The destination path at which to create the symbolic link. */ char const *new_path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Unlink a file. * Return `errno::isdir` if the path refers to a directory. @@ -1854,7 +1864,7 @@ __wasi_errno_t __wasi_path_unlink_file( * The path to a file to unlink. */ char const *path -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Concurrently poll for the occurrence of a set of events. * @return @@ -1874,7 +1884,7 @@ __wasi_errno_t __wasi_poll_oneoff( */ __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Terminate the process normally. An exit code of 0 indicates successful * termination of the program. The meanings of other values is dependent on @@ -1885,14 +1895,14 @@ _Noreturn void __wasi_proc_exit( * The exit code returned by the process. */ __wasi_exitcode_t rval -); +) __WASI_NOEXCEPT ; /** * Temporarily yield execution of the calling thread. * Note: This is similar to `sched_yield` in POSIX. */ __wasi_errno_t __wasi_sched_yield( void -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write high-quality random data into a buffer. * This function blocks when the implementation is unable to immediately @@ -1907,7 +1917,7 @@ __wasi_errno_t __wasi_random_get( */ uint8_t * buf, __wasi_size_t buf_len -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Accept a new incoming connection. * Note: This is similar to `accept` in POSIX. @@ -1924,7 +1934,7 @@ __wasi_errno_t __wasi_sock_accept( */ __wasi_fdflags_t flags, __wasi_fd_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Receive a message from a socket. * Note: This is similar to `recv` in POSIX, though it also supports reading @@ -1948,7 +1958,7 @@ __wasi_errno_t __wasi_sock_recv( __wasi_riflags_t ri_flags, __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Send a message on a socket. * Note: This is similar to `send` in POSIX, though it also supports writing @@ -1971,7 +1981,7 @@ __wasi_errno_t __wasi_sock_send( */ __wasi_siflags_t si_flags, __wasi_size_t *retptr0 -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Shut down socket send and receive channels. * Note: This is similar to `shutdown` in POSIX. @@ -1982,7 +1992,7 @@ __wasi_errno_t __wasi_sock_shutdown( * Which channels on the socket to shut down. */ __wasi_sdflags_t how -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** @} */ #ifdef _REENTRANT @@ -2001,7 +2011,7 @@ int32_t __wasi_thread_spawn( * function. */ void *start_arg -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); #endif #ifdef __cplusplus diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index d758cb09f..99a5daf3f 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -13,7 +13,7 @@ #include #include -uint32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_get") )); @@ -25,7 +25,7 @@ __wasi_errno_t __wasi_args_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((uintptr_t) argv, (uintptr_t) argv_buf); } -uint32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_sizes_get") )); @@ -37,7 +37,7 @@ __wasi_errno_t __wasi_args_sizes_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_get") )); @@ -49,7 +49,7 @@ __wasi_errno_t __wasi_environ_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((uintptr_t) environ, (uintptr_t) environ_buf); } -uint32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_sizes_get") )); @@ -61,7 +61,7 @@ __wasi_errno_t __wasi_environ_sizes_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_clock_res_get(uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_clock_res_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_res_get") )); @@ -73,7 +73,7 @@ __wasi_errno_t __wasi_clock_res_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((uint32_t) id, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_clock_time_get(uint32_t, uint64_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_clock_time_get(uint32_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_time_get") )); @@ -86,7 +86,7 @@ __wasi_errno_t __wasi_clock_time_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((uint32_t) id, (uint64_t) precision, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_advise(uint32_t, uint64_t, uint64_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_advise(uint32_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_advise") )); @@ -100,7 +100,7 @@ __wasi_errno_t __wasi_fd_advise( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((uint32_t) fd, (uint64_t) offset, (uint64_t) len, (uint32_t) advice); } -uint32_t __imported_wasi_snapshot_preview1_fd_allocate(uint32_t, uint64_t, uint64_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_allocate(uint32_t, uint64_t, uint64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_allocate") )); @@ -113,7 +113,7 @@ __wasi_errno_t __wasi_fd_allocate( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((uint32_t) fd, (uint64_t) offset, (uint64_t) len); } -uint32_t __imported_wasi_snapshot_preview1_fd_close(uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_close(uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_close") )); @@ -124,7 +124,7 @@ __wasi_errno_t __wasi_fd_close( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((uint32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_datasync(uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_datasync(uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_datasync") )); @@ -135,7 +135,7 @@ __wasi_errno_t __wasi_fd_datasync( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((uint32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_get") )); @@ -147,7 +147,7 @@ __wasi_errno_t __wasi_fd_fdstat_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((uint32_t) fd, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uint32_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_flags") )); @@ -159,7 +159,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((uint32_t) fd, (uint32_t) flags); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uint32_t, uint64_t, uint64_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uint32_t, uint64_t, uint64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_rights") )); @@ -172,7 +172,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((uint32_t) fd, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_get") )); @@ -184,7 +184,7 @@ __wasi_errno_t __wasi_fd_filestat_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((uint32_t) fd, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uint32_t, uint64_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uint32_t, uint64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_size") )); @@ -196,7 +196,7 @@ __wasi_errno_t __wasi_fd_filestat_set_size( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((uint32_t) fd, (uint64_t) size); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uint32_t, uint64_t, uint64_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uint32_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_times") )); @@ -210,7 +210,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((uint32_t) fd, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); } -uint32_t __imported_wasi_snapshot_preview1_fd_pread(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_pread(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pread") )); @@ -225,7 +225,7 @@ __wasi_errno_t __wasi_fd_pread( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_get") )); @@ -237,7 +237,7 @@ __wasi_errno_t __wasi_fd_prestat_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((uint32_t) fd, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_dir_name") )); @@ -250,7 +250,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_fd_pwrite(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_pwrite(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pwrite") )); @@ -265,7 +265,7 @@ __wasi_errno_t __wasi_fd_pwrite( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_read(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_read(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_read") )); @@ -279,7 +279,7 @@ __wasi_errno_t __wasi_fd_read( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_readdir(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_readdir(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_readdir") )); @@ -294,7 +294,7 @@ __wasi_errno_t __wasi_fd_readdir( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((uint32_t) fd, (uintptr_t) buf, (__wasi_size_t) buf_len, (uint64_t) cookie, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_renumber(uint32_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_renumber(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_renumber") )); @@ -306,7 +306,7 @@ __wasi_errno_t __wasi_fd_renumber( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((uint32_t) fd, (uint32_t) to); } -uint32_t __imported_wasi_snapshot_preview1_fd_seek(uint32_t, uint64_t, uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_seek(uint32_t, uint64_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_seek") )); @@ -320,7 +320,7 @@ __wasi_errno_t __wasi_fd_seek( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((uint32_t) fd, (uint64_t) offset, (uint32_t) whence, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_sync(uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_sync(uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_sync") )); @@ -331,7 +331,7 @@ __wasi_errno_t __wasi_fd_sync( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((uint32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_tell(uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_tell(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_tell") )); @@ -343,7 +343,7 @@ __wasi_errno_t __wasi_fd_tell( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((uint32_t) fd, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_write(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_fd_write(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_write") )); @@ -357,7 +357,7 @@ __wasi_errno_t __wasi_fd_write( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_create_directory(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_create_directory(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_create_directory") )); @@ -370,7 +370,7 @@ __wasi_errno_t __wasi_path_create_directory( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_filestat_get(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_filestat_get(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_get") )); @@ -385,7 +385,7 @@ __wasi_errno_t __wasi_path_filestat_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint64_t, uint64_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_set_times") )); @@ -402,7 +402,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); } -uint32_t __imported_wasi_snapshot_preview1_path_link(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_link(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_link") )); @@ -419,7 +419,7 @@ __wasi_errno_t __wasi_path_link( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((uint32_t) old_fd, (uint32_t) old_flags, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_open(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uint64_t, uint64_t, uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_open(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uint64_t, uint64_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_open") )); @@ -438,7 +438,7 @@ __wasi_errno_t __wasi_path_open( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((uint32_t) fd, (uint32_t) dirflags, (uintptr_t) path, (__wasi_size_t) path_len, (uint32_t) oflags, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting, (uint32_t) fdflags, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_readlink(uint32_t, uintptr_t, __wasi_size_t, uintptr_t, __wasi_size_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_readlink(uint32_t, uintptr_t, __wasi_size_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_readlink") )); @@ -454,7 +454,7 @@ __wasi_errno_t __wasi_path_readlink( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) buf, (__wasi_size_t) buf_len, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_remove_directory(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_remove_directory(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_remove_directory") )); @@ -467,7 +467,7 @@ __wasi_errno_t __wasi_path_remove_directory( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_rename(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_rename(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_rename") )); @@ -483,7 +483,7 @@ __wasi_errno_t __wasi_path_rename( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((uint32_t) fd, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_symlink") )); @@ -498,7 +498,7 @@ __wasi_errno_t __wasi_path_symlink( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_unlink_file(uint32_t, uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_path_unlink_file(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_unlink_file") )); @@ -511,7 +511,7 @@ __wasi_errno_t __wasi_path_unlink_file( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t, uintptr_t, uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t, uintptr_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("poll_oneoff") )); @@ -525,7 +525,7 @@ __wasi_errno_t __wasi_poll_oneoff( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((uintptr_t) in, (uintptr_t) out, (uint32_t) nsubscriptions, (uintptr_t) retptr0); } -_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uint32_t) __attribute__(( +_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("proc_exit") )); @@ -536,7 +536,7 @@ _Noreturn void __wasi_proc_exit( __imported_wasi_snapshot_preview1_proc_exit((uint32_t) rval); } -uint32_t __imported_wasi_snapshot_preview1_sched_yield() __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sched_yield") )); @@ -547,7 +547,7 @@ __wasi_errno_t __wasi_sched_yield( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sched_yield(); } -uint32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t, __wasi_size_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("random_get") )); @@ -559,7 +559,7 @@ __wasi_errno_t __wasi_random_get( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((uintptr_t) buf, (__wasi_size_t) buf_len); } -uint32_t __imported_wasi_snapshot_preview1_sock_accept(uint32_t, uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_accept(uint32_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_accept") )); @@ -572,7 +572,7 @@ __wasi_errno_t __wasi_sock_accept( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((uint32_t) fd, (uint32_t) flags, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_sock_recv(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_recv(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_recv") )); @@ -588,7 +588,7 @@ __wasi_errno_t __wasi_sock_recv( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((uint32_t) fd, (uintptr_t) ri_data, (__wasi_size_t) ri_data_len, (uint32_t) ri_flags, (uintptr_t) retptr0, (uintptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_sock_send(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_send(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_send") )); @@ -603,7 +603,7 @@ __wasi_errno_t __wasi_sock_send( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((uint32_t) fd, (uintptr_t) si_data, (__wasi_size_t) si_data_len, (uint32_t) si_flags, (uintptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_sock_shutdown(uint32_t, uint32_t) __attribute__(( +uint32_t __imported_wasi_snapshot_preview1_sock_shutdown(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_shutdown") )); @@ -616,12 +616,12 @@ __wasi_errno_t __wasi_sock_shutdown( } #ifdef _REENTRANT -uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attribute__(( - __import_module__("wasi_snapshot_preview2"), - __import_name__("thread_spawn") +uint32_t __imported_wasi_thread_spawn(uintptr_t arg0) __WASI_NOEXCEPT __attribute__(( + __import_module__("wasi"), + __import_name__("thread-spawn") )); -int32_t __wasi_thread_spawn(void* start_arg) { - return (int32_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { + return (int32_t) __imported_wasi_thread_spawn((uintptr_t) start_arg); } #endif diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 89436083c..b6e8e4bd0 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -53,6 +53,16 @@ _Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); extern "C" {{ #endif +#ifdef __cplusplus +#if __cplusplus >= 201103L +#define __WASI_NOEXCEPT noexcept +#else +#define __WASI_NOEXCEPT throw() +#endif +#else +#define __WASI_NOEXCEPT +#endif + // TODO: Encoding this in witx. #define __WASI_DIRCOOKIE_START (UINT64_C(0)) "#, @@ -116,7 +126,7 @@ int32_t __wasi_thread_spawn( * function. */ void *start_arg -) __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); #endif #ifdef __cplusplus @@ -129,13 +139,13 @@ int32_t __wasi_thread_spawn( source.push_str( r#"#ifdef _REENTRANT -uint32_t __imported_wasi_snapshot_preview2_thread_spawn(uintptr_t arg0) __attribute__(( - __import_module__("wasi_snapshot_preview2"), - __import_name__("thread_spawn") +uint32_t __imported_wasi_thread_spawn(uintptr_t arg0) __WASI_NOEXCEPT __attribute__(( + __import_module__("wasi"), + __import_name__("thread-spawn") )); -int32_t __wasi_thread_spawn(void* start_arg) { - return (int32_t) __imported_wasi_snapshot_preview2_thread_spawn((uintptr_t) start_arg); +int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { + return (int32_t) __imported_wasi_thread_spawn((uintptr_t) start_arg); } #endif "#, @@ -444,7 +454,7 @@ fn print_func_header(ret: &mut String, func: &InterfaceFunc) { } print_func_signature(ret, func, true); - + ret.push_str(" __WASI_NOEXCEPT "); if func.results.len() > 0 { ret.push_str(" __attribute__((__warn_unused_result__))"); } @@ -653,7 +663,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { ret.push_str("("); print_c_typeref_names(ret, func, ¶ms); - ret.push_str(") __attribute__((\n"); + ret.push_str(") __WASI_NOEXCEPT __attribute__((\n"); ret.push_str(&format!( " __import_module__(\"{}\"),\n", ident_name(module_name) From 72d9602694a200358365571612797f55c9c51caf Mon Sep 17 00:00:00 2001 From: trcrsired Date: Mon, 30 Oct 2023 23:40:59 -0400 Subject: [PATCH 12/43] Add wasi64 and wasi64+thread to CI --- .github/workflows/main.yml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index eb9b59f83..9e13cb17c 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -118,6 +118,22 @@ jobs: shell: bash run: make -j4 THREAD_MODEL=posix + - name: Build wasi64 + libc + # Only build the thread-capable wasi-libc in the latest supported Clang + # version; the earliest version does not have all necessary builtins + # (e.g., `__builtin_wasm_memory_atomic_notify`). + if: matrix.clang_version != '10.0.0' + shell: bash + run: make -j4 BUILD_WASI64=yes + + - name: Build wasi64 + libc + threads + # Only build the thread-capable wasi-libc in the latest supported Clang + # version; the earliest version does not have all necessary builtins + # (e.g., `__builtin_wasm_memory_atomic_notify`). + if: matrix.clang_version != '10.0.0' + shell: bash + run: make -j4 BUILD_WASI64=yes THREAD_MODEL=posix + # Disable the headerstest job for now, while WASI transitions from the # witx snapshots to wit proposals, and we have a few manual edits to the # generated header to make life easier for folks. From dfc09f2146d44f672238821f54df55b9b23f775b Mon Sep 17 00:00:00 2001 From: trcrsired Date: Mon, 30 Oct 2023 23:42:21 -0400 Subject: [PATCH 13/43] Change comment for CI for wasi64 and thread --- .github/workflows/main.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9e13cb17c..4dc6998aa 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -119,17 +119,13 @@ jobs: run: make -j4 THREAD_MODEL=posix - name: Build wasi64 + libc - # Only build the thread-capable wasi-libc in the latest supported Clang - # version; the earliest version does not have all necessary builtins - # (e.g., `__builtin_wasm_memory_atomic_notify`). + # Build wasi64 if: matrix.clang_version != '10.0.0' shell: bash run: make -j4 BUILD_WASI64=yes - name: Build wasi64 + libc + threads - # Only build the thread-capable wasi-libc in the latest supported Clang - # version; the earliest version does not have all necessary builtins - # (e.g., `__builtin_wasm_memory_atomic_notify`). + # Build wasi64 with thread support if: matrix.clang_version != '10.0.0' shell: bash run: make -j4 BUILD_WASI64=yes THREAD_MODEL=posix From c9ad7455966151dc47bcaa389ae18b42278b10d2 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 31 Oct 2023 16:37:32 -0400 Subject: [PATCH 14/43] Merge wasm32 code with wasm64 code Parameters changing back to use signed integer in __wasilibc_real.c rename libc-top-half/musl/arch/wasm32 to libc-top-half/musl/arch/wasm rename libc-top-half/musl/src/thread/wasm32 to libc-top-half/musl/src/thread/wasm rename wasi_thread_start.s to wasi_thread_start.S since .s does not support macros --- .github/workflows/main.yml | 4 +- Makefile | 28 +-- README.md | 4 +- libc-bottom-half/headers/public/wasi/api.h | 2 +- libc-bottom-half/sources/__wasilibc_real.c | 190 +++++++++--------- .../musl/arch/{wasm32 => wasm}/atomic_arch.h | 0 .../arch/{wasm32 => wasm}/bits/alltypes.h.in | 0 .../musl/arch/{wasm32 => wasm}/bits/dirent.h | 0 .../musl/arch/{wasm32 => wasm}/bits/fcntl.h | 0 .../musl/arch/{wasm32 => wasm}/bits/float.h | 0 .../musl/arch/{wasm32 => wasm}/bits/ioctl.h | 0 .../musl/arch/{wasm32 => wasm}/bits/limits.h | 0 .../musl/arch/{wasm32 => wasm}/bits/posix.h | 0 .../musl/arch/{wasm32 => wasm}/bits/reg.h | 0 .../musl/arch/{wasm32 => wasm}/bits/signal.h | 0 .../musl/arch/{wasm32 => wasm}/bits/stat.h | 0 .../musl/arch/{wasm32 => wasm}/bits/stdint.h | 0 .../musl/arch/{wasm32 => wasm}/fp_arch.h | 0 .../musl/arch/{wasm32 => wasm}/pthread_arch.h | 0 .../musl/arch/{wasm32 => wasm}/reloc.h | 0 .../musl/arch/{wasm32 => wasm}/syscall_arch.h | 0 .../wasi_thread_start.S} | 28 ++- .../src/thread/wasm64/wasi_thread_start.s | 48 ----- tools/wasi-headers/src/c_header.rs | 45 ++--- 24 files changed, 155 insertions(+), 194 deletions(-) rename libc-top-half/musl/arch/{wasm32 => wasm}/atomic_arch.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/alltypes.h.in (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/dirent.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/fcntl.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/float.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/ioctl.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/limits.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/posix.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/reg.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/signal.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/stat.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/bits/stdint.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/fp_arch.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/pthread_arch.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/reloc.h (100%) rename libc-top-half/musl/arch/{wasm32 => wasm}/syscall_arch.h (100%) rename libc-top-half/musl/src/thread/{wasm32/wasi_thread_start.s => wasm/wasi_thread_start.S} (71%) delete mode 100644 libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4dc6998aa..487301b4b 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -122,13 +122,13 @@ jobs: # Build wasi64 if: matrix.clang_version != '10.0.0' shell: bash - run: make -j4 BUILD_WASI64=yes + run: make -j4 WASM64=yes - name: Build wasi64 + libc + threads # Build wasi64 with thread support if: matrix.clang_version != '10.0.0' shell: bash - run: make -j4 BUILD_WASI64=yes THREAD_MODEL=posix + run: make -j4 WASM64=yes THREAD_MODEL=posix # Disable the headerstest job for now, while WASI transitions from the # witx snapshots to wit proposals, and we have a few manual edits to the diff --git a/Makefile b/Makefile index 0400e0f12..d97cda6d6 100644 --- a/Makefile +++ b/Makefile @@ -21,8 +21,8 @@ MALLOC_IMPL ?= dlmalloc BUILD_LIBC_TOP_HALF ?= yes # The directory where we will store intermediate artifacts. OBJDIR ?= build/$(TARGET_TRIPLE) - -BUILD_WASI64 ?= no +# 64 bit wasm? +WASM64 ?= no # When the length is no larger than this threshold, we consider the # overhead of bulk memory opcodes to outweigh the performance benefit, @@ -35,7 +35,7 @@ BULK_MEMORY_THRESHOLD ?= 32 # make command-line. # Set the default WASI target triple. -ifeq (${BUILD_WASI64}, yes) +ifeq (${WASM64}, yes) TARGET_TRIPLE = wasm64-wasi else TARGET_TRIPLE = wasm32-wasi @@ -44,7 +44,7 @@ endif # Threaded version necessitates a different traget, as objects from different # targets can't be mixed together while linking. ifeq ($(THREAD_MODEL), posix) - ifeq (${BUILD_WASI64}, yes) + ifeq (${WASM64}, yes) TARGET_TRIPLE = wasm64-wasi-threads else TARGET_TRIPLE = wasm32-wasi-threads @@ -209,13 +209,6 @@ LIBC_TOP_HALF_MUSL_SOURCES = \ ifeq ($(THREAD_MODEL), posix) -ifeq (${BUILD_WASI64}, yes) -WASM_THREAD_ASM_FILE = thread/wasm64/wasi_thread_start.s -else -WASM_THREAD_ASM_FILE = thread/wasm32/wasi_thread_start.s -endif - - LIBC_TOP_HALF_MUSL_SOURCES += \ $(addprefix $(LIBC_TOP_HALF_MUSL_SRC_DIR)/, \ env/__init_tls.c \ @@ -296,7 +289,7 @@ LIBC_TOP_HALF_MUSL_SOURCES += \ thread/sem_timedwait.c \ thread/sem_trywait.c \ thread/sem_wait.c \ - ${WASM_THREAD_ASM_FILE} \ + thread/wasm/wasi_thread_start.S \ ) endif @@ -346,6 +339,7 @@ ifeq ($(THREAD_MODEL), posix) # Specify the tls-model until LLVM 15 is released (which should contain # https://reviews.llvm.org/D130053). CFLAGS += -mthread-model posix -pthread -ftls-model=local-exec + ASMFLAGS += -matomics # Include cloudlib's directory to access the structure definition of clockid_t @@ -369,7 +363,7 @@ CFLAGS += -isystem "$(SYSROOT_INC)" # These variables describe the locations of various files and directories in # the build tree. objs = $(patsubst %.c,$(OBJDIR)/%.o,$(1)) -asmobjs = $(patsubst %.s,$(OBJDIR)/%.o,$(1)) +asmobjs = $(patsubst %.S,$(OBJDIR)/%.o,$(1)) DLMALLOC_OBJS = $(call objs,$(DLMALLOC_SOURCES)) EMMALLOC_OBJS = $(call objs,$(EMMALLOC_SOURCES)) LIBC_BOTTOM_HALF_ALL_OBJS = $(call objs,$(LIBC_BOTTOM_HALF_ALL_SOURCES)) @@ -606,7 +600,7 @@ $(OBJDIR)/%.o: %.c include_dirs @mkdir -p "$(@D)" $(CC) $(CFLAGS) -MD -MP -o $@ -c $< -$(OBJDIR)/%.o: %.s include_dirs +$(OBJDIR)/%.o: %.S include_dirs @mkdir -p "$(@D)" $(CC) $(ASMFLAGS) -o $@ -c $< @@ -625,7 +619,7 @@ startup_files $(LIBC_BOTTOM_HALF_ALL_OBJS) $(LIBC_BOTTOM_HALF_ALL_SO_OBJS): CFLA $(LIBC_TOP_HALF_ALL_OBJS) $(LIBC_TOP_HALF_ALL_SO_OBJS) $(MUSL_PRINTSCAN_LONG_DOUBLE_OBJS) $(MUSL_PRINTSCAN_LONG_DOUBLE_SO_OBJS) $(MUSL_PRINTSCAN_NO_FLOATING_POINT_OBJS) $(LIBWASI_EMULATED_SIGNAL_MUSL_OBJS) $(LIBWASI_EMULATED_SIGNAL_MUSL_SO_OBJS): CFLAGS += \ -I$(LIBC_TOP_HALF_MUSL_SRC_DIR)/include \ -I$(LIBC_TOP_HALF_MUSL_SRC_DIR)/internal \ - -I$(LIBC_TOP_HALF_MUSL_DIR)/arch/wasm32 \ + -I$(LIBC_TOP_HALF_MUSL_DIR)/arch/wasm \ -I$(LIBC_TOP_HALF_MUSL_DIR)/arch/generic \ -I$(LIBC_TOP_HALF_HEADERS_PRIVATE) \ -Wno-parentheses \ @@ -654,7 +648,7 @@ include_dirs: # Generate musl's bits/alltypes.h header. mkdir -p "$(SYSROOT_INC)/bits" sed -f $(LIBC_TOP_HALF_MUSL_DIR)/tools/mkalltypes.sed \ - $(LIBC_TOP_HALF_MUSL_DIR)/arch/wasm32/bits/alltypes.h.in \ + $(LIBC_TOP_HALF_MUSL_DIR)/arch/wasm/bits/alltypes.h.in \ $(LIBC_TOP_HALF_MUSL_DIR)/include/alltypes.h.in \ > "$(SYSROOT_INC)/bits/alltypes.h" @@ -662,7 +656,7 @@ include_dirs: cp -r "$(LIBC_TOP_HALF_MUSL_INC)"/* "$(SYSROOT_INC)" # Copy in the musl's "bits" header files. cp -r "$(LIBC_TOP_HALF_MUSL_DIR)"/arch/generic/bits/* "$(SYSROOT_INC)/bits" - cp -r "$(LIBC_TOP_HALF_MUSL_DIR)"/arch/wasm32/bits/* "$(SYSROOT_INC)/bits" + cp -r "$(LIBC_TOP_HALF_MUSL_DIR)"/arch/wasm/bits/* "$(SYSROOT_INC)/bits" # Remove selected header files. $(RM) $(patsubst %,$(SYSROOT_INC)/%,$(MUSL_OMIT_HEADERS)) diff --git a/README.md b/README.md index 236e6d9f7..aef1bcd8b 100644 --- a/README.md +++ b/README.md @@ -56,12 +56,12 @@ wasm32-wasi-threads`. ## 64 bits support To enable 64 bits support, follow the above -build directions with one addition: `make ... BUILD_WASI64=yes`. This creates +build directions with one addition: `make ... WASM64=yes`. This creates artifacts in `sysroot/lib/wasm64-wasi` to support `--target wasm64-wasi`. You can build 64 bits with pthread support together with -'make ... BUILD_WASI64=yes THREAD_MODEL=posix'. This creates +'make ... WASM64=yes THREAD_MODEL=posix'. This creates artifacts in `sysroot/lib/wasm64-wasi-threads` to support `--target wasm64-wasi-threads`. diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index bd96361d2..9378844bd 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -34,7 +34,7 @@ _Static_assert(_Alignof(int32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(uint32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(int64_t) == 8, "non-wasi data layout"); _Static_assert(_Alignof(uint64_t) == 8, "non-wasi data layout"); -_Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); +_Static_assert(_Alignof(void*) == sizeof(intptr_t), "non-wasi data layout"); #ifdef __cplusplus extern "C" { diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 99a5daf3f..58f5959cc 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -13,7 +13,11 @@ #include #include -uint32_t __imported_wasi_snapshot_preview1_args_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +#ifdef __cplusplus +extern "C" { +#endif + +int32_t __imported_wasi_snapshot_preview1_args_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_get") )); @@ -22,10 +26,10 @@ __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((uintptr_t) argv, (uintptr_t) argv_buf); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((intptr_t) argv, (intptr_t) argv_buf); } -uint32_t __imported_wasi_snapshot_preview1_args_sizes_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_args_sizes_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("args_sizes_get") )); @@ -34,10 +38,10 @@ __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_environ_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_environ_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_get") )); @@ -46,10 +50,10 @@ __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((uintptr_t) environ, (uintptr_t) environ_buf); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((intptr_t) environ, (intptr_t) environ_buf); } -uint32_t __imported_wasi_snapshot_preview1_environ_sizes_get(uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("environ_sizes_get") )); @@ -58,10 +62,10 @@ __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((uintptr_t) retptr0, (uintptr_t) retptr1); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_clock_res_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_clock_res_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_res_get") )); @@ -70,10 +74,10 @@ __wasi_errno_t __wasi_clock_res_get( __wasi_clockid_t id, __wasi_timestamp_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((uint32_t) id, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_clock_time_get(uint32_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_clock_time_get(int32_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("clock_time_get") )); @@ -83,10 +87,10 @@ __wasi_errno_t __wasi_clock_time_get( __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((uint32_t) id, (uint64_t) precision, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_advise(uint32_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_advise(int32_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_advise") )); @@ -97,10 +101,10 @@ __wasi_errno_t __wasi_fd_advise( __wasi_filesize_t len, __wasi_advice_t advice ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((uint32_t) fd, (uint64_t) offset, (uint64_t) len, (uint32_t) advice); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((int32_t) fd, (int64_t) offset, (int64_t) len, (int32_t) advice); } -uint32_t __imported_wasi_snapshot_preview1_fd_allocate(uint32_t, uint64_t, uint64_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_allocate(int32_t, int64_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_allocate") )); @@ -110,10 +114,10 @@ __wasi_errno_t __wasi_fd_allocate( __wasi_filesize_t offset, __wasi_filesize_t len ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((uint32_t) fd, (uint64_t) offset, (uint64_t) len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((int32_t) fd, (int64_t) offset, (int64_t) len); } -uint32_t __imported_wasi_snapshot_preview1_fd_close(uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_close(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_close") )); @@ -121,10 +125,10 @@ uint32_t __imported_wasi_snapshot_preview1_fd_close(uint32_t) __WASI_NOEXCEPT __ __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((uint32_t) fd); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((int32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_datasync(uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_datasync(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_datasync") )); @@ -132,10 +136,10 @@ uint32_t __imported_wasi_snapshot_preview1_fd_datasync(uint32_t) __WASI_NOEXCEPT __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((uint32_t) fd); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((int32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_get") )); @@ -144,10 +148,10 @@ __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((uint32_t) fd, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_flags") )); @@ -156,10 +160,10 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( __wasi_fd_t fd, __wasi_fdflags_t flags ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((uint32_t) fd, (uint32_t) flags); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((int32_t) fd, (int32_t) flags); } -uint32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(uint32_t, uint64_t, uint64_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(int32_t, int64_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_fdstat_set_rights") )); @@ -169,10 +173,10 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((uint32_t) fd, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((int32_t) fd, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_get") )); @@ -181,10 +185,10 @@ __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((uint32_t) fd, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(uint32_t, uint64_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(int32_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_size") )); @@ -193,10 +197,10 @@ __wasi_errno_t __wasi_fd_filestat_set_size( __wasi_fd_t fd, __wasi_filesize_t size ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((uint32_t) fd, (uint64_t) size); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((int32_t) fd, (int64_t) size); } -uint32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(uint32_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(int32_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_filestat_set_times") )); @@ -207,10 +211,10 @@ __wasi_errno_t __wasi_fd_filestat_set_times( __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((uint32_t) fd, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((int32_t) fd, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } -uint32_t __imported_wasi_snapshot_preview1_fd_pread(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_pread(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pread") )); @@ -222,10 +226,10 @@ __wasi_errno_t __wasi_fd_pread( __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_prestat_get(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_get") )); @@ -234,10 +238,10 @@ __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((uint32_t) fd, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_prestat_dir_name") )); @@ -247,10 +251,10 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( uint8_t * path, __wasi_size_t path_len ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_fd_pwrite(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_pwrite(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_pwrite") )); @@ -262,10 +266,10 @@ __wasi_errno_t __wasi_fd_pwrite( __wasi_filesize_t offset, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uint64_t) offset, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_read(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_read(int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_read") )); @@ -276,10 +280,10 @@ __wasi_errno_t __wasi_fd_read( size_t iovs_len, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_readdir(uint32_t, uintptr_t, __wasi_size_t, uint64_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_readdir(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_readdir") )); @@ -291,10 +295,10 @@ __wasi_errno_t __wasi_fd_readdir( __wasi_dircookie_t cookie, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((uint32_t) fd, (uintptr_t) buf, (__wasi_size_t) buf_len, (uint64_t) cookie, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (intptr_t) buf, (__wasi_size_t) buf_len, (int64_t) cookie, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_renumber(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_renumber(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_renumber") )); @@ -303,10 +307,10 @@ __wasi_errno_t __wasi_fd_renumber( __wasi_fd_t fd, __wasi_fd_t to ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((uint32_t) fd, (uint32_t) to); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((int32_t) fd, (int32_t) to); } -uint32_t __imported_wasi_snapshot_preview1_fd_seek(uint32_t, uint64_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_seek(int32_t, int64_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_seek") )); @@ -317,10 +321,10 @@ __wasi_errno_t __wasi_fd_seek( __wasi_whence_t whence, __wasi_filesize_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((uint32_t) fd, (uint64_t) offset, (uint32_t) whence, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, (int64_t) offset, (int32_t) whence, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_sync(uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_sync(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_sync") )); @@ -328,10 +332,10 @@ uint32_t __imported_wasi_snapshot_preview1_fd_sync(uint32_t) __WASI_NOEXCEPT __a __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((uint32_t) fd); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((int32_t) fd); } -uint32_t __imported_wasi_snapshot_preview1_fd_tell(uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_tell(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_tell") )); @@ -340,10 +344,10 @@ __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((uint32_t) fd, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_fd_write(uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_fd_write(int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("fd_write") )); @@ -354,10 +358,10 @@ __wasi_errno_t __wasi_fd_write( size_t iovs_len, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((uint32_t) fd, (uintptr_t) iovs, (__wasi_size_t) iovs_len, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_create_directory(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_create_directory(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_create_directory") )); @@ -367,10 +371,10 @@ __wasi_errno_t __wasi_path_create_directory( char const *path ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_filestat_get(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_filestat_get(int32_t, int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_get") )); @@ -382,10 +386,10 @@ __wasi_errno_t __wasi_path_filestat_get( __wasi_filestat_t *retptr0 ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint64_t, uint64_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(int32_t, int32_t, intptr_t, __wasi_size_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_filestat_set_times") )); @@ -399,10 +403,10 @@ __wasi_errno_t __wasi_path_filestat_set_times( __wasi_fstflags_t fst_flags ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((uint32_t) fd, (uint32_t) flags, (uintptr_t) path, (__wasi_size_t) path_len, (uint64_t) atim, (uint64_t) mtim, (uint32_t) fst_flags); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } -uint32_t __imported_wasi_snapshot_preview1_path_link(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_link(int32_t, int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_link") )); @@ -416,10 +420,10 @@ __wasi_errno_t __wasi_path_link( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((uint32_t) old_fd, (uint32_t) old_flags, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, (int32_t) old_flags, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_open(uint32_t, uint32_t, uintptr_t, __wasi_size_t, uint32_t, uint64_t, uint64_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_open(int32_t, int32_t, intptr_t, __wasi_size_t, int32_t, int64_t, int64_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_open") )); @@ -435,10 +439,10 @@ __wasi_errno_t __wasi_path_open( __wasi_fd_t *retptr0 ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((uint32_t) fd, (uint32_t) dirflags, (uintptr_t) path, (__wasi_size_t) path_len, (uint32_t) oflags, (uint64_t) fs_rights_base, (uint64_t) fs_rights_inheriting, (uint32_t) fdflags, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((int32_t) fd, (int32_t) dirflags, (intptr_t) path, (__wasi_size_t) path_len, (int32_t) oflags, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting, (int32_t) fdflags, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_readlink(uint32_t, uintptr_t, __wasi_size_t, uintptr_t, __wasi_size_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_readlink(int32_t, intptr_t, __wasi_size_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_readlink") )); @@ -451,10 +455,10 @@ __wasi_errno_t __wasi_path_readlink( __wasi_size_t *retptr0 ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len, (uintptr_t) buf, (__wasi_size_t) buf_len, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) buf, (__wasi_size_t) buf_len, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_path_remove_directory(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_remove_directory(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_remove_directory") )); @@ -464,10 +468,10 @@ __wasi_errno_t __wasi_path_remove_directory( char const *path ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_rename(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_rename(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_rename") )); @@ -480,10 +484,10 @@ __wasi_errno_t __wasi_path_rename( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((uint32_t) fd, (uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) new_fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_symlink(uintptr_t, __wasi_size_t, uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_symlink(intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_symlink") )); @@ -495,10 +499,10 @@ __wasi_errno_t __wasi_path_symlink( ){ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((uintptr_t) old_path, (__wasi_size_t) old_path_len, (uint32_t) fd, (uintptr_t) new_path, (__wasi_size_t) new_path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); } -uint32_t __imported_wasi_snapshot_preview1_path_unlink_file(uint32_t, uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_path_unlink_file(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("path_unlink_file") )); @@ -508,10 +512,10 @@ __wasi_errno_t __wasi_path_unlink_file( char const *path ){ size_t path_len = strlen(path); - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((uint32_t) fd, (uintptr_t) path, (__wasi_size_t) path_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } -uint32_t __imported_wasi_snapshot_preview1_poll_oneoff(uintptr_t, uintptr_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_poll_oneoff(intptr_t, intptr_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("poll_oneoff") )); @@ -522,10 +526,10 @@ __wasi_errno_t __wasi_poll_oneoff( __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((uintptr_t) in, (uintptr_t) out, (uint32_t) nsubscriptions, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((intptr_t) in, (intptr_t) out, (int32_t) nsubscriptions, (intptr_t) retptr0); } -_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uint32_t) __WASI_NOEXCEPT __attribute__(( +_Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("proc_exit") )); @@ -533,10 +537,10 @@ _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(uint32_t) __WASI_NOEX _Noreturn void __wasi_proc_exit( __wasi_exitcode_t rval ){ - __imported_wasi_snapshot_preview1_proc_exit((uint32_t) rval); + __imported_wasi_snapshot_preview1_proc_exit((int32_t) rval); } -uint32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sched_yield") )); @@ -547,7 +551,7 @@ __wasi_errno_t __wasi_sched_yield( return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sched_yield(); } -uint32_t __imported_wasi_snapshot_preview1_random_get(uintptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_random_get(intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("random_get") )); @@ -556,10 +560,10 @@ __wasi_errno_t __wasi_random_get( uint8_t * buf, __wasi_size_t buf_len ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((uintptr_t) buf, (__wasi_size_t) buf_len); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((intptr_t) buf, (__wasi_size_t) buf_len); } -uint32_t __imported_wasi_snapshot_preview1_sock_accept(uint32_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_accept(int32_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_accept") )); @@ -569,10 +573,10 @@ __wasi_errno_t __wasi_sock_accept( __wasi_fdflags_t flags, __wasi_fd_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((uint32_t) fd, (uint32_t) flags, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, (int32_t) flags, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_sock_recv(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_recv(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_recv") )); @@ -585,10 +589,10 @@ __wasi_errno_t __wasi_sock_recv( __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((uint32_t) fd, (uintptr_t) ri_data, (__wasi_size_t) ri_data_len, (uint32_t) ri_flags, (uintptr_t) retptr0, (uintptr_t) retptr1); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (intptr_t) ri_data, (__wasi_size_t) ri_data_len, (int32_t) ri_flags, (intptr_t) retptr0, (intptr_t) retptr1); } -uint32_t __imported_wasi_snapshot_preview1_sock_send(uint32_t, uintptr_t, __wasi_size_t, uint32_t, uintptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_send(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_send") )); @@ -600,10 +604,10 @@ __wasi_errno_t __wasi_sock_send( __wasi_siflags_t si_flags, __wasi_size_t *retptr0 ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((uint32_t) fd, (uintptr_t) si_data, (__wasi_size_t) si_data_len, (uint32_t) si_flags, (uintptr_t) retptr0); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (intptr_t) si_data, (__wasi_size_t) si_data_len, (int32_t) si_flags, (intptr_t) retptr0); } -uint32_t __imported_wasi_snapshot_preview1_sock_shutdown(uint32_t, uint32_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_sock_shutdown(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), __import_name__("sock_shutdown") )); @@ -612,16 +616,20 @@ __wasi_errno_t __wasi_sock_shutdown( __wasi_fd_t fd, __wasi_sdflags_t how ){ - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_shutdown((uint32_t) fd, (uint32_t) how); + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_shutdown((int32_t) fd, (int32_t) how); } #ifdef _REENTRANT -uint32_t __imported_wasi_thread_spawn(uintptr_t arg0) __WASI_NOEXCEPT __attribute__(( +uint32_t __imported_wasi_thread_spawn(intptr_t arg0) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi"), __import_name__("thread-spawn") )); int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { - return (int32_t) __imported_wasi_thread_spawn((uintptr_t) start_arg); + return (int32_t) __imported_wasi_thread_spawn((intptr_t) start_arg); +} +#endif + +#ifdef __cplusplus } #endif diff --git a/libc-top-half/musl/arch/wasm32/atomic_arch.h b/libc-top-half/musl/arch/wasm/atomic_arch.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/atomic_arch.h rename to libc-top-half/musl/arch/wasm/atomic_arch.h diff --git a/libc-top-half/musl/arch/wasm32/bits/alltypes.h.in b/libc-top-half/musl/arch/wasm/bits/alltypes.h.in similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/alltypes.h.in rename to libc-top-half/musl/arch/wasm/bits/alltypes.h.in diff --git a/libc-top-half/musl/arch/wasm32/bits/dirent.h b/libc-top-half/musl/arch/wasm/bits/dirent.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/dirent.h rename to libc-top-half/musl/arch/wasm/bits/dirent.h diff --git a/libc-top-half/musl/arch/wasm32/bits/fcntl.h b/libc-top-half/musl/arch/wasm/bits/fcntl.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/fcntl.h rename to libc-top-half/musl/arch/wasm/bits/fcntl.h diff --git a/libc-top-half/musl/arch/wasm32/bits/float.h b/libc-top-half/musl/arch/wasm/bits/float.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/float.h rename to libc-top-half/musl/arch/wasm/bits/float.h diff --git a/libc-top-half/musl/arch/wasm32/bits/ioctl.h b/libc-top-half/musl/arch/wasm/bits/ioctl.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/ioctl.h rename to libc-top-half/musl/arch/wasm/bits/ioctl.h diff --git a/libc-top-half/musl/arch/wasm32/bits/limits.h b/libc-top-half/musl/arch/wasm/bits/limits.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/limits.h rename to libc-top-half/musl/arch/wasm/bits/limits.h diff --git a/libc-top-half/musl/arch/wasm32/bits/posix.h b/libc-top-half/musl/arch/wasm/bits/posix.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/posix.h rename to libc-top-half/musl/arch/wasm/bits/posix.h diff --git a/libc-top-half/musl/arch/wasm32/bits/reg.h b/libc-top-half/musl/arch/wasm/bits/reg.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/reg.h rename to libc-top-half/musl/arch/wasm/bits/reg.h diff --git a/libc-top-half/musl/arch/wasm32/bits/signal.h b/libc-top-half/musl/arch/wasm/bits/signal.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/signal.h rename to libc-top-half/musl/arch/wasm/bits/signal.h diff --git a/libc-top-half/musl/arch/wasm32/bits/stat.h b/libc-top-half/musl/arch/wasm/bits/stat.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/stat.h rename to libc-top-half/musl/arch/wasm/bits/stat.h diff --git a/libc-top-half/musl/arch/wasm32/bits/stdint.h b/libc-top-half/musl/arch/wasm/bits/stdint.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/bits/stdint.h rename to libc-top-half/musl/arch/wasm/bits/stdint.h diff --git a/libc-top-half/musl/arch/wasm32/fp_arch.h b/libc-top-half/musl/arch/wasm/fp_arch.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/fp_arch.h rename to libc-top-half/musl/arch/wasm/fp_arch.h diff --git a/libc-top-half/musl/arch/wasm32/pthread_arch.h b/libc-top-half/musl/arch/wasm/pthread_arch.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/pthread_arch.h rename to libc-top-half/musl/arch/wasm/pthread_arch.h diff --git a/libc-top-half/musl/arch/wasm32/reloc.h b/libc-top-half/musl/arch/wasm/reloc.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/reloc.h rename to libc-top-half/musl/arch/wasm/reloc.h diff --git a/libc-top-half/musl/arch/wasm32/syscall_arch.h b/libc-top-half/musl/arch/wasm/syscall_arch.h similarity index 100% rename from libc-top-half/musl/arch/wasm32/syscall_arch.h rename to libc-top-half/musl/arch/wasm/syscall_arch.h diff --git a/libc-top-half/musl/src/thread/wasm32/wasi_thread_start.s b/libc-top-half/musl/src/thread/wasm/wasi_thread_start.S similarity index 71% rename from libc-top-half/musl/src/thread/wasm32/wasi_thread_start.s rename to libc-top-half/musl/src/thread/wasm/wasi_thread_start.S index 7a480b837..76159c9c5 100644 --- a/libc-top-half/musl/src/thread/wasm32/wasi_thread_start.s +++ b/libc-top-half/musl/src/thread/wasm/wasi_thread_start.S @@ -1,26 +1,34 @@ +#ifdef __wasm64__ +#define PTR i64 +#define PTRSIZE 8 +#else +#define PTR i32 +#define PTRSIZE 4 +#endif + .text .export_name wasi_thread_start, wasi_thread_start - .globaltype __stack_pointer, i32 - .globaltype __tls_base, i32 - .functype __wasi_thread_start_C (i32, i32) -> () + .globaltype __stack_pointer, PTR + .globaltype __tls_base, PTR + .functype __wasi_thread_start_C (PTR, PTR) -> () .hidden wasi_thread_start .globl wasi_thread_start .type wasi_thread_start,@function wasi_thread_start: - .functype wasi_thread_start (i32, i32) -> () + .functype wasi_thread_start (PTR, PTR) -> () # Set up the minimum C environment. # Note: offsetof(start_arg, stack) == 0 local.get 1 # start_arg - i32.load 0 # stack + PTR.load 0 # stack global.set __stack_pointer local.get 1 # start_arg - i32.load 4 # tls_base + PTR.load PTRSIZE # tls_base global.set __tls_base # Make the C function do the rest of work. @@ -34,13 +42,13 @@ wasi_thread_start: # by a joining thread. It's safe as we are in ASM and no longer use # our C stack or pthread_t. It's impossible to do this safely in C # because there is no way to tell the C compiler not to use C stack. - i32.const __thread_list_lock - i32.const 0 - i32.atomic.store 0 + PTR.const __thread_list_lock + PTR.const 0 + PTR.atomic.store 0 # As an optimization, we can check tl_lock_waiters here. # But for now, simply wake up unconditionally as # CLONE_CHILD_CLEARTID does. - i32.const __thread_list_lock + PTR.const __thread_list_lock i32.const 1 memory.atomic.notify 0 drop diff --git a/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s b/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s deleted file mode 100644 index 22ba21692..000000000 --- a/libc-top-half/musl/src/thread/wasm64/wasi_thread_start.s +++ /dev/null @@ -1,48 +0,0 @@ - .text - - .export_name wasi_thread_start, wasi_thread_start - - .globaltype __stack_pointer, i64 - .globaltype __tls_base, i64 - .functype __wasi_thread_start_C (i64, i64) -> () - - .hidden wasi_thread_start - .globl wasi_thread_start - .type wasi_thread_start,@function - -wasi_thread_start: - .functype wasi_thread_start (i64, i64) -> () - - # Set up the minimum C environment. - # Note: offsetof(start_arg, stack) == 0 - local.get 1 # start_arg - i64.load 0 # stack - global.set __stack_pointer - - local.get 1 # start_arg - i64.load 8 # tls_base - global.set __tls_base - - # Make the C function do the rest of work. - local.get 0 # tid - local.get 1 # start_arg - call __wasi_thread_start_C - - # Unlock thread list. (as CLONE_CHILD_CLEARTID would do for Linux) - # - # Note: once we unlock the thread list, our "map_base" can be freed - # by a joining thread. It's safe as we are in ASM and no longer use - # our C stack or pthread_t. It's impossible to do this safely in C - # because there is no way to tell the C compiler not to use C stack. - i64.const __thread_list_lock - i64.const 0 - i64.atomic.store 0 - # As an optimization, we can check tl_lock_waiters here. - # But for now, simply wake up unconditionally as - # CLONE_CHILD_CLEARTID does. - i64.const __thread_list_lock - i32.const 1 - memory.atomic.notify 0 - drop - - end_function diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index b6e8e4bd0..3ac7a9888 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -47,7 +47,7 @@ _Static_assert(_Alignof(int32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(uint32_t) == 4, "non-wasi data layout"); _Static_assert(_Alignof(int64_t) == 8, "non-wasi data layout"); _Static_assert(_Alignof(uint64_t) == 8, "non-wasi data layout"); -_Static_assert(_Alignof(void*) == sizeof(uintptr_t), "non-wasi data layout"); +_Static_assert(_Alignof(void*) == sizeof(intptr_t), "non-wasi data layout"); #ifdef __cplusplus extern "C" {{ @@ -86,6 +86,10 @@ extern "C" {{ #include #include +#ifdef __cplusplus +extern "C" {{ +#endif + "#, inputs_str, )); @@ -139,13 +143,17 @@ int32_t __wasi_thread_spawn( source.push_str( r#"#ifdef _REENTRANT -uint32_t __imported_wasi_thread_spawn(uintptr_t arg0) __WASI_NOEXCEPT __attribute__(( +uint32_t __imported_wasi_thread_spawn(intptr_t arg0) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi"), __import_name__("thread-spawn") )); int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { - return (int32_t) __imported_wasi_thread_spawn((uintptr_t) start_arg); + return (int32_t) __imported_wasi_thread_spawn((intptr_t) start_arg); +} +#endif + +#ifdef __cplusplus } #endif "#, @@ -513,12 +521,12 @@ fn print_func_signature(ret: &mut String, func: &InterfaceFunc, header: bool) { fn c_typeref_name(tref: &TypeRef, wtp: &witx::WasmType) -> String { match tref { - TypeRef::Name(_) => c_wasm_type(wtp).to_string(), + TypeRef::Name(_) => wasm_type(wtp).to_string(), TypeRef::Value(anon_type) => match &**anon_type { Type::List(_) => unreachable!("arrays excluded above"), Type::Builtin(b) => builtin_type_name(*b).to_string(), - Type::Pointer(_) => "uintptr_t".to_string(), - Type::ConstPointer(_) => "uintptr_t".to_string(), + Type::Pointer(_) => "intptr_t".to_string(), + Type::ConstPointer(_) => "intptr_t".to_string(), Type::Record { .. } | Type::Variant { .. } | Type::Handle { .. } => unreachable!( "wasi should not have anonymous structs, unions, enums, flags, handles" ), @@ -545,11 +553,11 @@ fn print_c_typeref_casting_names( Type::List(_) => { if casting { ret.push_str(&format!( - "(uintptr_t) {0}, (__wasi_size_t) {0}_len", + "(intptr_t) {0}, (__wasi_size_t) {0}_len", &identifiername )); } else { - ret.push_str("uintptr_t, __wasi_size_t"); + ret.push_str("intptr_t, __wasi_size_t"); } j = j + 2; } @@ -600,9 +608,9 @@ fn print_c_typeref_casting_names( ret.push_str(", "); } if casting { - ret.push_str(&format!("(uintptr_t) retptr{}", i)); + ret.push_str(&format!("(intptr_t) retptr{}", i)); } else { - ret.push_str("uintptr_t"); + ret.push_str("intptr_t"); } } } @@ -611,9 +619,9 @@ fn print_c_typeref_casting_names( ret.push_str(", "); } if casting { - ret.push_str("(uintptr_t) retptr0"); + ret.push_str("(intptr_t) retptr0"); } else { - ret.push_str("uintptr_t"); + ret.push_str("intptr_t"); } } } @@ -650,7 +658,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { match results.len() { 0 => ret.push_str("void "), 1 => { - ret.push_str(c_wasm_type(&results[0])); + ret.push_str(wasm_type(&results[0])); ret.push_str(" "); } _ => unimplemented!(), @@ -841,7 +849,7 @@ fn intrepr_const(i: IntRepr) -> &'static str { IntRepr::U64 => "UINT64_C", } } -/* + fn wasm_type(wasm: &WasmType) -> &'static str { match wasm { WasmType::I32 => "int32_t", @@ -850,13 +858,4 @@ fn wasm_type(wasm: &WasmType) -> &'static str { WasmType::F64 => "double", } } -*/ -fn c_wasm_type(wasm: &WasmType) -> &'static str { - match wasm { - WasmType::I32 => "uint32_t", - WasmType::I64 => "uint64_t", - WasmType::F32 => "float", - WasmType::F64 => "double", - } -} From 8a294b8512f8ff2190236cecd4fd2b4255656790 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 31 Oct 2023 16:41:09 -0400 Subject: [PATCH 15/43] change comment in main.yml from wasi64 to wasm64 --- .github/workflows/main.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 487301b4b..9bec40ebe 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -118,14 +118,14 @@ jobs: shell: bash run: make -j4 THREAD_MODEL=posix - - name: Build wasi64 + libc - # Build wasi64 + - name: Build wasm64 + libc + # Build wasm64 if: matrix.clang_version != '10.0.0' shell: bash run: make -j4 WASM64=yes - - name: Build wasi64 + libc + threads - # Build wasi64 with thread support + - name: Build wasm64 + libc + threads + # Build wasm64 with thread support if: matrix.clang_version != '10.0.0' shell: bash run: make -j4 WASM64=yes THREAD_MODEL=posix From 46ed3a82097acae0da89b3613b4e56af7698bac3 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 31 Oct 2023 16:49:39 -0400 Subject: [PATCH 16/43] Fix c_header.rs issue with rust fmt --- tools/wasi-headers/src/c_header.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 3ac7a9888..a64b984f5 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -858,4 +858,3 @@ fn wasm_type(wasm: &WasmType) -> &'static str { WasmType::F64 => "double", } } - From 4877ea7490866a007966ddc27ee59bd0d85a530c Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 18 Nov 2023 16:39:15 -0500 Subject: [PATCH 17/43] support dlfcn.h for wasm64 --- expected/wasm64-wasi-threads/include-all.c | 1 + expected/wasm64-wasi-threads/predefined-macros.txt | 9 +++++++++ expected/wasm64-wasi/include-all.c | 1 + expected/wasm64-wasi/predefined-macros.txt | 9 +++++++++ 4 files changed, 20 insertions(+) diff --git a/expected/wasm64-wasi-threads/include-all.c b/expected/wasm64-wasi-threads/include-all.c index 0b43b07d2..28b592438 100644 --- a/expected/wasm64-wasi-threads/include-all.c +++ b/expected/wasm64-wasi-threads/include-all.c @@ -75,6 +75,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt index ef26687d8..0120f130b 100644 --- a/expected/wasm64-wasi-threads/predefined-macros.txt +++ b/expected/wasm64-wasi-threads/predefined-macros.txt @@ -1499,6 +1499,14 @@ #define RRFIXEDSZ NS_RRFIXEDSZ #define RRQ 01 #define RS_HIPRI 0x01 +#define RTLD_DEFAULT ((void *)0) +#define RTLD_GLOBAL 256 +#define RTLD_LAZY 1 +#define RTLD_LOCAL 8 +#define RTLD_NEXT ((void *)-1) +#define RTLD_NODELETE 4096 +#define RTLD_NOLOAD 4 +#define RTLD_NOW 2 #define RUSAGE_CHILDREN 2 #define RUSAGE_SELF 1 #define R_OK (4) @@ -2044,6 +2052,7 @@ #define _Complex_I (0.0f+1.0fi) #define _DIRENT_H #define _DIRENT_HAVE_D_TYPE +#define _DLFCN_H #define _ENDIAN_H #define _ERRNO_H #define _ERR_H diff --git a/expected/wasm64-wasi/include-all.c b/expected/wasm64-wasi/include-all.c index 86297f3ef..297e48b14 100644 --- a/expected/wasm64-wasi/include-all.c +++ b/expected/wasm64-wasi/include-all.c @@ -75,6 +75,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt index f0d687b74..a53d9ebac 100644 --- a/expected/wasm64-wasi/predefined-macros.txt +++ b/expected/wasm64-wasi/predefined-macros.txt @@ -1467,6 +1467,14 @@ #define RRFIXEDSZ NS_RRFIXEDSZ #define RRQ 01 #define RS_HIPRI 0x01 +#define RTLD_DEFAULT ((void *)0) +#define RTLD_GLOBAL 256 +#define RTLD_LAZY 1 +#define RTLD_LOCAL 8 +#define RTLD_NEXT ((void *)-1) +#define RTLD_NODELETE 4096 +#define RTLD_NOLOAD 4 +#define RTLD_NOW 2 #define RUSAGE_CHILDREN 2 #define RUSAGE_SELF 1 #define R_OK (4) @@ -2010,6 +2018,7 @@ #define _Complex_I (0.0f+1.0fi) #define _DIRENT_H #define _DIRENT_HAVE_D_TYPE +#define _DLFCN_H #define _ENDIAN_H #define _ERRNO_H #define _ERR_H From a814fa8b3f94d1669a13aabc0feb9989654d459e Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 22:33:51 -0500 Subject: [PATCH 18/43] add import name for wasi64 with _i64 postfix --- tools/wasi-headers/src/c_header.rs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index a64b984f5..83bf278c7 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -86,6 +86,12 @@ extern "C" {{ #include #include +#ifdef __wasm64__ +#define IMPORT_NAME(x) __import_name__(x "-i64") +#else +#define IMPORT_NAME(x) __import_name__(x) +#endif + #ifdef __cplusplus extern "C" {{ #endif @@ -145,7 +151,7 @@ int32_t __wasi_thread_spawn( r#"#ifdef _REENTRANT uint32_t __imported_wasi_thread_spawn(intptr_t arg0) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi"), - __import_name__("thread-spawn") + IMPORT_NAME("thread-spawn") )); int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { @@ -677,7 +683,7 @@ fn print_func_source(ret: &mut String, func: &InterfaceFunc, module_name: &Id) { ident_name(module_name) )); ret.push_str(&format!( - " __import_name__(\"{}\")\n", + " IMPORT_NAME(\"{}\")\n", ident_name(&func.name) )); ret.push_str("));\n\n"); From d6aac51af124226341e0527e4d0a92cca0c7ac91 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 22:36:39 -0500 Subject: [PATCH 19/43] generate __wasilibc_real.c from rust code --- libc-bottom-half/sources/__wasilibc_real.c | 98 ++++++++++++---------- 1 file changed, 52 insertions(+), 46 deletions(-) diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 58f5959cc..edbc579f8 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -13,13 +13,19 @@ #include #include +#ifdef __wasm64__ +#define IMPORT_NAME(x) __import_name__(x "-i64") +#else +#define IMPORT_NAME(x) __import_name__(x) +#endif + #ifdef __cplusplus extern "C" { #endif int32_t __imported_wasi_snapshot_preview1_args_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("args_get") + IMPORT_NAME("args_get") )); __wasi_errno_t __wasi_args_get( @@ -31,7 +37,7 @@ __wasi_errno_t __wasi_args_get( int32_t __imported_wasi_snapshot_preview1_args_sizes_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("args_sizes_get") + IMPORT_NAME("args_sizes_get") )); __wasi_errno_t __wasi_args_sizes_get( @@ -43,7 +49,7 @@ __wasi_errno_t __wasi_args_sizes_get( int32_t __imported_wasi_snapshot_preview1_environ_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("environ_get") + IMPORT_NAME("environ_get") )); __wasi_errno_t __wasi_environ_get( @@ -55,7 +61,7 @@ __wasi_errno_t __wasi_environ_get( int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("environ_sizes_get") + IMPORT_NAME("environ_sizes_get") )); __wasi_errno_t __wasi_environ_sizes_get( @@ -67,7 +73,7 @@ __wasi_errno_t __wasi_environ_sizes_get( int32_t __imported_wasi_snapshot_preview1_clock_res_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("clock_res_get") + IMPORT_NAME("clock_res_get") )); __wasi_errno_t __wasi_clock_res_get( @@ -79,7 +85,7 @@ __wasi_errno_t __wasi_clock_res_get( int32_t __imported_wasi_snapshot_preview1_clock_time_get(int32_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("clock_time_get") + IMPORT_NAME("clock_time_get") )); __wasi_errno_t __wasi_clock_time_get( @@ -92,7 +98,7 @@ __wasi_errno_t __wasi_clock_time_get( int32_t __imported_wasi_snapshot_preview1_fd_advise(int32_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_advise") + IMPORT_NAME("fd_advise") )); __wasi_errno_t __wasi_fd_advise( @@ -106,7 +112,7 @@ __wasi_errno_t __wasi_fd_advise( int32_t __imported_wasi_snapshot_preview1_fd_allocate(int32_t, int64_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_allocate") + IMPORT_NAME("fd_allocate") )); __wasi_errno_t __wasi_fd_allocate( @@ -119,7 +125,7 @@ __wasi_errno_t __wasi_fd_allocate( int32_t __imported_wasi_snapshot_preview1_fd_close(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_close") + IMPORT_NAME("fd_close") )); __wasi_errno_t __wasi_fd_close( @@ -130,7 +136,7 @@ __wasi_errno_t __wasi_fd_close( int32_t __imported_wasi_snapshot_preview1_fd_datasync(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_datasync") + IMPORT_NAME("fd_datasync") )); __wasi_errno_t __wasi_fd_datasync( @@ -141,7 +147,7 @@ __wasi_errno_t __wasi_fd_datasync( int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_fdstat_get") + IMPORT_NAME("fd_fdstat_get") )); __wasi_errno_t __wasi_fd_fdstat_get( @@ -153,7 +159,7 @@ __wasi_errno_t __wasi_fd_fdstat_get( int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_fdstat_set_flags") + IMPORT_NAME("fd_fdstat_set_flags") )); __wasi_errno_t __wasi_fd_fdstat_set_flags( @@ -165,7 +171,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_rights(int32_t, int64_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_fdstat_set_rights") + IMPORT_NAME("fd_fdstat_set_rights") )); __wasi_errno_t __wasi_fd_fdstat_set_rights( @@ -178,7 +184,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_filestat_get") + IMPORT_NAME("fd_filestat_get") )); __wasi_errno_t __wasi_fd_filestat_get( @@ -190,7 +196,7 @@ __wasi_errno_t __wasi_fd_filestat_get( int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(int32_t, int64_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_filestat_set_size") + IMPORT_NAME("fd_filestat_set_size") )); __wasi_errno_t __wasi_fd_filestat_set_size( @@ -202,7 +208,7 @@ __wasi_errno_t __wasi_fd_filestat_set_size( int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_times(int32_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_filestat_set_times") + IMPORT_NAME("fd_filestat_set_times") )); __wasi_errno_t __wasi_fd_filestat_set_times( @@ -216,7 +222,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( int32_t __imported_wasi_snapshot_preview1_fd_pread(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_pread") + IMPORT_NAME("fd_pread") )); __wasi_errno_t __wasi_fd_pread( @@ -231,7 +237,7 @@ __wasi_errno_t __wasi_fd_pread( int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_prestat_get") + IMPORT_NAME("fd_prestat_get") )); __wasi_errno_t __wasi_fd_prestat_get( @@ -243,7 +249,7 @@ __wasi_errno_t __wasi_fd_prestat_get( int32_t __imported_wasi_snapshot_preview1_fd_prestat_dir_name(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_prestat_dir_name") + IMPORT_NAME("fd_prestat_dir_name") )); __wasi_errno_t __wasi_fd_prestat_dir_name( @@ -256,7 +262,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( int32_t __imported_wasi_snapshot_preview1_fd_pwrite(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_pwrite") + IMPORT_NAME("fd_pwrite") )); __wasi_errno_t __wasi_fd_pwrite( @@ -271,7 +277,7 @@ __wasi_errno_t __wasi_fd_pwrite( int32_t __imported_wasi_snapshot_preview1_fd_read(int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_read") + IMPORT_NAME("fd_read") )); __wasi_errno_t __wasi_fd_read( @@ -285,7 +291,7 @@ __wasi_errno_t __wasi_fd_read( int32_t __imported_wasi_snapshot_preview1_fd_readdir(int32_t, intptr_t, __wasi_size_t, int64_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_readdir") + IMPORT_NAME("fd_readdir") )); __wasi_errno_t __wasi_fd_readdir( @@ -300,7 +306,7 @@ __wasi_errno_t __wasi_fd_readdir( int32_t __imported_wasi_snapshot_preview1_fd_renumber(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_renumber") + IMPORT_NAME("fd_renumber") )); __wasi_errno_t __wasi_fd_renumber( @@ -312,7 +318,7 @@ __wasi_errno_t __wasi_fd_renumber( int32_t __imported_wasi_snapshot_preview1_fd_seek(int32_t, int64_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_seek") + IMPORT_NAME("fd_seek") )); __wasi_errno_t __wasi_fd_seek( @@ -326,7 +332,7 @@ __wasi_errno_t __wasi_fd_seek( int32_t __imported_wasi_snapshot_preview1_fd_sync(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_sync") + IMPORT_NAME("fd_sync") )); __wasi_errno_t __wasi_fd_sync( @@ -337,7 +343,7 @@ __wasi_errno_t __wasi_fd_sync( int32_t __imported_wasi_snapshot_preview1_fd_tell(int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_tell") + IMPORT_NAME("fd_tell") )); __wasi_errno_t __wasi_fd_tell( @@ -349,7 +355,7 @@ __wasi_errno_t __wasi_fd_tell( int32_t __imported_wasi_snapshot_preview1_fd_write(int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("fd_write") + IMPORT_NAME("fd_write") )); __wasi_errno_t __wasi_fd_write( @@ -363,7 +369,7 @@ __wasi_errno_t __wasi_fd_write( int32_t __imported_wasi_snapshot_preview1_path_create_directory(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_create_directory") + IMPORT_NAME("path_create_directory") )); __wasi_errno_t __wasi_path_create_directory( @@ -376,7 +382,7 @@ __wasi_errno_t __wasi_path_create_directory( int32_t __imported_wasi_snapshot_preview1_path_filestat_get(int32_t, int32_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_filestat_get") + IMPORT_NAME("path_filestat_get") )); __wasi_errno_t __wasi_path_filestat_get( @@ -391,7 +397,7 @@ __wasi_errno_t __wasi_path_filestat_get( int32_t __imported_wasi_snapshot_preview1_path_filestat_set_times(int32_t, int32_t, intptr_t, __wasi_size_t, int64_t, int64_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_filestat_set_times") + IMPORT_NAME("path_filestat_set_times") )); __wasi_errno_t __wasi_path_filestat_set_times( @@ -408,7 +414,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( int32_t __imported_wasi_snapshot_preview1_path_link(int32_t, int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_link") + IMPORT_NAME("path_link") )); __wasi_errno_t __wasi_path_link( @@ -425,7 +431,7 @@ __wasi_errno_t __wasi_path_link( int32_t __imported_wasi_snapshot_preview1_path_open(int32_t, int32_t, intptr_t, __wasi_size_t, int32_t, int64_t, int64_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_open") + IMPORT_NAME("path_open") )); __wasi_errno_t __wasi_path_open( @@ -444,7 +450,7 @@ __wasi_errno_t __wasi_path_open( int32_t __imported_wasi_snapshot_preview1_path_readlink(int32_t, intptr_t, __wasi_size_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_readlink") + IMPORT_NAME("path_readlink") )); __wasi_errno_t __wasi_path_readlink( @@ -460,7 +466,7 @@ __wasi_errno_t __wasi_path_readlink( int32_t __imported_wasi_snapshot_preview1_path_remove_directory(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_remove_directory") + IMPORT_NAME("path_remove_directory") )); __wasi_errno_t __wasi_path_remove_directory( @@ -473,7 +479,7 @@ __wasi_errno_t __wasi_path_remove_directory( int32_t __imported_wasi_snapshot_preview1_path_rename(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_rename") + IMPORT_NAME("path_rename") )); __wasi_errno_t __wasi_path_rename( @@ -489,7 +495,7 @@ __wasi_errno_t __wasi_path_rename( int32_t __imported_wasi_snapshot_preview1_path_symlink(intptr_t, __wasi_size_t, int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_symlink") + IMPORT_NAME("path_symlink") )); __wasi_errno_t __wasi_path_symlink( @@ -504,7 +510,7 @@ __wasi_errno_t __wasi_path_symlink( int32_t __imported_wasi_snapshot_preview1_path_unlink_file(int32_t, intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("path_unlink_file") + IMPORT_NAME("path_unlink_file") )); __wasi_errno_t __wasi_path_unlink_file( @@ -517,7 +523,7 @@ __wasi_errno_t __wasi_path_unlink_file( int32_t __imported_wasi_snapshot_preview1_poll_oneoff(intptr_t, intptr_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("poll_oneoff") + IMPORT_NAME("poll_oneoff") )); __wasi_errno_t __wasi_poll_oneoff( @@ -531,7 +537,7 @@ __wasi_errno_t __wasi_poll_oneoff( _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("proc_exit") + IMPORT_NAME("proc_exit") )); _Noreturn void __wasi_proc_exit( @@ -542,7 +548,7 @@ _Noreturn void __wasi_proc_exit( int32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("sched_yield") + IMPORT_NAME("sched_yield") )); __wasi_errno_t __wasi_sched_yield( @@ -553,7 +559,7 @@ __wasi_errno_t __wasi_sched_yield( int32_t __imported_wasi_snapshot_preview1_random_get(intptr_t, __wasi_size_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("random_get") + IMPORT_NAME("random_get") )); __wasi_errno_t __wasi_random_get( @@ -565,7 +571,7 @@ __wasi_errno_t __wasi_random_get( int32_t __imported_wasi_snapshot_preview1_sock_accept(int32_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("sock_accept") + IMPORT_NAME("sock_accept") )); __wasi_errno_t __wasi_sock_accept( @@ -578,7 +584,7 @@ __wasi_errno_t __wasi_sock_accept( int32_t __imported_wasi_snapshot_preview1_sock_recv(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("sock_recv") + IMPORT_NAME("sock_recv") )); __wasi_errno_t __wasi_sock_recv( @@ -594,7 +600,7 @@ __wasi_errno_t __wasi_sock_recv( int32_t __imported_wasi_snapshot_preview1_sock_send(int32_t, intptr_t, __wasi_size_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("sock_send") + IMPORT_NAME("sock_send") )); __wasi_errno_t __wasi_sock_send( @@ -609,7 +615,7 @@ __wasi_errno_t __wasi_sock_send( int32_t __imported_wasi_snapshot_preview1_sock_shutdown(int32_t, int32_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), - __import_name__("sock_shutdown") + IMPORT_NAME("sock_shutdown") )); __wasi_errno_t __wasi_sock_shutdown( @@ -622,7 +628,7 @@ __wasi_errno_t __wasi_sock_shutdown( #ifdef _REENTRANT uint32_t __imported_wasi_thread_spawn(intptr_t arg0) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi"), - __import_name__("thread-spawn") + IMPORT_NAME("thread-spawn") )); int32_t __wasi_thread_spawn(void* start_arg) __WASI_NOEXCEPT { From 9703cc13af7a7589cc6553d973d369a52318ed61 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 22:53:04 -0500 Subject: [PATCH 20/43] should be _i64 not -i64 --- tools/wasi-headers/src/c_header.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 83bf278c7..eade87f52 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -87,7 +87,7 @@ extern "C" {{ #include #ifdef __wasm64__ -#define IMPORT_NAME(x) __import_name__(x "-i64") +#define IMPORT_NAME(x) __import_name__(x "_i64") #else #define IMPORT_NAME(x) __import_name__(x) #endif From d2884b2f6b0f15f2bec2523e2352de64f727e995 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 22:54:22 -0500 Subject: [PATCH 21/43] fix __wasilibc_real.c --- libc-bottom-half/sources/__wasilibc_real.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index edbc579f8..3dba47403 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -14,7 +14,7 @@ #include #ifdef __wasm64__ -#define IMPORT_NAME(x) __import_name__(x "-i64") +#define IMPORT_NAME(x) __import_name__(x "_i64") #else #define IMPORT_NAME(x) __import_name__(x) #endif From 26f0de5a715b714a298ceff79844a459c982e8a7 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 23:16:54 -0500 Subject: [PATCH 22/43] __WASI_NOEXCEPT missing in the definition of function --- tools/wasi-headers/src/c_header.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index eade87f52..5c2e92c7f 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -522,7 +522,7 @@ fn print_func_signature(ret: &mut String, func: &InterfaceFunc, header: bool) { ret.push_str("\n"); } } - ret.push_str(")"); + ret.push_str(") __WASI_NOEXCEPT "); } fn c_typeref_name(tref: &TypeRef, wtp: &witx::WasmType) -> String { From 3f36fea298950daef049ae28f66637d244aaa58d Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 12 Dec 2023 23:17:46 -0500 Subject: [PATCH 23/43] fix __WASI_NOEXCEPT missing issue --- libc-bottom-half/sources/__wasilibc_real.c | 90 +++++++++++----------- 1 file changed, 45 insertions(+), 45 deletions(-) diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 3dba47403..c7b80b17d 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -31,7 +31,7 @@ int32_t __imported_wasi_snapshot_preview1_args_get(intptr_t, intptr_t) __WASI_NO __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((intptr_t) argv, (intptr_t) argv_buf); } @@ -43,7 +43,7 @@ int32_t __imported_wasi_snapshot_preview1_args_sizes_get(intptr_t, intptr_t) __W __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } @@ -55,7 +55,7 @@ int32_t __imported_wasi_snapshot_preview1_environ_get(intptr_t, intptr_t) __WASI __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((intptr_t) environ, (intptr_t) environ_buf); } @@ -67,7 +67,7 @@ int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(intptr_t, intptr_t) __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } @@ -79,7 +79,7 @@ int32_t __imported_wasi_snapshot_preview1_clock_res_get(int32_t, intptr_t) __WAS __wasi_errno_t __wasi_clock_res_get( __wasi_clockid_t id, __wasi_timestamp_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (intptr_t) retptr0); } @@ -92,7 +92,7 @@ __wasi_errno_t __wasi_clock_time_get( __wasi_clockid_t id, __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (intptr_t) retptr0); } @@ -106,7 +106,7 @@ __wasi_errno_t __wasi_fd_advise( __wasi_filesize_t offset, __wasi_filesize_t len, __wasi_advice_t advice -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((int32_t) fd, (int64_t) offset, (int64_t) len, (int32_t) advice); } @@ -119,7 +119,7 @@ __wasi_errno_t __wasi_fd_allocate( __wasi_fd_t fd, __wasi_filesize_t offset, __wasi_filesize_t len -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((int32_t) fd, (int64_t) offset, (int64_t) len); } @@ -130,7 +130,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_close(int32_t) __WASI_NOEXCEPT __at __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((int32_t) fd); } @@ -141,7 +141,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_datasync(int32_t) __WASI_NOEXCEPT _ __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((int32_t) fd); } @@ -153,7 +153,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(int32_t, intptr_t) __WAS __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (intptr_t) retptr0); } @@ -165,7 +165,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(int32_t, int32_t) __wasi_errno_t __wasi_fd_fdstat_set_flags( __wasi_fd_t fd, __wasi_fdflags_t flags -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((int32_t) fd, (int32_t) flags); } @@ -178,7 +178,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_fd_t fd, __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((int32_t) fd, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting); } @@ -190,7 +190,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(int32_t, intptr_t) __W __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (intptr_t) retptr0); } @@ -202,7 +202,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(int32_t, int64_t) __wasi_errno_t __wasi_fd_filestat_set_size( __wasi_fd_t fd, __wasi_filesize_t size -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((int32_t) fd, (int64_t) size); } @@ -216,7 +216,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( __wasi_timestamp_t atim, __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((int32_t) fd, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } @@ -231,7 +231,7 @@ __wasi_errno_t __wasi_fd_pread( size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } @@ -243,7 +243,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(int32_t, intptr_t) __WA __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (intptr_t) retptr0); } @@ -256,7 +256,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( __wasi_fd_t fd, uint8_t * path, __wasi_size_t path_len -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -271,7 +271,7 @@ __wasi_errno_t __wasi_fd_pwrite( size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } @@ -285,7 +285,7 @@ __wasi_errno_t __wasi_fd_read( __wasi_iovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } @@ -300,7 +300,7 @@ __wasi_errno_t __wasi_fd_readdir( __wasi_size_t buf_len, __wasi_dircookie_t cookie, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (intptr_t) buf, (__wasi_size_t) buf_len, (int64_t) cookie, (intptr_t) retptr0); } @@ -312,7 +312,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_renumber(int32_t, int32_t) __WASI_N __wasi_errno_t __wasi_fd_renumber( __wasi_fd_t fd, __wasi_fd_t to -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((int32_t) fd, (int32_t) to); } @@ -326,7 +326,7 @@ __wasi_errno_t __wasi_fd_seek( __wasi_filedelta_t offset, __wasi_whence_t whence, __wasi_filesize_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, (int64_t) offset, (int32_t) whence, (intptr_t) retptr0); } @@ -337,7 +337,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_sync(int32_t) __WASI_NOEXCEPT __att __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((int32_t) fd); } @@ -349,7 +349,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_tell(int32_t, intptr_t) __WASI_NOEX __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (intptr_t) retptr0); } @@ -363,7 +363,7 @@ __wasi_errno_t __wasi_fd_write( __wasi_ciovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } @@ -375,7 +375,7 @@ int32_t __imported_wasi_snapshot_preview1_path_create_directory(int32_t, intptr_ __wasi_errno_t __wasi_path_create_directory( __wasi_fd_t fd, char const *path -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -390,7 +390,7 @@ __wasi_errno_t __wasi_path_filestat_get( __wasi_lookupflags_t flags, char const *path, __wasi_filestat_t *retptr0 -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) retptr0); } @@ -407,7 +407,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( __wasi_timestamp_t atim, __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } @@ -423,7 +423,7 @@ __wasi_errno_t __wasi_path_link( char const *old_path, __wasi_fd_t new_fd, char const *new_path -){ +) __WASI_NOEXCEPT { size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, (int32_t) old_flags, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -443,7 +443,7 @@ __wasi_errno_t __wasi_path_open( __wasi_rights_t fs_rights_inheriting, __wasi_fdflags_t fdflags, __wasi_fd_t *retptr0 -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((int32_t) fd, (int32_t) dirflags, (intptr_t) path, (__wasi_size_t) path_len, (int32_t) oflags, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting, (int32_t) fdflags, (intptr_t) retptr0); } @@ -459,7 +459,7 @@ __wasi_errno_t __wasi_path_readlink( uint8_t * buf, __wasi_size_t buf_len, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) buf, (__wasi_size_t) buf_len, (intptr_t) retptr0); } @@ -472,7 +472,7 @@ int32_t __imported_wasi_snapshot_preview1_path_remove_directory(int32_t, intptr_ __wasi_errno_t __wasi_path_remove_directory( __wasi_fd_t fd, char const *path -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -487,7 +487,7 @@ __wasi_errno_t __wasi_path_rename( char const *old_path, __wasi_fd_t new_fd, char const *new_path -){ +) __WASI_NOEXCEPT { size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -502,7 +502,7 @@ __wasi_errno_t __wasi_path_symlink( char const *old_path, __wasi_fd_t fd, char const *new_path -){ +) __WASI_NOEXCEPT { size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -516,7 +516,7 @@ int32_t __imported_wasi_snapshot_preview1_path_unlink_file(int32_t, intptr_t, __ __wasi_errno_t __wasi_path_unlink_file( __wasi_fd_t fd, char const *path -){ +) __WASI_NOEXCEPT { size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -531,7 +531,7 @@ __wasi_errno_t __wasi_poll_oneoff( __wasi_event_t * out, __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((intptr_t) in, (intptr_t) out, (int32_t) nsubscriptions, (intptr_t) retptr0); } @@ -542,7 +542,7 @@ _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t) __WASI_NOEXC _Noreturn void __wasi_proc_exit( __wasi_exitcode_t rval -){ +) __WASI_NOEXCEPT { __imported_wasi_snapshot_preview1_proc_exit((int32_t) rval); } @@ -553,7 +553,7 @@ int32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attrib __wasi_errno_t __wasi_sched_yield( void -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sched_yield(); } @@ -565,7 +565,7 @@ int32_t __imported_wasi_snapshot_preview1_random_get(intptr_t, __wasi_size_t) __ __wasi_errno_t __wasi_random_get( uint8_t * buf, __wasi_size_t buf_len -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((intptr_t) buf, (__wasi_size_t) buf_len); } @@ -578,7 +578,7 @@ __wasi_errno_t __wasi_sock_accept( __wasi_fd_t fd, __wasi_fdflags_t flags, __wasi_fd_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, (int32_t) flags, (intptr_t) retptr0); } @@ -594,7 +594,7 @@ __wasi_errno_t __wasi_sock_recv( __wasi_riflags_t ri_flags, __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (intptr_t) ri_data, (__wasi_size_t) ri_data_len, (int32_t) ri_flags, (intptr_t) retptr0, (intptr_t) retptr1); } @@ -609,7 +609,7 @@ __wasi_errno_t __wasi_sock_send( size_t si_data_len, __wasi_siflags_t si_flags, __wasi_size_t *retptr0 -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (intptr_t) si_data, (__wasi_size_t) si_data_len, (int32_t) si_flags, (intptr_t) retptr0); } @@ -621,7 +621,7 @@ int32_t __imported_wasi_snapshot_preview1_sock_shutdown(int32_t, int32_t) __WASI __wasi_errno_t __wasi_sock_shutdown( __wasi_fd_t fd, __wasi_sdflags_t how -){ +) __WASI_NOEXCEPT { return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_shutdown((int32_t) fd, (int32_t) how); } From c8352f8c145fe1fc21db79893f45ed7aa4d9eef2 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 13 Dec 2023 03:37:16 -0500 Subject: [PATCH 24/43] fix the issue that the definition of one_polloff isn't right on wasm64 --- libc-bottom-half/headers/public/wasi/api.h | 90 ++++++++++----------- libc-bottom-half/sources/__wasilibc_real.c | 94 +++++++++++----------- tools/wasi-headers/src/c_header.rs | 8 +- 3 files changed, 96 insertions(+), 96 deletions(-) diff --git a/libc-bottom-half/headers/public/wasi/api.h b/libc-bottom-half/headers/public/wasi/api.h index 9378844bd..48d6f41e1 100644 --- a/libc-bottom-half/headers/public/wasi/api.h +++ b/libc-bottom-half/headers/public/wasi/api.h @@ -1311,7 +1311,7 @@ typedef struct __wasi_prestat_t { __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return command-line argument data sizes. * @return @@ -1321,7 +1321,7 @@ __wasi_errno_t __wasi_args_get( __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read environment variable data. * The sizes of the buffers should match that returned by `environ_sizes_get`. @@ -1330,7 +1330,7 @@ __wasi_errno_t __wasi_args_sizes_get( __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return environment variable data sizes. * @return @@ -1340,7 +1340,7 @@ __wasi_errno_t __wasi_environ_get( __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the resolution of a clock. * Implementations are required to provide a non-zero value for supported clocks. For unsupported clocks, @@ -1355,7 +1355,7 @@ __wasi_errno_t __wasi_clock_res_get( */ __wasi_clockid_t id, __wasi_timestamp_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the time value of a clock. * Note: This is similar to `clock_gettime` in POSIX. @@ -1372,7 +1372,7 @@ __wasi_errno_t __wasi_clock_time_get( */ __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Provide file advisory information on a file descriptor. * Note: This is similar to `posix_fadvise` in POSIX. @@ -1391,7 +1391,7 @@ __wasi_errno_t __wasi_fd_advise( * The advice. */ __wasi_advice_t advice -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Force the allocation of space in a file. * Note: This is similar to `posix_fallocate` in POSIX. @@ -1406,21 +1406,21 @@ __wasi_errno_t __wasi_fd_allocate( * The length of the area that is allocated. */ __wasi_filesize_t len -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Close a file descriptor. * Note: This is similar to `close` in POSIX. */ __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Synchronize the data of a file to disk. * Note: This is similar to `fdatasync` in POSIX. */ __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Get the attributes of a file descriptor. * Note: This returns similar flags to `fsync(fd, F_GETFL)` in POSIX, as well as additional fields. @@ -1430,7 +1430,7 @@ __wasi_errno_t __wasi_fd_datasync( __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the flags associated with a file descriptor. * Note: This is similar to `fcntl(fd, F_SETFL, flags)` in POSIX. @@ -1441,7 +1441,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_flags( * The desired values of the file descriptor flags. */ __wasi_fdflags_t flags -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the rights associated with a file descriptor. * This can only be used to remove rights, and returns `errno::notcapable` if called in a way that would attempt to add rights @@ -1453,7 +1453,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( */ __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the attributes of an open file. * @return @@ -1462,7 +1462,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the size of an open file. If this increases the file's size, the extra bytes are filled with zeros. * Note: This is similar to `ftruncate` in POSIX. @@ -1473,7 +1473,7 @@ __wasi_errno_t __wasi_fd_filestat_set_size( * The desired file size. */ __wasi_filesize_t size -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the timestamps of an open file or directory. * Note: This is similar to `futimens` in POSIX. @@ -1492,7 +1492,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( * A bitmask indicating which timestamps to adjust. */ __wasi_fstflags_t fst_flags -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read from a file descriptor, without using and updating the file descriptor's offset. * Note: This is similar to `preadv` in POSIX. @@ -1514,7 +1514,7 @@ __wasi_errno_t __wasi_fd_pread( */ __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return a description of the given preopened file descriptor. * @return @@ -1523,7 +1523,7 @@ __wasi_errno_t __wasi_fd_pread( __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return a description of the given preopened file descriptor. */ @@ -1534,7 +1534,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( */ uint8_t * path, __wasi_size_t path_len -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write to a file descriptor, without using and updating the file descriptor's offset. * Note: This is similar to `pwritev` in POSIX. @@ -1556,7 +1556,7 @@ __wasi_errno_t __wasi_fd_pwrite( */ __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read from a file descriptor. * Note: This is similar to `readv` in POSIX. @@ -1574,7 +1574,7 @@ __wasi_errno_t __wasi_fd_read( */ size_t iovs_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read directory entries from a directory. * When successful, the contents of the output buffer consist of a sequence of @@ -1600,7 +1600,7 @@ __wasi_errno_t __wasi_fd_readdir( */ __wasi_dircookie_t cookie, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Atomically replace a file descriptor by renumbering another file descriptor. * Due to the strong focus on thread safety, this environment does not provide @@ -1617,7 +1617,7 @@ __wasi_errno_t __wasi_fd_renumber( * The file descriptor to overwrite. */ __wasi_fd_t to -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Move the offset of a file descriptor. * Note: This is similar to `lseek` in POSIX. @@ -1635,14 +1635,14 @@ __wasi_errno_t __wasi_fd_seek( */ __wasi_whence_t whence, __wasi_filesize_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Synchronize the data and metadata of a file to disk. * Note: This is similar to `fsync` in POSIX. */ __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the current offset of a file descriptor. * Note: This is similar to `lseek(fd, 0, SEEK_CUR)` in POSIX. @@ -1652,7 +1652,7 @@ __wasi_errno_t __wasi_fd_sync( __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write to a file descriptor. * Note: This is similar to `writev` in POSIX. @@ -1668,7 +1668,7 @@ __wasi_errno_t __wasi_fd_write( */ size_t iovs_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a directory. * Note: This is similar to `mkdirat` in POSIX. @@ -1679,7 +1679,7 @@ __wasi_errno_t __wasi_path_create_directory( * The path at which to create the directory. */ char const *path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Return the attributes of a file or directory. * Note: This is similar to `stat` in POSIX. @@ -1697,7 +1697,7 @@ __wasi_errno_t __wasi_path_filestat_get( */ char const *path, __wasi_filestat_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Adjust the timestamps of a file or directory. * Note: This is similar to `utimensat` in POSIX. @@ -1724,7 +1724,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( * A bitmask indicating which timestamps to adjust. */ __wasi_fstflags_t fst_flags -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a hard link. * Note: This is similar to `linkat` in POSIX. @@ -1747,7 +1747,7 @@ __wasi_errno_t __wasi_path_link( * The destination path at which to create the hard link. */ char const *new_path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Open a file or directory. * The returned file descriptor is not guaranteed to be the lowest-numbered @@ -1787,7 +1787,7 @@ __wasi_errno_t __wasi_path_open( __wasi_rights_t fs_rights_inheriting, __wasi_fdflags_t fdflags, __wasi_fd_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Read the contents of a symbolic link. * Note: This is similar to `readlinkat` in POSIX. @@ -1806,7 +1806,7 @@ __wasi_errno_t __wasi_path_readlink( uint8_t * buf, __wasi_size_t buf_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Remove a directory. * Return `errno::notempty` if the directory is not empty. @@ -1818,7 +1818,7 @@ __wasi_errno_t __wasi_path_remove_directory( * The path to a directory to remove. */ char const *path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Rename a file or directory. * Note: This is similar to `renameat` in POSIX. @@ -1837,7 +1837,7 @@ __wasi_errno_t __wasi_path_rename( * The destination path to which to rename the file or directory. */ char const *new_path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Create a symbolic link. * Note: This is similar to `symlinkat` in POSIX. @@ -1852,7 +1852,7 @@ __wasi_errno_t __wasi_path_symlink( * The destination path at which to create the symbolic link. */ char const *new_path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Unlink a file. * Return `errno::isdir` if the path refers to a directory. @@ -1864,7 +1864,7 @@ __wasi_errno_t __wasi_path_unlink_file( * The path to a file to unlink. */ char const *path -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Concurrently poll for the occurrence of a set of events. * @return @@ -1884,7 +1884,7 @@ __wasi_errno_t __wasi_poll_oneoff( */ __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Terminate the process normally. An exit code of 0 indicates successful * termination of the program. The meanings of other values is dependent on @@ -1895,14 +1895,14 @@ _Noreturn void __wasi_proc_exit( * The exit code returned by the process. */ __wasi_exitcode_t rval -) __WASI_NOEXCEPT ; +) __WASI_NOEXCEPT; /** * Temporarily yield execution of the calling thread. * Note: This is similar to `sched_yield` in POSIX. */ __wasi_errno_t __wasi_sched_yield( void -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Write high-quality random data into a buffer. * This function blocks when the implementation is unable to immediately @@ -1917,7 +1917,7 @@ __wasi_errno_t __wasi_random_get( */ uint8_t * buf, __wasi_size_t buf_len -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Accept a new incoming connection. * Note: This is similar to `accept` in POSIX. @@ -1934,7 +1934,7 @@ __wasi_errno_t __wasi_sock_accept( */ __wasi_fdflags_t flags, __wasi_fd_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Receive a message from a socket. * Note: This is similar to `recv` in POSIX, though it also supports reading @@ -1958,7 +1958,7 @@ __wasi_errno_t __wasi_sock_recv( __wasi_riflags_t ri_flags, __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Send a message on a socket. * Note: This is similar to `send` in POSIX, though it also supports writing @@ -1981,7 +1981,7 @@ __wasi_errno_t __wasi_sock_send( */ __wasi_siflags_t si_flags, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** * Shut down socket send and receive channels. * Note: This is similar to `shutdown` in POSIX. @@ -1992,7 +1992,7 @@ __wasi_errno_t __wasi_sock_shutdown( * Which channels on the socket to shut down. */ __wasi_sdflags_t how -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); /** @} */ #ifdef _REENTRANT diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index c7b80b17d..4f0486455 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -31,7 +31,7 @@ int32_t __imported_wasi_snapshot_preview1_args_get(intptr_t, intptr_t) __WASI_NO __wasi_errno_t __wasi_args_get( uint8_t * * argv, uint8_t * argv_buf -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_get((intptr_t) argv, (intptr_t) argv_buf); } @@ -43,7 +43,7 @@ int32_t __imported_wasi_snapshot_preview1_args_sizes_get(intptr_t, intptr_t) __W __wasi_errno_t __wasi_args_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_args_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } @@ -55,7 +55,7 @@ int32_t __imported_wasi_snapshot_preview1_environ_get(intptr_t, intptr_t) __WASI __wasi_errno_t __wasi_environ_get( uint8_t * * environ, uint8_t * environ_buf -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_get((intptr_t) environ, (intptr_t) environ_buf); } @@ -67,7 +67,7 @@ int32_t __imported_wasi_snapshot_preview1_environ_sizes_get(intptr_t, intptr_t) __wasi_errno_t __wasi_environ_sizes_get( __wasi_size_t *retptr0, __wasi_size_t *retptr1 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_environ_sizes_get((intptr_t) retptr0, (intptr_t) retptr1); } @@ -79,7 +79,7 @@ int32_t __imported_wasi_snapshot_preview1_clock_res_get(int32_t, intptr_t) __WAS __wasi_errno_t __wasi_clock_res_get( __wasi_clockid_t id, __wasi_timestamp_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_res_get((int32_t) id, (intptr_t) retptr0); } @@ -92,7 +92,7 @@ __wasi_errno_t __wasi_clock_time_get( __wasi_clockid_t id, __wasi_timestamp_t precision, __wasi_timestamp_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_clock_time_get((int32_t) id, (int64_t) precision, (intptr_t) retptr0); } @@ -106,7 +106,7 @@ __wasi_errno_t __wasi_fd_advise( __wasi_filesize_t offset, __wasi_filesize_t len, __wasi_advice_t advice -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_advise((int32_t) fd, (int64_t) offset, (int64_t) len, (int32_t) advice); } @@ -119,7 +119,7 @@ __wasi_errno_t __wasi_fd_allocate( __wasi_fd_t fd, __wasi_filesize_t offset, __wasi_filesize_t len -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_allocate((int32_t) fd, (int64_t) offset, (int64_t) len); } @@ -130,7 +130,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_close(int32_t) __WASI_NOEXCEPT __at __wasi_errno_t __wasi_fd_close( __wasi_fd_t fd -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_close((int32_t) fd); } @@ -141,7 +141,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_datasync(int32_t) __WASI_NOEXCEPT _ __wasi_errno_t __wasi_fd_datasync( __wasi_fd_t fd -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_datasync((int32_t) fd); } @@ -153,7 +153,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_fdstat_get(int32_t, intptr_t) __WAS __wasi_errno_t __wasi_fd_fdstat_get( __wasi_fd_t fd, __wasi_fdstat_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_get((int32_t) fd, (intptr_t) retptr0); } @@ -165,7 +165,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_fdstat_set_flags(int32_t, int32_t) __wasi_errno_t __wasi_fd_fdstat_set_flags( __wasi_fd_t fd, __wasi_fdflags_t flags -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_flags((int32_t) fd, (int32_t) flags); } @@ -178,7 +178,7 @@ __wasi_errno_t __wasi_fd_fdstat_set_rights( __wasi_fd_t fd, __wasi_rights_t fs_rights_base, __wasi_rights_t fs_rights_inheriting -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_fdstat_set_rights((int32_t) fd, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting); } @@ -190,7 +190,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_filestat_get(int32_t, intptr_t) __W __wasi_errno_t __wasi_fd_filestat_get( __wasi_fd_t fd, __wasi_filestat_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_get((int32_t) fd, (intptr_t) retptr0); } @@ -202,7 +202,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_filestat_set_size(int32_t, int64_t) __wasi_errno_t __wasi_fd_filestat_set_size( __wasi_fd_t fd, __wasi_filesize_t size -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_size((int32_t) fd, (int64_t) size); } @@ -216,7 +216,7 @@ __wasi_errno_t __wasi_fd_filestat_set_times( __wasi_timestamp_t atim, __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_filestat_set_times((int32_t) fd, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } @@ -231,7 +231,7 @@ __wasi_errno_t __wasi_fd_pread( size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pread((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } @@ -243,7 +243,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_prestat_get(int32_t, intptr_t) __WA __wasi_errno_t __wasi_fd_prestat_get( __wasi_fd_t fd, __wasi_prestat_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_get((int32_t) fd, (intptr_t) retptr0); } @@ -256,7 +256,7 @@ __wasi_errno_t __wasi_fd_prestat_dir_name( __wasi_fd_t fd, uint8_t * path, __wasi_size_t path_len -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_prestat_dir_name((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -271,7 +271,7 @@ __wasi_errno_t __wasi_fd_pwrite( size_t iovs_len, __wasi_filesize_t offset, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_pwrite((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (int64_t) offset, (intptr_t) retptr0); } @@ -285,7 +285,7 @@ __wasi_errno_t __wasi_fd_read( __wasi_iovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_read((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } @@ -300,7 +300,7 @@ __wasi_errno_t __wasi_fd_readdir( __wasi_size_t buf_len, __wasi_dircookie_t cookie, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_readdir((int32_t) fd, (intptr_t) buf, (__wasi_size_t) buf_len, (int64_t) cookie, (intptr_t) retptr0); } @@ -312,7 +312,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_renumber(int32_t, int32_t) __WASI_N __wasi_errno_t __wasi_fd_renumber( __wasi_fd_t fd, __wasi_fd_t to -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_renumber((int32_t) fd, (int32_t) to); } @@ -326,7 +326,7 @@ __wasi_errno_t __wasi_fd_seek( __wasi_filedelta_t offset, __wasi_whence_t whence, __wasi_filesize_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_seek((int32_t) fd, (int64_t) offset, (int32_t) whence, (intptr_t) retptr0); } @@ -337,7 +337,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_sync(int32_t) __WASI_NOEXCEPT __att __wasi_errno_t __wasi_fd_sync( __wasi_fd_t fd -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_sync((int32_t) fd); } @@ -349,7 +349,7 @@ int32_t __imported_wasi_snapshot_preview1_fd_tell(int32_t, intptr_t) __WASI_NOEX __wasi_errno_t __wasi_fd_tell( __wasi_fd_t fd, __wasi_filesize_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_tell((int32_t) fd, (intptr_t) retptr0); } @@ -363,7 +363,7 @@ __wasi_errno_t __wasi_fd_write( __wasi_ciovec_t const *iovs, size_t iovs_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_fd_write((int32_t) fd, (intptr_t) iovs, (__wasi_size_t) iovs_len, (intptr_t) retptr0); } @@ -375,7 +375,7 @@ int32_t __imported_wasi_snapshot_preview1_path_create_directory(int32_t, intptr_ __wasi_errno_t __wasi_path_create_directory( __wasi_fd_t fd, char const *path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_create_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -390,7 +390,7 @@ __wasi_errno_t __wasi_path_filestat_get( __wasi_lookupflags_t flags, char const *path, __wasi_filestat_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_get((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) retptr0); } @@ -407,7 +407,7 @@ __wasi_errno_t __wasi_path_filestat_set_times( __wasi_timestamp_t atim, __wasi_timestamp_t mtim, __wasi_fstflags_t fst_flags -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_filestat_set_times((int32_t) fd, (int32_t) flags, (intptr_t) path, (__wasi_size_t) path_len, (int64_t) atim, (int64_t) mtim, (int32_t) fst_flags); } @@ -423,7 +423,7 @@ __wasi_errno_t __wasi_path_link( char const *old_path, __wasi_fd_t new_fd, char const *new_path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_link((int32_t) old_fd, (int32_t) old_flags, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -443,7 +443,7 @@ __wasi_errno_t __wasi_path_open( __wasi_rights_t fs_rights_inheriting, __wasi_fdflags_t fdflags, __wasi_fd_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_open((int32_t) fd, (int32_t) dirflags, (intptr_t) path, (__wasi_size_t) path_len, (int32_t) oflags, (int64_t) fs_rights_base, (int64_t) fs_rights_inheriting, (int32_t) fdflags, (intptr_t) retptr0); } @@ -459,7 +459,7 @@ __wasi_errno_t __wasi_path_readlink( uint8_t * buf, __wasi_size_t buf_len, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_readlink((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len, (intptr_t) buf, (__wasi_size_t) buf_len, (intptr_t) retptr0); } @@ -472,7 +472,7 @@ int32_t __imported_wasi_snapshot_preview1_path_remove_directory(int32_t, intptr_ __wasi_errno_t __wasi_path_remove_directory( __wasi_fd_t fd, char const *path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_remove_directory((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } @@ -487,7 +487,7 @@ __wasi_errno_t __wasi_path_rename( char const *old_path, __wasi_fd_t new_fd, char const *new_path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_rename((int32_t) fd, (intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) new_fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -502,7 +502,7 @@ __wasi_errno_t __wasi_path_symlink( char const *old_path, __wasi_fd_t fd, char const *new_path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t old_path_len = strlen(old_path); size_t new_path_len = strlen(new_path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_symlink((intptr_t) old_path, (__wasi_size_t) old_path_len, (int32_t) fd, (intptr_t) new_path, (__wasi_size_t) new_path_len); @@ -516,12 +516,12 @@ int32_t __imported_wasi_snapshot_preview1_path_unlink_file(int32_t, intptr_t, __ __wasi_errno_t __wasi_path_unlink_file( __wasi_fd_t fd, char const *path -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ size_t path_len = strlen(path); return (__wasi_errno_t) __imported_wasi_snapshot_preview1_path_unlink_file((int32_t) fd, (intptr_t) path, (__wasi_size_t) path_len); } -int32_t __imported_wasi_snapshot_preview1_poll_oneoff(intptr_t, intptr_t, int32_t, intptr_t) __WASI_NOEXCEPT __attribute__(( +int32_t __imported_wasi_snapshot_preview1_poll_oneoff(intptr_t, intptr_t, __wasi_size_t, intptr_t) __WASI_NOEXCEPT __attribute__(( __import_module__("wasi_snapshot_preview1"), IMPORT_NAME("poll_oneoff") )); @@ -531,8 +531,8 @@ __wasi_errno_t __wasi_poll_oneoff( __wasi_event_t * out, __wasi_size_t nsubscriptions, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { - return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((intptr_t) in, (intptr_t) out, (int32_t) nsubscriptions, (intptr_t) retptr0); +) __WASI_NOEXCEPT{ + return (__wasi_errno_t) __imported_wasi_snapshot_preview1_poll_oneoff((intptr_t) in, (intptr_t) out, (__wasi_size_t) nsubscriptions, (intptr_t) retptr0); } _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t) __WASI_NOEXCEPT __attribute__(( @@ -542,7 +542,7 @@ _Noreturn void __imported_wasi_snapshot_preview1_proc_exit(int32_t) __WASI_NOEXC _Noreturn void __wasi_proc_exit( __wasi_exitcode_t rval -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ __imported_wasi_snapshot_preview1_proc_exit((int32_t) rval); } @@ -553,7 +553,7 @@ int32_t __imported_wasi_snapshot_preview1_sched_yield() __WASI_NOEXCEPT __attrib __wasi_errno_t __wasi_sched_yield( void -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sched_yield(); } @@ -565,7 +565,7 @@ int32_t __imported_wasi_snapshot_preview1_random_get(intptr_t, __wasi_size_t) __ __wasi_errno_t __wasi_random_get( uint8_t * buf, __wasi_size_t buf_len -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_random_get((intptr_t) buf, (__wasi_size_t) buf_len); } @@ -578,7 +578,7 @@ __wasi_errno_t __wasi_sock_accept( __wasi_fd_t fd, __wasi_fdflags_t flags, __wasi_fd_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_accept((int32_t) fd, (int32_t) flags, (intptr_t) retptr0); } @@ -594,7 +594,7 @@ __wasi_errno_t __wasi_sock_recv( __wasi_riflags_t ri_flags, __wasi_size_t *retptr0, __wasi_roflags_t *retptr1 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_recv((int32_t) fd, (intptr_t) ri_data, (__wasi_size_t) ri_data_len, (int32_t) ri_flags, (intptr_t) retptr0, (intptr_t) retptr1); } @@ -609,7 +609,7 @@ __wasi_errno_t __wasi_sock_send( size_t si_data_len, __wasi_siflags_t si_flags, __wasi_size_t *retptr0 -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_send((int32_t) fd, (intptr_t) si_data, (__wasi_size_t) si_data_len, (int32_t) si_flags, (intptr_t) retptr0); } @@ -621,7 +621,7 @@ int32_t __imported_wasi_snapshot_preview1_sock_shutdown(int32_t, int32_t) __WASI __wasi_errno_t __wasi_sock_shutdown( __wasi_fd_t fd, __wasi_sdflags_t how -) __WASI_NOEXCEPT { +) __WASI_NOEXCEPT{ return (__wasi_errno_t) __imported_wasi_snapshot_preview1_sock_shutdown((int32_t) fd, (int32_t) how); } diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 5c2e92c7f..f92ce3967 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -136,7 +136,7 @@ int32_t __wasi_thread_spawn( * function. */ void *start_arg -) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); +) __WASI_NOEXCEPT __attribute__((__warn_unused_result__)); #endif #ifdef __cplusplus @@ -468,7 +468,7 @@ fn print_func_header(ret: &mut String, func: &InterfaceFunc) { } print_func_signature(ret, func, true); - ret.push_str(" __WASI_NOEXCEPT "); +// ret.push_str(" __WASI_NOEXCEPT "); if func.results.len() > 0 { ret.push_str(" __attribute__((__warn_unused_result__))"); } @@ -522,7 +522,7 @@ fn print_func_signature(ret: &mut String, func: &InterfaceFunc, header: bool) { ret.push_str("\n"); } } - ret.push_str(") __WASI_NOEXCEPT "); + ret.push_str(") __WASI_NOEXCEPT"); } fn c_typeref_name(tref: &TypeRef, wtp: &witx::WasmType) -> String { @@ -569,7 +569,7 @@ fn print_c_typeref_casting_names( } _ => { // Fix around buf_len which is incorrectly marked uint32_t in metadata - if identifiername.ends_with("_len") { + if identifiername == "nsubscriptions" || identifiername.ends_with("_len") { if casting { ret.push_str(&format!("(__wasi_size_t) {}", &identifiername)); } else { From 4f012946212f100aaef5c367afb833e9befaf89a Mon Sep 17 00:00:00 2001 From: trcrsired Date: Wed, 13 Dec 2023 03:40:13 -0500 Subject: [PATCH 25/43] fix the issue with rustfmt --- tools/wasi-headers/src/c_header.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index f92ce3967..94f5e798a 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -468,7 +468,6 @@ fn print_func_header(ret: &mut String, func: &InterfaceFunc) { } print_func_signature(ret, func, true); -// ret.push_str(" __WASI_NOEXCEPT "); if func.results.len() > 0 { ret.push_str(" __attribute__((__warn_unused_result__))"); } From c889960bf8f0aef4db31915d203a835065569beb Mon Sep 17 00:00:00 2001 From: trcrsired Date: Thu, 14 Dec 2023 12:48:53 -0500 Subject: [PATCH 26/43] change _i64 postfix to _wasm64 --- libc-bottom-half/sources/__wasilibc_real.c | 2 +- tools/wasi-headers/src/c_header.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libc-bottom-half/sources/__wasilibc_real.c b/libc-bottom-half/sources/__wasilibc_real.c index 4f0486455..37b3cd546 100644 --- a/libc-bottom-half/sources/__wasilibc_real.c +++ b/libc-bottom-half/sources/__wasilibc_real.c @@ -14,7 +14,7 @@ #include #ifdef __wasm64__ -#define IMPORT_NAME(x) __import_name__(x "_i64") +#define IMPORT_NAME(x) __import_name__(x "_wasm64") #else #define IMPORT_NAME(x) __import_name__(x) #endif diff --git a/tools/wasi-headers/src/c_header.rs b/tools/wasi-headers/src/c_header.rs index 94f5e798a..909a8643b 100644 --- a/tools/wasi-headers/src/c_header.rs +++ b/tools/wasi-headers/src/c_header.rs @@ -87,7 +87,7 @@ extern "C" {{ #include #ifdef __wasm64__ -#define IMPORT_NAME(x) __import_name__(x "_i64") +#define IMPORT_NAME(x) __import_name__(x "_wasm64") #else #define IMPORT_NAME(x) __import_name__(x) #endif From e6abb3c8fcc01b3277c9c4d4c6d166032a8fc6ad Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sun, 7 Jan 2024 16:31:01 -0500 Subject: [PATCH 27/43] add wasm64-wasi-preview2 --- Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 6fdc962bd..8de9f6fa9 100644 --- a/Makefile +++ b/Makefile @@ -54,7 +54,11 @@ ifeq ($(THREAD_MODEL), posix) endif ifeq ($(WASI_SNAPSHOT), preview2) -TARGET_TRIPLE = wasm32-wasi-preview2 + ifeq (${WASM64}, yes) + TARGET_TRIPLE = wasm64-wasi-preview2 + else + TARGET_TRIPLE = wasm32-wasi-preview2 + endif endif BUILTINS_LIB ?= $(shell ${CC} --print-libgcc-file-name) From 5c5b14e8e764624f0dd4da3a2076f0ec06ec39b3 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sun, 7 Jan 2024 16:34:14 -0500 Subject: [PATCH 28/43] Add wasm64-wasi-preview2 expected --- .../wasm64-wasi-preview2/defined-symbols.txt | 1206 ++++++ expected/wasm64-wasi-preview2/include-all.c | 171 + .../predefined-macros.txt | 3365 +++++++++++++++++ .../undefined-symbols.txt | 69 + 4 files changed, 4811 insertions(+) create mode 100644 expected/wasm64-wasi-preview2/defined-symbols.txt create mode 100644 expected/wasm64-wasi-preview2/include-all.c create mode 100644 expected/wasm64-wasi-preview2/predefined-macros.txt create mode 100644 expected/wasm64-wasi-preview2/undefined-symbols.txt diff --git a/expected/wasm64-wasi-preview2/defined-symbols.txt b/expected/wasm64-wasi-preview2/defined-symbols.txt new file mode 100644 index 000000000..6e743228b --- /dev/null +++ b/expected/wasm64-wasi-preview2/defined-symbols.txt @@ -0,0 +1,1206 @@ +_CLOCK_MONOTONIC +_CLOCK_REALTIME +_Exit +_IO_feof_unlocked +_IO_ferror_unlocked +_IO_getc +_IO_getc_unlocked +_IO_putc +_IO_putc_unlocked +__EINVAL +__ENOMEM +__SIG_ERR +__SIG_IGN +__asctime_r +__assert_fail +__c_dot_utf8 +__c_dot_utf8_locale +__c_locale +__clock +__clock_gettime +__clock_nanosleep +__cos +__cosdf +__cosl +__crypt_blowfish +__crypt_des +__crypt_md5 +__crypt_r +__crypt_sha256 +__crypt_sha512 +__ctype_b_loc +__ctype_get_mb_cur_max +__ctype_tolower_loc +__ctype_toupper_loc +__cxa_atexit +__cxa_finalize +__des_setkey +__do_des +__duplocale +__env_rm_add +__errno_location +__exp2f_data +__exp_data +__expo2 +__expo2f +__fbufsize +__fclose_ca +__fdopen +__fesetround +__fgetwc_unlocked +__flbf +__floatscan +__fmodeflags +__fopen_rb_ca +__fpending +__fpurge +__fputwc_unlocked +__freadable +__freadahead +__freading +__freadptr +__freadptrinc +__freelocale +__fseeko +__fseeko_unlocked +__fseterr +__fsetlocking +__fsmu8 +__ftello +__ftello_unlocked +__funcs_on_exit +__funcs_on_quick_exit +__futimesat +__fwritable +__fwritex +__fwriting +__get_locale +__getdelim +__getentropy +__getopt_msg +__gmtime_r +__hwcap +__inet_aton +__init_ssp +__intscan +__invtrigl_R +__isalnum_l +__isalpha_l +__isatty +__isblank_l +__iscntrl_l +__isdigit_l +__isgraph_l +__islower_l +__isoc99_fscanf +__isoc99_fwscanf +__isoc99_scanf +__isoc99_sscanf +__isoc99_swscanf +__isoc99_vfscanf +__isoc99_vfwscanf +__isoc99_vscanf +__isoc99_vsscanf +__isoc99_vswscanf +__isoc99_vwscanf +__isoc99_wscanf +__isprint_l +__ispunct_l +__isspace_l +__isupper_l +__iswalnum_l +__iswalpha_l +__iswblank_l +__iswcntrl_l +__iswctype_l +__iswdigit_l +__iswgraph_l +__iswlower_l +__iswprint_l +__iswpunct_l +__iswspace_l +__iswupper_l +__iswxdigit_l +__isxdigit_l +__lctrans +__lctrans_cur +__lctrans_impl +__ldexp_cexp +__ldexp_cexpf +__lgamma_r +__lgammaf_r +__lgammal_r +__libc +__libc_calloc +__libc_free +__libc_malloc +__loc_is_allocated +__localtime_r +__log2_data +__log2f_data +__log_data +__logf_data +__lseek +__main_void +__math_divzero +__math_divzerof +__math_invalid +__math_invalidf +__math_invalidl +__math_oflow +__math_oflowf +__math_uflow +__math_uflowf +__math_xflow +__math_xflowf +__memrchr +__mo_lookup +__month_to_secs +__newlocale +__nl_langinfo +__nl_langinfo_l +__ofl_add +__ofl_lock +__ofl_unlock +__optpos +__optreset +__overflow +__p1evll +__pio2_hi +__pio2_lo +__pleval +__polevll +__posix_getopt +__pow_log_data +__powf_log2_data +__progname +__progname_full +__putenv +__qsort_r +__rand48_step +__reallocarray +__rem_pio2 +__rem_pio2_large +__rem_pio2f +__rem_pio2l +__rsqrt_tab +__secs_to_tm +__secs_to_zone +__seed48 +__shgetc +__shlim +__signgam +__sin +__sindf +__sinl +__small_printf +__stack_chk_fail +__stack_chk_fail_local +__stack_chk_guard +__stderr_FILE +__stderr_used +__stdin_FILE +__stdin_used +__stdio_close +__stdio_exit +__stdio_exit_needed +__stdio_read +__stdio_seek +__stdio_write +__stdout_FILE +__stdout_used +__stdout_write +__stpcpy +__stpncpy +__strcasecmp_l +__strchrnul +__strcoll_l +__strerror_l +__strftime_fmt_1 +__strftime_l +__strncasecmp_l +__strtod_l +__strtof_l +__strtoimax_internal +__strtol_internal +__strtold_l +__strtoll_internal +__strtoul_internal +__strtoull_internal +__strtoumax_internal +__strxfrm_l +__sysinfo +__sysv_signal +__tan +__tandf +__tanl +__tm_to_secs +__tm_to_tzname +__tolower_l +__toread +__toread_needs_stdio_exit +__toupper_l +__towctrans_l +__towlower_l +__towrite +__towrite_needs_stdio_exit +__towupper_l +__tre_mem_alloc_impl +__tre_mem_destroy +__tre_mem_new_impl +__tsearch_balance +__uflow +__unlist_locked_file +__uselocale +__utc +__wasi_args_get +__wasi_args_sizes_get +__wasi_clock_res_get +__wasi_clock_time_get +__wasi_environ_get +__wasi_environ_sizes_get +__wasi_fd_advise +__wasi_fd_allocate +__wasi_fd_close +__wasi_fd_datasync +__wasi_fd_fdstat_get +__wasi_fd_fdstat_set_flags +__wasi_fd_fdstat_set_rights +__wasi_fd_filestat_get +__wasi_fd_filestat_set_size +__wasi_fd_filestat_set_times +__wasi_fd_pread +__wasi_fd_prestat_dir_name +__wasi_fd_prestat_get +__wasi_fd_pwrite +__wasi_fd_read +__wasi_fd_readdir +__wasi_fd_renumber +__wasi_fd_seek +__wasi_fd_sync +__wasi_fd_tell +__wasi_fd_write +__wasi_path_create_directory +__wasi_path_filestat_get +__wasi_path_filestat_set_times +__wasi_path_link +__wasi_path_open +__wasi_path_readlink +__wasi_path_remove_directory +__wasi_path_rename +__wasi_path_symlink +__wasi_path_unlink_file +__wasi_poll_oneoff +__wasi_proc_exit +__wasi_random_get +__wasi_sched_yield +__wasi_sock_accept +__wasi_sock_recv +__wasi_sock_send +__wasi_sock_shutdown +__wasilibc_access +__wasilibc_cwd +__wasilibc_deinitialize_environ +__wasilibc_dttoif +__wasilibc_ensure_environ +__wasilibc_environ +__wasilibc_fd_renumber +__wasilibc_find_abspath +__wasilibc_find_relpath +__wasilibc_find_relpath_alloc +__wasilibc_get_environ +__wasilibc_iftodt +__wasilibc_initialize_environ +__wasilibc_link +__wasilibc_link_newat +__wasilibc_link_oldat +__wasilibc_maybe_reinitialize_environ_eagerly +__wasilibc_nocwd___wasilibc_rmdirat +__wasilibc_nocwd___wasilibc_unlinkat +__wasilibc_nocwd_faccessat +__wasilibc_nocwd_fstatat +__wasilibc_nocwd_linkat +__wasilibc_nocwd_mkdirat_nomode +__wasilibc_nocwd_openat_nomode +__wasilibc_nocwd_opendirat +__wasilibc_nocwd_readlinkat +__wasilibc_nocwd_renameat +__wasilibc_nocwd_scandirat +__wasilibc_nocwd_symlinkat +__wasilibc_nocwd_utimensat +__wasilibc_open_nomode +__wasilibc_populate_preopens +__wasilibc_register_preopened_fd +__wasilibc_rename_newat +__wasilibc_rename_oldat +__wasilibc_rmdirat +__wasilibc_stat +__wasilibc_tell +__wasilibc_unlinkat +__wasilibc_utimens +__wasm_call_dtors +__wcscoll_l +__wcsftime_l +__wcsxfrm_l +__wctrans_l +__wctype_l +__xpg_basename +__xpg_strerror_r +__year_to_secs +_environ +_exit +_flushlbf +_initialize +_start +a64l +abort +abs +accept +accept4 +access +acos +acosf +acosh +acoshf +acoshl +acosl +aligned_alloc +alphasort +alphasort64 +arc4random +arc4random_buf +arc4random_uniform +asctime +asctime_r +asin +asinf +asinh +asinhf +asinhl +asinl +asprintf +at_quick_exit +atan +atan2 +atan2f +atan2l +atanf +atanh +atanhf +atanhl +atanl +atexit +atof +atoi +atol +atoll +basename +bcmp +bcopy +bsd_signal +bsearch +btowc +bzero +c16rtomb +c32rtomb +cabs +cabsf +cabsl +cacos +cacosf +cacosh +cacoshf +cacoshl +cacosl +calloc +carg +cargf +cargl +casin +casinf +casinh +casinhf +casinhl +casinl +catan +catanf +catanh +catanhf +catanhl +catanl +catclose +catgets +catopen +cbrt +cbrtf +cbrtl +ccos +ccosf +ccosh +ccoshf +ccoshl +ccosl +ceil +ceilf +ceill +cexp +cexpf +cexpl +chdir +cimag +cimagf +cimagl +clearenv +clearerr +clearerr_unlocked +clock +clock_getres +clock_gettime +clock_nanosleep +clog +clogf +clogl +close +closedir +confstr +conj +conjf +conjl +copysign +copysignf +copysignl +cos +cosf +cosh +coshf +coshl +cosl +cpow +cpowf +cpowl +cproj +cprojf +cprojl +creal +crealf +creall +creat +creat64 +crypt +crypt_r +csin +csinf +csinh +csinhf +csinhl +csinl +csqrt +csqrtf +csqrtl +ctan +ctanf +ctanh +ctanhf +ctanhl +ctanl +ctime +ctime_r +difftime +dirfd +dirname +div +dprintf +drand48 +drem +dremf +duplocale +ecvt +encrypt +environ +erand48 +erf +erfc +erfcf +erfcl +erff +erfl +errno +exit +exp +exp10 +exp10f +exp10l +exp2 +exp2f +exp2l +expf +expl +explicit_bzero +expm1 +expm1f +expm1l +fabs +fabsf +fabsl +faccessat +fclose +fcntl +fcvt +fdatasync +fdclosedir +fdim +fdimf +fdiml +fdopen +fdopendir +feclearexcept +fegetenv +fegetexceptflag +fegetround +feholdexcept +feof +feof_unlocked +feraiseexcept +ferror +ferror_unlocked +fesetenv +fesetexceptflag +fesetround +fetestexcept +feupdateenv +fflush +fflush_unlocked +ffs +ffsl +ffsll +fgetc +fgetc_unlocked +fgetln +fgetpos +fgetpos64 +fgets +fgets_unlocked +fgetwc +fgetwc_unlocked +fgetws +fgetws_unlocked +fileno +fileno_unlocked +finite +finitef +floor +floorf +floorl +fma +fmaf +fmal +fmax +fmaxf +fmaxl +fmemopen +fmin +fminf +fminl +fmod +fmodf +fmodl +fmtmsg +fnmatch +fopen +fopen64 +fopencookie +fpathconf +fprintf +fpurge +fputc +fputc_unlocked +fputs +fputs_unlocked +fputwc +fputwc_unlocked +fputws +fputws_unlocked +fread +fread_unlocked +free +freelocale +freopen +freopen64 +frexp +frexpf +frexpl +fscanf +fseek +fseeko +fseeko64 +fsetpos +fsetpos64 +fstat +fstatat +fsync +ftell +ftello +ftello64 +ftime +ftruncate +futimens +futimesat +fwide +fwprintf +fwrite +fwrite_unlocked +fwscanf +gcvt +get_avphys_pages +get_nprocs +get_nprocs_conf +get_phys_pages +getc +getc_unlocked +getchar +getchar_unlocked +getcwd +getdate +getdate_err +getdelim +getdomainname +getentropy +getenv +gethostid +getline +getopt +getopt_long +getopt_long_only +getpagesize +getpid +getrusage +getsockopt +getsubopt +gettimeofday +getw +getwc +getwc_unlocked +getwchar +getwchar_unlocked +glob +glob64 +globfree +globfree64 +gmtime +gmtime_r +hcreate +hcreate_r +hdestroy +hdestroy_r +hsearch +hsearch_r +htonl +htons +hypot +hypotf +hypotl +iconv +iconv_close +iconv_open +ilogb +ilogbf +ilogbl +imaxabs +imaxdiv +in6addr_any +in6addr_loopback +index +inet_aton +inet_ntop +inet_pton +initstate +insque +ioctl +iprintf +isalnum +isalnum_l +isalpha +isalpha_l +isascii +isatty +isblank +isblank_l +iscntrl +iscntrl_l +isdigit +isdigit_l +isgraph +isgraph_l +islower +islower_l +isprint +isprint_l +ispunct +ispunct_l +isspace +isspace_l +isupper +isupper_l +iswalnum +iswalnum_l +iswalpha +iswalpha_l +iswblank +iswblank_l +iswcntrl +iswcntrl_l +iswctype +iswctype_l +iswdigit +iswdigit_l +iswgraph +iswgraph_l +iswlower +iswlower_l +iswprint +iswprint_l +iswpunct +iswpunct_l +iswspace +iswspace_l +iswupper +iswupper_l +iswxdigit +iswxdigit_l +isxdigit +isxdigit_l +j0 +j0f +j1 +j1f +jn +jnf +jrand48 +l64a +labs +lcong48 +ldexp +ldexpf +ldexpl +ldiv +lfind +lgamma +lgamma_r +lgammaf +lgammaf_r +lgammal +lgammal_r +link +linkat +llabs +lldiv +llrint +llrintf +llrintl +llround +llroundf +llroundl +localeconv +localtime +localtime_r +log +log10 +log10f +log10l +log1p +log1pf +log1pl +log2 +log2f +log2l +logb +logbf +logbl +logf +logl +lrand48 +lrint +lrintf +lrintl +lround +lroundf +lroundl +lsearch +lseek +lstat +malloc +malloc_usable_size +mblen +mbrlen +mbrtoc16 +mbrtoc32 +mbrtowc +mbsinit +mbsnrtowcs +mbsrtowcs +mbstowcs +mbtowc +memccpy +memchr +memcmp +memcpy +memmem +memmove +mempcpy +memrchr +memset +mkdir +mkdirat +mktime +mmap +modf +modff +modfl +mrand48 +munmap +nan +nanf +nanl +nanosleep +nearbyint +nearbyintf +nearbyintl +newlocale +nextafter +nextafterf +nextafterl +nexttoward +nexttowardf +nexttowardl +nftw +nftw64 +nl_langinfo +nl_langinfo_l +nrand48 +ntohl +ntohs +open +open_memstream +open_wmemstream +openat +opendir +opendirat +optarg +opterr +optind +optopt +optreset +pathconf +perror +poll +posix_close +posix_fadvise +posix_fallocate +posix_memalign +pow +pow10 +pow10f +pow10l +powf +powl +pread +preadv +printf +program_invocation_name +program_invocation_short_name +pselect +psignal +putc +putc_unlocked +putchar +putchar_unlocked +putenv +puts +putw +putwc +putwc_unlocked +putwchar +putwchar_unlocked +pwrite +pwritev +qsort +qsort_r +quick_exit +raise +rand +rand_r +random +read +readdir +readlink +readlinkat +readv +realloc +reallocarray +recv +regcomp +regerror +regexec +regfree +remainder +remainderf +remainderl +remove +remque +remquo +remquof +remquol +rename +renameat +rewind +rewinddir +rindex +rint +rintf +rintl +rmdir +round +roundf +roundl +sbrk +scalb +scalbf +scalbln +scalblnf +scalblnl +scalbn +scalbnf +scalbnl +scandir +scandirat +scanf +sched_yield +seed48 +seekdir +select +send +setbuf +setbuffer +setenv +setkey +setlinebuf +setlocale +setstate +setvbuf +shutdown +signal +signgam +significand +significandf +sin +sincos +sincosf +sincosl +sinf +sinh +sinhf +sinhl +sinl +sleep +snprintf +sprintf +sqrt +sqrtf +sqrtl +srand +srand48 +srandom +sscanf +stat +stderr +stdin +stdout +stpcpy +stpncpy +strcasecmp +strcasecmp_l +strcasestr +strcat +strchr +strchrnul +strcmp +strcoll +strcoll_l +strcpy +strcspn +strdup +strerror +strerror_l +strerror_r +strfmon +strfmon_l +strftime +strftime_l +strlcat +strlcpy +strlen +strncasecmp +strncasecmp_l +strncat +strncmp +strncpy +strndup +strnlen +strpbrk +strptime +strrchr +strsep +strsignal +strspn +strstr +strtod +strtod_l +strtof +strtof_l +strtoimax +strtok +strtok_r +strtol +strtold +strtold_l +strtoll +strtoul +strtoull +strtoumax +strverscmp +strxfrm +strxfrm_l +swab +swprintf +swscanf +symlink +symlinkat +sysconf +tan +tanf +tanh +tanhf +tanhl +tanl +tdelete +tdestroy +telldir +tfind +tgamma +tgammaf +tgammal +thrd_sleep +time +timegm +times +timespec_get +toascii +tolower +tolower_l +toupper +toupper_l +towctrans +towctrans_l +towlower +towlower_l +towupper +towupper_l +trunc +truncate +truncf +truncl +tsearch +twalk +uname +ungetc +ungetwc +unlink +unlinkat +unsetenv +uselocale +usleep +utime +utimensat +utimes +vasprintf +vdprintf +versionsort +versionsort64 +vfprintf +vfscanf +vfwprintf +vfwscanf +vprintf +vscanf +vsnprintf +vsprintf +vsscanf +vswprintf +vswscanf +vwprintf +vwscanf +wcpcpy +wcpncpy +wcrtomb +wcscasecmp +wcscasecmp_l +wcscat +wcschr +wcscmp +wcscoll +wcscoll_l +wcscpy +wcscspn +wcsdup +wcsftime +wcsftime_l +wcslen +wcsncasecmp +wcsncasecmp_l +wcsncat +wcsncmp +wcsncpy +wcsnlen +wcsnrtombs +wcspbrk +wcsrchr +wcsrtombs +wcsspn +wcsstr +wcstod +wcstof +wcstoimax +wcstok +wcstol +wcstold +wcstoll +wcstombs +wcstoul +wcstoull +wcstoumax +wcswcs +wcswidth +wcsxfrm +wcsxfrm_l +wctob +wctomb +wctrans +wctrans_l +wctype +wctype_l +wcwidth +wmemchr +wmemcmp +wmemcpy +wmemmove +wmemset +wprintf +write +writev +wscanf +y0 +y0f +y1 +y1f +yn +ynf diff --git a/expected/wasm64-wasi-preview2/include-all.c b/expected/wasm64-wasi-preview2/include-all.c new file mode 100644 index 000000000..297e48b14 --- /dev/null +++ b/expected/wasm64-wasi-preview2/include-all.c @@ -0,0 +1,171 @@ +#include <__errno.h> +#include <__errno_values.h> +#include <__fd_set.h> +#include <__function___isatty.h> +#include <__functions_malloc.h> +#include <__functions_memcpy.h> +#include <__header_dirent.h> +#include <__header_fcntl.h> +#include <__header_inttypes.h> +#include <__header_netinet_in.h> +#include <__header_poll.h> +#include <__header_stdlib.h> +#include <__header_string.h> +#include <__header_sys_ioctl.h> +#include <__header_sys_resource.h> +#include <__header_sys_socket.h> +#include <__header_sys_stat.h> +#include <__header_time.h> +#include <__header_unistd.h> +#include <__macro_FD_SETSIZE.h> +#include <__macro_PAGESIZE.h> +#include <__mode_t.h> +#include <__seek.h> +#include <__struct_dirent.h> +#include <__struct_in6_addr.h> +#include <__struct_in_addr.h> +#include <__struct_iovec.h> +#include <__struct_msghdr.h> +#include <__struct_pollfd.h> +#include <__struct_rusage.h> +#include <__struct_sockaddr.h> +#include <__struct_sockaddr_in.h> +#include <__struct_sockaddr_in6.h> +#include <__struct_sockaddr_storage.h> +#include <__struct_sockaddr_un.h> +#include <__struct_stat.h> +#include <__struct_timespec.h> +#include <__struct_timeval.h> +#include <__struct_tm.h> +#include <__struct_tms.h> +#include <__typedef_DIR.h> +#include <__typedef_blkcnt_t.h> +#include <__typedef_blksize_t.h> +#include <__typedef_clock_t.h> +#include <__typedef_clockid_t.h> +#include <__typedef_dev_t.h> +#include <__typedef_fd_set.h> +#include <__typedef_gid_t.h> +#include <__typedef_in_addr_t.h> +#include <__typedef_in_port_t.h> +#include <__typedef_ino_t.h> +#include <__typedef_mode_t.h> +#include <__typedef_nfds_t.h> +#include <__typedef_nlink_t.h> +#include <__typedef_off_t.h> +#include <__typedef_sa_family_t.h> +#include <__typedef_sigset_t.h> +#include <__typedef_socklen_t.h> +#include <__typedef_ssize_t.h> +#include <__typedef_suseconds_t.h> +#include <__typedef_time_t.h> +#include <__typedef_uid_t.h> +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include diff --git a/expected/wasm64-wasi-preview2/predefined-macros.txt b/expected/wasm64-wasi-preview2/predefined-macros.txt new file mode 100644 index 000000000..dec1ead06 --- /dev/null +++ b/expected/wasm64-wasi-preview2/predefined-macros.txt @@ -0,0 +1,3365 @@ +#define ABDAY_1 0x20000 +#define ABDAY_2 0x20001 +#define ABDAY_3 0x20002 +#define ABDAY_4 0x20003 +#define ABDAY_5 0x20004 +#define ABDAY_6 0x20005 +#define ABDAY_7 0x20006 +#define ABMON_1 0x2000E +#define ABMON_10 0x20017 +#define ABMON_11 0x20018 +#define ABMON_12 0x20019 +#define ABMON_2 0x2000F +#define ABMON_3 0x20010 +#define ABMON_4 0x20011 +#define ABMON_5 0x20012 +#define ABMON_6 0x20013 +#define ABMON_7 0x20014 +#define ABMON_8 0x20015 +#define ABMON_9 0x20016 +#define ABORT 238 +#define ACK 04 +#define ADD ns_uop_add +#define ADJ_ESTERROR 0x0008 +#define ADJ_FREQUENCY 0x0002 +#define ADJ_MAXERROR 0x0004 +#define ADJ_MICRO 0x1000 +#define ADJ_NANO 0x2000 +#define ADJ_OFFSET 0x0001 +#define ADJ_OFFSET_SINGLESHOT 0x8001 +#define ADJ_OFFSET_SS_READ 0xa001 +#define ADJ_SETOFFSET 0x0100 +#define ADJ_STATUS 0x0010 +#define ADJ_TAI 0x0080 +#define ADJ_TICK 0x4000 +#define ADJ_TIMECONST 0x0020 +#define AF_INET PF_INET +#define AF_INET6 PF_INET6 +#define AF_UNIX 3 +#define AF_UNSPEC PF_UNSPEC +#define ALT_DIGITS 0x2002F +#define AM_STR 0x20026 +#define ANYMARK 0x01 +#define AO 245 +#define AREGTYPE '\0' +#define ARFMAG "`\n" +#define ARG_MAX 131072 +#define ARMAG "!\n" +#define AT_EACCESS (0x0) +#define AT_FDCWD (-2) +#define AT_REMOVEDIR (0x4) +#define AT_SYMLINK_FOLLOW (0x2) +#define AT_SYMLINK_NOFOLLOW (0x1) +#define AUTHTYPE_CNT 5 +#define AUTHTYPE_KERBEROS_V4 1 +#define AUTHTYPE_KERBEROS_V5 2 +#define AUTHTYPE_MINK 4 +#define AUTHTYPE_NAME(x) authtype_names[x] +#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) +#define AUTHTYPE_NULL 0 +#define AUTHTYPE_SPX 3 +#define AUTHTYPE_TEST 99 +#define AUTH_HOW_MASK 2 +#define AUTH_HOW_MUTUAL 2 +#define AUTH_HOW_ONE_WAY 0 +#define AUTH_WHO_CLIENT 0 +#define AUTH_WHO_MASK 1 +#define AUTH_WHO_SERVER 1 +#define AYT 246 +#define BIG_ENDIAN __BIG_ENDIAN +#define BITSPERBYTE CHAR_BIT +#define BLKTYPE '4' +#define BLK_BYTECOUNT 2 +#define BLK_EOF 0x40 +#define BLK_EOR 0x80 +#define BLK_ERRORS 0x20 +#define BLK_RESTART 0x10 +#define BREAK 243 +#define BUFSIZ 1024 +#define BYTE_ORDER __BYTE_ORDER +#define CANBSIZ 255 +#define CBRK CEOL +#define CDISCARD CTRL('o') +#define CDSUSP CTRL('y') +#define CEOF CTRL('d') +#define CEOL '\0' +#define CEOT CEOF +#define CERASE 0177 +#define CFLUSH CDISCARD +#define CHARBITS (sizeof(char) * 8) +#define CHARCLASS_NAME_MAX 14 +#define CHAR_BIT 8 +#define CHAR_MAX 127 +#define CHAR_MIN (-128) +#define CHRTYPE '3' +#define CINTR CTRL('c') +#define CKILL CTRL('u') +#define CLNEXT CTRL('v') +#define CLOCKS_PER_SEC ((clock_t)1000000000) +#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) +#define CLOCK_REALTIME (&_CLOCK_REALTIME) +#define CMIN 1 +#define CMPLX(x,y) __CMPLX(x, y, double) +#define CMPLXF(x,y) __CMPLX(x, y, float) +#define CMPLXL(x,y) __CMPLX(x, y, long double) +#define CODESET 14 +#define COLL_WEIGHTS_MAX 2 +#define COMPLETE 2 +#define CONTINUE 3 +#define CONTTYPE '7' +#define CQUIT 034 +#define CREPRINT CTRL('r') +#define CRNCYSTR 0x4000F +#define CRPRNT CREPRINT +#define CSTART CTRL('q') +#define CSTATUS '\0' +#define CSTOP CTRL('s') +#define CSUSP CTRL('z') +#define CTIME 0 +#define CTRL(x) ((x)&037) +#define CWERASE CTRL('w') +#define C_ANY ns_c_any +#define C_CHAOS ns_c_chaos +#define C_HS ns_c_hs +#define C_IN ns_c_in +#define C_IRGRP 000040 +#define C_IROTH 000004 +#define C_IRUSR 000400 +#define C_ISBLK 060000 +#define C_ISCHR 020000 +#define C_ISCTG 0110000 +#define C_ISDIR 040000 +#define C_ISFIFO 010000 +#define C_ISGID 002000 +#define C_ISLNK 0120000 +#define C_ISREG 0100000 +#define C_ISSOCK 0140000 +#define C_ISUID 004000 +#define C_ISVTX 001000 +#define C_IWGRP 000020 +#define C_IWOTH 000002 +#define C_IWUSR 000200 +#define C_IXGRP 000010 +#define C_IXOTH 000001 +#define C_IXUSR 000100 +#define C_NONE ns_c_none +#define DATA 03 +#define DAY_1 0x20007 +#define DAY_2 0x20008 +#define DAY_3 0x20009 +#define DAY_4 0x2000A +#define DAY_5 0x2000B +#define DAY_6 0x2000C +#define DAY_7 0x2000D +#define DBL_DECIMAL_DIG 17 +#define DBL_DIG 15 +#define DBL_EPSILON 2.22044604925031308085e-16 +#define DBL_HAS_SUBNORM 1 +#define DBL_MANT_DIG 53 +#define DBL_MAX 1.79769313486231570815e+308 +#define DBL_MAX_10_EXP 308 +#define DBL_MAX_EXP 1024 +#define DBL_MIN 2.22507385850720138309e-308 +#define DBL_MIN_10_EXP (-307) +#define DBL_MIN_EXP (-1021) +#define DBL_TRUE_MIN 4.94065645841246544177e-324 +#define DECIMAL_DIG 36 +#define DELAYTIMER_MAX 0x7fffffff +#define DELETE ns_uop_delete +#define DEV_BSIZE 512 +#define DIRTYPE '5' +#define DM 242 +#define DMAXEXP DBL_MAX_EXP +#define DMINEXP DBL_MIN_EXP +#define DO 253 +#define DONT 254 +#define DOUBLEBITS (sizeof(double) * 8) +#define DTTOIF(x) (__wasilibc_dttoif(x)) +#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE +#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE +#define DT_DIR __WASI_FILETYPE_DIRECTORY +#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM +#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK +#define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN +#define D_FMT 0x20029 +#define D_T_FMT 0x20028 +#define E2BIG __WASI_ERRNO_2BIG +#define EACCES __WASI_ERRNO_ACCES +#define EACCESS 2 +#define EADDRINUSE __WASI_ERRNO_ADDRINUSE +#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL +#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT +#define EAGAIN __WASI_ERRNO_AGAIN +#define EALREADY __WASI_ERRNO_ALREADY +#define EBADF __WASI_ERRNO_BADF +#define EBADID 5 +#define EBADMSG __WASI_ERRNO_BADMSG +#define EBADOP 4 +#define EBUSY __WASI_ERRNO_BUSY +#define EC 247 +#define ECANCELED __WASI_ERRNO_CANCELED +#define ECHILD __WASI_ERRNO_CHILD +#define ECONNABORTED __WASI_ERRNO_CONNABORTED +#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED +#define ECONNRESET __WASI_ERRNO_CONNRESET +#define EDEADLK __WASI_ERRNO_DEADLK +#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ +#define EDOM __WASI_ERRNO_DOM +#define EDQUOT __WASI_ERRNO_DQUOT +#define EEXIST __WASI_ERRNO_EXIST +#define EEXISTS 6 +#define EFAULT __WASI_ERRNO_FAULT +#define EFBIG __WASI_ERRNO_FBIG +#define EFD_CLOEXEC O_CLOEXEC +#define EFD_NONBLOCK O_NONBLOCK +#define EFD_SEMAPHORE 1 +#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH +#define EIDRM __WASI_ERRNO_IDRM +#define EILSEQ __WASI_ERRNO_ILSEQ +#define EINPROGRESS __WASI_ERRNO_INPROGRESS +#define EINTR __WASI_ERRNO_INTR +#define EINVAL __WASI_ERRNO_INVAL +#define EIO __WASI_ERRNO_IO +#define EISCONN __WASI_ERRNO_ISCONN +#define EISDIR __WASI_ERRNO_ISDIR +#define EL 248 +#define ELOOP __WASI_ERRNO_LOOP +#define EMFILE __WASI_ERRNO_MFILE +#define EMLINK __WASI_ERRNO_MLINK +#define EMSGSIZE __WASI_ERRNO_MSGSIZE +#define EMULTIHOP __WASI_ERRNO_MULTIHOP +#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG +#define ENCRYPT_CNT 9 +#define ENCRYPT_DEC_KEYID 8 +#define ENCRYPT_ENC_KEYID 7 +#define ENCRYPT_END 4 +#define ENCRYPT_IS 0 +#define ENCRYPT_NAME(x) encrypt_names[x] +#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) +#define ENCRYPT_REPLY 2 +#define ENCRYPT_REQEND 6 +#define ENCRYPT_REQSTART 5 +#define ENCRYPT_START 3 +#define ENCRYPT_SUPPORT 1 +#define ENCTYPE_ANY 0 +#define ENCTYPE_CNT 3 +#define ENCTYPE_DES_CFB64 1 +#define ENCTYPE_DES_OFB64 2 +#define ENCTYPE_NAME(x) enctype_names[x] +#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) +#define ENETDOWN __WASI_ERRNO_NETDOWN +#define ENETRESET __WASI_ERRNO_NETRESET +#define ENETUNREACH __WASI_ERRNO_NETUNREACH +#define ENFILE __WASI_ERRNO_NFILE +#define ENOBUFS __WASI_ERRNO_NOBUFS +#define ENODEV __WASI_ERRNO_NODEV +#define ENOENT __WASI_ERRNO_NOENT +#define ENOEXEC __WASI_ERRNO_NOEXEC +#define ENOLCK __WASI_ERRNO_NOLCK +#define ENOLINK __WASI_ERRNO_NOLINK +#define ENOMEM __WASI_ERRNO_NOMEM +#define ENOMSG __WASI_ERRNO_NOMSG +#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT +#define ENOSPACE 3 +#define ENOSPC __WASI_ERRNO_NOSPC +#define ENOSYS __WASI_ERRNO_NOSYS +#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE +#define ENOTCONN __WASI_ERRNO_NOTCONN +#define ENOTDIR __WASI_ERRNO_NOTDIR +#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY +#define ENOTFOUND 1 +#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE +#define ENOTSOCK __WASI_ERRNO_NOTSOCK +#define ENOTSUP __WASI_ERRNO_NOTSUP +#define ENOTTY __WASI_ERRNO_NOTTY +#define ENOUSER 7 +#define ENV_ESC 2 +#define ENV_USERVAR 3 +#define ENXIO __WASI_ERRNO_NXIO +#define EOF (-1) +#define EOPNOTSUPP ENOTSUP +#define EOR 239 +#define EOVERFLOW __WASI_ERRNO_OVERFLOW +#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD +#define EPERM __WASI_ERRNO_PERM +#define EPIPE __WASI_ERRNO_PIPE +#define EPROTO __WASI_ERRNO_PROTO +#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT +#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE +#define ERA 0x2002C +#define ERANGE __WASI_ERRNO_RANGE +#define ERA_D_FMT 0x2002E +#define ERA_D_T_FMT 0x20030 +#define ERA_T_FMT 0x20031 +#define EROFS __WASI_ERRNO_ROFS +#define ERROR 05 +#define ESPIPE __WASI_ERRNO_SPIPE +#define ESRCH __WASI_ERRNO_SRCH +#define ESTALE __WASI_ERRNO_STALE +#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT +#define ETXTBSY __WASI_ERRNO_TXTBSY +#define EUNDEF 0 +#define EWOULDBLOCK EAGAIN +#define EXDEV __WASI_ERRNO_XDEV +#define EXIT_FAILURE 1 +#define EXIT_SUCCESS 0 +#define EX_CANTCREAT 73 +#define EX_CONFIG 78 +#define EX_DATAERR 65 +#define EX_IOERR 74 +#define EX_NOHOST 68 +#define EX_NOINPUT 66 +#define EX_NOPERM 77 +#define EX_NOUSER 67 +#define EX_OK 0 +#define EX_OSERR 71 +#define EX_OSFILE 72 +#define EX_PROTOCOL 76 +#define EX_SOFTWARE 70 +#define EX_TEMPFAIL 75 +#define EX_UNAVAILABLE 69 +#define EX_USAGE 64 +#define EX__BASE 64 +#define EX__MAX 78 +#define FD_CLOEXEC (1) +#define FD_CLR(fd,set) (FD_CLR((fd), (set))) +#define FD_COPY(from,to) (FD_COPY((from), (to))) +#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) +#define FD_SET(fd,set) (FD_SET((fd), (set))) +#define FD_SETSIZE 1024 +#define FD_ZERO(set) (FD_ZERO((set))) +#define FE_ALL_EXCEPT 0 +#define FE_DFL_ENV ((const fenv_t *) -1) +#define FE_TONEAREST 0 +#define FIFOTYPE '6' +#define FILENAME_MAX 4096 +#define FILESIZEBITS 64 +#define FIONBIO 2 +#define FIONREAD 1 +#define FLOATBITS (sizeof(float) * 8) +#define FLT_DECIMAL_DIG 9 +#define FLT_DIG 6 +#define FLT_EPSILON 1.1920928955078125e-07F +#define FLT_EVAL_METHOD 0 +#define FLT_HAS_SUBNORM 1 +#define FLT_MANT_DIG 24 +#define FLT_MAX 3.40282346638528859812e+38F +#define FLT_MAX_10_EXP 38 +#define FLT_MAX_EXP 128 +#define FLT_MIN 1.17549435082228750797e-38F +#define FLT_MIN_10_EXP (-37) +#define FLT_MIN_EXP (-125) +#define FLT_RADIX 2 +#define FLT_ROUNDS (__builtin_flt_rounds()) +#define FLT_TRUE_MIN 1.40129846432481707092e-45F +#define FLUSHBAND 0x04 +#define FLUSHR 0x01 +#define FLUSHRW 0x03 +#define FLUSHW 0x02 +#define FMAXEXP FLT_MAX_EXP +#define FMINEXP FLT_MIN_EXP +#define FMNAMESZ 8 +#define FNM_CASEFOLD 0x10 +#define FNM_FILE_NAME FNM_PATHNAME +#define FNM_LEADING_DIR 0x8 +#define FNM_NOESCAPE 0x2 +#define FNM_NOMATCH 1 +#define FNM_NOSYS (-1) +#define FNM_PATHNAME 0x1 +#define FNM_PERIOD 0x4 +#define FOPEN_MAX 1000 +#define FORMERR ns_r_formerr +#define FORM_C 3 +#define FORM_N 1 +#define FORM_T 2 +#define FP_ILOGB0 FP_ILOGBNAN +#define FP_ILOGBNAN (-1-0x7fffffff) +#define FP_INFINITE 1 +#define FP_NAN 0 +#define FP_NORMAL 4 +#define FP_SUBNORMAL 3 +#define FP_ZERO 2 +#define FSETLOCKING_BYCALLER 2 +#define FSETLOCKING_INTERNAL 1 +#define FSETLOCKING_QUERY 0 +#define FTW_CHDIR 4 +#define FTW_D 2 +#define FTW_DEPTH 8 +#define FTW_DNR 3 +#define FTW_DP 6 +#define FTW_F 1 +#define FTW_MOUNT 2 +#define FTW_NS 4 +#define FTW_PHYS 1 +#define FTW_SL 5 +#define FTW_SLN 7 +#define F_GETFD (1) +#define F_GETFL (3) +#define F_LOCK 1 +#define F_OK (0) +#define F_SETFD (2) +#define F_SETFL (4) +#define F_TEST 3 +#define F_TLOCK 2 +#define F_ULOCK 0 +#define GA 249 +#define GETLONG NS_GET32 +#define GETSHORT NS_GET16 +#define GLOB_ABORTED 2 +#define GLOB_APPEND 0x20 +#define GLOB_DOOFFS 0x08 +#define GLOB_ERR 0x01 +#define GLOB_MARK 0x02 +#define GLOB_NOCHECK 0x10 +#define GLOB_NOESCAPE 0x40 +#define GLOB_NOMATCH 3 +#define GLOB_NOSORT 0x04 +#define GLOB_NOSPACE 1 +#define GLOB_NOSYS 4 +#define GLOB_PERIOD 0x80 +#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) +#define HFIXEDSZ NS_HFIXEDSZ +#define HIBITL MINLONG +#define HIBITS MINSHORT +#define HOST_NAME_MAX 255 +#define HUGE 3.40282346638528859812e+38F +#define HUGE_VAL ((double)INFINITY) +#define HUGE_VALF INFINITY +#define HUGE_VALL ((long double)INFINITY) +#define I _Complex_I +#define IAC 255 +#define ICMP6_DST_UNREACH 1 +#define ICMP6_DST_UNREACH_ADDR 3 +#define ICMP6_DST_UNREACH_ADMIN 1 +#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 +#define ICMP6_DST_UNREACH_NOPORT 4 +#define ICMP6_DST_UNREACH_NOROUTE 0 +#define ICMP6_ECHO_REPLY 129 +#define ICMP6_ECHO_REQUEST 128 +#define ICMP6_FILTER 1 +#define ICMP6_FILTER_BLOCK 1 +#define ICMP6_FILTER_BLOCKOTHERS 3 +#define ICMP6_FILTER_PASS 2 +#define ICMP6_FILTER_PASSONLY 4 +#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) +#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) +#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) +#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) +#define ICMP6_INFOMSG_MASK 0x80 +#define ICMP6_PACKET_TOO_BIG 2 +#define ICMP6_PARAMPROB_HEADER 0 +#define ICMP6_PARAMPROB_NEXTHEADER 1 +#define ICMP6_PARAMPROB_OPTION 2 +#define ICMP6_PARAM_PROB 4 +#define ICMP6_ROUTER_RENUMBERING 138 +#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 +#define ICMP6_RR_FLAGS_PREVDONE 0x08 +#define ICMP6_RR_FLAGS_REQRESULT 0x40 +#define ICMP6_RR_FLAGS_SPECSITE 0x10 +#define ICMP6_RR_FLAGS_TEST 0x80 +#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 +#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 +#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 +#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 +#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 +#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 +#define ICMP6_TIME_EXCEEDED 3 +#define ICMP6_TIME_EXCEED_REASSEMBLY 1 +#define ICMP6_TIME_EXCEED_TRANSIT 0 +#define ICMP_ADDRESS 17 +#define ICMP_ADDRESSREPLY 18 +#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) +#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) +#define ICMP_DEST_UNREACH 3 +#define ICMP_ECHO 8 +#define ICMP_ECHOREPLY 0 +#define ICMP_EXC_FRAGTIME 1 +#define ICMP_EXC_TTL 0 +#define ICMP_FRAG_NEEDED 4 +#define ICMP_HOST_ANO 10 +#define ICMP_HOST_ISOLATED 8 +#define ICMP_HOST_UNKNOWN 7 +#define ICMP_HOST_UNREACH 1 +#define ICMP_HOST_UNR_TOS 12 +#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) +#define ICMP_INFO_REPLY 16 +#define ICMP_INFO_REQUEST 15 +#define ICMP_IREQ 15 +#define ICMP_IREQREPLY 16 +#define ICMP_MASKLEN 12 +#define ICMP_MASKREPLY 18 +#define ICMP_MASKREQ 17 +#define ICMP_MAXTYPE 18 +#define ICMP_MINLEN 8 +#define ICMP_NET_ANO 9 +#define ICMP_NET_UNKNOWN 6 +#define ICMP_NET_UNREACH 0 +#define ICMP_NET_UNR_TOS 11 +#define ICMP_PARAMETERPROB 12 +#define ICMP_PARAMPROB 12 +#define ICMP_PARAMPROB_OPTABSENT 1 +#define ICMP_PKT_FILTERED 13 +#define ICMP_PORT_UNREACH 3 +#define ICMP_PREC_CUTOFF 15 +#define ICMP_PREC_VIOLATION 14 +#define ICMP_PROT_UNREACH 2 +#define ICMP_REDIRECT 5 +#define ICMP_REDIRECT_HOST 1 +#define ICMP_REDIRECT_NET 0 +#define ICMP_REDIRECT_TOSHOST 3 +#define ICMP_REDIRECT_TOSNET 2 +#define ICMP_REDIR_HOST 1 +#define ICMP_REDIR_HOSTTOS 3 +#define ICMP_REDIR_NET 0 +#define ICMP_REDIR_NETTOS 2 +#define ICMP_ROUTERADVERT 9 +#define ICMP_ROUTERSOLICIT 10 +#define ICMP_SOURCEQUENCH 4 +#define ICMP_SOURCE_QUENCH 4 +#define ICMP_SR_FAILED 5 +#define ICMP_TIMESTAMP 13 +#define ICMP_TIMESTAMPREPLY 14 +#define ICMP_TIME_EXCEEDED 11 +#define ICMP_TIMXCEED 11 +#define ICMP_TIMXCEED_INTRANS 0 +#define ICMP_TIMXCEED_REASS 1 +#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) +#define ICMP_TSTAMP 13 +#define ICMP_TSTAMPREPLY 14 +#define ICMP_UNREACH 3 +#define ICMP_UNREACH_FILTER_PROHIB 13 +#define ICMP_UNREACH_HOST 1 +#define ICMP_UNREACH_HOST_PRECEDENCE 14 +#define ICMP_UNREACH_HOST_PROHIB 10 +#define ICMP_UNREACH_HOST_UNKNOWN 7 +#define ICMP_UNREACH_ISOLATED 8 +#define ICMP_UNREACH_NEEDFRAG 4 +#define ICMP_UNREACH_NET 0 +#define ICMP_UNREACH_NET_PROHIB 9 +#define ICMP_UNREACH_NET_UNKNOWN 6 +#define ICMP_UNREACH_PORT 3 +#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 +#define ICMP_UNREACH_PROTOCOL 2 +#define ICMP_UNREACH_SRCFAIL 5 +#define ICMP_UNREACH_TOSHOST 12 +#define ICMP_UNREACH_TOSNET 11 +#define IFTODT(x) (__wasilibc_iftodt(x)) +#define IGMP_AWAKENING_MEMBER 5 +#define IGMP_DELAYING_MEMBER 1 +#define IGMP_DVMRP 0x13 +#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP +#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY +#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT +#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT +#define IGMP_IDLE_MEMBER 2 +#define IGMP_LAZY_MEMBER 3 +#define IGMP_MAX_HOST_REPORT_DELAY 10 +#define IGMP_MEMBERSHIP_QUERY 0x11 +#define IGMP_MINLEN 8 +#define IGMP_MTRACE 0x1f +#define IGMP_MTRACE_RESP 0x1e +#define IGMP_PIM 0x14 +#define IGMP_SLEEPING_MEMBER 4 +#define IGMP_TIMER_SCALE 10 +#define IGMP_TRACE 0x15 +#define IGMP_V1_MEMBERSHIP_REPORT 0x12 +#define IGMP_V2_LEAVE_GROUP 0x17 +#define IGMP_V2_MEMBERSHIP_REPORT 0x16 +#define IGMP_v1_ROUTER 1 +#define IGMP_v2_ROUTER 2 +#define IN6ADDRSZ NS_IN6ADDRSZ +#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } +#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } +#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) +#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) +#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) +#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) +#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) +#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) +#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) +#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) +#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) +#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) +#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) +#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) +#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) +#define INADDRSZ NS_INADDRSZ +#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) +#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) +#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) +#define INADDR_ANY ((in_addr_t) 0x00000000) +#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) +#define INADDR_DUMMY ((in_addr_t) 0xc0000008) +#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) +#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) +#define INADDR_NONE ((in_addr_t) 0xffffffff) +#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) +#define INDIR_MASK NS_CMPRSFLGS +#define INET6_ADDRSTRLEN 46 +#define INET_ADDRSTRLEN 16 +#define INFINITY 1e5000f +#define INT16SZ NS_INT16SZ +#define INT16_C(c) c +#define INT16_MAX (0x7fff) +#define INT16_MIN (-1-0x7fff) +#define INT32SZ NS_INT32SZ +#define INT32_C(c) c +#define INT32_MAX (0x7fffffff) +#define INT32_MIN (-1-0x7fffffff) +#define INT64_C(c) c ## LL +#define INT64_MAX (0x7fffffffffffffff) +#define INT64_MIN (-1-0x7fffffffffffffff) +#define INT8SZ NS_INT8SZ +#define INT8_C(c) c +#define INT8_MAX (0x7f) +#define INT8_MIN (-1-0x7f) +#define INTBITS (sizeof(int) * 8) +#define INTMAX_C(c) c ## LL +#define INTMAX_MAX INT64_MAX +#define INTMAX_MIN INT64_MIN +#define INTPTR_MAX INT32_MAX +#define INTPTR_MIN INT32_MIN +#define INT_FAST16_MAX INT16_MAX +#define INT_FAST16_MIN INT16_MIN +#define INT_FAST32_MAX INT32_MAX +#define INT_FAST32_MIN INT32_MIN +#define INT_FAST64_MAX INT64_MAX +#define INT_FAST64_MIN INT64_MIN +#define INT_FAST8_MAX INT8_MAX +#define INT_FAST8_MIN INT8_MIN +#define INT_LEAST16_MAX INT16_MAX +#define INT_LEAST16_MIN INT16_MIN +#define INT_LEAST32_MAX INT32_MAX +#define INT_LEAST32_MIN INT32_MIN +#define INT_LEAST64_MAX INT64_MAX +#define INT_LEAST64_MIN INT64_MIN +#define INT_LEAST8_MAX INT8_MAX +#define INT_LEAST8_MIN INT8_MIN +#define INT_MAX 0x7fffffff +#define INT_MIN (-1-0x7fffffff) +#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) +#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) +#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) +#define IN_CLASSA_MAX 128 +#define IN_CLASSA_NET 0xff000000 +#define IN_CLASSA_NSHIFT 24 +#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) +#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) +#define IN_CLASSB_MAX 65536 +#define IN_CLASSB_NET 0xffff0000 +#define IN_CLASSB_NSHIFT 16 +#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) +#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) +#define IN_CLASSC_NET 0xffffff00 +#define IN_CLASSC_NSHIFT 8 +#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) +#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) +#define IN_LOOPBACKNET 127 +#define IN_MULTICAST(a) IN_CLASSD(a) +#define IOV_MAX 1024 +#define IP 244 +#define IP6F_MORE_FRAG 0x0100 +#define IP6F_OFF_MASK 0xf8ff +#define IP6F_RESERVED_MASK 0x0600 +#define IP6OPT_JUMBO 0xc2 +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_NSAP_ADDR 0xc3 +#define IP6OPT_PAD1 0 +#define IP6OPT_PADN 1 +#define IP6OPT_ROUTER_ALERT 0x05 +#define IP6OPT_TUNNEL_LIMIT 0x04 +#define IP6OPT_TYPE(o) ((o) & 0xc0) +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xc0 +#define IP6OPT_TYPE_MUTABLE 0x20 +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6_ALERT_AN 0x0200 +#define IP6_ALERT_MLD 0x0000 +#define IP6_ALERT_RSVP 0x0100 +#define IPDEFTTL 64 +#define IPFRAGTTL 60 +#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) +#define IPOPT_CLASS_MASK 0x60 +#define IPOPT_CONTROL 0x00 +#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) +#define IPOPT_COPY 0x80 +#define IPOPT_DEBMEAS 0x40 +#define IPOPT_END IPOPT_EOL +#define IPOPT_EOL 0 +#define IPOPT_LSRR 131 +#define IPOPT_MEASUREMENT IPOPT_DEBMEAS +#define IPOPT_MINOFF 4 +#define IPOPT_NOOP IPOPT_NOP +#define IPOPT_NOP 1 +#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) +#define IPOPT_NUMBER_MASK 0x1f +#define IPOPT_OFFSET 2 +#define IPOPT_OLEN 1 +#define IPOPT_OPTVAL 0 +#define IPOPT_RA 148 +#define IPOPT_RESERVED1 0x20 +#define IPOPT_RESERVED2 0x60 +#define IPOPT_RR 7 +#define IPOPT_SATID 136 +#define IPOPT_SEC IPOPT_SECURITY +#define IPOPT_SECURITY 130 +#define IPOPT_SECUR_CONFID 0xf135 +#define IPOPT_SECUR_EFTO 0x789a +#define IPOPT_SECUR_MMMM 0xbc4d +#define IPOPT_SECUR_RESTR 0xaf13 +#define IPOPT_SECUR_SECRET 0xd788 +#define IPOPT_SECUR_TOPSECRET 0x6bc5 +#define IPOPT_SECUR_UNCLASS 0x0000 +#define IPOPT_SID IPOPT_SATID +#define IPOPT_SSRR 137 +#define IPOPT_TIMESTAMP IPOPT_TS +#define IPOPT_TS 68 +#define IPOPT_TS_PRESPEC 3 +#define IPOPT_TS_TSANDADDR 1 +#define IPOPT_TS_TSONLY 0 +#define IPPORT_RESERVED 1024 +#define IPPROTO_ICMP 1 +#define IPPROTO_IP 0 +#define IPPROTO_IPV6 41 +#define IPPROTO_RAW 255 +#define IPPROTO_TCP 6 +#define IPPROTO_UDP 17 +#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) +#define IPTOS_CLASS_CS0 0x00 +#define IPTOS_CLASS_CS1 0x20 +#define IPTOS_CLASS_CS2 0x40 +#define IPTOS_CLASS_CS3 0x60 +#define IPTOS_CLASS_CS4 0x80 +#define IPTOS_CLASS_CS5 0xa0 +#define IPTOS_CLASS_CS6 0xc0 +#define IPTOS_CLASS_CS7 0xe0 +#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 +#define IPTOS_CLASS_MASK 0xe0 +#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) +#define IPTOS_DSCP_AF11 0x28 +#define IPTOS_DSCP_AF12 0x30 +#define IPTOS_DSCP_AF13 0x38 +#define IPTOS_DSCP_AF21 0x48 +#define IPTOS_DSCP_AF22 0x50 +#define IPTOS_DSCP_AF23 0x58 +#define IPTOS_DSCP_AF31 0x68 +#define IPTOS_DSCP_AF32 0x70 +#define IPTOS_DSCP_AF33 0x78 +#define IPTOS_DSCP_AF41 0x88 +#define IPTOS_DSCP_AF42 0x90 +#define IPTOS_DSCP_AF43 0x98 +#define IPTOS_DSCP_EF 0xb8 +#define IPTOS_DSCP_MASK 0xfc +#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) +#define IPTOS_ECN_CE 0x03 +#define IPTOS_ECN_ECT0 0x02 +#define IPTOS_ECN_ECT1 0x01 +#define IPTOS_ECN_MASK 0x03 +#define IPTOS_ECN_NOT_ECT 0x00 +#define IPTOS_LOWCOST 0x02 +#define IPTOS_LOWDELAY 0x10 +#define IPTOS_MINCOST IPTOS_LOWCOST +#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) +#define IPTOS_PREC_CRITIC_ECP 0xa0 +#define IPTOS_PREC_FLASH 0x60 +#define IPTOS_PREC_FLASHOVERRIDE 0x80 +#define IPTOS_PREC_IMMEDIATE 0x40 +#define IPTOS_PREC_INTERNETCONTROL 0xc0 +#define IPTOS_PREC_MASK 0xe0 +#define IPTOS_PREC_NETCONTROL 0xe0 +#define IPTOS_PREC_PRIORITY 0x20 +#define IPTOS_PREC_ROUTINE 0x00 +#define IPTOS_RELIABILITY 0x04 +#define IPTOS_THROUGHPUT 0x08 +#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) +#define IPTOS_TOS_MASK 0x1E +#define IPTTLDEC 1 +#define IPV6_2292DSTOPTS 4 +#define IPV6_2292HOPLIMIT 8 +#define IPV6_2292HOPOPTS 3 +#define IPV6_2292PKTINFO 2 +#define IPV6_2292PKTOPTIONS 6 +#define IPV6_2292RTHDR 5 +#define IPV6_ADDRFORM 1 +#define IPV6_ADDR_PREFERENCES 72 +#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP +#define IPV6_AUTHHDR 10 +#define IPV6_AUTOFLOWLABEL 70 +#define IPV6_CHECKSUM 7 +#define IPV6_DONTFRAG 62 +#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP +#define IPV6_DSTOPTS 59 +#define IPV6_FREEBIND 78 +#define IPV6_HDRINCL 36 +#define IPV6_HOPLIMIT 52 +#define IPV6_HOPOPTS 54 +#define IPV6_IPSEC_POLICY 34 +#define IPV6_JOIN_ANYCAST 27 +#define IPV6_JOIN_GROUP 20 +#define IPV6_LEAVE_ANYCAST 28 +#define IPV6_LEAVE_GROUP 21 +#define IPV6_MINHOPCOUNT 73 +#define IPV6_MTU 24 +#define IPV6_MTU_DISCOVER 23 +#define IPV6_MULTICAST_ALL 29 +#define IPV6_MULTICAST_HOPS 18 +#define IPV6_MULTICAST_IF 17 +#define IPV6_MULTICAST_LOOP 19 +#define IPV6_NEXTHOP 9 +#define IPV6_ORIGDSTADDR 74 +#define IPV6_PATHMTU 61 +#define IPV6_PKTINFO 50 +#define IPV6_PMTUDISC_DO 2 +#define IPV6_PMTUDISC_DONT 0 +#define IPV6_PMTUDISC_INTERFACE 4 +#define IPV6_PMTUDISC_OMIT 5 +#define IPV6_PMTUDISC_PROBE 3 +#define IPV6_PMTUDISC_WANT 1 +#define IPV6_PREFER_SRC_CGA 0x0008 +#define IPV6_PREFER_SRC_COA 0x0004 +#define IPV6_PREFER_SRC_HOME 0x0400 +#define IPV6_PREFER_SRC_NONCGA 0x0800 +#define IPV6_PREFER_SRC_PUBLIC 0x0002 +#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 +#define IPV6_PREFER_SRC_TMP 0x0001 +#define IPV6_RECVDSTOPTS 58 +#define IPV6_RECVERR 25 +#define IPV6_RECVFRAGSIZE 77 +#define IPV6_RECVHOPLIMIT 51 +#define IPV6_RECVHOPOPTS 53 +#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR +#define IPV6_RECVPATHMTU 60 +#define IPV6_RECVPKTINFO 49 +#define IPV6_RECVRTHDR 56 +#define IPV6_RECVTCLASS 66 +#define IPV6_ROUTER_ALERT 22 +#define IPV6_ROUTER_ALERT_ISOLATE 30 +#define IPV6_RTHDR 57 +#define IPV6_RTHDRDSTOPTS 55 +#define IPV6_RTHDR_LOOSE 0 +#define IPV6_RTHDR_STRICT 1 +#define IPV6_RTHDR_TYPE_0 0 +#define IPV6_RXDSTOPTS IPV6_DSTOPTS +#define IPV6_RXHOPOPTS IPV6_HOPOPTS +#define IPV6_TCLASS 67 +#define IPV6_TRANSPARENT 75 +#define IPV6_UNICAST_HOPS 16 +#define IPV6_UNICAST_IF 76 +#define IPV6_V6ONLY 26 +#define IPV6_XFRM_POLICY 35 +#define IPVERSION 4 +#define IP_ADD_MEMBERSHIP 35 +#define IP_ADD_SOURCE_MEMBERSHIP 39 +#define IP_BIND_ADDRESS_NO_PORT 24 +#define IP_BLOCK_SOURCE 38 +#define IP_CHECKSUM 23 +#define IP_DEFAULT_MULTICAST_LOOP 1 +#define IP_DEFAULT_MULTICAST_TTL 1 +#define IP_DF 0x4000 +#define IP_DROP_MEMBERSHIP 36 +#define IP_DROP_SOURCE_MEMBERSHIP 40 +#define IP_FREEBIND 15 +#define IP_HDRINCL 3 +#define IP_IPSEC_POLICY 16 +#define IP_MAXPACKET 65535 +#define IP_MAX_MEMBERSHIPS 20 +#define IP_MF 0x2000 +#define IP_MINTTL 21 +#define IP_MSFILTER 41 +#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) +#define IP_MSS 576 +#define IP_MTU 14 +#define IP_MTU_DISCOVER 10 +#define IP_MULTICAST_ALL 49 +#define IP_MULTICAST_IF 32 +#define IP_MULTICAST_LOOP 34 +#define IP_MULTICAST_TTL 33 +#define IP_NODEFRAG 22 +#define IP_OFFMASK 0x1fff +#define IP_OPTIONS 4 +#define IP_ORIGDSTADDR 20 +#define IP_PASSSEC 18 +#define IP_PKTINFO 8 +#define IP_PKTOPTIONS 9 +#define IP_PMTUDISC 10 +#define IP_PMTUDISC_DO 2 +#define IP_PMTUDISC_DONT 0 +#define IP_PMTUDISC_INTERFACE 4 +#define IP_PMTUDISC_OMIT 5 +#define IP_PMTUDISC_PROBE 3 +#define IP_PMTUDISC_WANT 1 +#define IP_RECVERR 11 +#define IP_RECVERR_RFC4884 26 +#define IP_RECVFRAGSIZE 25 +#define IP_RECVOPTS 6 +#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR +#define IP_RECVRETOPTS IP_RETOPTS +#define IP_RECVTOS 13 +#define IP_RECVTTL 12 +#define IP_RETOPTS 7 +#define IP_RF 0x8000 +#define IP_ROUTER_ALERT 5 +#define IP_TOS 1 +#define IP_TRANSPARENT 19 +#define IP_TTL 2 +#define IP_UNBLOCK_SOURCE 37 +#define IP_UNICAST_IF 50 +#define IP_XFRM_POLICY 17 +#define IQUERY ns_o_iquery +#define I_ATMARK (__SID |31) +#define I_CANPUT (__SID |34) +#define I_CKBAND (__SID |29) +#define I_FDINSERT (__SID |16) +#define I_FIND (__SID |11) +#define I_FLUSH (__SID | 5) +#define I_FLUSHBAND (__SID |28) +#define I_GETBAND (__SID |30) +#define I_GETCLTIME (__SID |33) +#define I_GETSIG (__SID |10) +#define I_GRDOPT (__SID | 7) +#define I_GWROPT (__SID |20) +#define I_LINK (__SID |12) +#define I_LIST (__SID |21) +#define I_LOOK (__SID | 4) +#define I_NREAD (__SID | 1) +#define I_PEEK (__SID |15) +#define I_PLINK (__SID |22) +#define I_POP (__SID | 3) +#define I_PUNLINK (__SID |23) +#define I_PUSH (__SID | 2) +#define I_RECVFD (__SID |14) +#define I_SENDFD (__SID |17) +#define I_SETCLTIME (__SID |32) +#define I_SETSIG (__SID | 9) +#define I_SRDOPT (__SID | 6) +#define I_STR (__SID | 8) +#define I_SWROPT (__SID |19) +#define I_UNLINK (__SID |13) +#define LASTMARK 0x02 +#define LC_ALL 6 +#define LC_ALL_MASK 0x7fffffff +#define LC_COLLATE 3 +#define LC_COLLATE_MASK (1<(b))?(a):(b)) +#define MAXCDNAME NS_MAXCDNAME +#define MAXDNAME NS_MAXDNAME +#define MAXDOUBLE DBL_MAX +#define MAXFLOAT FLT_MAX +#define MAXHOSTNAMELEN 64 +#define MAXINT INT_MAX +#define MAXLABEL NS_MAXLABEL +#define MAXLONG LONG_MAX +#define MAXNAMLEN 255 +#define MAXPATHLEN 4096 +#define MAXSHORT SHRT_MAX +#define MAXSYMLINKS 20 +#define MAXTC 6 +#define MAXTTL 255 +#define MAX_IPOPTLEN 40 +#define MB_CUR_MAX (__ctype_get_mb_cur_max()) +#define MB_LEN_MAX 4 +#define MCAST_BLOCK_SOURCE 43 +#define MCAST_EXCLUDE 0 +#define MCAST_INCLUDE 1 +#define MCAST_JOIN_GROUP 42 +#define MCAST_JOIN_SOURCE_GROUP 46 +#define MCAST_LEAVE_GROUP 45 +#define MCAST_LEAVE_SOURCE_GROUP 47 +#define MCAST_MSFILTER 48 +#define MCAST_UNBLOCK_SOURCE 44 +#define MIN(a,b) (((a)<(b))?(a):(b)) +#define MINDOUBLE DBL_MIN +#define MINFLOAT FLT_MIN +#define MININT INT_MIN +#define MINLONG LONG_MIN +#define MINSHORT SHRT_MIN +#define MLD_LISTENER_QUERY 130 +#define MLD_LISTENER_REDUCTION 132 +#define MLD_LISTENER_REPORT 131 +#define MM_APPL 8 +#define MM_CONSOLE 512 +#define MM_ERROR 2 +#define MM_FIRM 4 +#define MM_HALT 1 +#define MM_HARD 1 +#define MM_INFO 4 +#define MM_NOCON 4 +#define MM_NOMSG 1 +#define MM_NOSEV 0 +#define MM_NOTOK (-1) +#define MM_NRECOV 128 +#define MM_NULLACT ((char*)0) +#define MM_NULLLBL ((char*)0) +#define MM_NULLMC 0L +#define MM_NULLSEV 0 +#define MM_NULLTAG ((char*)0) +#define MM_NULLTXT ((char*)0) +#define MM_OK 0 +#define MM_OPSYS 32 +#define MM_PRINT 256 +#define MM_RECOVER 64 +#define MM_SOFT 2 +#define MM_UTIL 16 +#define MM_WARNING 3 +#define MODE_ACK 0x04 +#define MODE_B 2 +#define MODE_C 3 +#define MODE_ECHO 0x0200 +#define MODE_EDIT 0x01 +#define MODE_FLOW 0x0100 +#define MODE_FORCE 0x1000 +#define MODE_INBIN 0x0400 +#define MODE_LIT_ECHO 0x10 +#define MODE_MASK 0x1f +#define MODE_OUTBIN 0x0800 +#define MODE_S 1 +#define MODE_SOFT_TAB 0x08 +#define MODE_TRAPSIG 0x02 +#define MOD_CLKA ADJ_OFFSET_SINGLESHOT +#define MOD_CLKB ADJ_TICK +#define MOD_ESTERROR ADJ_ESTERROR +#define MOD_FREQUENCY ADJ_FREQUENCY +#define MOD_MAXERROR ADJ_MAXERROR +#define MOD_MICRO ADJ_MICRO +#define MOD_NANO ADJ_NANO +#define MOD_OFFSET ADJ_OFFSET +#define MOD_STATUS ADJ_STATUS +#define MOD_TAI ADJ_TAI +#define MOD_TIMECONST ADJ_TIMECONST +#define MON_1 0x2001A +#define MON_10 0x20023 +#define MON_11 0x20024 +#define MON_12 0x20025 +#define MON_2 0x2001B +#define MON_3 0x2001C +#define MON_4 0x2001D +#define MON_5 0x2001E +#define MON_6 0x2001F +#define MON_7 0x20020 +#define MON_8 0x20021 +#define MON_9 0x20022 +#define MORECTL 1 +#define MOREDATA 2 +#define MSG_ANY 0x02 +#define MSG_BAND 0x04 +#define MSG_HIPRI 0x01 +#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK +#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED +#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL +#define MUXID_ALL (-1) +#define M_1_PI 0.31830988618379067154 +#define M_2_PI 0.63661977236758134308 +#define M_2_SQRTPI 1.12837916709551257390 +#define M_E 2.7182818284590452354 +#define M_LN10 2.30258509299404568402 +#define M_LN2 0.69314718055994530942 +#define M_LOG10E 0.43429448190325182765 +#define M_LOG2E 1.4426950408889634074 +#define M_PI 3.14159265358979323846 +#define M_PI_2 1.57079632679489661923 +#define M_PI_4 0.78539816339744830962 +#define M_SQRT1_2 0.70710678118654752440 +#define M_SQRT2 1.41421356237309504880 +#define NAMESERVER_PORT NS_DEFAULTPORT +#define NAME_MAX 255 +#define NAN (0.0f/0.0f) +#define NBBY 8 +#define NCARGS 131072 +#define ND_NA_FLAG_OVERRIDE 0x00000020 +#define ND_NA_FLAG_ROUTER 0x00000080 +#define ND_NA_FLAG_SOLICITED 0x00000040 +#define ND_NEIGHBOR_ADVERT 136 +#define ND_NEIGHBOR_SOLICIT 135 +#define ND_OPT_HOME_AGENT_INFO 8 +#define ND_OPT_MTU 5 +#define ND_OPT_PI_FLAG_AUTO 0x40 +#define ND_OPT_PI_FLAG_ONLINK 0x80 +#define ND_OPT_PI_FLAG_RADDR 0x20 +#define ND_OPT_PREFIX_INFORMATION 3 +#define ND_OPT_REDIRECTED_HEADER 4 +#define ND_OPT_RTR_ADV_INTERVAL 7 +#define ND_OPT_SOURCE_LINKADDR 1 +#define ND_OPT_TARGET_LINKADDR 2 +#define ND_RA_FLAG_HOME_AGENT 0x20 +#define ND_RA_FLAG_MANAGED 0x80 +#define ND_RA_FLAG_OTHER 0x40 +#define ND_REDIRECT 137 +#define ND_ROUTER_ADVERT 134 +#define ND_ROUTER_SOLICIT 133 +#define NEW_ENV_VALUE 1 +#define NEW_ENV_VAR 0 +#define NGROUPS 32 +#define NGROUPS_MAX 32 +#define NL_ARGMAX 9 +#define NL_CAT_LOCALE 1 +#define NL_LANGMAX 32 +#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) +#define NL_MSGMAX 32767 +#define NL_NMAX 16 +#define NL_SETD 1 +#define NL_SETMAX 255 +#define NL_TEXTMAX 2048 +#define NOERROR ns_r_noerror +#define NOEXPR 0x50001 +#define NOFILE 256 +#define NOGROUP (-1) +#define NOP 241 +#define NOSTR 0x50003 +#define NOTAUTH ns_r_notauth +#define NOTIMP ns_r_notimpl +#define NOTZONE ns_r_notzone +#define NR_ICMP_TYPES 18 +#define NR_ICMP_UNREACH 15 +#define NSLC 18 +#define NS_ALG_DH 2 +#define NS_ALG_DSA 3 +#define NS_ALG_DSS NS_ALG_DSA +#define NS_ALG_EXPIRE_ONLY 253 +#define NS_ALG_MD5RSA 1 +#define NS_ALG_PRIVATE_OID 254 +#define NS_CMPRSFLGS 0xc0 +#define NS_DEFAULTPORT 53 +#define NS_DSA_MAX_BYTES 405 +#define NS_DSA_MIN_SIZE 213 +#define NS_DSA_SIG_SIZE 41 +#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) +#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) +#define NS_HFIXEDSZ 12 +#define NS_IN6ADDRSZ 16 +#define NS_INADDRSZ 4 +#define NS_INT16SZ 2 +#define NS_INT32SZ 4 +#define NS_INT8SZ 1 +#define NS_KEY_EXTENDED_FLAGS 0x1000 +#define NS_KEY_NAME_ENTITY 0x0200 +#define NS_KEY_NAME_RESERVED 0x0300 +#define NS_KEY_NAME_TYPE 0x0300 +#define NS_KEY_NAME_USER 0x0000 +#define NS_KEY_NAME_ZONE 0x0100 +#define NS_KEY_NO_AUTH 0x8000 +#define NS_KEY_NO_CONF 0x4000 +#define NS_KEY_PROT_ANY 255 +#define NS_KEY_PROT_DNSSEC 3 +#define NS_KEY_PROT_EMAIL 2 +#define NS_KEY_PROT_IPSEC 4 +#define NS_KEY_PROT_TLS 1 +#define NS_KEY_RESERVED10 0x0020 +#define NS_KEY_RESERVED11 0x0010 +#define NS_KEY_RESERVED2 0x2000 +#define NS_KEY_RESERVED4 0x0800 +#define NS_KEY_RESERVED5 0x0400 +#define NS_KEY_RESERVED8 0x0080 +#define NS_KEY_RESERVED9 0x0040 +#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) +#define NS_KEY_RESERVED_BITMASK2 0xFFFF +#define NS_KEY_SIGNATORYMASK 0x000F +#define NS_KEY_TYPEMASK 0xC000 +#define NS_KEY_TYPE_AUTH_CONF 0x0000 +#define NS_KEY_TYPE_AUTH_ONLY 0x4000 +#define NS_KEY_TYPE_CONF_ONLY 0x8000 +#define NS_KEY_TYPE_NO_KEY 0xC000 +#define NS_MAXCDNAME 255 +#define NS_MAXDNAME 1025 +#define NS_MAXLABEL 63 +#define NS_MAXMSG 65535 +#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) +#define NS_MD5RSA_MAX_BITS 4096 +#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) +#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) +#define NS_MD5RSA_MIN_BITS 512 +#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) +#define NS_NOTIFY_OP ns_o_notify +#define NS_NXT_BITS 8 +#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_MAX 127 +#define NS_OPT_DNSSEC_OK 0x8000U +#define NS_OPT_NSID 3 +#define NS_PACKETSZ 512 +#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) +#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) +#define NS_QFIXEDSZ 4 +#define NS_RRFIXEDSZ 10 +#define NS_SIG_ALG 2 +#define NS_SIG_EXPIR 8 +#define NS_SIG_FOOT 16 +#define NS_SIG_LABELS 3 +#define NS_SIG_OTTL 4 +#define NS_SIG_SIGNED 12 +#define NS_SIG_SIGNER 18 +#define NS_SIG_TYPE 0 +#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" +#define NS_TSIG_ERROR_FORMERR -12 +#define NS_TSIG_ERROR_NO_SPACE -11 +#define NS_TSIG_ERROR_NO_TSIG -10 +#define NS_TSIG_FUDGE 300 +#define NS_TSIG_TCP_COUNT 100 +#define NS_UPDATE_OP ns_o_update +#define NTELOPTS (1+TELOPT_NEW_ENVIRON) +#define NULL ((void*)0) +#define NXDOMAIN ns_r_nxdomain +#define NXRRSET ns_r_nxrrset +#define NZERO 20 +#define OLD_ENV_VALUE 0 +#define OLD_ENV_VAR 1 +#define ONCE_FLAG_INIT 0 +#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) +#define O_APPEND __WASI_FDFLAGS_APPEND +#define O_CLOEXEC (0) +#define O_CREAT (__WASI_OFLAGS_CREAT << 12) +#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) +#define O_DSYNC __WASI_FDFLAGS_DSYNC +#define O_EXCL (__WASI_OFLAGS_EXCL << 12) +#define O_EXEC (0x02000000) +#define O_NOCTTY (0) +#define O_NOFOLLOW (0x01000000) +#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK +#define O_RDONLY (0x04000000) +#define O_RDWR (O_RDONLY | O_WRONLY) +#define O_RSYNC __WASI_FDFLAGS_RSYNC +#define O_SEARCH (0x08000000) +#define O_SYNC __WASI_FDFLAGS_SYNC +#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) +#define O_TTY_INIT (0) +#define O_WRONLY (0x10000000) +#define PACKETSZ NS_PACKETSZ +#define PACKET_ADD_MEMBERSHIP 1 +#define PACKET_AUXDATA 8 +#define PACKET_BROADCAST 1 +#define PACKET_COPY_THRESH 7 +#define PACKET_DROP_MEMBERSHIP 2 +#define PACKET_FANOUT 18 +#define PACKET_FANOUT_DATA 22 +#define PACKET_FASTROUTE 6 +#define PACKET_HDRLEN 11 +#define PACKET_HOST 0 +#define PACKET_IGNORE_OUTGOING 23 +#define PACKET_LOOPBACK 5 +#define PACKET_LOSS 14 +#define PACKET_MR_ALLMULTI 2 +#define PACKET_MR_MULTICAST 0 +#define PACKET_MR_PROMISC 1 +#define PACKET_MR_UNICAST 3 +#define PACKET_MULTICAST 2 +#define PACKET_ORIGDEV 9 +#define PACKET_OTHERHOST 3 +#define PACKET_OUTGOING 4 +#define PACKET_QDISC_BYPASS 20 +#define PACKET_RECV_OUTPUT 3 +#define PACKET_RESERVE 12 +#define PACKET_ROLLOVER_STATS 21 +#define PACKET_RX_RING 5 +#define PACKET_STATISTICS 6 +#define PACKET_TIMESTAMP 17 +#define PACKET_TX_HAS_OFF 19 +#define PACKET_TX_RING 13 +#define PACKET_TX_TIMESTAMP 16 +#define PACKET_VERSION 10 +#define PACKET_VNET_HDR 15 +#define PAGESIZE (0x10000) +#define PAGE_SIZE PAGESIZE +#define PATH_MAX 4096 +#define PDP_ENDIAN __PDP_ENDIAN +#define PF_INET 1 +#define PF_INET6 2 +#define PF_UNSPEC 0 +#define PM_STR 0x20027 +#define POLLERR 0x1000 +#define POLLHUP 0x2000 +#define POLLIN POLLRDNORM +#define POLLNVAL 0x4000 +#define POLLOUT POLLWRNORM +#define POLLRDNORM 0x1 +#define POLLWRNORM 0x2 +#define POSIX_CLOSE_RESTART 0 +#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED +#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE +#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL +#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM +#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL +#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED +#define PRELIM 1 +#define PRIX16 __UINT16_FMTX__ +#define PRIX32 __UINT32_FMTX__ +#define PRIX64 __UINT64_FMTX__ +#define PRIX8 __UINT8_FMTX__ +#define PRIXFAST16 __UINT_FAST16_FMTX__ +#define PRIXFAST32 __UINT_FAST32_FMTX__ +#define PRIXFAST64 __UINT_FAST64_FMTX__ +#define PRIXFAST8 __UINT_FAST8_FMTX__ +#define PRIXLEAST16 __UINT_LEAST16_FMTX__ +#define PRIXLEAST32 __UINT_LEAST32_FMTX__ +#define PRIXLEAST64 __UINT_LEAST64_FMTX__ +#define PRIXLEAST8 __UINT_LEAST8_FMTX__ +#define PRIXMAX __UINTMAX_FMTX__ +#define PRIXPTR __UINTPTR_FMTX__ +#define PRId16 __INT16_FMTd__ +#define PRId32 __INT32_FMTd__ +#define PRId64 __INT64_FMTd__ +#define PRId8 __INT8_FMTd__ +#define PRIdFAST16 __INT_FAST16_FMTd__ +#define PRIdFAST32 __INT_FAST32_FMTd__ +#define PRIdFAST64 __INT_FAST64_FMTd__ +#define PRIdFAST8 __INT_FAST8_FMTd__ +#define PRIdLEAST16 __INT_LEAST16_FMTd__ +#define PRIdLEAST32 __INT_LEAST32_FMTd__ +#define PRIdLEAST64 __INT_LEAST64_FMTd__ +#define PRIdLEAST8 __INT_LEAST8_FMTd__ +#define PRIdMAX __INTMAX_FMTd__ +#define PRIdPTR __INTPTR_FMTd__ +#define PRIi16 __INT16_FMTi__ +#define PRIi32 __INT32_FMTi__ +#define PRIi64 __INT64_FMTi__ +#define PRIi8 __INT8_FMTi__ +#define PRIiFAST16 __INT_FAST16_FMTi__ +#define PRIiFAST32 __INT_FAST32_FMTi__ +#define PRIiFAST64 __INT_FAST64_FMTi__ +#define PRIiFAST8 __INT_FAST8_FMTi__ +#define PRIiLEAST16 __INT_LEAST16_FMTi__ +#define PRIiLEAST32 __INT_LEAST32_FMTi__ +#define PRIiLEAST64 __INT_LEAST64_FMTi__ +#define PRIiLEAST8 __INT_LEAST8_FMTi__ +#define PRIiMAX __INTMAX_FMTi__ +#define PRIiPTR __INTPTR_FMTi__ +#define PRIo16 __UINT16_FMTo__ +#define PRIo32 __UINT32_FMTo__ +#define PRIo64 __UINT64_FMTo__ +#define PRIo8 __UINT8_FMTo__ +#define PRIoFAST16 __UINT_FAST16_FMTo__ +#define PRIoFAST32 __UINT_FAST32_FMTo__ +#define PRIoFAST64 __UINT_FAST64_FMTo__ +#define PRIoFAST8 __UINT_FAST8_FMTo__ +#define PRIoLEAST16 __UINT_LEAST16_FMTo__ +#define PRIoLEAST32 __UINT_LEAST32_FMTo__ +#define PRIoLEAST64 __UINT_LEAST64_FMTo__ +#define PRIoLEAST8 __UINT_LEAST8_FMTo__ +#define PRIoMAX __UINTMAX_FMTo__ +#define PRIoPTR __UINTPTR_FMTo__ +#define PRIu16 __UINT16_FMTu__ +#define PRIu32 __UINT32_FMTu__ +#define PRIu64 __UINT64_FMTu__ +#define PRIu8 __UINT8_FMTu__ +#define PRIuFAST16 __UINT_FAST16_FMTu__ +#define PRIuFAST32 __UINT_FAST32_FMTu__ +#define PRIuFAST64 __UINT_FAST64_FMTu__ +#define PRIuFAST8 __UINT_FAST8_FMTu__ +#define PRIuLEAST16 __UINT_LEAST16_FMTu__ +#define PRIuLEAST32 __UINT_LEAST32_FMTu__ +#define PRIuLEAST64 __UINT_LEAST64_FMTu__ +#define PRIuLEAST8 __UINT_LEAST8_FMTu__ +#define PRIuMAX __UINTMAX_FMTu__ +#define PRIuPTR __UINTPTR_FMTu__ +#define PRIx16 __UINT16_FMTx__ +#define PRIx32 __UINT32_FMTx__ +#define PRIx64 __UINT64_FMTx__ +#define PRIx8 __UINT8_FMTx__ +#define PRIxFAST16 __UINT_FAST16_FMTx__ +#define PRIxFAST32 __UINT_FAST32_FMTx__ +#define PRIxFAST64 __UINT_FAST64_FMTx__ +#define PRIxFAST8 __UINT_FAST8_FMTx__ +#define PRIxLEAST16 __UINT_LEAST16_FMTx__ +#define PRIxLEAST32 __UINT_LEAST32_FMTx__ +#define PRIxLEAST64 __UINT_LEAST64_FMTx__ +#define PRIxLEAST8 __UINT_LEAST8_FMTx__ +#define PRIxMAX __UINTMAX_FMTx__ +#define PRIxPTR __UINTPTR_FMTx__ +#define PTRBITS (sizeof(char *) * 8) +#define PTRDIFF_MAX INT32_MAX +#define PTRDIFF_MIN INT32_MIN +#define PUTLONG NS_PUT32 +#define PUTSHORT NS_PUT16 +#define QFIXEDSZ NS_QFIXEDSZ +#define QUERY ns_o_query +#define RADIXCHAR 0x10000 +#define RAND_MAX (0x7fffffff) +#define REC_EOF '\002' +#define REC_EOR '\001' +#define REC_ESC '\377' +#define REFUSED ns_r_refused +#define REGTYPE '0' +#define REG_BADBR 10 +#define REG_BADPAT 2 +#define REG_BADRPT 13 +#define REG_EBRACE 9 +#define REG_EBRACK 7 +#define REG_ECOLLATE 3 +#define REG_ECTYPE 4 +#define REG_EESCAPE 5 +#define REG_ENOSYS -1 +#define REG_EPAREN 8 +#define REG_ERANGE 11 +#define REG_ESPACE 12 +#define REG_ESUBREG 6 +#define REG_EXTENDED 1 +#define REG_ICASE 2 +#define REG_NEWLINE 4 +#define REG_NOMATCH 1 +#define REG_NOSUB 8 +#define REG_NOTBOL 1 +#define REG_NOTEOL 2 +#define REG_OK 0 +#define RE_DUP_MAX 255 +#define RMSGD 0x0001 +#define RMSGN 0x0002 +#define RNORM 0x0000 +#define RPM_PCO_ADD 1 +#define RPM_PCO_CHANGE 2 +#define RPM_PCO_SETGLOBAL 3 +#define RPROTDAT 0x0004 +#define RPROTDIS 0x0008 +#define RPROTMASK 0x001C +#define RPROTNORM 0x0010 +#define RRFIXEDSZ NS_RRFIXEDSZ +#define RRQ 01 +#define RS_HIPRI 0x01 +#define RTLD_DEFAULT ((void *)0) +#define RTLD_GLOBAL 256 +#define RTLD_LAZY 1 +#define RTLD_LOCAL 8 +#define RTLD_NEXT ((void *)-1) +#define RTLD_NODELETE 4096 +#define RTLD_NOLOAD 4 +#define RTLD_NOW 2 +#define RUSAGE_CHILDREN 2 +#define RUSAGE_SELF 1 +#define R_OK (4) +#define SARMAG 8 +#define SB 250 +#define SCHAR_MAX 127 +#define SCHAR_MIN (-128) +#define SCNd16 __INT16_FMTd__ +#define SCNd32 __INT32_FMTd__ +#define SCNd64 __INT64_FMTd__ +#define SCNd8 __INT8_FMTd__ +#define SCNdFAST16 __INT_FAST16_FMTd__ +#define SCNdFAST32 __INT_FAST32_FMTd__ +#define SCNdFAST64 __INT_FAST64_FMTd__ +#define SCNdFAST8 __INT_FAST8_FMTd__ +#define SCNdLEAST16 __INT_LEAST16_FMTd__ +#define SCNdLEAST32 __INT_LEAST32_FMTd__ +#define SCNdLEAST64 __INT_LEAST64_FMTd__ +#define SCNdLEAST8 __INT_LEAST8_FMTd__ +#define SCNdMAX __INTMAX_FMTd__ +#define SCNdPTR __INTPTR_FMTd__ +#define SCNi16 __INT16_FMTi__ +#define SCNi32 __INT32_FMTi__ +#define SCNi64 __INT64_FMTi__ +#define SCNi8 __INT8_FMTi__ +#define SCNiFAST16 __INT_FAST16_FMTi__ +#define SCNiFAST32 __INT_FAST32_FMTi__ +#define SCNiFAST64 __INT_FAST64_FMTi__ +#define SCNiFAST8 __INT_FAST8_FMTi__ +#define SCNiLEAST16 __INT_LEAST16_FMTi__ +#define SCNiLEAST32 __INT_LEAST32_FMTi__ +#define SCNiLEAST64 __INT_LEAST64_FMTi__ +#define SCNiLEAST8 __INT_LEAST8_FMTi__ +#define SCNiMAX __INTMAX_FMTi__ +#define SCNiPTR __INTPTR_FMTi__ +#define SCNo16 __UINT16_FMTo__ +#define SCNo32 __UINT32_FMTo__ +#define SCNo64 __UINT64_FMTo__ +#define SCNo8 __UINT8_FMTo__ +#define SCNoFAST16 __UINT_FAST16_FMTo__ +#define SCNoFAST32 __UINT_FAST32_FMTo__ +#define SCNoFAST64 __UINT_FAST64_FMTo__ +#define SCNoFAST8 __UINT_FAST8_FMTo__ +#define SCNoLEAST16 __UINT_LEAST16_FMTo__ +#define SCNoLEAST32 __UINT_LEAST32_FMTo__ +#define SCNoLEAST64 __UINT_LEAST64_FMTo__ +#define SCNoLEAST8 __UINT_LEAST8_FMTo__ +#define SCNoMAX __UINTMAX_FMTo__ +#define SCNoPTR __UINTPTR_FMTo__ +#define SCNu16 __UINT16_FMTu__ +#define SCNu32 __UINT32_FMTu__ +#define SCNu64 __UINT64_FMTu__ +#define SCNu8 __UINT8_FMTu__ +#define SCNuFAST16 __UINT_FAST16_FMTu__ +#define SCNuFAST32 __UINT_FAST32_FMTu__ +#define SCNuFAST64 __UINT_FAST64_FMTu__ +#define SCNuFAST8 __UINT_FAST8_FMTu__ +#define SCNuLEAST16 __UINT_LEAST16_FMTu__ +#define SCNuLEAST32 __UINT_LEAST32_FMTu__ +#define SCNuLEAST64 __UINT_LEAST64_FMTu__ +#define SCNuLEAST8 __UINT_LEAST8_FMTu__ +#define SCNuMAX __UINTMAX_FMTu__ +#define SCNuPTR __UINTPTR_FMTu__ +#define SCNx16 __UINT16_FMTx__ +#define SCNx32 __UINT32_FMTx__ +#define SCNx64 __UINT64_FMTx__ +#define SCNx8 __UINT8_FMTx__ +#define SCNxFAST16 __UINT_FAST16_FMTx__ +#define SCNxFAST32 __UINT_FAST32_FMTx__ +#define SCNxFAST64 __UINT_FAST64_FMTx__ +#define SCNxFAST8 __UINT_FAST8_FMTx__ +#define SCNxLEAST16 __UINT_LEAST16_FMTx__ +#define SCNxLEAST32 __UINT_LEAST32_FMTx__ +#define SCNxLEAST64 __UINT_LEAST64_FMTx__ +#define SCNxLEAST8 __UINT_LEAST8_FMTx__ +#define SCNxMAX __UINTMAX_FMTx__ +#define SCNxPTR __UINTPTR_FMTx__ +#define SE 240 +#define SEEK_CUR __WASI_WHENCE_CUR +#define SEEK_END __WASI_WHENCE_END +#define SEEK_SET __WASI_WHENCE_SET +#define SEGSIZE 512 +#define SEM_FAILED ((sem_t *)0) +#define SERVFAIL ns_r_servfail +#define SHORTBITS (sizeof(short) * 8) +#define SHRT_MAX 0x7fff +#define SHRT_MIN (-1-0x7fff) +#define SHUT_RD __WASI_SDFLAGS_RD +#define SHUT_RDWR (SHUT_RD | SHUT_WR) +#define SHUT_WR __WASI_SDFLAGS_WR +#define SIG_ATOMIC_MAX INT32_MAX +#define SIG_ATOMIC_MIN INT32_MIN +#define SIZE_MAX UINT32_MAX +#define SI_LOAD_SHIFT 16 +#define SLC_ABORT 7 +#define SLC_ACK 0x80 +#define SLC_AO 4 +#define SLC_AYT 5 +#define SLC_BRK 2 +#define SLC_CANTCHANGE 1 +#define SLC_DEFAULT 3 +#define SLC_EC 10 +#define SLC_EL 11 +#define SLC_EOF 8 +#define SLC_EOR 6 +#define SLC_EW 12 +#define SLC_FLAGS 1 +#define SLC_FLUSHIN 0x40 +#define SLC_FLUSHOUT 0x20 +#define SLC_FORW1 17 +#define SLC_FORW2 18 +#define SLC_FUNC 0 +#define SLC_IP 3 +#define SLC_LEVELBITS 0x03 +#define SLC_LNEXT 14 +#define SLC_NAME(x) slc_names[x] +#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, +#define SLC_NAMES SLC_NAMELIST +#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) +#define SLC_NOSUPPORT 0 +#define SLC_RP 13 +#define SLC_SUSP 9 +#define SLC_SYNCH 1 +#define SLC_VALUE 2 +#define SLC_VARIABLE 2 +#define SLC_XOFF 16 +#define SLC_XON 15 +#define SNDPIPE 0x002 +#define SNDZERO 0x001 +#define SOCK_CLOEXEC (0x00002000) +#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM +#define SOCK_NONBLOCK (0x00004000) +#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM +#define SOL_SOCKET 0x7fffffff +#define SOL_TCP 6 +#define SOL_UDP 17 +#define SO_TYPE 3 +#define SSIZE_MAX LONG_MAX +#define STATUS ns_o_status +#define STA_CLK 0x8000 +#define STA_CLOCKERR 0x1000 +#define STA_DEL 0x0020 +#define STA_FLL 0x0008 +#define STA_FREQHOLD 0x0080 +#define STA_INS 0x0010 +#define STA_MODE 0x4000 +#define STA_NANO 0x2000 +#define STA_PLL 0x0001 +#define STA_PPSERROR 0x0800 +#define STA_PPSFREQ 0x0002 +#define STA_PPSJITTER 0x0200 +#define STA_PPSSIGNAL 0x0100 +#define STA_PPSTIME 0x0004 +#define STA_PPSWANDER 0x0400 +#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) +#define STA_UNSYNC 0x0040 +#define STDERR_FILENO 2 +#define STDIN_FILENO 0 +#define STDOUT_FILENO 1 +#define STRU_F 1 +#define STRU_P 3 +#define STRU_R 2 +#define SUN_LEN(s) (2+strlen((s)->sun_path)) +#define SUSP 237 +#define SYMLOOP_MAX 40 +#define SYMTYPE '2' +#define SYNCH 242 +#define S_ADDT ns_s_ar +#define S_BANDURG 0x0200 +#define S_ERROR 0x0010 +#define S_HANGUP 0x0020 +#define S_HIPRI 0x0002 +#define S_IEXEC S_IXUSR +#define S_IFBLK (0x6000) +#define S_IFCHR (0x2000) +#define S_IFDIR (0x4000) +#define S_IFIFO (0xc000) +#define S_IFLNK (0xa000) +#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) +#define S_IFREG (0x8000) +#define S_IFSOCK (0xc000) +#define S_INPUT 0x0001 +#define S_IREAD S_IRUSR +#define S_IRGRP (0x20) +#define S_IROTH (0x4) +#define S_IRUSR (0x100) +#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) +#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) +#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) +#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) +#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) +#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) +#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) +#define S_ISGID (0x400) +#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) +#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) +#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) +#define S_ISUID (0x800) +#define S_ISVTX (0x200) +#define S_IWGRP (0x10) +#define S_IWOTH (0x2) +#define S_IWRITE S_IWUSR +#define S_IWUSR (0x80) +#define S_IXGRP (0x8) +#define S_IXOTH (0x1) +#define S_IXUSR (0x40) +#define S_MSG 0x0008 +#define S_OUTPUT 0x0004 +#define S_PREREQ ns_s_pr +#define S_RDBAND 0x0080 +#define S_RDNORM 0x0040 +#define S_UPDATE ns_s_ud +#define S_WRBAND 0x0100 +#define S_WRNORM S_OUTPUT +#define S_ZONE ns_s_zn +#define TCPI_OPT_ECN 8 +#define TCPI_OPT_SACK 2 +#define TCPI_OPT_TIMESTAMPS 1 +#define TCPI_OPT_WSCALE 4 +#define TCPOLEN_MAXSEG 4 +#define TCPOLEN_SACK_PERMITTED 2 +#define TCPOLEN_TIMESTAMP 10 +#define TCPOLEN_WINDOW 3 +#define TCPOPT_EOL 0 +#define TCPOPT_MAXSEG 2 +#define TCPOPT_NOP 1 +#define TCPOPT_SACK 5 +#define TCPOPT_SACK_PERMITTED 4 +#define TCPOPT_TIMESTAMP 8 +#define TCPOPT_WINDOW 3 +#define TCP_CA_CWR 2 +#define TCP_CA_Disorder 1 +#define TCP_CA_Loss 4 +#define TCP_CA_Open 0 +#define TCP_CA_Recovery 3 +#define TCP_CC_INFO 26 +#define TCP_CLOSE 7 +#define TCP_CLOSE_WAIT 8 +#define TCP_CLOSING 11 +#define TCP_CM_INQ TCP_INQ +#define TCP_CONGESTION 13 +#define TCP_CORK 3 +#define TCP_DEFER_ACCEPT 9 +#define TCP_ENCAP_ESPINTCP 7 +#define TCP_ESTABLISHED 1 +#define TCP_FASTOPEN 23 +#define TCP_FASTOPEN_CONNECT 30 +#define TCP_FASTOPEN_KEY 33 +#define TCP_FASTOPEN_NO_COOKIE 34 +#define TCP_FIN_WAIT1 4 +#define TCP_FIN_WAIT2 5 +#define TCP_INFO 11 +#define TCP_INQ 36 +#define TCP_KEEPCNT 6 +#define TCP_KEEPIDLE 4 +#define TCP_KEEPINTVL 5 +#define TCP_LAST_ACK 9 +#define TCP_LINGER2 8 +#define TCP_LISTEN 10 +#define TCP_MAXSEG 2 +#define TCP_MD5SIG 14 +#define TCP_MD5SIG_EXT 32 +#define TCP_MD5SIG_FLAG_IFINDEX 0x2 +#define TCP_MD5SIG_FLAG_PREFIX 0x1 +#define TCP_MD5SIG_MAXKEYLEN 80 +#define TCP_NODELAY 1 +#define TCP_NOTSENT_LOWAT 25 +#define TCP_QUEUE_SEQ 21 +#define TCP_QUICKACK 12 +#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 +#define TCP_REPAIR 19 +#define TCP_REPAIR_OFF 0 +#define TCP_REPAIR_OFF_NO_WP -1 +#define TCP_REPAIR_ON 1 +#define TCP_REPAIR_OPTIONS 22 +#define TCP_REPAIR_QUEUE 20 +#define TCP_REPAIR_WINDOW 29 +#define TCP_SAVED_SYN 28 +#define TCP_SAVE_SYN 27 +#define TCP_SYNCNT 7 +#define TCP_SYN_RECV 3 +#define TCP_SYN_SENT 2 +#define TCP_THIN_DUPACK 17 +#define TCP_THIN_LINEAR_TIMEOUTS 16 +#define TCP_TIMESTAMP 24 +#define TCP_TIME_WAIT 6 +#define TCP_TX_DELAY 37 +#define TCP_ULP 31 +#define TCP_USER_TIMEOUT 18 +#define TCP_WINDOW_CLAMP 10 +#define TCP_ZEROCOPY_RECEIVE 35 +#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] +#define TELCMD_FIRST xEOF +#define TELCMD_LAST IAC +#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) +#define TELOPT_3270REGIME 29 +#define TELOPT_AUTHENTICATION 37 +#define TELOPT_BINARY 0 +#define TELOPT_BM 19 +#define TELOPT_DET 20 +#define TELOPT_ECHO 1 +#define TELOPT_ENCRYPT 38 +#define TELOPT_EOR 25 +#define TELOPT_EXOPL 255 +#define TELOPT_LFLOW 33 +#define TELOPT_LINEMODE 34 +#define TELOPT_LOGOUT 18 +#define TELOPT_NAMS 4 +#define TELOPT_NAOCRD 10 +#define TELOPT_NAOFFD 13 +#define TELOPT_NAOHTD 12 +#define TELOPT_NAOHTS 11 +#define TELOPT_NAOL 8 +#define TELOPT_NAOLFD 16 +#define TELOPT_NAOP 9 +#define TELOPT_NAOVTD 15 +#define TELOPT_NAOVTS 14 +#define TELOPT_NAWS 31 +#define TELOPT_NEW_ENVIRON 39 +#define TELOPT_OLD_ENVIRON 36 +#define TELOPT_OUTMRK 27 +#define TELOPT_RCP 2 +#define TELOPT_RCTE 7 +#define TELOPT_SGA 3 +#define TELOPT_SNDLOC 23 +#define TELOPT_STATUS 5 +#define TELOPT_SUPDUP 21 +#define TELOPT_SUPDUPOUTPUT 22 +#define TELOPT_TM 6 +#define TELOPT_TSPEED 32 +#define TELOPT_TTYLOC 28 +#define TELOPT_TTYPE 24 +#define TELOPT_TUID 26 +#define TELOPT_X3PAD 30 +#define TELOPT_XASCII 17 +#define TELOPT_XDISPLOC 35 +#define TELQUAL_INFO 2 +#define TELQUAL_IS 0 +#define TELQUAL_NAME 3 +#define TELQUAL_REPLY 2 +#define TELQUAL_SEND 1 +#define TGEXEC 00010 +#define TGREAD 00040 +#define TGWRITE 00020 +#define THOUSEP 0x10001 +#define TH_ACK 0x10 +#define TH_FIN 0x01 +#define TH_PUSH 0x08 +#define TH_RST 0x04 +#define TH_SYN 0x02 +#define TH_URG 0x20 +#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME +#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) +#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) +#define TIME_BAD TIME_ERROR +#define TIME_DEL 2 +#define TIME_ERROR 5 +#define TIME_INS 1 +#define TIME_OK 0 +#define TIME_OOP 3 +#define TIME_UTC 1 +#define TIME_WAIT 4 +#define TMAGIC "ustar" +#define TMAGLEN 6 +#define TOEXEC 00001 +#define TOREAD 00004 +#define TOWRITE 00002 +#define TRANSIENT 4 +#define TSGID 02000 +#define TSS_DTOR_ITERATIONS 4 +#define TSUID 04000 +#define TSVTX 01000 +#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) +#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) +#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) +#define TTYDEF_SPEED (B9600) +#define TTY_NAME_MAX 32 +#define TUEXEC 00100 +#define TUREAD 00400 +#define TUWRITE 00200 +#define TVERSION "00" +#define TVERSLEN 2 +#define TYPE_A 1 +#define TYPE_E 2 +#define TYPE_I 3 +#define TYPE_L 4 +#define TZNAME_MAX 6 +#define T_A ns_t_a +#define T_A6 ns_t_a6 +#define T_AAAA ns_t_aaaa +#define T_AFSDB ns_t_afsdb +#define T_ANY ns_t_any +#define T_ATMA ns_t_atma +#define T_AXFR ns_t_axfr +#define T_CNAME ns_t_cname +#define T_DNAME ns_t_dname +#define T_EID ns_t_eid +#define T_FMT 0x2002A +#define T_FMT_AMPM 0x2002B +#define T_GPOS ns_t_gpos +#define T_HINFO ns_t_hinfo +#define T_ISDN ns_t_isdn +#define T_IXFR ns_t_ixfr +#define T_KEY ns_t_key +#define T_LOC ns_t_loc +#define T_MAILA ns_t_maila +#define T_MAILB ns_t_mailb +#define T_MB ns_t_mb +#define T_MD ns_t_md +#define T_MF ns_t_mf +#define T_MG ns_t_mg +#define T_MINFO ns_t_minfo +#define T_MR ns_t_mr +#define T_MX ns_t_mx +#define T_NAPTR ns_t_naptr +#define T_NIMLOC ns_t_nimloc +#define T_NS ns_t_ns +#define T_NSAP ns_t_nsap +#define T_NSAP_PTR ns_t_nsap_ptr +#define T_NULL ns_t_null +#define T_NXT ns_t_nxt +#define T_PTR ns_t_ptr +#define T_PX ns_t_px +#define T_RP ns_t_rp +#define T_RT ns_t_rt +#define T_SIG ns_t_sig +#define T_SOA ns_t_soa +#define T_SRV ns_t_srv +#define T_TSIG ns_t_tsig +#define T_TXT ns_t_txt +#define T_WKS ns_t_wks +#define T_X25 ns_t_x25 +#define UCHAR_MAX 255 +#define UDP_CORK 1 +#define UDP_ENCAP 100 +#define UDP_ENCAP_ESPINUDP 2 +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 +#define UDP_ENCAP_GTP0 4 +#define UDP_ENCAP_GTP1U 5 +#define UDP_ENCAP_L2TPINUDP 3 +#define UDP_ENCAP_RXRPC 6 +#define UDP_GRO 104 +#define UDP_NO_CHECK6_RX 102 +#define UDP_NO_CHECK6_TX 101 +#define UDP_SEGMENT 103 +#define UINT16_C(c) c +#define UINT16_MAX (0xffff) +#define UINT32_C(c) c ## U +#define UINT32_MAX (0xffffffffu) +#define UINT64_C(c) c ## ULL +#define UINT64_MAX (0xffffffffffffffffu) +#define UINT8_C(c) c +#define UINT8_MAX (0xff) +#define UINTMAX_C(c) c ## ULL +#define UINTMAX_MAX UINT64_MAX +#define UINTPTR_MAX UINT32_MAX +#define UINT_FAST16_MAX UINT16_MAX +#define UINT_FAST32_MAX UINT32_MAX +#define UINT_FAST64_MAX UINT64_MAX +#define UINT_FAST8_MAX UINT8_MAX +#define UINT_LEAST16_MAX UINT16_MAX +#define UINT_LEAST32_MAX UINT32_MAX +#define UINT_LEAST64_MAX UINT64_MAX +#define UINT_LEAST8_MAX UINT8_MAX +#define UINT_MAX 0xffffffffU +#define UIO_MAXIOV 1024 +#define ULLONG_MAX (2ULL*LLONG_MAX+1) +#define ULONG_MAX (2UL*LONG_MAX+1) +#define USHRT_MAX 0xffff +#define UTIME_NOW (-1) +#define UTIME_OMIT (-2) +#define WCHAR_MAX (0x7fffffff+L'\0') +#define WCHAR_MIN (-1-0x7fffffff+L'\0') +#define WEOF 0xffffffffU +#define WILL 251 +#define WINT_MAX UINT32_MAX +#define WINT_MIN 0U +#define WONT 252 +#define WORD_BIT 32 +#define WRQ 02 +#define W_OK (2) +#define X_OK (1) +#define YESEXPR 0x50000 +#define YESSTR 0x50002 +#define YXDOMAIN ns_r_yxdomain +#define YXRRSET ns_r_yxrrset +#define _ALLOCA_H +#define _ALL_SOURCE 1 +#define _ARPA_FTP_H +#define _ARPA_INET_H +#define _ARPA_NAMESER_H +#define _ARPA_TELNET_H +#define _ARPA_TFTP_H +#define _AR_H +#define _BYTESWAP_H +#define _COMPLEX_H +#define _CPIO_H +#define _CRYPT_H +#define _CS_GNU_LIBC_VERSION 2 +#define _CS_GNU_LIBPTHREAD_VERSION 3 +#define _CS_PATH 0 +#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 +#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 +#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 +#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 +#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 +#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 +#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 +#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 +#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 +#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 +#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 +#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 +#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 +#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 +#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 +#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 +#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 +#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 +#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 +#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 +#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 +#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 +#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 +#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 +#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 +#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 +#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 +#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 +#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 +#define _CS_V6_ENV 1148 +#define _CS_V7_ENV 1149 +#define _CTYPE_H +#define _Complex_I (0.0f+1.0fi) +#define _DIRENT_H +#define _DIRENT_HAVE_D_TYPE +#define _DLFCN_H +#define _ENDIAN_H +#define _ERRNO_H +#define _ERR_H +#define _FCNTL_H +#define _FEATURES_H +#define _FENV_H +#define _FLOAT_H +#define _FMTMSG_H +#define _FNMATCH_H +#define _FTW_H +#define _GETOPT_H +#define _GLOB_H +#define _GNU_SOURCE 1 +#define _ICONV_H +#define _IFADDRS_H +#define _INTTYPES_H +#define _IOFBF 0 +#define _IOLBF 1 +#define _IONBF 2 +#define _ISO646_H +#define _LANGINFO_H +#define _LIBGEN_H +#define _LIMITS_H +#define _LOCALE_H +#define _LP64 1 +#define _MALLOC_H +#define _MATH_H +#define _MONETARY_H +#define _MQUEUE_H +#define _NETINET_ICMP6_H +#define _NETINET_IGMP_H +#define _NETINET_IN_H +#define _NETINET_IN_SYSTM_H +#define _NETINET_IP6_H +#define _NETINET_IP_H +#define _NETINET_IP_ICMP_H +#define _NETINET_TCP_H +#define _NETINET_UDP_H +#define _NETPACKET_PACKET_H +#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) +#define _NL_TYPES_H +#define _PC_2_SYMLINKS 20 +#define _PC_ALLOC_SIZE_MIN 18 +#define _PC_ASYNC_IO 10 +#define _PC_CHOWN_RESTRICTED 6 +#define _PC_FILESIZEBITS 13 +#define _PC_LINK_MAX 0 +#define _PC_MAX_CANON 1 +#define _PC_MAX_INPUT 2 +#define _PC_NAME_MAX 3 +#define _PC_NO_TRUNC 7 +#define _PC_PATH_MAX 4 +#define _PC_PIPE_BUF 5 +#define _PC_PRIO_IO 11 +#define _PC_REC_INCR_XFER_SIZE 14 +#define _PC_REC_MAX_XFER_SIZE 15 +#define _PC_REC_MIN_XFER_SIZE 16 +#define _PC_REC_XFER_ALIGN 17 +#define _PC_SOCK_MAXBUF 12 +#define _PC_SYMLINK_MAX 19 +#define _PC_SYNC_IO 9 +#define _PC_VDISABLE 8 +#define _POLL_H +#define _POSIX2_BC_BASE_MAX 99 +#define _POSIX2_BC_DIM_MAX 2048 +#define _POSIX2_BC_SCALE_MAX 99 +#define _POSIX2_BC_STRING_MAX 1000 +#define _POSIX2_CHARCLASS_NAME_MAX 14 +#define _POSIX2_COLL_WEIGHTS_MAX 2 +#define _POSIX2_C_BIND _POSIX_VERSION +#define _POSIX2_EXPR_NEST_MAX 32 +#define _POSIX2_LINE_MAX 2048 +#define _POSIX2_RE_DUP_MAX 255 +#define _POSIX2_VERSION _POSIX_VERSION +#define _POSIX_ADVISORY_INFO _POSIX_VERSION +#define _POSIX_AIO_LISTIO_MAX 2 +#define _POSIX_AIO_MAX 1 +#define _POSIX_ARG_MAX 4096 +#define _POSIX_BARRIERS _POSIX_VERSION +#define _POSIX_CHILD_MAX 25 +#define _POSIX_CHOWN_RESTRICTED 1 +#define _POSIX_CLOCKRES_MIN 20000000 +#define _POSIX_CLOCK_SELECTION _POSIX_VERSION +#define _POSIX_CPUTIME _POSIX_VERSION +#define _POSIX_DELAYTIMER_MAX 32 +#define _POSIX_FSYNC _POSIX_VERSION +#define _POSIX_HOST_NAME_MAX 255 +#define _POSIX_IPV6 _POSIX_VERSION +#define _POSIX_LINK_MAX 8 +#define _POSIX_LOGIN_NAME_MAX 9 +#define _POSIX_MAX_CANON 255 +#define _POSIX_MAX_INPUT 255 +#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION +#define _POSIX_MQ_OPEN_MAX 8 +#define _POSIX_MQ_PRIO_MAX 32 +#define _POSIX_NAME_MAX 14 +#define _POSIX_NGROUPS_MAX 8 +#define _POSIX_NO_TRUNC 1 +#define _POSIX_OPEN_MAX 20 +#define _POSIX_PATH_MAX 256 +#define _POSIX_PIPE_BUF 512 +#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION +#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION +#define _POSIX_REGEXP 1 +#define _POSIX_RE_DUP_MAX 255 +#define _POSIX_RTSIG_MAX 8 +#define _POSIX_SEM_NSEMS_MAX 256 +#define _POSIX_SEM_VALUE_MAX 32767 +#define _POSIX_SIGQUEUE_MAX 32 +#define _POSIX_SPIN_LOCKS _POSIX_VERSION +#define _POSIX_SSIZE_MAX 32767 +#define _POSIX_SS_REPL_MAX 4 +#define _POSIX_STREAM_MAX 8 +#define _POSIX_SYMLINK_MAX 255 +#define _POSIX_SYMLOOP_MAX 8 +#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION +#define _POSIX_THREAD_CPUTIME _POSIX_VERSION +#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 +#define _POSIX_THREAD_KEYS_MAX 128 +#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION +#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION +#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION +#define _POSIX_THREAD_THREADS_MAX 64 +#define _POSIX_TIMEOUTS _POSIX_VERSION +#define _POSIX_TIMERS _POSIX_VERSION +#define _POSIX_TIMER_MAX 32 +#define _POSIX_TRACE_EVENT_NAME_MAX 30 +#define _POSIX_TRACE_NAME_MAX 8 +#define _POSIX_TRACE_SYS_MAX 8 +#define _POSIX_TRACE_USER_EVENT_MAX 32 +#define _POSIX_TTY_NAME_MAX 9 +#define _POSIX_TZNAME_MAX 6 +#define _POSIX_V6_ILP32_OFFBIG (1) +#define _POSIX_V7_ILP32_OFFBIG (1) +#define _POSIX_VDISABLE 0 +#define _POSIX_VERSION 200809L +#define _PTRDIFF_T +#define _REGEX_H +#define _SCHED_H +#define _SC_2_CHAR_TERM 95 +#define _SC_2_C_BIND 47 +#define _SC_2_C_DEV 48 +#define _SC_2_FORT_DEV 49 +#define _SC_2_FORT_RUN 50 +#define _SC_2_LOCALEDEF 52 +#define _SC_2_PBS 168 +#define _SC_2_PBS_ACCOUNTING 169 +#define _SC_2_PBS_CHECKPOINT 175 +#define _SC_2_PBS_LOCATE 170 +#define _SC_2_PBS_MESSAGE 171 +#define _SC_2_PBS_TRACK 172 +#define _SC_2_SW_DEV 51 +#define _SC_2_UPE 97 +#define _SC_2_VERSION 46 +#define _SC_ADVISORY_INFO 132 +#define _SC_AIO_LISTIO_MAX 23 +#define _SC_AIO_MAX 24 +#define _SC_AIO_PRIO_DELTA_MAX 25 +#define _SC_ARG_MAX 0 +#define _SC_ASYNCHRONOUS_IO 12 +#define _SC_ATEXIT_MAX 87 +#define _SC_AVPHYS_PAGES 86 +#define _SC_BARRIERS 133 +#define _SC_BC_BASE_MAX 36 +#define _SC_BC_DIM_MAX 37 +#define _SC_BC_SCALE_MAX 38 +#define _SC_BC_STRING_MAX 39 +#define _SC_CHILD_MAX 1 +#define _SC_CLK_TCK 2 +#define _SC_CLOCK_SELECTION 137 +#define _SC_COLL_WEIGHTS_MAX 40 +#define _SC_CPUTIME 138 +#define _SC_DELAYTIMER_MAX 26 +#define _SC_EXPR_NEST_MAX 42 +#define _SC_FSYNC 15 +#define _SC_GETGR_R_SIZE_MAX 69 +#define _SC_GETPW_R_SIZE_MAX 70 +#define _SC_HOST_NAME_MAX 180 +#define _SC_IOV_MAX 60 +#define _SC_IPV6 235 +#define _SC_JOB_CONTROL 7 +#define _SC_LINE_MAX 43 +#define _SC_LOGIN_NAME_MAX 71 +#define _SC_MAPPED_FILES 16 +#define _SC_MEMLOCK 17 +#define _SC_MEMLOCK_RANGE 18 +#define _SC_MEMORY_PROTECTION 19 +#define _SC_MESSAGE_PASSING 20 +#define _SC_MONOTONIC_CLOCK 149 +#define _SC_MQ_OPEN_MAX 27 +#define _SC_MQ_PRIO_MAX 28 +#define _SC_NGROUPS_MAX 3 +#define _SC_NPROCESSORS_CONF 83 +#define _SC_NPROCESSORS_ONLN 84 +#define _SC_NZERO 109 +#define _SC_OPEN_MAX 4 +#define _SC_PAGESIZE 30 +#define _SC_PAGE_SIZE 30 +#define _SC_PASS_MAX 88 +#define _SC_PHYS_PAGES 85 +#define _SC_PRIORITIZED_IO 13 +#define _SC_PRIORITY_SCHEDULING 10 +#define _SC_RAW_SOCKETS 236 +#define _SC_READER_WRITER_LOCKS 153 +#define _SC_REALTIME_SIGNALS 9 +#define _SC_REGEXP 155 +#define _SC_RE_DUP_MAX 44 +#define _SC_RTSIG_MAX 31 +#define _SC_SAVED_IDS 8 +#define _SC_SEMAPHORES 21 +#define _SC_SEM_NSEMS_MAX 32 +#define _SC_SEM_VALUE_MAX 33 +#define _SC_SHARED_MEMORY_OBJECTS 22 +#define _SC_SHELL 157 +#define _SC_SIGQUEUE_MAX 34 +#define _SC_SPAWN 159 +#define _SC_SPIN_LOCKS 154 +#define _SC_SPORADIC_SERVER 160 +#define _SC_SS_REPL_MAX 241 +#define _SC_STREAMS 174 +#define _SC_STREAM_MAX 5 +#define _SC_SYMLOOP_MAX 173 +#define _SC_SYNCHRONIZED_IO 14 +#define _SC_THREADS 67 +#define _SC_THREAD_ATTR_STACKADDR 77 +#define _SC_THREAD_ATTR_STACKSIZE 78 +#define _SC_THREAD_CPUTIME 139 +#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 +#define _SC_THREAD_KEYS_MAX 74 +#define _SC_THREAD_PRIORITY_SCHEDULING 79 +#define _SC_THREAD_PRIO_INHERIT 80 +#define _SC_THREAD_PRIO_PROTECT 81 +#define _SC_THREAD_PROCESS_SHARED 82 +#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 +#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 +#define _SC_THREAD_SAFE_FUNCTIONS 68 +#define _SC_THREAD_SPORADIC_SERVER 161 +#define _SC_THREAD_STACK_MIN 75 +#define _SC_THREAD_THREADS_MAX 76 +#define _SC_TIMEOUTS 164 +#define _SC_TIMERS 11 +#define _SC_TIMER_MAX 35 +#define _SC_TRACE 181 +#define _SC_TRACE_EVENT_FILTER 182 +#define _SC_TRACE_EVENT_NAME_MAX 242 +#define _SC_TRACE_INHERIT 183 +#define _SC_TRACE_LOG 184 +#define _SC_TRACE_NAME_MAX 243 +#define _SC_TRACE_SYS_MAX 244 +#define _SC_TRACE_USER_EVENT_MAX 245 +#define _SC_TTY_NAME_MAX 72 +#define _SC_TYPED_MEMORY_OBJECTS 165 +#define _SC_TZNAME_MAX 6 +#define _SC_UIO_MAXIOV 60 +#define _SC_V6_ILP32_OFF32 176 +#define _SC_V6_ILP32_OFFBIG 177 +#define _SC_V6_LP64_OFF64 178 +#define _SC_V6_LPBIG_OFFBIG 179 +#define _SC_V7_ILP32_OFF32 237 +#define _SC_V7_ILP32_OFFBIG 238 +#define _SC_V7_LP64_OFF64 239 +#define _SC_V7_LPBIG_OFFBIG 240 +#define _SC_VERSION 29 +#define _SC_XBS5_ILP32_OFF32 125 +#define _SC_XBS5_ILP32_OFFBIG 126 +#define _SC_XBS5_LP64_OFF64 127 +#define _SC_XBS5_LPBIG_OFFBIG 128 +#define _SC_XOPEN_CRYPT 92 +#define _SC_XOPEN_ENH_I18N 93 +#define _SC_XOPEN_LEGACY 129 +#define _SC_XOPEN_REALTIME 130 +#define _SC_XOPEN_REALTIME_THREADS 131 +#define _SC_XOPEN_SHM 94 +#define _SC_XOPEN_STREAMS 246 +#define _SC_XOPEN_UNIX 91 +#define _SC_XOPEN_VERSION 89 +#define _SC_XOPEN_XCU_VERSION 90 +#define _SC_XOPEN_XPG2 98 +#define _SC_XOPEN_XPG3 99 +#define _SC_XOPEN_XPG4 100 +#define _SEARCH_H +#define _SEMAPHORE_H +#define _SIZE_T +#define _STDALIGN_H +#define _STDBOOL_H +#define _STDC_PREDEF_H +#define _STDINT_H +#define _STDIO_EXT_H +#define _STDIO_H +#define _STDLIB_H +#define _STDNORETURN_H +#define _STRINGS_H +#define _STRING_H +#define _STROPTS_H +#define _SYSEXITS_H +#define _SYS_EVENTFD_H +#define _SYS_FILE_H +#define _SYS_IOCTL_H +#define _SYS_PARAM_H +#define _SYS_RANDOM_H +#define _SYS_REG_H +#define _SYS_SELECT_H +#define _SYS_SOCKET_H +#define _SYS_STAT_H +#define _SYS_SYSCALL_H +#define _SYS_SYSINFO_H +#define _SYS_TIMEB_H +#define _SYS_TIMEX_H +#define _SYS_TIME_H +#define _SYS_TTYDEFAULTS_H +#define _SYS_TYPES_H +#define _SYS_UIO_H +#define _SYS_UN_H +#define _SYS_UTSNAME_H +#define _TAR_H +#define _TGMATH_H +#define _THREADS_H +#define _TIME_H +#define _UCHAR_H +#define _UNISTD_H +#define _UTIME_H +#define _VALUES_H +#define _VA_LIST +#define _WCHAR_H +#define _WCHAR_T +#define _WCTYPE_H +#define _WINT_T +#define _XOPEN_ENH_I18N 1 +#define _XOPEN_IOV_MAX 16 +#define _XOPEN_NAME_MAX 255 +#define _XOPEN_PATH_MAX 1024 +#define _XOPEN_UNIX 1 +#define _XOPEN_VERSION 700 +#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) +#define __ATOMIC_ACQUIRE 2 +#define __ATOMIC_ACQ_REL 4 +#define __ATOMIC_CONSUME 1 +#define __ATOMIC_RELAXED 0 +#define __ATOMIC_RELEASE 3 +#define __ATOMIC_SEQ_CST 5 +#define __BIGGEST_ALIGNMENT__ 16 +#define __BIG_ENDIAN 4321 +#define __BIND 19950621 +#define __BYTE_ORDER __BYTE_ORDER__ +#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ +#define __CHAR16_TYPE__ unsigned short +#define __CHAR32_TYPE__ unsigned int +#define __CHAR_BIT__ 8 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __CLANG_MAX_ALIGN_T_DEFINED +#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) +#define __CONSTANT_CFSTRINGS__ 1 +#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) +#define __DBL_DECIMAL_DIG__ 17 +#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 +#define __DBL_DIG__ 15 +#define __DBL_EPSILON__ 2.2204460492503131e-16 +#define __DBL_HAS_DENORM__ 1 +#define __DBL_HAS_INFINITY__ 1 +#define __DBL_HAS_QUIET_NAN__ 1 +#define __DBL_MANT_DIG__ 53 +#define __DBL_MAX_10_EXP__ 308 +#define __DBL_MAX_EXP__ 1024 +#define __DBL_MAX__ 1.7976931348623157e+308 +#define __DBL_MIN_10_EXP__ (-307) +#define __DBL_MIN_EXP__ (-1021) +#define __DBL_MIN__ 2.2250738585072014e-308 +#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ +#define __DEFINED_FILE +#define __DEFINED___isoc_va_list +#define __DEFINED_blkcnt_t +#define __DEFINED_blksize_t +#define __DEFINED_clock_t +#define __DEFINED_clockid_t +#define __DEFINED_cnd_t +#define __DEFINED_dev_t +#define __DEFINED_double_t +#define __DEFINED_float_t +#define __DEFINED_fsblkcnt_t +#define __DEFINED_fsfilcnt_t +#define __DEFINED_gid_t +#define __DEFINED_id_t +#define __DEFINED_ino_t +#define __DEFINED_int16_t +#define __DEFINED_int32_t +#define __DEFINED_int64_t +#define __DEFINED_int8_t +#define __DEFINED_intmax_t +#define __DEFINED_intptr_t +#define __DEFINED_key_t +#define __DEFINED_locale_t +#define __DEFINED_mbstate_t +#define __DEFINED_mode_t +#define __DEFINED_mtx_t +#define __DEFINED_nlink_t +#define __DEFINED_off_t +#define __DEFINED_pid_t +#define __DEFINED_pthread_attr_t +#define __DEFINED_pthread_barrier_t +#define __DEFINED_pthread_barrierattr_t +#define __DEFINED_pthread_cond_t +#define __DEFINED_pthread_condattr_t +#define __DEFINED_pthread_key_t +#define __DEFINED_pthread_mutex_t +#define __DEFINED_pthread_mutexattr_t +#define __DEFINED_pthread_once_t +#define __DEFINED_pthread_rwlock_t +#define __DEFINED_pthread_rwlockattr_t +#define __DEFINED_pthread_spinlock_t +#define __DEFINED_pthread_t +#define __DEFINED_register_t +#define __DEFINED_regoff_t +#define __DEFINED_sa_family_t +#define __DEFINED_sigset_t +#define __DEFINED_size_t +#define __DEFINED_socklen_t +#define __DEFINED_ssize_t +#define __DEFINED_suseconds_t +#define __DEFINED_time_t +#define __DEFINED_timer_t +#define __DEFINED_u_int64_t +#define __DEFINED_uid_t +#define __DEFINED_uint16_t +#define __DEFINED_uint32_t +#define __DEFINED_uint64_t +#define __DEFINED_uint8_t +#define __DEFINED_uintmax_t +#define __DEFINED_uintptr_t +#define __DEFINED_useconds_t +#define __DEFINED_va_list +#define __DEFINED_wchar_t +#define __DEFINED_wctype_t +#define __DEFINED_wint_t +#define __FINITE_MATH_ONLY__ 0 +#define __FLOAT128__ 1 +#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) +#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) +#define __FLT_DECIMAL_DIG__ 9 +#define __FLT_DENORM_MIN__ 1.40129846e-45F +#define __FLT_DIG__ 6 +#define __FLT_EPSILON__ 1.19209290e-7F +#define __FLT_HAS_DENORM__ 1 +#define __FLT_HAS_INFINITY__ 1 +#define __FLT_HAS_QUIET_NAN__ 1 +#define __FLT_MANT_DIG__ 24 +#define __FLT_MAX_10_EXP__ 38 +#define __FLT_MAX_EXP__ 128 +#define __FLT_MAX__ 3.40282347e+38F +#define __FLT_MIN_10_EXP__ (-37) +#define __FLT_MIN_EXP__ (-125) +#define __FLT_MIN__ 1.17549435e-38F +#define __FLT_RADIX__ 2 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __GNUC_STDC_INLINE__ 1 +#define __GNUC_VA_LIST 1 +#define __GXX_ABI_VERSION 1002 +#define __INT16_C_SUFFIX__ +#define __INT16_FMTd__ "hd" +#define __INT16_FMTi__ "hi" +#define __INT16_MAX__ 32767 +#define __INT16_TYPE__ short +#define __INT32_C_SUFFIX__ +#define __INT32_FMTd__ "d" +#define __INT32_FMTi__ "i" +#define __INT32_MAX__ 2147483647 +#define __INT32_TYPE__ int +#define __INT64_C_SUFFIX__ LL +#define __INT64_FMTd__ "lld" +#define __INT64_FMTi__ "lli" +#define __INT64_MAX__ 9223372036854775807LL +#define __INT64_TYPE__ long long int +#define __INT8_C_SUFFIX__ +#define __INT8_FMTd__ "hhd" +#define __INT8_FMTi__ "hhi" +#define __INT8_MAX__ 127 +#define __INT8_TYPE__ signed char +#define __INTMAX_C_SUFFIX__ LL +#define __INTMAX_FMTd__ "lld" +#define __INTMAX_FMTi__ "lli" +#define __INTMAX_MAX__ 9223372036854775807LL +#define __INTMAX_TYPE__ long long int +#define __INTMAX_WIDTH__ 64 +#define __INTPTR_FMTd__ "ld" +#define __INTPTR_FMTi__ "li" +#define __INTPTR_MAX__ 9223372036854775807L +#define __INTPTR_TYPE__ long int +#define __INTPTR_WIDTH__ 64 +#define __INT_FAST16_FMTd__ "hd" +#define __INT_FAST16_FMTi__ "hi" +#define __INT_FAST16_MAX__ 32767 +#define __INT_FAST16_TYPE__ short +#define __INT_FAST32_FMTd__ "d" +#define __INT_FAST32_FMTi__ "i" +#define __INT_FAST32_MAX__ 2147483647 +#define __INT_FAST32_TYPE__ int +#define __INT_FAST64_FMTd__ "lld" +#define __INT_FAST64_FMTi__ "lli" +#define __INT_FAST64_MAX__ 9223372036854775807LL +#define __INT_FAST64_TYPE__ long long int +#define __INT_FAST8_FMTd__ "hhd" +#define __INT_FAST8_FMTi__ "hhi" +#define __INT_FAST8_MAX__ 127 +#define __INT_FAST8_TYPE__ signed char +#define __INT_LEAST16_FMTd__ "hd" +#define __INT_LEAST16_FMTi__ "hi" +#define __INT_LEAST16_MAX__ 32767 +#define __INT_LEAST16_TYPE__ short +#define __INT_LEAST32_FMTd__ "d" +#define __INT_LEAST32_FMTi__ "i" +#define __INT_LEAST32_MAX__ 2147483647 +#define __INT_LEAST32_TYPE__ int +#define __INT_LEAST64_FMTd__ "lld" +#define __INT_LEAST64_FMTi__ "lli" +#define __INT_LEAST64_MAX__ 9223372036854775807LL +#define __INT_LEAST64_TYPE__ long long int +#define __INT_LEAST8_FMTd__ "hhd" +#define __INT_LEAST8_FMTi__ "hhi" +#define __INT_LEAST8_MAX__ 127 +#define __INT_LEAST8_TYPE__ signed char +#define __INT_MAX__ 2147483647 +#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) +#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) +#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) +#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) +#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) +#define __LDBL_DECIMAL_DIG__ 36 +#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L +#define __LDBL_DIG__ 33 +#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L +#define __LDBL_HAS_DENORM__ 1 +#define __LDBL_HAS_INFINITY__ 1 +#define __LDBL_HAS_QUIET_NAN__ 1 +#define __LDBL_MANT_DIG__ 113 +#define __LDBL_MAX_10_EXP__ 4932 +#define __LDBL_MAX_EXP__ 16384 +#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L +#define __LDBL_MIN_10_EXP__ (-4931) +#define __LDBL_MIN_EXP__ (-16381) +#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L +#define __LITTLE_ENDIAN 1234 +#define __LITTLE_ENDIAN__ 1 +#define __LONG_LONG_MAX__ 9223372036854775807LL +#define __LONG_MAX __LONG_MAX__ +#define __LONG_MAX__ 9223372036854775807L +#define __LP64__ 1 +#define __NAMESER 19991006 +#define __NEED_FILE +#define __NEED___isoc_va_list +#define __NEED_blkcnt_t +#define __NEED_blksize_t +#define __NEED_clock_t +#define __NEED_clockid_t +#define __NEED_cnd_t +#define __NEED_dev_t +#define __NEED_double_t +#define __NEED_float_t +#define __NEED_fsblkcnt_t +#define __NEED_fsfilcnt_t +#define __NEED_gid_t +#define __NEED_id_t +#define __NEED_ino_t +#define __NEED_int16_t +#define __NEED_int32_t +#define __NEED_int64_t +#define __NEED_int8_t +#define __NEED_intmax_t +#define __NEED_intptr_t +#define __NEED_key_t +#define __NEED_locale_t +#define __NEED_mbstate_t +#define __NEED_mode_t +#define __NEED_mtx_t +#define __NEED_nlink_t +#define __NEED_off_t +#define __NEED_pid_t +#define __NEED_pthread_attr_t +#define __NEED_pthread_barrier_t +#define __NEED_pthread_barrierattr_t +#define __NEED_pthread_cond_t +#define __NEED_pthread_condattr_t +#define __NEED_pthread_key_t +#define __NEED_pthread_mutex_t +#define __NEED_pthread_mutexattr_t +#define __NEED_pthread_once_t +#define __NEED_pthread_rwlock_t +#define __NEED_pthread_rwlockattr_t +#define __NEED_pthread_spinlock_t +#define __NEED_pthread_t +#define __NEED_register_t +#define __NEED_regoff_t +#define __NEED_sa_family_t +#define __NEED_sigset_t +#define __NEED_size_t +#define __NEED_socklen_t +#define __NEED_ssize_t +#define __NEED_struct_iovec +#define __NEED_struct_timespec +#define __NEED_struct_timeval +#define __NEED_suseconds_t +#define __NEED_time_t +#define __NEED_timer_t +#define __NEED_u_int64_t +#define __NEED_uid_t +#define __NEED_uint16_t +#define __NEED_uint32_t +#define __NEED_uint64_t +#define __NEED_uint8_t +#define __NEED_uintmax_t +#define __NEED_uintptr_t +#define __NEED_useconds_t +#define __NEED_va_list +#define __NEED_wchar_t +#define __NEED_wctype_t +#define __NEED_wint_t +#define __OBJC_BOOL_IS_BOOL 0 +#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 +#define __OPENCL_MEMORY_SCOPE_DEVICE 2 +#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 +#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 +#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 +#define __ORDER_BIG_ENDIAN__ 4321 +#define __ORDER_LITTLE_ENDIAN__ 1234 +#define __ORDER_PDP_ENDIAN__ 3412 +#define __PDP_ENDIAN 3412 +#define __POINTER_WIDTH__ 64 +#define __PRAGMA_REDEFINE_EXTNAME 1 +#define __PTRDIFF_FMTd__ "ld" +#define __PTRDIFF_FMTi__ "li" +#define __PTRDIFF_MAX__ 9223372036854775807L +#define __PTRDIFF_TYPE__ long int +#define __PTRDIFF_WIDTH__ 64 +#define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#define __RETCAST(x) +#define __RETCAST_2(x,y) +#define __RETCAST_3(x,y,z) +#define __RETCAST_CX(x) +#define __RETCAST_REAL(x) +#define __SCHAR_MAX__ 127 +#define __SHRT_MAX__ 32767 +#define __SID ('S' << 8) +#define __SIG_ATOMIC_MAX__ 9223372036854775807L +#define __SIG_ATOMIC_WIDTH__ 64 +#define __SIZEOF_DOUBLE__ 8 +#define __SIZEOF_FLOAT__ 4 +#define __SIZEOF_INT128__ 16 +#define __SIZEOF_INT__ 4 +#define __SIZEOF_LONG_DOUBLE__ 16 +#define __SIZEOF_LONG_LONG__ 8 +#define __SIZEOF_LONG__ 8 +#define __SIZEOF_POINTER__ 8 +#define __SIZEOF_PTRDIFF_T__ 8 +#define __SIZEOF_SHORT__ 2 +#define __SIZEOF_SIZE_T__ 8 +#define __SIZEOF_WCHAR_T__ 4 +#define __SIZEOF_WINT_T__ 4 +#define __SIZE_FMTX__ "lX" +#define __SIZE_FMTo__ "lo" +#define __SIZE_FMTu__ "lu" +#define __SIZE_FMTx__ "lx" +#define __SIZE_MAX__ 18446744073709551615UL +#define __SIZE_TYPE__ long unsigned int +#define __SIZE_WIDTH__ 64 +#define __STDARG_H +#define __STDC_HOSTED__ 1 +#define __STDC_IEC_559__ 1 +#define __STDC_ISO_10646__ 201206L +#define __STDC_UTF_16__ 1 +#define __STDC_UTF_32__ 1 +#define __STDC_VERSION__ 201710L +#define __STDC__ 1 +#define __STDDEF_H +#define __UAPI_DEF_IN6_ADDR 0 +#define __UAPI_DEF_IN6_ADDR_ALT 0 +#define __UAPI_DEF_IN6_PKTINFO 0 +#define __UAPI_DEF_IN_ADDR 0 +#define __UAPI_DEF_IN_CLASS 0 +#define __UAPI_DEF_IN_IPPROTO 0 +#define __UAPI_DEF_IN_PKTINFO 0 +#define __UAPI_DEF_IP6_MTUINFO 0 +#define __UAPI_DEF_IPHDR 0 +#define __UAPI_DEF_IPPROTO_V6 0 +#define __UAPI_DEF_IPV6_MREQ 0 +#define __UAPI_DEF_IPV6_OPTIONS 0 +#define __UAPI_DEF_IP_MREQ 0 +#define __UAPI_DEF_SOCKADDR_IN 0 +#define __UAPI_DEF_SOCKADDR_IN6 0 +#define __UINT16_C_SUFFIX__ +#define __UINT16_FMTX__ "hX" +#define __UINT16_FMTo__ "ho" +#define __UINT16_FMTu__ "hu" +#define __UINT16_FMTx__ "hx" +#define __UINT16_MAX__ 65535 +#define __UINT16_TYPE__ unsigned short +#define __UINT32_C_SUFFIX__ U +#define __UINT32_FMTX__ "X" +#define __UINT32_FMTo__ "o" +#define __UINT32_FMTu__ "u" +#define __UINT32_FMTx__ "x" +#define __UINT32_MAX__ 4294967295U +#define __UINT32_TYPE__ unsigned int +#define __UINT64_C_SUFFIX__ ULL +#define __UINT64_FMTX__ "llX" +#define __UINT64_FMTo__ "llo" +#define __UINT64_FMTu__ "llu" +#define __UINT64_FMTx__ "llx" +#define __UINT64_MAX__ 18446744073709551615ULL +#define __UINT64_TYPE__ long long unsigned int +#define __UINT8_C_SUFFIX__ +#define __UINT8_FMTX__ "hhX" +#define __UINT8_FMTo__ "hho" +#define __UINT8_FMTu__ "hhu" +#define __UINT8_FMTx__ "hhx" +#define __UINT8_MAX__ 255 +#define __UINT8_TYPE__ unsigned char +#define __UINTMAX_C_SUFFIX__ ULL +#define __UINTMAX_FMTX__ "llX" +#define __UINTMAX_FMTo__ "llo" +#define __UINTMAX_FMTu__ "llu" +#define __UINTMAX_FMTx__ "llx" +#define __UINTMAX_MAX__ 18446744073709551615ULL +#define __UINTMAX_TYPE__ long long unsigned int +#define __UINTMAX_WIDTH__ 64 +#define __UINTPTR_FMTX__ "lX" +#define __UINTPTR_FMTo__ "lo" +#define __UINTPTR_FMTu__ "lu" +#define __UINTPTR_FMTx__ "lx" +#define __UINTPTR_MAX__ 18446744073709551615UL +#define __UINTPTR_TYPE__ long unsigned int +#define __UINTPTR_WIDTH__ 64 +#define __UINT_FAST16_FMTX__ "hX" +#define __UINT_FAST16_FMTo__ "ho" +#define __UINT_FAST16_FMTu__ "hu" +#define __UINT_FAST16_FMTx__ "hx" +#define __UINT_FAST16_MAX__ 65535 +#define __UINT_FAST16_TYPE__ unsigned short +#define __UINT_FAST32_FMTX__ "X" +#define __UINT_FAST32_FMTo__ "o" +#define __UINT_FAST32_FMTu__ "u" +#define __UINT_FAST32_FMTx__ "x" +#define __UINT_FAST32_MAX__ 4294967295U +#define __UINT_FAST32_TYPE__ unsigned int +#define __UINT_FAST64_FMTX__ "llX" +#define __UINT_FAST64_FMTo__ "llo" +#define __UINT_FAST64_FMTu__ "llu" +#define __UINT_FAST64_FMTx__ "llx" +#define __UINT_FAST64_MAX__ 18446744073709551615ULL +#define __UINT_FAST64_TYPE__ long long unsigned int +#define __UINT_FAST8_FMTX__ "hhX" +#define __UINT_FAST8_FMTo__ "hho" +#define __UINT_FAST8_FMTu__ "hhu" +#define __UINT_FAST8_FMTx__ "hhx" +#define __UINT_FAST8_MAX__ 255 +#define __UINT_FAST8_TYPE__ unsigned char +#define __UINT_LEAST16_FMTX__ "hX" +#define __UINT_LEAST16_FMTo__ "ho" +#define __UINT_LEAST16_FMTu__ "hu" +#define __UINT_LEAST16_FMTx__ "hx" +#define __UINT_LEAST16_MAX__ 65535 +#define __UINT_LEAST16_TYPE__ unsigned short +#define __UINT_LEAST32_FMTX__ "X" +#define __UINT_LEAST32_FMTo__ "o" +#define __UINT_LEAST32_FMTu__ "u" +#define __UINT_LEAST32_FMTx__ "x" +#define __UINT_LEAST32_MAX__ 4294967295U +#define __UINT_LEAST32_TYPE__ unsigned int +#define __UINT_LEAST64_FMTX__ "llX" +#define __UINT_LEAST64_FMTo__ "llo" +#define __UINT_LEAST64_FMTu__ "llu" +#define __UINT_LEAST64_FMTx__ "llx" +#define __UINT_LEAST64_MAX__ 18446744073709551615ULL +#define __UINT_LEAST64_TYPE__ long long unsigned int +#define __UINT_LEAST8_FMTX__ "hhX" +#define __UINT_LEAST8_FMTo__ "hho" +#define __UINT_LEAST8_FMTu__ "hhu" +#define __UINT_LEAST8_FMTx__ "hhx" +#define __UINT_LEAST8_MAX__ 255 +#define __UINT_LEAST8_TYPE__ unsigned char +#define __USER_LABEL_PREFIX__ +#define __USE_TIME_BITS64 1 +#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) +#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) +#define __WASI_ADVICE_NORMAL (UINT8_C(0)) +#define __WASI_ADVICE_RANDOM (UINT8_C(2)) +#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) +#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) +#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) +#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) +#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) +#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) +#define __WASI_DIRCOOKIE_START (UINT64_C(0)) +#define __WASI_ERRNO_2BIG (UINT16_C(1)) +#define __WASI_ERRNO_ACCES (UINT16_C(2)) +#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) +#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) +#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) +#define __WASI_ERRNO_AGAIN (UINT16_C(6)) +#define __WASI_ERRNO_ALREADY (UINT16_C(7)) +#define __WASI_ERRNO_BADF (UINT16_C(8)) +#define __WASI_ERRNO_BADMSG (UINT16_C(9)) +#define __WASI_ERRNO_BUSY (UINT16_C(10)) +#define __WASI_ERRNO_CANCELED (UINT16_C(11)) +#define __WASI_ERRNO_CHILD (UINT16_C(12)) +#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) +#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) +#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) +#define __WASI_ERRNO_DEADLK (UINT16_C(16)) +#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) +#define __WASI_ERRNO_DOM (UINT16_C(18)) +#define __WASI_ERRNO_DQUOT (UINT16_C(19)) +#define __WASI_ERRNO_EXIST (UINT16_C(20)) +#define __WASI_ERRNO_FAULT (UINT16_C(21)) +#define __WASI_ERRNO_FBIG (UINT16_C(22)) +#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) +#define __WASI_ERRNO_IDRM (UINT16_C(24)) +#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) +#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) +#define __WASI_ERRNO_INTR (UINT16_C(27)) +#define __WASI_ERRNO_INVAL (UINT16_C(28)) +#define __WASI_ERRNO_IO (UINT16_C(29)) +#define __WASI_ERRNO_ISCONN (UINT16_C(30)) +#define __WASI_ERRNO_ISDIR (UINT16_C(31)) +#define __WASI_ERRNO_LOOP (UINT16_C(32)) +#define __WASI_ERRNO_MFILE (UINT16_C(33)) +#define __WASI_ERRNO_MLINK (UINT16_C(34)) +#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) +#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) +#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) +#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) +#define __WASI_ERRNO_NETRESET (UINT16_C(39)) +#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) +#define __WASI_ERRNO_NFILE (UINT16_C(41)) +#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) +#define __WASI_ERRNO_NODEV (UINT16_C(43)) +#define __WASI_ERRNO_NOENT (UINT16_C(44)) +#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) +#define __WASI_ERRNO_NOLCK (UINT16_C(46)) +#define __WASI_ERRNO_NOLINK (UINT16_C(47)) +#define __WASI_ERRNO_NOMEM (UINT16_C(48)) +#define __WASI_ERRNO_NOMSG (UINT16_C(49)) +#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) +#define __WASI_ERRNO_NOSPC (UINT16_C(51)) +#define __WASI_ERRNO_NOSYS (UINT16_C(52)) +#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) +#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) +#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) +#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) +#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) +#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) +#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) +#define __WASI_ERRNO_NOTTY (UINT16_C(59)) +#define __WASI_ERRNO_NXIO (UINT16_C(60)) +#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) +#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) +#define __WASI_ERRNO_PERM (UINT16_C(63)) +#define __WASI_ERRNO_PIPE (UINT16_C(64)) +#define __WASI_ERRNO_PROTO (UINT16_C(65)) +#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) +#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) +#define __WASI_ERRNO_RANGE (UINT16_C(68)) +#define __WASI_ERRNO_ROFS (UINT16_C(69)) +#define __WASI_ERRNO_SPIPE (UINT16_C(70)) +#define __WASI_ERRNO_SRCH (UINT16_C(71)) +#define __WASI_ERRNO_STALE (UINT16_C(72)) +#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) +#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) +#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) +#define __WASI_ERRNO_XDEV (UINT16_C(75)) +#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) +#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) +#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) +#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) +#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) +#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) +#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) +#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) +#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) +#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) +#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) +#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) +#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) +#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) +#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) +#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) +#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) +#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) +#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) +#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) +#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) +#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT +#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) +#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) +#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) +#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) +#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) +#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) +#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) +#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) +#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) +#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) +#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) +#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) +#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) +#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) +#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) +#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) +#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) +#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) +#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) +#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) +#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) +#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) +#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) +#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) +#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) +#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) +#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) +#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) +#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) +#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) +#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) +#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) +#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) +#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) +#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) +#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) +#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) +#define __WASI_WHENCE_CUR (UINT8_C(1)) +#define __WASI_WHENCE_END (UINT8_C(2)) +#define __WASI_WHENCE_SET (UINT8_C(0)) +#define __WCHAR_MAX__ 2147483647 +#define __WCHAR_TYPE__ int +#define __WCHAR_WIDTH__ 32 +#define __WINT_MAX__ 2147483647 +#define __WINT_TYPE__ int +#define __WINT_WIDTH__ 32 +#define __WORDSIZE 64 +#define __alignas_is_defined 1 +#define __alignof_is_defined 1 +#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) +#define __bool_true_false_are_defined 1 +#define __inline inline +#define __restrict restrict +#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) +#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) +#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) +#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) +#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) +#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) +#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) +#define __tm_gmtoff tm_gmtoff +#define __tm_zone tm_zone +#define __va_copy(d,s) __builtin_va_copy(d, s) +#define __wasi__ 1 +#define __wasi_api_h +#define __wasi_libc_environ_h +#define __wasi_libc_find_relpath_h +#define __wasi_libc_h +#define __wasi_libc_nocwd_h +#define __wasilibc___errno_h +#define __wasilibc___errno_values_h +#define __wasilibc___fd_set_h +#define __wasilibc___function___isatty_h +#define __wasilibc___functions_malloc_h +#define __wasilibc___functions_memcpy_h +#define __wasilibc___header_dirent_h +#define __wasilibc___header_fcntl_h +#define __wasilibc___header_netinet_in_h +#define __wasilibc___header_poll_h +#define __wasilibc___header_stdlib_h +#define __wasilibc___header_string_h +#define __wasilibc___header_sys_ioctl_h +#define __wasilibc___header_sys_resource_h +#define __wasilibc___header_sys_socket_h +#define __wasilibc___header_sys_stat_h +#define __wasilibc___header_time_h +#define __wasilibc___header_unistd_h +#define __wasilibc___include_inttypes_h +#define __wasilibc___macro_FD_SETSIZE_h +#define __wasilibc___macro_PAGESIZE_h +#define __wasilibc___mode_t_h +#define __wasilibc___seek_h +#define __wasilibc___struct_dirent_h +#define __wasilibc___struct_in6_addr_h +#define __wasilibc___struct_in_addr_h +#define __wasilibc___struct_iovec_h +#define __wasilibc___struct_msghdr_h +#define __wasilibc___struct_pollfd_h +#define __wasilibc___struct_rusage_h +#define __wasilibc___struct_sockaddr_h +#define __wasilibc___struct_sockaddr_in6_h +#define __wasilibc___struct_sockaddr_in_h +#define __wasilibc___struct_sockaddr_storage_h +#define __wasilibc___struct_sockaddr_un_h +#define __wasilibc___struct_stat_h +#define __wasilibc___struct_timespec_h +#define __wasilibc___struct_timeval_h +#define __wasilibc___struct_tm_h +#define __wasilibc___struct_tms_h +#define __wasilibc___typedef_DIR_h +#define __wasilibc___typedef_blkcnt_t_h +#define __wasilibc___typedef_blksize_t_h +#define __wasilibc___typedef_clock_t_h +#define __wasilibc___typedef_clockid_t_h +#define __wasilibc___typedef_dev_t_h +#define __wasilibc___typedef_fd_set_h +#define __wasilibc___typedef_gid_t_h +#define __wasilibc___typedef_in_addr_t_h +#define __wasilibc___typedef_in_port_t_h +#define __wasilibc___typedef_ino_t_h +#define __wasilibc___typedef_mode_t_h +#define __wasilibc___typedef_nfds_t_h +#define __wasilibc___typedef_nlink_t_h +#define __wasilibc___typedef_off_t_h +#define __wasilibc___typedef_sa_family_t_h +#define __wasilibc___typedef_sigset_t_h +#define __wasilibc___typedef_socklen_t_h +#define __wasilibc___typedef_ssize_t_h +#define __wasilibc___typedef_suseconds_t_h +#define __wasilibc___typedef_time_t_h +#define __wasilibc___typedef_uid_t_h +#define __wasm 1 +#define __wasm64 1 +#define __wasm64__ 1 +#define __wasm__ 1 +#define _tolower(a) ((a)|0x20) +#define _toupper(a) ((a)&0x5f) +#define acos(x) __tg_real_complex(acos, (x)) +#define acosh(x) __tg_real_complex(acosh, (x)) +#define alignas _Alignas +#define alignof _Alignof +#define alloca __builtin_alloca +#define alphasort64 alphasort +#define and && +#define and_eq &= +#define asin(x) __tg_real_complex(asin, (x)) +#define asinh(x) __tg_real_complex(asinh, (x)) +#define atan(x) __tg_real_complex(atan, (x)) +#define atan2(x,y) __tg_real_2(atan2, (x), (y)) +#define atanh(x) __tg_real_complex(atanh, (x)) +#define be16toh(x) __bswap16(x) +#define be32toh(x) __bswap32(x) +#define be64toh(x) __bswap64(x) +#define betoh16(x) __bswap16(x) +#define betoh32(x) __bswap32(x) +#define betoh64(x) __bswap64(x) +#define bitand & +#define bitor | +#define blkcnt64_t blkcnt_t +#define bool _Bool +#define bswap_16(x) __bswap_16(x) +#define bswap_32(x) __bswap_32(x) +#define bswap_64(x) __bswap_64(x) +#define carg(x) __tg_complex_retreal(carg, (x)) +#define cbrt(x) __tg_real(cbrt, (x)) +#define ceil(x) __tg_real(ceil, (x)) +#define cimag(x) __tg_complex_retreal(cimag, (x)) +#define cimagf(x) (__builtin_cimagf(x)) +#define cimagl(x) (__builtin_cimagl(x)) +#define clrbit(x,i) __bitop(x,i,&=~) +#define compl ~ +#define complex _Complex +#define conj(x) __tg_complex(conj, (x)) +#define copysign(x,y) __tg_real_2(copysign, (x), (y)) +#define cos(x) __tg_real_complex(cos, (x)) +#define cosh(x) __tg_real_complex(cosh, (x)) +#define cproj(x) __tg_complex(cproj, (x)) +#define creal(x) __tg_complex_retreal(creal, (x)) +#define crealf(x) (__builtin_crealf(x)) +#define creall(x) (__builtin_creall(x)) +#define creat64 creat +#define d_fileno d_ino +#define direct dirent +#define dirent64 dirent +#define erf(x) __tg_real(erf, (x)) +#define erfc(x) __tg_real(erfc, (x)) +#define errno errno +#define exp(x) __tg_real_complex(exp, (x)) +#define exp2(x) __tg_real(exp2, (x)) +#define expm1(x) __tg_real(expm1, (x)) +#define fabs(x) __tg_real_complex_fabs(x) +#define false 0 +#define fdim(x,y) __tg_real_2(fdim, (x), (y)) +#define fgetpos64 fgetpos +#define floor(x) __tg_real(floor, (x)) +#define fma(x,y,z) __tg_real_fma((x), (y), (z)) +#define fmax(x,y) __tg_real_2(fmax, (x), (y)) +#define fmin(x,y) __tg_real_2(fmin, (x), (y)) +#define fmod(x,y) __tg_real_2(fmod, (x), (y)) +#define fopen64 fopen +#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) +#define fpos64_t fpos_t +#define freopen64 freopen +#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) +#define fsblkcnt64_t fsblkcnt_t +#define fseeko64 fseeko +#define fsetpos64 fsetpos +#define fsfilcnt64_t fsfilcnt_t +#define fstat64 fstat +#define fstatat64 fstatat +#define ftello64 ftello +#define ftruncate64 ftruncate +#define getdents64 getdents +#define glob64 glob +#define glob64_t glob_t +#define globfree64 globfree +#define howmany(n,d) (((n)+((d)-1))/(d)) +#define htobe16(x) __bswap16(x) +#define htobe32(x) __bswap32(x) +#define htobe64(x) __bswap64(x) +#define htole16(x) (uint16_t)(x) +#define htole32(x) (uint32_t)(x) +#define htole64(x) (uint64_t)(x) +#define hypot(x,y) __tg_real_2(hypot, (x), (y)) +#define icmp6_data16 icmp6_dataun.icmp6_un_data16 +#define icmp6_data32 icmp6_dataun.icmp6_un_data32 +#define icmp6_data8 icmp6_dataun.icmp6_un_data8 +#define icmp6_id icmp6_data16[0] +#define icmp6_maxdelay icmp6_data16[0] +#define icmp6_mtu icmp6_data32[0] +#define icmp6_pptr icmp6_data32[0] +#define icmp6_seq icmp6_data16[1] +#define icmp_data icmp_dun.id_data +#define icmp_gwaddr icmp_hun.ih_gwaddr +#define icmp_id icmp_hun.ih_idseq.icd_id +#define icmp_ip icmp_dun.id_ip.idi_ip +#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime +#define icmp_mask icmp_dun.id_mask +#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu +#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs +#define icmp_otime icmp_dun.id_ts.its_otime +#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void +#define icmp_pptr icmp_hun.ih_pptr +#define icmp_radv icmp_dun.id_radv +#define icmp_rtime icmp_dun.id_ts.its_rtime +#define icmp_seq icmp_hun.ih_idseq.icd_seq +#define icmp_ttime icmp_dun.id_ts.its_ttime +#define icmp_void icmp_hun.ih_void +#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa +#define ifa_broadaddr ifa_ifu.ifu_broadaddr +#define ifa_dstaddr ifa_ifu.ifu_dstaddr +#define ilogb(x) __tg_real_nocast(ilogb, (x)) +#define ino64_t ino_t +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) +#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) +#define isclr(x,i) !isset(x,i) +#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) +#define isfinite(x) (__builtin_isfinite(x)) +#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) +#define isgreater(x,y) (__builtin_isgreater(x, y)) +#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) +#define isinf(x) (__builtin_isinf(x)) +#define isless(x,y) (__builtin_isless(x, y)) +#define islessequal(x,y) (__builtin_islessequal(x, y)) +#define islessgreater(x,y) (__builtin_islessgreater(x, y)) +#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) +#define isnan(x) (__builtin_isnan(x)) +#define isnormal(x) (__builtin_isnormal(x)) +#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) +#define isset(x,i) __bitop(x,i,&) +#define isspace(a) __isspace(a) +#define isunordered(x,y) (__builtin_isunordered(x, y)) +#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) +#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) +#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) +#define le16toh(x) (uint16_t)(x) +#define le32toh(x) (uint32_t)(x) +#define le64toh(x) (uint64_t)(x) +#define letoh16(x) (uint16_t)(x) +#define letoh32(x) (uint32_t)(x) +#define letoh64(x) (uint64_t)(x) +#define lgamma(x) __tg_real(lgamma, (x)) +#define llrint(x) __tg_real_nocast(llrint, (x)) +#define llround(x) __tg_real_nocast(llround, (x)) +#define loff_t off_t +#define log(x) __tg_real_complex(log, (x)) +#define log10(x) __tg_real(log10, (x)) +#define log1p(x) __tg_real(log1p, (x)) +#define log2(x) __tg_real(log2, (x)) +#define logb(x) __tg_real(logb, (x)) +#define lrint(x) __tg_real_nocast(lrint, (x)) +#define lround(x) __tg_real_nocast(lround, (x)) +#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) +#define lseek64 lseek +#define lstat64 lstat +#define math_errhandling 2 +#define mld_cksum mld_icmp6_hdr.icmp6_cksum +#define mld_code mld_icmp6_hdr.icmp6_code +#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] +#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] +#define mld_type mld_icmp6_hdr.icmp6_type +#define nd_na_cksum nd_na_hdr.icmp6_cksum +#define nd_na_code nd_na_hdr.icmp6_code +#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] +#define nd_na_type nd_na_hdr.icmp6_type +#define nd_ns_cksum nd_ns_hdr.icmp6_cksum +#define nd_ns_code nd_ns_hdr.icmp6_code +#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] +#define nd_ns_type nd_ns_hdr.icmp6_type +#define nd_ra_cksum nd_ra_hdr.icmp6_cksum +#define nd_ra_code nd_ra_hdr.icmp6_code +#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] +#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] +#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] +#define nd_ra_type nd_ra_hdr.icmp6_type +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rs_cksum nd_rs_hdr.icmp6_cksum +#define nd_rs_code nd_rs_hdr.icmp6_code +#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] +#define nd_rs_type nd_rs_hdr.icmp6_type +#define nearbyint(x) __tg_real(nearbyint, (x)) +#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) +#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) +#define nftw64 nftw +#define no_argument 0 +#define noreturn _Noreturn +#define not ! +#define not_eq != +#define ns_msg_base(handle) ((handle)._msg + 0) +#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) +#define ns_msg_end(handle) ((handle)._eom + 0) +#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) +#define ns_msg_id(handle) ((handle)._id + 0) +#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) +#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) +#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") +#define ns_rr_rdata(rr) ((rr).rdata + 0) +#define ns_rr_rdlen(rr) ((rr).rdlength + 0) +#define ns_rr_ttl(rr) ((rr).ttl + 0) +#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) +#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) +#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) +#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) +#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) +#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) +#define off64_t off_t +#define offsetof(t,d) __builtin_offsetof(t, d) +#define open64 open +#define openat64 openat +#define optional_argument 2 +#define or || +#define or_eq |= +#define posix_fadvise64 posix_fadvise +#define posix_fallocate64 posix_fallocate +#define pow(x,y) __tg_real_complex_pow((x), (y)) +#define powerof2(n) !(((n)-1) & (n)) +#define pread64 pread +#define preadv64 preadv +#define pwrite64 pwrite +#define pwritev64 pwritev +#define readdir64 readdir +#define remainder(x,y) __tg_real_2(remainder, (x), (y)) +#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) +#define required_argument 1 +#define rint(x) __tg_real(rint, (x)) +#define round(x) __tg_real(round, (x)) +#define roundup(n,d) (howmany(n,d)*(d)) +#define rr_cksum rr_hdr.icmp6_cksum +#define rr_code rr_hdr.icmp6_code +#define rr_seqnum rr_hdr.icmp6_data32[0] +#define rr_type rr_hdr.icmp6_type +#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) +#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) +#define scandir64 scandir +#define setbit(x,i) __bitop(x,i,|=) +#define signbit(x) (__builtin_signbit(x)) +#define sin(x) __tg_real_complex(sin, (x)) +#define sinh(x) __tg_real_complex(sinh, (x)) +#define sqrt(x) __tg_real_complex(sqrt, (x)) +#define st_atime st_atim.tv_sec +#define st_ctime st_ctim.tv_sec +#define st_mtime st_mtim.tv_sec +#define stat64 stat +#define static_assert _Static_assert +#define stderr (stderr) +#define stdin (stdin) +#define stdout (stdout) +#define strdupa(x) strcpy(alloca(strlen(x)+1),x) +#define tan(x) __tg_real_complex(tan, (x)) +#define tanh(x) __tg_real_complex(tanh, (x)) +#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) +#define tgamma(x) __tg_real(tgamma, (x)) +#define th_block th_u.tu_block +#define th_code th_u.tu_code +#define th_msg th_data +#define th_stuff th_u.tu_stuff +#define thrd_equal(A,B) ((A) == (B)) +#define thread_local _Thread_local +#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) +#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) +#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) +#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) +#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) +#define true 1 +#define trunc(x) __tg_real(trunc, (x)) +#define uh_dport dest +#define uh_sport source +#define uh_sum check +#define uh_ulen len +#define va_arg(ap,type) __builtin_va_arg(ap, type) +#define va_copy(dest,src) __builtin_va_copy(dest, src) +#define va_end(ap) __builtin_va_end(ap) +#define va_start(ap,param) __builtin_va_start(ap, param) +#define versionsort64 versionsort +#define xEOF 236 +#define xor ^ +#define xor_eq ^= diff --git a/expected/wasm64-wasi-preview2/undefined-symbols.txt b/expected/wasm64-wasi-preview2/undefined-symbols.txt new file mode 100644 index 000000000..e7c62031f --- /dev/null +++ b/expected/wasm64-wasi-preview2/undefined-symbols.txt @@ -0,0 +1,69 @@ +__addtf3 +__divtf3 +__eqtf2 +__extenddftf2 +__extendsftf2 +__fixtfdi +__fixtfsi +__fixunstfsi +__floatditf +__floatsitf +__floatunsitf +__getf2 +__gttf2 +__heap_base +__heap_end +__imported_wasi_snapshot_preview1_args_get +__imported_wasi_snapshot_preview1_args_sizes_get +__imported_wasi_snapshot_preview1_clock_res_get +__imported_wasi_snapshot_preview1_clock_time_get +__imported_wasi_snapshot_preview1_environ_get +__imported_wasi_snapshot_preview1_environ_sizes_get +__imported_wasi_snapshot_preview1_fd_advise +__imported_wasi_snapshot_preview1_fd_allocate +__imported_wasi_snapshot_preview1_fd_close +__imported_wasi_snapshot_preview1_fd_datasync +__imported_wasi_snapshot_preview1_fd_fdstat_get +__imported_wasi_snapshot_preview1_fd_fdstat_set_flags +__imported_wasi_snapshot_preview1_fd_fdstat_set_rights +__imported_wasi_snapshot_preview1_fd_filestat_get +__imported_wasi_snapshot_preview1_fd_filestat_set_size +__imported_wasi_snapshot_preview1_fd_filestat_set_times +__imported_wasi_snapshot_preview1_fd_pread +__imported_wasi_snapshot_preview1_fd_prestat_dir_name +__imported_wasi_snapshot_preview1_fd_prestat_get +__imported_wasi_snapshot_preview1_fd_pwrite +__imported_wasi_snapshot_preview1_fd_read +__imported_wasi_snapshot_preview1_fd_readdir +__imported_wasi_snapshot_preview1_fd_renumber +__imported_wasi_snapshot_preview1_fd_seek +__imported_wasi_snapshot_preview1_fd_sync +__imported_wasi_snapshot_preview1_fd_tell +__imported_wasi_snapshot_preview1_fd_write +__imported_wasi_snapshot_preview1_path_create_directory +__imported_wasi_snapshot_preview1_path_filestat_get +__imported_wasi_snapshot_preview1_path_filestat_set_times +__imported_wasi_snapshot_preview1_path_link +__imported_wasi_snapshot_preview1_path_open +__imported_wasi_snapshot_preview1_path_readlink +__imported_wasi_snapshot_preview1_path_remove_directory +__imported_wasi_snapshot_preview1_path_rename +__imported_wasi_snapshot_preview1_path_symlink +__imported_wasi_snapshot_preview1_path_unlink_file +__imported_wasi_snapshot_preview1_poll_oneoff +__imported_wasi_snapshot_preview1_proc_exit +__imported_wasi_snapshot_preview1_random_get +__imported_wasi_snapshot_preview1_sched_yield +__imported_wasi_snapshot_preview1_sock_accept +__imported_wasi_snapshot_preview1_sock_recv +__imported_wasi_snapshot_preview1_sock_send +__imported_wasi_snapshot_preview1_sock_shutdown +__letf2 +__lttf2 +__netf2 +__stack_pointer +__subtf3 +__trunctfdf2 +__trunctfsf2 +__unordtf2 +__wasm_call_ctors From c94c0c65c0126d6fa6407f71ba1e48feea747a5e Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sun, 7 Jan 2024 16:51:32 -0500 Subject: [PATCH 29/43] fix CI and wasm32-wasi-preview2 predefined-macros --- .github/workflows/main.yml | 7 +++++++ expected/wasm32-wasi-preview2/predefined-macros.txt | 1 + 2 files changed, 8 insertions(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ae451a83f..ddcdaed70 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -122,11 +122,18 @@ jobs: shell: bash run: make -j4 WASM64=yes + - name: Build wasm64 + libc + preview2 + shell: bash + run: | + make -j4 + WASI_SNAPSHOT=preview2 make -j4 WASM64=yes + - name: Build wasm64 + libc + threads # Build wasm64 with thread support if: matrix.clang_version != '10.0.0' shell: bash run: make -j4 WASM64=yes THREAD_MODEL=posix + - uses: actions/upload-artifact@v1 with: # Upload the sysroot folder. Give it a name according to the OS it was built for. diff --git a/expected/wasm32-wasi-preview2/predefined-macros.txt b/expected/wasm32-wasi-preview2/predefined-macros.txt index ff6029d2e..43911b8cb 100644 --- a/expected/wasm32-wasi-preview2/predefined-macros.txt +++ b/expected/wasm32-wasi-preview2/predefined-macros.txt @@ -2928,6 +2928,7 @@ #define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) #define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) #define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT #define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) #define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) #define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) From 01e6ed37e5062ac7748e3c9b758eabb6fb9a5b60 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sun, 7 Jan 2024 16:53:10 -0500 Subject: [PATCH 30/43] prevent clang 10 from crashing --- .github/workflows/main.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ddcdaed70..851a3fc63 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -123,6 +123,7 @@ jobs: run: make -j4 WASM64=yes - name: Build wasm64 + libc + preview2 + if: matrix.clang_version != '10.0.0' shell: bash run: | make -j4 From 84472d93f9adc47a579a9b6d37b24ef458506061 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Mon, 15 Jan 2024 03:22:46 -0500 Subject: [PATCH 31/43] recompile to fix CI --- .github/workflows/main.yml | 7 ------- .../wasm64-wasi-threads/defined-symbols.txt | 5 +++++ expected/wasm64-wasi-threads/include-all.c | 1 + .../wasm64-wasi-threads/predefined-macros.txt | 18 ++++++++++++++++- expected/wasm64-wasi/defined-symbols.txt | 5 +++++ expected/wasm64-wasi/include-all.c | 1 + expected/wasm64-wasi/predefined-macros.txt | 20 +++++++++++++++++-- 7 files changed, 47 insertions(+), 10 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ca7ddc6f1..ef874f623 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -132,13 +132,6 @@ jobs: shell: bash run: make -j4 WASM64=yes - - name: Build wasm64 + libc + preview2 - if: matrix.clang_version != '10.0.0' - shell: bash - run: | - make -j4 - WASI_SNAPSHOT=preview2 make -j4 WASM64=yes - - name: Build wasm64 + libc + threads # Build wasm64 with thread support if: matrix.clang_version != '10.0.0' diff --git a/expected/wasm64-wasi-threads/defined-symbols.txt b/expected/wasm64-wasi-threads/defined-symbols.txt index c913f1620..c434bf8a3 100644 --- a/expected/wasm64-wasi-threads/defined-symbols.txt +++ b/expected/wasm64-wasi-threads/defined-symbols.txt @@ -511,6 +511,7 @@ cexp cexpf cexpl chdir +chmod cimag cimagf cimagl @@ -607,6 +608,8 @@ fabs fabsf fabsl faccessat +fchmod +fchmodat fclose fcntl fcvt @@ -702,6 +705,7 @@ fsetpos fsetpos64 fstat fstatat +fstatvfs fsync ftell ftello @@ -1162,6 +1166,7 @@ srand48 srandom sscanf stat +statvfs stderr stdin stdout diff --git a/expected/wasm64-wasi-threads/include-all.c b/expected/wasm64-wasi-threads/include-all.c index 28b592438..d9536e09f 100644 --- a/expected/wasm64-wasi-threads/include-all.c +++ b/expected/wasm64-wasi-threads/include-all.c @@ -142,6 +142,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt index 0120f130b..ee5db9cac 100644 --- a/expected/wasm64-wasi-threads/predefined-macros.txt +++ b/expected/wasm64-wasi-threads/predefined-macros.txt @@ -181,6 +181,7 @@ #define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM #define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK #define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_SOCK 20 #define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN #define D_FMT 0x20029 #define D_T_FMT 0x20028 @@ -1671,6 +1672,18 @@ #define STRU_F 1 #define STRU_P 3 #define STRU_R 2 +#define ST_APPEND 256 +#define ST_IMMUTABLE 512 +#define ST_MANDLOCK 64 +#define ST_NOATIME 1024 +#define ST_NODEV 4 +#define ST_NODIRATIME 2048 +#define ST_NOEXEC 8 +#define ST_NOSUID 2 +#define ST_RDONLY 1 +#define ST_RELATIME 4096 +#define ST_SYNCHRONOUS 16 +#define ST_WRITE 128 #define SUN_LEN(s) (2+strlen((s)->sun_path)) #define SUSP 237 #define SYMLOOP_MAX 40 @@ -1685,7 +1698,7 @@ #define S_IFBLK (0x6000) #define S_IFCHR (0x2000) #define S_IFDIR (0x4000) -#define S_IFIFO (0xc000) +#define S_IFIFO (0x1000) #define S_IFLNK (0xa000) #define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) #define S_IFREG (0x8000) @@ -2360,6 +2373,7 @@ #define _SYS_REG_H #define _SYS_SELECT_H #define _SYS_SOCKET_H +#define _SYS_STATVFS_H #define _SYS_STAT_H #define _SYS_SYSCALL_H #define _SYS_SYSINFO_H @@ -3186,6 +3200,7 @@ #define fsfilcnt64_t fsfilcnt_t #define fstat64 fstat #define fstatat64 fstatat +#define fstatvfs64 fstatvfs #define ftello64 ftello #define ftruncate64 ftruncate #define getdents64 getdents @@ -3372,6 +3387,7 @@ #define st_mtime st_mtim.tv_sec #define stat64 stat #define static_assert _Static_assert +#define statvfs64 statvfs #define stderr (stderr) #define stdin (stdin) #define stdout (stdout) diff --git a/expected/wasm64-wasi/defined-symbols.txt b/expected/wasm64-wasi/defined-symbols.txt index 6e743228b..8342dd5ee 100644 --- a/expected/wasm64-wasi/defined-symbols.txt +++ b/expected/wasm64-wasi/defined-symbols.txt @@ -447,6 +447,7 @@ cexp cexpf cexpl chdir +chmod cimag cimagf cimagl @@ -543,6 +544,8 @@ fabs fabsf fabsl faccessat +fchmod +fchmodat fclose fcntl fcvt @@ -637,6 +640,7 @@ fsetpos fsetpos64 fstat fstatat +fstatvfs fsync ftell ftello @@ -1012,6 +1016,7 @@ srand48 srandom sscanf stat +statvfs stderr stdin stdout diff --git a/expected/wasm64-wasi/include-all.c b/expected/wasm64-wasi/include-all.c index 297e48b14..1040097ba 100644 --- a/expected/wasm64-wasi/include-all.c +++ b/expected/wasm64-wasi/include-all.c @@ -141,6 +141,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt index a53d9ebac..06ca96d05 100644 --- a/expected/wasm64-wasi/predefined-macros.txt +++ b/expected/wasm64-wasi/predefined-macros.txt @@ -181,6 +181,7 @@ #define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM #define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK #define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_SOCK 20 #define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN #define D_FMT 0x20029 #define D_T_FMT 0x20028 @@ -1637,6 +1638,18 @@ #define STRU_F 1 #define STRU_P 3 #define STRU_R 2 +#define ST_APPEND 256 +#define ST_IMMUTABLE 512 +#define ST_MANDLOCK 64 +#define ST_NOATIME 1024 +#define ST_NODEV 4 +#define ST_NODIRATIME 2048 +#define ST_NOEXEC 8 +#define ST_NOSUID 2 +#define ST_RDONLY 1 +#define ST_RELATIME 4096 +#define ST_SYNCHRONOUS 16 +#define ST_WRITE 128 #define SUN_LEN(s) (2+strlen((s)->sun_path)) #define SUSP 237 #define SYMLOOP_MAX 40 @@ -1651,7 +1664,7 @@ #define S_IFBLK (0x6000) #define S_IFCHR (0x2000) #define S_IFDIR (0x4000) -#define S_IFIFO (0xc000) +#define S_IFIFO (0x1000) #define S_IFLNK (0xa000) #define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) #define S_IFREG (0x8000) @@ -2018,7 +2031,7 @@ #define _Complex_I (0.0f+1.0fi) #define _DIRENT_H #define _DIRENT_HAVE_D_TYPE -#define _DLFCN_H +#define _DLFCN_H #define _ENDIAN_H #define _ERRNO_H #define _ERR_H @@ -2323,6 +2336,7 @@ #define _SYS_REG_H #define _SYS_SELECT_H #define _SYS_SOCKET_H +#define _SYS_STATVFS_H #define _SYS_STAT_H #define _SYS_SYSCALL_H #define _SYS_SYSINFO_H @@ -3147,6 +3161,7 @@ #define fsfilcnt64_t fsfilcnt_t #define fstat64 fstat #define fstatat64 fstatat +#define fstatvfs64 fstatvfs #define ftello64 ftello #define ftruncate64 ftruncate #define getdents64 getdents @@ -3330,6 +3345,7 @@ #define st_mtime st_mtim.tv_sec #define stat64 stat #define static_assert _Static_assert +#define statvfs64 statvfs #define stderr (stderr) #define stdin (stdin) #define stdout (stdout) From 96b3d9e942102461f0fe771995931c5e5b21f4fb Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 16 Mar 2024 21:59:57 -0400 Subject: [PATCH 32/43] fix --- .../wasm64-wasip1-threads/defined-symbols.txt | 1366 +++++++ expected/wasm64-wasip1-threads/include-all.c | 173 + .../predefined-macros.txt | 3423 +++++++++++++++++ .../undefined-symbols.txt | 76 + expected/wasm64-wasip2/defined-symbols.txt | 1206 ++++++ expected/wasm64-wasip2/include-all.c | 171 + expected/wasm64-wasip2/predefined-macros.txt | 3365 ++++++++++++++++ expected/wasm64-wasip2/undefined-symbols.txt | 69 + 8 files changed, 9849 insertions(+) create mode 100644 expected/wasm64-wasip1-threads/defined-symbols.txt create mode 100644 expected/wasm64-wasip1-threads/include-all.c create mode 100644 expected/wasm64-wasip1-threads/predefined-macros.txt create mode 100644 expected/wasm64-wasip1-threads/undefined-symbols.txt create mode 100644 expected/wasm64-wasip2/defined-symbols.txt create mode 100644 expected/wasm64-wasip2/include-all.c create mode 100644 expected/wasm64-wasip2/predefined-macros.txt create mode 100644 expected/wasm64-wasip2/undefined-symbols.txt diff --git a/expected/wasm64-wasip1-threads/defined-symbols.txt b/expected/wasm64-wasip1-threads/defined-symbols.txt new file mode 100644 index 000000000..c434bf8a3 --- /dev/null +++ b/expected/wasm64-wasip1-threads/defined-symbols.txt @@ -0,0 +1,1366 @@ +_CLOCK_MONOTONIC +_CLOCK_REALTIME +_Exit +_IO_feof_unlocked +_IO_ferror_unlocked +_IO_getc +_IO_getc_unlocked +_IO_putc +_IO_putc_unlocked +__EINVAL +__ENOMEM +__SIG_ERR +__SIG_IGN +__acquire_ptc +__aio_close +__asctime_r +__assert_fail +__at_quick_exit_lockptr +__atexit_lockptr +__c_dot_utf8 +__c_dot_utf8_locale +__c_locale +__clock +__clock_gettime +__clock_nanosleep +__copy_tls +__cos +__cosdf +__cosl +__crypt_blowfish +__crypt_des +__crypt_md5 +__crypt_r +__crypt_sha256 +__crypt_sha512 +__ctype_b_loc +__ctype_get_mb_cur_max +__ctype_tolower_loc +__ctype_toupper_loc +__cxa_atexit +__cxa_finalize +__default_guardsize +__default_stacksize +__des_setkey +__do_cleanup_pop +__do_cleanup_push +__do_des +__do_orphaned_stdio_locks +__dummy_reference +__duplocale +__env_rm_add +__errno_location +__exp2f_data +__exp_data +__expo2 +__expo2f +__fbufsize +__fclose_ca +__fdopen +__fesetround +__fgetwc_unlocked +__flbf +__floatscan +__fmodeflags +__fopen_rb_ca +__fpending +__fpurge +__fputwc_unlocked +__freadable +__freadahead +__freading +__freadptr +__freadptrinc +__freelocale +__fseeko +__fseeko_unlocked +__fseterr +__fsetlocking +__fsmu8 +__ftello +__ftello_unlocked +__funcs_on_exit +__funcs_on_quick_exit +__futimesat +__fwritable +__fwritex +__fwriting +__get_locale +__getdelim +__getentropy +__getopt_msg +__gmtime_r +__hwcap +__inet_aton +__init_ssp +__init_tp +__intscan +__invtrigl_R +__isalnum_l +__isalpha_l +__isatty +__isblank_l +__iscntrl_l +__isdigit_l +__isgraph_l +__islower_l +__isoc99_fscanf +__isoc99_fwscanf +__isoc99_scanf +__isoc99_sscanf +__isoc99_swscanf +__isoc99_vfscanf +__isoc99_vfwscanf +__isoc99_vscanf +__isoc99_vsscanf +__isoc99_vswscanf +__isoc99_vwscanf +__isoc99_wscanf +__isprint_l +__ispunct_l +__isspace_l +__isupper_l +__iswalnum_l +__iswalpha_l +__iswblank_l +__iswcntrl_l +__iswctype_l +__iswdigit_l +__iswgraph_l +__iswlower_l +__iswprint_l +__iswpunct_l +__iswspace_l +__iswupper_l +__iswxdigit_l +__isxdigit_l +__lctrans +__lctrans_cur +__lctrans_impl +__ldexp_cexp +__ldexp_cexpf +__lgamma_r +__lgammaf_r +__lgammal_r +__libc +__libc_calloc +__libc_free +__libc_malloc +__loc_is_allocated +__locale_lock +__locale_lockptr +__localtime_r +__lock +__lockfile +__log2_data +__log2f_data +__log_data +__logf_data +__lseek +__main_void +__math_divzero +__math_divzerof +__math_invalid +__math_invalidf +__math_invalidl +__math_oflow +__math_oflowf +__math_uflow +__math_uflowf +__math_xflow +__math_xflowf +__memrchr +__mo_lookup +__month_to_secs +__newlocale +__nl_langinfo +__nl_langinfo_l +__ofl_add +__ofl_lock +__ofl_unlock +__optpos +__optreset +__overflow +__p1evll +__pio2_hi +__pio2_lo +__pleval +__polevll +__posix_getopt +__pow_log_data +__powf_log2_data +__private_cond_signal +__progname +__progname_full +__pthread_cond_timedwait +__pthread_create +__pthread_join +__pthread_key_create +__pthread_key_delete +__pthread_mutex_lock +__pthread_mutex_timedlock +__pthread_mutex_trylock +__pthread_mutex_trylock_owner +__pthread_mutex_unlock +__pthread_once +__pthread_once_full +__pthread_rwlock_rdlock +__pthread_rwlock_timedrdlock +__pthread_rwlock_timedwrlock +__pthread_rwlock_tryrdlock +__pthread_rwlock_trywrlock +__pthread_rwlock_unlock +__pthread_rwlock_wrlock +__pthread_setcancelstate +__pthread_testcancel +__pthread_tsd_main +__pthread_tsd_run_dtors +__pthread_tsd_size +__putenv +__qsort_r +__rand48_step +__random_lockptr +__reallocarray +__register_locked_file +__release_ptc +__rem_pio2 +__rem_pio2_large +__rem_pio2f +__rem_pio2l +__rsqrt_tab +__secs_to_tm +__secs_to_zone +__seed48 +__shgetc +__shlim +__signgam +__sin +__sindf +__sinl +__small_printf +__stack_chk_fail +__stack_chk_fail_local +__stack_chk_guard +__stderr_FILE +__stderr_used +__stdin_FILE +__stdin_used +__stdio_close +__stdio_exit +__stdio_exit_needed +__stdio_ofl_lockptr +__stdio_read +__stdio_seek +__stdio_write +__stdout_FILE +__stdout_used +__stdout_write +__stpcpy +__stpncpy +__strcasecmp_l +__strchrnul +__strcoll_l +__strerror_l +__strftime_fmt_1 +__strftime_l +__strncasecmp_l +__strtod_l +__strtof_l +__strtoimax_internal +__strtol_internal +__strtold_l +__strtoll_internal +__strtoul_internal +__strtoull_internal +__strtoumax_internal +__strxfrm_l +__sysinfo +__sysv_signal +__tan +__tandf +__tanl +__testcancel +__thread_list_lock +__timedwait +__timedwait_cp +__tl_lock +__tl_sync +__tl_unlock +__tm_to_secs +__tm_to_tzname +__tolower_l +__toread +__toread_needs_stdio_exit +__toupper_l +__towctrans_l +__towlower_l +__towrite +__towrite_needs_stdio_exit +__towupper_l +__tre_mem_alloc_impl +__tre_mem_destroy +__tre_mem_new_impl +__tsearch_balance +__uflow +__unlist_locked_file +__unlock +__unlockfile +__uselocale +__utc +__wait +__wasi_args_get +__wasi_args_sizes_get +__wasi_clock_res_get +__wasi_clock_time_get +__wasi_environ_get +__wasi_environ_sizes_get +__wasi_fd_advise +__wasi_fd_allocate +__wasi_fd_close +__wasi_fd_datasync +__wasi_fd_fdstat_get +__wasi_fd_fdstat_set_flags +__wasi_fd_fdstat_set_rights +__wasi_fd_filestat_get +__wasi_fd_filestat_set_size +__wasi_fd_filestat_set_times +__wasi_fd_pread +__wasi_fd_prestat_dir_name +__wasi_fd_prestat_get +__wasi_fd_pwrite +__wasi_fd_read +__wasi_fd_readdir +__wasi_fd_renumber +__wasi_fd_seek +__wasi_fd_sync +__wasi_fd_tell +__wasi_fd_write +__wasi_init_tp +__wasi_path_create_directory +__wasi_path_filestat_get +__wasi_path_filestat_set_times +__wasi_path_link +__wasi_path_open +__wasi_path_readlink +__wasi_path_remove_directory +__wasi_path_rename +__wasi_path_symlink +__wasi_path_unlink_file +__wasi_poll_oneoff +__wasi_proc_exit +__wasi_random_get +__wasi_sched_yield +__wasi_sock_accept +__wasi_sock_recv +__wasi_sock_send +__wasi_sock_shutdown +__wasi_thread_spawn +__wasi_thread_start_C +__wasilibc_access +__wasilibc_cwd +__wasilibc_cwd_lock +__wasilibc_cwd_unlock +__wasilibc_deinitialize_environ +__wasilibc_dttoif +__wasilibc_ensure_environ +__wasilibc_environ +__wasilibc_fd_renumber +__wasilibc_find_abspath +__wasilibc_find_relpath +__wasilibc_find_relpath_alloc +__wasilibc_futex_wait +__wasilibc_get_environ +__wasilibc_iftodt +__wasilibc_initialize_environ +__wasilibc_link +__wasilibc_link_newat +__wasilibc_link_oldat +__wasilibc_maybe_reinitialize_environ_eagerly +__wasilibc_nocwd___wasilibc_rmdirat +__wasilibc_nocwd___wasilibc_unlinkat +__wasilibc_nocwd_faccessat +__wasilibc_nocwd_fstatat +__wasilibc_nocwd_linkat +__wasilibc_nocwd_mkdirat_nomode +__wasilibc_nocwd_openat_nomode +__wasilibc_nocwd_opendirat +__wasilibc_nocwd_readlinkat +__wasilibc_nocwd_renameat +__wasilibc_nocwd_scandirat +__wasilibc_nocwd_symlinkat +__wasilibc_nocwd_utimensat +__wasilibc_open_nomode +__wasilibc_populate_preopens +__wasilibc_pthread_self +__wasilibc_register_preopened_fd +__wasilibc_rename_newat +__wasilibc_rename_oldat +__wasilibc_rmdirat +__wasilibc_stat +__wasilibc_tell +__wasilibc_unlinkat +__wasilibc_utimens +__wasm_call_dtors +__wcscoll_l +__wcsftime_l +__wcsxfrm_l +__wctrans_l +__wctype_l +__xpg_basename +__xpg_strerror_r +__year_to_secs +_environ +_exit +_flushlbf +_initialize +_pthread_cleanup_pop +_pthread_cleanup_push +_start +a64l +abort +abs +accept +accept4 +access +acos +acosf +acosh +acoshf +acoshl +acosl +aligned_alloc +alphasort +alphasort64 +arc4random +arc4random_buf +arc4random_uniform +asctime +asctime_r +asin +asinf +asinh +asinhf +asinhl +asinl +asprintf +at_quick_exit +atan +atan2 +atan2f +atan2l +atanf +atanh +atanhf +atanhl +atanl +atexit +atof +atoi +atol +atoll +basename +bcmp +bcopy +bsd_signal +bsearch +btowc +bzero +c16rtomb +c32rtomb +cabs +cabsf +cabsl +cacos +cacosf +cacosh +cacoshf +cacoshl +cacosl +calloc +carg +cargf +cargl +casin +casinf +casinh +casinhf +casinhl +casinl +catan +catanf +catanh +catanhf +catanhl +catanl +catclose +catgets +catopen +cbrt +cbrtf +cbrtl +ccos +ccosf +ccosh +ccoshf +ccoshl +ccosl +ceil +ceilf +ceill +cexp +cexpf +cexpl +chdir +chmod +cimag +cimagf +cimagl +clearenv +clearerr +clearerr_unlocked +clock +clock_getres +clock_gettime +clock_nanosleep +clog +clogf +clogl +close +closedir +confstr +conj +conjf +conjl +copysign +copysignf +copysignl +cos +cosf +cosh +coshf +coshl +cosl +cpow +cpowf +cpowl +cproj +cprojf +cprojl +creal +crealf +creall +creat +creat64 +crypt +crypt_r +csin +csinf +csinh +csinhf +csinhl +csinl +csqrt +csqrtf +csqrtl +ctan +ctanf +ctanh +ctanhf +ctanhl +ctanl +ctime +ctime_r +difftime +dirfd +dirname +div +dprintf +drand48 +drem +dremf +duplocale +ecvt +encrypt +environ +erand48 +erf +erfc +erfcf +erfcl +erff +erfl +errno +exit +exp +exp10 +exp10f +exp10l +exp2 +exp2f +exp2l +expf +expl +explicit_bzero +expm1 +expm1f +expm1l +fabs +fabsf +fabsl +faccessat +fchmod +fchmodat +fclose +fcntl +fcvt +fdatasync +fdclosedir +fdim +fdimf +fdiml +fdopen +fdopendir +feclearexcept +fegetenv +fegetexceptflag +fegetround +feholdexcept +feof +feof_unlocked +feraiseexcept +ferror +ferror_unlocked +fesetenv +fesetexceptflag +fesetround +fetestexcept +feupdateenv +fflush +fflush_unlocked +ffs +ffsl +ffsll +fgetc +fgetc_unlocked +fgetln +fgetpos +fgetpos64 +fgets +fgets_unlocked +fgetwc +fgetwc_unlocked +fgetws +fgetws_unlocked +fileno +fileno_unlocked +finite +finitef +flockfile +floor +floorf +floorl +fma +fmaf +fmal +fmax +fmaxf +fmaxl +fmemopen +fmin +fminf +fminl +fmod +fmodf +fmodl +fmtmsg +fnmatch +fopen +fopen64 +fopencookie +fpathconf +fprintf +fpurge +fputc +fputc_unlocked +fputs +fputs_unlocked +fputwc +fputwc_unlocked +fputws +fputws_unlocked +fread +fread_unlocked +free +freelocale +freopen +freopen64 +frexp +frexpf +frexpl +fscanf +fseek +fseeko +fseeko64 +fsetpos +fsetpos64 +fstat +fstatat +fstatvfs +fsync +ftell +ftello +ftello64 +ftime +ftruncate +ftrylockfile +funlockfile +futimens +futimesat +fwide +fwprintf +fwrite +fwrite_unlocked +fwscanf +gcvt +get_avphys_pages +get_nprocs +get_nprocs_conf +get_phys_pages +getc +getc_unlocked +getchar +getchar_unlocked +getcwd +getdate +getdate_err +getdelim +getdomainname +getentropy +getenv +gethostid +getline +getopt +getopt_long +getopt_long_only +getpagesize +getpid +getrusage +getsockopt +getsubopt +gettimeofday +getw +getwc +getwc_unlocked +getwchar +getwchar_unlocked +glob +glob64 +globfree +globfree64 +gmtime +gmtime_r +hcreate +hcreate_r +hdestroy +hdestroy_r +hsearch +hsearch_r +htonl +htons +hypot +hypotf +hypotl +iconv +iconv_close +iconv_open +ilogb +ilogbf +ilogbl +imaxabs +imaxdiv +in6addr_any +in6addr_loopback +index +inet_aton +inet_ntop +inet_pton +initstate +insque +ioctl +iprintf +isalnum +isalnum_l +isalpha +isalpha_l +isascii +isatty +isblank +isblank_l +iscntrl +iscntrl_l +isdigit +isdigit_l +isgraph +isgraph_l +islower +islower_l +isprint +isprint_l +ispunct +ispunct_l +isspace +isspace_l +isupper +isupper_l +iswalnum +iswalnum_l +iswalpha +iswalpha_l +iswblank +iswblank_l +iswcntrl +iswcntrl_l +iswctype +iswctype_l +iswdigit +iswdigit_l +iswgraph +iswgraph_l +iswlower +iswlower_l +iswprint +iswprint_l +iswpunct +iswpunct_l +iswspace +iswspace_l +iswupper +iswupper_l +iswxdigit +iswxdigit_l +isxdigit +isxdigit_l +j0 +j0f +j1 +j1f +jn +jnf +jrand48 +l64a +labs +lcong48 +ldexp +ldexpf +ldexpl +ldiv +lfind +lgamma +lgamma_r +lgammaf +lgammaf_r +lgammal +lgammal_r +link +linkat +llabs +lldiv +llrint +llrintf +llrintl +llround +llroundf +llroundl +localeconv +localtime +localtime_r +log +log10 +log10f +log10l +log1p +log1pf +log1pl +log2 +log2f +log2l +logb +logbf +logbl +logf +logl +lrand48 +lrint +lrintf +lrintl +lround +lroundf +lroundl +lsearch +lseek +lstat +malloc +malloc_usable_size +mblen +mbrlen +mbrtoc16 +mbrtoc32 +mbrtowc +mbsinit +mbsnrtowcs +mbsrtowcs +mbstowcs +mbtowc +memccpy +memchr +memcmp +memcpy +memmem +memmove +mempcpy +memrchr +memset +mkdir +mkdirat +mktime +mmap +modf +modff +modfl +mrand48 +munmap +nan +nanf +nanl +nanosleep +nearbyint +nearbyintf +nearbyintl +newlocale +nextafter +nextafterf +nextafterl +nexttoward +nexttowardf +nexttowardl +nftw +nftw64 +nl_langinfo +nl_langinfo_l +nrand48 +ntohl +ntohs +open +open_memstream +open_wmemstream +openat +opendir +opendirat +optarg +opterr +optind +optopt +optreset +pathconf +perror +poll +posix_close +posix_fadvise +posix_fallocate +posix_memalign +pow +pow10 +pow10f +pow10l +powf +powl +pread +preadv +printf +program_invocation_name +program_invocation_short_name +pselect +psignal +pthread_attr_destroy +pthread_attr_getdetachstate +pthread_attr_getguardsize +pthread_attr_getinheritsched +pthread_attr_getscope +pthread_attr_getstack +pthread_attr_getstacksize +pthread_attr_init +pthread_attr_setdetachstate +pthread_attr_setstack +pthread_attr_setstacksize +pthread_barrier_destroy +pthread_barrier_init +pthread_barrier_wait +pthread_barrierattr_getpshared +pthread_cond_broadcast +pthread_cond_destroy +pthread_cond_init +pthread_cond_signal +pthread_cond_timedwait +pthread_cond_wait +pthread_condattr_destroy +pthread_condattr_getpshared +pthread_condattr_init +pthread_condattr_setclock +pthread_condattr_setpshared +pthread_create +pthread_detach +pthread_equal +pthread_getspecific +pthread_join +pthread_key_create +pthread_key_delete +pthread_mutex_consistent +pthread_mutex_destroy +pthread_mutex_getprioceiling +pthread_mutex_init +pthread_mutex_lock +pthread_mutex_timedlock +pthread_mutex_trylock +pthread_mutex_unlock +pthread_mutexattr_destroy +pthread_mutexattr_getprotocol +pthread_mutexattr_getpshared +pthread_mutexattr_getrobust +pthread_mutexattr_gettype +pthread_mutexattr_init +pthread_mutexattr_setprotocol +pthread_mutexattr_setpshared +pthread_mutexattr_setrobust +pthread_mutexattr_settype +pthread_once +pthread_rwlock_destroy +pthread_rwlock_init +pthread_rwlock_rdlock +pthread_rwlock_timedrdlock +pthread_rwlock_timedwrlock +pthread_rwlock_tryrdlock +pthread_rwlock_trywrlock +pthread_rwlock_unlock +pthread_rwlock_wrlock +pthread_rwlockattr_destroy +pthread_rwlockattr_getpshared +pthread_rwlockattr_init +pthread_rwlockattr_setpshared +pthread_self +pthread_setcancelstate +pthread_setspecific +pthread_spin_destroy +pthread_spin_init +pthread_spin_lock +pthread_spin_trylock +pthread_spin_unlock +pthread_testcancel +pthread_timedjoin_np +pthread_tryjoin_np +putc +putc_unlocked +putchar +putchar_unlocked +putenv +puts +putw +putwc +putwc_unlocked +putwchar +putwchar_unlocked +pwrite +pwritev +qsort +qsort_r +quick_exit +raise +rand +rand_r +random +read +readdir +readlink +readlinkat +readv +realloc +reallocarray +recv +regcomp +regerror +regexec +regfree +remainder +remainderf +remainderl +remove +remque +remquo +remquof +remquol +rename +renameat +rewind +rewinddir +rindex +rint +rintf +rintl +rmdir +round +roundf +roundl +sbrk +scalb +scalbf +scalbln +scalblnf +scalblnl +scalbn +scalbnf +scalbnl +scandir +scandirat +scanf +sched_yield +seed48 +seekdir +select +sem_destroy +sem_getvalue +sem_init +sem_post +sem_timedwait +sem_trywait +sem_wait +send +setbuf +setbuffer +setenv +setkey +setlinebuf +setlocale +setstate +setvbuf +shutdown +signal +signgam +significand +significandf +sin +sincos +sincosf +sincosl +sinf +sinh +sinhf +sinhl +sinl +sleep +snprintf +sprintf +sqrt +sqrtf +sqrtl +srand +srand48 +srandom +sscanf +stat +statvfs +stderr +stdin +stdout +stpcpy +stpncpy +strcasecmp +strcasecmp_l +strcasestr +strcat +strchr +strchrnul +strcmp +strcoll +strcoll_l +strcpy +strcspn +strdup +strerror +strerror_l +strerror_r +strfmon +strfmon_l +strftime +strftime_l +strlcat +strlcpy +strlen +strncasecmp +strncasecmp_l +strncat +strncmp +strncpy +strndup +strnlen +strpbrk +strptime +strrchr +strsep +strsignal +strspn +strstr +strtod +strtod_l +strtof +strtof_l +strtoimax +strtok +strtok_r +strtol +strtold +strtold_l +strtoll +strtoul +strtoull +strtoumax +strverscmp +strxfrm +strxfrm_l +swab +swprintf +swscanf +symlink +symlinkat +sysconf +tan +tanf +tanh +tanhf +tanhl +tanl +tdelete +tdestroy +telldir +tfind +tgamma +tgammaf +tgammal +thrd_current +thrd_detach +thrd_equal +thrd_sleep +time +timegm +times +timespec_get +toascii +tolower +tolower_l +toupper +toupper_l +towctrans +towctrans_l +towlower +towlower_l +towupper +towupper_l +trunc +truncate +truncf +truncl +tsearch +tss_get +twalk +uname +ungetc +ungetwc +unlink +unlinkat +unsetenv +uselocale +usleep +utime +utimensat +utimes +vasprintf +vdprintf +versionsort +versionsort64 +vfprintf +vfscanf +vfwprintf +vfwscanf +vprintf +vscanf +vsnprintf +vsprintf +vsscanf +vswprintf +vswscanf +vwprintf +vwscanf +wasi_thread_start +wcpcpy +wcpncpy +wcrtomb +wcscasecmp +wcscasecmp_l +wcscat +wcschr +wcscmp +wcscoll +wcscoll_l +wcscpy +wcscspn +wcsdup +wcsftime +wcsftime_l +wcslen +wcsncasecmp +wcsncasecmp_l +wcsncat +wcsncmp +wcsncpy +wcsnlen +wcsnrtombs +wcspbrk +wcsrchr +wcsrtombs +wcsspn +wcsstr +wcstod +wcstof +wcstoimax +wcstok +wcstol +wcstold +wcstoll +wcstombs +wcstoul +wcstoull +wcstoumax +wcswcs +wcswidth +wcsxfrm +wcsxfrm_l +wctob +wctomb +wctrans +wctrans_l +wctype +wctype_l +wcwidth +wmemchr +wmemcmp +wmemcpy +wmemmove +wmemset +wprintf +write +writev +wscanf +y0 +y0f +y1 +y1f +yn +ynf diff --git a/expected/wasm64-wasip1-threads/include-all.c b/expected/wasm64-wasip1-threads/include-all.c new file mode 100644 index 000000000..d9536e09f --- /dev/null +++ b/expected/wasm64-wasip1-threads/include-all.c @@ -0,0 +1,173 @@ +#include <__errno.h> +#include <__errno_values.h> +#include <__fd_set.h> +#include <__function___isatty.h> +#include <__functions_malloc.h> +#include <__functions_memcpy.h> +#include <__header_dirent.h> +#include <__header_fcntl.h> +#include <__header_inttypes.h> +#include <__header_netinet_in.h> +#include <__header_poll.h> +#include <__header_stdlib.h> +#include <__header_string.h> +#include <__header_sys_ioctl.h> +#include <__header_sys_resource.h> +#include <__header_sys_socket.h> +#include <__header_sys_stat.h> +#include <__header_time.h> +#include <__header_unistd.h> +#include <__macro_FD_SETSIZE.h> +#include <__macro_PAGESIZE.h> +#include <__mode_t.h> +#include <__seek.h> +#include <__struct_dirent.h> +#include <__struct_in6_addr.h> +#include <__struct_in_addr.h> +#include <__struct_iovec.h> +#include <__struct_msghdr.h> +#include <__struct_pollfd.h> +#include <__struct_rusage.h> +#include <__struct_sockaddr.h> +#include <__struct_sockaddr_in.h> +#include <__struct_sockaddr_in6.h> +#include <__struct_sockaddr_storage.h> +#include <__struct_sockaddr_un.h> +#include <__struct_stat.h> +#include <__struct_timespec.h> +#include <__struct_timeval.h> +#include <__struct_tm.h> +#include <__struct_tms.h> +#include <__typedef_DIR.h> +#include <__typedef_blkcnt_t.h> +#include <__typedef_blksize_t.h> +#include <__typedef_clock_t.h> +#include <__typedef_clockid_t.h> +#include <__typedef_dev_t.h> +#include <__typedef_fd_set.h> +#include <__typedef_gid_t.h> +#include <__typedef_in_addr_t.h> +#include <__typedef_in_port_t.h> +#include <__typedef_ino_t.h> +#include <__typedef_mode_t.h> +#include <__typedef_nfds_t.h> +#include <__typedef_nlink_t.h> +#include <__typedef_off_t.h> +#include <__typedef_sa_family_t.h> +#include <__typedef_sigset_t.h> +#include <__typedef_socklen_t.h> +#include <__typedef_ssize_t.h> +#include <__typedef_suseconds_t.h> +#include <__typedef_time_t.h> +#include <__typedef_uid_t.h> +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include diff --git a/expected/wasm64-wasip1-threads/predefined-macros.txt b/expected/wasm64-wasip1-threads/predefined-macros.txt new file mode 100644 index 000000000..ee5db9cac --- /dev/null +++ b/expected/wasm64-wasip1-threads/predefined-macros.txt @@ -0,0 +1,3423 @@ +#define ABDAY_1 0x20000 +#define ABDAY_2 0x20001 +#define ABDAY_3 0x20002 +#define ABDAY_4 0x20003 +#define ABDAY_5 0x20004 +#define ABDAY_6 0x20005 +#define ABDAY_7 0x20006 +#define ABMON_1 0x2000E +#define ABMON_10 0x20017 +#define ABMON_11 0x20018 +#define ABMON_12 0x20019 +#define ABMON_2 0x2000F +#define ABMON_3 0x20010 +#define ABMON_4 0x20011 +#define ABMON_5 0x20012 +#define ABMON_6 0x20013 +#define ABMON_7 0x20014 +#define ABMON_8 0x20015 +#define ABMON_9 0x20016 +#define ABORT 238 +#define ACK 04 +#define ADD ns_uop_add +#define ADJ_ESTERROR 0x0008 +#define ADJ_FREQUENCY 0x0002 +#define ADJ_MAXERROR 0x0004 +#define ADJ_MICRO 0x1000 +#define ADJ_NANO 0x2000 +#define ADJ_OFFSET 0x0001 +#define ADJ_OFFSET_SINGLESHOT 0x8001 +#define ADJ_OFFSET_SS_READ 0xa001 +#define ADJ_SETOFFSET 0x0100 +#define ADJ_STATUS 0x0010 +#define ADJ_TAI 0x0080 +#define ADJ_TICK 0x4000 +#define ADJ_TIMECONST 0x0020 +#define AF_INET PF_INET +#define AF_INET6 PF_INET6 +#define AF_UNIX 3 +#define AF_UNSPEC PF_UNSPEC +#define ALT_DIGITS 0x2002F +#define AM_STR 0x20026 +#define ANYMARK 0x01 +#define AO 245 +#define AREGTYPE '\0' +#define ARFMAG "`\n" +#define ARG_MAX 131072 +#define ARMAG "!\n" +#define AT_EACCESS (0x0) +#define AT_FDCWD (-2) +#define AT_REMOVEDIR (0x4) +#define AT_SYMLINK_FOLLOW (0x2) +#define AT_SYMLINK_NOFOLLOW (0x1) +#define AUTHTYPE_CNT 5 +#define AUTHTYPE_KERBEROS_V4 1 +#define AUTHTYPE_KERBEROS_V5 2 +#define AUTHTYPE_MINK 4 +#define AUTHTYPE_NAME(x) authtype_names[x] +#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) +#define AUTHTYPE_NULL 0 +#define AUTHTYPE_SPX 3 +#define AUTHTYPE_TEST 99 +#define AUTH_HOW_MASK 2 +#define AUTH_HOW_MUTUAL 2 +#define AUTH_HOW_ONE_WAY 0 +#define AUTH_WHO_CLIENT 0 +#define AUTH_WHO_MASK 1 +#define AUTH_WHO_SERVER 1 +#define AYT 246 +#define BIG_ENDIAN __BIG_ENDIAN +#define BITSPERBYTE CHAR_BIT +#define BLKTYPE '4' +#define BLK_BYTECOUNT 2 +#define BLK_EOF 0x40 +#define BLK_EOR 0x80 +#define BLK_ERRORS 0x20 +#define BLK_RESTART 0x10 +#define BREAK 243 +#define BUFSIZ 1024 +#define BYTE_ORDER __BYTE_ORDER +#define CANBSIZ 255 +#define CBRK CEOL +#define CDISCARD CTRL('o') +#define CDSUSP CTRL('y') +#define CEOF CTRL('d') +#define CEOL '\0' +#define CEOT CEOF +#define CERASE 0177 +#define CFLUSH CDISCARD +#define CHARBITS (sizeof(char) * 8) +#define CHARCLASS_NAME_MAX 14 +#define CHAR_BIT 8 +#define CHAR_MAX 127 +#define CHAR_MIN (-128) +#define CHRTYPE '3' +#define CINTR CTRL('c') +#define CKILL CTRL('u') +#define CLNEXT CTRL('v') +#define CLOCKS_PER_SEC ((clock_t)1000000000) +#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) +#define CLOCK_REALTIME (&_CLOCK_REALTIME) +#define CMIN 1 +#define CMPLX(x,y) __CMPLX(x, y, double) +#define CMPLXF(x,y) __CMPLX(x, y, float) +#define CMPLXL(x,y) __CMPLX(x, y, long double) +#define CODESET 14 +#define COLL_WEIGHTS_MAX 2 +#define COMPLETE 2 +#define CONTINUE 3 +#define CONTTYPE '7' +#define CQUIT 034 +#define CREPRINT CTRL('r') +#define CRNCYSTR 0x4000F +#define CRPRNT CREPRINT +#define CSTART CTRL('q') +#define CSTATUS '\0' +#define CSTOP CTRL('s') +#define CSUSP CTRL('z') +#define CTIME 0 +#define CTRL(x) ((x)&037) +#define CWERASE CTRL('w') +#define C_ANY ns_c_any +#define C_CHAOS ns_c_chaos +#define C_HS ns_c_hs +#define C_IN ns_c_in +#define C_IRGRP 000040 +#define C_IROTH 000004 +#define C_IRUSR 000400 +#define C_ISBLK 060000 +#define C_ISCHR 020000 +#define C_ISCTG 0110000 +#define C_ISDIR 040000 +#define C_ISFIFO 010000 +#define C_ISGID 002000 +#define C_ISLNK 0120000 +#define C_ISREG 0100000 +#define C_ISSOCK 0140000 +#define C_ISUID 004000 +#define C_ISVTX 001000 +#define C_IWGRP 000020 +#define C_IWOTH 000002 +#define C_IWUSR 000200 +#define C_IXGRP 000010 +#define C_IXOTH 000001 +#define C_IXUSR 000100 +#define C_NONE ns_c_none +#define DATA 03 +#define DAY_1 0x20007 +#define DAY_2 0x20008 +#define DAY_3 0x20009 +#define DAY_4 0x2000A +#define DAY_5 0x2000B +#define DAY_6 0x2000C +#define DAY_7 0x2000D +#define DBL_DECIMAL_DIG 17 +#define DBL_DIG 15 +#define DBL_EPSILON 2.22044604925031308085e-16 +#define DBL_HAS_SUBNORM 1 +#define DBL_MANT_DIG 53 +#define DBL_MAX 1.79769313486231570815e+308 +#define DBL_MAX_10_EXP 308 +#define DBL_MAX_EXP 1024 +#define DBL_MIN 2.22507385850720138309e-308 +#define DBL_MIN_10_EXP (-307) +#define DBL_MIN_EXP (-1021) +#define DBL_TRUE_MIN 4.94065645841246544177e-324 +#define DECIMAL_DIG 36 +#define DELAYTIMER_MAX 0x7fffffff +#define DELETE ns_uop_delete +#define DEV_BSIZE 512 +#define DIRTYPE '5' +#define DM 242 +#define DMAXEXP DBL_MAX_EXP +#define DMINEXP DBL_MIN_EXP +#define DO 253 +#define DONT 254 +#define DOUBLEBITS (sizeof(double) * 8) +#define DTTOIF(x) (__wasilibc_dttoif(x)) +#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE +#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE +#define DT_DIR __WASI_FILETYPE_DIRECTORY +#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM +#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK +#define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_SOCK 20 +#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN +#define D_FMT 0x20029 +#define D_T_FMT 0x20028 +#define E2BIG __WASI_ERRNO_2BIG +#define EACCES __WASI_ERRNO_ACCES +#define EACCESS 2 +#define EADDRINUSE __WASI_ERRNO_ADDRINUSE +#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL +#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT +#define EAGAIN __WASI_ERRNO_AGAIN +#define EALREADY __WASI_ERRNO_ALREADY +#define EBADF __WASI_ERRNO_BADF +#define EBADID 5 +#define EBADMSG __WASI_ERRNO_BADMSG +#define EBADOP 4 +#define EBUSY __WASI_ERRNO_BUSY +#define EC 247 +#define ECANCELED __WASI_ERRNO_CANCELED +#define ECHILD __WASI_ERRNO_CHILD +#define ECONNABORTED __WASI_ERRNO_CONNABORTED +#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED +#define ECONNRESET __WASI_ERRNO_CONNRESET +#define EDEADLK __WASI_ERRNO_DEADLK +#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ +#define EDOM __WASI_ERRNO_DOM +#define EDQUOT __WASI_ERRNO_DQUOT +#define EEXIST __WASI_ERRNO_EXIST +#define EEXISTS 6 +#define EFAULT __WASI_ERRNO_FAULT +#define EFBIG __WASI_ERRNO_FBIG +#define EFD_CLOEXEC O_CLOEXEC +#define EFD_NONBLOCK O_NONBLOCK +#define EFD_SEMAPHORE 1 +#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH +#define EIDRM __WASI_ERRNO_IDRM +#define EILSEQ __WASI_ERRNO_ILSEQ +#define EINPROGRESS __WASI_ERRNO_INPROGRESS +#define EINTR __WASI_ERRNO_INTR +#define EINVAL __WASI_ERRNO_INVAL +#define EIO __WASI_ERRNO_IO +#define EISCONN __WASI_ERRNO_ISCONN +#define EISDIR __WASI_ERRNO_ISDIR +#define EL 248 +#define ELOOP __WASI_ERRNO_LOOP +#define EMFILE __WASI_ERRNO_MFILE +#define EMLINK __WASI_ERRNO_MLINK +#define EMSGSIZE __WASI_ERRNO_MSGSIZE +#define EMULTIHOP __WASI_ERRNO_MULTIHOP +#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG +#define ENCRYPT_CNT 9 +#define ENCRYPT_DEC_KEYID 8 +#define ENCRYPT_ENC_KEYID 7 +#define ENCRYPT_END 4 +#define ENCRYPT_IS 0 +#define ENCRYPT_NAME(x) encrypt_names[x] +#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) +#define ENCRYPT_REPLY 2 +#define ENCRYPT_REQEND 6 +#define ENCRYPT_REQSTART 5 +#define ENCRYPT_START 3 +#define ENCRYPT_SUPPORT 1 +#define ENCTYPE_ANY 0 +#define ENCTYPE_CNT 3 +#define ENCTYPE_DES_CFB64 1 +#define ENCTYPE_DES_OFB64 2 +#define ENCTYPE_NAME(x) enctype_names[x] +#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) +#define ENETDOWN __WASI_ERRNO_NETDOWN +#define ENETRESET __WASI_ERRNO_NETRESET +#define ENETUNREACH __WASI_ERRNO_NETUNREACH +#define ENFILE __WASI_ERRNO_NFILE +#define ENOBUFS __WASI_ERRNO_NOBUFS +#define ENODEV __WASI_ERRNO_NODEV +#define ENOENT __WASI_ERRNO_NOENT +#define ENOEXEC __WASI_ERRNO_NOEXEC +#define ENOLCK __WASI_ERRNO_NOLCK +#define ENOLINK __WASI_ERRNO_NOLINK +#define ENOMEM __WASI_ERRNO_NOMEM +#define ENOMSG __WASI_ERRNO_NOMSG +#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT +#define ENOSPACE 3 +#define ENOSPC __WASI_ERRNO_NOSPC +#define ENOSYS __WASI_ERRNO_NOSYS +#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE +#define ENOTCONN __WASI_ERRNO_NOTCONN +#define ENOTDIR __WASI_ERRNO_NOTDIR +#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY +#define ENOTFOUND 1 +#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE +#define ENOTSOCK __WASI_ERRNO_NOTSOCK +#define ENOTSUP __WASI_ERRNO_NOTSUP +#define ENOTTY __WASI_ERRNO_NOTTY +#define ENOUSER 7 +#define ENV_ESC 2 +#define ENV_USERVAR 3 +#define ENXIO __WASI_ERRNO_NXIO +#define EOF (-1) +#define EOPNOTSUPP ENOTSUP +#define EOR 239 +#define EOVERFLOW __WASI_ERRNO_OVERFLOW +#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD +#define EPERM __WASI_ERRNO_PERM +#define EPIPE __WASI_ERRNO_PIPE +#define EPROTO __WASI_ERRNO_PROTO +#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT +#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE +#define ERA 0x2002C +#define ERANGE __WASI_ERRNO_RANGE +#define ERA_D_FMT 0x2002E +#define ERA_D_T_FMT 0x20030 +#define ERA_T_FMT 0x20031 +#define EROFS __WASI_ERRNO_ROFS +#define ERROR 05 +#define ESPIPE __WASI_ERRNO_SPIPE +#define ESRCH __WASI_ERRNO_SRCH +#define ESTALE __WASI_ERRNO_STALE +#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT +#define ETXTBSY __WASI_ERRNO_TXTBSY +#define EUNDEF 0 +#define EWOULDBLOCK EAGAIN +#define EXDEV __WASI_ERRNO_XDEV +#define EXIT_FAILURE 1 +#define EXIT_SUCCESS 0 +#define EX_CANTCREAT 73 +#define EX_CONFIG 78 +#define EX_DATAERR 65 +#define EX_IOERR 74 +#define EX_NOHOST 68 +#define EX_NOINPUT 66 +#define EX_NOPERM 77 +#define EX_NOUSER 67 +#define EX_OK 0 +#define EX_OSERR 71 +#define EX_OSFILE 72 +#define EX_PROTOCOL 76 +#define EX_SOFTWARE 70 +#define EX_TEMPFAIL 75 +#define EX_UNAVAILABLE 69 +#define EX_USAGE 64 +#define EX__BASE 64 +#define EX__MAX 78 +#define FD_CLOEXEC (1) +#define FD_CLR(fd,set) (FD_CLR((fd), (set))) +#define FD_COPY(from,to) (FD_COPY((from), (to))) +#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) +#define FD_SET(fd,set) (FD_SET((fd), (set))) +#define FD_SETSIZE 1024 +#define FD_ZERO(set) (FD_ZERO((set))) +#define FE_ALL_EXCEPT 0 +#define FE_DFL_ENV ((const fenv_t *) -1) +#define FE_TONEAREST 0 +#define FIFOTYPE '6' +#define FILENAME_MAX 4096 +#define FILESIZEBITS 64 +#define FIONBIO 2 +#define FIONREAD 1 +#define FLOATBITS (sizeof(float) * 8) +#define FLT_DECIMAL_DIG 9 +#define FLT_DIG 6 +#define FLT_EPSILON 1.1920928955078125e-07F +#define FLT_EVAL_METHOD 0 +#define FLT_HAS_SUBNORM 1 +#define FLT_MANT_DIG 24 +#define FLT_MAX 3.40282346638528859812e+38F +#define FLT_MAX_10_EXP 38 +#define FLT_MAX_EXP 128 +#define FLT_MIN 1.17549435082228750797e-38F +#define FLT_MIN_10_EXP (-37) +#define FLT_MIN_EXP (-125) +#define FLT_RADIX 2 +#define FLT_ROUNDS (__builtin_flt_rounds()) +#define FLT_TRUE_MIN 1.40129846432481707092e-45F +#define FLUSHBAND 0x04 +#define FLUSHR 0x01 +#define FLUSHRW 0x03 +#define FLUSHW 0x02 +#define FMAXEXP FLT_MAX_EXP +#define FMINEXP FLT_MIN_EXP +#define FMNAMESZ 8 +#define FNM_CASEFOLD 0x10 +#define FNM_FILE_NAME FNM_PATHNAME +#define FNM_LEADING_DIR 0x8 +#define FNM_NOESCAPE 0x2 +#define FNM_NOMATCH 1 +#define FNM_NOSYS (-1) +#define FNM_PATHNAME 0x1 +#define FNM_PERIOD 0x4 +#define FOPEN_MAX 1000 +#define FORMERR ns_r_formerr +#define FORM_C 3 +#define FORM_N 1 +#define FORM_T 2 +#define FP_ILOGB0 FP_ILOGBNAN +#define FP_ILOGBNAN (-1-0x7fffffff) +#define FP_INFINITE 1 +#define FP_NAN 0 +#define FP_NORMAL 4 +#define FP_SUBNORMAL 3 +#define FP_ZERO 2 +#define FSETLOCKING_BYCALLER 2 +#define FSETLOCKING_INTERNAL 1 +#define FSETLOCKING_QUERY 0 +#define FTW_CHDIR 4 +#define FTW_D 2 +#define FTW_DEPTH 8 +#define FTW_DNR 3 +#define FTW_DP 6 +#define FTW_F 1 +#define FTW_MOUNT 2 +#define FTW_NS 4 +#define FTW_PHYS 1 +#define FTW_SL 5 +#define FTW_SLN 7 +#define F_GETFD (1) +#define F_GETFL (3) +#define F_LOCK 1 +#define F_OK (0) +#define F_SETFD (2) +#define F_SETFL (4) +#define F_TEST 3 +#define F_TLOCK 2 +#define F_ULOCK 0 +#define GA 249 +#define GETLONG NS_GET32 +#define GETSHORT NS_GET16 +#define GLOB_ABORTED 2 +#define GLOB_APPEND 0x20 +#define GLOB_DOOFFS 0x08 +#define GLOB_ERR 0x01 +#define GLOB_MARK 0x02 +#define GLOB_NOCHECK 0x10 +#define GLOB_NOESCAPE 0x40 +#define GLOB_NOMATCH 3 +#define GLOB_NOSORT 0x04 +#define GLOB_NOSPACE 1 +#define GLOB_NOSYS 4 +#define GLOB_PERIOD 0x80 +#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) +#define HFIXEDSZ NS_HFIXEDSZ +#define HIBITL MINLONG +#define HIBITS MINSHORT +#define HOST_NAME_MAX 255 +#define HUGE 3.40282346638528859812e+38F +#define HUGE_VAL ((double)INFINITY) +#define HUGE_VALF INFINITY +#define HUGE_VALL ((long double)INFINITY) +#define I _Complex_I +#define IAC 255 +#define ICMP6_DST_UNREACH 1 +#define ICMP6_DST_UNREACH_ADDR 3 +#define ICMP6_DST_UNREACH_ADMIN 1 +#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 +#define ICMP6_DST_UNREACH_NOPORT 4 +#define ICMP6_DST_UNREACH_NOROUTE 0 +#define ICMP6_ECHO_REPLY 129 +#define ICMP6_ECHO_REQUEST 128 +#define ICMP6_FILTER 1 +#define ICMP6_FILTER_BLOCK 1 +#define ICMP6_FILTER_BLOCKOTHERS 3 +#define ICMP6_FILTER_PASS 2 +#define ICMP6_FILTER_PASSONLY 4 +#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) +#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) +#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) +#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) +#define ICMP6_INFOMSG_MASK 0x80 +#define ICMP6_PACKET_TOO_BIG 2 +#define ICMP6_PARAMPROB_HEADER 0 +#define ICMP6_PARAMPROB_NEXTHEADER 1 +#define ICMP6_PARAMPROB_OPTION 2 +#define ICMP6_PARAM_PROB 4 +#define ICMP6_ROUTER_RENUMBERING 138 +#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 +#define ICMP6_RR_FLAGS_PREVDONE 0x08 +#define ICMP6_RR_FLAGS_REQRESULT 0x40 +#define ICMP6_RR_FLAGS_SPECSITE 0x10 +#define ICMP6_RR_FLAGS_TEST 0x80 +#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 +#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 +#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 +#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 +#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 +#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 +#define ICMP6_TIME_EXCEEDED 3 +#define ICMP6_TIME_EXCEED_REASSEMBLY 1 +#define ICMP6_TIME_EXCEED_TRANSIT 0 +#define ICMP_ADDRESS 17 +#define ICMP_ADDRESSREPLY 18 +#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) +#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) +#define ICMP_DEST_UNREACH 3 +#define ICMP_ECHO 8 +#define ICMP_ECHOREPLY 0 +#define ICMP_EXC_FRAGTIME 1 +#define ICMP_EXC_TTL 0 +#define ICMP_FRAG_NEEDED 4 +#define ICMP_HOST_ANO 10 +#define ICMP_HOST_ISOLATED 8 +#define ICMP_HOST_UNKNOWN 7 +#define ICMP_HOST_UNREACH 1 +#define ICMP_HOST_UNR_TOS 12 +#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) +#define ICMP_INFO_REPLY 16 +#define ICMP_INFO_REQUEST 15 +#define ICMP_IREQ 15 +#define ICMP_IREQREPLY 16 +#define ICMP_MASKLEN 12 +#define ICMP_MASKREPLY 18 +#define ICMP_MASKREQ 17 +#define ICMP_MAXTYPE 18 +#define ICMP_MINLEN 8 +#define ICMP_NET_ANO 9 +#define ICMP_NET_UNKNOWN 6 +#define ICMP_NET_UNREACH 0 +#define ICMP_NET_UNR_TOS 11 +#define ICMP_PARAMETERPROB 12 +#define ICMP_PARAMPROB 12 +#define ICMP_PARAMPROB_OPTABSENT 1 +#define ICMP_PKT_FILTERED 13 +#define ICMP_PORT_UNREACH 3 +#define ICMP_PREC_CUTOFF 15 +#define ICMP_PREC_VIOLATION 14 +#define ICMP_PROT_UNREACH 2 +#define ICMP_REDIRECT 5 +#define ICMP_REDIRECT_HOST 1 +#define ICMP_REDIRECT_NET 0 +#define ICMP_REDIRECT_TOSHOST 3 +#define ICMP_REDIRECT_TOSNET 2 +#define ICMP_REDIR_HOST 1 +#define ICMP_REDIR_HOSTTOS 3 +#define ICMP_REDIR_NET 0 +#define ICMP_REDIR_NETTOS 2 +#define ICMP_ROUTERADVERT 9 +#define ICMP_ROUTERSOLICIT 10 +#define ICMP_SOURCEQUENCH 4 +#define ICMP_SOURCE_QUENCH 4 +#define ICMP_SR_FAILED 5 +#define ICMP_TIMESTAMP 13 +#define ICMP_TIMESTAMPREPLY 14 +#define ICMP_TIME_EXCEEDED 11 +#define ICMP_TIMXCEED 11 +#define ICMP_TIMXCEED_INTRANS 0 +#define ICMP_TIMXCEED_REASS 1 +#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) +#define ICMP_TSTAMP 13 +#define ICMP_TSTAMPREPLY 14 +#define ICMP_UNREACH 3 +#define ICMP_UNREACH_FILTER_PROHIB 13 +#define ICMP_UNREACH_HOST 1 +#define ICMP_UNREACH_HOST_PRECEDENCE 14 +#define ICMP_UNREACH_HOST_PROHIB 10 +#define ICMP_UNREACH_HOST_UNKNOWN 7 +#define ICMP_UNREACH_ISOLATED 8 +#define ICMP_UNREACH_NEEDFRAG 4 +#define ICMP_UNREACH_NET 0 +#define ICMP_UNREACH_NET_PROHIB 9 +#define ICMP_UNREACH_NET_UNKNOWN 6 +#define ICMP_UNREACH_PORT 3 +#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 +#define ICMP_UNREACH_PROTOCOL 2 +#define ICMP_UNREACH_SRCFAIL 5 +#define ICMP_UNREACH_TOSHOST 12 +#define ICMP_UNREACH_TOSNET 11 +#define IFTODT(x) (__wasilibc_iftodt(x)) +#define IGMP_AWAKENING_MEMBER 5 +#define IGMP_DELAYING_MEMBER 1 +#define IGMP_DVMRP 0x13 +#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP +#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY +#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT +#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT +#define IGMP_IDLE_MEMBER 2 +#define IGMP_LAZY_MEMBER 3 +#define IGMP_MAX_HOST_REPORT_DELAY 10 +#define IGMP_MEMBERSHIP_QUERY 0x11 +#define IGMP_MINLEN 8 +#define IGMP_MTRACE 0x1f +#define IGMP_MTRACE_RESP 0x1e +#define IGMP_PIM 0x14 +#define IGMP_SLEEPING_MEMBER 4 +#define IGMP_TIMER_SCALE 10 +#define IGMP_TRACE 0x15 +#define IGMP_V1_MEMBERSHIP_REPORT 0x12 +#define IGMP_V2_LEAVE_GROUP 0x17 +#define IGMP_V2_MEMBERSHIP_REPORT 0x16 +#define IGMP_v1_ROUTER 1 +#define IGMP_v2_ROUTER 2 +#define IN6ADDRSZ NS_IN6ADDRSZ +#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } +#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } +#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) +#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) +#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) +#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) +#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) +#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) +#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) +#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) +#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) +#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) +#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) +#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) +#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) +#define INADDRSZ NS_INADDRSZ +#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) +#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) +#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) +#define INADDR_ANY ((in_addr_t) 0x00000000) +#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) +#define INADDR_DUMMY ((in_addr_t) 0xc0000008) +#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) +#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) +#define INADDR_NONE ((in_addr_t) 0xffffffff) +#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) +#define INDIR_MASK NS_CMPRSFLGS +#define INET6_ADDRSTRLEN 46 +#define INET_ADDRSTRLEN 16 +#define INFINITY 1e5000f +#define INT16SZ NS_INT16SZ +#define INT16_C(c) c +#define INT16_MAX (0x7fff) +#define INT16_MIN (-1-0x7fff) +#define INT32SZ NS_INT32SZ +#define INT32_C(c) c +#define INT32_MAX (0x7fffffff) +#define INT32_MIN (-1-0x7fffffff) +#define INT64_C(c) c ## LL +#define INT64_MAX (0x7fffffffffffffff) +#define INT64_MIN (-1-0x7fffffffffffffff) +#define INT8SZ NS_INT8SZ +#define INT8_C(c) c +#define INT8_MAX (0x7f) +#define INT8_MIN (-1-0x7f) +#define INTBITS (sizeof(int) * 8) +#define INTMAX_C(c) c ## LL +#define INTMAX_MAX INT64_MAX +#define INTMAX_MIN INT64_MIN +#define INTPTR_MAX INT32_MAX +#define INTPTR_MIN INT32_MIN +#define INT_FAST16_MAX INT16_MAX +#define INT_FAST16_MIN INT16_MIN +#define INT_FAST32_MAX INT32_MAX +#define INT_FAST32_MIN INT32_MIN +#define INT_FAST64_MAX INT64_MAX +#define INT_FAST64_MIN INT64_MIN +#define INT_FAST8_MAX INT8_MAX +#define INT_FAST8_MIN INT8_MIN +#define INT_LEAST16_MAX INT16_MAX +#define INT_LEAST16_MIN INT16_MIN +#define INT_LEAST32_MAX INT32_MAX +#define INT_LEAST32_MIN INT32_MIN +#define INT_LEAST64_MAX INT64_MAX +#define INT_LEAST64_MIN INT64_MIN +#define INT_LEAST8_MAX INT8_MAX +#define INT_LEAST8_MIN INT8_MIN +#define INT_MAX 0x7fffffff +#define INT_MIN (-1-0x7fffffff) +#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) +#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) +#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) +#define IN_CLASSA_MAX 128 +#define IN_CLASSA_NET 0xff000000 +#define IN_CLASSA_NSHIFT 24 +#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) +#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) +#define IN_CLASSB_MAX 65536 +#define IN_CLASSB_NET 0xffff0000 +#define IN_CLASSB_NSHIFT 16 +#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) +#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) +#define IN_CLASSC_NET 0xffffff00 +#define IN_CLASSC_NSHIFT 8 +#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) +#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) +#define IN_LOOPBACKNET 127 +#define IN_MULTICAST(a) IN_CLASSD(a) +#define IOV_MAX 1024 +#define IP 244 +#define IP6F_MORE_FRAG 0x0100 +#define IP6F_OFF_MASK 0xf8ff +#define IP6F_RESERVED_MASK 0x0600 +#define IP6OPT_JUMBO 0xc2 +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_NSAP_ADDR 0xc3 +#define IP6OPT_PAD1 0 +#define IP6OPT_PADN 1 +#define IP6OPT_ROUTER_ALERT 0x05 +#define IP6OPT_TUNNEL_LIMIT 0x04 +#define IP6OPT_TYPE(o) ((o) & 0xc0) +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xc0 +#define IP6OPT_TYPE_MUTABLE 0x20 +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6_ALERT_AN 0x0200 +#define IP6_ALERT_MLD 0x0000 +#define IP6_ALERT_RSVP 0x0100 +#define IPDEFTTL 64 +#define IPFRAGTTL 60 +#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) +#define IPOPT_CLASS_MASK 0x60 +#define IPOPT_CONTROL 0x00 +#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) +#define IPOPT_COPY 0x80 +#define IPOPT_DEBMEAS 0x40 +#define IPOPT_END IPOPT_EOL +#define IPOPT_EOL 0 +#define IPOPT_LSRR 131 +#define IPOPT_MEASUREMENT IPOPT_DEBMEAS +#define IPOPT_MINOFF 4 +#define IPOPT_NOOP IPOPT_NOP +#define IPOPT_NOP 1 +#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) +#define IPOPT_NUMBER_MASK 0x1f +#define IPOPT_OFFSET 2 +#define IPOPT_OLEN 1 +#define IPOPT_OPTVAL 0 +#define IPOPT_RA 148 +#define IPOPT_RESERVED1 0x20 +#define IPOPT_RESERVED2 0x60 +#define IPOPT_RR 7 +#define IPOPT_SATID 136 +#define IPOPT_SEC IPOPT_SECURITY +#define IPOPT_SECURITY 130 +#define IPOPT_SECUR_CONFID 0xf135 +#define IPOPT_SECUR_EFTO 0x789a +#define IPOPT_SECUR_MMMM 0xbc4d +#define IPOPT_SECUR_RESTR 0xaf13 +#define IPOPT_SECUR_SECRET 0xd788 +#define IPOPT_SECUR_TOPSECRET 0x6bc5 +#define IPOPT_SECUR_UNCLASS 0x0000 +#define IPOPT_SID IPOPT_SATID +#define IPOPT_SSRR 137 +#define IPOPT_TIMESTAMP IPOPT_TS +#define IPOPT_TS 68 +#define IPOPT_TS_PRESPEC 3 +#define IPOPT_TS_TSANDADDR 1 +#define IPOPT_TS_TSONLY 0 +#define IPPORT_RESERVED 1024 +#define IPPROTO_ICMP 1 +#define IPPROTO_IP 0 +#define IPPROTO_IPV6 41 +#define IPPROTO_RAW 255 +#define IPPROTO_TCP 6 +#define IPPROTO_UDP 17 +#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) +#define IPTOS_CLASS_CS0 0x00 +#define IPTOS_CLASS_CS1 0x20 +#define IPTOS_CLASS_CS2 0x40 +#define IPTOS_CLASS_CS3 0x60 +#define IPTOS_CLASS_CS4 0x80 +#define IPTOS_CLASS_CS5 0xa0 +#define IPTOS_CLASS_CS6 0xc0 +#define IPTOS_CLASS_CS7 0xe0 +#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 +#define IPTOS_CLASS_MASK 0xe0 +#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) +#define IPTOS_DSCP_AF11 0x28 +#define IPTOS_DSCP_AF12 0x30 +#define IPTOS_DSCP_AF13 0x38 +#define IPTOS_DSCP_AF21 0x48 +#define IPTOS_DSCP_AF22 0x50 +#define IPTOS_DSCP_AF23 0x58 +#define IPTOS_DSCP_AF31 0x68 +#define IPTOS_DSCP_AF32 0x70 +#define IPTOS_DSCP_AF33 0x78 +#define IPTOS_DSCP_AF41 0x88 +#define IPTOS_DSCP_AF42 0x90 +#define IPTOS_DSCP_AF43 0x98 +#define IPTOS_DSCP_EF 0xb8 +#define IPTOS_DSCP_MASK 0xfc +#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) +#define IPTOS_ECN_CE 0x03 +#define IPTOS_ECN_ECT0 0x02 +#define IPTOS_ECN_ECT1 0x01 +#define IPTOS_ECN_MASK 0x03 +#define IPTOS_ECN_NOT_ECT 0x00 +#define IPTOS_LOWCOST 0x02 +#define IPTOS_LOWDELAY 0x10 +#define IPTOS_MINCOST IPTOS_LOWCOST +#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) +#define IPTOS_PREC_CRITIC_ECP 0xa0 +#define IPTOS_PREC_FLASH 0x60 +#define IPTOS_PREC_FLASHOVERRIDE 0x80 +#define IPTOS_PREC_IMMEDIATE 0x40 +#define IPTOS_PREC_INTERNETCONTROL 0xc0 +#define IPTOS_PREC_MASK 0xe0 +#define IPTOS_PREC_NETCONTROL 0xe0 +#define IPTOS_PREC_PRIORITY 0x20 +#define IPTOS_PREC_ROUTINE 0x00 +#define IPTOS_RELIABILITY 0x04 +#define IPTOS_THROUGHPUT 0x08 +#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) +#define IPTOS_TOS_MASK 0x1E +#define IPTTLDEC 1 +#define IPV6_2292DSTOPTS 4 +#define IPV6_2292HOPLIMIT 8 +#define IPV6_2292HOPOPTS 3 +#define IPV6_2292PKTINFO 2 +#define IPV6_2292PKTOPTIONS 6 +#define IPV6_2292RTHDR 5 +#define IPV6_ADDRFORM 1 +#define IPV6_ADDR_PREFERENCES 72 +#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP +#define IPV6_AUTHHDR 10 +#define IPV6_AUTOFLOWLABEL 70 +#define IPV6_CHECKSUM 7 +#define IPV6_DONTFRAG 62 +#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP +#define IPV6_DSTOPTS 59 +#define IPV6_FREEBIND 78 +#define IPV6_HDRINCL 36 +#define IPV6_HOPLIMIT 52 +#define IPV6_HOPOPTS 54 +#define IPV6_IPSEC_POLICY 34 +#define IPV6_JOIN_ANYCAST 27 +#define IPV6_JOIN_GROUP 20 +#define IPV6_LEAVE_ANYCAST 28 +#define IPV6_LEAVE_GROUP 21 +#define IPV6_MINHOPCOUNT 73 +#define IPV6_MTU 24 +#define IPV6_MTU_DISCOVER 23 +#define IPV6_MULTICAST_ALL 29 +#define IPV6_MULTICAST_HOPS 18 +#define IPV6_MULTICAST_IF 17 +#define IPV6_MULTICAST_LOOP 19 +#define IPV6_NEXTHOP 9 +#define IPV6_ORIGDSTADDR 74 +#define IPV6_PATHMTU 61 +#define IPV6_PKTINFO 50 +#define IPV6_PMTUDISC_DO 2 +#define IPV6_PMTUDISC_DONT 0 +#define IPV6_PMTUDISC_INTERFACE 4 +#define IPV6_PMTUDISC_OMIT 5 +#define IPV6_PMTUDISC_PROBE 3 +#define IPV6_PMTUDISC_WANT 1 +#define IPV6_PREFER_SRC_CGA 0x0008 +#define IPV6_PREFER_SRC_COA 0x0004 +#define IPV6_PREFER_SRC_HOME 0x0400 +#define IPV6_PREFER_SRC_NONCGA 0x0800 +#define IPV6_PREFER_SRC_PUBLIC 0x0002 +#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 +#define IPV6_PREFER_SRC_TMP 0x0001 +#define IPV6_RECVDSTOPTS 58 +#define IPV6_RECVERR 25 +#define IPV6_RECVFRAGSIZE 77 +#define IPV6_RECVHOPLIMIT 51 +#define IPV6_RECVHOPOPTS 53 +#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR +#define IPV6_RECVPATHMTU 60 +#define IPV6_RECVPKTINFO 49 +#define IPV6_RECVRTHDR 56 +#define IPV6_RECVTCLASS 66 +#define IPV6_ROUTER_ALERT 22 +#define IPV6_ROUTER_ALERT_ISOLATE 30 +#define IPV6_RTHDR 57 +#define IPV6_RTHDRDSTOPTS 55 +#define IPV6_RTHDR_LOOSE 0 +#define IPV6_RTHDR_STRICT 1 +#define IPV6_RTHDR_TYPE_0 0 +#define IPV6_RXDSTOPTS IPV6_DSTOPTS +#define IPV6_RXHOPOPTS IPV6_HOPOPTS +#define IPV6_TCLASS 67 +#define IPV6_TRANSPARENT 75 +#define IPV6_UNICAST_HOPS 16 +#define IPV6_UNICAST_IF 76 +#define IPV6_V6ONLY 26 +#define IPV6_XFRM_POLICY 35 +#define IPVERSION 4 +#define IP_ADD_MEMBERSHIP 35 +#define IP_ADD_SOURCE_MEMBERSHIP 39 +#define IP_BIND_ADDRESS_NO_PORT 24 +#define IP_BLOCK_SOURCE 38 +#define IP_CHECKSUM 23 +#define IP_DEFAULT_MULTICAST_LOOP 1 +#define IP_DEFAULT_MULTICAST_TTL 1 +#define IP_DF 0x4000 +#define IP_DROP_MEMBERSHIP 36 +#define IP_DROP_SOURCE_MEMBERSHIP 40 +#define IP_FREEBIND 15 +#define IP_HDRINCL 3 +#define IP_IPSEC_POLICY 16 +#define IP_MAXPACKET 65535 +#define IP_MAX_MEMBERSHIPS 20 +#define IP_MF 0x2000 +#define IP_MINTTL 21 +#define IP_MSFILTER 41 +#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) +#define IP_MSS 576 +#define IP_MTU 14 +#define IP_MTU_DISCOVER 10 +#define IP_MULTICAST_ALL 49 +#define IP_MULTICAST_IF 32 +#define IP_MULTICAST_LOOP 34 +#define IP_MULTICAST_TTL 33 +#define IP_NODEFRAG 22 +#define IP_OFFMASK 0x1fff +#define IP_OPTIONS 4 +#define IP_ORIGDSTADDR 20 +#define IP_PASSSEC 18 +#define IP_PKTINFO 8 +#define IP_PKTOPTIONS 9 +#define IP_PMTUDISC 10 +#define IP_PMTUDISC_DO 2 +#define IP_PMTUDISC_DONT 0 +#define IP_PMTUDISC_INTERFACE 4 +#define IP_PMTUDISC_OMIT 5 +#define IP_PMTUDISC_PROBE 3 +#define IP_PMTUDISC_WANT 1 +#define IP_RECVERR 11 +#define IP_RECVERR_RFC4884 26 +#define IP_RECVFRAGSIZE 25 +#define IP_RECVOPTS 6 +#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR +#define IP_RECVRETOPTS IP_RETOPTS +#define IP_RECVTOS 13 +#define IP_RECVTTL 12 +#define IP_RETOPTS 7 +#define IP_RF 0x8000 +#define IP_ROUTER_ALERT 5 +#define IP_TOS 1 +#define IP_TRANSPARENT 19 +#define IP_TTL 2 +#define IP_UNBLOCK_SOURCE 37 +#define IP_UNICAST_IF 50 +#define IP_XFRM_POLICY 17 +#define IQUERY ns_o_iquery +#define I_ATMARK (__SID |31) +#define I_CANPUT (__SID |34) +#define I_CKBAND (__SID |29) +#define I_FDINSERT (__SID |16) +#define I_FIND (__SID |11) +#define I_FLUSH (__SID | 5) +#define I_FLUSHBAND (__SID |28) +#define I_GETBAND (__SID |30) +#define I_GETCLTIME (__SID |33) +#define I_GETSIG (__SID |10) +#define I_GRDOPT (__SID | 7) +#define I_GWROPT (__SID |20) +#define I_LINK (__SID |12) +#define I_LIST (__SID |21) +#define I_LOOK (__SID | 4) +#define I_NREAD (__SID | 1) +#define I_PEEK (__SID |15) +#define I_PLINK (__SID |22) +#define I_POP (__SID | 3) +#define I_PUNLINK (__SID |23) +#define I_PUSH (__SID | 2) +#define I_RECVFD (__SID |14) +#define I_SENDFD (__SID |17) +#define I_SETCLTIME (__SID |32) +#define I_SETSIG (__SID | 9) +#define I_SRDOPT (__SID | 6) +#define I_STR (__SID | 8) +#define I_SWROPT (__SID |19) +#define I_UNLINK (__SID |13) +#define LASTMARK 0x02 +#define LC_ALL 6 +#define LC_ALL_MASK 0x7fffffff +#define LC_COLLATE 3 +#define LC_COLLATE_MASK (1<(b))?(a):(b)) +#define MAXCDNAME NS_MAXCDNAME +#define MAXDNAME NS_MAXDNAME +#define MAXDOUBLE DBL_MAX +#define MAXFLOAT FLT_MAX +#define MAXHOSTNAMELEN 64 +#define MAXINT INT_MAX +#define MAXLABEL NS_MAXLABEL +#define MAXLONG LONG_MAX +#define MAXNAMLEN 255 +#define MAXPATHLEN 4096 +#define MAXSHORT SHRT_MAX +#define MAXSYMLINKS 20 +#define MAXTC 6 +#define MAXTTL 255 +#define MAX_IPOPTLEN 40 +#define MB_CUR_MAX (__ctype_get_mb_cur_max()) +#define MB_LEN_MAX 4 +#define MCAST_BLOCK_SOURCE 43 +#define MCAST_EXCLUDE 0 +#define MCAST_INCLUDE 1 +#define MCAST_JOIN_GROUP 42 +#define MCAST_JOIN_SOURCE_GROUP 46 +#define MCAST_LEAVE_GROUP 45 +#define MCAST_LEAVE_SOURCE_GROUP 47 +#define MCAST_MSFILTER 48 +#define MCAST_UNBLOCK_SOURCE 44 +#define MIN(a,b) (((a)<(b))?(a):(b)) +#define MINDOUBLE DBL_MIN +#define MINFLOAT FLT_MIN +#define MININT INT_MIN +#define MINLONG LONG_MIN +#define MINSHORT SHRT_MIN +#define MLD_LISTENER_QUERY 130 +#define MLD_LISTENER_REDUCTION 132 +#define MLD_LISTENER_REPORT 131 +#define MM_APPL 8 +#define MM_CONSOLE 512 +#define MM_ERROR 2 +#define MM_FIRM 4 +#define MM_HALT 1 +#define MM_HARD 1 +#define MM_INFO 4 +#define MM_NOCON 4 +#define MM_NOMSG 1 +#define MM_NOSEV 0 +#define MM_NOTOK (-1) +#define MM_NRECOV 128 +#define MM_NULLACT ((char*)0) +#define MM_NULLLBL ((char*)0) +#define MM_NULLMC 0L +#define MM_NULLSEV 0 +#define MM_NULLTAG ((char*)0) +#define MM_NULLTXT ((char*)0) +#define MM_OK 0 +#define MM_OPSYS 32 +#define MM_PRINT 256 +#define MM_RECOVER 64 +#define MM_SOFT 2 +#define MM_UTIL 16 +#define MM_WARNING 3 +#define MODE_ACK 0x04 +#define MODE_B 2 +#define MODE_C 3 +#define MODE_ECHO 0x0200 +#define MODE_EDIT 0x01 +#define MODE_FLOW 0x0100 +#define MODE_FORCE 0x1000 +#define MODE_INBIN 0x0400 +#define MODE_LIT_ECHO 0x10 +#define MODE_MASK 0x1f +#define MODE_OUTBIN 0x0800 +#define MODE_S 1 +#define MODE_SOFT_TAB 0x08 +#define MODE_TRAPSIG 0x02 +#define MOD_CLKA ADJ_OFFSET_SINGLESHOT +#define MOD_CLKB ADJ_TICK +#define MOD_ESTERROR ADJ_ESTERROR +#define MOD_FREQUENCY ADJ_FREQUENCY +#define MOD_MAXERROR ADJ_MAXERROR +#define MOD_MICRO ADJ_MICRO +#define MOD_NANO ADJ_NANO +#define MOD_OFFSET ADJ_OFFSET +#define MOD_STATUS ADJ_STATUS +#define MOD_TAI ADJ_TAI +#define MOD_TIMECONST ADJ_TIMECONST +#define MON_1 0x2001A +#define MON_10 0x20023 +#define MON_11 0x20024 +#define MON_12 0x20025 +#define MON_2 0x2001B +#define MON_3 0x2001C +#define MON_4 0x2001D +#define MON_5 0x2001E +#define MON_6 0x2001F +#define MON_7 0x20020 +#define MON_8 0x20021 +#define MON_9 0x20022 +#define MORECTL 1 +#define MOREDATA 2 +#define MSG_ANY 0x02 +#define MSG_BAND 0x04 +#define MSG_HIPRI 0x01 +#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK +#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED +#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL +#define MUXID_ALL (-1) +#define M_1_PI 0.31830988618379067154 +#define M_2_PI 0.63661977236758134308 +#define M_2_SQRTPI 1.12837916709551257390 +#define M_E 2.7182818284590452354 +#define M_LN10 2.30258509299404568402 +#define M_LN2 0.69314718055994530942 +#define M_LOG10E 0.43429448190325182765 +#define M_LOG2E 1.4426950408889634074 +#define M_PI 3.14159265358979323846 +#define M_PI_2 1.57079632679489661923 +#define M_PI_4 0.78539816339744830962 +#define M_SQRT1_2 0.70710678118654752440 +#define M_SQRT2 1.41421356237309504880 +#define NAMESERVER_PORT NS_DEFAULTPORT +#define NAME_MAX 255 +#define NAN (0.0f/0.0f) +#define NBBY 8 +#define NCARGS 131072 +#define ND_NA_FLAG_OVERRIDE 0x00000020 +#define ND_NA_FLAG_ROUTER 0x00000080 +#define ND_NA_FLAG_SOLICITED 0x00000040 +#define ND_NEIGHBOR_ADVERT 136 +#define ND_NEIGHBOR_SOLICIT 135 +#define ND_OPT_HOME_AGENT_INFO 8 +#define ND_OPT_MTU 5 +#define ND_OPT_PI_FLAG_AUTO 0x40 +#define ND_OPT_PI_FLAG_ONLINK 0x80 +#define ND_OPT_PI_FLAG_RADDR 0x20 +#define ND_OPT_PREFIX_INFORMATION 3 +#define ND_OPT_REDIRECTED_HEADER 4 +#define ND_OPT_RTR_ADV_INTERVAL 7 +#define ND_OPT_SOURCE_LINKADDR 1 +#define ND_OPT_TARGET_LINKADDR 2 +#define ND_RA_FLAG_HOME_AGENT 0x20 +#define ND_RA_FLAG_MANAGED 0x80 +#define ND_RA_FLAG_OTHER 0x40 +#define ND_REDIRECT 137 +#define ND_ROUTER_ADVERT 134 +#define ND_ROUTER_SOLICIT 133 +#define NEW_ENV_VALUE 1 +#define NEW_ENV_VAR 0 +#define NGROUPS 32 +#define NGROUPS_MAX 32 +#define NL_ARGMAX 9 +#define NL_CAT_LOCALE 1 +#define NL_LANGMAX 32 +#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) +#define NL_MSGMAX 32767 +#define NL_NMAX 16 +#define NL_SETD 1 +#define NL_SETMAX 255 +#define NL_TEXTMAX 2048 +#define NOERROR ns_r_noerror +#define NOEXPR 0x50001 +#define NOFILE 256 +#define NOGROUP (-1) +#define NOP 241 +#define NOSTR 0x50003 +#define NOTAUTH ns_r_notauth +#define NOTIMP ns_r_notimpl +#define NOTZONE ns_r_notzone +#define NR_ICMP_TYPES 18 +#define NR_ICMP_UNREACH 15 +#define NSLC 18 +#define NS_ALG_DH 2 +#define NS_ALG_DSA 3 +#define NS_ALG_DSS NS_ALG_DSA +#define NS_ALG_EXPIRE_ONLY 253 +#define NS_ALG_MD5RSA 1 +#define NS_ALG_PRIVATE_OID 254 +#define NS_CMPRSFLGS 0xc0 +#define NS_DEFAULTPORT 53 +#define NS_DSA_MAX_BYTES 405 +#define NS_DSA_MIN_SIZE 213 +#define NS_DSA_SIG_SIZE 41 +#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) +#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) +#define NS_HFIXEDSZ 12 +#define NS_IN6ADDRSZ 16 +#define NS_INADDRSZ 4 +#define NS_INT16SZ 2 +#define NS_INT32SZ 4 +#define NS_INT8SZ 1 +#define NS_KEY_EXTENDED_FLAGS 0x1000 +#define NS_KEY_NAME_ENTITY 0x0200 +#define NS_KEY_NAME_RESERVED 0x0300 +#define NS_KEY_NAME_TYPE 0x0300 +#define NS_KEY_NAME_USER 0x0000 +#define NS_KEY_NAME_ZONE 0x0100 +#define NS_KEY_NO_AUTH 0x8000 +#define NS_KEY_NO_CONF 0x4000 +#define NS_KEY_PROT_ANY 255 +#define NS_KEY_PROT_DNSSEC 3 +#define NS_KEY_PROT_EMAIL 2 +#define NS_KEY_PROT_IPSEC 4 +#define NS_KEY_PROT_TLS 1 +#define NS_KEY_RESERVED10 0x0020 +#define NS_KEY_RESERVED11 0x0010 +#define NS_KEY_RESERVED2 0x2000 +#define NS_KEY_RESERVED4 0x0800 +#define NS_KEY_RESERVED5 0x0400 +#define NS_KEY_RESERVED8 0x0080 +#define NS_KEY_RESERVED9 0x0040 +#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) +#define NS_KEY_RESERVED_BITMASK2 0xFFFF +#define NS_KEY_SIGNATORYMASK 0x000F +#define NS_KEY_TYPEMASK 0xC000 +#define NS_KEY_TYPE_AUTH_CONF 0x0000 +#define NS_KEY_TYPE_AUTH_ONLY 0x4000 +#define NS_KEY_TYPE_CONF_ONLY 0x8000 +#define NS_KEY_TYPE_NO_KEY 0xC000 +#define NS_MAXCDNAME 255 +#define NS_MAXDNAME 1025 +#define NS_MAXLABEL 63 +#define NS_MAXMSG 65535 +#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) +#define NS_MD5RSA_MAX_BITS 4096 +#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) +#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) +#define NS_MD5RSA_MIN_BITS 512 +#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) +#define NS_NOTIFY_OP ns_o_notify +#define NS_NXT_BITS 8 +#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_MAX 127 +#define NS_OPT_DNSSEC_OK 0x8000U +#define NS_OPT_NSID 3 +#define NS_PACKETSZ 512 +#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) +#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) +#define NS_QFIXEDSZ 4 +#define NS_RRFIXEDSZ 10 +#define NS_SIG_ALG 2 +#define NS_SIG_EXPIR 8 +#define NS_SIG_FOOT 16 +#define NS_SIG_LABELS 3 +#define NS_SIG_OTTL 4 +#define NS_SIG_SIGNED 12 +#define NS_SIG_SIGNER 18 +#define NS_SIG_TYPE 0 +#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" +#define NS_TSIG_ERROR_FORMERR -12 +#define NS_TSIG_ERROR_NO_SPACE -11 +#define NS_TSIG_ERROR_NO_TSIG -10 +#define NS_TSIG_FUDGE 300 +#define NS_TSIG_TCP_COUNT 100 +#define NS_UPDATE_OP ns_o_update +#define NTELOPTS (1+TELOPT_NEW_ENVIRON) +#define NULL ((void*)0) +#define NXDOMAIN ns_r_nxdomain +#define NXRRSET ns_r_nxrrset +#define NZERO 20 +#define OLD_ENV_VALUE 0 +#define OLD_ENV_VAR 1 +#define ONCE_FLAG_INIT 0 +#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) +#define O_APPEND __WASI_FDFLAGS_APPEND +#define O_CLOEXEC (0) +#define O_CREAT (__WASI_OFLAGS_CREAT << 12) +#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) +#define O_DSYNC __WASI_FDFLAGS_DSYNC +#define O_EXCL (__WASI_OFLAGS_EXCL << 12) +#define O_EXEC (0x02000000) +#define O_NOCTTY (0) +#define O_NOFOLLOW (0x01000000) +#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK +#define O_RDONLY (0x04000000) +#define O_RDWR (O_RDONLY | O_WRONLY) +#define O_RSYNC __WASI_FDFLAGS_RSYNC +#define O_SEARCH (0x08000000) +#define O_SYNC __WASI_FDFLAGS_SYNC +#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) +#define O_TTY_INIT (0) +#define O_WRONLY (0x10000000) +#define PACKETSZ NS_PACKETSZ +#define PACKET_ADD_MEMBERSHIP 1 +#define PACKET_AUXDATA 8 +#define PACKET_BROADCAST 1 +#define PACKET_COPY_THRESH 7 +#define PACKET_DROP_MEMBERSHIP 2 +#define PACKET_FANOUT 18 +#define PACKET_FANOUT_DATA 22 +#define PACKET_FASTROUTE 6 +#define PACKET_HDRLEN 11 +#define PACKET_HOST 0 +#define PACKET_IGNORE_OUTGOING 23 +#define PACKET_LOOPBACK 5 +#define PACKET_LOSS 14 +#define PACKET_MR_ALLMULTI 2 +#define PACKET_MR_MULTICAST 0 +#define PACKET_MR_PROMISC 1 +#define PACKET_MR_UNICAST 3 +#define PACKET_MULTICAST 2 +#define PACKET_ORIGDEV 9 +#define PACKET_OTHERHOST 3 +#define PACKET_OUTGOING 4 +#define PACKET_QDISC_BYPASS 20 +#define PACKET_RECV_OUTPUT 3 +#define PACKET_RESERVE 12 +#define PACKET_ROLLOVER_STATS 21 +#define PACKET_RX_RING 5 +#define PACKET_STATISTICS 6 +#define PACKET_TIMESTAMP 17 +#define PACKET_TX_HAS_OFF 19 +#define PACKET_TX_RING 13 +#define PACKET_TX_TIMESTAMP 16 +#define PACKET_VERSION 10 +#define PACKET_VNET_HDR 15 +#define PAGESIZE (0x10000) +#define PAGE_SIZE PAGESIZE +#define PATH_MAX 4096 +#define PDP_ENDIAN __PDP_ENDIAN +#define PF_INET 1 +#define PF_INET6 2 +#define PF_UNSPEC 0 +#define PM_STR 0x20027 +#define POLLERR 0x1000 +#define POLLHUP 0x2000 +#define POLLIN POLLRDNORM +#define POLLNVAL 0x4000 +#define POLLOUT POLLWRNORM +#define POLLRDNORM 0x1 +#define POLLWRNORM 0x2 +#define POSIX_CLOSE_RESTART 0 +#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED +#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE +#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL +#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM +#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL +#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED +#define PRELIM 1 +#define PRIX16 __UINT16_FMTX__ +#define PRIX32 __UINT32_FMTX__ +#define PRIX64 __UINT64_FMTX__ +#define PRIX8 __UINT8_FMTX__ +#define PRIXFAST16 __UINT_FAST16_FMTX__ +#define PRIXFAST32 __UINT_FAST32_FMTX__ +#define PRIXFAST64 __UINT_FAST64_FMTX__ +#define PRIXFAST8 __UINT_FAST8_FMTX__ +#define PRIXLEAST16 __UINT_LEAST16_FMTX__ +#define PRIXLEAST32 __UINT_LEAST32_FMTX__ +#define PRIXLEAST64 __UINT_LEAST64_FMTX__ +#define PRIXLEAST8 __UINT_LEAST8_FMTX__ +#define PRIXMAX __UINTMAX_FMTX__ +#define PRIXPTR __UINTPTR_FMTX__ +#define PRId16 __INT16_FMTd__ +#define PRId32 __INT32_FMTd__ +#define PRId64 __INT64_FMTd__ +#define PRId8 __INT8_FMTd__ +#define PRIdFAST16 __INT_FAST16_FMTd__ +#define PRIdFAST32 __INT_FAST32_FMTd__ +#define PRIdFAST64 __INT_FAST64_FMTd__ +#define PRIdFAST8 __INT_FAST8_FMTd__ +#define PRIdLEAST16 __INT_LEAST16_FMTd__ +#define PRIdLEAST32 __INT_LEAST32_FMTd__ +#define PRIdLEAST64 __INT_LEAST64_FMTd__ +#define PRIdLEAST8 __INT_LEAST8_FMTd__ +#define PRIdMAX __INTMAX_FMTd__ +#define PRIdPTR __INTPTR_FMTd__ +#define PRIi16 __INT16_FMTi__ +#define PRIi32 __INT32_FMTi__ +#define PRIi64 __INT64_FMTi__ +#define PRIi8 __INT8_FMTi__ +#define PRIiFAST16 __INT_FAST16_FMTi__ +#define PRIiFAST32 __INT_FAST32_FMTi__ +#define PRIiFAST64 __INT_FAST64_FMTi__ +#define PRIiFAST8 __INT_FAST8_FMTi__ +#define PRIiLEAST16 __INT_LEAST16_FMTi__ +#define PRIiLEAST32 __INT_LEAST32_FMTi__ +#define PRIiLEAST64 __INT_LEAST64_FMTi__ +#define PRIiLEAST8 __INT_LEAST8_FMTi__ +#define PRIiMAX __INTMAX_FMTi__ +#define PRIiPTR __INTPTR_FMTi__ +#define PRIo16 __UINT16_FMTo__ +#define PRIo32 __UINT32_FMTo__ +#define PRIo64 __UINT64_FMTo__ +#define PRIo8 __UINT8_FMTo__ +#define PRIoFAST16 __UINT_FAST16_FMTo__ +#define PRIoFAST32 __UINT_FAST32_FMTo__ +#define PRIoFAST64 __UINT_FAST64_FMTo__ +#define PRIoFAST8 __UINT_FAST8_FMTo__ +#define PRIoLEAST16 __UINT_LEAST16_FMTo__ +#define PRIoLEAST32 __UINT_LEAST32_FMTo__ +#define PRIoLEAST64 __UINT_LEAST64_FMTo__ +#define PRIoLEAST8 __UINT_LEAST8_FMTo__ +#define PRIoMAX __UINTMAX_FMTo__ +#define PRIoPTR __UINTPTR_FMTo__ +#define PRIu16 __UINT16_FMTu__ +#define PRIu32 __UINT32_FMTu__ +#define PRIu64 __UINT64_FMTu__ +#define PRIu8 __UINT8_FMTu__ +#define PRIuFAST16 __UINT_FAST16_FMTu__ +#define PRIuFAST32 __UINT_FAST32_FMTu__ +#define PRIuFAST64 __UINT_FAST64_FMTu__ +#define PRIuFAST8 __UINT_FAST8_FMTu__ +#define PRIuLEAST16 __UINT_LEAST16_FMTu__ +#define PRIuLEAST32 __UINT_LEAST32_FMTu__ +#define PRIuLEAST64 __UINT_LEAST64_FMTu__ +#define PRIuLEAST8 __UINT_LEAST8_FMTu__ +#define PRIuMAX __UINTMAX_FMTu__ +#define PRIuPTR __UINTPTR_FMTu__ +#define PRIx16 __UINT16_FMTx__ +#define PRIx32 __UINT32_FMTx__ +#define PRIx64 __UINT64_FMTx__ +#define PRIx8 __UINT8_FMTx__ +#define PRIxFAST16 __UINT_FAST16_FMTx__ +#define PRIxFAST32 __UINT_FAST32_FMTx__ +#define PRIxFAST64 __UINT_FAST64_FMTx__ +#define PRIxFAST8 __UINT_FAST8_FMTx__ +#define PRIxLEAST16 __UINT_LEAST16_FMTx__ +#define PRIxLEAST32 __UINT_LEAST32_FMTx__ +#define PRIxLEAST64 __UINT_LEAST64_FMTx__ +#define PRIxLEAST8 __UINT_LEAST8_FMTx__ +#define PRIxMAX __UINTMAX_FMTx__ +#define PRIxPTR __UINTPTR_FMTx__ +#define PTHREAD_BARRIER_SERIAL_THREAD (-1) +#define PTHREAD_CANCELED ((void *)-1) +#define PTHREAD_CANCEL_ASYNCHRONOUS 1 +#define PTHREAD_CANCEL_DEFERRED 0 +#define PTHREAD_CANCEL_DISABLE 1 +#define PTHREAD_CANCEL_ENABLE 0 +#define PTHREAD_CANCEL_MASKED 2 +#define PTHREAD_COND_INITIALIZER {{{0}}} +#define PTHREAD_CREATE_DETACHED 1 +#define PTHREAD_CREATE_JOINABLE 0 +#define PTHREAD_DESTRUCTOR_ITERATIONS 4 +#define PTHREAD_EXPLICIT_SCHED 1 +#define PTHREAD_INHERIT_SCHED 0 +#define PTHREAD_KEYS_MAX 128 +#define PTHREAD_MUTEX_DEFAULT 0 +#define PTHREAD_MUTEX_ERRORCHECK 2 +#define PTHREAD_MUTEX_INITIALIZER {{{0}}} +#define PTHREAD_MUTEX_NORMAL 0 +#define PTHREAD_MUTEX_RECURSIVE 1 +#define PTHREAD_MUTEX_ROBUST 1 +#define PTHREAD_MUTEX_STALLED 0 +#define PTHREAD_NULL ((pthread_t)0) +#define PTHREAD_ONCE_INIT 0 +#define PTHREAD_PRIO_INHERIT 1 +#define PTHREAD_PRIO_NONE 0 +#define PTHREAD_PRIO_PROTECT 2 +#define PTHREAD_PROCESS_PRIVATE 0 +#define PTHREAD_PROCESS_SHARED 1 +#define PTHREAD_RWLOCK_INITIALIZER {{{0}}} +#define PTHREAD_SCOPE_PROCESS 1 +#define PTHREAD_SCOPE_SYSTEM 0 +#define PTHREAD_STACK_MIN 2048 +#define PTRBITS (sizeof(char *) * 8) +#define PTRDIFF_MAX INT32_MAX +#define PTRDIFF_MIN INT32_MIN +#define PUTLONG NS_PUT32 +#define PUTSHORT NS_PUT16 +#define QFIXEDSZ NS_QFIXEDSZ +#define QUERY ns_o_query +#define RADIXCHAR 0x10000 +#define RAND_MAX (0x7fffffff) +#define REC_EOF '\002' +#define REC_EOR '\001' +#define REC_ESC '\377' +#define REFUSED ns_r_refused +#define REGTYPE '0' +#define REG_BADBR 10 +#define REG_BADPAT 2 +#define REG_BADRPT 13 +#define REG_EBRACE 9 +#define REG_EBRACK 7 +#define REG_ECOLLATE 3 +#define REG_ECTYPE 4 +#define REG_EESCAPE 5 +#define REG_ENOSYS -1 +#define REG_EPAREN 8 +#define REG_ERANGE 11 +#define REG_ESPACE 12 +#define REG_ESUBREG 6 +#define REG_EXTENDED 1 +#define REG_ICASE 2 +#define REG_NEWLINE 4 +#define REG_NOMATCH 1 +#define REG_NOSUB 8 +#define REG_NOTBOL 1 +#define REG_NOTEOL 2 +#define REG_OK 0 +#define RE_DUP_MAX 255 +#define RMSGD 0x0001 +#define RMSGN 0x0002 +#define RNORM 0x0000 +#define RPM_PCO_ADD 1 +#define RPM_PCO_CHANGE 2 +#define RPM_PCO_SETGLOBAL 3 +#define RPROTDAT 0x0004 +#define RPROTDIS 0x0008 +#define RPROTMASK 0x001C +#define RPROTNORM 0x0010 +#define RRFIXEDSZ NS_RRFIXEDSZ +#define RRQ 01 +#define RS_HIPRI 0x01 +#define RTLD_DEFAULT ((void *)0) +#define RTLD_GLOBAL 256 +#define RTLD_LAZY 1 +#define RTLD_LOCAL 8 +#define RTLD_NEXT ((void *)-1) +#define RTLD_NODELETE 4096 +#define RTLD_NOLOAD 4 +#define RTLD_NOW 2 +#define RUSAGE_CHILDREN 2 +#define RUSAGE_SELF 1 +#define R_OK (4) +#define SARMAG 8 +#define SB 250 +#define SCHAR_MAX 127 +#define SCHAR_MIN (-128) +#define SCNd16 __INT16_FMTd__ +#define SCNd32 __INT32_FMTd__ +#define SCNd64 __INT64_FMTd__ +#define SCNd8 __INT8_FMTd__ +#define SCNdFAST16 __INT_FAST16_FMTd__ +#define SCNdFAST32 __INT_FAST32_FMTd__ +#define SCNdFAST64 __INT_FAST64_FMTd__ +#define SCNdFAST8 __INT_FAST8_FMTd__ +#define SCNdLEAST16 __INT_LEAST16_FMTd__ +#define SCNdLEAST32 __INT_LEAST32_FMTd__ +#define SCNdLEAST64 __INT_LEAST64_FMTd__ +#define SCNdLEAST8 __INT_LEAST8_FMTd__ +#define SCNdMAX __INTMAX_FMTd__ +#define SCNdPTR __INTPTR_FMTd__ +#define SCNi16 __INT16_FMTi__ +#define SCNi32 __INT32_FMTi__ +#define SCNi64 __INT64_FMTi__ +#define SCNi8 __INT8_FMTi__ +#define SCNiFAST16 __INT_FAST16_FMTi__ +#define SCNiFAST32 __INT_FAST32_FMTi__ +#define SCNiFAST64 __INT_FAST64_FMTi__ +#define SCNiFAST8 __INT_FAST8_FMTi__ +#define SCNiLEAST16 __INT_LEAST16_FMTi__ +#define SCNiLEAST32 __INT_LEAST32_FMTi__ +#define SCNiLEAST64 __INT_LEAST64_FMTi__ +#define SCNiLEAST8 __INT_LEAST8_FMTi__ +#define SCNiMAX __INTMAX_FMTi__ +#define SCNiPTR __INTPTR_FMTi__ +#define SCNo16 __UINT16_FMTo__ +#define SCNo32 __UINT32_FMTo__ +#define SCNo64 __UINT64_FMTo__ +#define SCNo8 __UINT8_FMTo__ +#define SCNoFAST16 __UINT_FAST16_FMTo__ +#define SCNoFAST32 __UINT_FAST32_FMTo__ +#define SCNoFAST64 __UINT_FAST64_FMTo__ +#define SCNoFAST8 __UINT_FAST8_FMTo__ +#define SCNoLEAST16 __UINT_LEAST16_FMTo__ +#define SCNoLEAST32 __UINT_LEAST32_FMTo__ +#define SCNoLEAST64 __UINT_LEAST64_FMTo__ +#define SCNoLEAST8 __UINT_LEAST8_FMTo__ +#define SCNoMAX __UINTMAX_FMTo__ +#define SCNoPTR __UINTPTR_FMTo__ +#define SCNu16 __UINT16_FMTu__ +#define SCNu32 __UINT32_FMTu__ +#define SCNu64 __UINT64_FMTu__ +#define SCNu8 __UINT8_FMTu__ +#define SCNuFAST16 __UINT_FAST16_FMTu__ +#define SCNuFAST32 __UINT_FAST32_FMTu__ +#define SCNuFAST64 __UINT_FAST64_FMTu__ +#define SCNuFAST8 __UINT_FAST8_FMTu__ +#define SCNuLEAST16 __UINT_LEAST16_FMTu__ +#define SCNuLEAST32 __UINT_LEAST32_FMTu__ +#define SCNuLEAST64 __UINT_LEAST64_FMTu__ +#define SCNuLEAST8 __UINT_LEAST8_FMTu__ +#define SCNuMAX __UINTMAX_FMTu__ +#define SCNuPTR __UINTPTR_FMTu__ +#define SCNx16 __UINT16_FMTx__ +#define SCNx32 __UINT32_FMTx__ +#define SCNx64 __UINT64_FMTx__ +#define SCNx8 __UINT8_FMTx__ +#define SCNxFAST16 __UINT_FAST16_FMTx__ +#define SCNxFAST32 __UINT_FAST32_FMTx__ +#define SCNxFAST64 __UINT_FAST64_FMTx__ +#define SCNxFAST8 __UINT_FAST8_FMTx__ +#define SCNxLEAST16 __UINT_LEAST16_FMTx__ +#define SCNxLEAST32 __UINT_LEAST32_FMTx__ +#define SCNxLEAST64 __UINT_LEAST64_FMTx__ +#define SCNxLEAST8 __UINT_LEAST8_FMTx__ +#define SCNxMAX __UINTMAX_FMTx__ +#define SCNxPTR __UINTPTR_FMTx__ +#define SE 240 +#define SEEK_CUR __WASI_WHENCE_CUR +#define SEEK_END __WASI_WHENCE_END +#define SEEK_SET __WASI_WHENCE_SET +#define SEGSIZE 512 +#define SEM_FAILED ((sem_t *)0) +#define SEM_NSEMS_MAX 256 +#define SEM_VALUE_MAX 0x7fffffff +#define SERVFAIL ns_r_servfail +#define SHORTBITS (sizeof(short) * 8) +#define SHRT_MAX 0x7fff +#define SHRT_MIN (-1-0x7fff) +#define SHUT_RD __WASI_SDFLAGS_RD +#define SHUT_RDWR (SHUT_RD | SHUT_WR) +#define SHUT_WR __WASI_SDFLAGS_WR +#define SIG_ATOMIC_MAX INT32_MAX +#define SIG_ATOMIC_MIN INT32_MIN +#define SIZE_MAX UINT32_MAX +#define SI_LOAD_SHIFT 16 +#define SLC_ABORT 7 +#define SLC_ACK 0x80 +#define SLC_AO 4 +#define SLC_AYT 5 +#define SLC_BRK 2 +#define SLC_CANTCHANGE 1 +#define SLC_DEFAULT 3 +#define SLC_EC 10 +#define SLC_EL 11 +#define SLC_EOF 8 +#define SLC_EOR 6 +#define SLC_EW 12 +#define SLC_FLAGS 1 +#define SLC_FLUSHIN 0x40 +#define SLC_FLUSHOUT 0x20 +#define SLC_FORW1 17 +#define SLC_FORW2 18 +#define SLC_FUNC 0 +#define SLC_IP 3 +#define SLC_LEVELBITS 0x03 +#define SLC_LNEXT 14 +#define SLC_NAME(x) slc_names[x] +#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, +#define SLC_NAMES SLC_NAMELIST +#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) +#define SLC_NOSUPPORT 0 +#define SLC_RP 13 +#define SLC_SUSP 9 +#define SLC_SYNCH 1 +#define SLC_VALUE 2 +#define SLC_VARIABLE 2 +#define SLC_XOFF 16 +#define SLC_XON 15 +#define SNDPIPE 0x002 +#define SNDZERO 0x001 +#define SOCK_CLOEXEC (0x00002000) +#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM +#define SOCK_NONBLOCK (0x00004000) +#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM +#define SOL_SOCKET 0x7fffffff +#define SOL_TCP 6 +#define SOL_UDP 17 +#define SO_TYPE 3 +#define SSIZE_MAX LONG_MAX +#define STATUS ns_o_status +#define STA_CLK 0x8000 +#define STA_CLOCKERR 0x1000 +#define STA_DEL 0x0020 +#define STA_FLL 0x0008 +#define STA_FREQHOLD 0x0080 +#define STA_INS 0x0010 +#define STA_MODE 0x4000 +#define STA_NANO 0x2000 +#define STA_PLL 0x0001 +#define STA_PPSERROR 0x0800 +#define STA_PPSFREQ 0x0002 +#define STA_PPSJITTER 0x0200 +#define STA_PPSSIGNAL 0x0100 +#define STA_PPSTIME 0x0004 +#define STA_PPSWANDER 0x0400 +#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) +#define STA_UNSYNC 0x0040 +#define STDERR_FILENO 2 +#define STDIN_FILENO 0 +#define STDOUT_FILENO 1 +#define STRU_F 1 +#define STRU_P 3 +#define STRU_R 2 +#define ST_APPEND 256 +#define ST_IMMUTABLE 512 +#define ST_MANDLOCK 64 +#define ST_NOATIME 1024 +#define ST_NODEV 4 +#define ST_NODIRATIME 2048 +#define ST_NOEXEC 8 +#define ST_NOSUID 2 +#define ST_RDONLY 1 +#define ST_RELATIME 4096 +#define ST_SYNCHRONOUS 16 +#define ST_WRITE 128 +#define SUN_LEN(s) (2+strlen((s)->sun_path)) +#define SUSP 237 +#define SYMLOOP_MAX 40 +#define SYMTYPE '2' +#define SYNCH 242 +#define S_ADDT ns_s_ar +#define S_BANDURG 0x0200 +#define S_ERROR 0x0010 +#define S_HANGUP 0x0020 +#define S_HIPRI 0x0002 +#define S_IEXEC S_IXUSR +#define S_IFBLK (0x6000) +#define S_IFCHR (0x2000) +#define S_IFDIR (0x4000) +#define S_IFIFO (0x1000) +#define S_IFLNK (0xa000) +#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) +#define S_IFREG (0x8000) +#define S_IFSOCK (0xc000) +#define S_INPUT 0x0001 +#define S_IREAD S_IRUSR +#define S_IRGRP (0x20) +#define S_IROTH (0x4) +#define S_IRUSR (0x100) +#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) +#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) +#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) +#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) +#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) +#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) +#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) +#define S_ISGID (0x400) +#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) +#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) +#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) +#define S_ISUID (0x800) +#define S_ISVTX (0x200) +#define S_IWGRP (0x10) +#define S_IWOTH (0x2) +#define S_IWRITE S_IWUSR +#define S_IWUSR (0x80) +#define S_IXGRP (0x8) +#define S_IXOTH (0x1) +#define S_IXUSR (0x40) +#define S_MSG 0x0008 +#define S_OUTPUT 0x0004 +#define S_PREREQ ns_s_pr +#define S_RDBAND 0x0080 +#define S_RDNORM 0x0040 +#define S_UPDATE ns_s_ud +#define S_WRBAND 0x0100 +#define S_WRNORM S_OUTPUT +#define S_ZONE ns_s_zn +#define TCPI_OPT_ECN 8 +#define TCPI_OPT_SACK 2 +#define TCPI_OPT_TIMESTAMPS 1 +#define TCPI_OPT_WSCALE 4 +#define TCPOLEN_MAXSEG 4 +#define TCPOLEN_SACK_PERMITTED 2 +#define TCPOLEN_TIMESTAMP 10 +#define TCPOLEN_WINDOW 3 +#define TCPOPT_EOL 0 +#define TCPOPT_MAXSEG 2 +#define TCPOPT_NOP 1 +#define TCPOPT_SACK 5 +#define TCPOPT_SACK_PERMITTED 4 +#define TCPOPT_TIMESTAMP 8 +#define TCPOPT_WINDOW 3 +#define TCP_CA_CWR 2 +#define TCP_CA_Disorder 1 +#define TCP_CA_Loss 4 +#define TCP_CA_Open 0 +#define TCP_CA_Recovery 3 +#define TCP_CC_INFO 26 +#define TCP_CLOSE 7 +#define TCP_CLOSE_WAIT 8 +#define TCP_CLOSING 11 +#define TCP_CM_INQ TCP_INQ +#define TCP_CONGESTION 13 +#define TCP_CORK 3 +#define TCP_DEFER_ACCEPT 9 +#define TCP_ENCAP_ESPINTCP 7 +#define TCP_ESTABLISHED 1 +#define TCP_FASTOPEN 23 +#define TCP_FASTOPEN_CONNECT 30 +#define TCP_FASTOPEN_KEY 33 +#define TCP_FASTOPEN_NO_COOKIE 34 +#define TCP_FIN_WAIT1 4 +#define TCP_FIN_WAIT2 5 +#define TCP_INFO 11 +#define TCP_INQ 36 +#define TCP_KEEPCNT 6 +#define TCP_KEEPIDLE 4 +#define TCP_KEEPINTVL 5 +#define TCP_LAST_ACK 9 +#define TCP_LINGER2 8 +#define TCP_LISTEN 10 +#define TCP_MAXSEG 2 +#define TCP_MD5SIG 14 +#define TCP_MD5SIG_EXT 32 +#define TCP_MD5SIG_FLAG_IFINDEX 0x2 +#define TCP_MD5SIG_FLAG_PREFIX 0x1 +#define TCP_MD5SIG_MAXKEYLEN 80 +#define TCP_NODELAY 1 +#define TCP_NOTSENT_LOWAT 25 +#define TCP_QUEUE_SEQ 21 +#define TCP_QUICKACK 12 +#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 +#define TCP_REPAIR 19 +#define TCP_REPAIR_OFF 0 +#define TCP_REPAIR_OFF_NO_WP -1 +#define TCP_REPAIR_ON 1 +#define TCP_REPAIR_OPTIONS 22 +#define TCP_REPAIR_QUEUE 20 +#define TCP_REPAIR_WINDOW 29 +#define TCP_SAVED_SYN 28 +#define TCP_SAVE_SYN 27 +#define TCP_SYNCNT 7 +#define TCP_SYN_RECV 3 +#define TCP_SYN_SENT 2 +#define TCP_THIN_DUPACK 17 +#define TCP_THIN_LINEAR_TIMEOUTS 16 +#define TCP_TIMESTAMP 24 +#define TCP_TIME_WAIT 6 +#define TCP_TX_DELAY 37 +#define TCP_ULP 31 +#define TCP_USER_TIMEOUT 18 +#define TCP_WINDOW_CLAMP 10 +#define TCP_ZEROCOPY_RECEIVE 35 +#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] +#define TELCMD_FIRST xEOF +#define TELCMD_LAST IAC +#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) +#define TELOPT_3270REGIME 29 +#define TELOPT_AUTHENTICATION 37 +#define TELOPT_BINARY 0 +#define TELOPT_BM 19 +#define TELOPT_DET 20 +#define TELOPT_ECHO 1 +#define TELOPT_ENCRYPT 38 +#define TELOPT_EOR 25 +#define TELOPT_EXOPL 255 +#define TELOPT_LFLOW 33 +#define TELOPT_LINEMODE 34 +#define TELOPT_LOGOUT 18 +#define TELOPT_NAMS 4 +#define TELOPT_NAOCRD 10 +#define TELOPT_NAOFFD 13 +#define TELOPT_NAOHTD 12 +#define TELOPT_NAOHTS 11 +#define TELOPT_NAOL 8 +#define TELOPT_NAOLFD 16 +#define TELOPT_NAOP 9 +#define TELOPT_NAOVTD 15 +#define TELOPT_NAOVTS 14 +#define TELOPT_NAWS 31 +#define TELOPT_NEW_ENVIRON 39 +#define TELOPT_OLD_ENVIRON 36 +#define TELOPT_OUTMRK 27 +#define TELOPT_RCP 2 +#define TELOPT_RCTE 7 +#define TELOPT_SGA 3 +#define TELOPT_SNDLOC 23 +#define TELOPT_STATUS 5 +#define TELOPT_SUPDUP 21 +#define TELOPT_SUPDUPOUTPUT 22 +#define TELOPT_TM 6 +#define TELOPT_TSPEED 32 +#define TELOPT_TTYLOC 28 +#define TELOPT_TTYPE 24 +#define TELOPT_TUID 26 +#define TELOPT_X3PAD 30 +#define TELOPT_XASCII 17 +#define TELOPT_XDISPLOC 35 +#define TELQUAL_INFO 2 +#define TELQUAL_IS 0 +#define TELQUAL_NAME 3 +#define TELQUAL_REPLY 2 +#define TELQUAL_SEND 1 +#define TGEXEC 00010 +#define TGREAD 00040 +#define TGWRITE 00020 +#define THOUSEP 0x10001 +#define TH_ACK 0x10 +#define TH_FIN 0x01 +#define TH_PUSH 0x08 +#define TH_RST 0x04 +#define TH_SYN 0x02 +#define TH_URG 0x20 +#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME +#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) +#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) +#define TIME_BAD TIME_ERROR +#define TIME_DEL 2 +#define TIME_ERROR 5 +#define TIME_INS 1 +#define TIME_OK 0 +#define TIME_OOP 3 +#define TIME_UTC 1 +#define TIME_WAIT 4 +#define TMAGIC "ustar" +#define TMAGLEN 6 +#define TOEXEC 00001 +#define TOREAD 00004 +#define TOWRITE 00002 +#define TRANSIENT 4 +#define TSGID 02000 +#define TSS_DTOR_ITERATIONS 4 +#define TSUID 04000 +#define TSVTX 01000 +#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) +#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) +#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) +#define TTYDEF_SPEED (B9600) +#define TTY_NAME_MAX 32 +#define TUEXEC 00100 +#define TUREAD 00400 +#define TUWRITE 00200 +#define TVERSION "00" +#define TVERSLEN 2 +#define TYPE_A 1 +#define TYPE_E 2 +#define TYPE_I 3 +#define TYPE_L 4 +#define TZNAME_MAX 6 +#define T_A ns_t_a +#define T_A6 ns_t_a6 +#define T_AAAA ns_t_aaaa +#define T_AFSDB ns_t_afsdb +#define T_ANY ns_t_any +#define T_ATMA ns_t_atma +#define T_AXFR ns_t_axfr +#define T_CNAME ns_t_cname +#define T_DNAME ns_t_dname +#define T_EID ns_t_eid +#define T_FMT 0x2002A +#define T_FMT_AMPM 0x2002B +#define T_GPOS ns_t_gpos +#define T_HINFO ns_t_hinfo +#define T_ISDN ns_t_isdn +#define T_IXFR ns_t_ixfr +#define T_KEY ns_t_key +#define T_LOC ns_t_loc +#define T_MAILA ns_t_maila +#define T_MAILB ns_t_mailb +#define T_MB ns_t_mb +#define T_MD ns_t_md +#define T_MF ns_t_mf +#define T_MG ns_t_mg +#define T_MINFO ns_t_minfo +#define T_MR ns_t_mr +#define T_MX ns_t_mx +#define T_NAPTR ns_t_naptr +#define T_NIMLOC ns_t_nimloc +#define T_NS ns_t_ns +#define T_NSAP ns_t_nsap +#define T_NSAP_PTR ns_t_nsap_ptr +#define T_NULL ns_t_null +#define T_NXT ns_t_nxt +#define T_PTR ns_t_ptr +#define T_PX ns_t_px +#define T_RP ns_t_rp +#define T_RT ns_t_rt +#define T_SIG ns_t_sig +#define T_SOA ns_t_soa +#define T_SRV ns_t_srv +#define T_TSIG ns_t_tsig +#define T_TXT ns_t_txt +#define T_WKS ns_t_wks +#define T_X25 ns_t_x25 +#define UCHAR_MAX 255 +#define UDP_CORK 1 +#define UDP_ENCAP 100 +#define UDP_ENCAP_ESPINUDP 2 +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 +#define UDP_ENCAP_GTP0 4 +#define UDP_ENCAP_GTP1U 5 +#define UDP_ENCAP_L2TPINUDP 3 +#define UDP_ENCAP_RXRPC 6 +#define UDP_GRO 104 +#define UDP_NO_CHECK6_RX 102 +#define UDP_NO_CHECK6_TX 101 +#define UDP_SEGMENT 103 +#define UINT16_C(c) c +#define UINT16_MAX (0xffff) +#define UINT32_C(c) c ## U +#define UINT32_MAX (0xffffffffu) +#define UINT64_C(c) c ## ULL +#define UINT64_MAX (0xffffffffffffffffu) +#define UINT8_C(c) c +#define UINT8_MAX (0xff) +#define UINTMAX_C(c) c ## ULL +#define UINTMAX_MAX UINT64_MAX +#define UINTPTR_MAX UINT32_MAX +#define UINT_FAST16_MAX UINT16_MAX +#define UINT_FAST32_MAX UINT32_MAX +#define UINT_FAST64_MAX UINT64_MAX +#define UINT_FAST8_MAX UINT8_MAX +#define UINT_LEAST16_MAX UINT16_MAX +#define UINT_LEAST32_MAX UINT32_MAX +#define UINT_LEAST64_MAX UINT64_MAX +#define UINT_LEAST8_MAX UINT8_MAX +#define UINT_MAX 0xffffffffU +#define UIO_MAXIOV 1024 +#define ULLONG_MAX (2ULL*LLONG_MAX+1) +#define ULONG_MAX (2UL*LONG_MAX+1) +#define USHRT_MAX 0xffff +#define UTIME_NOW (-1) +#define UTIME_OMIT (-2) +#define WCHAR_MAX (0x7fffffff+L'\0') +#define WCHAR_MIN (-1-0x7fffffff+L'\0') +#define WEOF 0xffffffffU +#define WILL 251 +#define WINT_MAX UINT32_MAX +#define WINT_MIN 0U +#define WONT 252 +#define WORD_BIT 32 +#define WRQ 02 +#define W_OK (2) +#define X_OK (1) +#define YESEXPR 0x50000 +#define YESSTR 0x50002 +#define YXDOMAIN ns_r_yxdomain +#define YXRRSET ns_r_yxrrset +#define _ALLOCA_H +#define _ALL_SOURCE 1 +#define _ARPA_FTP_H +#define _ARPA_INET_H +#define _ARPA_NAMESER_H +#define _ARPA_TELNET_H +#define _ARPA_TFTP_H +#define _AR_H +#define _BYTESWAP_H +#define _COMPLEX_H +#define _CPIO_H +#define _CRYPT_H +#define _CS_GNU_LIBC_VERSION 2 +#define _CS_GNU_LIBPTHREAD_VERSION 3 +#define _CS_PATH 0 +#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 +#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 +#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 +#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 +#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 +#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 +#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 +#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 +#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 +#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 +#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 +#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 +#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 +#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 +#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 +#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 +#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 +#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 +#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 +#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 +#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 +#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 +#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 +#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 +#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 +#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 +#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 +#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 +#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 +#define _CS_V6_ENV 1148 +#define _CS_V7_ENV 1149 +#define _CTYPE_H +#define _Complex_I (0.0f+1.0fi) +#define _DIRENT_H +#define _DIRENT_HAVE_D_TYPE +#define _DLFCN_H +#define _ENDIAN_H +#define _ERRNO_H +#define _ERR_H +#define _FCNTL_H +#define _FEATURES_H +#define _FENV_H +#define _FLOAT_H +#define _FMTMSG_H +#define _FNMATCH_H +#define _FTW_H +#define _GETOPT_H +#define _GLOB_H +#define _GNU_SOURCE 1 +#define _ICONV_H +#define _IFADDRS_H +#define _INTTYPES_H +#define _IOFBF 0 +#define _IOLBF 1 +#define _IONBF 2 +#define _ISO646_H +#define _LANGINFO_H +#define _LIBGEN_H +#define _LIMITS_H +#define _LOCALE_H +#define _LP64 1 +#define _MALLOC_H +#define _MATH_H +#define _MONETARY_H +#define _MQUEUE_H +#define _NETINET_ICMP6_H +#define _NETINET_IGMP_H +#define _NETINET_IN_H +#define _NETINET_IN_SYSTM_H +#define _NETINET_IP6_H +#define _NETINET_IP_H +#define _NETINET_IP_ICMP_H +#define _NETINET_TCP_H +#define _NETINET_UDP_H +#define _NETPACKET_PACKET_H +#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) +#define _NL_TYPES_H +#define _PC_2_SYMLINKS 20 +#define _PC_ALLOC_SIZE_MIN 18 +#define _PC_ASYNC_IO 10 +#define _PC_CHOWN_RESTRICTED 6 +#define _PC_FILESIZEBITS 13 +#define _PC_LINK_MAX 0 +#define _PC_MAX_CANON 1 +#define _PC_MAX_INPUT 2 +#define _PC_NAME_MAX 3 +#define _PC_NO_TRUNC 7 +#define _PC_PATH_MAX 4 +#define _PC_PIPE_BUF 5 +#define _PC_PRIO_IO 11 +#define _PC_REC_INCR_XFER_SIZE 14 +#define _PC_REC_MAX_XFER_SIZE 15 +#define _PC_REC_MIN_XFER_SIZE 16 +#define _PC_REC_XFER_ALIGN 17 +#define _PC_SOCK_MAXBUF 12 +#define _PC_SYMLINK_MAX 19 +#define _PC_SYNC_IO 9 +#define _PC_VDISABLE 8 +#define _POLL_H +#define _POSIX2_BC_BASE_MAX 99 +#define _POSIX2_BC_DIM_MAX 2048 +#define _POSIX2_BC_SCALE_MAX 99 +#define _POSIX2_BC_STRING_MAX 1000 +#define _POSIX2_CHARCLASS_NAME_MAX 14 +#define _POSIX2_COLL_WEIGHTS_MAX 2 +#define _POSIX2_C_BIND _POSIX_VERSION +#define _POSIX2_EXPR_NEST_MAX 32 +#define _POSIX2_LINE_MAX 2048 +#define _POSIX2_RE_DUP_MAX 255 +#define _POSIX2_VERSION _POSIX_VERSION +#define _POSIX_ADVISORY_INFO _POSIX_VERSION +#define _POSIX_AIO_LISTIO_MAX 2 +#define _POSIX_AIO_MAX 1 +#define _POSIX_ARG_MAX 4096 +#define _POSIX_BARRIERS _POSIX_VERSION +#define _POSIX_CHILD_MAX 25 +#define _POSIX_CHOWN_RESTRICTED 1 +#define _POSIX_CLOCKRES_MIN 20000000 +#define _POSIX_CLOCK_SELECTION _POSIX_VERSION +#define _POSIX_CPUTIME _POSIX_VERSION +#define _POSIX_DELAYTIMER_MAX 32 +#define _POSIX_FSYNC _POSIX_VERSION +#define _POSIX_HOST_NAME_MAX 255 +#define _POSIX_IPV6 _POSIX_VERSION +#define _POSIX_LINK_MAX 8 +#define _POSIX_LOGIN_NAME_MAX 9 +#define _POSIX_MAX_CANON 255 +#define _POSIX_MAX_INPUT 255 +#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION +#define _POSIX_MQ_OPEN_MAX 8 +#define _POSIX_MQ_PRIO_MAX 32 +#define _POSIX_NAME_MAX 14 +#define _POSIX_NGROUPS_MAX 8 +#define _POSIX_NO_TRUNC 1 +#define _POSIX_OPEN_MAX 20 +#define _POSIX_PATH_MAX 256 +#define _POSIX_PIPE_BUF 512 +#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION +#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION +#define _POSIX_REGEXP 1 +#define _POSIX_RE_DUP_MAX 255 +#define _POSIX_RTSIG_MAX 8 +#define _POSIX_SEM_NSEMS_MAX 256 +#define _POSIX_SEM_VALUE_MAX 32767 +#define _POSIX_SIGQUEUE_MAX 32 +#define _POSIX_SPIN_LOCKS _POSIX_VERSION +#define _POSIX_SSIZE_MAX 32767 +#define _POSIX_SS_REPL_MAX 4 +#define _POSIX_STREAM_MAX 8 +#define _POSIX_SYMLINK_MAX 255 +#define _POSIX_SYMLOOP_MAX 8 +#define _POSIX_THREADS _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION +#define _POSIX_THREAD_CPUTIME _POSIX_VERSION +#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 +#define _POSIX_THREAD_KEYS_MAX 128 +#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION +#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION +#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION +#define _POSIX_THREAD_THREADS_MAX 64 +#define _POSIX_TIMEOUTS _POSIX_VERSION +#define _POSIX_TIMERS _POSIX_VERSION +#define _POSIX_TIMER_MAX 32 +#define _POSIX_TRACE_EVENT_NAME_MAX 30 +#define _POSIX_TRACE_NAME_MAX 8 +#define _POSIX_TRACE_SYS_MAX 8 +#define _POSIX_TRACE_USER_EVENT_MAX 32 +#define _POSIX_TTY_NAME_MAX 9 +#define _POSIX_TZNAME_MAX 6 +#define _POSIX_V6_ILP32_OFFBIG (1) +#define _POSIX_V7_ILP32_OFFBIG (1) +#define _POSIX_VDISABLE 0 +#define _POSIX_VERSION 200809L +#define _PTHREAD_H +#define _PTRDIFF_T +#define _REENTRANT 1 +#define _REGEX_H +#define _SCHED_H +#define _SC_2_CHAR_TERM 95 +#define _SC_2_C_BIND 47 +#define _SC_2_C_DEV 48 +#define _SC_2_FORT_DEV 49 +#define _SC_2_FORT_RUN 50 +#define _SC_2_LOCALEDEF 52 +#define _SC_2_PBS 168 +#define _SC_2_PBS_ACCOUNTING 169 +#define _SC_2_PBS_CHECKPOINT 175 +#define _SC_2_PBS_LOCATE 170 +#define _SC_2_PBS_MESSAGE 171 +#define _SC_2_PBS_TRACK 172 +#define _SC_2_SW_DEV 51 +#define _SC_2_UPE 97 +#define _SC_2_VERSION 46 +#define _SC_ADVISORY_INFO 132 +#define _SC_AIO_LISTIO_MAX 23 +#define _SC_AIO_MAX 24 +#define _SC_AIO_PRIO_DELTA_MAX 25 +#define _SC_ARG_MAX 0 +#define _SC_ASYNCHRONOUS_IO 12 +#define _SC_ATEXIT_MAX 87 +#define _SC_AVPHYS_PAGES 86 +#define _SC_BARRIERS 133 +#define _SC_BC_BASE_MAX 36 +#define _SC_BC_DIM_MAX 37 +#define _SC_BC_SCALE_MAX 38 +#define _SC_BC_STRING_MAX 39 +#define _SC_CHILD_MAX 1 +#define _SC_CLK_TCK 2 +#define _SC_CLOCK_SELECTION 137 +#define _SC_COLL_WEIGHTS_MAX 40 +#define _SC_CPUTIME 138 +#define _SC_DELAYTIMER_MAX 26 +#define _SC_EXPR_NEST_MAX 42 +#define _SC_FSYNC 15 +#define _SC_GETGR_R_SIZE_MAX 69 +#define _SC_GETPW_R_SIZE_MAX 70 +#define _SC_HOST_NAME_MAX 180 +#define _SC_IOV_MAX 60 +#define _SC_IPV6 235 +#define _SC_JOB_CONTROL 7 +#define _SC_LINE_MAX 43 +#define _SC_LOGIN_NAME_MAX 71 +#define _SC_MAPPED_FILES 16 +#define _SC_MEMLOCK 17 +#define _SC_MEMLOCK_RANGE 18 +#define _SC_MEMORY_PROTECTION 19 +#define _SC_MESSAGE_PASSING 20 +#define _SC_MONOTONIC_CLOCK 149 +#define _SC_MQ_OPEN_MAX 27 +#define _SC_MQ_PRIO_MAX 28 +#define _SC_NGROUPS_MAX 3 +#define _SC_NPROCESSORS_CONF 83 +#define _SC_NPROCESSORS_ONLN 84 +#define _SC_NZERO 109 +#define _SC_OPEN_MAX 4 +#define _SC_PAGESIZE 30 +#define _SC_PAGE_SIZE 30 +#define _SC_PASS_MAX 88 +#define _SC_PHYS_PAGES 85 +#define _SC_PRIORITIZED_IO 13 +#define _SC_PRIORITY_SCHEDULING 10 +#define _SC_RAW_SOCKETS 236 +#define _SC_READER_WRITER_LOCKS 153 +#define _SC_REALTIME_SIGNALS 9 +#define _SC_REGEXP 155 +#define _SC_RE_DUP_MAX 44 +#define _SC_RTSIG_MAX 31 +#define _SC_SAVED_IDS 8 +#define _SC_SEMAPHORES 21 +#define _SC_SEM_NSEMS_MAX 32 +#define _SC_SEM_VALUE_MAX 33 +#define _SC_SHARED_MEMORY_OBJECTS 22 +#define _SC_SHELL 157 +#define _SC_SIGQUEUE_MAX 34 +#define _SC_SPAWN 159 +#define _SC_SPIN_LOCKS 154 +#define _SC_SPORADIC_SERVER 160 +#define _SC_SS_REPL_MAX 241 +#define _SC_STREAMS 174 +#define _SC_STREAM_MAX 5 +#define _SC_SYMLOOP_MAX 173 +#define _SC_SYNCHRONIZED_IO 14 +#define _SC_THREADS 67 +#define _SC_THREAD_ATTR_STACKADDR 77 +#define _SC_THREAD_ATTR_STACKSIZE 78 +#define _SC_THREAD_CPUTIME 139 +#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 +#define _SC_THREAD_KEYS_MAX 74 +#define _SC_THREAD_PRIORITY_SCHEDULING 79 +#define _SC_THREAD_PRIO_INHERIT 80 +#define _SC_THREAD_PRIO_PROTECT 81 +#define _SC_THREAD_PROCESS_SHARED 82 +#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 +#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 +#define _SC_THREAD_SAFE_FUNCTIONS 68 +#define _SC_THREAD_SPORADIC_SERVER 161 +#define _SC_THREAD_STACK_MIN 75 +#define _SC_THREAD_THREADS_MAX 76 +#define _SC_TIMEOUTS 164 +#define _SC_TIMERS 11 +#define _SC_TIMER_MAX 35 +#define _SC_TRACE 181 +#define _SC_TRACE_EVENT_FILTER 182 +#define _SC_TRACE_EVENT_NAME_MAX 242 +#define _SC_TRACE_INHERIT 183 +#define _SC_TRACE_LOG 184 +#define _SC_TRACE_NAME_MAX 243 +#define _SC_TRACE_SYS_MAX 244 +#define _SC_TRACE_USER_EVENT_MAX 245 +#define _SC_TTY_NAME_MAX 72 +#define _SC_TYPED_MEMORY_OBJECTS 165 +#define _SC_TZNAME_MAX 6 +#define _SC_UIO_MAXIOV 60 +#define _SC_V6_ILP32_OFF32 176 +#define _SC_V6_ILP32_OFFBIG 177 +#define _SC_V6_LP64_OFF64 178 +#define _SC_V6_LPBIG_OFFBIG 179 +#define _SC_V7_ILP32_OFF32 237 +#define _SC_V7_ILP32_OFFBIG 238 +#define _SC_V7_LP64_OFF64 239 +#define _SC_V7_LPBIG_OFFBIG 240 +#define _SC_VERSION 29 +#define _SC_XBS5_ILP32_OFF32 125 +#define _SC_XBS5_ILP32_OFFBIG 126 +#define _SC_XBS5_LP64_OFF64 127 +#define _SC_XBS5_LPBIG_OFFBIG 128 +#define _SC_XOPEN_CRYPT 92 +#define _SC_XOPEN_ENH_I18N 93 +#define _SC_XOPEN_LEGACY 129 +#define _SC_XOPEN_REALTIME 130 +#define _SC_XOPEN_REALTIME_THREADS 131 +#define _SC_XOPEN_SHM 94 +#define _SC_XOPEN_STREAMS 246 +#define _SC_XOPEN_UNIX 91 +#define _SC_XOPEN_VERSION 89 +#define _SC_XOPEN_XCU_VERSION 90 +#define _SC_XOPEN_XPG2 98 +#define _SC_XOPEN_XPG3 99 +#define _SC_XOPEN_XPG4 100 +#define _SEARCH_H +#define _SEMAPHORE_H +#define _SIZE_T +#define _STDALIGN_H +#define _STDBOOL_H +#define _STDC_PREDEF_H +#define _STDINT_H +#define _STDIO_EXT_H +#define _STDIO_H +#define _STDLIB_H +#define _STDNORETURN_H +#define _STRINGS_H +#define _STRING_H +#define _STROPTS_H +#define _SYSEXITS_H +#define _SYS_EVENTFD_H +#define _SYS_FILE_H +#define _SYS_IOCTL_H +#define _SYS_PARAM_H +#define _SYS_RANDOM_H +#define _SYS_REG_H +#define _SYS_SELECT_H +#define _SYS_SOCKET_H +#define _SYS_STATVFS_H +#define _SYS_STAT_H +#define _SYS_SYSCALL_H +#define _SYS_SYSINFO_H +#define _SYS_TIMEB_H +#define _SYS_TIMEX_H +#define _SYS_TIME_H +#define _SYS_TTYDEFAULTS_H +#define _SYS_TYPES_H +#define _SYS_UIO_H +#define _SYS_UN_H +#define _SYS_UTSNAME_H +#define _TAR_H +#define _TGMATH_H +#define _THREADS_H +#define _TIME_H +#define _UCHAR_H +#define _UNISTD_H +#define _UTIME_H +#define _VALUES_H +#define _VA_LIST +#define _WCHAR_H +#define _WCHAR_T +#define _WCTYPE_H +#define _WINT_T +#define _XOPEN_ENH_I18N 1 +#define _XOPEN_IOV_MAX 16 +#define _XOPEN_NAME_MAX 255 +#define _XOPEN_PATH_MAX 1024 +#define _XOPEN_UNIX 1 +#define _XOPEN_VERSION 700 +#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) +#define __ATOMIC_ACQUIRE 2 +#define __ATOMIC_ACQ_REL 4 +#define __ATOMIC_CONSUME 1 +#define __ATOMIC_RELAXED 0 +#define __ATOMIC_RELEASE 3 +#define __ATOMIC_SEQ_CST 5 +#define __BIGGEST_ALIGNMENT__ 16 +#define __BIG_ENDIAN 4321 +#define __BIND 19950621 +#define __BYTE_ORDER __BYTE_ORDER__ +#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ +#define __CHAR16_TYPE__ unsigned short +#define __CHAR32_TYPE__ unsigned int +#define __CHAR_BIT__ 8 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __CLANG_MAX_ALIGN_T_DEFINED +#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) +#define __CONSTANT_CFSTRINGS__ 1 +#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) +#define __DBL_DECIMAL_DIG__ 17 +#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 +#define __DBL_DIG__ 15 +#define __DBL_EPSILON__ 2.2204460492503131e-16 +#define __DBL_HAS_DENORM__ 1 +#define __DBL_HAS_INFINITY__ 1 +#define __DBL_HAS_QUIET_NAN__ 1 +#define __DBL_MANT_DIG__ 53 +#define __DBL_MAX_10_EXP__ 308 +#define __DBL_MAX_EXP__ 1024 +#define __DBL_MAX__ 1.7976931348623157e+308 +#define __DBL_MIN_10_EXP__ (-307) +#define __DBL_MIN_EXP__ (-1021) +#define __DBL_MIN__ 2.2250738585072014e-308 +#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ +#define __DEFINED_FILE +#define __DEFINED___isoc_va_list +#define __DEFINED_blkcnt_t +#define __DEFINED_blksize_t +#define __DEFINED_clock_t +#define __DEFINED_clockid_t +#define __DEFINED_cnd_t +#define __DEFINED_dev_t +#define __DEFINED_double_t +#define __DEFINED_float_t +#define __DEFINED_fsblkcnt_t +#define __DEFINED_fsfilcnt_t +#define __DEFINED_gid_t +#define __DEFINED_id_t +#define __DEFINED_ino_t +#define __DEFINED_int16_t +#define __DEFINED_int32_t +#define __DEFINED_int64_t +#define __DEFINED_int8_t +#define __DEFINED_intmax_t +#define __DEFINED_intptr_t +#define __DEFINED_key_t +#define __DEFINED_locale_t +#define __DEFINED_mbstate_t +#define __DEFINED_mode_t +#define __DEFINED_mtx_t +#define __DEFINED_nlink_t +#define __DEFINED_off_t +#define __DEFINED_pid_t +#define __DEFINED_pthread_attr_t +#define __DEFINED_pthread_barrier_t +#define __DEFINED_pthread_barrierattr_t +#define __DEFINED_pthread_cond_t +#define __DEFINED_pthread_condattr_t +#define __DEFINED_pthread_key_t +#define __DEFINED_pthread_mutex_t +#define __DEFINED_pthread_mutexattr_t +#define __DEFINED_pthread_once_t +#define __DEFINED_pthread_rwlock_t +#define __DEFINED_pthread_rwlockattr_t +#define __DEFINED_pthread_spinlock_t +#define __DEFINED_pthread_t +#define __DEFINED_register_t +#define __DEFINED_regoff_t +#define __DEFINED_sa_family_t +#define __DEFINED_sigset_t +#define __DEFINED_size_t +#define __DEFINED_socklen_t +#define __DEFINED_ssize_t +#define __DEFINED_suseconds_t +#define __DEFINED_time_t +#define __DEFINED_timer_t +#define __DEFINED_u_int64_t +#define __DEFINED_uid_t +#define __DEFINED_uint16_t +#define __DEFINED_uint32_t +#define __DEFINED_uint64_t +#define __DEFINED_uint8_t +#define __DEFINED_uintmax_t +#define __DEFINED_uintptr_t +#define __DEFINED_useconds_t +#define __DEFINED_va_list +#define __DEFINED_wchar_t +#define __DEFINED_wctype_t +#define __DEFINED_wint_t +#define __FINITE_MATH_ONLY__ 0 +#define __FLOAT128__ 1 +#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) +#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) +#define __FLT_DECIMAL_DIG__ 9 +#define __FLT_DENORM_MIN__ 1.40129846e-45F +#define __FLT_DIG__ 6 +#define __FLT_EPSILON__ 1.19209290e-7F +#define __FLT_HAS_DENORM__ 1 +#define __FLT_HAS_INFINITY__ 1 +#define __FLT_HAS_QUIET_NAN__ 1 +#define __FLT_MANT_DIG__ 24 +#define __FLT_MAX_10_EXP__ 38 +#define __FLT_MAX_EXP__ 128 +#define __FLT_MAX__ 3.40282347e+38F +#define __FLT_MIN_10_EXP__ (-37) +#define __FLT_MIN_EXP__ (-125) +#define __FLT_MIN__ 1.17549435e-38F +#define __FLT_RADIX__ 2 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __GNUC_STDC_INLINE__ 1 +#define __GNUC_VA_LIST 1 +#define __GXX_ABI_VERSION 1002 +#define __INT16_C_SUFFIX__ +#define __INT16_FMTd__ "hd" +#define __INT16_FMTi__ "hi" +#define __INT16_MAX__ 32767 +#define __INT16_TYPE__ short +#define __INT32_C_SUFFIX__ +#define __INT32_FMTd__ "d" +#define __INT32_FMTi__ "i" +#define __INT32_MAX__ 2147483647 +#define __INT32_TYPE__ int +#define __INT64_C_SUFFIX__ LL +#define __INT64_FMTd__ "lld" +#define __INT64_FMTi__ "lli" +#define __INT64_MAX__ 9223372036854775807LL +#define __INT64_TYPE__ long long int +#define __INT8_C_SUFFIX__ +#define __INT8_FMTd__ "hhd" +#define __INT8_FMTi__ "hhi" +#define __INT8_MAX__ 127 +#define __INT8_TYPE__ signed char +#define __INTMAX_C_SUFFIX__ LL +#define __INTMAX_FMTd__ "lld" +#define __INTMAX_FMTi__ "lli" +#define __INTMAX_MAX__ 9223372036854775807LL +#define __INTMAX_TYPE__ long long int +#define __INTMAX_WIDTH__ 64 +#define __INTPTR_FMTd__ "ld" +#define __INTPTR_FMTi__ "li" +#define __INTPTR_MAX__ 9223372036854775807L +#define __INTPTR_TYPE__ long int +#define __INTPTR_WIDTH__ 64 +#define __INT_FAST16_FMTd__ "hd" +#define __INT_FAST16_FMTi__ "hi" +#define __INT_FAST16_MAX__ 32767 +#define __INT_FAST16_TYPE__ short +#define __INT_FAST32_FMTd__ "d" +#define __INT_FAST32_FMTi__ "i" +#define __INT_FAST32_MAX__ 2147483647 +#define __INT_FAST32_TYPE__ int +#define __INT_FAST64_FMTd__ "lld" +#define __INT_FAST64_FMTi__ "lli" +#define __INT_FAST64_MAX__ 9223372036854775807LL +#define __INT_FAST64_TYPE__ long long int +#define __INT_FAST8_FMTd__ "hhd" +#define __INT_FAST8_FMTi__ "hhi" +#define __INT_FAST8_MAX__ 127 +#define __INT_FAST8_TYPE__ signed char +#define __INT_LEAST16_FMTd__ "hd" +#define __INT_LEAST16_FMTi__ "hi" +#define __INT_LEAST16_MAX__ 32767 +#define __INT_LEAST16_TYPE__ short +#define __INT_LEAST32_FMTd__ "d" +#define __INT_LEAST32_FMTi__ "i" +#define __INT_LEAST32_MAX__ 2147483647 +#define __INT_LEAST32_TYPE__ int +#define __INT_LEAST64_FMTd__ "lld" +#define __INT_LEAST64_FMTi__ "lli" +#define __INT_LEAST64_MAX__ 9223372036854775807LL +#define __INT_LEAST64_TYPE__ long long int +#define __INT_LEAST8_FMTd__ "hhd" +#define __INT_LEAST8_FMTi__ "hhi" +#define __INT_LEAST8_MAX__ 127 +#define __INT_LEAST8_TYPE__ signed char +#define __INT_MAX__ 2147483647 +#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) +#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) +#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) +#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) +#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) +#define __LDBL_DECIMAL_DIG__ 36 +#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L +#define __LDBL_DIG__ 33 +#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L +#define __LDBL_HAS_DENORM__ 1 +#define __LDBL_HAS_INFINITY__ 1 +#define __LDBL_HAS_QUIET_NAN__ 1 +#define __LDBL_MANT_DIG__ 113 +#define __LDBL_MAX_10_EXP__ 4932 +#define __LDBL_MAX_EXP__ 16384 +#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L +#define __LDBL_MIN_10_EXP__ (-4931) +#define __LDBL_MIN_EXP__ (-16381) +#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L +#define __LITTLE_ENDIAN 1234 +#define __LITTLE_ENDIAN__ 1 +#define __LONG_LONG_MAX__ 9223372036854775807LL +#define __LONG_MAX __LONG_MAX__ +#define __LONG_MAX__ 9223372036854775807L +#define __LP64__ 1 +#define __NAMESER 19991006 +#define __NEED_FILE +#define __NEED___isoc_va_list +#define __NEED_blkcnt_t +#define __NEED_blksize_t +#define __NEED_clock_t +#define __NEED_clockid_t +#define __NEED_cnd_t +#define __NEED_dev_t +#define __NEED_double_t +#define __NEED_float_t +#define __NEED_fsblkcnt_t +#define __NEED_fsfilcnt_t +#define __NEED_gid_t +#define __NEED_id_t +#define __NEED_ino_t +#define __NEED_int16_t +#define __NEED_int32_t +#define __NEED_int64_t +#define __NEED_int8_t +#define __NEED_intmax_t +#define __NEED_intptr_t +#define __NEED_key_t +#define __NEED_locale_t +#define __NEED_mbstate_t +#define __NEED_mode_t +#define __NEED_mtx_t +#define __NEED_nlink_t +#define __NEED_off_t +#define __NEED_pid_t +#define __NEED_pthread_attr_t +#define __NEED_pthread_barrier_t +#define __NEED_pthread_barrierattr_t +#define __NEED_pthread_cond_t +#define __NEED_pthread_condattr_t +#define __NEED_pthread_key_t +#define __NEED_pthread_mutex_t +#define __NEED_pthread_mutexattr_t +#define __NEED_pthread_once_t +#define __NEED_pthread_rwlock_t +#define __NEED_pthread_rwlockattr_t +#define __NEED_pthread_spinlock_t +#define __NEED_pthread_t +#define __NEED_register_t +#define __NEED_regoff_t +#define __NEED_sa_family_t +#define __NEED_sigset_t +#define __NEED_size_t +#define __NEED_socklen_t +#define __NEED_ssize_t +#define __NEED_struct_iovec +#define __NEED_struct_timespec +#define __NEED_struct_timeval +#define __NEED_suseconds_t +#define __NEED_time_t +#define __NEED_timer_t +#define __NEED_u_int64_t +#define __NEED_uid_t +#define __NEED_uint16_t +#define __NEED_uint32_t +#define __NEED_uint64_t +#define __NEED_uint8_t +#define __NEED_uintmax_t +#define __NEED_uintptr_t +#define __NEED_useconds_t +#define __NEED_va_list +#define __NEED_wchar_t +#define __NEED_wctype_t +#define __NEED_wint_t +#define __OBJC_BOOL_IS_BOOL 0 +#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 +#define __OPENCL_MEMORY_SCOPE_DEVICE 2 +#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 +#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 +#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 +#define __ORDER_BIG_ENDIAN__ 4321 +#define __ORDER_LITTLE_ENDIAN__ 1234 +#define __ORDER_PDP_ENDIAN__ 3412 +#define __PDP_ENDIAN 3412 +#define __POINTER_WIDTH__ 64 +#define __PRAGMA_REDEFINE_EXTNAME 1 +#define __PTRDIFF_FMTd__ "ld" +#define __PTRDIFF_FMTi__ "li" +#define __PTRDIFF_MAX__ 9223372036854775807L +#define __PTRDIFF_TYPE__ long int +#define __PTRDIFF_WIDTH__ 64 +#define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#define __RETCAST(x) +#define __RETCAST_2(x,y) +#define __RETCAST_3(x,y,z) +#define __RETCAST_CX(x) +#define __RETCAST_REAL(x) +#define __SCHAR_MAX__ 127 +#define __SHRT_MAX__ 32767 +#define __SID ('S' << 8) +#define __SIG_ATOMIC_MAX__ 9223372036854775807L +#define __SIG_ATOMIC_WIDTH__ 64 +#define __SIZEOF_DOUBLE__ 8 +#define __SIZEOF_FLOAT__ 4 +#define __SIZEOF_INT128__ 16 +#define __SIZEOF_INT__ 4 +#define __SIZEOF_LONG_DOUBLE__ 16 +#define __SIZEOF_LONG_LONG__ 8 +#define __SIZEOF_LONG__ 8 +#define __SIZEOF_POINTER__ 8 +#define __SIZEOF_PTRDIFF_T__ 8 +#define __SIZEOF_SHORT__ 2 +#define __SIZEOF_SIZE_T__ 8 +#define __SIZEOF_WCHAR_T__ 4 +#define __SIZEOF_WINT_T__ 4 +#define __SIZE_FMTX__ "lX" +#define __SIZE_FMTo__ "lo" +#define __SIZE_FMTu__ "lu" +#define __SIZE_FMTx__ "lx" +#define __SIZE_MAX__ 18446744073709551615UL +#define __SIZE_TYPE__ long unsigned int +#define __SIZE_WIDTH__ 64 +#define __STDARG_H +#define __STDC_HOSTED__ 1 +#define __STDC_IEC_559__ 1 +#define __STDC_ISO_10646__ 201206L +#define __STDC_UTF_16__ 1 +#define __STDC_UTF_32__ 1 +#define __STDC_VERSION__ 201710L +#define __STDC__ 1 +#define __STDDEF_H +#define __UAPI_DEF_IN6_ADDR 0 +#define __UAPI_DEF_IN6_ADDR_ALT 0 +#define __UAPI_DEF_IN6_PKTINFO 0 +#define __UAPI_DEF_IN_ADDR 0 +#define __UAPI_DEF_IN_CLASS 0 +#define __UAPI_DEF_IN_IPPROTO 0 +#define __UAPI_DEF_IN_PKTINFO 0 +#define __UAPI_DEF_IP6_MTUINFO 0 +#define __UAPI_DEF_IPHDR 0 +#define __UAPI_DEF_IPPROTO_V6 0 +#define __UAPI_DEF_IPV6_MREQ 0 +#define __UAPI_DEF_IPV6_OPTIONS 0 +#define __UAPI_DEF_IP_MREQ 0 +#define __UAPI_DEF_SOCKADDR_IN 0 +#define __UAPI_DEF_SOCKADDR_IN6 0 +#define __UINT16_C_SUFFIX__ +#define __UINT16_FMTX__ "hX" +#define __UINT16_FMTo__ "ho" +#define __UINT16_FMTu__ "hu" +#define __UINT16_FMTx__ "hx" +#define __UINT16_MAX__ 65535 +#define __UINT16_TYPE__ unsigned short +#define __UINT32_C_SUFFIX__ U +#define __UINT32_FMTX__ "X" +#define __UINT32_FMTo__ "o" +#define __UINT32_FMTu__ "u" +#define __UINT32_FMTx__ "x" +#define __UINT32_MAX__ 4294967295U +#define __UINT32_TYPE__ unsigned int +#define __UINT64_C_SUFFIX__ ULL +#define __UINT64_FMTX__ "llX" +#define __UINT64_FMTo__ "llo" +#define __UINT64_FMTu__ "llu" +#define __UINT64_FMTx__ "llx" +#define __UINT64_MAX__ 18446744073709551615ULL +#define __UINT64_TYPE__ long long unsigned int +#define __UINT8_C_SUFFIX__ +#define __UINT8_FMTX__ "hhX" +#define __UINT8_FMTo__ "hho" +#define __UINT8_FMTu__ "hhu" +#define __UINT8_FMTx__ "hhx" +#define __UINT8_MAX__ 255 +#define __UINT8_TYPE__ unsigned char +#define __UINTMAX_C_SUFFIX__ ULL +#define __UINTMAX_FMTX__ "llX" +#define __UINTMAX_FMTo__ "llo" +#define __UINTMAX_FMTu__ "llu" +#define __UINTMAX_FMTx__ "llx" +#define __UINTMAX_MAX__ 18446744073709551615ULL +#define __UINTMAX_TYPE__ long long unsigned int +#define __UINTMAX_WIDTH__ 64 +#define __UINTPTR_FMTX__ "lX" +#define __UINTPTR_FMTo__ "lo" +#define __UINTPTR_FMTu__ "lu" +#define __UINTPTR_FMTx__ "lx" +#define __UINTPTR_MAX__ 18446744073709551615UL +#define __UINTPTR_TYPE__ long unsigned int +#define __UINTPTR_WIDTH__ 64 +#define __UINT_FAST16_FMTX__ "hX" +#define __UINT_FAST16_FMTo__ "ho" +#define __UINT_FAST16_FMTu__ "hu" +#define __UINT_FAST16_FMTx__ "hx" +#define __UINT_FAST16_MAX__ 65535 +#define __UINT_FAST16_TYPE__ unsigned short +#define __UINT_FAST32_FMTX__ "X" +#define __UINT_FAST32_FMTo__ "o" +#define __UINT_FAST32_FMTu__ "u" +#define __UINT_FAST32_FMTx__ "x" +#define __UINT_FAST32_MAX__ 4294967295U +#define __UINT_FAST32_TYPE__ unsigned int +#define __UINT_FAST64_FMTX__ "llX" +#define __UINT_FAST64_FMTo__ "llo" +#define __UINT_FAST64_FMTu__ "llu" +#define __UINT_FAST64_FMTx__ "llx" +#define __UINT_FAST64_MAX__ 18446744073709551615ULL +#define __UINT_FAST64_TYPE__ long long unsigned int +#define __UINT_FAST8_FMTX__ "hhX" +#define __UINT_FAST8_FMTo__ "hho" +#define __UINT_FAST8_FMTu__ "hhu" +#define __UINT_FAST8_FMTx__ "hhx" +#define __UINT_FAST8_MAX__ 255 +#define __UINT_FAST8_TYPE__ unsigned char +#define __UINT_LEAST16_FMTX__ "hX" +#define __UINT_LEAST16_FMTo__ "ho" +#define __UINT_LEAST16_FMTu__ "hu" +#define __UINT_LEAST16_FMTx__ "hx" +#define __UINT_LEAST16_MAX__ 65535 +#define __UINT_LEAST16_TYPE__ unsigned short +#define __UINT_LEAST32_FMTX__ "X" +#define __UINT_LEAST32_FMTo__ "o" +#define __UINT_LEAST32_FMTu__ "u" +#define __UINT_LEAST32_FMTx__ "x" +#define __UINT_LEAST32_MAX__ 4294967295U +#define __UINT_LEAST32_TYPE__ unsigned int +#define __UINT_LEAST64_FMTX__ "llX" +#define __UINT_LEAST64_FMTo__ "llo" +#define __UINT_LEAST64_FMTu__ "llu" +#define __UINT_LEAST64_FMTx__ "llx" +#define __UINT_LEAST64_MAX__ 18446744073709551615ULL +#define __UINT_LEAST64_TYPE__ long long unsigned int +#define __UINT_LEAST8_FMTX__ "hhX" +#define __UINT_LEAST8_FMTo__ "hho" +#define __UINT_LEAST8_FMTu__ "hhu" +#define __UINT_LEAST8_FMTx__ "hhx" +#define __UINT_LEAST8_MAX__ 255 +#define __UINT_LEAST8_TYPE__ unsigned char +#define __USER_LABEL_PREFIX__ +#define __USE_TIME_BITS64 1 +#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) +#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) +#define __WASI_ADVICE_NORMAL (UINT8_C(0)) +#define __WASI_ADVICE_RANDOM (UINT8_C(2)) +#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) +#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) +#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) +#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) +#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) +#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) +#define __WASI_DIRCOOKIE_START (UINT64_C(0)) +#define __WASI_ERRNO_2BIG (UINT16_C(1)) +#define __WASI_ERRNO_ACCES (UINT16_C(2)) +#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) +#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) +#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) +#define __WASI_ERRNO_AGAIN (UINT16_C(6)) +#define __WASI_ERRNO_ALREADY (UINT16_C(7)) +#define __WASI_ERRNO_BADF (UINT16_C(8)) +#define __WASI_ERRNO_BADMSG (UINT16_C(9)) +#define __WASI_ERRNO_BUSY (UINT16_C(10)) +#define __WASI_ERRNO_CANCELED (UINT16_C(11)) +#define __WASI_ERRNO_CHILD (UINT16_C(12)) +#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) +#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) +#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) +#define __WASI_ERRNO_DEADLK (UINT16_C(16)) +#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) +#define __WASI_ERRNO_DOM (UINT16_C(18)) +#define __WASI_ERRNO_DQUOT (UINT16_C(19)) +#define __WASI_ERRNO_EXIST (UINT16_C(20)) +#define __WASI_ERRNO_FAULT (UINT16_C(21)) +#define __WASI_ERRNO_FBIG (UINT16_C(22)) +#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) +#define __WASI_ERRNO_IDRM (UINT16_C(24)) +#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) +#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) +#define __WASI_ERRNO_INTR (UINT16_C(27)) +#define __WASI_ERRNO_INVAL (UINT16_C(28)) +#define __WASI_ERRNO_IO (UINT16_C(29)) +#define __WASI_ERRNO_ISCONN (UINT16_C(30)) +#define __WASI_ERRNO_ISDIR (UINT16_C(31)) +#define __WASI_ERRNO_LOOP (UINT16_C(32)) +#define __WASI_ERRNO_MFILE (UINT16_C(33)) +#define __WASI_ERRNO_MLINK (UINT16_C(34)) +#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) +#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) +#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) +#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) +#define __WASI_ERRNO_NETRESET (UINT16_C(39)) +#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) +#define __WASI_ERRNO_NFILE (UINT16_C(41)) +#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) +#define __WASI_ERRNO_NODEV (UINT16_C(43)) +#define __WASI_ERRNO_NOENT (UINT16_C(44)) +#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) +#define __WASI_ERRNO_NOLCK (UINT16_C(46)) +#define __WASI_ERRNO_NOLINK (UINT16_C(47)) +#define __WASI_ERRNO_NOMEM (UINT16_C(48)) +#define __WASI_ERRNO_NOMSG (UINT16_C(49)) +#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) +#define __WASI_ERRNO_NOSPC (UINT16_C(51)) +#define __WASI_ERRNO_NOSYS (UINT16_C(52)) +#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) +#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) +#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) +#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) +#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) +#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) +#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) +#define __WASI_ERRNO_NOTTY (UINT16_C(59)) +#define __WASI_ERRNO_NXIO (UINT16_C(60)) +#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) +#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) +#define __WASI_ERRNO_PERM (UINT16_C(63)) +#define __WASI_ERRNO_PIPE (UINT16_C(64)) +#define __WASI_ERRNO_PROTO (UINT16_C(65)) +#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) +#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) +#define __WASI_ERRNO_RANGE (UINT16_C(68)) +#define __WASI_ERRNO_ROFS (UINT16_C(69)) +#define __WASI_ERRNO_SPIPE (UINT16_C(70)) +#define __WASI_ERRNO_SRCH (UINT16_C(71)) +#define __WASI_ERRNO_STALE (UINT16_C(72)) +#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) +#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) +#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) +#define __WASI_ERRNO_XDEV (UINT16_C(75)) +#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) +#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) +#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) +#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) +#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) +#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) +#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) +#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) +#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) +#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) +#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) +#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) +#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) +#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) +#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) +#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) +#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) +#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) +#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) +#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) +#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) +#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT +#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) +#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) +#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) +#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) +#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) +#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) +#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) +#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) +#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) +#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) +#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) +#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) +#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) +#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) +#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) +#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) +#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) +#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) +#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) +#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) +#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) +#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) +#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) +#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) +#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) +#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) +#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) +#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) +#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) +#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) +#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) +#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) +#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) +#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) +#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) +#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) +#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) +#define __WASI_WHENCE_CUR (UINT8_C(1)) +#define __WASI_WHENCE_END (UINT8_C(2)) +#define __WASI_WHENCE_SET (UINT8_C(0)) +#define __WCHAR_MAX__ 2147483647 +#define __WCHAR_TYPE__ int +#define __WCHAR_WIDTH__ 32 +#define __WINT_MAX__ 2147483647 +#define __WINT_TYPE__ int +#define __WINT_WIDTH__ 32 +#define __WORDSIZE 64 +#define __alignas_is_defined 1 +#define __alignof_is_defined 1 +#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) +#define __bool_true_false_are_defined 1 +#define __inline inline +#define __restrict restrict +#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) +#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) +#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) +#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) +#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) +#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) +#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) +#define __tm_gmtoff tm_gmtoff +#define __tm_zone tm_zone +#define __va_copy(d,s) __builtin_va_copy(d, s) +#define __wasi__ 1 +#define __wasi_api_h +#define __wasi_libc_environ_h +#define __wasi_libc_find_relpath_h +#define __wasi_libc_h +#define __wasi_libc_nocwd_h +#define __wasilibc___errno_h +#define __wasilibc___errno_values_h +#define __wasilibc___fd_set_h +#define __wasilibc___function___isatty_h +#define __wasilibc___functions_malloc_h +#define __wasilibc___functions_memcpy_h +#define __wasilibc___header_dirent_h +#define __wasilibc___header_fcntl_h +#define __wasilibc___header_netinet_in_h +#define __wasilibc___header_poll_h +#define __wasilibc___header_stdlib_h +#define __wasilibc___header_string_h +#define __wasilibc___header_sys_ioctl_h +#define __wasilibc___header_sys_resource_h +#define __wasilibc___header_sys_socket_h +#define __wasilibc___header_sys_stat_h +#define __wasilibc___header_time_h +#define __wasilibc___header_unistd_h +#define __wasilibc___include_inttypes_h +#define __wasilibc___macro_FD_SETSIZE_h +#define __wasilibc___macro_PAGESIZE_h +#define __wasilibc___mode_t_h +#define __wasilibc___seek_h +#define __wasilibc___struct_dirent_h +#define __wasilibc___struct_in6_addr_h +#define __wasilibc___struct_in_addr_h +#define __wasilibc___struct_iovec_h +#define __wasilibc___struct_msghdr_h +#define __wasilibc___struct_pollfd_h +#define __wasilibc___struct_rusage_h +#define __wasilibc___struct_sockaddr_h +#define __wasilibc___struct_sockaddr_in6_h +#define __wasilibc___struct_sockaddr_in_h +#define __wasilibc___struct_sockaddr_storage_h +#define __wasilibc___struct_sockaddr_un_h +#define __wasilibc___struct_stat_h +#define __wasilibc___struct_timespec_h +#define __wasilibc___struct_timeval_h +#define __wasilibc___struct_tm_h +#define __wasilibc___struct_tms_h +#define __wasilibc___typedef_DIR_h +#define __wasilibc___typedef_blkcnt_t_h +#define __wasilibc___typedef_blksize_t_h +#define __wasilibc___typedef_clock_t_h +#define __wasilibc___typedef_clockid_t_h +#define __wasilibc___typedef_dev_t_h +#define __wasilibc___typedef_fd_set_h +#define __wasilibc___typedef_gid_t_h +#define __wasilibc___typedef_in_addr_t_h +#define __wasilibc___typedef_in_port_t_h +#define __wasilibc___typedef_ino_t_h +#define __wasilibc___typedef_mode_t_h +#define __wasilibc___typedef_nfds_t_h +#define __wasilibc___typedef_nlink_t_h +#define __wasilibc___typedef_off_t_h +#define __wasilibc___typedef_sa_family_t_h +#define __wasilibc___typedef_sigset_t_h +#define __wasilibc___typedef_socklen_t_h +#define __wasilibc___typedef_ssize_t_h +#define __wasilibc___typedef_suseconds_t_h +#define __wasilibc___typedef_time_t_h +#define __wasilibc___typedef_uid_t_h +#define __wasm 1 +#define __wasm64 1 +#define __wasm64__ 1 +#define __wasm__ 1 +#define __wasm_atomics__ 1 +#define __wasm_bulk_memory__ 1 +#define _tolower(a) ((a)|0x20) +#define _toupper(a) ((a)&0x5f) +#define acos(x) __tg_real_complex(acos, (x)) +#define acosh(x) __tg_real_complex(acosh, (x)) +#define alignas _Alignas +#define alignof _Alignof +#define alloca __builtin_alloca +#define alphasort64 alphasort +#define and && +#define and_eq &= +#define asin(x) __tg_real_complex(asin, (x)) +#define asinh(x) __tg_real_complex(asinh, (x)) +#define atan(x) __tg_real_complex(atan, (x)) +#define atan2(x,y) __tg_real_2(atan2, (x), (y)) +#define atanh(x) __tg_real_complex(atanh, (x)) +#define be16toh(x) __bswap16(x) +#define be32toh(x) __bswap32(x) +#define be64toh(x) __bswap64(x) +#define betoh16(x) __bswap16(x) +#define betoh32(x) __bswap32(x) +#define betoh64(x) __bswap64(x) +#define bitand & +#define bitor | +#define blkcnt64_t blkcnt_t +#define bool _Bool +#define bswap_16(x) __bswap_16(x) +#define bswap_32(x) __bswap_32(x) +#define bswap_64(x) __bswap_64(x) +#define carg(x) __tg_complex_retreal(carg, (x)) +#define cbrt(x) __tg_real(cbrt, (x)) +#define ceil(x) __tg_real(ceil, (x)) +#define cimag(x) __tg_complex_retreal(cimag, (x)) +#define cimagf(x) (__builtin_cimagf(x)) +#define cimagl(x) (__builtin_cimagl(x)) +#define clrbit(x,i) __bitop(x,i,&=~) +#define compl ~ +#define complex _Complex +#define conj(x) __tg_complex(conj, (x)) +#define copysign(x,y) __tg_real_2(copysign, (x), (y)) +#define cos(x) __tg_real_complex(cos, (x)) +#define cosh(x) __tg_real_complex(cosh, (x)) +#define cproj(x) __tg_complex(cproj, (x)) +#define creal(x) __tg_complex_retreal(creal, (x)) +#define crealf(x) (__builtin_crealf(x)) +#define creall(x) (__builtin_creall(x)) +#define creat64 creat +#define d_fileno d_ino +#define direct dirent +#define dirent64 dirent +#define erf(x) __tg_real(erf, (x)) +#define erfc(x) __tg_real(erfc, (x)) +#define errno errno +#define exp(x) __tg_real_complex(exp, (x)) +#define exp2(x) __tg_real(exp2, (x)) +#define expm1(x) __tg_real(expm1, (x)) +#define fabs(x) __tg_real_complex_fabs(x) +#define false 0 +#define fdim(x,y) __tg_real_2(fdim, (x), (y)) +#define fgetpos64 fgetpos +#define floor(x) __tg_real(floor, (x)) +#define fma(x,y,z) __tg_real_fma((x), (y), (z)) +#define fmax(x,y) __tg_real_2(fmax, (x), (y)) +#define fmin(x,y) __tg_real_2(fmin, (x), (y)) +#define fmod(x,y) __tg_real_2(fmod, (x), (y)) +#define fopen64 fopen +#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) +#define fpos64_t fpos_t +#define freopen64 freopen +#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) +#define fsblkcnt64_t fsblkcnt_t +#define fseeko64 fseeko +#define fsetpos64 fsetpos +#define fsfilcnt64_t fsfilcnt_t +#define fstat64 fstat +#define fstatat64 fstatat +#define fstatvfs64 fstatvfs +#define ftello64 ftello +#define ftruncate64 ftruncate +#define getdents64 getdents +#define glob64 glob +#define glob64_t glob_t +#define globfree64 globfree +#define howmany(n,d) (((n)+((d)-1))/(d)) +#define htobe16(x) __bswap16(x) +#define htobe32(x) __bswap32(x) +#define htobe64(x) __bswap64(x) +#define htole16(x) (uint16_t)(x) +#define htole32(x) (uint32_t)(x) +#define htole64(x) (uint64_t)(x) +#define hypot(x,y) __tg_real_2(hypot, (x), (y)) +#define icmp6_data16 icmp6_dataun.icmp6_un_data16 +#define icmp6_data32 icmp6_dataun.icmp6_un_data32 +#define icmp6_data8 icmp6_dataun.icmp6_un_data8 +#define icmp6_id icmp6_data16[0] +#define icmp6_maxdelay icmp6_data16[0] +#define icmp6_mtu icmp6_data32[0] +#define icmp6_pptr icmp6_data32[0] +#define icmp6_seq icmp6_data16[1] +#define icmp_data icmp_dun.id_data +#define icmp_gwaddr icmp_hun.ih_gwaddr +#define icmp_id icmp_hun.ih_idseq.icd_id +#define icmp_ip icmp_dun.id_ip.idi_ip +#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime +#define icmp_mask icmp_dun.id_mask +#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu +#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs +#define icmp_otime icmp_dun.id_ts.its_otime +#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void +#define icmp_pptr icmp_hun.ih_pptr +#define icmp_radv icmp_dun.id_radv +#define icmp_rtime icmp_dun.id_ts.its_rtime +#define icmp_seq icmp_hun.ih_idseq.icd_seq +#define icmp_ttime icmp_dun.id_ts.its_ttime +#define icmp_void icmp_hun.ih_void +#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa +#define ifa_broadaddr ifa_ifu.ifu_broadaddr +#define ifa_dstaddr ifa_ifu.ifu_dstaddr +#define ilogb(x) __tg_real_nocast(ilogb, (x)) +#define ino64_t ino_t +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) +#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) +#define isclr(x,i) !isset(x,i) +#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) +#define isfinite(x) (__builtin_isfinite(x)) +#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) +#define isgreater(x,y) (__builtin_isgreater(x, y)) +#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) +#define isinf(x) (__builtin_isinf(x)) +#define isless(x,y) (__builtin_isless(x, y)) +#define islessequal(x,y) (__builtin_islessequal(x, y)) +#define islessgreater(x,y) (__builtin_islessgreater(x, y)) +#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) +#define isnan(x) (__builtin_isnan(x)) +#define isnormal(x) (__builtin_isnormal(x)) +#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) +#define isset(x,i) __bitop(x,i,&) +#define isspace(a) __isspace(a) +#define isunordered(x,y) (__builtin_isunordered(x, y)) +#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) +#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) +#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) +#define le16toh(x) (uint16_t)(x) +#define le32toh(x) (uint32_t)(x) +#define le64toh(x) (uint64_t)(x) +#define letoh16(x) (uint16_t)(x) +#define letoh32(x) (uint32_t)(x) +#define letoh64(x) (uint64_t)(x) +#define lgamma(x) __tg_real(lgamma, (x)) +#define llrint(x) __tg_real_nocast(llrint, (x)) +#define llround(x) __tg_real_nocast(llround, (x)) +#define loff_t off_t +#define log(x) __tg_real_complex(log, (x)) +#define log10(x) __tg_real(log10, (x)) +#define log1p(x) __tg_real(log1p, (x)) +#define log2(x) __tg_real(log2, (x)) +#define logb(x) __tg_real(logb, (x)) +#define lrint(x) __tg_real_nocast(lrint, (x)) +#define lround(x) __tg_real_nocast(lround, (x)) +#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) +#define lseek64 lseek +#define lstat64 lstat +#define math_errhandling 2 +#define mld_cksum mld_icmp6_hdr.icmp6_cksum +#define mld_code mld_icmp6_hdr.icmp6_code +#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] +#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] +#define mld_type mld_icmp6_hdr.icmp6_type +#define nd_na_cksum nd_na_hdr.icmp6_cksum +#define nd_na_code nd_na_hdr.icmp6_code +#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] +#define nd_na_type nd_na_hdr.icmp6_type +#define nd_ns_cksum nd_ns_hdr.icmp6_cksum +#define nd_ns_code nd_ns_hdr.icmp6_code +#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] +#define nd_ns_type nd_ns_hdr.icmp6_type +#define nd_ra_cksum nd_ra_hdr.icmp6_cksum +#define nd_ra_code nd_ra_hdr.icmp6_code +#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] +#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] +#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] +#define nd_ra_type nd_ra_hdr.icmp6_type +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rs_cksum nd_rs_hdr.icmp6_cksum +#define nd_rs_code nd_rs_hdr.icmp6_code +#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] +#define nd_rs_type nd_rs_hdr.icmp6_type +#define nearbyint(x) __tg_real(nearbyint, (x)) +#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) +#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) +#define nftw64 nftw +#define no_argument 0 +#define noreturn _Noreturn +#define not ! +#define not_eq != +#define ns_msg_base(handle) ((handle)._msg + 0) +#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) +#define ns_msg_end(handle) ((handle)._eom + 0) +#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) +#define ns_msg_id(handle) ((handle)._id + 0) +#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) +#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) +#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") +#define ns_rr_rdata(rr) ((rr).rdata + 0) +#define ns_rr_rdlen(rr) ((rr).rdlength + 0) +#define ns_rr_ttl(rr) ((rr).ttl + 0) +#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) +#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) +#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) +#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) +#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) +#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) +#define off64_t off_t +#define offsetof(t,d) __builtin_offsetof(t, d) +#define open64 open +#define openat64 openat +#define optional_argument 2 +#define or || +#define or_eq |= +#define posix_fadvise64 posix_fadvise +#define posix_fallocate64 posix_fallocate +#define pow(x,y) __tg_real_complex_pow((x), (y)) +#define powerof2(n) !(((n)-1) & (n)) +#define pread64 pread +#define preadv64 preadv +#define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) +#define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); +#define pthread_equal(x,y) ((x)==(y)) +#define pwrite64 pwrite +#define pwritev64 pwritev +#define readdir64 readdir +#define remainder(x,y) __tg_real_2(remainder, (x), (y)) +#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) +#define required_argument 1 +#define rint(x) __tg_real(rint, (x)) +#define round(x) __tg_real(round, (x)) +#define roundup(n,d) (howmany(n,d)*(d)) +#define rr_cksum rr_hdr.icmp6_cksum +#define rr_code rr_hdr.icmp6_code +#define rr_seqnum rr_hdr.icmp6_data32[0] +#define rr_type rr_hdr.icmp6_type +#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) +#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) +#define scandir64 scandir +#define setbit(x,i) __bitop(x,i,|=) +#define signbit(x) (__builtin_signbit(x)) +#define sin(x) __tg_real_complex(sin, (x)) +#define sinh(x) __tg_real_complex(sinh, (x)) +#define sqrt(x) __tg_real_complex(sqrt, (x)) +#define st_atime st_atim.tv_sec +#define st_ctime st_ctim.tv_sec +#define st_mtime st_mtim.tv_sec +#define stat64 stat +#define static_assert _Static_assert +#define statvfs64 statvfs +#define stderr (stderr) +#define stdin (stdin) +#define stdout (stdout) +#define strdupa(x) strcpy(alloca(strlen(x)+1),x) +#define tan(x) __tg_real_complex(tan, (x)) +#define tanh(x) __tg_real_complex(tanh, (x)) +#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) +#define tgamma(x) __tg_real(tgamma, (x)) +#define th_block th_u.tu_block +#define th_code th_u.tu_code +#define th_msg th_data +#define th_stuff th_u.tu_stuff +#define thrd_equal(A,B) ((A) == (B)) +#define thread_local _Thread_local +#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) +#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) +#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) +#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) +#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) +#define true 1 +#define trunc(x) __tg_real(trunc, (x)) +#define uh_dport dest +#define uh_sport source +#define uh_sum check +#define uh_ulen len +#define va_arg(ap,type) __builtin_va_arg(ap, type) +#define va_copy(dest,src) __builtin_va_copy(dest, src) +#define va_end(ap) __builtin_va_end(ap) +#define va_start(ap,param) __builtin_va_start(ap, param) +#define versionsort64 versionsort +#define xEOF 236 +#define xor ^ +#define xor_eq ^= diff --git a/expected/wasm64-wasip1-threads/undefined-symbols.txt b/expected/wasm64-wasip1-threads/undefined-symbols.txt new file mode 100644 index 000000000..938e64776 --- /dev/null +++ b/expected/wasm64-wasip1-threads/undefined-symbols.txt @@ -0,0 +1,76 @@ +__addtf3 +__data_end +__divtf3 +__eqtf2 +__extenddftf2 +__extendsftf2 +__fixtfdi +__fixtfsi +__fixunstfsi +__floatditf +__floatsitf +__floatunsitf +__getf2 +__global_base +__gttf2 +__heap_base +__heap_end +__imported_wasi_snapshot_preview1_args_get +__imported_wasi_snapshot_preview1_args_sizes_get +__imported_wasi_snapshot_preview1_clock_res_get +__imported_wasi_snapshot_preview1_clock_time_get +__imported_wasi_snapshot_preview1_environ_get +__imported_wasi_snapshot_preview1_environ_sizes_get +__imported_wasi_snapshot_preview1_fd_advise +__imported_wasi_snapshot_preview1_fd_allocate +__imported_wasi_snapshot_preview1_fd_close +__imported_wasi_snapshot_preview1_fd_datasync +__imported_wasi_snapshot_preview1_fd_fdstat_get +__imported_wasi_snapshot_preview1_fd_fdstat_set_flags +__imported_wasi_snapshot_preview1_fd_fdstat_set_rights +__imported_wasi_snapshot_preview1_fd_filestat_get +__imported_wasi_snapshot_preview1_fd_filestat_set_size +__imported_wasi_snapshot_preview1_fd_filestat_set_times +__imported_wasi_snapshot_preview1_fd_pread +__imported_wasi_snapshot_preview1_fd_prestat_dir_name +__imported_wasi_snapshot_preview1_fd_prestat_get +__imported_wasi_snapshot_preview1_fd_pwrite +__imported_wasi_snapshot_preview1_fd_read +__imported_wasi_snapshot_preview1_fd_readdir +__imported_wasi_snapshot_preview1_fd_renumber +__imported_wasi_snapshot_preview1_fd_seek +__imported_wasi_snapshot_preview1_fd_sync +__imported_wasi_snapshot_preview1_fd_tell +__imported_wasi_snapshot_preview1_fd_write +__imported_wasi_snapshot_preview1_path_create_directory +__imported_wasi_snapshot_preview1_path_filestat_get +__imported_wasi_snapshot_preview1_path_filestat_set_times +__imported_wasi_snapshot_preview1_path_link +__imported_wasi_snapshot_preview1_path_open +__imported_wasi_snapshot_preview1_path_readlink +__imported_wasi_snapshot_preview1_path_remove_directory +__imported_wasi_snapshot_preview1_path_rename +__imported_wasi_snapshot_preview1_path_symlink +__imported_wasi_snapshot_preview1_path_unlink_file +__imported_wasi_snapshot_preview1_poll_oneoff +__imported_wasi_snapshot_preview1_proc_exit +__imported_wasi_snapshot_preview1_random_get +__imported_wasi_snapshot_preview1_sched_yield +__imported_wasi_snapshot_preview1_sock_accept +__imported_wasi_snapshot_preview1_sock_recv +__imported_wasi_snapshot_preview1_sock_send +__imported_wasi_snapshot_preview1_sock_shutdown +__imported_wasi_thread_spawn +__letf2 +__lttf2 +__netf2 +__stack_pointer +__subtf3 +__tls_align +__tls_base +__tls_size +__trunctfdf2 +__trunctfsf2 +__unordtf2 +__wasm_call_ctors +__wasm_init_tls diff --git a/expected/wasm64-wasip2/defined-symbols.txt b/expected/wasm64-wasip2/defined-symbols.txt new file mode 100644 index 000000000..6e743228b --- /dev/null +++ b/expected/wasm64-wasip2/defined-symbols.txt @@ -0,0 +1,1206 @@ +_CLOCK_MONOTONIC +_CLOCK_REALTIME +_Exit +_IO_feof_unlocked +_IO_ferror_unlocked +_IO_getc +_IO_getc_unlocked +_IO_putc +_IO_putc_unlocked +__EINVAL +__ENOMEM +__SIG_ERR +__SIG_IGN +__asctime_r +__assert_fail +__c_dot_utf8 +__c_dot_utf8_locale +__c_locale +__clock +__clock_gettime +__clock_nanosleep +__cos +__cosdf +__cosl +__crypt_blowfish +__crypt_des +__crypt_md5 +__crypt_r +__crypt_sha256 +__crypt_sha512 +__ctype_b_loc +__ctype_get_mb_cur_max +__ctype_tolower_loc +__ctype_toupper_loc +__cxa_atexit +__cxa_finalize +__des_setkey +__do_des +__duplocale +__env_rm_add +__errno_location +__exp2f_data +__exp_data +__expo2 +__expo2f +__fbufsize +__fclose_ca +__fdopen +__fesetround +__fgetwc_unlocked +__flbf +__floatscan +__fmodeflags +__fopen_rb_ca +__fpending +__fpurge +__fputwc_unlocked +__freadable +__freadahead +__freading +__freadptr +__freadptrinc +__freelocale +__fseeko +__fseeko_unlocked +__fseterr +__fsetlocking +__fsmu8 +__ftello +__ftello_unlocked +__funcs_on_exit +__funcs_on_quick_exit +__futimesat +__fwritable +__fwritex +__fwriting +__get_locale +__getdelim +__getentropy +__getopt_msg +__gmtime_r +__hwcap +__inet_aton +__init_ssp +__intscan +__invtrigl_R +__isalnum_l +__isalpha_l +__isatty +__isblank_l +__iscntrl_l +__isdigit_l +__isgraph_l +__islower_l +__isoc99_fscanf +__isoc99_fwscanf +__isoc99_scanf +__isoc99_sscanf +__isoc99_swscanf +__isoc99_vfscanf +__isoc99_vfwscanf +__isoc99_vscanf +__isoc99_vsscanf +__isoc99_vswscanf +__isoc99_vwscanf +__isoc99_wscanf +__isprint_l +__ispunct_l +__isspace_l +__isupper_l +__iswalnum_l +__iswalpha_l +__iswblank_l +__iswcntrl_l +__iswctype_l +__iswdigit_l +__iswgraph_l +__iswlower_l +__iswprint_l +__iswpunct_l +__iswspace_l +__iswupper_l +__iswxdigit_l +__isxdigit_l +__lctrans +__lctrans_cur +__lctrans_impl +__ldexp_cexp +__ldexp_cexpf +__lgamma_r +__lgammaf_r +__lgammal_r +__libc +__libc_calloc +__libc_free +__libc_malloc +__loc_is_allocated +__localtime_r +__log2_data +__log2f_data +__log_data +__logf_data +__lseek +__main_void +__math_divzero +__math_divzerof +__math_invalid +__math_invalidf +__math_invalidl +__math_oflow +__math_oflowf +__math_uflow +__math_uflowf +__math_xflow +__math_xflowf +__memrchr +__mo_lookup +__month_to_secs +__newlocale +__nl_langinfo +__nl_langinfo_l +__ofl_add +__ofl_lock +__ofl_unlock +__optpos +__optreset +__overflow +__p1evll +__pio2_hi +__pio2_lo +__pleval +__polevll +__posix_getopt +__pow_log_data +__powf_log2_data +__progname +__progname_full +__putenv +__qsort_r +__rand48_step +__reallocarray +__rem_pio2 +__rem_pio2_large +__rem_pio2f +__rem_pio2l +__rsqrt_tab +__secs_to_tm +__secs_to_zone +__seed48 +__shgetc +__shlim +__signgam +__sin +__sindf +__sinl +__small_printf +__stack_chk_fail +__stack_chk_fail_local +__stack_chk_guard +__stderr_FILE +__stderr_used +__stdin_FILE +__stdin_used +__stdio_close +__stdio_exit +__stdio_exit_needed +__stdio_read +__stdio_seek +__stdio_write +__stdout_FILE +__stdout_used +__stdout_write +__stpcpy +__stpncpy +__strcasecmp_l +__strchrnul +__strcoll_l +__strerror_l +__strftime_fmt_1 +__strftime_l +__strncasecmp_l +__strtod_l +__strtof_l +__strtoimax_internal +__strtol_internal +__strtold_l +__strtoll_internal +__strtoul_internal +__strtoull_internal +__strtoumax_internal +__strxfrm_l +__sysinfo +__sysv_signal +__tan +__tandf +__tanl +__tm_to_secs +__tm_to_tzname +__tolower_l +__toread +__toread_needs_stdio_exit +__toupper_l +__towctrans_l +__towlower_l +__towrite +__towrite_needs_stdio_exit +__towupper_l +__tre_mem_alloc_impl +__tre_mem_destroy +__tre_mem_new_impl +__tsearch_balance +__uflow +__unlist_locked_file +__uselocale +__utc +__wasi_args_get +__wasi_args_sizes_get +__wasi_clock_res_get +__wasi_clock_time_get +__wasi_environ_get +__wasi_environ_sizes_get +__wasi_fd_advise +__wasi_fd_allocate +__wasi_fd_close +__wasi_fd_datasync +__wasi_fd_fdstat_get +__wasi_fd_fdstat_set_flags +__wasi_fd_fdstat_set_rights +__wasi_fd_filestat_get +__wasi_fd_filestat_set_size +__wasi_fd_filestat_set_times +__wasi_fd_pread +__wasi_fd_prestat_dir_name +__wasi_fd_prestat_get +__wasi_fd_pwrite +__wasi_fd_read +__wasi_fd_readdir +__wasi_fd_renumber +__wasi_fd_seek +__wasi_fd_sync +__wasi_fd_tell +__wasi_fd_write +__wasi_path_create_directory +__wasi_path_filestat_get +__wasi_path_filestat_set_times +__wasi_path_link +__wasi_path_open +__wasi_path_readlink +__wasi_path_remove_directory +__wasi_path_rename +__wasi_path_symlink +__wasi_path_unlink_file +__wasi_poll_oneoff +__wasi_proc_exit +__wasi_random_get +__wasi_sched_yield +__wasi_sock_accept +__wasi_sock_recv +__wasi_sock_send +__wasi_sock_shutdown +__wasilibc_access +__wasilibc_cwd +__wasilibc_deinitialize_environ +__wasilibc_dttoif +__wasilibc_ensure_environ +__wasilibc_environ +__wasilibc_fd_renumber +__wasilibc_find_abspath +__wasilibc_find_relpath +__wasilibc_find_relpath_alloc +__wasilibc_get_environ +__wasilibc_iftodt +__wasilibc_initialize_environ +__wasilibc_link +__wasilibc_link_newat +__wasilibc_link_oldat +__wasilibc_maybe_reinitialize_environ_eagerly +__wasilibc_nocwd___wasilibc_rmdirat +__wasilibc_nocwd___wasilibc_unlinkat +__wasilibc_nocwd_faccessat +__wasilibc_nocwd_fstatat +__wasilibc_nocwd_linkat +__wasilibc_nocwd_mkdirat_nomode +__wasilibc_nocwd_openat_nomode +__wasilibc_nocwd_opendirat +__wasilibc_nocwd_readlinkat +__wasilibc_nocwd_renameat +__wasilibc_nocwd_scandirat +__wasilibc_nocwd_symlinkat +__wasilibc_nocwd_utimensat +__wasilibc_open_nomode +__wasilibc_populate_preopens +__wasilibc_register_preopened_fd +__wasilibc_rename_newat +__wasilibc_rename_oldat +__wasilibc_rmdirat +__wasilibc_stat +__wasilibc_tell +__wasilibc_unlinkat +__wasilibc_utimens +__wasm_call_dtors +__wcscoll_l +__wcsftime_l +__wcsxfrm_l +__wctrans_l +__wctype_l +__xpg_basename +__xpg_strerror_r +__year_to_secs +_environ +_exit +_flushlbf +_initialize +_start +a64l +abort +abs +accept +accept4 +access +acos +acosf +acosh +acoshf +acoshl +acosl +aligned_alloc +alphasort +alphasort64 +arc4random +arc4random_buf +arc4random_uniform +asctime +asctime_r +asin +asinf +asinh +asinhf +asinhl +asinl +asprintf +at_quick_exit +atan +atan2 +atan2f +atan2l +atanf +atanh +atanhf +atanhl +atanl +atexit +atof +atoi +atol +atoll +basename +bcmp +bcopy +bsd_signal +bsearch +btowc +bzero +c16rtomb +c32rtomb +cabs +cabsf +cabsl +cacos +cacosf +cacosh +cacoshf +cacoshl +cacosl +calloc +carg +cargf +cargl +casin +casinf +casinh +casinhf +casinhl +casinl +catan +catanf +catanh +catanhf +catanhl +catanl +catclose +catgets +catopen +cbrt +cbrtf +cbrtl +ccos +ccosf +ccosh +ccoshf +ccoshl +ccosl +ceil +ceilf +ceill +cexp +cexpf +cexpl +chdir +cimag +cimagf +cimagl +clearenv +clearerr +clearerr_unlocked +clock +clock_getres +clock_gettime +clock_nanosleep +clog +clogf +clogl +close +closedir +confstr +conj +conjf +conjl +copysign +copysignf +copysignl +cos +cosf +cosh +coshf +coshl +cosl +cpow +cpowf +cpowl +cproj +cprojf +cprojl +creal +crealf +creall +creat +creat64 +crypt +crypt_r +csin +csinf +csinh +csinhf +csinhl +csinl +csqrt +csqrtf +csqrtl +ctan +ctanf +ctanh +ctanhf +ctanhl +ctanl +ctime +ctime_r +difftime +dirfd +dirname +div +dprintf +drand48 +drem +dremf +duplocale +ecvt +encrypt +environ +erand48 +erf +erfc +erfcf +erfcl +erff +erfl +errno +exit +exp +exp10 +exp10f +exp10l +exp2 +exp2f +exp2l +expf +expl +explicit_bzero +expm1 +expm1f +expm1l +fabs +fabsf +fabsl +faccessat +fclose +fcntl +fcvt +fdatasync +fdclosedir +fdim +fdimf +fdiml +fdopen +fdopendir +feclearexcept +fegetenv +fegetexceptflag +fegetround +feholdexcept +feof +feof_unlocked +feraiseexcept +ferror +ferror_unlocked +fesetenv +fesetexceptflag +fesetround +fetestexcept +feupdateenv +fflush +fflush_unlocked +ffs +ffsl +ffsll +fgetc +fgetc_unlocked +fgetln +fgetpos +fgetpos64 +fgets +fgets_unlocked +fgetwc +fgetwc_unlocked +fgetws +fgetws_unlocked +fileno +fileno_unlocked +finite +finitef +floor +floorf +floorl +fma +fmaf +fmal +fmax +fmaxf +fmaxl +fmemopen +fmin +fminf +fminl +fmod +fmodf +fmodl +fmtmsg +fnmatch +fopen +fopen64 +fopencookie +fpathconf +fprintf +fpurge +fputc +fputc_unlocked +fputs +fputs_unlocked +fputwc +fputwc_unlocked +fputws +fputws_unlocked +fread +fread_unlocked +free +freelocale +freopen +freopen64 +frexp +frexpf +frexpl +fscanf +fseek +fseeko +fseeko64 +fsetpos +fsetpos64 +fstat +fstatat +fsync +ftell +ftello +ftello64 +ftime +ftruncate +futimens +futimesat +fwide +fwprintf +fwrite +fwrite_unlocked +fwscanf +gcvt +get_avphys_pages +get_nprocs +get_nprocs_conf +get_phys_pages +getc +getc_unlocked +getchar +getchar_unlocked +getcwd +getdate +getdate_err +getdelim +getdomainname +getentropy +getenv +gethostid +getline +getopt +getopt_long +getopt_long_only +getpagesize +getpid +getrusage +getsockopt +getsubopt +gettimeofday +getw +getwc +getwc_unlocked +getwchar +getwchar_unlocked +glob +glob64 +globfree +globfree64 +gmtime +gmtime_r +hcreate +hcreate_r +hdestroy +hdestroy_r +hsearch +hsearch_r +htonl +htons +hypot +hypotf +hypotl +iconv +iconv_close +iconv_open +ilogb +ilogbf +ilogbl +imaxabs +imaxdiv +in6addr_any +in6addr_loopback +index +inet_aton +inet_ntop +inet_pton +initstate +insque +ioctl +iprintf +isalnum +isalnum_l +isalpha +isalpha_l +isascii +isatty +isblank +isblank_l +iscntrl +iscntrl_l +isdigit +isdigit_l +isgraph +isgraph_l +islower +islower_l +isprint +isprint_l +ispunct +ispunct_l +isspace +isspace_l +isupper +isupper_l +iswalnum +iswalnum_l +iswalpha +iswalpha_l +iswblank +iswblank_l +iswcntrl +iswcntrl_l +iswctype +iswctype_l +iswdigit +iswdigit_l +iswgraph +iswgraph_l +iswlower +iswlower_l +iswprint +iswprint_l +iswpunct +iswpunct_l +iswspace +iswspace_l +iswupper +iswupper_l +iswxdigit +iswxdigit_l +isxdigit +isxdigit_l +j0 +j0f +j1 +j1f +jn +jnf +jrand48 +l64a +labs +lcong48 +ldexp +ldexpf +ldexpl +ldiv +lfind +lgamma +lgamma_r +lgammaf +lgammaf_r +lgammal +lgammal_r +link +linkat +llabs +lldiv +llrint +llrintf +llrintl +llround +llroundf +llroundl +localeconv +localtime +localtime_r +log +log10 +log10f +log10l +log1p +log1pf +log1pl +log2 +log2f +log2l +logb +logbf +logbl +logf +logl +lrand48 +lrint +lrintf +lrintl +lround +lroundf +lroundl +lsearch +lseek +lstat +malloc +malloc_usable_size +mblen +mbrlen +mbrtoc16 +mbrtoc32 +mbrtowc +mbsinit +mbsnrtowcs +mbsrtowcs +mbstowcs +mbtowc +memccpy +memchr +memcmp +memcpy +memmem +memmove +mempcpy +memrchr +memset +mkdir +mkdirat +mktime +mmap +modf +modff +modfl +mrand48 +munmap +nan +nanf +nanl +nanosleep +nearbyint +nearbyintf +nearbyintl +newlocale +nextafter +nextafterf +nextafterl +nexttoward +nexttowardf +nexttowardl +nftw +nftw64 +nl_langinfo +nl_langinfo_l +nrand48 +ntohl +ntohs +open +open_memstream +open_wmemstream +openat +opendir +opendirat +optarg +opterr +optind +optopt +optreset +pathconf +perror +poll +posix_close +posix_fadvise +posix_fallocate +posix_memalign +pow +pow10 +pow10f +pow10l +powf +powl +pread +preadv +printf +program_invocation_name +program_invocation_short_name +pselect +psignal +putc +putc_unlocked +putchar +putchar_unlocked +putenv +puts +putw +putwc +putwc_unlocked +putwchar +putwchar_unlocked +pwrite +pwritev +qsort +qsort_r +quick_exit +raise +rand +rand_r +random +read +readdir +readlink +readlinkat +readv +realloc +reallocarray +recv +regcomp +regerror +regexec +regfree +remainder +remainderf +remainderl +remove +remque +remquo +remquof +remquol +rename +renameat +rewind +rewinddir +rindex +rint +rintf +rintl +rmdir +round +roundf +roundl +sbrk +scalb +scalbf +scalbln +scalblnf +scalblnl +scalbn +scalbnf +scalbnl +scandir +scandirat +scanf +sched_yield +seed48 +seekdir +select +send +setbuf +setbuffer +setenv +setkey +setlinebuf +setlocale +setstate +setvbuf +shutdown +signal +signgam +significand +significandf +sin +sincos +sincosf +sincosl +sinf +sinh +sinhf +sinhl +sinl +sleep +snprintf +sprintf +sqrt +sqrtf +sqrtl +srand +srand48 +srandom +sscanf +stat +stderr +stdin +stdout +stpcpy +stpncpy +strcasecmp +strcasecmp_l +strcasestr +strcat +strchr +strchrnul +strcmp +strcoll +strcoll_l +strcpy +strcspn +strdup +strerror +strerror_l +strerror_r +strfmon +strfmon_l +strftime +strftime_l +strlcat +strlcpy +strlen +strncasecmp +strncasecmp_l +strncat +strncmp +strncpy +strndup +strnlen +strpbrk +strptime +strrchr +strsep +strsignal +strspn +strstr +strtod +strtod_l +strtof +strtof_l +strtoimax +strtok +strtok_r +strtol +strtold +strtold_l +strtoll +strtoul +strtoull +strtoumax +strverscmp +strxfrm +strxfrm_l +swab +swprintf +swscanf +symlink +symlinkat +sysconf +tan +tanf +tanh +tanhf +tanhl +tanl +tdelete +tdestroy +telldir +tfind +tgamma +tgammaf +tgammal +thrd_sleep +time +timegm +times +timespec_get +toascii +tolower +tolower_l +toupper +toupper_l +towctrans +towctrans_l +towlower +towlower_l +towupper +towupper_l +trunc +truncate +truncf +truncl +tsearch +twalk +uname +ungetc +ungetwc +unlink +unlinkat +unsetenv +uselocale +usleep +utime +utimensat +utimes +vasprintf +vdprintf +versionsort +versionsort64 +vfprintf +vfscanf +vfwprintf +vfwscanf +vprintf +vscanf +vsnprintf +vsprintf +vsscanf +vswprintf +vswscanf +vwprintf +vwscanf +wcpcpy +wcpncpy +wcrtomb +wcscasecmp +wcscasecmp_l +wcscat +wcschr +wcscmp +wcscoll +wcscoll_l +wcscpy +wcscspn +wcsdup +wcsftime +wcsftime_l +wcslen +wcsncasecmp +wcsncasecmp_l +wcsncat +wcsncmp +wcsncpy +wcsnlen +wcsnrtombs +wcspbrk +wcsrchr +wcsrtombs +wcsspn +wcsstr +wcstod +wcstof +wcstoimax +wcstok +wcstol +wcstold +wcstoll +wcstombs +wcstoul +wcstoull +wcstoumax +wcswcs +wcswidth +wcsxfrm +wcsxfrm_l +wctob +wctomb +wctrans +wctrans_l +wctype +wctype_l +wcwidth +wmemchr +wmemcmp +wmemcpy +wmemmove +wmemset +wprintf +write +writev +wscanf +y0 +y0f +y1 +y1f +yn +ynf diff --git a/expected/wasm64-wasip2/include-all.c b/expected/wasm64-wasip2/include-all.c new file mode 100644 index 000000000..297e48b14 --- /dev/null +++ b/expected/wasm64-wasip2/include-all.c @@ -0,0 +1,171 @@ +#include <__errno.h> +#include <__errno_values.h> +#include <__fd_set.h> +#include <__function___isatty.h> +#include <__functions_malloc.h> +#include <__functions_memcpy.h> +#include <__header_dirent.h> +#include <__header_fcntl.h> +#include <__header_inttypes.h> +#include <__header_netinet_in.h> +#include <__header_poll.h> +#include <__header_stdlib.h> +#include <__header_string.h> +#include <__header_sys_ioctl.h> +#include <__header_sys_resource.h> +#include <__header_sys_socket.h> +#include <__header_sys_stat.h> +#include <__header_time.h> +#include <__header_unistd.h> +#include <__macro_FD_SETSIZE.h> +#include <__macro_PAGESIZE.h> +#include <__mode_t.h> +#include <__seek.h> +#include <__struct_dirent.h> +#include <__struct_in6_addr.h> +#include <__struct_in_addr.h> +#include <__struct_iovec.h> +#include <__struct_msghdr.h> +#include <__struct_pollfd.h> +#include <__struct_rusage.h> +#include <__struct_sockaddr.h> +#include <__struct_sockaddr_in.h> +#include <__struct_sockaddr_in6.h> +#include <__struct_sockaddr_storage.h> +#include <__struct_sockaddr_un.h> +#include <__struct_stat.h> +#include <__struct_timespec.h> +#include <__struct_timeval.h> +#include <__struct_tm.h> +#include <__struct_tms.h> +#include <__typedef_DIR.h> +#include <__typedef_blkcnt_t.h> +#include <__typedef_blksize_t.h> +#include <__typedef_clock_t.h> +#include <__typedef_clockid_t.h> +#include <__typedef_dev_t.h> +#include <__typedef_fd_set.h> +#include <__typedef_gid_t.h> +#include <__typedef_in_addr_t.h> +#include <__typedef_in_port_t.h> +#include <__typedef_ino_t.h> +#include <__typedef_mode_t.h> +#include <__typedef_nfds_t.h> +#include <__typedef_nlink_t.h> +#include <__typedef_off_t.h> +#include <__typedef_sa_family_t.h> +#include <__typedef_sigset_t.h> +#include <__typedef_socklen_t.h> +#include <__typedef_ssize_t.h> +#include <__typedef_suseconds_t.h> +#include <__typedef_time_t.h> +#include <__typedef_uid_t.h> +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include diff --git a/expected/wasm64-wasip2/predefined-macros.txt b/expected/wasm64-wasip2/predefined-macros.txt new file mode 100644 index 000000000..dec1ead06 --- /dev/null +++ b/expected/wasm64-wasip2/predefined-macros.txt @@ -0,0 +1,3365 @@ +#define ABDAY_1 0x20000 +#define ABDAY_2 0x20001 +#define ABDAY_3 0x20002 +#define ABDAY_4 0x20003 +#define ABDAY_5 0x20004 +#define ABDAY_6 0x20005 +#define ABDAY_7 0x20006 +#define ABMON_1 0x2000E +#define ABMON_10 0x20017 +#define ABMON_11 0x20018 +#define ABMON_12 0x20019 +#define ABMON_2 0x2000F +#define ABMON_3 0x20010 +#define ABMON_4 0x20011 +#define ABMON_5 0x20012 +#define ABMON_6 0x20013 +#define ABMON_7 0x20014 +#define ABMON_8 0x20015 +#define ABMON_9 0x20016 +#define ABORT 238 +#define ACK 04 +#define ADD ns_uop_add +#define ADJ_ESTERROR 0x0008 +#define ADJ_FREQUENCY 0x0002 +#define ADJ_MAXERROR 0x0004 +#define ADJ_MICRO 0x1000 +#define ADJ_NANO 0x2000 +#define ADJ_OFFSET 0x0001 +#define ADJ_OFFSET_SINGLESHOT 0x8001 +#define ADJ_OFFSET_SS_READ 0xa001 +#define ADJ_SETOFFSET 0x0100 +#define ADJ_STATUS 0x0010 +#define ADJ_TAI 0x0080 +#define ADJ_TICK 0x4000 +#define ADJ_TIMECONST 0x0020 +#define AF_INET PF_INET +#define AF_INET6 PF_INET6 +#define AF_UNIX 3 +#define AF_UNSPEC PF_UNSPEC +#define ALT_DIGITS 0x2002F +#define AM_STR 0x20026 +#define ANYMARK 0x01 +#define AO 245 +#define AREGTYPE '\0' +#define ARFMAG "`\n" +#define ARG_MAX 131072 +#define ARMAG "!\n" +#define AT_EACCESS (0x0) +#define AT_FDCWD (-2) +#define AT_REMOVEDIR (0x4) +#define AT_SYMLINK_FOLLOW (0x2) +#define AT_SYMLINK_NOFOLLOW (0x1) +#define AUTHTYPE_CNT 5 +#define AUTHTYPE_KERBEROS_V4 1 +#define AUTHTYPE_KERBEROS_V5 2 +#define AUTHTYPE_MINK 4 +#define AUTHTYPE_NAME(x) authtype_names[x] +#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) +#define AUTHTYPE_NULL 0 +#define AUTHTYPE_SPX 3 +#define AUTHTYPE_TEST 99 +#define AUTH_HOW_MASK 2 +#define AUTH_HOW_MUTUAL 2 +#define AUTH_HOW_ONE_WAY 0 +#define AUTH_WHO_CLIENT 0 +#define AUTH_WHO_MASK 1 +#define AUTH_WHO_SERVER 1 +#define AYT 246 +#define BIG_ENDIAN __BIG_ENDIAN +#define BITSPERBYTE CHAR_BIT +#define BLKTYPE '4' +#define BLK_BYTECOUNT 2 +#define BLK_EOF 0x40 +#define BLK_EOR 0x80 +#define BLK_ERRORS 0x20 +#define BLK_RESTART 0x10 +#define BREAK 243 +#define BUFSIZ 1024 +#define BYTE_ORDER __BYTE_ORDER +#define CANBSIZ 255 +#define CBRK CEOL +#define CDISCARD CTRL('o') +#define CDSUSP CTRL('y') +#define CEOF CTRL('d') +#define CEOL '\0' +#define CEOT CEOF +#define CERASE 0177 +#define CFLUSH CDISCARD +#define CHARBITS (sizeof(char) * 8) +#define CHARCLASS_NAME_MAX 14 +#define CHAR_BIT 8 +#define CHAR_MAX 127 +#define CHAR_MIN (-128) +#define CHRTYPE '3' +#define CINTR CTRL('c') +#define CKILL CTRL('u') +#define CLNEXT CTRL('v') +#define CLOCKS_PER_SEC ((clock_t)1000000000) +#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) +#define CLOCK_REALTIME (&_CLOCK_REALTIME) +#define CMIN 1 +#define CMPLX(x,y) __CMPLX(x, y, double) +#define CMPLXF(x,y) __CMPLX(x, y, float) +#define CMPLXL(x,y) __CMPLX(x, y, long double) +#define CODESET 14 +#define COLL_WEIGHTS_MAX 2 +#define COMPLETE 2 +#define CONTINUE 3 +#define CONTTYPE '7' +#define CQUIT 034 +#define CREPRINT CTRL('r') +#define CRNCYSTR 0x4000F +#define CRPRNT CREPRINT +#define CSTART CTRL('q') +#define CSTATUS '\0' +#define CSTOP CTRL('s') +#define CSUSP CTRL('z') +#define CTIME 0 +#define CTRL(x) ((x)&037) +#define CWERASE CTRL('w') +#define C_ANY ns_c_any +#define C_CHAOS ns_c_chaos +#define C_HS ns_c_hs +#define C_IN ns_c_in +#define C_IRGRP 000040 +#define C_IROTH 000004 +#define C_IRUSR 000400 +#define C_ISBLK 060000 +#define C_ISCHR 020000 +#define C_ISCTG 0110000 +#define C_ISDIR 040000 +#define C_ISFIFO 010000 +#define C_ISGID 002000 +#define C_ISLNK 0120000 +#define C_ISREG 0100000 +#define C_ISSOCK 0140000 +#define C_ISUID 004000 +#define C_ISVTX 001000 +#define C_IWGRP 000020 +#define C_IWOTH 000002 +#define C_IWUSR 000200 +#define C_IXGRP 000010 +#define C_IXOTH 000001 +#define C_IXUSR 000100 +#define C_NONE ns_c_none +#define DATA 03 +#define DAY_1 0x20007 +#define DAY_2 0x20008 +#define DAY_3 0x20009 +#define DAY_4 0x2000A +#define DAY_5 0x2000B +#define DAY_6 0x2000C +#define DAY_7 0x2000D +#define DBL_DECIMAL_DIG 17 +#define DBL_DIG 15 +#define DBL_EPSILON 2.22044604925031308085e-16 +#define DBL_HAS_SUBNORM 1 +#define DBL_MANT_DIG 53 +#define DBL_MAX 1.79769313486231570815e+308 +#define DBL_MAX_10_EXP 308 +#define DBL_MAX_EXP 1024 +#define DBL_MIN 2.22507385850720138309e-308 +#define DBL_MIN_10_EXP (-307) +#define DBL_MIN_EXP (-1021) +#define DBL_TRUE_MIN 4.94065645841246544177e-324 +#define DECIMAL_DIG 36 +#define DELAYTIMER_MAX 0x7fffffff +#define DELETE ns_uop_delete +#define DEV_BSIZE 512 +#define DIRTYPE '5' +#define DM 242 +#define DMAXEXP DBL_MAX_EXP +#define DMINEXP DBL_MIN_EXP +#define DO 253 +#define DONT 254 +#define DOUBLEBITS (sizeof(double) * 8) +#define DTTOIF(x) (__wasilibc_dttoif(x)) +#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE +#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE +#define DT_DIR __WASI_FILETYPE_DIRECTORY +#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM +#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK +#define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN +#define D_FMT 0x20029 +#define D_T_FMT 0x20028 +#define E2BIG __WASI_ERRNO_2BIG +#define EACCES __WASI_ERRNO_ACCES +#define EACCESS 2 +#define EADDRINUSE __WASI_ERRNO_ADDRINUSE +#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL +#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT +#define EAGAIN __WASI_ERRNO_AGAIN +#define EALREADY __WASI_ERRNO_ALREADY +#define EBADF __WASI_ERRNO_BADF +#define EBADID 5 +#define EBADMSG __WASI_ERRNO_BADMSG +#define EBADOP 4 +#define EBUSY __WASI_ERRNO_BUSY +#define EC 247 +#define ECANCELED __WASI_ERRNO_CANCELED +#define ECHILD __WASI_ERRNO_CHILD +#define ECONNABORTED __WASI_ERRNO_CONNABORTED +#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED +#define ECONNRESET __WASI_ERRNO_CONNRESET +#define EDEADLK __WASI_ERRNO_DEADLK +#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ +#define EDOM __WASI_ERRNO_DOM +#define EDQUOT __WASI_ERRNO_DQUOT +#define EEXIST __WASI_ERRNO_EXIST +#define EEXISTS 6 +#define EFAULT __WASI_ERRNO_FAULT +#define EFBIG __WASI_ERRNO_FBIG +#define EFD_CLOEXEC O_CLOEXEC +#define EFD_NONBLOCK O_NONBLOCK +#define EFD_SEMAPHORE 1 +#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH +#define EIDRM __WASI_ERRNO_IDRM +#define EILSEQ __WASI_ERRNO_ILSEQ +#define EINPROGRESS __WASI_ERRNO_INPROGRESS +#define EINTR __WASI_ERRNO_INTR +#define EINVAL __WASI_ERRNO_INVAL +#define EIO __WASI_ERRNO_IO +#define EISCONN __WASI_ERRNO_ISCONN +#define EISDIR __WASI_ERRNO_ISDIR +#define EL 248 +#define ELOOP __WASI_ERRNO_LOOP +#define EMFILE __WASI_ERRNO_MFILE +#define EMLINK __WASI_ERRNO_MLINK +#define EMSGSIZE __WASI_ERRNO_MSGSIZE +#define EMULTIHOP __WASI_ERRNO_MULTIHOP +#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG +#define ENCRYPT_CNT 9 +#define ENCRYPT_DEC_KEYID 8 +#define ENCRYPT_ENC_KEYID 7 +#define ENCRYPT_END 4 +#define ENCRYPT_IS 0 +#define ENCRYPT_NAME(x) encrypt_names[x] +#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) +#define ENCRYPT_REPLY 2 +#define ENCRYPT_REQEND 6 +#define ENCRYPT_REQSTART 5 +#define ENCRYPT_START 3 +#define ENCRYPT_SUPPORT 1 +#define ENCTYPE_ANY 0 +#define ENCTYPE_CNT 3 +#define ENCTYPE_DES_CFB64 1 +#define ENCTYPE_DES_OFB64 2 +#define ENCTYPE_NAME(x) enctype_names[x] +#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) +#define ENETDOWN __WASI_ERRNO_NETDOWN +#define ENETRESET __WASI_ERRNO_NETRESET +#define ENETUNREACH __WASI_ERRNO_NETUNREACH +#define ENFILE __WASI_ERRNO_NFILE +#define ENOBUFS __WASI_ERRNO_NOBUFS +#define ENODEV __WASI_ERRNO_NODEV +#define ENOENT __WASI_ERRNO_NOENT +#define ENOEXEC __WASI_ERRNO_NOEXEC +#define ENOLCK __WASI_ERRNO_NOLCK +#define ENOLINK __WASI_ERRNO_NOLINK +#define ENOMEM __WASI_ERRNO_NOMEM +#define ENOMSG __WASI_ERRNO_NOMSG +#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT +#define ENOSPACE 3 +#define ENOSPC __WASI_ERRNO_NOSPC +#define ENOSYS __WASI_ERRNO_NOSYS +#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE +#define ENOTCONN __WASI_ERRNO_NOTCONN +#define ENOTDIR __WASI_ERRNO_NOTDIR +#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY +#define ENOTFOUND 1 +#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE +#define ENOTSOCK __WASI_ERRNO_NOTSOCK +#define ENOTSUP __WASI_ERRNO_NOTSUP +#define ENOTTY __WASI_ERRNO_NOTTY +#define ENOUSER 7 +#define ENV_ESC 2 +#define ENV_USERVAR 3 +#define ENXIO __WASI_ERRNO_NXIO +#define EOF (-1) +#define EOPNOTSUPP ENOTSUP +#define EOR 239 +#define EOVERFLOW __WASI_ERRNO_OVERFLOW +#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD +#define EPERM __WASI_ERRNO_PERM +#define EPIPE __WASI_ERRNO_PIPE +#define EPROTO __WASI_ERRNO_PROTO +#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT +#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE +#define ERA 0x2002C +#define ERANGE __WASI_ERRNO_RANGE +#define ERA_D_FMT 0x2002E +#define ERA_D_T_FMT 0x20030 +#define ERA_T_FMT 0x20031 +#define EROFS __WASI_ERRNO_ROFS +#define ERROR 05 +#define ESPIPE __WASI_ERRNO_SPIPE +#define ESRCH __WASI_ERRNO_SRCH +#define ESTALE __WASI_ERRNO_STALE +#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT +#define ETXTBSY __WASI_ERRNO_TXTBSY +#define EUNDEF 0 +#define EWOULDBLOCK EAGAIN +#define EXDEV __WASI_ERRNO_XDEV +#define EXIT_FAILURE 1 +#define EXIT_SUCCESS 0 +#define EX_CANTCREAT 73 +#define EX_CONFIG 78 +#define EX_DATAERR 65 +#define EX_IOERR 74 +#define EX_NOHOST 68 +#define EX_NOINPUT 66 +#define EX_NOPERM 77 +#define EX_NOUSER 67 +#define EX_OK 0 +#define EX_OSERR 71 +#define EX_OSFILE 72 +#define EX_PROTOCOL 76 +#define EX_SOFTWARE 70 +#define EX_TEMPFAIL 75 +#define EX_UNAVAILABLE 69 +#define EX_USAGE 64 +#define EX__BASE 64 +#define EX__MAX 78 +#define FD_CLOEXEC (1) +#define FD_CLR(fd,set) (FD_CLR((fd), (set))) +#define FD_COPY(from,to) (FD_COPY((from), (to))) +#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) +#define FD_SET(fd,set) (FD_SET((fd), (set))) +#define FD_SETSIZE 1024 +#define FD_ZERO(set) (FD_ZERO((set))) +#define FE_ALL_EXCEPT 0 +#define FE_DFL_ENV ((const fenv_t *) -1) +#define FE_TONEAREST 0 +#define FIFOTYPE '6' +#define FILENAME_MAX 4096 +#define FILESIZEBITS 64 +#define FIONBIO 2 +#define FIONREAD 1 +#define FLOATBITS (sizeof(float) * 8) +#define FLT_DECIMAL_DIG 9 +#define FLT_DIG 6 +#define FLT_EPSILON 1.1920928955078125e-07F +#define FLT_EVAL_METHOD 0 +#define FLT_HAS_SUBNORM 1 +#define FLT_MANT_DIG 24 +#define FLT_MAX 3.40282346638528859812e+38F +#define FLT_MAX_10_EXP 38 +#define FLT_MAX_EXP 128 +#define FLT_MIN 1.17549435082228750797e-38F +#define FLT_MIN_10_EXP (-37) +#define FLT_MIN_EXP (-125) +#define FLT_RADIX 2 +#define FLT_ROUNDS (__builtin_flt_rounds()) +#define FLT_TRUE_MIN 1.40129846432481707092e-45F +#define FLUSHBAND 0x04 +#define FLUSHR 0x01 +#define FLUSHRW 0x03 +#define FLUSHW 0x02 +#define FMAXEXP FLT_MAX_EXP +#define FMINEXP FLT_MIN_EXP +#define FMNAMESZ 8 +#define FNM_CASEFOLD 0x10 +#define FNM_FILE_NAME FNM_PATHNAME +#define FNM_LEADING_DIR 0x8 +#define FNM_NOESCAPE 0x2 +#define FNM_NOMATCH 1 +#define FNM_NOSYS (-1) +#define FNM_PATHNAME 0x1 +#define FNM_PERIOD 0x4 +#define FOPEN_MAX 1000 +#define FORMERR ns_r_formerr +#define FORM_C 3 +#define FORM_N 1 +#define FORM_T 2 +#define FP_ILOGB0 FP_ILOGBNAN +#define FP_ILOGBNAN (-1-0x7fffffff) +#define FP_INFINITE 1 +#define FP_NAN 0 +#define FP_NORMAL 4 +#define FP_SUBNORMAL 3 +#define FP_ZERO 2 +#define FSETLOCKING_BYCALLER 2 +#define FSETLOCKING_INTERNAL 1 +#define FSETLOCKING_QUERY 0 +#define FTW_CHDIR 4 +#define FTW_D 2 +#define FTW_DEPTH 8 +#define FTW_DNR 3 +#define FTW_DP 6 +#define FTW_F 1 +#define FTW_MOUNT 2 +#define FTW_NS 4 +#define FTW_PHYS 1 +#define FTW_SL 5 +#define FTW_SLN 7 +#define F_GETFD (1) +#define F_GETFL (3) +#define F_LOCK 1 +#define F_OK (0) +#define F_SETFD (2) +#define F_SETFL (4) +#define F_TEST 3 +#define F_TLOCK 2 +#define F_ULOCK 0 +#define GA 249 +#define GETLONG NS_GET32 +#define GETSHORT NS_GET16 +#define GLOB_ABORTED 2 +#define GLOB_APPEND 0x20 +#define GLOB_DOOFFS 0x08 +#define GLOB_ERR 0x01 +#define GLOB_MARK 0x02 +#define GLOB_NOCHECK 0x10 +#define GLOB_NOESCAPE 0x40 +#define GLOB_NOMATCH 3 +#define GLOB_NOSORT 0x04 +#define GLOB_NOSPACE 1 +#define GLOB_NOSYS 4 +#define GLOB_PERIOD 0x80 +#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) +#define HFIXEDSZ NS_HFIXEDSZ +#define HIBITL MINLONG +#define HIBITS MINSHORT +#define HOST_NAME_MAX 255 +#define HUGE 3.40282346638528859812e+38F +#define HUGE_VAL ((double)INFINITY) +#define HUGE_VALF INFINITY +#define HUGE_VALL ((long double)INFINITY) +#define I _Complex_I +#define IAC 255 +#define ICMP6_DST_UNREACH 1 +#define ICMP6_DST_UNREACH_ADDR 3 +#define ICMP6_DST_UNREACH_ADMIN 1 +#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 +#define ICMP6_DST_UNREACH_NOPORT 4 +#define ICMP6_DST_UNREACH_NOROUTE 0 +#define ICMP6_ECHO_REPLY 129 +#define ICMP6_ECHO_REQUEST 128 +#define ICMP6_FILTER 1 +#define ICMP6_FILTER_BLOCK 1 +#define ICMP6_FILTER_BLOCKOTHERS 3 +#define ICMP6_FILTER_PASS 2 +#define ICMP6_FILTER_PASSONLY 4 +#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) +#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) +#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); +#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) +#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) +#define ICMP6_INFOMSG_MASK 0x80 +#define ICMP6_PACKET_TOO_BIG 2 +#define ICMP6_PARAMPROB_HEADER 0 +#define ICMP6_PARAMPROB_NEXTHEADER 1 +#define ICMP6_PARAMPROB_OPTION 2 +#define ICMP6_PARAM_PROB 4 +#define ICMP6_ROUTER_RENUMBERING 138 +#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 +#define ICMP6_RR_FLAGS_PREVDONE 0x08 +#define ICMP6_RR_FLAGS_REQRESULT 0x40 +#define ICMP6_RR_FLAGS_SPECSITE 0x10 +#define ICMP6_RR_FLAGS_TEST 0x80 +#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 +#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 +#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 +#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 +#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 +#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 +#define ICMP6_TIME_EXCEEDED 3 +#define ICMP6_TIME_EXCEED_REASSEMBLY 1 +#define ICMP6_TIME_EXCEED_TRANSIT 0 +#define ICMP_ADDRESS 17 +#define ICMP_ADDRESSREPLY 18 +#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) +#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) +#define ICMP_DEST_UNREACH 3 +#define ICMP_ECHO 8 +#define ICMP_ECHOREPLY 0 +#define ICMP_EXC_FRAGTIME 1 +#define ICMP_EXC_TTL 0 +#define ICMP_FRAG_NEEDED 4 +#define ICMP_HOST_ANO 10 +#define ICMP_HOST_ISOLATED 8 +#define ICMP_HOST_UNKNOWN 7 +#define ICMP_HOST_UNREACH 1 +#define ICMP_HOST_UNR_TOS 12 +#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) +#define ICMP_INFO_REPLY 16 +#define ICMP_INFO_REQUEST 15 +#define ICMP_IREQ 15 +#define ICMP_IREQREPLY 16 +#define ICMP_MASKLEN 12 +#define ICMP_MASKREPLY 18 +#define ICMP_MASKREQ 17 +#define ICMP_MAXTYPE 18 +#define ICMP_MINLEN 8 +#define ICMP_NET_ANO 9 +#define ICMP_NET_UNKNOWN 6 +#define ICMP_NET_UNREACH 0 +#define ICMP_NET_UNR_TOS 11 +#define ICMP_PARAMETERPROB 12 +#define ICMP_PARAMPROB 12 +#define ICMP_PARAMPROB_OPTABSENT 1 +#define ICMP_PKT_FILTERED 13 +#define ICMP_PORT_UNREACH 3 +#define ICMP_PREC_CUTOFF 15 +#define ICMP_PREC_VIOLATION 14 +#define ICMP_PROT_UNREACH 2 +#define ICMP_REDIRECT 5 +#define ICMP_REDIRECT_HOST 1 +#define ICMP_REDIRECT_NET 0 +#define ICMP_REDIRECT_TOSHOST 3 +#define ICMP_REDIRECT_TOSNET 2 +#define ICMP_REDIR_HOST 1 +#define ICMP_REDIR_HOSTTOS 3 +#define ICMP_REDIR_NET 0 +#define ICMP_REDIR_NETTOS 2 +#define ICMP_ROUTERADVERT 9 +#define ICMP_ROUTERSOLICIT 10 +#define ICMP_SOURCEQUENCH 4 +#define ICMP_SOURCE_QUENCH 4 +#define ICMP_SR_FAILED 5 +#define ICMP_TIMESTAMP 13 +#define ICMP_TIMESTAMPREPLY 14 +#define ICMP_TIME_EXCEEDED 11 +#define ICMP_TIMXCEED 11 +#define ICMP_TIMXCEED_INTRANS 0 +#define ICMP_TIMXCEED_REASS 1 +#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) +#define ICMP_TSTAMP 13 +#define ICMP_TSTAMPREPLY 14 +#define ICMP_UNREACH 3 +#define ICMP_UNREACH_FILTER_PROHIB 13 +#define ICMP_UNREACH_HOST 1 +#define ICMP_UNREACH_HOST_PRECEDENCE 14 +#define ICMP_UNREACH_HOST_PROHIB 10 +#define ICMP_UNREACH_HOST_UNKNOWN 7 +#define ICMP_UNREACH_ISOLATED 8 +#define ICMP_UNREACH_NEEDFRAG 4 +#define ICMP_UNREACH_NET 0 +#define ICMP_UNREACH_NET_PROHIB 9 +#define ICMP_UNREACH_NET_UNKNOWN 6 +#define ICMP_UNREACH_PORT 3 +#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 +#define ICMP_UNREACH_PROTOCOL 2 +#define ICMP_UNREACH_SRCFAIL 5 +#define ICMP_UNREACH_TOSHOST 12 +#define ICMP_UNREACH_TOSNET 11 +#define IFTODT(x) (__wasilibc_iftodt(x)) +#define IGMP_AWAKENING_MEMBER 5 +#define IGMP_DELAYING_MEMBER 1 +#define IGMP_DVMRP 0x13 +#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP +#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY +#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT +#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT +#define IGMP_IDLE_MEMBER 2 +#define IGMP_LAZY_MEMBER 3 +#define IGMP_MAX_HOST_REPORT_DELAY 10 +#define IGMP_MEMBERSHIP_QUERY 0x11 +#define IGMP_MINLEN 8 +#define IGMP_MTRACE 0x1f +#define IGMP_MTRACE_RESP 0x1e +#define IGMP_PIM 0x14 +#define IGMP_SLEEPING_MEMBER 4 +#define IGMP_TIMER_SCALE 10 +#define IGMP_TRACE 0x15 +#define IGMP_V1_MEMBERSHIP_REPORT 0x12 +#define IGMP_V2_LEAVE_GROUP 0x17 +#define IGMP_V2_MEMBERSHIP_REPORT 0x16 +#define IGMP_v1_ROUTER 1 +#define IGMP_v2_ROUTER 2 +#define IN6ADDRSZ NS_IN6ADDRSZ +#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } +#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } +#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) +#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) +#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) +#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) +#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) +#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) +#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) +#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) +#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) +#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) +#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) +#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) +#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) +#define INADDRSZ NS_INADDRSZ +#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) +#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) +#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) +#define INADDR_ANY ((in_addr_t) 0x00000000) +#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) +#define INADDR_DUMMY ((in_addr_t) 0xc0000008) +#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) +#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) +#define INADDR_NONE ((in_addr_t) 0xffffffff) +#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) +#define INDIR_MASK NS_CMPRSFLGS +#define INET6_ADDRSTRLEN 46 +#define INET_ADDRSTRLEN 16 +#define INFINITY 1e5000f +#define INT16SZ NS_INT16SZ +#define INT16_C(c) c +#define INT16_MAX (0x7fff) +#define INT16_MIN (-1-0x7fff) +#define INT32SZ NS_INT32SZ +#define INT32_C(c) c +#define INT32_MAX (0x7fffffff) +#define INT32_MIN (-1-0x7fffffff) +#define INT64_C(c) c ## LL +#define INT64_MAX (0x7fffffffffffffff) +#define INT64_MIN (-1-0x7fffffffffffffff) +#define INT8SZ NS_INT8SZ +#define INT8_C(c) c +#define INT8_MAX (0x7f) +#define INT8_MIN (-1-0x7f) +#define INTBITS (sizeof(int) * 8) +#define INTMAX_C(c) c ## LL +#define INTMAX_MAX INT64_MAX +#define INTMAX_MIN INT64_MIN +#define INTPTR_MAX INT32_MAX +#define INTPTR_MIN INT32_MIN +#define INT_FAST16_MAX INT16_MAX +#define INT_FAST16_MIN INT16_MIN +#define INT_FAST32_MAX INT32_MAX +#define INT_FAST32_MIN INT32_MIN +#define INT_FAST64_MAX INT64_MAX +#define INT_FAST64_MIN INT64_MIN +#define INT_FAST8_MAX INT8_MAX +#define INT_FAST8_MIN INT8_MIN +#define INT_LEAST16_MAX INT16_MAX +#define INT_LEAST16_MIN INT16_MIN +#define INT_LEAST32_MAX INT32_MAX +#define INT_LEAST32_MIN INT32_MIN +#define INT_LEAST64_MAX INT64_MAX +#define INT_LEAST64_MIN INT64_MIN +#define INT_LEAST8_MAX INT8_MAX +#define INT_LEAST8_MIN INT8_MIN +#define INT_MAX 0x7fffffff +#define INT_MIN (-1-0x7fffffff) +#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) +#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) +#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) +#define IN_CLASSA_MAX 128 +#define IN_CLASSA_NET 0xff000000 +#define IN_CLASSA_NSHIFT 24 +#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) +#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) +#define IN_CLASSB_MAX 65536 +#define IN_CLASSB_NET 0xffff0000 +#define IN_CLASSB_NSHIFT 16 +#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) +#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) +#define IN_CLASSC_NET 0xffffff00 +#define IN_CLASSC_NSHIFT 8 +#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) +#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) +#define IN_LOOPBACKNET 127 +#define IN_MULTICAST(a) IN_CLASSD(a) +#define IOV_MAX 1024 +#define IP 244 +#define IP6F_MORE_FRAG 0x0100 +#define IP6F_OFF_MASK 0xf8ff +#define IP6F_RESERVED_MASK 0x0600 +#define IP6OPT_JUMBO 0xc2 +#define IP6OPT_JUMBO_LEN 6 +#define IP6OPT_NSAP_ADDR 0xc3 +#define IP6OPT_PAD1 0 +#define IP6OPT_PADN 1 +#define IP6OPT_ROUTER_ALERT 0x05 +#define IP6OPT_TUNNEL_LIMIT 0x04 +#define IP6OPT_TYPE(o) ((o) & 0xc0) +#define IP6OPT_TYPE_DISCARD 0x40 +#define IP6OPT_TYPE_FORCEICMP 0x80 +#define IP6OPT_TYPE_ICMP 0xc0 +#define IP6OPT_TYPE_MUTABLE 0x20 +#define IP6OPT_TYPE_SKIP 0x00 +#define IP6_ALERT_AN 0x0200 +#define IP6_ALERT_MLD 0x0000 +#define IP6_ALERT_RSVP 0x0100 +#define IPDEFTTL 64 +#define IPFRAGTTL 60 +#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) +#define IPOPT_CLASS_MASK 0x60 +#define IPOPT_CONTROL 0x00 +#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) +#define IPOPT_COPY 0x80 +#define IPOPT_DEBMEAS 0x40 +#define IPOPT_END IPOPT_EOL +#define IPOPT_EOL 0 +#define IPOPT_LSRR 131 +#define IPOPT_MEASUREMENT IPOPT_DEBMEAS +#define IPOPT_MINOFF 4 +#define IPOPT_NOOP IPOPT_NOP +#define IPOPT_NOP 1 +#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) +#define IPOPT_NUMBER_MASK 0x1f +#define IPOPT_OFFSET 2 +#define IPOPT_OLEN 1 +#define IPOPT_OPTVAL 0 +#define IPOPT_RA 148 +#define IPOPT_RESERVED1 0x20 +#define IPOPT_RESERVED2 0x60 +#define IPOPT_RR 7 +#define IPOPT_SATID 136 +#define IPOPT_SEC IPOPT_SECURITY +#define IPOPT_SECURITY 130 +#define IPOPT_SECUR_CONFID 0xf135 +#define IPOPT_SECUR_EFTO 0x789a +#define IPOPT_SECUR_MMMM 0xbc4d +#define IPOPT_SECUR_RESTR 0xaf13 +#define IPOPT_SECUR_SECRET 0xd788 +#define IPOPT_SECUR_TOPSECRET 0x6bc5 +#define IPOPT_SECUR_UNCLASS 0x0000 +#define IPOPT_SID IPOPT_SATID +#define IPOPT_SSRR 137 +#define IPOPT_TIMESTAMP IPOPT_TS +#define IPOPT_TS 68 +#define IPOPT_TS_PRESPEC 3 +#define IPOPT_TS_TSANDADDR 1 +#define IPOPT_TS_TSONLY 0 +#define IPPORT_RESERVED 1024 +#define IPPROTO_ICMP 1 +#define IPPROTO_IP 0 +#define IPPROTO_IPV6 41 +#define IPPROTO_RAW 255 +#define IPPROTO_TCP 6 +#define IPPROTO_UDP 17 +#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) +#define IPTOS_CLASS_CS0 0x00 +#define IPTOS_CLASS_CS1 0x20 +#define IPTOS_CLASS_CS2 0x40 +#define IPTOS_CLASS_CS3 0x60 +#define IPTOS_CLASS_CS4 0x80 +#define IPTOS_CLASS_CS5 0xa0 +#define IPTOS_CLASS_CS6 0xc0 +#define IPTOS_CLASS_CS7 0xe0 +#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 +#define IPTOS_CLASS_MASK 0xe0 +#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) +#define IPTOS_DSCP_AF11 0x28 +#define IPTOS_DSCP_AF12 0x30 +#define IPTOS_DSCP_AF13 0x38 +#define IPTOS_DSCP_AF21 0x48 +#define IPTOS_DSCP_AF22 0x50 +#define IPTOS_DSCP_AF23 0x58 +#define IPTOS_DSCP_AF31 0x68 +#define IPTOS_DSCP_AF32 0x70 +#define IPTOS_DSCP_AF33 0x78 +#define IPTOS_DSCP_AF41 0x88 +#define IPTOS_DSCP_AF42 0x90 +#define IPTOS_DSCP_AF43 0x98 +#define IPTOS_DSCP_EF 0xb8 +#define IPTOS_DSCP_MASK 0xfc +#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) +#define IPTOS_ECN_CE 0x03 +#define IPTOS_ECN_ECT0 0x02 +#define IPTOS_ECN_ECT1 0x01 +#define IPTOS_ECN_MASK 0x03 +#define IPTOS_ECN_NOT_ECT 0x00 +#define IPTOS_LOWCOST 0x02 +#define IPTOS_LOWDELAY 0x10 +#define IPTOS_MINCOST IPTOS_LOWCOST +#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) +#define IPTOS_PREC_CRITIC_ECP 0xa0 +#define IPTOS_PREC_FLASH 0x60 +#define IPTOS_PREC_FLASHOVERRIDE 0x80 +#define IPTOS_PREC_IMMEDIATE 0x40 +#define IPTOS_PREC_INTERNETCONTROL 0xc0 +#define IPTOS_PREC_MASK 0xe0 +#define IPTOS_PREC_NETCONTROL 0xe0 +#define IPTOS_PREC_PRIORITY 0x20 +#define IPTOS_PREC_ROUTINE 0x00 +#define IPTOS_RELIABILITY 0x04 +#define IPTOS_THROUGHPUT 0x08 +#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) +#define IPTOS_TOS_MASK 0x1E +#define IPTTLDEC 1 +#define IPV6_2292DSTOPTS 4 +#define IPV6_2292HOPLIMIT 8 +#define IPV6_2292HOPOPTS 3 +#define IPV6_2292PKTINFO 2 +#define IPV6_2292PKTOPTIONS 6 +#define IPV6_2292RTHDR 5 +#define IPV6_ADDRFORM 1 +#define IPV6_ADDR_PREFERENCES 72 +#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP +#define IPV6_AUTHHDR 10 +#define IPV6_AUTOFLOWLABEL 70 +#define IPV6_CHECKSUM 7 +#define IPV6_DONTFRAG 62 +#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP +#define IPV6_DSTOPTS 59 +#define IPV6_FREEBIND 78 +#define IPV6_HDRINCL 36 +#define IPV6_HOPLIMIT 52 +#define IPV6_HOPOPTS 54 +#define IPV6_IPSEC_POLICY 34 +#define IPV6_JOIN_ANYCAST 27 +#define IPV6_JOIN_GROUP 20 +#define IPV6_LEAVE_ANYCAST 28 +#define IPV6_LEAVE_GROUP 21 +#define IPV6_MINHOPCOUNT 73 +#define IPV6_MTU 24 +#define IPV6_MTU_DISCOVER 23 +#define IPV6_MULTICAST_ALL 29 +#define IPV6_MULTICAST_HOPS 18 +#define IPV6_MULTICAST_IF 17 +#define IPV6_MULTICAST_LOOP 19 +#define IPV6_NEXTHOP 9 +#define IPV6_ORIGDSTADDR 74 +#define IPV6_PATHMTU 61 +#define IPV6_PKTINFO 50 +#define IPV6_PMTUDISC_DO 2 +#define IPV6_PMTUDISC_DONT 0 +#define IPV6_PMTUDISC_INTERFACE 4 +#define IPV6_PMTUDISC_OMIT 5 +#define IPV6_PMTUDISC_PROBE 3 +#define IPV6_PMTUDISC_WANT 1 +#define IPV6_PREFER_SRC_CGA 0x0008 +#define IPV6_PREFER_SRC_COA 0x0004 +#define IPV6_PREFER_SRC_HOME 0x0400 +#define IPV6_PREFER_SRC_NONCGA 0x0800 +#define IPV6_PREFER_SRC_PUBLIC 0x0002 +#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 +#define IPV6_PREFER_SRC_TMP 0x0001 +#define IPV6_RECVDSTOPTS 58 +#define IPV6_RECVERR 25 +#define IPV6_RECVFRAGSIZE 77 +#define IPV6_RECVHOPLIMIT 51 +#define IPV6_RECVHOPOPTS 53 +#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR +#define IPV6_RECVPATHMTU 60 +#define IPV6_RECVPKTINFO 49 +#define IPV6_RECVRTHDR 56 +#define IPV6_RECVTCLASS 66 +#define IPV6_ROUTER_ALERT 22 +#define IPV6_ROUTER_ALERT_ISOLATE 30 +#define IPV6_RTHDR 57 +#define IPV6_RTHDRDSTOPTS 55 +#define IPV6_RTHDR_LOOSE 0 +#define IPV6_RTHDR_STRICT 1 +#define IPV6_RTHDR_TYPE_0 0 +#define IPV6_RXDSTOPTS IPV6_DSTOPTS +#define IPV6_RXHOPOPTS IPV6_HOPOPTS +#define IPV6_TCLASS 67 +#define IPV6_TRANSPARENT 75 +#define IPV6_UNICAST_HOPS 16 +#define IPV6_UNICAST_IF 76 +#define IPV6_V6ONLY 26 +#define IPV6_XFRM_POLICY 35 +#define IPVERSION 4 +#define IP_ADD_MEMBERSHIP 35 +#define IP_ADD_SOURCE_MEMBERSHIP 39 +#define IP_BIND_ADDRESS_NO_PORT 24 +#define IP_BLOCK_SOURCE 38 +#define IP_CHECKSUM 23 +#define IP_DEFAULT_MULTICAST_LOOP 1 +#define IP_DEFAULT_MULTICAST_TTL 1 +#define IP_DF 0x4000 +#define IP_DROP_MEMBERSHIP 36 +#define IP_DROP_SOURCE_MEMBERSHIP 40 +#define IP_FREEBIND 15 +#define IP_HDRINCL 3 +#define IP_IPSEC_POLICY 16 +#define IP_MAXPACKET 65535 +#define IP_MAX_MEMBERSHIPS 20 +#define IP_MF 0x2000 +#define IP_MINTTL 21 +#define IP_MSFILTER 41 +#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) +#define IP_MSS 576 +#define IP_MTU 14 +#define IP_MTU_DISCOVER 10 +#define IP_MULTICAST_ALL 49 +#define IP_MULTICAST_IF 32 +#define IP_MULTICAST_LOOP 34 +#define IP_MULTICAST_TTL 33 +#define IP_NODEFRAG 22 +#define IP_OFFMASK 0x1fff +#define IP_OPTIONS 4 +#define IP_ORIGDSTADDR 20 +#define IP_PASSSEC 18 +#define IP_PKTINFO 8 +#define IP_PKTOPTIONS 9 +#define IP_PMTUDISC 10 +#define IP_PMTUDISC_DO 2 +#define IP_PMTUDISC_DONT 0 +#define IP_PMTUDISC_INTERFACE 4 +#define IP_PMTUDISC_OMIT 5 +#define IP_PMTUDISC_PROBE 3 +#define IP_PMTUDISC_WANT 1 +#define IP_RECVERR 11 +#define IP_RECVERR_RFC4884 26 +#define IP_RECVFRAGSIZE 25 +#define IP_RECVOPTS 6 +#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR +#define IP_RECVRETOPTS IP_RETOPTS +#define IP_RECVTOS 13 +#define IP_RECVTTL 12 +#define IP_RETOPTS 7 +#define IP_RF 0x8000 +#define IP_ROUTER_ALERT 5 +#define IP_TOS 1 +#define IP_TRANSPARENT 19 +#define IP_TTL 2 +#define IP_UNBLOCK_SOURCE 37 +#define IP_UNICAST_IF 50 +#define IP_XFRM_POLICY 17 +#define IQUERY ns_o_iquery +#define I_ATMARK (__SID |31) +#define I_CANPUT (__SID |34) +#define I_CKBAND (__SID |29) +#define I_FDINSERT (__SID |16) +#define I_FIND (__SID |11) +#define I_FLUSH (__SID | 5) +#define I_FLUSHBAND (__SID |28) +#define I_GETBAND (__SID |30) +#define I_GETCLTIME (__SID |33) +#define I_GETSIG (__SID |10) +#define I_GRDOPT (__SID | 7) +#define I_GWROPT (__SID |20) +#define I_LINK (__SID |12) +#define I_LIST (__SID |21) +#define I_LOOK (__SID | 4) +#define I_NREAD (__SID | 1) +#define I_PEEK (__SID |15) +#define I_PLINK (__SID |22) +#define I_POP (__SID | 3) +#define I_PUNLINK (__SID |23) +#define I_PUSH (__SID | 2) +#define I_RECVFD (__SID |14) +#define I_SENDFD (__SID |17) +#define I_SETCLTIME (__SID |32) +#define I_SETSIG (__SID | 9) +#define I_SRDOPT (__SID | 6) +#define I_STR (__SID | 8) +#define I_SWROPT (__SID |19) +#define I_UNLINK (__SID |13) +#define LASTMARK 0x02 +#define LC_ALL 6 +#define LC_ALL_MASK 0x7fffffff +#define LC_COLLATE 3 +#define LC_COLLATE_MASK (1<(b))?(a):(b)) +#define MAXCDNAME NS_MAXCDNAME +#define MAXDNAME NS_MAXDNAME +#define MAXDOUBLE DBL_MAX +#define MAXFLOAT FLT_MAX +#define MAXHOSTNAMELEN 64 +#define MAXINT INT_MAX +#define MAXLABEL NS_MAXLABEL +#define MAXLONG LONG_MAX +#define MAXNAMLEN 255 +#define MAXPATHLEN 4096 +#define MAXSHORT SHRT_MAX +#define MAXSYMLINKS 20 +#define MAXTC 6 +#define MAXTTL 255 +#define MAX_IPOPTLEN 40 +#define MB_CUR_MAX (__ctype_get_mb_cur_max()) +#define MB_LEN_MAX 4 +#define MCAST_BLOCK_SOURCE 43 +#define MCAST_EXCLUDE 0 +#define MCAST_INCLUDE 1 +#define MCAST_JOIN_GROUP 42 +#define MCAST_JOIN_SOURCE_GROUP 46 +#define MCAST_LEAVE_GROUP 45 +#define MCAST_LEAVE_SOURCE_GROUP 47 +#define MCAST_MSFILTER 48 +#define MCAST_UNBLOCK_SOURCE 44 +#define MIN(a,b) (((a)<(b))?(a):(b)) +#define MINDOUBLE DBL_MIN +#define MINFLOAT FLT_MIN +#define MININT INT_MIN +#define MINLONG LONG_MIN +#define MINSHORT SHRT_MIN +#define MLD_LISTENER_QUERY 130 +#define MLD_LISTENER_REDUCTION 132 +#define MLD_LISTENER_REPORT 131 +#define MM_APPL 8 +#define MM_CONSOLE 512 +#define MM_ERROR 2 +#define MM_FIRM 4 +#define MM_HALT 1 +#define MM_HARD 1 +#define MM_INFO 4 +#define MM_NOCON 4 +#define MM_NOMSG 1 +#define MM_NOSEV 0 +#define MM_NOTOK (-1) +#define MM_NRECOV 128 +#define MM_NULLACT ((char*)0) +#define MM_NULLLBL ((char*)0) +#define MM_NULLMC 0L +#define MM_NULLSEV 0 +#define MM_NULLTAG ((char*)0) +#define MM_NULLTXT ((char*)0) +#define MM_OK 0 +#define MM_OPSYS 32 +#define MM_PRINT 256 +#define MM_RECOVER 64 +#define MM_SOFT 2 +#define MM_UTIL 16 +#define MM_WARNING 3 +#define MODE_ACK 0x04 +#define MODE_B 2 +#define MODE_C 3 +#define MODE_ECHO 0x0200 +#define MODE_EDIT 0x01 +#define MODE_FLOW 0x0100 +#define MODE_FORCE 0x1000 +#define MODE_INBIN 0x0400 +#define MODE_LIT_ECHO 0x10 +#define MODE_MASK 0x1f +#define MODE_OUTBIN 0x0800 +#define MODE_S 1 +#define MODE_SOFT_TAB 0x08 +#define MODE_TRAPSIG 0x02 +#define MOD_CLKA ADJ_OFFSET_SINGLESHOT +#define MOD_CLKB ADJ_TICK +#define MOD_ESTERROR ADJ_ESTERROR +#define MOD_FREQUENCY ADJ_FREQUENCY +#define MOD_MAXERROR ADJ_MAXERROR +#define MOD_MICRO ADJ_MICRO +#define MOD_NANO ADJ_NANO +#define MOD_OFFSET ADJ_OFFSET +#define MOD_STATUS ADJ_STATUS +#define MOD_TAI ADJ_TAI +#define MOD_TIMECONST ADJ_TIMECONST +#define MON_1 0x2001A +#define MON_10 0x20023 +#define MON_11 0x20024 +#define MON_12 0x20025 +#define MON_2 0x2001B +#define MON_3 0x2001C +#define MON_4 0x2001D +#define MON_5 0x2001E +#define MON_6 0x2001F +#define MON_7 0x20020 +#define MON_8 0x20021 +#define MON_9 0x20022 +#define MORECTL 1 +#define MOREDATA 2 +#define MSG_ANY 0x02 +#define MSG_BAND 0x04 +#define MSG_HIPRI 0x01 +#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK +#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED +#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL +#define MUXID_ALL (-1) +#define M_1_PI 0.31830988618379067154 +#define M_2_PI 0.63661977236758134308 +#define M_2_SQRTPI 1.12837916709551257390 +#define M_E 2.7182818284590452354 +#define M_LN10 2.30258509299404568402 +#define M_LN2 0.69314718055994530942 +#define M_LOG10E 0.43429448190325182765 +#define M_LOG2E 1.4426950408889634074 +#define M_PI 3.14159265358979323846 +#define M_PI_2 1.57079632679489661923 +#define M_PI_4 0.78539816339744830962 +#define M_SQRT1_2 0.70710678118654752440 +#define M_SQRT2 1.41421356237309504880 +#define NAMESERVER_PORT NS_DEFAULTPORT +#define NAME_MAX 255 +#define NAN (0.0f/0.0f) +#define NBBY 8 +#define NCARGS 131072 +#define ND_NA_FLAG_OVERRIDE 0x00000020 +#define ND_NA_FLAG_ROUTER 0x00000080 +#define ND_NA_FLAG_SOLICITED 0x00000040 +#define ND_NEIGHBOR_ADVERT 136 +#define ND_NEIGHBOR_SOLICIT 135 +#define ND_OPT_HOME_AGENT_INFO 8 +#define ND_OPT_MTU 5 +#define ND_OPT_PI_FLAG_AUTO 0x40 +#define ND_OPT_PI_FLAG_ONLINK 0x80 +#define ND_OPT_PI_FLAG_RADDR 0x20 +#define ND_OPT_PREFIX_INFORMATION 3 +#define ND_OPT_REDIRECTED_HEADER 4 +#define ND_OPT_RTR_ADV_INTERVAL 7 +#define ND_OPT_SOURCE_LINKADDR 1 +#define ND_OPT_TARGET_LINKADDR 2 +#define ND_RA_FLAG_HOME_AGENT 0x20 +#define ND_RA_FLAG_MANAGED 0x80 +#define ND_RA_FLAG_OTHER 0x40 +#define ND_REDIRECT 137 +#define ND_ROUTER_ADVERT 134 +#define ND_ROUTER_SOLICIT 133 +#define NEW_ENV_VALUE 1 +#define NEW_ENV_VAR 0 +#define NGROUPS 32 +#define NGROUPS_MAX 32 +#define NL_ARGMAX 9 +#define NL_CAT_LOCALE 1 +#define NL_LANGMAX 32 +#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) +#define NL_MSGMAX 32767 +#define NL_NMAX 16 +#define NL_SETD 1 +#define NL_SETMAX 255 +#define NL_TEXTMAX 2048 +#define NOERROR ns_r_noerror +#define NOEXPR 0x50001 +#define NOFILE 256 +#define NOGROUP (-1) +#define NOP 241 +#define NOSTR 0x50003 +#define NOTAUTH ns_r_notauth +#define NOTIMP ns_r_notimpl +#define NOTZONE ns_r_notzone +#define NR_ICMP_TYPES 18 +#define NR_ICMP_UNREACH 15 +#define NSLC 18 +#define NS_ALG_DH 2 +#define NS_ALG_DSA 3 +#define NS_ALG_DSS NS_ALG_DSA +#define NS_ALG_EXPIRE_ONLY 253 +#define NS_ALG_MD5RSA 1 +#define NS_ALG_PRIVATE_OID 254 +#define NS_CMPRSFLGS 0xc0 +#define NS_DEFAULTPORT 53 +#define NS_DSA_MAX_BYTES 405 +#define NS_DSA_MIN_SIZE 213 +#define NS_DSA_SIG_SIZE 41 +#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) +#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) +#define NS_HFIXEDSZ 12 +#define NS_IN6ADDRSZ 16 +#define NS_INADDRSZ 4 +#define NS_INT16SZ 2 +#define NS_INT32SZ 4 +#define NS_INT8SZ 1 +#define NS_KEY_EXTENDED_FLAGS 0x1000 +#define NS_KEY_NAME_ENTITY 0x0200 +#define NS_KEY_NAME_RESERVED 0x0300 +#define NS_KEY_NAME_TYPE 0x0300 +#define NS_KEY_NAME_USER 0x0000 +#define NS_KEY_NAME_ZONE 0x0100 +#define NS_KEY_NO_AUTH 0x8000 +#define NS_KEY_NO_CONF 0x4000 +#define NS_KEY_PROT_ANY 255 +#define NS_KEY_PROT_DNSSEC 3 +#define NS_KEY_PROT_EMAIL 2 +#define NS_KEY_PROT_IPSEC 4 +#define NS_KEY_PROT_TLS 1 +#define NS_KEY_RESERVED10 0x0020 +#define NS_KEY_RESERVED11 0x0010 +#define NS_KEY_RESERVED2 0x2000 +#define NS_KEY_RESERVED4 0x0800 +#define NS_KEY_RESERVED5 0x0400 +#define NS_KEY_RESERVED8 0x0080 +#define NS_KEY_RESERVED9 0x0040 +#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) +#define NS_KEY_RESERVED_BITMASK2 0xFFFF +#define NS_KEY_SIGNATORYMASK 0x000F +#define NS_KEY_TYPEMASK 0xC000 +#define NS_KEY_TYPE_AUTH_CONF 0x0000 +#define NS_KEY_TYPE_AUTH_ONLY 0x4000 +#define NS_KEY_TYPE_CONF_ONLY 0x8000 +#define NS_KEY_TYPE_NO_KEY 0xC000 +#define NS_MAXCDNAME 255 +#define NS_MAXDNAME 1025 +#define NS_MAXLABEL 63 +#define NS_MAXMSG 65535 +#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) +#define NS_MD5RSA_MAX_BITS 4096 +#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) +#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) +#define NS_MD5RSA_MIN_BITS 512 +#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) +#define NS_NOTIFY_OP ns_o_notify +#define NS_NXT_BITS 8 +#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) +#define NS_NXT_MAX 127 +#define NS_OPT_DNSSEC_OK 0x8000U +#define NS_OPT_NSID 3 +#define NS_PACKETSZ 512 +#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) +#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) +#define NS_QFIXEDSZ 4 +#define NS_RRFIXEDSZ 10 +#define NS_SIG_ALG 2 +#define NS_SIG_EXPIR 8 +#define NS_SIG_FOOT 16 +#define NS_SIG_LABELS 3 +#define NS_SIG_OTTL 4 +#define NS_SIG_SIGNED 12 +#define NS_SIG_SIGNER 18 +#define NS_SIG_TYPE 0 +#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" +#define NS_TSIG_ERROR_FORMERR -12 +#define NS_TSIG_ERROR_NO_SPACE -11 +#define NS_TSIG_ERROR_NO_TSIG -10 +#define NS_TSIG_FUDGE 300 +#define NS_TSIG_TCP_COUNT 100 +#define NS_UPDATE_OP ns_o_update +#define NTELOPTS (1+TELOPT_NEW_ENVIRON) +#define NULL ((void*)0) +#define NXDOMAIN ns_r_nxdomain +#define NXRRSET ns_r_nxrrset +#define NZERO 20 +#define OLD_ENV_VALUE 0 +#define OLD_ENV_VAR 1 +#define ONCE_FLAG_INIT 0 +#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) +#define O_APPEND __WASI_FDFLAGS_APPEND +#define O_CLOEXEC (0) +#define O_CREAT (__WASI_OFLAGS_CREAT << 12) +#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) +#define O_DSYNC __WASI_FDFLAGS_DSYNC +#define O_EXCL (__WASI_OFLAGS_EXCL << 12) +#define O_EXEC (0x02000000) +#define O_NOCTTY (0) +#define O_NOFOLLOW (0x01000000) +#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK +#define O_RDONLY (0x04000000) +#define O_RDWR (O_RDONLY | O_WRONLY) +#define O_RSYNC __WASI_FDFLAGS_RSYNC +#define O_SEARCH (0x08000000) +#define O_SYNC __WASI_FDFLAGS_SYNC +#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) +#define O_TTY_INIT (0) +#define O_WRONLY (0x10000000) +#define PACKETSZ NS_PACKETSZ +#define PACKET_ADD_MEMBERSHIP 1 +#define PACKET_AUXDATA 8 +#define PACKET_BROADCAST 1 +#define PACKET_COPY_THRESH 7 +#define PACKET_DROP_MEMBERSHIP 2 +#define PACKET_FANOUT 18 +#define PACKET_FANOUT_DATA 22 +#define PACKET_FASTROUTE 6 +#define PACKET_HDRLEN 11 +#define PACKET_HOST 0 +#define PACKET_IGNORE_OUTGOING 23 +#define PACKET_LOOPBACK 5 +#define PACKET_LOSS 14 +#define PACKET_MR_ALLMULTI 2 +#define PACKET_MR_MULTICAST 0 +#define PACKET_MR_PROMISC 1 +#define PACKET_MR_UNICAST 3 +#define PACKET_MULTICAST 2 +#define PACKET_ORIGDEV 9 +#define PACKET_OTHERHOST 3 +#define PACKET_OUTGOING 4 +#define PACKET_QDISC_BYPASS 20 +#define PACKET_RECV_OUTPUT 3 +#define PACKET_RESERVE 12 +#define PACKET_ROLLOVER_STATS 21 +#define PACKET_RX_RING 5 +#define PACKET_STATISTICS 6 +#define PACKET_TIMESTAMP 17 +#define PACKET_TX_HAS_OFF 19 +#define PACKET_TX_RING 13 +#define PACKET_TX_TIMESTAMP 16 +#define PACKET_VERSION 10 +#define PACKET_VNET_HDR 15 +#define PAGESIZE (0x10000) +#define PAGE_SIZE PAGESIZE +#define PATH_MAX 4096 +#define PDP_ENDIAN __PDP_ENDIAN +#define PF_INET 1 +#define PF_INET6 2 +#define PF_UNSPEC 0 +#define PM_STR 0x20027 +#define POLLERR 0x1000 +#define POLLHUP 0x2000 +#define POLLIN POLLRDNORM +#define POLLNVAL 0x4000 +#define POLLOUT POLLWRNORM +#define POLLRDNORM 0x1 +#define POLLWRNORM 0x2 +#define POSIX_CLOSE_RESTART 0 +#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED +#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE +#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL +#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM +#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL +#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED +#define PRELIM 1 +#define PRIX16 __UINT16_FMTX__ +#define PRIX32 __UINT32_FMTX__ +#define PRIX64 __UINT64_FMTX__ +#define PRIX8 __UINT8_FMTX__ +#define PRIXFAST16 __UINT_FAST16_FMTX__ +#define PRIXFAST32 __UINT_FAST32_FMTX__ +#define PRIXFAST64 __UINT_FAST64_FMTX__ +#define PRIXFAST8 __UINT_FAST8_FMTX__ +#define PRIXLEAST16 __UINT_LEAST16_FMTX__ +#define PRIXLEAST32 __UINT_LEAST32_FMTX__ +#define PRIXLEAST64 __UINT_LEAST64_FMTX__ +#define PRIXLEAST8 __UINT_LEAST8_FMTX__ +#define PRIXMAX __UINTMAX_FMTX__ +#define PRIXPTR __UINTPTR_FMTX__ +#define PRId16 __INT16_FMTd__ +#define PRId32 __INT32_FMTd__ +#define PRId64 __INT64_FMTd__ +#define PRId8 __INT8_FMTd__ +#define PRIdFAST16 __INT_FAST16_FMTd__ +#define PRIdFAST32 __INT_FAST32_FMTd__ +#define PRIdFAST64 __INT_FAST64_FMTd__ +#define PRIdFAST8 __INT_FAST8_FMTd__ +#define PRIdLEAST16 __INT_LEAST16_FMTd__ +#define PRIdLEAST32 __INT_LEAST32_FMTd__ +#define PRIdLEAST64 __INT_LEAST64_FMTd__ +#define PRIdLEAST8 __INT_LEAST8_FMTd__ +#define PRIdMAX __INTMAX_FMTd__ +#define PRIdPTR __INTPTR_FMTd__ +#define PRIi16 __INT16_FMTi__ +#define PRIi32 __INT32_FMTi__ +#define PRIi64 __INT64_FMTi__ +#define PRIi8 __INT8_FMTi__ +#define PRIiFAST16 __INT_FAST16_FMTi__ +#define PRIiFAST32 __INT_FAST32_FMTi__ +#define PRIiFAST64 __INT_FAST64_FMTi__ +#define PRIiFAST8 __INT_FAST8_FMTi__ +#define PRIiLEAST16 __INT_LEAST16_FMTi__ +#define PRIiLEAST32 __INT_LEAST32_FMTi__ +#define PRIiLEAST64 __INT_LEAST64_FMTi__ +#define PRIiLEAST8 __INT_LEAST8_FMTi__ +#define PRIiMAX __INTMAX_FMTi__ +#define PRIiPTR __INTPTR_FMTi__ +#define PRIo16 __UINT16_FMTo__ +#define PRIo32 __UINT32_FMTo__ +#define PRIo64 __UINT64_FMTo__ +#define PRIo8 __UINT8_FMTo__ +#define PRIoFAST16 __UINT_FAST16_FMTo__ +#define PRIoFAST32 __UINT_FAST32_FMTo__ +#define PRIoFAST64 __UINT_FAST64_FMTo__ +#define PRIoFAST8 __UINT_FAST8_FMTo__ +#define PRIoLEAST16 __UINT_LEAST16_FMTo__ +#define PRIoLEAST32 __UINT_LEAST32_FMTo__ +#define PRIoLEAST64 __UINT_LEAST64_FMTo__ +#define PRIoLEAST8 __UINT_LEAST8_FMTo__ +#define PRIoMAX __UINTMAX_FMTo__ +#define PRIoPTR __UINTPTR_FMTo__ +#define PRIu16 __UINT16_FMTu__ +#define PRIu32 __UINT32_FMTu__ +#define PRIu64 __UINT64_FMTu__ +#define PRIu8 __UINT8_FMTu__ +#define PRIuFAST16 __UINT_FAST16_FMTu__ +#define PRIuFAST32 __UINT_FAST32_FMTu__ +#define PRIuFAST64 __UINT_FAST64_FMTu__ +#define PRIuFAST8 __UINT_FAST8_FMTu__ +#define PRIuLEAST16 __UINT_LEAST16_FMTu__ +#define PRIuLEAST32 __UINT_LEAST32_FMTu__ +#define PRIuLEAST64 __UINT_LEAST64_FMTu__ +#define PRIuLEAST8 __UINT_LEAST8_FMTu__ +#define PRIuMAX __UINTMAX_FMTu__ +#define PRIuPTR __UINTPTR_FMTu__ +#define PRIx16 __UINT16_FMTx__ +#define PRIx32 __UINT32_FMTx__ +#define PRIx64 __UINT64_FMTx__ +#define PRIx8 __UINT8_FMTx__ +#define PRIxFAST16 __UINT_FAST16_FMTx__ +#define PRIxFAST32 __UINT_FAST32_FMTx__ +#define PRIxFAST64 __UINT_FAST64_FMTx__ +#define PRIxFAST8 __UINT_FAST8_FMTx__ +#define PRIxLEAST16 __UINT_LEAST16_FMTx__ +#define PRIxLEAST32 __UINT_LEAST32_FMTx__ +#define PRIxLEAST64 __UINT_LEAST64_FMTx__ +#define PRIxLEAST8 __UINT_LEAST8_FMTx__ +#define PRIxMAX __UINTMAX_FMTx__ +#define PRIxPTR __UINTPTR_FMTx__ +#define PTRBITS (sizeof(char *) * 8) +#define PTRDIFF_MAX INT32_MAX +#define PTRDIFF_MIN INT32_MIN +#define PUTLONG NS_PUT32 +#define PUTSHORT NS_PUT16 +#define QFIXEDSZ NS_QFIXEDSZ +#define QUERY ns_o_query +#define RADIXCHAR 0x10000 +#define RAND_MAX (0x7fffffff) +#define REC_EOF '\002' +#define REC_EOR '\001' +#define REC_ESC '\377' +#define REFUSED ns_r_refused +#define REGTYPE '0' +#define REG_BADBR 10 +#define REG_BADPAT 2 +#define REG_BADRPT 13 +#define REG_EBRACE 9 +#define REG_EBRACK 7 +#define REG_ECOLLATE 3 +#define REG_ECTYPE 4 +#define REG_EESCAPE 5 +#define REG_ENOSYS -1 +#define REG_EPAREN 8 +#define REG_ERANGE 11 +#define REG_ESPACE 12 +#define REG_ESUBREG 6 +#define REG_EXTENDED 1 +#define REG_ICASE 2 +#define REG_NEWLINE 4 +#define REG_NOMATCH 1 +#define REG_NOSUB 8 +#define REG_NOTBOL 1 +#define REG_NOTEOL 2 +#define REG_OK 0 +#define RE_DUP_MAX 255 +#define RMSGD 0x0001 +#define RMSGN 0x0002 +#define RNORM 0x0000 +#define RPM_PCO_ADD 1 +#define RPM_PCO_CHANGE 2 +#define RPM_PCO_SETGLOBAL 3 +#define RPROTDAT 0x0004 +#define RPROTDIS 0x0008 +#define RPROTMASK 0x001C +#define RPROTNORM 0x0010 +#define RRFIXEDSZ NS_RRFIXEDSZ +#define RRQ 01 +#define RS_HIPRI 0x01 +#define RTLD_DEFAULT ((void *)0) +#define RTLD_GLOBAL 256 +#define RTLD_LAZY 1 +#define RTLD_LOCAL 8 +#define RTLD_NEXT ((void *)-1) +#define RTLD_NODELETE 4096 +#define RTLD_NOLOAD 4 +#define RTLD_NOW 2 +#define RUSAGE_CHILDREN 2 +#define RUSAGE_SELF 1 +#define R_OK (4) +#define SARMAG 8 +#define SB 250 +#define SCHAR_MAX 127 +#define SCHAR_MIN (-128) +#define SCNd16 __INT16_FMTd__ +#define SCNd32 __INT32_FMTd__ +#define SCNd64 __INT64_FMTd__ +#define SCNd8 __INT8_FMTd__ +#define SCNdFAST16 __INT_FAST16_FMTd__ +#define SCNdFAST32 __INT_FAST32_FMTd__ +#define SCNdFAST64 __INT_FAST64_FMTd__ +#define SCNdFAST8 __INT_FAST8_FMTd__ +#define SCNdLEAST16 __INT_LEAST16_FMTd__ +#define SCNdLEAST32 __INT_LEAST32_FMTd__ +#define SCNdLEAST64 __INT_LEAST64_FMTd__ +#define SCNdLEAST8 __INT_LEAST8_FMTd__ +#define SCNdMAX __INTMAX_FMTd__ +#define SCNdPTR __INTPTR_FMTd__ +#define SCNi16 __INT16_FMTi__ +#define SCNi32 __INT32_FMTi__ +#define SCNi64 __INT64_FMTi__ +#define SCNi8 __INT8_FMTi__ +#define SCNiFAST16 __INT_FAST16_FMTi__ +#define SCNiFAST32 __INT_FAST32_FMTi__ +#define SCNiFAST64 __INT_FAST64_FMTi__ +#define SCNiFAST8 __INT_FAST8_FMTi__ +#define SCNiLEAST16 __INT_LEAST16_FMTi__ +#define SCNiLEAST32 __INT_LEAST32_FMTi__ +#define SCNiLEAST64 __INT_LEAST64_FMTi__ +#define SCNiLEAST8 __INT_LEAST8_FMTi__ +#define SCNiMAX __INTMAX_FMTi__ +#define SCNiPTR __INTPTR_FMTi__ +#define SCNo16 __UINT16_FMTo__ +#define SCNo32 __UINT32_FMTo__ +#define SCNo64 __UINT64_FMTo__ +#define SCNo8 __UINT8_FMTo__ +#define SCNoFAST16 __UINT_FAST16_FMTo__ +#define SCNoFAST32 __UINT_FAST32_FMTo__ +#define SCNoFAST64 __UINT_FAST64_FMTo__ +#define SCNoFAST8 __UINT_FAST8_FMTo__ +#define SCNoLEAST16 __UINT_LEAST16_FMTo__ +#define SCNoLEAST32 __UINT_LEAST32_FMTo__ +#define SCNoLEAST64 __UINT_LEAST64_FMTo__ +#define SCNoLEAST8 __UINT_LEAST8_FMTo__ +#define SCNoMAX __UINTMAX_FMTo__ +#define SCNoPTR __UINTPTR_FMTo__ +#define SCNu16 __UINT16_FMTu__ +#define SCNu32 __UINT32_FMTu__ +#define SCNu64 __UINT64_FMTu__ +#define SCNu8 __UINT8_FMTu__ +#define SCNuFAST16 __UINT_FAST16_FMTu__ +#define SCNuFAST32 __UINT_FAST32_FMTu__ +#define SCNuFAST64 __UINT_FAST64_FMTu__ +#define SCNuFAST8 __UINT_FAST8_FMTu__ +#define SCNuLEAST16 __UINT_LEAST16_FMTu__ +#define SCNuLEAST32 __UINT_LEAST32_FMTu__ +#define SCNuLEAST64 __UINT_LEAST64_FMTu__ +#define SCNuLEAST8 __UINT_LEAST8_FMTu__ +#define SCNuMAX __UINTMAX_FMTu__ +#define SCNuPTR __UINTPTR_FMTu__ +#define SCNx16 __UINT16_FMTx__ +#define SCNx32 __UINT32_FMTx__ +#define SCNx64 __UINT64_FMTx__ +#define SCNx8 __UINT8_FMTx__ +#define SCNxFAST16 __UINT_FAST16_FMTx__ +#define SCNxFAST32 __UINT_FAST32_FMTx__ +#define SCNxFAST64 __UINT_FAST64_FMTx__ +#define SCNxFAST8 __UINT_FAST8_FMTx__ +#define SCNxLEAST16 __UINT_LEAST16_FMTx__ +#define SCNxLEAST32 __UINT_LEAST32_FMTx__ +#define SCNxLEAST64 __UINT_LEAST64_FMTx__ +#define SCNxLEAST8 __UINT_LEAST8_FMTx__ +#define SCNxMAX __UINTMAX_FMTx__ +#define SCNxPTR __UINTPTR_FMTx__ +#define SE 240 +#define SEEK_CUR __WASI_WHENCE_CUR +#define SEEK_END __WASI_WHENCE_END +#define SEEK_SET __WASI_WHENCE_SET +#define SEGSIZE 512 +#define SEM_FAILED ((sem_t *)0) +#define SERVFAIL ns_r_servfail +#define SHORTBITS (sizeof(short) * 8) +#define SHRT_MAX 0x7fff +#define SHRT_MIN (-1-0x7fff) +#define SHUT_RD __WASI_SDFLAGS_RD +#define SHUT_RDWR (SHUT_RD | SHUT_WR) +#define SHUT_WR __WASI_SDFLAGS_WR +#define SIG_ATOMIC_MAX INT32_MAX +#define SIG_ATOMIC_MIN INT32_MIN +#define SIZE_MAX UINT32_MAX +#define SI_LOAD_SHIFT 16 +#define SLC_ABORT 7 +#define SLC_ACK 0x80 +#define SLC_AO 4 +#define SLC_AYT 5 +#define SLC_BRK 2 +#define SLC_CANTCHANGE 1 +#define SLC_DEFAULT 3 +#define SLC_EC 10 +#define SLC_EL 11 +#define SLC_EOF 8 +#define SLC_EOR 6 +#define SLC_EW 12 +#define SLC_FLAGS 1 +#define SLC_FLUSHIN 0x40 +#define SLC_FLUSHOUT 0x20 +#define SLC_FORW1 17 +#define SLC_FORW2 18 +#define SLC_FUNC 0 +#define SLC_IP 3 +#define SLC_LEVELBITS 0x03 +#define SLC_LNEXT 14 +#define SLC_NAME(x) slc_names[x] +#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, +#define SLC_NAMES SLC_NAMELIST +#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) +#define SLC_NOSUPPORT 0 +#define SLC_RP 13 +#define SLC_SUSP 9 +#define SLC_SYNCH 1 +#define SLC_VALUE 2 +#define SLC_VARIABLE 2 +#define SLC_XOFF 16 +#define SLC_XON 15 +#define SNDPIPE 0x002 +#define SNDZERO 0x001 +#define SOCK_CLOEXEC (0x00002000) +#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM +#define SOCK_NONBLOCK (0x00004000) +#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM +#define SOL_SOCKET 0x7fffffff +#define SOL_TCP 6 +#define SOL_UDP 17 +#define SO_TYPE 3 +#define SSIZE_MAX LONG_MAX +#define STATUS ns_o_status +#define STA_CLK 0x8000 +#define STA_CLOCKERR 0x1000 +#define STA_DEL 0x0020 +#define STA_FLL 0x0008 +#define STA_FREQHOLD 0x0080 +#define STA_INS 0x0010 +#define STA_MODE 0x4000 +#define STA_NANO 0x2000 +#define STA_PLL 0x0001 +#define STA_PPSERROR 0x0800 +#define STA_PPSFREQ 0x0002 +#define STA_PPSJITTER 0x0200 +#define STA_PPSSIGNAL 0x0100 +#define STA_PPSTIME 0x0004 +#define STA_PPSWANDER 0x0400 +#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) +#define STA_UNSYNC 0x0040 +#define STDERR_FILENO 2 +#define STDIN_FILENO 0 +#define STDOUT_FILENO 1 +#define STRU_F 1 +#define STRU_P 3 +#define STRU_R 2 +#define SUN_LEN(s) (2+strlen((s)->sun_path)) +#define SUSP 237 +#define SYMLOOP_MAX 40 +#define SYMTYPE '2' +#define SYNCH 242 +#define S_ADDT ns_s_ar +#define S_BANDURG 0x0200 +#define S_ERROR 0x0010 +#define S_HANGUP 0x0020 +#define S_HIPRI 0x0002 +#define S_IEXEC S_IXUSR +#define S_IFBLK (0x6000) +#define S_IFCHR (0x2000) +#define S_IFDIR (0x4000) +#define S_IFIFO (0xc000) +#define S_IFLNK (0xa000) +#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) +#define S_IFREG (0x8000) +#define S_IFSOCK (0xc000) +#define S_INPUT 0x0001 +#define S_IREAD S_IRUSR +#define S_IRGRP (0x20) +#define S_IROTH (0x4) +#define S_IRUSR (0x100) +#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) +#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) +#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) +#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) +#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) +#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) +#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) +#define S_ISGID (0x400) +#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) +#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) +#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) +#define S_ISUID (0x800) +#define S_ISVTX (0x200) +#define S_IWGRP (0x10) +#define S_IWOTH (0x2) +#define S_IWRITE S_IWUSR +#define S_IWUSR (0x80) +#define S_IXGRP (0x8) +#define S_IXOTH (0x1) +#define S_IXUSR (0x40) +#define S_MSG 0x0008 +#define S_OUTPUT 0x0004 +#define S_PREREQ ns_s_pr +#define S_RDBAND 0x0080 +#define S_RDNORM 0x0040 +#define S_UPDATE ns_s_ud +#define S_WRBAND 0x0100 +#define S_WRNORM S_OUTPUT +#define S_ZONE ns_s_zn +#define TCPI_OPT_ECN 8 +#define TCPI_OPT_SACK 2 +#define TCPI_OPT_TIMESTAMPS 1 +#define TCPI_OPT_WSCALE 4 +#define TCPOLEN_MAXSEG 4 +#define TCPOLEN_SACK_PERMITTED 2 +#define TCPOLEN_TIMESTAMP 10 +#define TCPOLEN_WINDOW 3 +#define TCPOPT_EOL 0 +#define TCPOPT_MAXSEG 2 +#define TCPOPT_NOP 1 +#define TCPOPT_SACK 5 +#define TCPOPT_SACK_PERMITTED 4 +#define TCPOPT_TIMESTAMP 8 +#define TCPOPT_WINDOW 3 +#define TCP_CA_CWR 2 +#define TCP_CA_Disorder 1 +#define TCP_CA_Loss 4 +#define TCP_CA_Open 0 +#define TCP_CA_Recovery 3 +#define TCP_CC_INFO 26 +#define TCP_CLOSE 7 +#define TCP_CLOSE_WAIT 8 +#define TCP_CLOSING 11 +#define TCP_CM_INQ TCP_INQ +#define TCP_CONGESTION 13 +#define TCP_CORK 3 +#define TCP_DEFER_ACCEPT 9 +#define TCP_ENCAP_ESPINTCP 7 +#define TCP_ESTABLISHED 1 +#define TCP_FASTOPEN 23 +#define TCP_FASTOPEN_CONNECT 30 +#define TCP_FASTOPEN_KEY 33 +#define TCP_FASTOPEN_NO_COOKIE 34 +#define TCP_FIN_WAIT1 4 +#define TCP_FIN_WAIT2 5 +#define TCP_INFO 11 +#define TCP_INQ 36 +#define TCP_KEEPCNT 6 +#define TCP_KEEPIDLE 4 +#define TCP_KEEPINTVL 5 +#define TCP_LAST_ACK 9 +#define TCP_LINGER2 8 +#define TCP_LISTEN 10 +#define TCP_MAXSEG 2 +#define TCP_MD5SIG 14 +#define TCP_MD5SIG_EXT 32 +#define TCP_MD5SIG_FLAG_IFINDEX 0x2 +#define TCP_MD5SIG_FLAG_PREFIX 0x1 +#define TCP_MD5SIG_MAXKEYLEN 80 +#define TCP_NODELAY 1 +#define TCP_NOTSENT_LOWAT 25 +#define TCP_QUEUE_SEQ 21 +#define TCP_QUICKACK 12 +#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 +#define TCP_REPAIR 19 +#define TCP_REPAIR_OFF 0 +#define TCP_REPAIR_OFF_NO_WP -1 +#define TCP_REPAIR_ON 1 +#define TCP_REPAIR_OPTIONS 22 +#define TCP_REPAIR_QUEUE 20 +#define TCP_REPAIR_WINDOW 29 +#define TCP_SAVED_SYN 28 +#define TCP_SAVE_SYN 27 +#define TCP_SYNCNT 7 +#define TCP_SYN_RECV 3 +#define TCP_SYN_SENT 2 +#define TCP_THIN_DUPACK 17 +#define TCP_THIN_LINEAR_TIMEOUTS 16 +#define TCP_TIMESTAMP 24 +#define TCP_TIME_WAIT 6 +#define TCP_TX_DELAY 37 +#define TCP_ULP 31 +#define TCP_USER_TIMEOUT 18 +#define TCP_WINDOW_CLAMP 10 +#define TCP_ZEROCOPY_RECEIVE 35 +#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] +#define TELCMD_FIRST xEOF +#define TELCMD_LAST IAC +#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) +#define TELOPT_3270REGIME 29 +#define TELOPT_AUTHENTICATION 37 +#define TELOPT_BINARY 0 +#define TELOPT_BM 19 +#define TELOPT_DET 20 +#define TELOPT_ECHO 1 +#define TELOPT_ENCRYPT 38 +#define TELOPT_EOR 25 +#define TELOPT_EXOPL 255 +#define TELOPT_LFLOW 33 +#define TELOPT_LINEMODE 34 +#define TELOPT_LOGOUT 18 +#define TELOPT_NAMS 4 +#define TELOPT_NAOCRD 10 +#define TELOPT_NAOFFD 13 +#define TELOPT_NAOHTD 12 +#define TELOPT_NAOHTS 11 +#define TELOPT_NAOL 8 +#define TELOPT_NAOLFD 16 +#define TELOPT_NAOP 9 +#define TELOPT_NAOVTD 15 +#define TELOPT_NAOVTS 14 +#define TELOPT_NAWS 31 +#define TELOPT_NEW_ENVIRON 39 +#define TELOPT_OLD_ENVIRON 36 +#define TELOPT_OUTMRK 27 +#define TELOPT_RCP 2 +#define TELOPT_RCTE 7 +#define TELOPT_SGA 3 +#define TELOPT_SNDLOC 23 +#define TELOPT_STATUS 5 +#define TELOPT_SUPDUP 21 +#define TELOPT_SUPDUPOUTPUT 22 +#define TELOPT_TM 6 +#define TELOPT_TSPEED 32 +#define TELOPT_TTYLOC 28 +#define TELOPT_TTYPE 24 +#define TELOPT_TUID 26 +#define TELOPT_X3PAD 30 +#define TELOPT_XASCII 17 +#define TELOPT_XDISPLOC 35 +#define TELQUAL_INFO 2 +#define TELQUAL_IS 0 +#define TELQUAL_NAME 3 +#define TELQUAL_REPLY 2 +#define TELQUAL_SEND 1 +#define TGEXEC 00010 +#define TGREAD 00040 +#define TGWRITE 00020 +#define THOUSEP 0x10001 +#define TH_ACK 0x10 +#define TH_FIN 0x01 +#define TH_PUSH 0x08 +#define TH_RST 0x04 +#define TH_SYN 0x02 +#define TH_URG 0x20 +#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME +#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) +#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) +#define TIME_BAD TIME_ERROR +#define TIME_DEL 2 +#define TIME_ERROR 5 +#define TIME_INS 1 +#define TIME_OK 0 +#define TIME_OOP 3 +#define TIME_UTC 1 +#define TIME_WAIT 4 +#define TMAGIC "ustar" +#define TMAGLEN 6 +#define TOEXEC 00001 +#define TOREAD 00004 +#define TOWRITE 00002 +#define TRANSIENT 4 +#define TSGID 02000 +#define TSS_DTOR_ITERATIONS 4 +#define TSUID 04000 +#define TSVTX 01000 +#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) +#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) +#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) +#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) +#define TTYDEF_SPEED (B9600) +#define TTY_NAME_MAX 32 +#define TUEXEC 00100 +#define TUREAD 00400 +#define TUWRITE 00200 +#define TVERSION "00" +#define TVERSLEN 2 +#define TYPE_A 1 +#define TYPE_E 2 +#define TYPE_I 3 +#define TYPE_L 4 +#define TZNAME_MAX 6 +#define T_A ns_t_a +#define T_A6 ns_t_a6 +#define T_AAAA ns_t_aaaa +#define T_AFSDB ns_t_afsdb +#define T_ANY ns_t_any +#define T_ATMA ns_t_atma +#define T_AXFR ns_t_axfr +#define T_CNAME ns_t_cname +#define T_DNAME ns_t_dname +#define T_EID ns_t_eid +#define T_FMT 0x2002A +#define T_FMT_AMPM 0x2002B +#define T_GPOS ns_t_gpos +#define T_HINFO ns_t_hinfo +#define T_ISDN ns_t_isdn +#define T_IXFR ns_t_ixfr +#define T_KEY ns_t_key +#define T_LOC ns_t_loc +#define T_MAILA ns_t_maila +#define T_MAILB ns_t_mailb +#define T_MB ns_t_mb +#define T_MD ns_t_md +#define T_MF ns_t_mf +#define T_MG ns_t_mg +#define T_MINFO ns_t_minfo +#define T_MR ns_t_mr +#define T_MX ns_t_mx +#define T_NAPTR ns_t_naptr +#define T_NIMLOC ns_t_nimloc +#define T_NS ns_t_ns +#define T_NSAP ns_t_nsap +#define T_NSAP_PTR ns_t_nsap_ptr +#define T_NULL ns_t_null +#define T_NXT ns_t_nxt +#define T_PTR ns_t_ptr +#define T_PX ns_t_px +#define T_RP ns_t_rp +#define T_RT ns_t_rt +#define T_SIG ns_t_sig +#define T_SOA ns_t_soa +#define T_SRV ns_t_srv +#define T_TSIG ns_t_tsig +#define T_TXT ns_t_txt +#define T_WKS ns_t_wks +#define T_X25 ns_t_x25 +#define UCHAR_MAX 255 +#define UDP_CORK 1 +#define UDP_ENCAP 100 +#define UDP_ENCAP_ESPINUDP 2 +#define UDP_ENCAP_ESPINUDP_NON_IKE 1 +#define UDP_ENCAP_GTP0 4 +#define UDP_ENCAP_GTP1U 5 +#define UDP_ENCAP_L2TPINUDP 3 +#define UDP_ENCAP_RXRPC 6 +#define UDP_GRO 104 +#define UDP_NO_CHECK6_RX 102 +#define UDP_NO_CHECK6_TX 101 +#define UDP_SEGMENT 103 +#define UINT16_C(c) c +#define UINT16_MAX (0xffff) +#define UINT32_C(c) c ## U +#define UINT32_MAX (0xffffffffu) +#define UINT64_C(c) c ## ULL +#define UINT64_MAX (0xffffffffffffffffu) +#define UINT8_C(c) c +#define UINT8_MAX (0xff) +#define UINTMAX_C(c) c ## ULL +#define UINTMAX_MAX UINT64_MAX +#define UINTPTR_MAX UINT32_MAX +#define UINT_FAST16_MAX UINT16_MAX +#define UINT_FAST32_MAX UINT32_MAX +#define UINT_FAST64_MAX UINT64_MAX +#define UINT_FAST8_MAX UINT8_MAX +#define UINT_LEAST16_MAX UINT16_MAX +#define UINT_LEAST32_MAX UINT32_MAX +#define UINT_LEAST64_MAX UINT64_MAX +#define UINT_LEAST8_MAX UINT8_MAX +#define UINT_MAX 0xffffffffU +#define UIO_MAXIOV 1024 +#define ULLONG_MAX (2ULL*LLONG_MAX+1) +#define ULONG_MAX (2UL*LONG_MAX+1) +#define USHRT_MAX 0xffff +#define UTIME_NOW (-1) +#define UTIME_OMIT (-2) +#define WCHAR_MAX (0x7fffffff+L'\0') +#define WCHAR_MIN (-1-0x7fffffff+L'\0') +#define WEOF 0xffffffffU +#define WILL 251 +#define WINT_MAX UINT32_MAX +#define WINT_MIN 0U +#define WONT 252 +#define WORD_BIT 32 +#define WRQ 02 +#define W_OK (2) +#define X_OK (1) +#define YESEXPR 0x50000 +#define YESSTR 0x50002 +#define YXDOMAIN ns_r_yxdomain +#define YXRRSET ns_r_yxrrset +#define _ALLOCA_H +#define _ALL_SOURCE 1 +#define _ARPA_FTP_H +#define _ARPA_INET_H +#define _ARPA_NAMESER_H +#define _ARPA_TELNET_H +#define _ARPA_TFTP_H +#define _AR_H +#define _BYTESWAP_H +#define _COMPLEX_H +#define _CPIO_H +#define _CRYPT_H +#define _CS_GNU_LIBC_VERSION 2 +#define _CS_GNU_LIBPTHREAD_VERSION 3 +#define _CS_PATH 0 +#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 +#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 +#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 +#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 +#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 +#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 +#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 +#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 +#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 +#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 +#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 +#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 +#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 +#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 +#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 +#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 +#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 +#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 +#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 +#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 +#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 +#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 +#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 +#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 +#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 +#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 +#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 +#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 +#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 +#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 +#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 +#define _CS_V6_ENV 1148 +#define _CS_V7_ENV 1149 +#define _CTYPE_H +#define _Complex_I (0.0f+1.0fi) +#define _DIRENT_H +#define _DIRENT_HAVE_D_TYPE +#define _DLFCN_H +#define _ENDIAN_H +#define _ERRNO_H +#define _ERR_H +#define _FCNTL_H +#define _FEATURES_H +#define _FENV_H +#define _FLOAT_H +#define _FMTMSG_H +#define _FNMATCH_H +#define _FTW_H +#define _GETOPT_H +#define _GLOB_H +#define _GNU_SOURCE 1 +#define _ICONV_H +#define _IFADDRS_H +#define _INTTYPES_H +#define _IOFBF 0 +#define _IOLBF 1 +#define _IONBF 2 +#define _ISO646_H +#define _LANGINFO_H +#define _LIBGEN_H +#define _LIMITS_H +#define _LOCALE_H +#define _LP64 1 +#define _MALLOC_H +#define _MATH_H +#define _MONETARY_H +#define _MQUEUE_H +#define _NETINET_ICMP6_H +#define _NETINET_IGMP_H +#define _NETINET_IN_H +#define _NETINET_IN_SYSTM_H +#define _NETINET_IP6_H +#define _NETINET_IP_H +#define _NETINET_IP_ICMP_H +#define _NETINET_TCP_H +#define _NETINET_UDP_H +#define _NETPACKET_PACKET_H +#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) +#define _NL_TYPES_H +#define _PC_2_SYMLINKS 20 +#define _PC_ALLOC_SIZE_MIN 18 +#define _PC_ASYNC_IO 10 +#define _PC_CHOWN_RESTRICTED 6 +#define _PC_FILESIZEBITS 13 +#define _PC_LINK_MAX 0 +#define _PC_MAX_CANON 1 +#define _PC_MAX_INPUT 2 +#define _PC_NAME_MAX 3 +#define _PC_NO_TRUNC 7 +#define _PC_PATH_MAX 4 +#define _PC_PIPE_BUF 5 +#define _PC_PRIO_IO 11 +#define _PC_REC_INCR_XFER_SIZE 14 +#define _PC_REC_MAX_XFER_SIZE 15 +#define _PC_REC_MIN_XFER_SIZE 16 +#define _PC_REC_XFER_ALIGN 17 +#define _PC_SOCK_MAXBUF 12 +#define _PC_SYMLINK_MAX 19 +#define _PC_SYNC_IO 9 +#define _PC_VDISABLE 8 +#define _POLL_H +#define _POSIX2_BC_BASE_MAX 99 +#define _POSIX2_BC_DIM_MAX 2048 +#define _POSIX2_BC_SCALE_MAX 99 +#define _POSIX2_BC_STRING_MAX 1000 +#define _POSIX2_CHARCLASS_NAME_MAX 14 +#define _POSIX2_COLL_WEIGHTS_MAX 2 +#define _POSIX2_C_BIND _POSIX_VERSION +#define _POSIX2_EXPR_NEST_MAX 32 +#define _POSIX2_LINE_MAX 2048 +#define _POSIX2_RE_DUP_MAX 255 +#define _POSIX2_VERSION _POSIX_VERSION +#define _POSIX_ADVISORY_INFO _POSIX_VERSION +#define _POSIX_AIO_LISTIO_MAX 2 +#define _POSIX_AIO_MAX 1 +#define _POSIX_ARG_MAX 4096 +#define _POSIX_BARRIERS _POSIX_VERSION +#define _POSIX_CHILD_MAX 25 +#define _POSIX_CHOWN_RESTRICTED 1 +#define _POSIX_CLOCKRES_MIN 20000000 +#define _POSIX_CLOCK_SELECTION _POSIX_VERSION +#define _POSIX_CPUTIME _POSIX_VERSION +#define _POSIX_DELAYTIMER_MAX 32 +#define _POSIX_FSYNC _POSIX_VERSION +#define _POSIX_HOST_NAME_MAX 255 +#define _POSIX_IPV6 _POSIX_VERSION +#define _POSIX_LINK_MAX 8 +#define _POSIX_LOGIN_NAME_MAX 9 +#define _POSIX_MAX_CANON 255 +#define _POSIX_MAX_INPUT 255 +#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION +#define _POSIX_MQ_OPEN_MAX 8 +#define _POSIX_MQ_PRIO_MAX 32 +#define _POSIX_NAME_MAX 14 +#define _POSIX_NGROUPS_MAX 8 +#define _POSIX_NO_TRUNC 1 +#define _POSIX_OPEN_MAX 20 +#define _POSIX_PATH_MAX 256 +#define _POSIX_PIPE_BUF 512 +#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION +#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION +#define _POSIX_REGEXP 1 +#define _POSIX_RE_DUP_MAX 255 +#define _POSIX_RTSIG_MAX 8 +#define _POSIX_SEM_NSEMS_MAX 256 +#define _POSIX_SEM_VALUE_MAX 32767 +#define _POSIX_SIGQUEUE_MAX 32 +#define _POSIX_SPIN_LOCKS _POSIX_VERSION +#define _POSIX_SSIZE_MAX 32767 +#define _POSIX_SS_REPL_MAX 4 +#define _POSIX_STREAM_MAX 8 +#define _POSIX_SYMLINK_MAX 255 +#define _POSIX_SYMLOOP_MAX 8 +#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION +#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION +#define _POSIX_THREAD_CPUTIME _POSIX_VERSION +#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 +#define _POSIX_THREAD_KEYS_MAX 128 +#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION +#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION +#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION +#define _POSIX_THREAD_THREADS_MAX 64 +#define _POSIX_TIMEOUTS _POSIX_VERSION +#define _POSIX_TIMERS _POSIX_VERSION +#define _POSIX_TIMER_MAX 32 +#define _POSIX_TRACE_EVENT_NAME_MAX 30 +#define _POSIX_TRACE_NAME_MAX 8 +#define _POSIX_TRACE_SYS_MAX 8 +#define _POSIX_TRACE_USER_EVENT_MAX 32 +#define _POSIX_TTY_NAME_MAX 9 +#define _POSIX_TZNAME_MAX 6 +#define _POSIX_V6_ILP32_OFFBIG (1) +#define _POSIX_V7_ILP32_OFFBIG (1) +#define _POSIX_VDISABLE 0 +#define _POSIX_VERSION 200809L +#define _PTRDIFF_T +#define _REGEX_H +#define _SCHED_H +#define _SC_2_CHAR_TERM 95 +#define _SC_2_C_BIND 47 +#define _SC_2_C_DEV 48 +#define _SC_2_FORT_DEV 49 +#define _SC_2_FORT_RUN 50 +#define _SC_2_LOCALEDEF 52 +#define _SC_2_PBS 168 +#define _SC_2_PBS_ACCOUNTING 169 +#define _SC_2_PBS_CHECKPOINT 175 +#define _SC_2_PBS_LOCATE 170 +#define _SC_2_PBS_MESSAGE 171 +#define _SC_2_PBS_TRACK 172 +#define _SC_2_SW_DEV 51 +#define _SC_2_UPE 97 +#define _SC_2_VERSION 46 +#define _SC_ADVISORY_INFO 132 +#define _SC_AIO_LISTIO_MAX 23 +#define _SC_AIO_MAX 24 +#define _SC_AIO_PRIO_DELTA_MAX 25 +#define _SC_ARG_MAX 0 +#define _SC_ASYNCHRONOUS_IO 12 +#define _SC_ATEXIT_MAX 87 +#define _SC_AVPHYS_PAGES 86 +#define _SC_BARRIERS 133 +#define _SC_BC_BASE_MAX 36 +#define _SC_BC_DIM_MAX 37 +#define _SC_BC_SCALE_MAX 38 +#define _SC_BC_STRING_MAX 39 +#define _SC_CHILD_MAX 1 +#define _SC_CLK_TCK 2 +#define _SC_CLOCK_SELECTION 137 +#define _SC_COLL_WEIGHTS_MAX 40 +#define _SC_CPUTIME 138 +#define _SC_DELAYTIMER_MAX 26 +#define _SC_EXPR_NEST_MAX 42 +#define _SC_FSYNC 15 +#define _SC_GETGR_R_SIZE_MAX 69 +#define _SC_GETPW_R_SIZE_MAX 70 +#define _SC_HOST_NAME_MAX 180 +#define _SC_IOV_MAX 60 +#define _SC_IPV6 235 +#define _SC_JOB_CONTROL 7 +#define _SC_LINE_MAX 43 +#define _SC_LOGIN_NAME_MAX 71 +#define _SC_MAPPED_FILES 16 +#define _SC_MEMLOCK 17 +#define _SC_MEMLOCK_RANGE 18 +#define _SC_MEMORY_PROTECTION 19 +#define _SC_MESSAGE_PASSING 20 +#define _SC_MONOTONIC_CLOCK 149 +#define _SC_MQ_OPEN_MAX 27 +#define _SC_MQ_PRIO_MAX 28 +#define _SC_NGROUPS_MAX 3 +#define _SC_NPROCESSORS_CONF 83 +#define _SC_NPROCESSORS_ONLN 84 +#define _SC_NZERO 109 +#define _SC_OPEN_MAX 4 +#define _SC_PAGESIZE 30 +#define _SC_PAGE_SIZE 30 +#define _SC_PASS_MAX 88 +#define _SC_PHYS_PAGES 85 +#define _SC_PRIORITIZED_IO 13 +#define _SC_PRIORITY_SCHEDULING 10 +#define _SC_RAW_SOCKETS 236 +#define _SC_READER_WRITER_LOCKS 153 +#define _SC_REALTIME_SIGNALS 9 +#define _SC_REGEXP 155 +#define _SC_RE_DUP_MAX 44 +#define _SC_RTSIG_MAX 31 +#define _SC_SAVED_IDS 8 +#define _SC_SEMAPHORES 21 +#define _SC_SEM_NSEMS_MAX 32 +#define _SC_SEM_VALUE_MAX 33 +#define _SC_SHARED_MEMORY_OBJECTS 22 +#define _SC_SHELL 157 +#define _SC_SIGQUEUE_MAX 34 +#define _SC_SPAWN 159 +#define _SC_SPIN_LOCKS 154 +#define _SC_SPORADIC_SERVER 160 +#define _SC_SS_REPL_MAX 241 +#define _SC_STREAMS 174 +#define _SC_STREAM_MAX 5 +#define _SC_SYMLOOP_MAX 173 +#define _SC_SYNCHRONIZED_IO 14 +#define _SC_THREADS 67 +#define _SC_THREAD_ATTR_STACKADDR 77 +#define _SC_THREAD_ATTR_STACKSIZE 78 +#define _SC_THREAD_CPUTIME 139 +#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 +#define _SC_THREAD_KEYS_MAX 74 +#define _SC_THREAD_PRIORITY_SCHEDULING 79 +#define _SC_THREAD_PRIO_INHERIT 80 +#define _SC_THREAD_PRIO_PROTECT 81 +#define _SC_THREAD_PROCESS_SHARED 82 +#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 +#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 +#define _SC_THREAD_SAFE_FUNCTIONS 68 +#define _SC_THREAD_SPORADIC_SERVER 161 +#define _SC_THREAD_STACK_MIN 75 +#define _SC_THREAD_THREADS_MAX 76 +#define _SC_TIMEOUTS 164 +#define _SC_TIMERS 11 +#define _SC_TIMER_MAX 35 +#define _SC_TRACE 181 +#define _SC_TRACE_EVENT_FILTER 182 +#define _SC_TRACE_EVENT_NAME_MAX 242 +#define _SC_TRACE_INHERIT 183 +#define _SC_TRACE_LOG 184 +#define _SC_TRACE_NAME_MAX 243 +#define _SC_TRACE_SYS_MAX 244 +#define _SC_TRACE_USER_EVENT_MAX 245 +#define _SC_TTY_NAME_MAX 72 +#define _SC_TYPED_MEMORY_OBJECTS 165 +#define _SC_TZNAME_MAX 6 +#define _SC_UIO_MAXIOV 60 +#define _SC_V6_ILP32_OFF32 176 +#define _SC_V6_ILP32_OFFBIG 177 +#define _SC_V6_LP64_OFF64 178 +#define _SC_V6_LPBIG_OFFBIG 179 +#define _SC_V7_ILP32_OFF32 237 +#define _SC_V7_ILP32_OFFBIG 238 +#define _SC_V7_LP64_OFF64 239 +#define _SC_V7_LPBIG_OFFBIG 240 +#define _SC_VERSION 29 +#define _SC_XBS5_ILP32_OFF32 125 +#define _SC_XBS5_ILP32_OFFBIG 126 +#define _SC_XBS5_LP64_OFF64 127 +#define _SC_XBS5_LPBIG_OFFBIG 128 +#define _SC_XOPEN_CRYPT 92 +#define _SC_XOPEN_ENH_I18N 93 +#define _SC_XOPEN_LEGACY 129 +#define _SC_XOPEN_REALTIME 130 +#define _SC_XOPEN_REALTIME_THREADS 131 +#define _SC_XOPEN_SHM 94 +#define _SC_XOPEN_STREAMS 246 +#define _SC_XOPEN_UNIX 91 +#define _SC_XOPEN_VERSION 89 +#define _SC_XOPEN_XCU_VERSION 90 +#define _SC_XOPEN_XPG2 98 +#define _SC_XOPEN_XPG3 99 +#define _SC_XOPEN_XPG4 100 +#define _SEARCH_H +#define _SEMAPHORE_H +#define _SIZE_T +#define _STDALIGN_H +#define _STDBOOL_H +#define _STDC_PREDEF_H +#define _STDINT_H +#define _STDIO_EXT_H +#define _STDIO_H +#define _STDLIB_H +#define _STDNORETURN_H +#define _STRINGS_H +#define _STRING_H +#define _STROPTS_H +#define _SYSEXITS_H +#define _SYS_EVENTFD_H +#define _SYS_FILE_H +#define _SYS_IOCTL_H +#define _SYS_PARAM_H +#define _SYS_RANDOM_H +#define _SYS_REG_H +#define _SYS_SELECT_H +#define _SYS_SOCKET_H +#define _SYS_STAT_H +#define _SYS_SYSCALL_H +#define _SYS_SYSINFO_H +#define _SYS_TIMEB_H +#define _SYS_TIMEX_H +#define _SYS_TIME_H +#define _SYS_TTYDEFAULTS_H +#define _SYS_TYPES_H +#define _SYS_UIO_H +#define _SYS_UN_H +#define _SYS_UTSNAME_H +#define _TAR_H +#define _TGMATH_H +#define _THREADS_H +#define _TIME_H +#define _UCHAR_H +#define _UNISTD_H +#define _UTIME_H +#define _VALUES_H +#define _VA_LIST +#define _WCHAR_H +#define _WCHAR_T +#define _WCTYPE_H +#define _WINT_T +#define _XOPEN_ENH_I18N 1 +#define _XOPEN_IOV_MAX 16 +#define _XOPEN_NAME_MAX 255 +#define _XOPEN_PATH_MAX 1024 +#define _XOPEN_UNIX 1 +#define _XOPEN_VERSION 700 +#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) +#define __ATOMIC_ACQUIRE 2 +#define __ATOMIC_ACQ_REL 4 +#define __ATOMIC_CONSUME 1 +#define __ATOMIC_RELAXED 0 +#define __ATOMIC_RELEASE 3 +#define __ATOMIC_SEQ_CST 5 +#define __BIGGEST_ALIGNMENT__ 16 +#define __BIG_ENDIAN 4321 +#define __BIND 19950621 +#define __BYTE_ORDER __BYTE_ORDER__ +#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ +#define __CHAR16_TYPE__ unsigned short +#define __CHAR32_TYPE__ unsigned int +#define __CHAR_BIT__ 8 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __CLANG_MAX_ALIGN_T_DEFINED +#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) +#define __CONSTANT_CFSTRINGS__ 1 +#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) +#define __DBL_DECIMAL_DIG__ 17 +#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 +#define __DBL_DIG__ 15 +#define __DBL_EPSILON__ 2.2204460492503131e-16 +#define __DBL_HAS_DENORM__ 1 +#define __DBL_HAS_INFINITY__ 1 +#define __DBL_HAS_QUIET_NAN__ 1 +#define __DBL_MANT_DIG__ 53 +#define __DBL_MAX_10_EXP__ 308 +#define __DBL_MAX_EXP__ 1024 +#define __DBL_MAX__ 1.7976931348623157e+308 +#define __DBL_MIN_10_EXP__ (-307) +#define __DBL_MIN_EXP__ (-1021) +#define __DBL_MIN__ 2.2250738585072014e-308 +#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ +#define __DEFINED_FILE +#define __DEFINED___isoc_va_list +#define __DEFINED_blkcnt_t +#define __DEFINED_blksize_t +#define __DEFINED_clock_t +#define __DEFINED_clockid_t +#define __DEFINED_cnd_t +#define __DEFINED_dev_t +#define __DEFINED_double_t +#define __DEFINED_float_t +#define __DEFINED_fsblkcnt_t +#define __DEFINED_fsfilcnt_t +#define __DEFINED_gid_t +#define __DEFINED_id_t +#define __DEFINED_ino_t +#define __DEFINED_int16_t +#define __DEFINED_int32_t +#define __DEFINED_int64_t +#define __DEFINED_int8_t +#define __DEFINED_intmax_t +#define __DEFINED_intptr_t +#define __DEFINED_key_t +#define __DEFINED_locale_t +#define __DEFINED_mbstate_t +#define __DEFINED_mode_t +#define __DEFINED_mtx_t +#define __DEFINED_nlink_t +#define __DEFINED_off_t +#define __DEFINED_pid_t +#define __DEFINED_pthread_attr_t +#define __DEFINED_pthread_barrier_t +#define __DEFINED_pthread_barrierattr_t +#define __DEFINED_pthread_cond_t +#define __DEFINED_pthread_condattr_t +#define __DEFINED_pthread_key_t +#define __DEFINED_pthread_mutex_t +#define __DEFINED_pthread_mutexattr_t +#define __DEFINED_pthread_once_t +#define __DEFINED_pthread_rwlock_t +#define __DEFINED_pthread_rwlockattr_t +#define __DEFINED_pthread_spinlock_t +#define __DEFINED_pthread_t +#define __DEFINED_register_t +#define __DEFINED_regoff_t +#define __DEFINED_sa_family_t +#define __DEFINED_sigset_t +#define __DEFINED_size_t +#define __DEFINED_socklen_t +#define __DEFINED_ssize_t +#define __DEFINED_suseconds_t +#define __DEFINED_time_t +#define __DEFINED_timer_t +#define __DEFINED_u_int64_t +#define __DEFINED_uid_t +#define __DEFINED_uint16_t +#define __DEFINED_uint32_t +#define __DEFINED_uint64_t +#define __DEFINED_uint8_t +#define __DEFINED_uintmax_t +#define __DEFINED_uintptr_t +#define __DEFINED_useconds_t +#define __DEFINED_va_list +#define __DEFINED_wchar_t +#define __DEFINED_wctype_t +#define __DEFINED_wint_t +#define __FINITE_MATH_ONLY__ 0 +#define __FLOAT128__ 1 +#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) +#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) +#define __FLT_DECIMAL_DIG__ 9 +#define __FLT_DENORM_MIN__ 1.40129846e-45F +#define __FLT_DIG__ 6 +#define __FLT_EPSILON__ 1.19209290e-7F +#define __FLT_HAS_DENORM__ 1 +#define __FLT_HAS_INFINITY__ 1 +#define __FLT_HAS_QUIET_NAN__ 1 +#define __FLT_MANT_DIG__ 24 +#define __FLT_MAX_10_EXP__ 38 +#define __FLT_MAX_EXP__ 128 +#define __FLT_MAX__ 3.40282347e+38F +#define __FLT_MIN_10_EXP__ (-37) +#define __FLT_MIN_EXP__ (-125) +#define __FLT_MIN__ 1.17549435e-38F +#define __FLT_RADIX__ 2 +#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 +#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 +#define __compiler_ATOMIC_INT_LOCK_FREE 2 +#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 +#define __compiler_ATOMIC_LONG_LOCK_FREE 2 +#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 +#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 +#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 +#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 +#define __GNUC_STDC_INLINE__ 1 +#define __GNUC_VA_LIST 1 +#define __GXX_ABI_VERSION 1002 +#define __INT16_C_SUFFIX__ +#define __INT16_FMTd__ "hd" +#define __INT16_FMTi__ "hi" +#define __INT16_MAX__ 32767 +#define __INT16_TYPE__ short +#define __INT32_C_SUFFIX__ +#define __INT32_FMTd__ "d" +#define __INT32_FMTi__ "i" +#define __INT32_MAX__ 2147483647 +#define __INT32_TYPE__ int +#define __INT64_C_SUFFIX__ LL +#define __INT64_FMTd__ "lld" +#define __INT64_FMTi__ "lli" +#define __INT64_MAX__ 9223372036854775807LL +#define __INT64_TYPE__ long long int +#define __INT8_C_SUFFIX__ +#define __INT8_FMTd__ "hhd" +#define __INT8_FMTi__ "hhi" +#define __INT8_MAX__ 127 +#define __INT8_TYPE__ signed char +#define __INTMAX_C_SUFFIX__ LL +#define __INTMAX_FMTd__ "lld" +#define __INTMAX_FMTi__ "lli" +#define __INTMAX_MAX__ 9223372036854775807LL +#define __INTMAX_TYPE__ long long int +#define __INTMAX_WIDTH__ 64 +#define __INTPTR_FMTd__ "ld" +#define __INTPTR_FMTi__ "li" +#define __INTPTR_MAX__ 9223372036854775807L +#define __INTPTR_TYPE__ long int +#define __INTPTR_WIDTH__ 64 +#define __INT_FAST16_FMTd__ "hd" +#define __INT_FAST16_FMTi__ "hi" +#define __INT_FAST16_MAX__ 32767 +#define __INT_FAST16_TYPE__ short +#define __INT_FAST32_FMTd__ "d" +#define __INT_FAST32_FMTi__ "i" +#define __INT_FAST32_MAX__ 2147483647 +#define __INT_FAST32_TYPE__ int +#define __INT_FAST64_FMTd__ "lld" +#define __INT_FAST64_FMTi__ "lli" +#define __INT_FAST64_MAX__ 9223372036854775807LL +#define __INT_FAST64_TYPE__ long long int +#define __INT_FAST8_FMTd__ "hhd" +#define __INT_FAST8_FMTi__ "hhi" +#define __INT_FAST8_MAX__ 127 +#define __INT_FAST8_TYPE__ signed char +#define __INT_LEAST16_FMTd__ "hd" +#define __INT_LEAST16_FMTi__ "hi" +#define __INT_LEAST16_MAX__ 32767 +#define __INT_LEAST16_TYPE__ short +#define __INT_LEAST32_FMTd__ "d" +#define __INT_LEAST32_FMTi__ "i" +#define __INT_LEAST32_MAX__ 2147483647 +#define __INT_LEAST32_TYPE__ int +#define __INT_LEAST64_FMTd__ "lld" +#define __INT_LEAST64_FMTi__ "lli" +#define __INT_LEAST64_MAX__ 9223372036854775807LL +#define __INT_LEAST64_TYPE__ long long int +#define __INT_LEAST8_FMTd__ "hhd" +#define __INT_LEAST8_FMTi__ "hhi" +#define __INT_LEAST8_MAX__ 127 +#define __INT_LEAST8_TYPE__ signed char +#define __INT_MAX__ 2147483647 +#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) +#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) +#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) +#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) +#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) +#define __LDBL_DECIMAL_DIG__ 36 +#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L +#define __LDBL_DIG__ 33 +#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L +#define __LDBL_HAS_DENORM__ 1 +#define __LDBL_HAS_INFINITY__ 1 +#define __LDBL_HAS_QUIET_NAN__ 1 +#define __LDBL_MANT_DIG__ 113 +#define __LDBL_MAX_10_EXP__ 4932 +#define __LDBL_MAX_EXP__ 16384 +#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L +#define __LDBL_MIN_10_EXP__ (-4931) +#define __LDBL_MIN_EXP__ (-16381) +#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L +#define __LITTLE_ENDIAN 1234 +#define __LITTLE_ENDIAN__ 1 +#define __LONG_LONG_MAX__ 9223372036854775807LL +#define __LONG_MAX __LONG_MAX__ +#define __LONG_MAX__ 9223372036854775807L +#define __LP64__ 1 +#define __NAMESER 19991006 +#define __NEED_FILE +#define __NEED___isoc_va_list +#define __NEED_blkcnt_t +#define __NEED_blksize_t +#define __NEED_clock_t +#define __NEED_clockid_t +#define __NEED_cnd_t +#define __NEED_dev_t +#define __NEED_double_t +#define __NEED_float_t +#define __NEED_fsblkcnt_t +#define __NEED_fsfilcnt_t +#define __NEED_gid_t +#define __NEED_id_t +#define __NEED_ino_t +#define __NEED_int16_t +#define __NEED_int32_t +#define __NEED_int64_t +#define __NEED_int8_t +#define __NEED_intmax_t +#define __NEED_intptr_t +#define __NEED_key_t +#define __NEED_locale_t +#define __NEED_mbstate_t +#define __NEED_mode_t +#define __NEED_mtx_t +#define __NEED_nlink_t +#define __NEED_off_t +#define __NEED_pid_t +#define __NEED_pthread_attr_t +#define __NEED_pthread_barrier_t +#define __NEED_pthread_barrierattr_t +#define __NEED_pthread_cond_t +#define __NEED_pthread_condattr_t +#define __NEED_pthread_key_t +#define __NEED_pthread_mutex_t +#define __NEED_pthread_mutexattr_t +#define __NEED_pthread_once_t +#define __NEED_pthread_rwlock_t +#define __NEED_pthread_rwlockattr_t +#define __NEED_pthread_spinlock_t +#define __NEED_pthread_t +#define __NEED_register_t +#define __NEED_regoff_t +#define __NEED_sa_family_t +#define __NEED_sigset_t +#define __NEED_size_t +#define __NEED_socklen_t +#define __NEED_ssize_t +#define __NEED_struct_iovec +#define __NEED_struct_timespec +#define __NEED_struct_timeval +#define __NEED_suseconds_t +#define __NEED_time_t +#define __NEED_timer_t +#define __NEED_u_int64_t +#define __NEED_uid_t +#define __NEED_uint16_t +#define __NEED_uint32_t +#define __NEED_uint64_t +#define __NEED_uint8_t +#define __NEED_uintmax_t +#define __NEED_uintptr_t +#define __NEED_useconds_t +#define __NEED_va_list +#define __NEED_wchar_t +#define __NEED_wctype_t +#define __NEED_wint_t +#define __OBJC_BOOL_IS_BOOL 0 +#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 +#define __OPENCL_MEMORY_SCOPE_DEVICE 2 +#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 +#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 +#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 +#define __ORDER_BIG_ENDIAN__ 4321 +#define __ORDER_LITTLE_ENDIAN__ 1234 +#define __ORDER_PDP_ENDIAN__ 3412 +#define __PDP_ENDIAN 3412 +#define __POINTER_WIDTH__ 64 +#define __PRAGMA_REDEFINE_EXTNAME 1 +#define __PTRDIFF_FMTd__ "ld" +#define __PTRDIFF_FMTi__ "li" +#define __PTRDIFF_MAX__ 9223372036854775807L +#define __PTRDIFF_TYPE__ long int +#define __PTRDIFF_WIDTH__ 64 +#define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#define __RETCAST(x) +#define __RETCAST_2(x,y) +#define __RETCAST_3(x,y,z) +#define __RETCAST_CX(x) +#define __RETCAST_REAL(x) +#define __SCHAR_MAX__ 127 +#define __SHRT_MAX__ 32767 +#define __SID ('S' << 8) +#define __SIG_ATOMIC_MAX__ 9223372036854775807L +#define __SIG_ATOMIC_WIDTH__ 64 +#define __SIZEOF_DOUBLE__ 8 +#define __SIZEOF_FLOAT__ 4 +#define __SIZEOF_INT128__ 16 +#define __SIZEOF_INT__ 4 +#define __SIZEOF_LONG_DOUBLE__ 16 +#define __SIZEOF_LONG_LONG__ 8 +#define __SIZEOF_LONG__ 8 +#define __SIZEOF_POINTER__ 8 +#define __SIZEOF_PTRDIFF_T__ 8 +#define __SIZEOF_SHORT__ 2 +#define __SIZEOF_SIZE_T__ 8 +#define __SIZEOF_WCHAR_T__ 4 +#define __SIZEOF_WINT_T__ 4 +#define __SIZE_FMTX__ "lX" +#define __SIZE_FMTo__ "lo" +#define __SIZE_FMTu__ "lu" +#define __SIZE_FMTx__ "lx" +#define __SIZE_MAX__ 18446744073709551615UL +#define __SIZE_TYPE__ long unsigned int +#define __SIZE_WIDTH__ 64 +#define __STDARG_H +#define __STDC_HOSTED__ 1 +#define __STDC_IEC_559__ 1 +#define __STDC_ISO_10646__ 201206L +#define __STDC_UTF_16__ 1 +#define __STDC_UTF_32__ 1 +#define __STDC_VERSION__ 201710L +#define __STDC__ 1 +#define __STDDEF_H +#define __UAPI_DEF_IN6_ADDR 0 +#define __UAPI_DEF_IN6_ADDR_ALT 0 +#define __UAPI_DEF_IN6_PKTINFO 0 +#define __UAPI_DEF_IN_ADDR 0 +#define __UAPI_DEF_IN_CLASS 0 +#define __UAPI_DEF_IN_IPPROTO 0 +#define __UAPI_DEF_IN_PKTINFO 0 +#define __UAPI_DEF_IP6_MTUINFO 0 +#define __UAPI_DEF_IPHDR 0 +#define __UAPI_DEF_IPPROTO_V6 0 +#define __UAPI_DEF_IPV6_MREQ 0 +#define __UAPI_DEF_IPV6_OPTIONS 0 +#define __UAPI_DEF_IP_MREQ 0 +#define __UAPI_DEF_SOCKADDR_IN 0 +#define __UAPI_DEF_SOCKADDR_IN6 0 +#define __UINT16_C_SUFFIX__ +#define __UINT16_FMTX__ "hX" +#define __UINT16_FMTo__ "ho" +#define __UINT16_FMTu__ "hu" +#define __UINT16_FMTx__ "hx" +#define __UINT16_MAX__ 65535 +#define __UINT16_TYPE__ unsigned short +#define __UINT32_C_SUFFIX__ U +#define __UINT32_FMTX__ "X" +#define __UINT32_FMTo__ "o" +#define __UINT32_FMTu__ "u" +#define __UINT32_FMTx__ "x" +#define __UINT32_MAX__ 4294967295U +#define __UINT32_TYPE__ unsigned int +#define __UINT64_C_SUFFIX__ ULL +#define __UINT64_FMTX__ "llX" +#define __UINT64_FMTo__ "llo" +#define __UINT64_FMTu__ "llu" +#define __UINT64_FMTx__ "llx" +#define __UINT64_MAX__ 18446744073709551615ULL +#define __UINT64_TYPE__ long long unsigned int +#define __UINT8_C_SUFFIX__ +#define __UINT8_FMTX__ "hhX" +#define __UINT8_FMTo__ "hho" +#define __UINT8_FMTu__ "hhu" +#define __UINT8_FMTx__ "hhx" +#define __UINT8_MAX__ 255 +#define __UINT8_TYPE__ unsigned char +#define __UINTMAX_C_SUFFIX__ ULL +#define __UINTMAX_FMTX__ "llX" +#define __UINTMAX_FMTo__ "llo" +#define __UINTMAX_FMTu__ "llu" +#define __UINTMAX_FMTx__ "llx" +#define __UINTMAX_MAX__ 18446744073709551615ULL +#define __UINTMAX_TYPE__ long long unsigned int +#define __UINTMAX_WIDTH__ 64 +#define __UINTPTR_FMTX__ "lX" +#define __UINTPTR_FMTo__ "lo" +#define __UINTPTR_FMTu__ "lu" +#define __UINTPTR_FMTx__ "lx" +#define __UINTPTR_MAX__ 18446744073709551615UL +#define __UINTPTR_TYPE__ long unsigned int +#define __UINTPTR_WIDTH__ 64 +#define __UINT_FAST16_FMTX__ "hX" +#define __UINT_FAST16_FMTo__ "ho" +#define __UINT_FAST16_FMTu__ "hu" +#define __UINT_FAST16_FMTx__ "hx" +#define __UINT_FAST16_MAX__ 65535 +#define __UINT_FAST16_TYPE__ unsigned short +#define __UINT_FAST32_FMTX__ "X" +#define __UINT_FAST32_FMTo__ "o" +#define __UINT_FAST32_FMTu__ "u" +#define __UINT_FAST32_FMTx__ "x" +#define __UINT_FAST32_MAX__ 4294967295U +#define __UINT_FAST32_TYPE__ unsigned int +#define __UINT_FAST64_FMTX__ "llX" +#define __UINT_FAST64_FMTo__ "llo" +#define __UINT_FAST64_FMTu__ "llu" +#define __UINT_FAST64_FMTx__ "llx" +#define __UINT_FAST64_MAX__ 18446744073709551615ULL +#define __UINT_FAST64_TYPE__ long long unsigned int +#define __UINT_FAST8_FMTX__ "hhX" +#define __UINT_FAST8_FMTo__ "hho" +#define __UINT_FAST8_FMTu__ "hhu" +#define __UINT_FAST8_FMTx__ "hhx" +#define __UINT_FAST8_MAX__ 255 +#define __UINT_FAST8_TYPE__ unsigned char +#define __UINT_LEAST16_FMTX__ "hX" +#define __UINT_LEAST16_FMTo__ "ho" +#define __UINT_LEAST16_FMTu__ "hu" +#define __UINT_LEAST16_FMTx__ "hx" +#define __UINT_LEAST16_MAX__ 65535 +#define __UINT_LEAST16_TYPE__ unsigned short +#define __UINT_LEAST32_FMTX__ "X" +#define __UINT_LEAST32_FMTo__ "o" +#define __UINT_LEAST32_FMTu__ "u" +#define __UINT_LEAST32_FMTx__ "x" +#define __UINT_LEAST32_MAX__ 4294967295U +#define __UINT_LEAST32_TYPE__ unsigned int +#define __UINT_LEAST64_FMTX__ "llX" +#define __UINT_LEAST64_FMTo__ "llo" +#define __UINT_LEAST64_FMTu__ "llu" +#define __UINT_LEAST64_FMTx__ "llx" +#define __UINT_LEAST64_MAX__ 18446744073709551615ULL +#define __UINT_LEAST64_TYPE__ long long unsigned int +#define __UINT_LEAST8_FMTX__ "hhX" +#define __UINT_LEAST8_FMTo__ "hho" +#define __UINT_LEAST8_FMTu__ "hhu" +#define __UINT_LEAST8_FMTx__ "hhx" +#define __UINT_LEAST8_MAX__ 255 +#define __UINT_LEAST8_TYPE__ unsigned char +#define __USER_LABEL_PREFIX__ +#define __USE_TIME_BITS64 1 +#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) +#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) +#define __WASI_ADVICE_NORMAL (UINT8_C(0)) +#define __WASI_ADVICE_RANDOM (UINT8_C(2)) +#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) +#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) +#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) +#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) +#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) +#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) +#define __WASI_DIRCOOKIE_START (UINT64_C(0)) +#define __WASI_ERRNO_2BIG (UINT16_C(1)) +#define __WASI_ERRNO_ACCES (UINT16_C(2)) +#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) +#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) +#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) +#define __WASI_ERRNO_AGAIN (UINT16_C(6)) +#define __WASI_ERRNO_ALREADY (UINT16_C(7)) +#define __WASI_ERRNO_BADF (UINT16_C(8)) +#define __WASI_ERRNO_BADMSG (UINT16_C(9)) +#define __WASI_ERRNO_BUSY (UINT16_C(10)) +#define __WASI_ERRNO_CANCELED (UINT16_C(11)) +#define __WASI_ERRNO_CHILD (UINT16_C(12)) +#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) +#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) +#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) +#define __WASI_ERRNO_DEADLK (UINT16_C(16)) +#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) +#define __WASI_ERRNO_DOM (UINT16_C(18)) +#define __WASI_ERRNO_DQUOT (UINT16_C(19)) +#define __WASI_ERRNO_EXIST (UINT16_C(20)) +#define __WASI_ERRNO_FAULT (UINT16_C(21)) +#define __WASI_ERRNO_FBIG (UINT16_C(22)) +#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) +#define __WASI_ERRNO_IDRM (UINT16_C(24)) +#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) +#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) +#define __WASI_ERRNO_INTR (UINT16_C(27)) +#define __WASI_ERRNO_INVAL (UINT16_C(28)) +#define __WASI_ERRNO_IO (UINT16_C(29)) +#define __WASI_ERRNO_ISCONN (UINT16_C(30)) +#define __WASI_ERRNO_ISDIR (UINT16_C(31)) +#define __WASI_ERRNO_LOOP (UINT16_C(32)) +#define __WASI_ERRNO_MFILE (UINT16_C(33)) +#define __WASI_ERRNO_MLINK (UINT16_C(34)) +#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) +#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) +#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) +#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) +#define __WASI_ERRNO_NETRESET (UINT16_C(39)) +#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) +#define __WASI_ERRNO_NFILE (UINT16_C(41)) +#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) +#define __WASI_ERRNO_NODEV (UINT16_C(43)) +#define __WASI_ERRNO_NOENT (UINT16_C(44)) +#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) +#define __WASI_ERRNO_NOLCK (UINT16_C(46)) +#define __WASI_ERRNO_NOLINK (UINT16_C(47)) +#define __WASI_ERRNO_NOMEM (UINT16_C(48)) +#define __WASI_ERRNO_NOMSG (UINT16_C(49)) +#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) +#define __WASI_ERRNO_NOSPC (UINT16_C(51)) +#define __WASI_ERRNO_NOSYS (UINT16_C(52)) +#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) +#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) +#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) +#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) +#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) +#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) +#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) +#define __WASI_ERRNO_NOTTY (UINT16_C(59)) +#define __WASI_ERRNO_NXIO (UINT16_C(60)) +#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) +#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) +#define __WASI_ERRNO_PERM (UINT16_C(63)) +#define __WASI_ERRNO_PIPE (UINT16_C(64)) +#define __WASI_ERRNO_PROTO (UINT16_C(65)) +#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) +#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) +#define __WASI_ERRNO_RANGE (UINT16_C(68)) +#define __WASI_ERRNO_ROFS (UINT16_C(69)) +#define __WASI_ERRNO_SPIPE (UINT16_C(70)) +#define __WASI_ERRNO_SRCH (UINT16_C(71)) +#define __WASI_ERRNO_STALE (UINT16_C(72)) +#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) +#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) +#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) +#define __WASI_ERRNO_XDEV (UINT16_C(75)) +#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) +#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) +#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) +#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) +#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) +#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) +#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) +#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) +#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) +#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) +#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) +#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) +#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) +#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) +#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) +#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) +#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) +#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) +#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) +#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) +#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) +#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) +#define __WASI_NOEXCEPT +#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) +#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) +#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) +#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) +#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) +#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) +#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) +#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) +#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) +#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) +#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) +#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) +#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) +#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) +#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) +#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) +#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) +#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) +#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) +#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) +#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) +#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) +#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) +#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) +#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) +#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) +#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) +#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) +#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) +#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) +#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) +#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) +#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) +#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) +#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) +#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) +#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) +#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) +#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) +#define __WASI_WHENCE_CUR (UINT8_C(1)) +#define __WASI_WHENCE_END (UINT8_C(2)) +#define __WASI_WHENCE_SET (UINT8_C(0)) +#define __WCHAR_MAX__ 2147483647 +#define __WCHAR_TYPE__ int +#define __WCHAR_WIDTH__ 32 +#define __WINT_MAX__ 2147483647 +#define __WINT_TYPE__ int +#define __WINT_WIDTH__ 32 +#define __WORDSIZE 64 +#define __alignas_is_defined 1 +#define __alignof_is_defined 1 +#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) +#define __bool_true_false_are_defined 1 +#define __inline inline +#define __restrict restrict +#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) +#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) +#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) +#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) +#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) +#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) +#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) +#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) +#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) +#define __tm_gmtoff tm_gmtoff +#define __tm_zone tm_zone +#define __va_copy(d,s) __builtin_va_copy(d, s) +#define __wasi__ 1 +#define __wasi_api_h +#define __wasi_libc_environ_h +#define __wasi_libc_find_relpath_h +#define __wasi_libc_h +#define __wasi_libc_nocwd_h +#define __wasilibc___errno_h +#define __wasilibc___errno_values_h +#define __wasilibc___fd_set_h +#define __wasilibc___function___isatty_h +#define __wasilibc___functions_malloc_h +#define __wasilibc___functions_memcpy_h +#define __wasilibc___header_dirent_h +#define __wasilibc___header_fcntl_h +#define __wasilibc___header_netinet_in_h +#define __wasilibc___header_poll_h +#define __wasilibc___header_stdlib_h +#define __wasilibc___header_string_h +#define __wasilibc___header_sys_ioctl_h +#define __wasilibc___header_sys_resource_h +#define __wasilibc___header_sys_socket_h +#define __wasilibc___header_sys_stat_h +#define __wasilibc___header_time_h +#define __wasilibc___header_unistd_h +#define __wasilibc___include_inttypes_h +#define __wasilibc___macro_FD_SETSIZE_h +#define __wasilibc___macro_PAGESIZE_h +#define __wasilibc___mode_t_h +#define __wasilibc___seek_h +#define __wasilibc___struct_dirent_h +#define __wasilibc___struct_in6_addr_h +#define __wasilibc___struct_in_addr_h +#define __wasilibc___struct_iovec_h +#define __wasilibc___struct_msghdr_h +#define __wasilibc___struct_pollfd_h +#define __wasilibc___struct_rusage_h +#define __wasilibc___struct_sockaddr_h +#define __wasilibc___struct_sockaddr_in6_h +#define __wasilibc___struct_sockaddr_in_h +#define __wasilibc___struct_sockaddr_storage_h +#define __wasilibc___struct_sockaddr_un_h +#define __wasilibc___struct_stat_h +#define __wasilibc___struct_timespec_h +#define __wasilibc___struct_timeval_h +#define __wasilibc___struct_tm_h +#define __wasilibc___struct_tms_h +#define __wasilibc___typedef_DIR_h +#define __wasilibc___typedef_blkcnt_t_h +#define __wasilibc___typedef_blksize_t_h +#define __wasilibc___typedef_clock_t_h +#define __wasilibc___typedef_clockid_t_h +#define __wasilibc___typedef_dev_t_h +#define __wasilibc___typedef_fd_set_h +#define __wasilibc___typedef_gid_t_h +#define __wasilibc___typedef_in_addr_t_h +#define __wasilibc___typedef_in_port_t_h +#define __wasilibc___typedef_ino_t_h +#define __wasilibc___typedef_mode_t_h +#define __wasilibc___typedef_nfds_t_h +#define __wasilibc___typedef_nlink_t_h +#define __wasilibc___typedef_off_t_h +#define __wasilibc___typedef_sa_family_t_h +#define __wasilibc___typedef_sigset_t_h +#define __wasilibc___typedef_socklen_t_h +#define __wasilibc___typedef_ssize_t_h +#define __wasilibc___typedef_suseconds_t_h +#define __wasilibc___typedef_time_t_h +#define __wasilibc___typedef_uid_t_h +#define __wasm 1 +#define __wasm64 1 +#define __wasm64__ 1 +#define __wasm__ 1 +#define _tolower(a) ((a)|0x20) +#define _toupper(a) ((a)&0x5f) +#define acos(x) __tg_real_complex(acos, (x)) +#define acosh(x) __tg_real_complex(acosh, (x)) +#define alignas _Alignas +#define alignof _Alignof +#define alloca __builtin_alloca +#define alphasort64 alphasort +#define and && +#define and_eq &= +#define asin(x) __tg_real_complex(asin, (x)) +#define asinh(x) __tg_real_complex(asinh, (x)) +#define atan(x) __tg_real_complex(atan, (x)) +#define atan2(x,y) __tg_real_2(atan2, (x), (y)) +#define atanh(x) __tg_real_complex(atanh, (x)) +#define be16toh(x) __bswap16(x) +#define be32toh(x) __bswap32(x) +#define be64toh(x) __bswap64(x) +#define betoh16(x) __bswap16(x) +#define betoh32(x) __bswap32(x) +#define betoh64(x) __bswap64(x) +#define bitand & +#define bitor | +#define blkcnt64_t blkcnt_t +#define bool _Bool +#define bswap_16(x) __bswap_16(x) +#define bswap_32(x) __bswap_32(x) +#define bswap_64(x) __bswap_64(x) +#define carg(x) __tg_complex_retreal(carg, (x)) +#define cbrt(x) __tg_real(cbrt, (x)) +#define ceil(x) __tg_real(ceil, (x)) +#define cimag(x) __tg_complex_retreal(cimag, (x)) +#define cimagf(x) (__builtin_cimagf(x)) +#define cimagl(x) (__builtin_cimagl(x)) +#define clrbit(x,i) __bitop(x,i,&=~) +#define compl ~ +#define complex _Complex +#define conj(x) __tg_complex(conj, (x)) +#define copysign(x,y) __tg_real_2(copysign, (x), (y)) +#define cos(x) __tg_real_complex(cos, (x)) +#define cosh(x) __tg_real_complex(cosh, (x)) +#define cproj(x) __tg_complex(cproj, (x)) +#define creal(x) __tg_complex_retreal(creal, (x)) +#define crealf(x) (__builtin_crealf(x)) +#define creall(x) (__builtin_creall(x)) +#define creat64 creat +#define d_fileno d_ino +#define direct dirent +#define dirent64 dirent +#define erf(x) __tg_real(erf, (x)) +#define erfc(x) __tg_real(erfc, (x)) +#define errno errno +#define exp(x) __tg_real_complex(exp, (x)) +#define exp2(x) __tg_real(exp2, (x)) +#define expm1(x) __tg_real(expm1, (x)) +#define fabs(x) __tg_real_complex_fabs(x) +#define false 0 +#define fdim(x,y) __tg_real_2(fdim, (x), (y)) +#define fgetpos64 fgetpos +#define floor(x) __tg_real(floor, (x)) +#define fma(x,y,z) __tg_real_fma((x), (y), (z)) +#define fmax(x,y) __tg_real_2(fmax, (x), (y)) +#define fmin(x,y) __tg_real_2(fmin, (x), (y)) +#define fmod(x,y) __tg_real_2(fmod, (x), (y)) +#define fopen64 fopen +#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) +#define fpos64_t fpos_t +#define freopen64 freopen +#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) +#define fsblkcnt64_t fsblkcnt_t +#define fseeko64 fseeko +#define fsetpos64 fsetpos +#define fsfilcnt64_t fsfilcnt_t +#define fstat64 fstat +#define fstatat64 fstatat +#define ftello64 ftello +#define ftruncate64 ftruncate +#define getdents64 getdents +#define glob64 glob +#define glob64_t glob_t +#define globfree64 globfree +#define howmany(n,d) (((n)+((d)-1))/(d)) +#define htobe16(x) __bswap16(x) +#define htobe32(x) __bswap32(x) +#define htobe64(x) __bswap64(x) +#define htole16(x) (uint16_t)(x) +#define htole32(x) (uint32_t)(x) +#define htole64(x) (uint64_t)(x) +#define hypot(x,y) __tg_real_2(hypot, (x), (y)) +#define icmp6_data16 icmp6_dataun.icmp6_un_data16 +#define icmp6_data32 icmp6_dataun.icmp6_un_data32 +#define icmp6_data8 icmp6_dataun.icmp6_un_data8 +#define icmp6_id icmp6_data16[0] +#define icmp6_maxdelay icmp6_data16[0] +#define icmp6_mtu icmp6_data32[0] +#define icmp6_pptr icmp6_data32[0] +#define icmp6_seq icmp6_data16[1] +#define icmp_data icmp_dun.id_data +#define icmp_gwaddr icmp_hun.ih_gwaddr +#define icmp_id icmp_hun.ih_idseq.icd_id +#define icmp_ip icmp_dun.id_ip.idi_ip +#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime +#define icmp_mask icmp_dun.id_mask +#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu +#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs +#define icmp_otime icmp_dun.id_ts.its_otime +#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void +#define icmp_pptr icmp_hun.ih_pptr +#define icmp_radv icmp_dun.id_radv +#define icmp_rtime icmp_dun.id_ts.its_rtime +#define icmp_seq icmp_hun.ih_idseq.icd_seq +#define icmp_ttime icmp_dun.id_ts.its_ttime +#define icmp_void icmp_hun.ih_void +#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa +#define ifa_broadaddr ifa_ifu.ifu_broadaddr +#define ifa_dstaddr ifa_ifu.ifu_dstaddr +#define ilogb(x) __tg_real_nocast(ilogb, (x)) +#define ino64_t ino_t +#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow +#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim +#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt +#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen +#define ip6_vfc ip6_ctlun.ip6_un2_vfc +#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) +#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) +#define isclr(x,i) !isset(x,i) +#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) +#define isfinite(x) (__builtin_isfinite(x)) +#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) +#define isgreater(x,y) (__builtin_isgreater(x, y)) +#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) +#define isinf(x) (__builtin_isinf(x)) +#define isless(x,y) (__builtin_isless(x, y)) +#define islessequal(x,y) (__builtin_islessequal(x, y)) +#define islessgreater(x,y) (__builtin_islessgreater(x, y)) +#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) +#define isnan(x) (__builtin_isnan(x)) +#define isnormal(x) (__builtin_isnormal(x)) +#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) +#define isset(x,i) __bitop(x,i,&) +#define isspace(a) __isspace(a) +#define isunordered(x,y) (__builtin_isunordered(x, y)) +#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) +#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) +#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) +#define le16toh(x) (uint16_t)(x) +#define le32toh(x) (uint32_t)(x) +#define le64toh(x) (uint64_t)(x) +#define letoh16(x) (uint16_t)(x) +#define letoh32(x) (uint32_t)(x) +#define letoh64(x) (uint64_t)(x) +#define lgamma(x) __tg_real(lgamma, (x)) +#define llrint(x) __tg_real_nocast(llrint, (x)) +#define llround(x) __tg_real_nocast(llround, (x)) +#define loff_t off_t +#define log(x) __tg_real_complex(log, (x)) +#define log10(x) __tg_real(log10, (x)) +#define log1p(x) __tg_real(log1p, (x)) +#define log2(x) __tg_real(log2, (x)) +#define logb(x) __tg_real(logb, (x)) +#define lrint(x) __tg_real_nocast(lrint, (x)) +#define lround(x) __tg_real_nocast(lround, (x)) +#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) +#define lseek64 lseek +#define lstat64 lstat +#define math_errhandling 2 +#define mld_cksum mld_icmp6_hdr.icmp6_cksum +#define mld_code mld_icmp6_hdr.icmp6_code +#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] +#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] +#define mld_type mld_icmp6_hdr.icmp6_type +#define nd_na_cksum nd_na_hdr.icmp6_cksum +#define nd_na_code nd_na_hdr.icmp6_code +#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] +#define nd_na_type nd_na_hdr.icmp6_type +#define nd_ns_cksum nd_ns_hdr.icmp6_cksum +#define nd_ns_code nd_ns_hdr.icmp6_code +#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] +#define nd_ns_type nd_ns_hdr.icmp6_type +#define nd_ra_cksum nd_ra_hdr.icmp6_cksum +#define nd_ra_code nd_ra_hdr.icmp6_code +#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] +#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] +#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] +#define nd_ra_type nd_ra_hdr.icmp6_type +#define nd_rd_cksum nd_rd_hdr.icmp6_cksum +#define nd_rd_code nd_rd_hdr.icmp6_code +#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] +#define nd_rd_type nd_rd_hdr.icmp6_type +#define nd_rs_cksum nd_rs_hdr.icmp6_cksum +#define nd_rs_code nd_rs_hdr.icmp6_code +#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] +#define nd_rs_type nd_rs_hdr.icmp6_type +#define nearbyint(x) __tg_real(nearbyint, (x)) +#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) +#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) +#define nftw64 nftw +#define no_argument 0 +#define noreturn _Noreturn +#define not ! +#define not_eq != +#define ns_msg_base(handle) ((handle)._msg + 0) +#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) +#define ns_msg_end(handle) ((handle)._eom + 0) +#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) +#define ns_msg_id(handle) ((handle)._id + 0) +#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) +#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) +#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") +#define ns_rr_rdata(rr) ((rr).rdata + 0) +#define ns_rr_rdlen(rr) ((rr).rdlength + 0) +#define ns_rr_ttl(rr) ((rr).ttl + 0) +#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) +#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) +#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) +#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) +#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) +#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) +#define off64_t off_t +#define offsetof(t,d) __builtin_offsetof(t, d) +#define open64 open +#define openat64 openat +#define optional_argument 2 +#define or || +#define or_eq |= +#define posix_fadvise64 posix_fadvise +#define posix_fallocate64 posix_fallocate +#define pow(x,y) __tg_real_complex_pow((x), (y)) +#define powerof2(n) !(((n)-1) & (n)) +#define pread64 pread +#define preadv64 preadv +#define pwrite64 pwrite +#define pwritev64 pwritev +#define readdir64 readdir +#define remainder(x,y) __tg_real_2(remainder, (x), (y)) +#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) +#define required_argument 1 +#define rint(x) __tg_real(rint, (x)) +#define round(x) __tg_real(round, (x)) +#define roundup(n,d) (howmany(n,d)*(d)) +#define rr_cksum rr_hdr.icmp6_cksum +#define rr_code rr_hdr.icmp6_code +#define rr_seqnum rr_hdr.icmp6_data32[0] +#define rr_type rr_hdr.icmp6_type +#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) +#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) +#define scandir64 scandir +#define setbit(x,i) __bitop(x,i,|=) +#define signbit(x) (__builtin_signbit(x)) +#define sin(x) __tg_real_complex(sin, (x)) +#define sinh(x) __tg_real_complex(sinh, (x)) +#define sqrt(x) __tg_real_complex(sqrt, (x)) +#define st_atime st_atim.tv_sec +#define st_ctime st_ctim.tv_sec +#define st_mtime st_mtim.tv_sec +#define stat64 stat +#define static_assert _Static_assert +#define stderr (stderr) +#define stdin (stdin) +#define stdout (stdout) +#define strdupa(x) strcpy(alloca(strlen(x)+1),x) +#define tan(x) __tg_real_complex(tan, (x)) +#define tanh(x) __tg_real_complex(tanh, (x)) +#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) +#define tgamma(x) __tg_real(tgamma, (x)) +#define th_block th_u.tu_block +#define th_code th_u.tu_code +#define th_msg th_data +#define th_stuff th_u.tu_stuff +#define thrd_equal(A,B) ((A) == (B)) +#define thread_local _Thread_local +#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) +#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) +#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) +#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) +#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) +#define true 1 +#define trunc(x) __tg_real(trunc, (x)) +#define uh_dport dest +#define uh_sport source +#define uh_sum check +#define uh_ulen len +#define va_arg(ap,type) __builtin_va_arg(ap, type) +#define va_copy(dest,src) __builtin_va_copy(dest, src) +#define va_end(ap) __builtin_va_end(ap) +#define va_start(ap,param) __builtin_va_start(ap, param) +#define versionsort64 versionsort +#define xEOF 236 +#define xor ^ +#define xor_eq ^= diff --git a/expected/wasm64-wasip2/undefined-symbols.txt b/expected/wasm64-wasip2/undefined-symbols.txt new file mode 100644 index 000000000..e7c62031f --- /dev/null +++ b/expected/wasm64-wasip2/undefined-symbols.txt @@ -0,0 +1,69 @@ +__addtf3 +__divtf3 +__eqtf2 +__extenddftf2 +__extendsftf2 +__fixtfdi +__fixtfsi +__fixunstfsi +__floatditf +__floatsitf +__floatunsitf +__getf2 +__gttf2 +__heap_base +__heap_end +__imported_wasi_snapshot_preview1_args_get +__imported_wasi_snapshot_preview1_args_sizes_get +__imported_wasi_snapshot_preview1_clock_res_get +__imported_wasi_snapshot_preview1_clock_time_get +__imported_wasi_snapshot_preview1_environ_get +__imported_wasi_snapshot_preview1_environ_sizes_get +__imported_wasi_snapshot_preview1_fd_advise +__imported_wasi_snapshot_preview1_fd_allocate +__imported_wasi_snapshot_preview1_fd_close +__imported_wasi_snapshot_preview1_fd_datasync +__imported_wasi_snapshot_preview1_fd_fdstat_get +__imported_wasi_snapshot_preview1_fd_fdstat_set_flags +__imported_wasi_snapshot_preview1_fd_fdstat_set_rights +__imported_wasi_snapshot_preview1_fd_filestat_get +__imported_wasi_snapshot_preview1_fd_filestat_set_size +__imported_wasi_snapshot_preview1_fd_filestat_set_times +__imported_wasi_snapshot_preview1_fd_pread +__imported_wasi_snapshot_preview1_fd_prestat_dir_name +__imported_wasi_snapshot_preview1_fd_prestat_get +__imported_wasi_snapshot_preview1_fd_pwrite +__imported_wasi_snapshot_preview1_fd_read +__imported_wasi_snapshot_preview1_fd_readdir +__imported_wasi_snapshot_preview1_fd_renumber +__imported_wasi_snapshot_preview1_fd_seek +__imported_wasi_snapshot_preview1_fd_sync +__imported_wasi_snapshot_preview1_fd_tell +__imported_wasi_snapshot_preview1_fd_write +__imported_wasi_snapshot_preview1_path_create_directory +__imported_wasi_snapshot_preview1_path_filestat_get +__imported_wasi_snapshot_preview1_path_filestat_set_times +__imported_wasi_snapshot_preview1_path_link +__imported_wasi_snapshot_preview1_path_open +__imported_wasi_snapshot_preview1_path_readlink +__imported_wasi_snapshot_preview1_path_remove_directory +__imported_wasi_snapshot_preview1_path_rename +__imported_wasi_snapshot_preview1_path_symlink +__imported_wasi_snapshot_preview1_path_unlink_file +__imported_wasi_snapshot_preview1_poll_oneoff +__imported_wasi_snapshot_preview1_proc_exit +__imported_wasi_snapshot_preview1_random_get +__imported_wasi_snapshot_preview1_sched_yield +__imported_wasi_snapshot_preview1_sock_accept +__imported_wasi_snapshot_preview1_sock_recv +__imported_wasi_snapshot_preview1_sock_send +__imported_wasi_snapshot_preview1_sock_shutdown +__letf2 +__lttf2 +__netf2 +__stack_pointer +__subtf3 +__trunctfdf2 +__trunctfsf2 +__unordtf2 +__wasm_call_ctors From 34e198524fa9dd973b8ae295456192fea295ed9f Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 16 Mar 2024 22:05:24 -0400 Subject: [PATCH 33/43] fix stdint.h on 64 bit wasm --- libc-top-half/musl/arch/wasm/bits/stdint.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/libc-top-half/musl/arch/wasm/bits/stdint.h b/libc-top-half/musl/arch/wasm/bits/stdint.h index 6e7c7705b..8f4ff30cd 100644 --- a/libc-top-half/musl/arch/wasm/bits/stdint.h +++ b/libc-top-half/musl/arch/wasm/bits/stdint.h @@ -12,9 +12,18 @@ typedef uint32_t uint_fast32_t; #define UINT_FAST16_MAX UINT16_MAX #define UINT_FAST32_MAX UINT32_MAX +#ifdef __wasm64__ +#define INTPTR_MIN INT64_MIN +#define INTPTR_MAX INT64_MAX +#define UINTPTR_MAX UINT64_MAX +#define PTRDIFF_MIN INT64_MIN +#define PTRDIFF_MAX INT64_MAX +#define SIZE_MAX UINT64_MAX +#else #define INTPTR_MIN INT32_MIN #define INTPTR_MAX INT32_MAX #define UINTPTR_MAX UINT32_MAX #define PTRDIFF_MIN INT32_MIN #define PTRDIFF_MAX INT32_MAX #define SIZE_MAX UINT32_MAX +#endif From ce67b68286cdf2981bde258d0736c4f3935e0c81 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 16 Mar 2024 22:24:30 -0400 Subject: [PATCH 34/43] Fix makefile for new the p2 update --- Makefile | 42 ++++++------------- .../wasm64-wasip1-threads/defined-symbols.txt | 2 + expected/wasm64-wasip1-threads/include-all.c | 1 + .../predefined-macros.txt | 20 ++++----- .../defined-symbols.txt | 6 +++ .../include-all.c | 2 + .../predefined-macros.txt | 38 ++++++++++++----- .../undefined-symbols.txt | 0 8 files changed, 61 insertions(+), 50 deletions(-) rename expected/{wasm64-wasi-preview2 => wasm64-wasip1}/defined-symbols.txt (99%) rename expected/{wasm64-wasi-preview2 => wasm64-wasip1}/include-all.c (98%) rename expected/{wasm64-wasi-preview2 => wasm64-wasip1}/predefined-macros.txt (99%) rename expected/{wasm64-wasi-preview2 => wasm64-wasip1}/undefined-symbols.txt (100%) diff --git a/Makefile b/Makefile index f1b729e0d..26f61cd22 100644 --- a/Makefile +++ b/Makefile @@ -43,31 +43,26 @@ BULK_MEMORY_THRESHOLD ?= 32 # Variables from this point on are not meant to be overridable via the # make command-line. -# Set the default WASI target triple. -ifeq (${WASM64}, yes) -TARGET_TRIPLE = wasm64-wasi -else -TARGET_TRIPLE = wasm32-wasi -endif - # Threaded version necessitates a different target, as objects from different # targets can't be mixed together while linking. + + + ifeq ($(THREAD_MODEL), posix) - ifeq (${WASM64}, yes) - TARGET_TRIPLE = wasm64-wasi-threads - else - TARGET_TRIPLE = wasm32-wasi-threads - endif +THREADS_SUFFIX=-threads +else +THREADS_SUFFIX= endif -ifeq ($(WASI_SNAPSHOT), p2) - ifeq (${WASM64}, yes) - TARGET_TRIPLE = wasm64-wasip2 - else - TARGET_TRIPLE = wasm32-wasip2 - endif +ifeq ($(WASM64), yes) +WASM_SUFFIX=64 +else +WASM_SUFFIX=32 endif +TARGET_TRIPLE = wasm${WASM_SUFFIX}-wasi$(WASI_SNAPSHOT)${THREADS_SUFFIX} +EXPECTED_TARGET_DIR = expected/${TARGET_TRIPLE} + BUILTINS_LIB ?= $(shell ${CC} --print-libgcc-file-name) # These variables describe the locations of various files and directories in @@ -780,17 +775,6 @@ endif DEFINED_SYMBOLS = $(SYSROOT_SHARE)/defined-symbols.txt UNDEFINED_SYMBOLS = $(SYSROOT_SHARE)/undefined-symbols.txt -ifeq ($(WASI_SNAPSHOT),p2) -EXPECTED_TARGET_DIR = expected/wasm32-wasip2 -else -ifeq ($(THREAD_MODEL),posix) -EXPECTED_TARGET_DIR = expected/wasm32-wasip1-threads -else -EXPECTED_TARGET_DIR = expected/wasm32-wasip1 -endif -endif - - check-symbols: startup_files libc # # Collect metadata on the sysroot and perform sanity checks. diff --git a/expected/wasm64-wasip1-threads/defined-symbols.txt b/expected/wasm64-wasip1-threads/defined-symbols.txt index c434bf8a3..f3fc6d4a7 100644 --- a/expected/wasm64-wasip1-threads/defined-symbols.txt +++ b/expected/wasm64-wasip1-threads/defined-symbols.txt @@ -1010,6 +1010,7 @@ pthread_condattr_setpshared pthread_create pthread_detach pthread_equal +pthread_getattr_np pthread_getspecific pthread_join pthread_key_create @@ -1084,6 +1085,7 @@ readlinkat readv realloc reallocarray +realpath recv regcomp regerror diff --git a/expected/wasm64-wasip1-threads/include-all.c b/expected/wasm64-wasip1-threads/include-all.c index d9536e09f..507337430 100644 --- a/expected/wasm64-wasip1-threads/include-all.c +++ b/expected/wasm64-wasip1-threads/include-all.c @@ -60,6 +60,7 @@ #include <__typedef_suseconds_t.h> #include <__typedef_time_t.h> #include <__typedef_uid_t.h> +#include <__wasi_snapshot.h> #include #include #include diff --git a/expected/wasm64-wasip1-threads/predefined-macros.txt b/expected/wasm64-wasip1-threads/predefined-macros.txt index ee5db9cac..64e6fa7f1 100644 --- a/expected/wasm64-wasip1-threads/predefined-macros.txt +++ b/expected/wasm64-wasip1-threads/predefined-macros.txt @@ -610,7 +610,7 @@ #define INT32_C(c) c #define INT32_MAX (0x7fffffff) #define INT32_MIN (-1-0x7fffffff) -#define INT64_C(c) c ## LL +#define INT64_C(c) c ## L #define INT64_MAX (0x7fffffffffffffff) #define INT64_MIN (-1-0x7fffffffffffffff) #define INT8SZ NS_INT8SZ @@ -618,11 +618,11 @@ #define INT8_MAX (0x7f) #define INT8_MIN (-1-0x7f) #define INTBITS (sizeof(int) * 8) -#define INTMAX_C(c) c ## LL +#define INTMAX_C(c) c ## L #define INTMAX_MAX INT64_MAX #define INTMAX_MIN INT64_MIN -#define INTPTR_MAX INT32_MAX -#define INTPTR_MIN INT32_MIN +#define INTPTR_MAX INT64_MAX +#define INTPTR_MIN INT64_MIN #define INT_FAST16_MAX INT16_MAX #define INT_FAST16_MIN INT16_MIN #define INT_FAST32_MAX INT32_MAX @@ -1452,8 +1452,8 @@ #define PTHREAD_SCOPE_SYSTEM 0 #define PTHREAD_STACK_MIN 2048 #define PTRBITS (sizeof(char *) * 8) -#define PTRDIFF_MAX INT32_MAX -#define PTRDIFF_MIN INT32_MIN +#define PTRDIFF_MAX INT64_MAX +#define PTRDIFF_MIN INT64_MIN #define PUTLONG NS_PUT32 #define PUTSHORT NS_PUT16 #define QFIXEDSZ NS_QFIXEDSZ @@ -1602,7 +1602,7 @@ #define SHUT_WR __WASI_SDFLAGS_WR #define SIG_ATOMIC_MAX INT32_MAX #define SIG_ATOMIC_MIN INT32_MIN -#define SIZE_MAX UINT32_MAX +#define SIZE_MAX UINT64_MAX #define SI_LOAD_SHIFT 16 #define SLC_ABORT 7 #define SLC_ACK 0x80 @@ -1972,13 +1972,13 @@ #define UINT16_MAX (0xffff) #define UINT32_C(c) c ## U #define UINT32_MAX (0xffffffffu) -#define UINT64_C(c) c ## ULL +#define UINT64_C(c) c ## UL #define UINT64_MAX (0xffffffffffffffffu) #define UINT8_C(c) c #define UINT8_MAX (0xff) -#define UINTMAX_C(c) c ## ULL +#define UINTMAX_C(c) c ## UL #define UINTMAX_MAX UINT64_MAX -#define UINTPTR_MAX UINT32_MAX +#define UINTPTR_MAX UINT64_MAX #define UINT_FAST16_MAX UINT16_MAX #define UINT_FAST32_MAX UINT32_MAX #define UINT_FAST64_MAX UINT64_MAX diff --git a/expected/wasm64-wasi-preview2/defined-symbols.txt b/expected/wasm64-wasip1/defined-symbols.txt similarity index 99% rename from expected/wasm64-wasi-preview2/defined-symbols.txt rename to expected/wasm64-wasip1/defined-symbols.txt index 6e743228b..13c10d7b5 100644 --- a/expected/wasm64-wasi-preview2/defined-symbols.txt +++ b/expected/wasm64-wasip1/defined-symbols.txt @@ -447,6 +447,7 @@ cexp cexpf cexpl chdir +chmod cimag cimagf cimagl @@ -543,6 +544,8 @@ fabs fabsf fabsl faccessat +fchmod +fchmodat fclose fcntl fcvt @@ -637,6 +640,7 @@ fsetpos fsetpos64 fstat fstatat +fstatvfs fsync ftell ftello @@ -937,6 +941,7 @@ readlinkat readv realloc reallocarray +realpath recv regcomp regerror @@ -1012,6 +1017,7 @@ srand48 srandom sscanf stat +statvfs stderr stdin stdout diff --git a/expected/wasm64-wasi-preview2/include-all.c b/expected/wasm64-wasip1/include-all.c similarity index 98% rename from expected/wasm64-wasi-preview2/include-all.c rename to expected/wasm64-wasip1/include-all.c index 297e48b14..cd3b81720 100644 --- a/expected/wasm64-wasi-preview2/include-all.c +++ b/expected/wasm64-wasip1/include-all.c @@ -60,6 +60,7 @@ #include <__typedef_suseconds_t.h> #include <__typedef_time_t.h> #include <__typedef_uid_t.h> +#include <__wasi_snapshot.h> #include #include #include @@ -141,6 +142,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasi-preview2/predefined-macros.txt b/expected/wasm64-wasip1/predefined-macros.txt similarity index 99% rename from expected/wasm64-wasi-preview2/predefined-macros.txt rename to expected/wasm64-wasip1/predefined-macros.txt index dec1ead06..901aa0c9b 100644 --- a/expected/wasm64-wasi-preview2/predefined-macros.txt +++ b/expected/wasm64-wasip1/predefined-macros.txt @@ -181,6 +181,7 @@ #define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM #define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK #define DT_REG __WASI_FILETYPE_REGULAR_FILE +#define DT_SOCK 20 #define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN #define D_FMT 0x20029 #define D_T_FMT 0x20028 @@ -609,7 +610,7 @@ #define INT32_C(c) c #define INT32_MAX (0x7fffffff) #define INT32_MIN (-1-0x7fffffff) -#define INT64_C(c) c ## LL +#define INT64_C(c) c ## L #define INT64_MAX (0x7fffffffffffffff) #define INT64_MIN (-1-0x7fffffffffffffff) #define INT8SZ NS_INT8SZ @@ -617,11 +618,11 @@ #define INT8_MAX (0x7f) #define INT8_MIN (-1-0x7f) #define INTBITS (sizeof(int) * 8) -#define INTMAX_C(c) c ## LL +#define INTMAX_C(c) c ## L #define INTMAX_MAX INT64_MAX #define INTMAX_MIN INT64_MIN -#define INTPTR_MAX INT32_MAX -#define INTPTR_MIN INT32_MIN +#define INTPTR_MAX INT64_MAX +#define INTPTR_MIN INT64_MIN #define INT_FAST16_MAX INT16_MAX #define INT_FAST16_MIN INT16_MIN #define INT_FAST32_MAX INT32_MAX @@ -1419,8 +1420,8 @@ #define PRIxMAX __UINTMAX_FMTx__ #define PRIxPTR __UINTPTR_FMTx__ #define PTRBITS (sizeof(char *) * 8) -#define PTRDIFF_MAX INT32_MAX -#define PTRDIFF_MIN INT32_MIN +#define PTRDIFF_MAX INT64_MAX +#define PTRDIFF_MIN INT64_MIN #define PUTLONG NS_PUT32 #define PUTSHORT NS_PUT16 #define QFIXEDSZ NS_QFIXEDSZ @@ -1567,7 +1568,7 @@ #define SHUT_WR __WASI_SDFLAGS_WR #define SIG_ATOMIC_MAX INT32_MAX #define SIG_ATOMIC_MIN INT32_MIN -#define SIZE_MAX UINT32_MAX +#define SIZE_MAX UINT64_MAX #define SI_LOAD_SHIFT 16 #define SLC_ABORT 7 #define SLC_ACK 0x80 @@ -1637,6 +1638,18 @@ #define STRU_F 1 #define STRU_P 3 #define STRU_R 2 +#define ST_APPEND 256 +#define ST_IMMUTABLE 512 +#define ST_MANDLOCK 64 +#define ST_NOATIME 1024 +#define ST_NODEV 4 +#define ST_NODIRATIME 2048 +#define ST_NOEXEC 8 +#define ST_NOSUID 2 +#define ST_RDONLY 1 +#define ST_RELATIME 4096 +#define ST_SYNCHRONOUS 16 +#define ST_WRITE 128 #define SUN_LEN(s) (2+strlen((s)->sun_path)) #define SUSP 237 #define SYMLOOP_MAX 40 @@ -1651,7 +1664,7 @@ #define S_IFBLK (0x6000) #define S_IFCHR (0x2000) #define S_IFDIR (0x4000) -#define S_IFIFO (0xc000) +#define S_IFIFO (0x1000) #define S_IFLNK (0xa000) #define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) #define S_IFREG (0x8000) @@ -1925,13 +1938,13 @@ #define UINT16_MAX (0xffff) #define UINT32_C(c) c ## U #define UINT32_MAX (0xffffffffu) -#define UINT64_C(c) c ## ULL +#define UINT64_C(c) c ## UL #define UINT64_MAX (0xffffffffffffffffu) #define UINT8_C(c) c #define UINT8_MAX (0xff) -#define UINTMAX_C(c) c ## ULL +#define UINTMAX_C(c) c ## UL #define UINTMAX_MAX UINT64_MAX -#define UINTPTR_MAX UINT32_MAX +#define UINTPTR_MAX UINT64_MAX #define UINT_FAST16_MAX UINT16_MAX #define UINT_FAST32_MAX UINT32_MAX #define UINT_FAST64_MAX UINT64_MAX @@ -2323,6 +2336,7 @@ #define _SYS_REG_H #define _SYS_SELECT_H #define _SYS_SOCKET_H +#define _SYS_STATVFS_H #define _SYS_STAT_H #define _SYS_SYSCALL_H #define _SYS_SYSINFO_H @@ -3147,6 +3161,7 @@ #define fsfilcnt64_t fsfilcnt_t #define fstat64 fstat #define fstatat64 fstatat +#define fstatvfs64 fstatvfs #define ftello64 ftello #define ftruncate64 ftruncate #define getdents64 getdents @@ -3330,6 +3345,7 @@ #define st_mtime st_mtim.tv_sec #define stat64 stat #define static_assert _Static_assert +#define statvfs64 statvfs #define stderr (stderr) #define stdin (stdin) #define stdout (stdout) diff --git a/expected/wasm64-wasi-preview2/undefined-symbols.txt b/expected/wasm64-wasip1/undefined-symbols.txt similarity index 100% rename from expected/wasm64-wasi-preview2/undefined-symbols.txt rename to expected/wasm64-wasip1/undefined-symbols.txt From 3c387fa4c50f0b0a9cbbb937f75102323c872755 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 16 Mar 2024 22:28:15 -0400 Subject: [PATCH 35/43] Remove old preview triple --- .../wasm64-wasi-threads/defined-symbols.txt | 1366 ------- expected/wasm64-wasi-threads/include-all.c | 173 - .../wasm64-wasi-threads/predefined-macros.txt | 3423 ----------------- .../wasm64-wasi-threads/undefined-symbols.txt | 76 - expected/wasm64-wasi/defined-symbols.txt | 1211 ------ expected/wasm64-wasi/include-all.c | 172 - expected/wasm64-wasi/predefined-macros.txt | 3381 ---------------- expected/wasm64-wasi/undefined-symbols.txt | 69 - 8 files changed, 9871 deletions(-) delete mode 100644 expected/wasm64-wasi-threads/defined-symbols.txt delete mode 100644 expected/wasm64-wasi-threads/include-all.c delete mode 100644 expected/wasm64-wasi-threads/predefined-macros.txt delete mode 100644 expected/wasm64-wasi-threads/undefined-symbols.txt delete mode 100644 expected/wasm64-wasi/defined-symbols.txt delete mode 100644 expected/wasm64-wasi/include-all.c delete mode 100644 expected/wasm64-wasi/predefined-macros.txt delete mode 100644 expected/wasm64-wasi/undefined-symbols.txt diff --git a/expected/wasm64-wasi-threads/defined-symbols.txt b/expected/wasm64-wasi-threads/defined-symbols.txt deleted file mode 100644 index c434bf8a3..000000000 --- a/expected/wasm64-wasi-threads/defined-symbols.txt +++ /dev/null @@ -1,1366 +0,0 @@ -_CLOCK_MONOTONIC -_CLOCK_REALTIME -_Exit -_IO_feof_unlocked -_IO_ferror_unlocked -_IO_getc -_IO_getc_unlocked -_IO_putc -_IO_putc_unlocked -__EINVAL -__ENOMEM -__SIG_ERR -__SIG_IGN -__acquire_ptc -__aio_close -__asctime_r -__assert_fail -__at_quick_exit_lockptr -__atexit_lockptr -__c_dot_utf8 -__c_dot_utf8_locale -__c_locale -__clock -__clock_gettime -__clock_nanosleep -__copy_tls -__cos -__cosdf -__cosl -__crypt_blowfish -__crypt_des -__crypt_md5 -__crypt_r -__crypt_sha256 -__crypt_sha512 -__ctype_b_loc -__ctype_get_mb_cur_max -__ctype_tolower_loc -__ctype_toupper_loc -__cxa_atexit -__cxa_finalize -__default_guardsize -__default_stacksize -__des_setkey -__do_cleanup_pop -__do_cleanup_push -__do_des -__do_orphaned_stdio_locks -__dummy_reference -__duplocale -__env_rm_add -__errno_location -__exp2f_data -__exp_data -__expo2 -__expo2f -__fbufsize -__fclose_ca -__fdopen -__fesetround -__fgetwc_unlocked -__flbf -__floatscan -__fmodeflags -__fopen_rb_ca -__fpending -__fpurge -__fputwc_unlocked -__freadable -__freadahead -__freading -__freadptr -__freadptrinc -__freelocale -__fseeko -__fseeko_unlocked -__fseterr -__fsetlocking -__fsmu8 -__ftello -__ftello_unlocked -__funcs_on_exit -__funcs_on_quick_exit -__futimesat -__fwritable -__fwritex -__fwriting -__get_locale -__getdelim -__getentropy -__getopt_msg -__gmtime_r -__hwcap -__inet_aton -__init_ssp -__init_tp -__intscan -__invtrigl_R -__isalnum_l -__isalpha_l -__isatty -__isblank_l -__iscntrl_l -__isdigit_l -__isgraph_l -__islower_l -__isoc99_fscanf -__isoc99_fwscanf -__isoc99_scanf -__isoc99_sscanf -__isoc99_swscanf -__isoc99_vfscanf -__isoc99_vfwscanf -__isoc99_vscanf -__isoc99_vsscanf -__isoc99_vswscanf -__isoc99_vwscanf -__isoc99_wscanf -__isprint_l -__ispunct_l -__isspace_l -__isupper_l -__iswalnum_l -__iswalpha_l -__iswblank_l -__iswcntrl_l -__iswctype_l -__iswdigit_l -__iswgraph_l -__iswlower_l -__iswprint_l -__iswpunct_l -__iswspace_l -__iswupper_l -__iswxdigit_l -__isxdigit_l -__lctrans -__lctrans_cur -__lctrans_impl -__ldexp_cexp -__ldexp_cexpf -__lgamma_r -__lgammaf_r -__lgammal_r -__libc -__libc_calloc -__libc_free -__libc_malloc -__loc_is_allocated -__locale_lock -__locale_lockptr -__localtime_r -__lock -__lockfile -__log2_data -__log2f_data -__log_data -__logf_data -__lseek -__main_void -__math_divzero -__math_divzerof -__math_invalid -__math_invalidf -__math_invalidl -__math_oflow -__math_oflowf -__math_uflow -__math_uflowf -__math_xflow -__math_xflowf -__memrchr -__mo_lookup -__month_to_secs -__newlocale -__nl_langinfo -__nl_langinfo_l -__ofl_add -__ofl_lock -__ofl_unlock -__optpos -__optreset -__overflow -__p1evll -__pio2_hi -__pio2_lo -__pleval -__polevll -__posix_getopt -__pow_log_data -__powf_log2_data -__private_cond_signal -__progname -__progname_full -__pthread_cond_timedwait -__pthread_create -__pthread_join -__pthread_key_create -__pthread_key_delete -__pthread_mutex_lock -__pthread_mutex_timedlock -__pthread_mutex_trylock -__pthread_mutex_trylock_owner -__pthread_mutex_unlock -__pthread_once -__pthread_once_full -__pthread_rwlock_rdlock -__pthread_rwlock_timedrdlock -__pthread_rwlock_timedwrlock -__pthread_rwlock_tryrdlock -__pthread_rwlock_trywrlock -__pthread_rwlock_unlock -__pthread_rwlock_wrlock -__pthread_setcancelstate -__pthread_testcancel -__pthread_tsd_main -__pthread_tsd_run_dtors -__pthread_tsd_size -__putenv -__qsort_r -__rand48_step -__random_lockptr -__reallocarray -__register_locked_file -__release_ptc -__rem_pio2 -__rem_pio2_large -__rem_pio2f -__rem_pio2l -__rsqrt_tab -__secs_to_tm -__secs_to_zone -__seed48 -__shgetc -__shlim -__signgam -__sin -__sindf -__sinl -__small_printf -__stack_chk_fail -__stack_chk_fail_local -__stack_chk_guard -__stderr_FILE -__stderr_used -__stdin_FILE -__stdin_used -__stdio_close -__stdio_exit -__stdio_exit_needed -__stdio_ofl_lockptr -__stdio_read -__stdio_seek -__stdio_write -__stdout_FILE -__stdout_used -__stdout_write -__stpcpy -__stpncpy -__strcasecmp_l -__strchrnul -__strcoll_l -__strerror_l -__strftime_fmt_1 -__strftime_l -__strncasecmp_l -__strtod_l -__strtof_l -__strtoimax_internal -__strtol_internal -__strtold_l -__strtoll_internal -__strtoul_internal -__strtoull_internal -__strtoumax_internal -__strxfrm_l -__sysinfo -__sysv_signal -__tan -__tandf -__tanl -__testcancel -__thread_list_lock -__timedwait -__timedwait_cp -__tl_lock -__tl_sync -__tl_unlock -__tm_to_secs -__tm_to_tzname -__tolower_l -__toread -__toread_needs_stdio_exit -__toupper_l -__towctrans_l -__towlower_l -__towrite -__towrite_needs_stdio_exit -__towupper_l -__tre_mem_alloc_impl -__tre_mem_destroy -__tre_mem_new_impl -__tsearch_balance -__uflow -__unlist_locked_file -__unlock -__unlockfile -__uselocale -__utc -__wait -__wasi_args_get -__wasi_args_sizes_get -__wasi_clock_res_get -__wasi_clock_time_get -__wasi_environ_get -__wasi_environ_sizes_get -__wasi_fd_advise -__wasi_fd_allocate -__wasi_fd_close -__wasi_fd_datasync -__wasi_fd_fdstat_get -__wasi_fd_fdstat_set_flags -__wasi_fd_fdstat_set_rights -__wasi_fd_filestat_get -__wasi_fd_filestat_set_size -__wasi_fd_filestat_set_times -__wasi_fd_pread -__wasi_fd_prestat_dir_name -__wasi_fd_prestat_get -__wasi_fd_pwrite -__wasi_fd_read -__wasi_fd_readdir -__wasi_fd_renumber -__wasi_fd_seek -__wasi_fd_sync -__wasi_fd_tell -__wasi_fd_write -__wasi_init_tp -__wasi_path_create_directory -__wasi_path_filestat_get -__wasi_path_filestat_set_times -__wasi_path_link -__wasi_path_open -__wasi_path_readlink -__wasi_path_remove_directory -__wasi_path_rename -__wasi_path_symlink -__wasi_path_unlink_file -__wasi_poll_oneoff -__wasi_proc_exit -__wasi_random_get -__wasi_sched_yield -__wasi_sock_accept -__wasi_sock_recv -__wasi_sock_send -__wasi_sock_shutdown -__wasi_thread_spawn -__wasi_thread_start_C -__wasilibc_access -__wasilibc_cwd -__wasilibc_cwd_lock -__wasilibc_cwd_unlock -__wasilibc_deinitialize_environ -__wasilibc_dttoif -__wasilibc_ensure_environ -__wasilibc_environ -__wasilibc_fd_renumber -__wasilibc_find_abspath -__wasilibc_find_relpath -__wasilibc_find_relpath_alloc -__wasilibc_futex_wait -__wasilibc_get_environ -__wasilibc_iftodt -__wasilibc_initialize_environ -__wasilibc_link -__wasilibc_link_newat -__wasilibc_link_oldat -__wasilibc_maybe_reinitialize_environ_eagerly -__wasilibc_nocwd___wasilibc_rmdirat -__wasilibc_nocwd___wasilibc_unlinkat -__wasilibc_nocwd_faccessat -__wasilibc_nocwd_fstatat -__wasilibc_nocwd_linkat -__wasilibc_nocwd_mkdirat_nomode -__wasilibc_nocwd_openat_nomode -__wasilibc_nocwd_opendirat -__wasilibc_nocwd_readlinkat -__wasilibc_nocwd_renameat -__wasilibc_nocwd_scandirat -__wasilibc_nocwd_symlinkat -__wasilibc_nocwd_utimensat -__wasilibc_open_nomode -__wasilibc_populate_preopens -__wasilibc_pthread_self -__wasilibc_register_preopened_fd -__wasilibc_rename_newat -__wasilibc_rename_oldat -__wasilibc_rmdirat -__wasilibc_stat -__wasilibc_tell -__wasilibc_unlinkat -__wasilibc_utimens -__wasm_call_dtors -__wcscoll_l -__wcsftime_l -__wcsxfrm_l -__wctrans_l -__wctype_l -__xpg_basename -__xpg_strerror_r -__year_to_secs -_environ -_exit -_flushlbf -_initialize -_pthread_cleanup_pop -_pthread_cleanup_push -_start -a64l -abort -abs -accept -accept4 -access -acos -acosf -acosh -acoshf -acoshl -acosl -aligned_alloc -alphasort -alphasort64 -arc4random -arc4random_buf -arc4random_uniform -asctime -asctime_r -asin -asinf -asinh -asinhf -asinhl -asinl -asprintf -at_quick_exit -atan -atan2 -atan2f -atan2l -atanf -atanh -atanhf -atanhl -atanl -atexit -atof -atoi -atol -atoll -basename -bcmp -bcopy -bsd_signal -bsearch -btowc -bzero -c16rtomb -c32rtomb -cabs -cabsf -cabsl -cacos -cacosf -cacosh -cacoshf -cacoshl -cacosl -calloc -carg -cargf -cargl -casin -casinf -casinh -casinhf -casinhl -casinl -catan -catanf -catanh -catanhf -catanhl -catanl -catclose -catgets -catopen -cbrt -cbrtf -cbrtl -ccos -ccosf -ccosh -ccoshf -ccoshl -ccosl -ceil -ceilf -ceill -cexp -cexpf -cexpl -chdir -chmod -cimag -cimagf -cimagl -clearenv -clearerr -clearerr_unlocked -clock -clock_getres -clock_gettime -clock_nanosleep -clog -clogf -clogl -close -closedir -confstr -conj -conjf -conjl -copysign -copysignf -copysignl -cos -cosf -cosh -coshf -coshl -cosl -cpow -cpowf -cpowl -cproj -cprojf -cprojl -creal -crealf -creall -creat -creat64 -crypt -crypt_r -csin -csinf -csinh -csinhf -csinhl -csinl -csqrt -csqrtf -csqrtl -ctan -ctanf -ctanh -ctanhf -ctanhl -ctanl -ctime -ctime_r -difftime -dirfd -dirname -div -dprintf -drand48 -drem -dremf -duplocale -ecvt -encrypt -environ -erand48 -erf -erfc -erfcf -erfcl -erff -erfl -errno -exit -exp -exp10 -exp10f -exp10l -exp2 -exp2f -exp2l -expf -expl -explicit_bzero -expm1 -expm1f -expm1l -fabs -fabsf -fabsl -faccessat -fchmod -fchmodat -fclose -fcntl -fcvt -fdatasync -fdclosedir -fdim -fdimf -fdiml -fdopen -fdopendir -feclearexcept -fegetenv -fegetexceptflag -fegetround -feholdexcept -feof -feof_unlocked -feraiseexcept -ferror -ferror_unlocked -fesetenv -fesetexceptflag -fesetround -fetestexcept -feupdateenv -fflush -fflush_unlocked -ffs -ffsl -ffsll -fgetc -fgetc_unlocked -fgetln -fgetpos -fgetpos64 -fgets -fgets_unlocked -fgetwc -fgetwc_unlocked -fgetws -fgetws_unlocked -fileno -fileno_unlocked -finite -finitef -flockfile -floor -floorf -floorl -fma -fmaf -fmal -fmax -fmaxf -fmaxl -fmemopen -fmin -fminf -fminl -fmod -fmodf -fmodl -fmtmsg -fnmatch -fopen -fopen64 -fopencookie -fpathconf -fprintf -fpurge -fputc -fputc_unlocked -fputs -fputs_unlocked -fputwc -fputwc_unlocked -fputws -fputws_unlocked -fread -fread_unlocked -free -freelocale -freopen -freopen64 -frexp -frexpf -frexpl -fscanf -fseek -fseeko -fseeko64 -fsetpos -fsetpos64 -fstat -fstatat -fstatvfs -fsync -ftell -ftello -ftello64 -ftime -ftruncate -ftrylockfile -funlockfile -futimens -futimesat -fwide -fwprintf -fwrite -fwrite_unlocked -fwscanf -gcvt -get_avphys_pages -get_nprocs -get_nprocs_conf -get_phys_pages -getc -getc_unlocked -getchar -getchar_unlocked -getcwd -getdate -getdate_err -getdelim -getdomainname -getentropy -getenv -gethostid -getline -getopt -getopt_long -getopt_long_only -getpagesize -getpid -getrusage -getsockopt -getsubopt -gettimeofday -getw -getwc -getwc_unlocked -getwchar -getwchar_unlocked -glob -glob64 -globfree -globfree64 -gmtime -gmtime_r -hcreate -hcreate_r -hdestroy -hdestroy_r -hsearch -hsearch_r -htonl -htons -hypot -hypotf -hypotl -iconv -iconv_close -iconv_open -ilogb -ilogbf -ilogbl -imaxabs -imaxdiv -in6addr_any -in6addr_loopback -index -inet_aton -inet_ntop -inet_pton -initstate -insque -ioctl -iprintf -isalnum -isalnum_l -isalpha -isalpha_l -isascii -isatty -isblank -isblank_l -iscntrl -iscntrl_l -isdigit -isdigit_l -isgraph -isgraph_l -islower -islower_l -isprint -isprint_l -ispunct -ispunct_l -isspace -isspace_l -isupper -isupper_l -iswalnum -iswalnum_l -iswalpha -iswalpha_l -iswblank -iswblank_l -iswcntrl -iswcntrl_l -iswctype -iswctype_l -iswdigit -iswdigit_l -iswgraph -iswgraph_l -iswlower -iswlower_l -iswprint -iswprint_l -iswpunct -iswpunct_l -iswspace -iswspace_l -iswupper -iswupper_l -iswxdigit -iswxdigit_l -isxdigit -isxdigit_l -j0 -j0f -j1 -j1f -jn -jnf -jrand48 -l64a -labs -lcong48 -ldexp -ldexpf -ldexpl -ldiv -lfind -lgamma -lgamma_r -lgammaf -lgammaf_r -lgammal -lgammal_r -link -linkat -llabs -lldiv -llrint -llrintf -llrintl -llround -llroundf -llroundl -localeconv -localtime -localtime_r -log -log10 -log10f -log10l -log1p -log1pf -log1pl -log2 -log2f -log2l -logb -logbf -logbl -logf -logl -lrand48 -lrint -lrintf -lrintl -lround -lroundf -lroundl -lsearch -lseek -lstat -malloc -malloc_usable_size -mblen -mbrlen -mbrtoc16 -mbrtoc32 -mbrtowc -mbsinit -mbsnrtowcs -mbsrtowcs -mbstowcs -mbtowc -memccpy -memchr -memcmp -memcpy -memmem -memmove -mempcpy -memrchr -memset -mkdir -mkdirat -mktime -mmap -modf -modff -modfl -mrand48 -munmap -nan -nanf -nanl -nanosleep -nearbyint -nearbyintf -nearbyintl -newlocale -nextafter -nextafterf -nextafterl -nexttoward -nexttowardf -nexttowardl -nftw -nftw64 -nl_langinfo -nl_langinfo_l -nrand48 -ntohl -ntohs -open -open_memstream -open_wmemstream -openat -opendir -opendirat -optarg -opterr -optind -optopt -optreset -pathconf -perror -poll -posix_close -posix_fadvise -posix_fallocate -posix_memalign -pow -pow10 -pow10f -pow10l -powf -powl -pread -preadv -printf -program_invocation_name -program_invocation_short_name -pselect -psignal -pthread_attr_destroy -pthread_attr_getdetachstate -pthread_attr_getguardsize -pthread_attr_getinheritsched -pthread_attr_getscope -pthread_attr_getstack -pthread_attr_getstacksize -pthread_attr_init -pthread_attr_setdetachstate -pthread_attr_setstack -pthread_attr_setstacksize -pthread_barrier_destroy -pthread_barrier_init -pthread_barrier_wait -pthread_barrierattr_getpshared -pthread_cond_broadcast -pthread_cond_destroy -pthread_cond_init -pthread_cond_signal -pthread_cond_timedwait -pthread_cond_wait -pthread_condattr_destroy -pthread_condattr_getpshared -pthread_condattr_init -pthread_condattr_setclock -pthread_condattr_setpshared -pthread_create -pthread_detach -pthread_equal -pthread_getspecific -pthread_join -pthread_key_create -pthread_key_delete -pthread_mutex_consistent -pthread_mutex_destroy -pthread_mutex_getprioceiling -pthread_mutex_init -pthread_mutex_lock -pthread_mutex_timedlock -pthread_mutex_trylock -pthread_mutex_unlock -pthread_mutexattr_destroy -pthread_mutexattr_getprotocol -pthread_mutexattr_getpshared -pthread_mutexattr_getrobust -pthread_mutexattr_gettype -pthread_mutexattr_init -pthread_mutexattr_setprotocol -pthread_mutexattr_setpshared -pthread_mutexattr_setrobust -pthread_mutexattr_settype -pthread_once -pthread_rwlock_destroy -pthread_rwlock_init -pthread_rwlock_rdlock -pthread_rwlock_timedrdlock -pthread_rwlock_timedwrlock -pthread_rwlock_tryrdlock -pthread_rwlock_trywrlock -pthread_rwlock_unlock -pthread_rwlock_wrlock -pthread_rwlockattr_destroy -pthread_rwlockattr_getpshared -pthread_rwlockattr_init -pthread_rwlockattr_setpshared -pthread_self -pthread_setcancelstate -pthread_setspecific -pthread_spin_destroy -pthread_spin_init -pthread_spin_lock -pthread_spin_trylock -pthread_spin_unlock -pthread_testcancel -pthread_timedjoin_np -pthread_tryjoin_np -putc -putc_unlocked -putchar -putchar_unlocked -putenv -puts -putw -putwc -putwc_unlocked -putwchar -putwchar_unlocked -pwrite -pwritev -qsort -qsort_r -quick_exit -raise -rand -rand_r -random -read -readdir -readlink -readlinkat -readv -realloc -reallocarray -recv -regcomp -regerror -regexec -regfree -remainder -remainderf -remainderl -remove -remque -remquo -remquof -remquol -rename -renameat -rewind -rewinddir -rindex -rint -rintf -rintl -rmdir -round -roundf -roundl -sbrk -scalb -scalbf -scalbln -scalblnf -scalblnl -scalbn -scalbnf -scalbnl -scandir -scandirat -scanf -sched_yield -seed48 -seekdir -select -sem_destroy -sem_getvalue -sem_init -sem_post -sem_timedwait -sem_trywait -sem_wait -send -setbuf -setbuffer -setenv -setkey -setlinebuf -setlocale -setstate -setvbuf -shutdown -signal -signgam -significand -significandf -sin -sincos -sincosf -sincosl -sinf -sinh -sinhf -sinhl -sinl -sleep -snprintf -sprintf -sqrt -sqrtf -sqrtl -srand -srand48 -srandom -sscanf -stat -statvfs -stderr -stdin -stdout -stpcpy -stpncpy -strcasecmp -strcasecmp_l -strcasestr -strcat -strchr -strchrnul -strcmp -strcoll -strcoll_l -strcpy -strcspn -strdup -strerror -strerror_l -strerror_r -strfmon -strfmon_l -strftime -strftime_l -strlcat -strlcpy -strlen -strncasecmp -strncasecmp_l -strncat -strncmp -strncpy -strndup -strnlen -strpbrk -strptime -strrchr -strsep -strsignal -strspn -strstr -strtod -strtod_l -strtof -strtof_l -strtoimax -strtok -strtok_r -strtol -strtold -strtold_l -strtoll -strtoul -strtoull -strtoumax -strverscmp -strxfrm -strxfrm_l -swab -swprintf -swscanf -symlink -symlinkat -sysconf -tan -tanf -tanh -tanhf -tanhl -tanl -tdelete -tdestroy -telldir -tfind -tgamma -tgammaf -tgammal -thrd_current -thrd_detach -thrd_equal -thrd_sleep -time -timegm -times -timespec_get -toascii -tolower -tolower_l -toupper -toupper_l -towctrans -towctrans_l -towlower -towlower_l -towupper -towupper_l -trunc -truncate -truncf -truncl -tsearch -tss_get -twalk -uname -ungetc -ungetwc -unlink -unlinkat -unsetenv -uselocale -usleep -utime -utimensat -utimes -vasprintf -vdprintf -versionsort -versionsort64 -vfprintf -vfscanf -vfwprintf -vfwscanf -vprintf -vscanf -vsnprintf -vsprintf -vsscanf -vswprintf -vswscanf -vwprintf -vwscanf -wasi_thread_start -wcpcpy -wcpncpy -wcrtomb -wcscasecmp -wcscasecmp_l -wcscat -wcschr -wcscmp -wcscoll -wcscoll_l -wcscpy -wcscspn -wcsdup -wcsftime -wcsftime_l -wcslen -wcsncasecmp -wcsncasecmp_l -wcsncat -wcsncmp -wcsncpy -wcsnlen -wcsnrtombs -wcspbrk -wcsrchr -wcsrtombs -wcsspn -wcsstr -wcstod -wcstof -wcstoimax -wcstok -wcstol -wcstold -wcstoll -wcstombs -wcstoul -wcstoull -wcstoumax -wcswcs -wcswidth -wcsxfrm -wcsxfrm_l -wctob -wctomb -wctrans -wctrans_l -wctype -wctype_l -wcwidth -wmemchr -wmemcmp -wmemcpy -wmemmove -wmemset -wprintf -write -writev -wscanf -y0 -y0f -y1 -y1f -yn -ynf diff --git a/expected/wasm64-wasi-threads/include-all.c b/expected/wasm64-wasi-threads/include-all.c deleted file mode 100644 index d9536e09f..000000000 --- a/expected/wasm64-wasi-threads/include-all.c +++ /dev/null @@ -1,173 +0,0 @@ -#include <__errno.h> -#include <__errno_values.h> -#include <__fd_set.h> -#include <__function___isatty.h> -#include <__functions_malloc.h> -#include <__functions_memcpy.h> -#include <__header_dirent.h> -#include <__header_fcntl.h> -#include <__header_inttypes.h> -#include <__header_netinet_in.h> -#include <__header_poll.h> -#include <__header_stdlib.h> -#include <__header_string.h> -#include <__header_sys_ioctl.h> -#include <__header_sys_resource.h> -#include <__header_sys_socket.h> -#include <__header_sys_stat.h> -#include <__header_time.h> -#include <__header_unistd.h> -#include <__macro_FD_SETSIZE.h> -#include <__macro_PAGESIZE.h> -#include <__mode_t.h> -#include <__seek.h> -#include <__struct_dirent.h> -#include <__struct_in6_addr.h> -#include <__struct_in_addr.h> -#include <__struct_iovec.h> -#include <__struct_msghdr.h> -#include <__struct_pollfd.h> -#include <__struct_rusage.h> -#include <__struct_sockaddr.h> -#include <__struct_sockaddr_in.h> -#include <__struct_sockaddr_in6.h> -#include <__struct_sockaddr_storage.h> -#include <__struct_sockaddr_un.h> -#include <__struct_stat.h> -#include <__struct_timespec.h> -#include <__struct_timeval.h> -#include <__struct_tm.h> -#include <__struct_tms.h> -#include <__typedef_DIR.h> -#include <__typedef_blkcnt_t.h> -#include <__typedef_blksize_t.h> -#include <__typedef_clock_t.h> -#include <__typedef_clockid_t.h> -#include <__typedef_dev_t.h> -#include <__typedef_fd_set.h> -#include <__typedef_gid_t.h> -#include <__typedef_in_addr_t.h> -#include <__typedef_in_port_t.h> -#include <__typedef_ino_t.h> -#include <__typedef_mode_t.h> -#include <__typedef_nfds_t.h> -#include <__typedef_nlink_t.h> -#include <__typedef_off_t.h> -#include <__typedef_sa_family_t.h> -#include <__typedef_sigset_t.h> -#include <__typedef_socklen_t.h> -#include <__typedef_ssize_t.h> -#include <__typedef_suseconds_t.h> -#include <__typedef_time_t.h> -#include <__typedef_uid_t.h> -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include diff --git a/expected/wasm64-wasi-threads/predefined-macros.txt b/expected/wasm64-wasi-threads/predefined-macros.txt deleted file mode 100644 index ee5db9cac..000000000 --- a/expected/wasm64-wasi-threads/predefined-macros.txt +++ /dev/null @@ -1,3423 +0,0 @@ -#define ABDAY_1 0x20000 -#define ABDAY_2 0x20001 -#define ABDAY_3 0x20002 -#define ABDAY_4 0x20003 -#define ABDAY_5 0x20004 -#define ABDAY_6 0x20005 -#define ABDAY_7 0x20006 -#define ABMON_1 0x2000E -#define ABMON_10 0x20017 -#define ABMON_11 0x20018 -#define ABMON_12 0x20019 -#define ABMON_2 0x2000F -#define ABMON_3 0x20010 -#define ABMON_4 0x20011 -#define ABMON_5 0x20012 -#define ABMON_6 0x20013 -#define ABMON_7 0x20014 -#define ABMON_8 0x20015 -#define ABMON_9 0x20016 -#define ABORT 238 -#define ACK 04 -#define ADD ns_uop_add -#define ADJ_ESTERROR 0x0008 -#define ADJ_FREQUENCY 0x0002 -#define ADJ_MAXERROR 0x0004 -#define ADJ_MICRO 0x1000 -#define ADJ_NANO 0x2000 -#define ADJ_OFFSET 0x0001 -#define ADJ_OFFSET_SINGLESHOT 0x8001 -#define ADJ_OFFSET_SS_READ 0xa001 -#define ADJ_SETOFFSET 0x0100 -#define ADJ_STATUS 0x0010 -#define ADJ_TAI 0x0080 -#define ADJ_TICK 0x4000 -#define ADJ_TIMECONST 0x0020 -#define AF_INET PF_INET -#define AF_INET6 PF_INET6 -#define AF_UNIX 3 -#define AF_UNSPEC PF_UNSPEC -#define ALT_DIGITS 0x2002F -#define AM_STR 0x20026 -#define ANYMARK 0x01 -#define AO 245 -#define AREGTYPE '\0' -#define ARFMAG "`\n" -#define ARG_MAX 131072 -#define ARMAG "!\n" -#define AT_EACCESS (0x0) -#define AT_FDCWD (-2) -#define AT_REMOVEDIR (0x4) -#define AT_SYMLINK_FOLLOW (0x2) -#define AT_SYMLINK_NOFOLLOW (0x1) -#define AUTHTYPE_CNT 5 -#define AUTHTYPE_KERBEROS_V4 1 -#define AUTHTYPE_KERBEROS_V5 2 -#define AUTHTYPE_MINK 4 -#define AUTHTYPE_NAME(x) authtype_names[x] -#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) -#define AUTHTYPE_NULL 0 -#define AUTHTYPE_SPX 3 -#define AUTHTYPE_TEST 99 -#define AUTH_HOW_MASK 2 -#define AUTH_HOW_MUTUAL 2 -#define AUTH_HOW_ONE_WAY 0 -#define AUTH_WHO_CLIENT 0 -#define AUTH_WHO_MASK 1 -#define AUTH_WHO_SERVER 1 -#define AYT 246 -#define BIG_ENDIAN __BIG_ENDIAN -#define BITSPERBYTE CHAR_BIT -#define BLKTYPE '4' -#define BLK_BYTECOUNT 2 -#define BLK_EOF 0x40 -#define BLK_EOR 0x80 -#define BLK_ERRORS 0x20 -#define BLK_RESTART 0x10 -#define BREAK 243 -#define BUFSIZ 1024 -#define BYTE_ORDER __BYTE_ORDER -#define CANBSIZ 255 -#define CBRK CEOL -#define CDISCARD CTRL('o') -#define CDSUSP CTRL('y') -#define CEOF CTRL('d') -#define CEOL '\0' -#define CEOT CEOF -#define CERASE 0177 -#define CFLUSH CDISCARD -#define CHARBITS (sizeof(char) * 8) -#define CHARCLASS_NAME_MAX 14 -#define CHAR_BIT 8 -#define CHAR_MAX 127 -#define CHAR_MIN (-128) -#define CHRTYPE '3' -#define CINTR CTRL('c') -#define CKILL CTRL('u') -#define CLNEXT CTRL('v') -#define CLOCKS_PER_SEC ((clock_t)1000000000) -#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) -#define CLOCK_REALTIME (&_CLOCK_REALTIME) -#define CMIN 1 -#define CMPLX(x,y) __CMPLX(x, y, double) -#define CMPLXF(x,y) __CMPLX(x, y, float) -#define CMPLXL(x,y) __CMPLX(x, y, long double) -#define CODESET 14 -#define COLL_WEIGHTS_MAX 2 -#define COMPLETE 2 -#define CONTINUE 3 -#define CONTTYPE '7' -#define CQUIT 034 -#define CREPRINT CTRL('r') -#define CRNCYSTR 0x4000F -#define CRPRNT CREPRINT -#define CSTART CTRL('q') -#define CSTATUS '\0' -#define CSTOP CTRL('s') -#define CSUSP CTRL('z') -#define CTIME 0 -#define CTRL(x) ((x)&037) -#define CWERASE CTRL('w') -#define C_ANY ns_c_any -#define C_CHAOS ns_c_chaos -#define C_HS ns_c_hs -#define C_IN ns_c_in -#define C_IRGRP 000040 -#define C_IROTH 000004 -#define C_IRUSR 000400 -#define C_ISBLK 060000 -#define C_ISCHR 020000 -#define C_ISCTG 0110000 -#define C_ISDIR 040000 -#define C_ISFIFO 010000 -#define C_ISGID 002000 -#define C_ISLNK 0120000 -#define C_ISREG 0100000 -#define C_ISSOCK 0140000 -#define C_ISUID 004000 -#define C_ISVTX 001000 -#define C_IWGRP 000020 -#define C_IWOTH 000002 -#define C_IWUSR 000200 -#define C_IXGRP 000010 -#define C_IXOTH 000001 -#define C_IXUSR 000100 -#define C_NONE ns_c_none -#define DATA 03 -#define DAY_1 0x20007 -#define DAY_2 0x20008 -#define DAY_3 0x20009 -#define DAY_4 0x2000A -#define DAY_5 0x2000B -#define DAY_6 0x2000C -#define DAY_7 0x2000D -#define DBL_DECIMAL_DIG 17 -#define DBL_DIG 15 -#define DBL_EPSILON 2.22044604925031308085e-16 -#define DBL_HAS_SUBNORM 1 -#define DBL_MANT_DIG 53 -#define DBL_MAX 1.79769313486231570815e+308 -#define DBL_MAX_10_EXP 308 -#define DBL_MAX_EXP 1024 -#define DBL_MIN 2.22507385850720138309e-308 -#define DBL_MIN_10_EXP (-307) -#define DBL_MIN_EXP (-1021) -#define DBL_TRUE_MIN 4.94065645841246544177e-324 -#define DECIMAL_DIG 36 -#define DELAYTIMER_MAX 0x7fffffff -#define DELETE ns_uop_delete -#define DEV_BSIZE 512 -#define DIRTYPE '5' -#define DM 242 -#define DMAXEXP DBL_MAX_EXP -#define DMINEXP DBL_MIN_EXP -#define DO 253 -#define DONT 254 -#define DOUBLEBITS (sizeof(double) * 8) -#define DTTOIF(x) (__wasilibc_dttoif(x)) -#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE -#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE -#define DT_DIR __WASI_FILETYPE_DIRECTORY -#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM -#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK -#define DT_REG __WASI_FILETYPE_REGULAR_FILE -#define DT_SOCK 20 -#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN -#define D_FMT 0x20029 -#define D_T_FMT 0x20028 -#define E2BIG __WASI_ERRNO_2BIG -#define EACCES __WASI_ERRNO_ACCES -#define EACCESS 2 -#define EADDRINUSE __WASI_ERRNO_ADDRINUSE -#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL -#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT -#define EAGAIN __WASI_ERRNO_AGAIN -#define EALREADY __WASI_ERRNO_ALREADY -#define EBADF __WASI_ERRNO_BADF -#define EBADID 5 -#define EBADMSG __WASI_ERRNO_BADMSG -#define EBADOP 4 -#define EBUSY __WASI_ERRNO_BUSY -#define EC 247 -#define ECANCELED __WASI_ERRNO_CANCELED -#define ECHILD __WASI_ERRNO_CHILD -#define ECONNABORTED __WASI_ERRNO_CONNABORTED -#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED -#define ECONNRESET __WASI_ERRNO_CONNRESET -#define EDEADLK __WASI_ERRNO_DEADLK -#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ -#define EDOM __WASI_ERRNO_DOM -#define EDQUOT __WASI_ERRNO_DQUOT -#define EEXIST __WASI_ERRNO_EXIST -#define EEXISTS 6 -#define EFAULT __WASI_ERRNO_FAULT -#define EFBIG __WASI_ERRNO_FBIG -#define EFD_CLOEXEC O_CLOEXEC -#define EFD_NONBLOCK O_NONBLOCK -#define EFD_SEMAPHORE 1 -#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH -#define EIDRM __WASI_ERRNO_IDRM -#define EILSEQ __WASI_ERRNO_ILSEQ -#define EINPROGRESS __WASI_ERRNO_INPROGRESS -#define EINTR __WASI_ERRNO_INTR -#define EINVAL __WASI_ERRNO_INVAL -#define EIO __WASI_ERRNO_IO -#define EISCONN __WASI_ERRNO_ISCONN -#define EISDIR __WASI_ERRNO_ISDIR -#define EL 248 -#define ELOOP __WASI_ERRNO_LOOP -#define EMFILE __WASI_ERRNO_MFILE -#define EMLINK __WASI_ERRNO_MLINK -#define EMSGSIZE __WASI_ERRNO_MSGSIZE -#define EMULTIHOP __WASI_ERRNO_MULTIHOP -#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG -#define ENCRYPT_CNT 9 -#define ENCRYPT_DEC_KEYID 8 -#define ENCRYPT_ENC_KEYID 7 -#define ENCRYPT_END 4 -#define ENCRYPT_IS 0 -#define ENCRYPT_NAME(x) encrypt_names[x] -#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) -#define ENCRYPT_REPLY 2 -#define ENCRYPT_REQEND 6 -#define ENCRYPT_REQSTART 5 -#define ENCRYPT_START 3 -#define ENCRYPT_SUPPORT 1 -#define ENCTYPE_ANY 0 -#define ENCTYPE_CNT 3 -#define ENCTYPE_DES_CFB64 1 -#define ENCTYPE_DES_OFB64 2 -#define ENCTYPE_NAME(x) enctype_names[x] -#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) -#define ENETDOWN __WASI_ERRNO_NETDOWN -#define ENETRESET __WASI_ERRNO_NETRESET -#define ENETUNREACH __WASI_ERRNO_NETUNREACH -#define ENFILE __WASI_ERRNO_NFILE -#define ENOBUFS __WASI_ERRNO_NOBUFS -#define ENODEV __WASI_ERRNO_NODEV -#define ENOENT __WASI_ERRNO_NOENT -#define ENOEXEC __WASI_ERRNO_NOEXEC -#define ENOLCK __WASI_ERRNO_NOLCK -#define ENOLINK __WASI_ERRNO_NOLINK -#define ENOMEM __WASI_ERRNO_NOMEM -#define ENOMSG __WASI_ERRNO_NOMSG -#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT -#define ENOSPACE 3 -#define ENOSPC __WASI_ERRNO_NOSPC -#define ENOSYS __WASI_ERRNO_NOSYS -#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE -#define ENOTCONN __WASI_ERRNO_NOTCONN -#define ENOTDIR __WASI_ERRNO_NOTDIR -#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY -#define ENOTFOUND 1 -#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE -#define ENOTSOCK __WASI_ERRNO_NOTSOCK -#define ENOTSUP __WASI_ERRNO_NOTSUP -#define ENOTTY __WASI_ERRNO_NOTTY -#define ENOUSER 7 -#define ENV_ESC 2 -#define ENV_USERVAR 3 -#define ENXIO __WASI_ERRNO_NXIO -#define EOF (-1) -#define EOPNOTSUPP ENOTSUP -#define EOR 239 -#define EOVERFLOW __WASI_ERRNO_OVERFLOW -#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD -#define EPERM __WASI_ERRNO_PERM -#define EPIPE __WASI_ERRNO_PIPE -#define EPROTO __WASI_ERRNO_PROTO -#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT -#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE -#define ERA 0x2002C -#define ERANGE __WASI_ERRNO_RANGE -#define ERA_D_FMT 0x2002E -#define ERA_D_T_FMT 0x20030 -#define ERA_T_FMT 0x20031 -#define EROFS __WASI_ERRNO_ROFS -#define ERROR 05 -#define ESPIPE __WASI_ERRNO_SPIPE -#define ESRCH __WASI_ERRNO_SRCH -#define ESTALE __WASI_ERRNO_STALE -#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT -#define ETXTBSY __WASI_ERRNO_TXTBSY -#define EUNDEF 0 -#define EWOULDBLOCK EAGAIN -#define EXDEV __WASI_ERRNO_XDEV -#define EXIT_FAILURE 1 -#define EXIT_SUCCESS 0 -#define EX_CANTCREAT 73 -#define EX_CONFIG 78 -#define EX_DATAERR 65 -#define EX_IOERR 74 -#define EX_NOHOST 68 -#define EX_NOINPUT 66 -#define EX_NOPERM 77 -#define EX_NOUSER 67 -#define EX_OK 0 -#define EX_OSERR 71 -#define EX_OSFILE 72 -#define EX_PROTOCOL 76 -#define EX_SOFTWARE 70 -#define EX_TEMPFAIL 75 -#define EX_UNAVAILABLE 69 -#define EX_USAGE 64 -#define EX__BASE 64 -#define EX__MAX 78 -#define FD_CLOEXEC (1) -#define FD_CLR(fd,set) (FD_CLR((fd), (set))) -#define FD_COPY(from,to) (FD_COPY((from), (to))) -#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) -#define FD_SET(fd,set) (FD_SET((fd), (set))) -#define FD_SETSIZE 1024 -#define FD_ZERO(set) (FD_ZERO((set))) -#define FE_ALL_EXCEPT 0 -#define FE_DFL_ENV ((const fenv_t *) -1) -#define FE_TONEAREST 0 -#define FIFOTYPE '6' -#define FILENAME_MAX 4096 -#define FILESIZEBITS 64 -#define FIONBIO 2 -#define FIONREAD 1 -#define FLOATBITS (sizeof(float) * 8) -#define FLT_DECIMAL_DIG 9 -#define FLT_DIG 6 -#define FLT_EPSILON 1.1920928955078125e-07F -#define FLT_EVAL_METHOD 0 -#define FLT_HAS_SUBNORM 1 -#define FLT_MANT_DIG 24 -#define FLT_MAX 3.40282346638528859812e+38F -#define FLT_MAX_10_EXP 38 -#define FLT_MAX_EXP 128 -#define FLT_MIN 1.17549435082228750797e-38F -#define FLT_MIN_10_EXP (-37) -#define FLT_MIN_EXP (-125) -#define FLT_RADIX 2 -#define FLT_ROUNDS (__builtin_flt_rounds()) -#define FLT_TRUE_MIN 1.40129846432481707092e-45F -#define FLUSHBAND 0x04 -#define FLUSHR 0x01 -#define FLUSHRW 0x03 -#define FLUSHW 0x02 -#define FMAXEXP FLT_MAX_EXP -#define FMINEXP FLT_MIN_EXP -#define FMNAMESZ 8 -#define FNM_CASEFOLD 0x10 -#define FNM_FILE_NAME FNM_PATHNAME -#define FNM_LEADING_DIR 0x8 -#define FNM_NOESCAPE 0x2 -#define FNM_NOMATCH 1 -#define FNM_NOSYS (-1) -#define FNM_PATHNAME 0x1 -#define FNM_PERIOD 0x4 -#define FOPEN_MAX 1000 -#define FORMERR ns_r_formerr -#define FORM_C 3 -#define FORM_N 1 -#define FORM_T 2 -#define FP_ILOGB0 FP_ILOGBNAN -#define FP_ILOGBNAN (-1-0x7fffffff) -#define FP_INFINITE 1 -#define FP_NAN 0 -#define FP_NORMAL 4 -#define FP_SUBNORMAL 3 -#define FP_ZERO 2 -#define FSETLOCKING_BYCALLER 2 -#define FSETLOCKING_INTERNAL 1 -#define FSETLOCKING_QUERY 0 -#define FTW_CHDIR 4 -#define FTW_D 2 -#define FTW_DEPTH 8 -#define FTW_DNR 3 -#define FTW_DP 6 -#define FTW_F 1 -#define FTW_MOUNT 2 -#define FTW_NS 4 -#define FTW_PHYS 1 -#define FTW_SL 5 -#define FTW_SLN 7 -#define F_GETFD (1) -#define F_GETFL (3) -#define F_LOCK 1 -#define F_OK (0) -#define F_SETFD (2) -#define F_SETFL (4) -#define F_TEST 3 -#define F_TLOCK 2 -#define F_ULOCK 0 -#define GA 249 -#define GETLONG NS_GET32 -#define GETSHORT NS_GET16 -#define GLOB_ABORTED 2 -#define GLOB_APPEND 0x20 -#define GLOB_DOOFFS 0x08 -#define GLOB_ERR 0x01 -#define GLOB_MARK 0x02 -#define GLOB_NOCHECK 0x10 -#define GLOB_NOESCAPE 0x40 -#define GLOB_NOMATCH 3 -#define GLOB_NOSORT 0x04 -#define GLOB_NOSPACE 1 -#define GLOB_NOSYS 4 -#define GLOB_PERIOD 0x80 -#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) -#define HFIXEDSZ NS_HFIXEDSZ -#define HIBITL MINLONG -#define HIBITS MINSHORT -#define HOST_NAME_MAX 255 -#define HUGE 3.40282346638528859812e+38F -#define HUGE_VAL ((double)INFINITY) -#define HUGE_VALF INFINITY -#define HUGE_VALL ((long double)INFINITY) -#define I _Complex_I -#define IAC 255 -#define ICMP6_DST_UNREACH 1 -#define ICMP6_DST_UNREACH_ADDR 3 -#define ICMP6_DST_UNREACH_ADMIN 1 -#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 -#define ICMP6_DST_UNREACH_NOPORT 4 -#define ICMP6_DST_UNREACH_NOROUTE 0 -#define ICMP6_ECHO_REPLY 129 -#define ICMP6_ECHO_REQUEST 128 -#define ICMP6_FILTER 1 -#define ICMP6_FILTER_BLOCK 1 -#define ICMP6_FILTER_BLOCKOTHERS 3 -#define ICMP6_FILTER_PASS 2 -#define ICMP6_FILTER_PASSONLY 4 -#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) -#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) -#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) -#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) -#define ICMP6_INFOMSG_MASK 0x80 -#define ICMP6_PACKET_TOO_BIG 2 -#define ICMP6_PARAMPROB_HEADER 0 -#define ICMP6_PARAMPROB_NEXTHEADER 1 -#define ICMP6_PARAMPROB_OPTION 2 -#define ICMP6_PARAM_PROB 4 -#define ICMP6_ROUTER_RENUMBERING 138 -#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 -#define ICMP6_RR_FLAGS_PREVDONE 0x08 -#define ICMP6_RR_FLAGS_REQRESULT 0x40 -#define ICMP6_RR_FLAGS_SPECSITE 0x10 -#define ICMP6_RR_FLAGS_TEST 0x80 -#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 -#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 -#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 -#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 -#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 -#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 -#define ICMP6_TIME_EXCEEDED 3 -#define ICMP6_TIME_EXCEED_REASSEMBLY 1 -#define ICMP6_TIME_EXCEED_TRANSIT 0 -#define ICMP_ADDRESS 17 -#define ICMP_ADDRESSREPLY 18 -#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) -#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) -#define ICMP_DEST_UNREACH 3 -#define ICMP_ECHO 8 -#define ICMP_ECHOREPLY 0 -#define ICMP_EXC_FRAGTIME 1 -#define ICMP_EXC_TTL 0 -#define ICMP_FRAG_NEEDED 4 -#define ICMP_HOST_ANO 10 -#define ICMP_HOST_ISOLATED 8 -#define ICMP_HOST_UNKNOWN 7 -#define ICMP_HOST_UNREACH 1 -#define ICMP_HOST_UNR_TOS 12 -#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) -#define ICMP_INFO_REPLY 16 -#define ICMP_INFO_REQUEST 15 -#define ICMP_IREQ 15 -#define ICMP_IREQREPLY 16 -#define ICMP_MASKLEN 12 -#define ICMP_MASKREPLY 18 -#define ICMP_MASKREQ 17 -#define ICMP_MAXTYPE 18 -#define ICMP_MINLEN 8 -#define ICMP_NET_ANO 9 -#define ICMP_NET_UNKNOWN 6 -#define ICMP_NET_UNREACH 0 -#define ICMP_NET_UNR_TOS 11 -#define ICMP_PARAMETERPROB 12 -#define ICMP_PARAMPROB 12 -#define ICMP_PARAMPROB_OPTABSENT 1 -#define ICMP_PKT_FILTERED 13 -#define ICMP_PORT_UNREACH 3 -#define ICMP_PREC_CUTOFF 15 -#define ICMP_PREC_VIOLATION 14 -#define ICMP_PROT_UNREACH 2 -#define ICMP_REDIRECT 5 -#define ICMP_REDIRECT_HOST 1 -#define ICMP_REDIRECT_NET 0 -#define ICMP_REDIRECT_TOSHOST 3 -#define ICMP_REDIRECT_TOSNET 2 -#define ICMP_REDIR_HOST 1 -#define ICMP_REDIR_HOSTTOS 3 -#define ICMP_REDIR_NET 0 -#define ICMP_REDIR_NETTOS 2 -#define ICMP_ROUTERADVERT 9 -#define ICMP_ROUTERSOLICIT 10 -#define ICMP_SOURCEQUENCH 4 -#define ICMP_SOURCE_QUENCH 4 -#define ICMP_SR_FAILED 5 -#define ICMP_TIMESTAMP 13 -#define ICMP_TIMESTAMPREPLY 14 -#define ICMP_TIME_EXCEEDED 11 -#define ICMP_TIMXCEED 11 -#define ICMP_TIMXCEED_INTRANS 0 -#define ICMP_TIMXCEED_REASS 1 -#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) -#define ICMP_TSTAMP 13 -#define ICMP_TSTAMPREPLY 14 -#define ICMP_UNREACH 3 -#define ICMP_UNREACH_FILTER_PROHIB 13 -#define ICMP_UNREACH_HOST 1 -#define ICMP_UNREACH_HOST_PRECEDENCE 14 -#define ICMP_UNREACH_HOST_PROHIB 10 -#define ICMP_UNREACH_HOST_UNKNOWN 7 -#define ICMP_UNREACH_ISOLATED 8 -#define ICMP_UNREACH_NEEDFRAG 4 -#define ICMP_UNREACH_NET 0 -#define ICMP_UNREACH_NET_PROHIB 9 -#define ICMP_UNREACH_NET_UNKNOWN 6 -#define ICMP_UNREACH_PORT 3 -#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 -#define ICMP_UNREACH_PROTOCOL 2 -#define ICMP_UNREACH_SRCFAIL 5 -#define ICMP_UNREACH_TOSHOST 12 -#define ICMP_UNREACH_TOSNET 11 -#define IFTODT(x) (__wasilibc_iftodt(x)) -#define IGMP_AWAKENING_MEMBER 5 -#define IGMP_DELAYING_MEMBER 1 -#define IGMP_DVMRP 0x13 -#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP -#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY -#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT -#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT -#define IGMP_IDLE_MEMBER 2 -#define IGMP_LAZY_MEMBER 3 -#define IGMP_MAX_HOST_REPORT_DELAY 10 -#define IGMP_MEMBERSHIP_QUERY 0x11 -#define IGMP_MINLEN 8 -#define IGMP_MTRACE 0x1f -#define IGMP_MTRACE_RESP 0x1e -#define IGMP_PIM 0x14 -#define IGMP_SLEEPING_MEMBER 4 -#define IGMP_TIMER_SCALE 10 -#define IGMP_TRACE 0x15 -#define IGMP_V1_MEMBERSHIP_REPORT 0x12 -#define IGMP_V2_LEAVE_GROUP 0x17 -#define IGMP_V2_MEMBERSHIP_REPORT 0x16 -#define IGMP_v1_ROUTER 1 -#define IGMP_v2_ROUTER 2 -#define IN6ADDRSZ NS_IN6ADDRSZ -#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } -#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } -#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) -#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) -#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) -#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) -#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) -#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) -#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) -#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) -#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) -#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) -#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) -#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) -#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) -#define INADDRSZ NS_INADDRSZ -#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) -#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) -#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) -#define INADDR_ANY ((in_addr_t) 0x00000000) -#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) -#define INADDR_DUMMY ((in_addr_t) 0xc0000008) -#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) -#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) -#define INADDR_NONE ((in_addr_t) 0xffffffff) -#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) -#define INDIR_MASK NS_CMPRSFLGS -#define INET6_ADDRSTRLEN 46 -#define INET_ADDRSTRLEN 16 -#define INFINITY 1e5000f -#define INT16SZ NS_INT16SZ -#define INT16_C(c) c -#define INT16_MAX (0x7fff) -#define INT16_MIN (-1-0x7fff) -#define INT32SZ NS_INT32SZ -#define INT32_C(c) c -#define INT32_MAX (0x7fffffff) -#define INT32_MIN (-1-0x7fffffff) -#define INT64_C(c) c ## LL -#define INT64_MAX (0x7fffffffffffffff) -#define INT64_MIN (-1-0x7fffffffffffffff) -#define INT8SZ NS_INT8SZ -#define INT8_C(c) c -#define INT8_MAX (0x7f) -#define INT8_MIN (-1-0x7f) -#define INTBITS (sizeof(int) * 8) -#define INTMAX_C(c) c ## LL -#define INTMAX_MAX INT64_MAX -#define INTMAX_MIN INT64_MIN -#define INTPTR_MAX INT32_MAX -#define INTPTR_MIN INT32_MIN -#define INT_FAST16_MAX INT16_MAX -#define INT_FAST16_MIN INT16_MIN -#define INT_FAST32_MAX INT32_MAX -#define INT_FAST32_MIN INT32_MIN -#define INT_FAST64_MAX INT64_MAX -#define INT_FAST64_MIN INT64_MIN -#define INT_FAST8_MAX INT8_MAX -#define INT_FAST8_MIN INT8_MIN -#define INT_LEAST16_MAX INT16_MAX -#define INT_LEAST16_MIN INT16_MIN -#define INT_LEAST32_MAX INT32_MAX -#define INT_LEAST32_MIN INT32_MIN -#define INT_LEAST64_MAX INT64_MAX -#define INT_LEAST64_MIN INT64_MIN -#define INT_LEAST8_MAX INT8_MAX -#define INT_LEAST8_MIN INT8_MIN -#define INT_MAX 0x7fffffff -#define INT_MIN (-1-0x7fffffff) -#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) -#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) -#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) -#define IN_CLASSA_MAX 128 -#define IN_CLASSA_NET 0xff000000 -#define IN_CLASSA_NSHIFT 24 -#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) -#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) -#define IN_CLASSB_MAX 65536 -#define IN_CLASSB_NET 0xffff0000 -#define IN_CLASSB_NSHIFT 16 -#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) -#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) -#define IN_CLASSC_NET 0xffffff00 -#define IN_CLASSC_NSHIFT 8 -#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) -#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) -#define IN_LOOPBACKNET 127 -#define IN_MULTICAST(a) IN_CLASSD(a) -#define IOV_MAX 1024 -#define IP 244 -#define IP6F_MORE_FRAG 0x0100 -#define IP6F_OFF_MASK 0xf8ff -#define IP6F_RESERVED_MASK 0x0600 -#define IP6OPT_JUMBO 0xc2 -#define IP6OPT_JUMBO_LEN 6 -#define IP6OPT_NSAP_ADDR 0xc3 -#define IP6OPT_PAD1 0 -#define IP6OPT_PADN 1 -#define IP6OPT_ROUTER_ALERT 0x05 -#define IP6OPT_TUNNEL_LIMIT 0x04 -#define IP6OPT_TYPE(o) ((o) & 0xc0) -#define IP6OPT_TYPE_DISCARD 0x40 -#define IP6OPT_TYPE_FORCEICMP 0x80 -#define IP6OPT_TYPE_ICMP 0xc0 -#define IP6OPT_TYPE_MUTABLE 0x20 -#define IP6OPT_TYPE_SKIP 0x00 -#define IP6_ALERT_AN 0x0200 -#define IP6_ALERT_MLD 0x0000 -#define IP6_ALERT_RSVP 0x0100 -#define IPDEFTTL 64 -#define IPFRAGTTL 60 -#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) -#define IPOPT_CLASS_MASK 0x60 -#define IPOPT_CONTROL 0x00 -#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) -#define IPOPT_COPY 0x80 -#define IPOPT_DEBMEAS 0x40 -#define IPOPT_END IPOPT_EOL -#define IPOPT_EOL 0 -#define IPOPT_LSRR 131 -#define IPOPT_MEASUREMENT IPOPT_DEBMEAS -#define IPOPT_MINOFF 4 -#define IPOPT_NOOP IPOPT_NOP -#define IPOPT_NOP 1 -#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) -#define IPOPT_NUMBER_MASK 0x1f -#define IPOPT_OFFSET 2 -#define IPOPT_OLEN 1 -#define IPOPT_OPTVAL 0 -#define IPOPT_RA 148 -#define IPOPT_RESERVED1 0x20 -#define IPOPT_RESERVED2 0x60 -#define IPOPT_RR 7 -#define IPOPT_SATID 136 -#define IPOPT_SEC IPOPT_SECURITY -#define IPOPT_SECURITY 130 -#define IPOPT_SECUR_CONFID 0xf135 -#define IPOPT_SECUR_EFTO 0x789a -#define IPOPT_SECUR_MMMM 0xbc4d -#define IPOPT_SECUR_RESTR 0xaf13 -#define IPOPT_SECUR_SECRET 0xd788 -#define IPOPT_SECUR_TOPSECRET 0x6bc5 -#define IPOPT_SECUR_UNCLASS 0x0000 -#define IPOPT_SID IPOPT_SATID -#define IPOPT_SSRR 137 -#define IPOPT_TIMESTAMP IPOPT_TS -#define IPOPT_TS 68 -#define IPOPT_TS_PRESPEC 3 -#define IPOPT_TS_TSANDADDR 1 -#define IPOPT_TS_TSONLY 0 -#define IPPORT_RESERVED 1024 -#define IPPROTO_ICMP 1 -#define IPPROTO_IP 0 -#define IPPROTO_IPV6 41 -#define IPPROTO_RAW 255 -#define IPPROTO_TCP 6 -#define IPPROTO_UDP 17 -#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) -#define IPTOS_CLASS_CS0 0x00 -#define IPTOS_CLASS_CS1 0x20 -#define IPTOS_CLASS_CS2 0x40 -#define IPTOS_CLASS_CS3 0x60 -#define IPTOS_CLASS_CS4 0x80 -#define IPTOS_CLASS_CS5 0xa0 -#define IPTOS_CLASS_CS6 0xc0 -#define IPTOS_CLASS_CS7 0xe0 -#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 -#define IPTOS_CLASS_MASK 0xe0 -#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) -#define IPTOS_DSCP_AF11 0x28 -#define IPTOS_DSCP_AF12 0x30 -#define IPTOS_DSCP_AF13 0x38 -#define IPTOS_DSCP_AF21 0x48 -#define IPTOS_DSCP_AF22 0x50 -#define IPTOS_DSCP_AF23 0x58 -#define IPTOS_DSCP_AF31 0x68 -#define IPTOS_DSCP_AF32 0x70 -#define IPTOS_DSCP_AF33 0x78 -#define IPTOS_DSCP_AF41 0x88 -#define IPTOS_DSCP_AF42 0x90 -#define IPTOS_DSCP_AF43 0x98 -#define IPTOS_DSCP_EF 0xb8 -#define IPTOS_DSCP_MASK 0xfc -#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) -#define IPTOS_ECN_CE 0x03 -#define IPTOS_ECN_ECT0 0x02 -#define IPTOS_ECN_ECT1 0x01 -#define IPTOS_ECN_MASK 0x03 -#define IPTOS_ECN_NOT_ECT 0x00 -#define IPTOS_LOWCOST 0x02 -#define IPTOS_LOWDELAY 0x10 -#define IPTOS_MINCOST IPTOS_LOWCOST -#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) -#define IPTOS_PREC_CRITIC_ECP 0xa0 -#define IPTOS_PREC_FLASH 0x60 -#define IPTOS_PREC_FLASHOVERRIDE 0x80 -#define IPTOS_PREC_IMMEDIATE 0x40 -#define IPTOS_PREC_INTERNETCONTROL 0xc0 -#define IPTOS_PREC_MASK 0xe0 -#define IPTOS_PREC_NETCONTROL 0xe0 -#define IPTOS_PREC_PRIORITY 0x20 -#define IPTOS_PREC_ROUTINE 0x00 -#define IPTOS_RELIABILITY 0x04 -#define IPTOS_THROUGHPUT 0x08 -#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) -#define IPTOS_TOS_MASK 0x1E -#define IPTTLDEC 1 -#define IPV6_2292DSTOPTS 4 -#define IPV6_2292HOPLIMIT 8 -#define IPV6_2292HOPOPTS 3 -#define IPV6_2292PKTINFO 2 -#define IPV6_2292PKTOPTIONS 6 -#define IPV6_2292RTHDR 5 -#define IPV6_ADDRFORM 1 -#define IPV6_ADDR_PREFERENCES 72 -#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP -#define IPV6_AUTHHDR 10 -#define IPV6_AUTOFLOWLABEL 70 -#define IPV6_CHECKSUM 7 -#define IPV6_DONTFRAG 62 -#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP -#define IPV6_DSTOPTS 59 -#define IPV6_FREEBIND 78 -#define IPV6_HDRINCL 36 -#define IPV6_HOPLIMIT 52 -#define IPV6_HOPOPTS 54 -#define IPV6_IPSEC_POLICY 34 -#define IPV6_JOIN_ANYCAST 27 -#define IPV6_JOIN_GROUP 20 -#define IPV6_LEAVE_ANYCAST 28 -#define IPV6_LEAVE_GROUP 21 -#define IPV6_MINHOPCOUNT 73 -#define IPV6_MTU 24 -#define IPV6_MTU_DISCOVER 23 -#define IPV6_MULTICAST_ALL 29 -#define IPV6_MULTICAST_HOPS 18 -#define IPV6_MULTICAST_IF 17 -#define IPV6_MULTICAST_LOOP 19 -#define IPV6_NEXTHOP 9 -#define IPV6_ORIGDSTADDR 74 -#define IPV6_PATHMTU 61 -#define IPV6_PKTINFO 50 -#define IPV6_PMTUDISC_DO 2 -#define IPV6_PMTUDISC_DONT 0 -#define IPV6_PMTUDISC_INTERFACE 4 -#define IPV6_PMTUDISC_OMIT 5 -#define IPV6_PMTUDISC_PROBE 3 -#define IPV6_PMTUDISC_WANT 1 -#define IPV6_PREFER_SRC_CGA 0x0008 -#define IPV6_PREFER_SRC_COA 0x0004 -#define IPV6_PREFER_SRC_HOME 0x0400 -#define IPV6_PREFER_SRC_NONCGA 0x0800 -#define IPV6_PREFER_SRC_PUBLIC 0x0002 -#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 -#define IPV6_PREFER_SRC_TMP 0x0001 -#define IPV6_RECVDSTOPTS 58 -#define IPV6_RECVERR 25 -#define IPV6_RECVFRAGSIZE 77 -#define IPV6_RECVHOPLIMIT 51 -#define IPV6_RECVHOPOPTS 53 -#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR -#define IPV6_RECVPATHMTU 60 -#define IPV6_RECVPKTINFO 49 -#define IPV6_RECVRTHDR 56 -#define IPV6_RECVTCLASS 66 -#define IPV6_ROUTER_ALERT 22 -#define IPV6_ROUTER_ALERT_ISOLATE 30 -#define IPV6_RTHDR 57 -#define IPV6_RTHDRDSTOPTS 55 -#define IPV6_RTHDR_LOOSE 0 -#define IPV6_RTHDR_STRICT 1 -#define IPV6_RTHDR_TYPE_0 0 -#define IPV6_RXDSTOPTS IPV6_DSTOPTS -#define IPV6_RXHOPOPTS IPV6_HOPOPTS -#define IPV6_TCLASS 67 -#define IPV6_TRANSPARENT 75 -#define IPV6_UNICAST_HOPS 16 -#define IPV6_UNICAST_IF 76 -#define IPV6_V6ONLY 26 -#define IPV6_XFRM_POLICY 35 -#define IPVERSION 4 -#define IP_ADD_MEMBERSHIP 35 -#define IP_ADD_SOURCE_MEMBERSHIP 39 -#define IP_BIND_ADDRESS_NO_PORT 24 -#define IP_BLOCK_SOURCE 38 -#define IP_CHECKSUM 23 -#define IP_DEFAULT_MULTICAST_LOOP 1 -#define IP_DEFAULT_MULTICAST_TTL 1 -#define IP_DF 0x4000 -#define IP_DROP_MEMBERSHIP 36 -#define IP_DROP_SOURCE_MEMBERSHIP 40 -#define IP_FREEBIND 15 -#define IP_HDRINCL 3 -#define IP_IPSEC_POLICY 16 -#define IP_MAXPACKET 65535 -#define IP_MAX_MEMBERSHIPS 20 -#define IP_MF 0x2000 -#define IP_MINTTL 21 -#define IP_MSFILTER 41 -#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) -#define IP_MSS 576 -#define IP_MTU 14 -#define IP_MTU_DISCOVER 10 -#define IP_MULTICAST_ALL 49 -#define IP_MULTICAST_IF 32 -#define IP_MULTICAST_LOOP 34 -#define IP_MULTICAST_TTL 33 -#define IP_NODEFRAG 22 -#define IP_OFFMASK 0x1fff -#define IP_OPTIONS 4 -#define IP_ORIGDSTADDR 20 -#define IP_PASSSEC 18 -#define IP_PKTINFO 8 -#define IP_PKTOPTIONS 9 -#define IP_PMTUDISC 10 -#define IP_PMTUDISC_DO 2 -#define IP_PMTUDISC_DONT 0 -#define IP_PMTUDISC_INTERFACE 4 -#define IP_PMTUDISC_OMIT 5 -#define IP_PMTUDISC_PROBE 3 -#define IP_PMTUDISC_WANT 1 -#define IP_RECVERR 11 -#define IP_RECVERR_RFC4884 26 -#define IP_RECVFRAGSIZE 25 -#define IP_RECVOPTS 6 -#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR -#define IP_RECVRETOPTS IP_RETOPTS -#define IP_RECVTOS 13 -#define IP_RECVTTL 12 -#define IP_RETOPTS 7 -#define IP_RF 0x8000 -#define IP_ROUTER_ALERT 5 -#define IP_TOS 1 -#define IP_TRANSPARENT 19 -#define IP_TTL 2 -#define IP_UNBLOCK_SOURCE 37 -#define IP_UNICAST_IF 50 -#define IP_XFRM_POLICY 17 -#define IQUERY ns_o_iquery -#define I_ATMARK (__SID |31) -#define I_CANPUT (__SID |34) -#define I_CKBAND (__SID |29) -#define I_FDINSERT (__SID |16) -#define I_FIND (__SID |11) -#define I_FLUSH (__SID | 5) -#define I_FLUSHBAND (__SID |28) -#define I_GETBAND (__SID |30) -#define I_GETCLTIME (__SID |33) -#define I_GETSIG (__SID |10) -#define I_GRDOPT (__SID | 7) -#define I_GWROPT (__SID |20) -#define I_LINK (__SID |12) -#define I_LIST (__SID |21) -#define I_LOOK (__SID | 4) -#define I_NREAD (__SID | 1) -#define I_PEEK (__SID |15) -#define I_PLINK (__SID |22) -#define I_POP (__SID | 3) -#define I_PUNLINK (__SID |23) -#define I_PUSH (__SID | 2) -#define I_RECVFD (__SID |14) -#define I_SENDFD (__SID |17) -#define I_SETCLTIME (__SID |32) -#define I_SETSIG (__SID | 9) -#define I_SRDOPT (__SID | 6) -#define I_STR (__SID | 8) -#define I_SWROPT (__SID |19) -#define I_UNLINK (__SID |13) -#define LASTMARK 0x02 -#define LC_ALL 6 -#define LC_ALL_MASK 0x7fffffff -#define LC_COLLATE 3 -#define LC_COLLATE_MASK (1<(b))?(a):(b)) -#define MAXCDNAME NS_MAXCDNAME -#define MAXDNAME NS_MAXDNAME -#define MAXDOUBLE DBL_MAX -#define MAXFLOAT FLT_MAX -#define MAXHOSTNAMELEN 64 -#define MAXINT INT_MAX -#define MAXLABEL NS_MAXLABEL -#define MAXLONG LONG_MAX -#define MAXNAMLEN 255 -#define MAXPATHLEN 4096 -#define MAXSHORT SHRT_MAX -#define MAXSYMLINKS 20 -#define MAXTC 6 -#define MAXTTL 255 -#define MAX_IPOPTLEN 40 -#define MB_CUR_MAX (__ctype_get_mb_cur_max()) -#define MB_LEN_MAX 4 -#define MCAST_BLOCK_SOURCE 43 -#define MCAST_EXCLUDE 0 -#define MCAST_INCLUDE 1 -#define MCAST_JOIN_GROUP 42 -#define MCAST_JOIN_SOURCE_GROUP 46 -#define MCAST_LEAVE_GROUP 45 -#define MCAST_LEAVE_SOURCE_GROUP 47 -#define MCAST_MSFILTER 48 -#define MCAST_UNBLOCK_SOURCE 44 -#define MIN(a,b) (((a)<(b))?(a):(b)) -#define MINDOUBLE DBL_MIN -#define MINFLOAT FLT_MIN -#define MININT INT_MIN -#define MINLONG LONG_MIN -#define MINSHORT SHRT_MIN -#define MLD_LISTENER_QUERY 130 -#define MLD_LISTENER_REDUCTION 132 -#define MLD_LISTENER_REPORT 131 -#define MM_APPL 8 -#define MM_CONSOLE 512 -#define MM_ERROR 2 -#define MM_FIRM 4 -#define MM_HALT 1 -#define MM_HARD 1 -#define MM_INFO 4 -#define MM_NOCON 4 -#define MM_NOMSG 1 -#define MM_NOSEV 0 -#define MM_NOTOK (-1) -#define MM_NRECOV 128 -#define MM_NULLACT ((char*)0) -#define MM_NULLLBL ((char*)0) -#define MM_NULLMC 0L -#define MM_NULLSEV 0 -#define MM_NULLTAG ((char*)0) -#define MM_NULLTXT ((char*)0) -#define MM_OK 0 -#define MM_OPSYS 32 -#define MM_PRINT 256 -#define MM_RECOVER 64 -#define MM_SOFT 2 -#define MM_UTIL 16 -#define MM_WARNING 3 -#define MODE_ACK 0x04 -#define MODE_B 2 -#define MODE_C 3 -#define MODE_ECHO 0x0200 -#define MODE_EDIT 0x01 -#define MODE_FLOW 0x0100 -#define MODE_FORCE 0x1000 -#define MODE_INBIN 0x0400 -#define MODE_LIT_ECHO 0x10 -#define MODE_MASK 0x1f -#define MODE_OUTBIN 0x0800 -#define MODE_S 1 -#define MODE_SOFT_TAB 0x08 -#define MODE_TRAPSIG 0x02 -#define MOD_CLKA ADJ_OFFSET_SINGLESHOT -#define MOD_CLKB ADJ_TICK -#define MOD_ESTERROR ADJ_ESTERROR -#define MOD_FREQUENCY ADJ_FREQUENCY -#define MOD_MAXERROR ADJ_MAXERROR -#define MOD_MICRO ADJ_MICRO -#define MOD_NANO ADJ_NANO -#define MOD_OFFSET ADJ_OFFSET -#define MOD_STATUS ADJ_STATUS -#define MOD_TAI ADJ_TAI -#define MOD_TIMECONST ADJ_TIMECONST -#define MON_1 0x2001A -#define MON_10 0x20023 -#define MON_11 0x20024 -#define MON_12 0x20025 -#define MON_2 0x2001B -#define MON_3 0x2001C -#define MON_4 0x2001D -#define MON_5 0x2001E -#define MON_6 0x2001F -#define MON_7 0x20020 -#define MON_8 0x20021 -#define MON_9 0x20022 -#define MORECTL 1 -#define MOREDATA 2 -#define MSG_ANY 0x02 -#define MSG_BAND 0x04 -#define MSG_HIPRI 0x01 -#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK -#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED -#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL -#define MUXID_ALL (-1) -#define M_1_PI 0.31830988618379067154 -#define M_2_PI 0.63661977236758134308 -#define M_2_SQRTPI 1.12837916709551257390 -#define M_E 2.7182818284590452354 -#define M_LN10 2.30258509299404568402 -#define M_LN2 0.69314718055994530942 -#define M_LOG10E 0.43429448190325182765 -#define M_LOG2E 1.4426950408889634074 -#define M_PI 3.14159265358979323846 -#define M_PI_2 1.57079632679489661923 -#define M_PI_4 0.78539816339744830962 -#define M_SQRT1_2 0.70710678118654752440 -#define M_SQRT2 1.41421356237309504880 -#define NAMESERVER_PORT NS_DEFAULTPORT -#define NAME_MAX 255 -#define NAN (0.0f/0.0f) -#define NBBY 8 -#define NCARGS 131072 -#define ND_NA_FLAG_OVERRIDE 0x00000020 -#define ND_NA_FLAG_ROUTER 0x00000080 -#define ND_NA_FLAG_SOLICITED 0x00000040 -#define ND_NEIGHBOR_ADVERT 136 -#define ND_NEIGHBOR_SOLICIT 135 -#define ND_OPT_HOME_AGENT_INFO 8 -#define ND_OPT_MTU 5 -#define ND_OPT_PI_FLAG_AUTO 0x40 -#define ND_OPT_PI_FLAG_ONLINK 0x80 -#define ND_OPT_PI_FLAG_RADDR 0x20 -#define ND_OPT_PREFIX_INFORMATION 3 -#define ND_OPT_REDIRECTED_HEADER 4 -#define ND_OPT_RTR_ADV_INTERVAL 7 -#define ND_OPT_SOURCE_LINKADDR 1 -#define ND_OPT_TARGET_LINKADDR 2 -#define ND_RA_FLAG_HOME_AGENT 0x20 -#define ND_RA_FLAG_MANAGED 0x80 -#define ND_RA_FLAG_OTHER 0x40 -#define ND_REDIRECT 137 -#define ND_ROUTER_ADVERT 134 -#define ND_ROUTER_SOLICIT 133 -#define NEW_ENV_VALUE 1 -#define NEW_ENV_VAR 0 -#define NGROUPS 32 -#define NGROUPS_MAX 32 -#define NL_ARGMAX 9 -#define NL_CAT_LOCALE 1 -#define NL_LANGMAX 32 -#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) -#define NL_MSGMAX 32767 -#define NL_NMAX 16 -#define NL_SETD 1 -#define NL_SETMAX 255 -#define NL_TEXTMAX 2048 -#define NOERROR ns_r_noerror -#define NOEXPR 0x50001 -#define NOFILE 256 -#define NOGROUP (-1) -#define NOP 241 -#define NOSTR 0x50003 -#define NOTAUTH ns_r_notauth -#define NOTIMP ns_r_notimpl -#define NOTZONE ns_r_notzone -#define NR_ICMP_TYPES 18 -#define NR_ICMP_UNREACH 15 -#define NSLC 18 -#define NS_ALG_DH 2 -#define NS_ALG_DSA 3 -#define NS_ALG_DSS NS_ALG_DSA -#define NS_ALG_EXPIRE_ONLY 253 -#define NS_ALG_MD5RSA 1 -#define NS_ALG_PRIVATE_OID 254 -#define NS_CMPRSFLGS 0xc0 -#define NS_DEFAULTPORT 53 -#define NS_DSA_MAX_BYTES 405 -#define NS_DSA_MIN_SIZE 213 -#define NS_DSA_SIG_SIZE 41 -#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) -#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) -#define NS_HFIXEDSZ 12 -#define NS_IN6ADDRSZ 16 -#define NS_INADDRSZ 4 -#define NS_INT16SZ 2 -#define NS_INT32SZ 4 -#define NS_INT8SZ 1 -#define NS_KEY_EXTENDED_FLAGS 0x1000 -#define NS_KEY_NAME_ENTITY 0x0200 -#define NS_KEY_NAME_RESERVED 0x0300 -#define NS_KEY_NAME_TYPE 0x0300 -#define NS_KEY_NAME_USER 0x0000 -#define NS_KEY_NAME_ZONE 0x0100 -#define NS_KEY_NO_AUTH 0x8000 -#define NS_KEY_NO_CONF 0x4000 -#define NS_KEY_PROT_ANY 255 -#define NS_KEY_PROT_DNSSEC 3 -#define NS_KEY_PROT_EMAIL 2 -#define NS_KEY_PROT_IPSEC 4 -#define NS_KEY_PROT_TLS 1 -#define NS_KEY_RESERVED10 0x0020 -#define NS_KEY_RESERVED11 0x0010 -#define NS_KEY_RESERVED2 0x2000 -#define NS_KEY_RESERVED4 0x0800 -#define NS_KEY_RESERVED5 0x0400 -#define NS_KEY_RESERVED8 0x0080 -#define NS_KEY_RESERVED9 0x0040 -#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) -#define NS_KEY_RESERVED_BITMASK2 0xFFFF -#define NS_KEY_SIGNATORYMASK 0x000F -#define NS_KEY_TYPEMASK 0xC000 -#define NS_KEY_TYPE_AUTH_CONF 0x0000 -#define NS_KEY_TYPE_AUTH_ONLY 0x4000 -#define NS_KEY_TYPE_CONF_ONLY 0x8000 -#define NS_KEY_TYPE_NO_KEY 0xC000 -#define NS_MAXCDNAME 255 -#define NS_MAXDNAME 1025 -#define NS_MAXLABEL 63 -#define NS_MAXMSG 65535 -#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) -#define NS_MD5RSA_MAX_BITS 4096 -#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) -#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) -#define NS_MD5RSA_MIN_BITS 512 -#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) -#define NS_NOTIFY_OP ns_o_notify -#define NS_NXT_BITS 8 -#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_MAX 127 -#define NS_OPT_DNSSEC_OK 0x8000U -#define NS_OPT_NSID 3 -#define NS_PACKETSZ 512 -#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) -#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) -#define NS_QFIXEDSZ 4 -#define NS_RRFIXEDSZ 10 -#define NS_SIG_ALG 2 -#define NS_SIG_EXPIR 8 -#define NS_SIG_FOOT 16 -#define NS_SIG_LABELS 3 -#define NS_SIG_OTTL 4 -#define NS_SIG_SIGNED 12 -#define NS_SIG_SIGNER 18 -#define NS_SIG_TYPE 0 -#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" -#define NS_TSIG_ERROR_FORMERR -12 -#define NS_TSIG_ERROR_NO_SPACE -11 -#define NS_TSIG_ERROR_NO_TSIG -10 -#define NS_TSIG_FUDGE 300 -#define NS_TSIG_TCP_COUNT 100 -#define NS_UPDATE_OP ns_o_update -#define NTELOPTS (1+TELOPT_NEW_ENVIRON) -#define NULL ((void*)0) -#define NXDOMAIN ns_r_nxdomain -#define NXRRSET ns_r_nxrrset -#define NZERO 20 -#define OLD_ENV_VALUE 0 -#define OLD_ENV_VAR 1 -#define ONCE_FLAG_INIT 0 -#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) -#define O_APPEND __WASI_FDFLAGS_APPEND -#define O_CLOEXEC (0) -#define O_CREAT (__WASI_OFLAGS_CREAT << 12) -#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) -#define O_DSYNC __WASI_FDFLAGS_DSYNC -#define O_EXCL (__WASI_OFLAGS_EXCL << 12) -#define O_EXEC (0x02000000) -#define O_NOCTTY (0) -#define O_NOFOLLOW (0x01000000) -#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK -#define O_RDONLY (0x04000000) -#define O_RDWR (O_RDONLY | O_WRONLY) -#define O_RSYNC __WASI_FDFLAGS_RSYNC -#define O_SEARCH (0x08000000) -#define O_SYNC __WASI_FDFLAGS_SYNC -#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) -#define O_TTY_INIT (0) -#define O_WRONLY (0x10000000) -#define PACKETSZ NS_PACKETSZ -#define PACKET_ADD_MEMBERSHIP 1 -#define PACKET_AUXDATA 8 -#define PACKET_BROADCAST 1 -#define PACKET_COPY_THRESH 7 -#define PACKET_DROP_MEMBERSHIP 2 -#define PACKET_FANOUT 18 -#define PACKET_FANOUT_DATA 22 -#define PACKET_FASTROUTE 6 -#define PACKET_HDRLEN 11 -#define PACKET_HOST 0 -#define PACKET_IGNORE_OUTGOING 23 -#define PACKET_LOOPBACK 5 -#define PACKET_LOSS 14 -#define PACKET_MR_ALLMULTI 2 -#define PACKET_MR_MULTICAST 0 -#define PACKET_MR_PROMISC 1 -#define PACKET_MR_UNICAST 3 -#define PACKET_MULTICAST 2 -#define PACKET_ORIGDEV 9 -#define PACKET_OTHERHOST 3 -#define PACKET_OUTGOING 4 -#define PACKET_QDISC_BYPASS 20 -#define PACKET_RECV_OUTPUT 3 -#define PACKET_RESERVE 12 -#define PACKET_ROLLOVER_STATS 21 -#define PACKET_RX_RING 5 -#define PACKET_STATISTICS 6 -#define PACKET_TIMESTAMP 17 -#define PACKET_TX_HAS_OFF 19 -#define PACKET_TX_RING 13 -#define PACKET_TX_TIMESTAMP 16 -#define PACKET_VERSION 10 -#define PACKET_VNET_HDR 15 -#define PAGESIZE (0x10000) -#define PAGE_SIZE PAGESIZE -#define PATH_MAX 4096 -#define PDP_ENDIAN __PDP_ENDIAN -#define PF_INET 1 -#define PF_INET6 2 -#define PF_UNSPEC 0 -#define PM_STR 0x20027 -#define POLLERR 0x1000 -#define POLLHUP 0x2000 -#define POLLIN POLLRDNORM -#define POLLNVAL 0x4000 -#define POLLOUT POLLWRNORM -#define POLLRDNORM 0x1 -#define POLLWRNORM 0x2 -#define POSIX_CLOSE_RESTART 0 -#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED -#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE -#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL -#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM -#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL -#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED -#define PRELIM 1 -#define PRIX16 __UINT16_FMTX__ -#define PRIX32 __UINT32_FMTX__ -#define PRIX64 __UINT64_FMTX__ -#define PRIX8 __UINT8_FMTX__ -#define PRIXFAST16 __UINT_FAST16_FMTX__ -#define PRIXFAST32 __UINT_FAST32_FMTX__ -#define PRIXFAST64 __UINT_FAST64_FMTX__ -#define PRIXFAST8 __UINT_FAST8_FMTX__ -#define PRIXLEAST16 __UINT_LEAST16_FMTX__ -#define PRIXLEAST32 __UINT_LEAST32_FMTX__ -#define PRIXLEAST64 __UINT_LEAST64_FMTX__ -#define PRIXLEAST8 __UINT_LEAST8_FMTX__ -#define PRIXMAX __UINTMAX_FMTX__ -#define PRIXPTR __UINTPTR_FMTX__ -#define PRId16 __INT16_FMTd__ -#define PRId32 __INT32_FMTd__ -#define PRId64 __INT64_FMTd__ -#define PRId8 __INT8_FMTd__ -#define PRIdFAST16 __INT_FAST16_FMTd__ -#define PRIdFAST32 __INT_FAST32_FMTd__ -#define PRIdFAST64 __INT_FAST64_FMTd__ -#define PRIdFAST8 __INT_FAST8_FMTd__ -#define PRIdLEAST16 __INT_LEAST16_FMTd__ -#define PRIdLEAST32 __INT_LEAST32_FMTd__ -#define PRIdLEAST64 __INT_LEAST64_FMTd__ -#define PRIdLEAST8 __INT_LEAST8_FMTd__ -#define PRIdMAX __INTMAX_FMTd__ -#define PRIdPTR __INTPTR_FMTd__ -#define PRIi16 __INT16_FMTi__ -#define PRIi32 __INT32_FMTi__ -#define PRIi64 __INT64_FMTi__ -#define PRIi8 __INT8_FMTi__ -#define PRIiFAST16 __INT_FAST16_FMTi__ -#define PRIiFAST32 __INT_FAST32_FMTi__ -#define PRIiFAST64 __INT_FAST64_FMTi__ -#define PRIiFAST8 __INT_FAST8_FMTi__ -#define PRIiLEAST16 __INT_LEAST16_FMTi__ -#define PRIiLEAST32 __INT_LEAST32_FMTi__ -#define PRIiLEAST64 __INT_LEAST64_FMTi__ -#define PRIiLEAST8 __INT_LEAST8_FMTi__ -#define PRIiMAX __INTMAX_FMTi__ -#define PRIiPTR __INTPTR_FMTi__ -#define PRIo16 __UINT16_FMTo__ -#define PRIo32 __UINT32_FMTo__ -#define PRIo64 __UINT64_FMTo__ -#define PRIo8 __UINT8_FMTo__ -#define PRIoFAST16 __UINT_FAST16_FMTo__ -#define PRIoFAST32 __UINT_FAST32_FMTo__ -#define PRIoFAST64 __UINT_FAST64_FMTo__ -#define PRIoFAST8 __UINT_FAST8_FMTo__ -#define PRIoLEAST16 __UINT_LEAST16_FMTo__ -#define PRIoLEAST32 __UINT_LEAST32_FMTo__ -#define PRIoLEAST64 __UINT_LEAST64_FMTo__ -#define PRIoLEAST8 __UINT_LEAST8_FMTo__ -#define PRIoMAX __UINTMAX_FMTo__ -#define PRIoPTR __UINTPTR_FMTo__ -#define PRIu16 __UINT16_FMTu__ -#define PRIu32 __UINT32_FMTu__ -#define PRIu64 __UINT64_FMTu__ -#define PRIu8 __UINT8_FMTu__ -#define PRIuFAST16 __UINT_FAST16_FMTu__ -#define PRIuFAST32 __UINT_FAST32_FMTu__ -#define PRIuFAST64 __UINT_FAST64_FMTu__ -#define PRIuFAST8 __UINT_FAST8_FMTu__ -#define PRIuLEAST16 __UINT_LEAST16_FMTu__ -#define PRIuLEAST32 __UINT_LEAST32_FMTu__ -#define PRIuLEAST64 __UINT_LEAST64_FMTu__ -#define PRIuLEAST8 __UINT_LEAST8_FMTu__ -#define PRIuMAX __UINTMAX_FMTu__ -#define PRIuPTR __UINTPTR_FMTu__ -#define PRIx16 __UINT16_FMTx__ -#define PRIx32 __UINT32_FMTx__ -#define PRIx64 __UINT64_FMTx__ -#define PRIx8 __UINT8_FMTx__ -#define PRIxFAST16 __UINT_FAST16_FMTx__ -#define PRIxFAST32 __UINT_FAST32_FMTx__ -#define PRIxFAST64 __UINT_FAST64_FMTx__ -#define PRIxFAST8 __UINT_FAST8_FMTx__ -#define PRIxLEAST16 __UINT_LEAST16_FMTx__ -#define PRIxLEAST32 __UINT_LEAST32_FMTx__ -#define PRIxLEAST64 __UINT_LEAST64_FMTx__ -#define PRIxLEAST8 __UINT_LEAST8_FMTx__ -#define PRIxMAX __UINTMAX_FMTx__ -#define PRIxPTR __UINTPTR_FMTx__ -#define PTHREAD_BARRIER_SERIAL_THREAD (-1) -#define PTHREAD_CANCELED ((void *)-1) -#define PTHREAD_CANCEL_ASYNCHRONOUS 1 -#define PTHREAD_CANCEL_DEFERRED 0 -#define PTHREAD_CANCEL_DISABLE 1 -#define PTHREAD_CANCEL_ENABLE 0 -#define PTHREAD_CANCEL_MASKED 2 -#define PTHREAD_COND_INITIALIZER {{{0}}} -#define PTHREAD_CREATE_DETACHED 1 -#define PTHREAD_CREATE_JOINABLE 0 -#define PTHREAD_DESTRUCTOR_ITERATIONS 4 -#define PTHREAD_EXPLICIT_SCHED 1 -#define PTHREAD_INHERIT_SCHED 0 -#define PTHREAD_KEYS_MAX 128 -#define PTHREAD_MUTEX_DEFAULT 0 -#define PTHREAD_MUTEX_ERRORCHECK 2 -#define PTHREAD_MUTEX_INITIALIZER {{{0}}} -#define PTHREAD_MUTEX_NORMAL 0 -#define PTHREAD_MUTEX_RECURSIVE 1 -#define PTHREAD_MUTEX_ROBUST 1 -#define PTHREAD_MUTEX_STALLED 0 -#define PTHREAD_NULL ((pthread_t)0) -#define PTHREAD_ONCE_INIT 0 -#define PTHREAD_PRIO_INHERIT 1 -#define PTHREAD_PRIO_NONE 0 -#define PTHREAD_PRIO_PROTECT 2 -#define PTHREAD_PROCESS_PRIVATE 0 -#define PTHREAD_PROCESS_SHARED 1 -#define PTHREAD_RWLOCK_INITIALIZER {{{0}}} -#define PTHREAD_SCOPE_PROCESS 1 -#define PTHREAD_SCOPE_SYSTEM 0 -#define PTHREAD_STACK_MIN 2048 -#define PTRBITS (sizeof(char *) * 8) -#define PTRDIFF_MAX INT32_MAX -#define PTRDIFF_MIN INT32_MIN -#define PUTLONG NS_PUT32 -#define PUTSHORT NS_PUT16 -#define QFIXEDSZ NS_QFIXEDSZ -#define QUERY ns_o_query -#define RADIXCHAR 0x10000 -#define RAND_MAX (0x7fffffff) -#define REC_EOF '\002' -#define REC_EOR '\001' -#define REC_ESC '\377' -#define REFUSED ns_r_refused -#define REGTYPE '0' -#define REG_BADBR 10 -#define REG_BADPAT 2 -#define REG_BADRPT 13 -#define REG_EBRACE 9 -#define REG_EBRACK 7 -#define REG_ECOLLATE 3 -#define REG_ECTYPE 4 -#define REG_EESCAPE 5 -#define REG_ENOSYS -1 -#define REG_EPAREN 8 -#define REG_ERANGE 11 -#define REG_ESPACE 12 -#define REG_ESUBREG 6 -#define REG_EXTENDED 1 -#define REG_ICASE 2 -#define REG_NEWLINE 4 -#define REG_NOMATCH 1 -#define REG_NOSUB 8 -#define REG_NOTBOL 1 -#define REG_NOTEOL 2 -#define REG_OK 0 -#define RE_DUP_MAX 255 -#define RMSGD 0x0001 -#define RMSGN 0x0002 -#define RNORM 0x0000 -#define RPM_PCO_ADD 1 -#define RPM_PCO_CHANGE 2 -#define RPM_PCO_SETGLOBAL 3 -#define RPROTDAT 0x0004 -#define RPROTDIS 0x0008 -#define RPROTMASK 0x001C -#define RPROTNORM 0x0010 -#define RRFIXEDSZ NS_RRFIXEDSZ -#define RRQ 01 -#define RS_HIPRI 0x01 -#define RTLD_DEFAULT ((void *)0) -#define RTLD_GLOBAL 256 -#define RTLD_LAZY 1 -#define RTLD_LOCAL 8 -#define RTLD_NEXT ((void *)-1) -#define RTLD_NODELETE 4096 -#define RTLD_NOLOAD 4 -#define RTLD_NOW 2 -#define RUSAGE_CHILDREN 2 -#define RUSAGE_SELF 1 -#define R_OK (4) -#define SARMAG 8 -#define SB 250 -#define SCHAR_MAX 127 -#define SCHAR_MIN (-128) -#define SCNd16 __INT16_FMTd__ -#define SCNd32 __INT32_FMTd__ -#define SCNd64 __INT64_FMTd__ -#define SCNd8 __INT8_FMTd__ -#define SCNdFAST16 __INT_FAST16_FMTd__ -#define SCNdFAST32 __INT_FAST32_FMTd__ -#define SCNdFAST64 __INT_FAST64_FMTd__ -#define SCNdFAST8 __INT_FAST8_FMTd__ -#define SCNdLEAST16 __INT_LEAST16_FMTd__ -#define SCNdLEAST32 __INT_LEAST32_FMTd__ -#define SCNdLEAST64 __INT_LEAST64_FMTd__ -#define SCNdLEAST8 __INT_LEAST8_FMTd__ -#define SCNdMAX __INTMAX_FMTd__ -#define SCNdPTR __INTPTR_FMTd__ -#define SCNi16 __INT16_FMTi__ -#define SCNi32 __INT32_FMTi__ -#define SCNi64 __INT64_FMTi__ -#define SCNi8 __INT8_FMTi__ -#define SCNiFAST16 __INT_FAST16_FMTi__ -#define SCNiFAST32 __INT_FAST32_FMTi__ -#define SCNiFAST64 __INT_FAST64_FMTi__ -#define SCNiFAST8 __INT_FAST8_FMTi__ -#define SCNiLEAST16 __INT_LEAST16_FMTi__ -#define SCNiLEAST32 __INT_LEAST32_FMTi__ -#define SCNiLEAST64 __INT_LEAST64_FMTi__ -#define SCNiLEAST8 __INT_LEAST8_FMTi__ -#define SCNiMAX __INTMAX_FMTi__ -#define SCNiPTR __INTPTR_FMTi__ -#define SCNo16 __UINT16_FMTo__ -#define SCNo32 __UINT32_FMTo__ -#define SCNo64 __UINT64_FMTo__ -#define SCNo8 __UINT8_FMTo__ -#define SCNoFAST16 __UINT_FAST16_FMTo__ -#define SCNoFAST32 __UINT_FAST32_FMTo__ -#define SCNoFAST64 __UINT_FAST64_FMTo__ -#define SCNoFAST8 __UINT_FAST8_FMTo__ -#define SCNoLEAST16 __UINT_LEAST16_FMTo__ -#define SCNoLEAST32 __UINT_LEAST32_FMTo__ -#define SCNoLEAST64 __UINT_LEAST64_FMTo__ -#define SCNoLEAST8 __UINT_LEAST8_FMTo__ -#define SCNoMAX __UINTMAX_FMTo__ -#define SCNoPTR __UINTPTR_FMTo__ -#define SCNu16 __UINT16_FMTu__ -#define SCNu32 __UINT32_FMTu__ -#define SCNu64 __UINT64_FMTu__ -#define SCNu8 __UINT8_FMTu__ -#define SCNuFAST16 __UINT_FAST16_FMTu__ -#define SCNuFAST32 __UINT_FAST32_FMTu__ -#define SCNuFAST64 __UINT_FAST64_FMTu__ -#define SCNuFAST8 __UINT_FAST8_FMTu__ -#define SCNuLEAST16 __UINT_LEAST16_FMTu__ -#define SCNuLEAST32 __UINT_LEAST32_FMTu__ -#define SCNuLEAST64 __UINT_LEAST64_FMTu__ -#define SCNuLEAST8 __UINT_LEAST8_FMTu__ -#define SCNuMAX __UINTMAX_FMTu__ -#define SCNuPTR __UINTPTR_FMTu__ -#define SCNx16 __UINT16_FMTx__ -#define SCNx32 __UINT32_FMTx__ -#define SCNx64 __UINT64_FMTx__ -#define SCNx8 __UINT8_FMTx__ -#define SCNxFAST16 __UINT_FAST16_FMTx__ -#define SCNxFAST32 __UINT_FAST32_FMTx__ -#define SCNxFAST64 __UINT_FAST64_FMTx__ -#define SCNxFAST8 __UINT_FAST8_FMTx__ -#define SCNxLEAST16 __UINT_LEAST16_FMTx__ -#define SCNxLEAST32 __UINT_LEAST32_FMTx__ -#define SCNxLEAST64 __UINT_LEAST64_FMTx__ -#define SCNxLEAST8 __UINT_LEAST8_FMTx__ -#define SCNxMAX __UINTMAX_FMTx__ -#define SCNxPTR __UINTPTR_FMTx__ -#define SE 240 -#define SEEK_CUR __WASI_WHENCE_CUR -#define SEEK_END __WASI_WHENCE_END -#define SEEK_SET __WASI_WHENCE_SET -#define SEGSIZE 512 -#define SEM_FAILED ((sem_t *)0) -#define SEM_NSEMS_MAX 256 -#define SEM_VALUE_MAX 0x7fffffff -#define SERVFAIL ns_r_servfail -#define SHORTBITS (sizeof(short) * 8) -#define SHRT_MAX 0x7fff -#define SHRT_MIN (-1-0x7fff) -#define SHUT_RD __WASI_SDFLAGS_RD -#define SHUT_RDWR (SHUT_RD | SHUT_WR) -#define SHUT_WR __WASI_SDFLAGS_WR -#define SIG_ATOMIC_MAX INT32_MAX -#define SIG_ATOMIC_MIN INT32_MIN -#define SIZE_MAX UINT32_MAX -#define SI_LOAD_SHIFT 16 -#define SLC_ABORT 7 -#define SLC_ACK 0x80 -#define SLC_AO 4 -#define SLC_AYT 5 -#define SLC_BRK 2 -#define SLC_CANTCHANGE 1 -#define SLC_DEFAULT 3 -#define SLC_EC 10 -#define SLC_EL 11 -#define SLC_EOF 8 -#define SLC_EOR 6 -#define SLC_EW 12 -#define SLC_FLAGS 1 -#define SLC_FLUSHIN 0x40 -#define SLC_FLUSHOUT 0x20 -#define SLC_FORW1 17 -#define SLC_FORW2 18 -#define SLC_FUNC 0 -#define SLC_IP 3 -#define SLC_LEVELBITS 0x03 -#define SLC_LNEXT 14 -#define SLC_NAME(x) slc_names[x] -#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, -#define SLC_NAMES SLC_NAMELIST -#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) -#define SLC_NOSUPPORT 0 -#define SLC_RP 13 -#define SLC_SUSP 9 -#define SLC_SYNCH 1 -#define SLC_VALUE 2 -#define SLC_VARIABLE 2 -#define SLC_XOFF 16 -#define SLC_XON 15 -#define SNDPIPE 0x002 -#define SNDZERO 0x001 -#define SOCK_CLOEXEC (0x00002000) -#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM -#define SOCK_NONBLOCK (0x00004000) -#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM -#define SOL_SOCKET 0x7fffffff -#define SOL_TCP 6 -#define SOL_UDP 17 -#define SO_TYPE 3 -#define SSIZE_MAX LONG_MAX -#define STATUS ns_o_status -#define STA_CLK 0x8000 -#define STA_CLOCKERR 0x1000 -#define STA_DEL 0x0020 -#define STA_FLL 0x0008 -#define STA_FREQHOLD 0x0080 -#define STA_INS 0x0010 -#define STA_MODE 0x4000 -#define STA_NANO 0x2000 -#define STA_PLL 0x0001 -#define STA_PPSERROR 0x0800 -#define STA_PPSFREQ 0x0002 -#define STA_PPSJITTER 0x0200 -#define STA_PPSSIGNAL 0x0100 -#define STA_PPSTIME 0x0004 -#define STA_PPSWANDER 0x0400 -#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) -#define STA_UNSYNC 0x0040 -#define STDERR_FILENO 2 -#define STDIN_FILENO 0 -#define STDOUT_FILENO 1 -#define STRU_F 1 -#define STRU_P 3 -#define STRU_R 2 -#define ST_APPEND 256 -#define ST_IMMUTABLE 512 -#define ST_MANDLOCK 64 -#define ST_NOATIME 1024 -#define ST_NODEV 4 -#define ST_NODIRATIME 2048 -#define ST_NOEXEC 8 -#define ST_NOSUID 2 -#define ST_RDONLY 1 -#define ST_RELATIME 4096 -#define ST_SYNCHRONOUS 16 -#define ST_WRITE 128 -#define SUN_LEN(s) (2+strlen((s)->sun_path)) -#define SUSP 237 -#define SYMLOOP_MAX 40 -#define SYMTYPE '2' -#define SYNCH 242 -#define S_ADDT ns_s_ar -#define S_BANDURG 0x0200 -#define S_ERROR 0x0010 -#define S_HANGUP 0x0020 -#define S_HIPRI 0x0002 -#define S_IEXEC S_IXUSR -#define S_IFBLK (0x6000) -#define S_IFCHR (0x2000) -#define S_IFDIR (0x4000) -#define S_IFIFO (0x1000) -#define S_IFLNK (0xa000) -#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) -#define S_IFREG (0x8000) -#define S_IFSOCK (0xc000) -#define S_INPUT 0x0001 -#define S_IREAD S_IRUSR -#define S_IRGRP (0x20) -#define S_IROTH (0x4) -#define S_IRUSR (0x100) -#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) -#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) -#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) -#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) -#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) -#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) -#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) -#define S_ISGID (0x400) -#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) -#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) -#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) -#define S_ISUID (0x800) -#define S_ISVTX (0x200) -#define S_IWGRP (0x10) -#define S_IWOTH (0x2) -#define S_IWRITE S_IWUSR -#define S_IWUSR (0x80) -#define S_IXGRP (0x8) -#define S_IXOTH (0x1) -#define S_IXUSR (0x40) -#define S_MSG 0x0008 -#define S_OUTPUT 0x0004 -#define S_PREREQ ns_s_pr -#define S_RDBAND 0x0080 -#define S_RDNORM 0x0040 -#define S_UPDATE ns_s_ud -#define S_WRBAND 0x0100 -#define S_WRNORM S_OUTPUT -#define S_ZONE ns_s_zn -#define TCPI_OPT_ECN 8 -#define TCPI_OPT_SACK 2 -#define TCPI_OPT_TIMESTAMPS 1 -#define TCPI_OPT_WSCALE 4 -#define TCPOLEN_MAXSEG 4 -#define TCPOLEN_SACK_PERMITTED 2 -#define TCPOLEN_TIMESTAMP 10 -#define TCPOLEN_WINDOW 3 -#define TCPOPT_EOL 0 -#define TCPOPT_MAXSEG 2 -#define TCPOPT_NOP 1 -#define TCPOPT_SACK 5 -#define TCPOPT_SACK_PERMITTED 4 -#define TCPOPT_TIMESTAMP 8 -#define TCPOPT_WINDOW 3 -#define TCP_CA_CWR 2 -#define TCP_CA_Disorder 1 -#define TCP_CA_Loss 4 -#define TCP_CA_Open 0 -#define TCP_CA_Recovery 3 -#define TCP_CC_INFO 26 -#define TCP_CLOSE 7 -#define TCP_CLOSE_WAIT 8 -#define TCP_CLOSING 11 -#define TCP_CM_INQ TCP_INQ -#define TCP_CONGESTION 13 -#define TCP_CORK 3 -#define TCP_DEFER_ACCEPT 9 -#define TCP_ENCAP_ESPINTCP 7 -#define TCP_ESTABLISHED 1 -#define TCP_FASTOPEN 23 -#define TCP_FASTOPEN_CONNECT 30 -#define TCP_FASTOPEN_KEY 33 -#define TCP_FASTOPEN_NO_COOKIE 34 -#define TCP_FIN_WAIT1 4 -#define TCP_FIN_WAIT2 5 -#define TCP_INFO 11 -#define TCP_INQ 36 -#define TCP_KEEPCNT 6 -#define TCP_KEEPIDLE 4 -#define TCP_KEEPINTVL 5 -#define TCP_LAST_ACK 9 -#define TCP_LINGER2 8 -#define TCP_LISTEN 10 -#define TCP_MAXSEG 2 -#define TCP_MD5SIG 14 -#define TCP_MD5SIG_EXT 32 -#define TCP_MD5SIG_FLAG_IFINDEX 0x2 -#define TCP_MD5SIG_FLAG_PREFIX 0x1 -#define TCP_MD5SIG_MAXKEYLEN 80 -#define TCP_NODELAY 1 -#define TCP_NOTSENT_LOWAT 25 -#define TCP_QUEUE_SEQ 21 -#define TCP_QUICKACK 12 -#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 -#define TCP_REPAIR 19 -#define TCP_REPAIR_OFF 0 -#define TCP_REPAIR_OFF_NO_WP -1 -#define TCP_REPAIR_ON 1 -#define TCP_REPAIR_OPTIONS 22 -#define TCP_REPAIR_QUEUE 20 -#define TCP_REPAIR_WINDOW 29 -#define TCP_SAVED_SYN 28 -#define TCP_SAVE_SYN 27 -#define TCP_SYNCNT 7 -#define TCP_SYN_RECV 3 -#define TCP_SYN_SENT 2 -#define TCP_THIN_DUPACK 17 -#define TCP_THIN_LINEAR_TIMEOUTS 16 -#define TCP_TIMESTAMP 24 -#define TCP_TIME_WAIT 6 -#define TCP_TX_DELAY 37 -#define TCP_ULP 31 -#define TCP_USER_TIMEOUT 18 -#define TCP_WINDOW_CLAMP 10 -#define TCP_ZEROCOPY_RECEIVE 35 -#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] -#define TELCMD_FIRST xEOF -#define TELCMD_LAST IAC -#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) -#define TELOPT_3270REGIME 29 -#define TELOPT_AUTHENTICATION 37 -#define TELOPT_BINARY 0 -#define TELOPT_BM 19 -#define TELOPT_DET 20 -#define TELOPT_ECHO 1 -#define TELOPT_ENCRYPT 38 -#define TELOPT_EOR 25 -#define TELOPT_EXOPL 255 -#define TELOPT_LFLOW 33 -#define TELOPT_LINEMODE 34 -#define TELOPT_LOGOUT 18 -#define TELOPT_NAMS 4 -#define TELOPT_NAOCRD 10 -#define TELOPT_NAOFFD 13 -#define TELOPT_NAOHTD 12 -#define TELOPT_NAOHTS 11 -#define TELOPT_NAOL 8 -#define TELOPT_NAOLFD 16 -#define TELOPT_NAOP 9 -#define TELOPT_NAOVTD 15 -#define TELOPT_NAOVTS 14 -#define TELOPT_NAWS 31 -#define TELOPT_NEW_ENVIRON 39 -#define TELOPT_OLD_ENVIRON 36 -#define TELOPT_OUTMRK 27 -#define TELOPT_RCP 2 -#define TELOPT_RCTE 7 -#define TELOPT_SGA 3 -#define TELOPT_SNDLOC 23 -#define TELOPT_STATUS 5 -#define TELOPT_SUPDUP 21 -#define TELOPT_SUPDUPOUTPUT 22 -#define TELOPT_TM 6 -#define TELOPT_TSPEED 32 -#define TELOPT_TTYLOC 28 -#define TELOPT_TTYPE 24 -#define TELOPT_TUID 26 -#define TELOPT_X3PAD 30 -#define TELOPT_XASCII 17 -#define TELOPT_XDISPLOC 35 -#define TELQUAL_INFO 2 -#define TELQUAL_IS 0 -#define TELQUAL_NAME 3 -#define TELQUAL_REPLY 2 -#define TELQUAL_SEND 1 -#define TGEXEC 00010 -#define TGREAD 00040 -#define TGWRITE 00020 -#define THOUSEP 0x10001 -#define TH_ACK 0x10 -#define TH_FIN 0x01 -#define TH_PUSH 0x08 -#define TH_RST 0x04 -#define TH_SYN 0x02 -#define TH_URG 0x20 -#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME -#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) -#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) -#define TIME_BAD TIME_ERROR -#define TIME_DEL 2 -#define TIME_ERROR 5 -#define TIME_INS 1 -#define TIME_OK 0 -#define TIME_OOP 3 -#define TIME_UTC 1 -#define TIME_WAIT 4 -#define TMAGIC "ustar" -#define TMAGLEN 6 -#define TOEXEC 00001 -#define TOREAD 00004 -#define TOWRITE 00002 -#define TRANSIENT 4 -#define TSGID 02000 -#define TSS_DTOR_ITERATIONS 4 -#define TSUID 04000 -#define TSVTX 01000 -#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) -#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) -#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) -#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) -#define TTYDEF_SPEED (B9600) -#define TTY_NAME_MAX 32 -#define TUEXEC 00100 -#define TUREAD 00400 -#define TUWRITE 00200 -#define TVERSION "00" -#define TVERSLEN 2 -#define TYPE_A 1 -#define TYPE_E 2 -#define TYPE_I 3 -#define TYPE_L 4 -#define TZNAME_MAX 6 -#define T_A ns_t_a -#define T_A6 ns_t_a6 -#define T_AAAA ns_t_aaaa -#define T_AFSDB ns_t_afsdb -#define T_ANY ns_t_any -#define T_ATMA ns_t_atma -#define T_AXFR ns_t_axfr -#define T_CNAME ns_t_cname -#define T_DNAME ns_t_dname -#define T_EID ns_t_eid -#define T_FMT 0x2002A -#define T_FMT_AMPM 0x2002B -#define T_GPOS ns_t_gpos -#define T_HINFO ns_t_hinfo -#define T_ISDN ns_t_isdn -#define T_IXFR ns_t_ixfr -#define T_KEY ns_t_key -#define T_LOC ns_t_loc -#define T_MAILA ns_t_maila -#define T_MAILB ns_t_mailb -#define T_MB ns_t_mb -#define T_MD ns_t_md -#define T_MF ns_t_mf -#define T_MG ns_t_mg -#define T_MINFO ns_t_minfo -#define T_MR ns_t_mr -#define T_MX ns_t_mx -#define T_NAPTR ns_t_naptr -#define T_NIMLOC ns_t_nimloc -#define T_NS ns_t_ns -#define T_NSAP ns_t_nsap -#define T_NSAP_PTR ns_t_nsap_ptr -#define T_NULL ns_t_null -#define T_NXT ns_t_nxt -#define T_PTR ns_t_ptr -#define T_PX ns_t_px -#define T_RP ns_t_rp -#define T_RT ns_t_rt -#define T_SIG ns_t_sig -#define T_SOA ns_t_soa -#define T_SRV ns_t_srv -#define T_TSIG ns_t_tsig -#define T_TXT ns_t_txt -#define T_WKS ns_t_wks -#define T_X25 ns_t_x25 -#define UCHAR_MAX 255 -#define UDP_CORK 1 -#define UDP_ENCAP 100 -#define UDP_ENCAP_ESPINUDP 2 -#define UDP_ENCAP_ESPINUDP_NON_IKE 1 -#define UDP_ENCAP_GTP0 4 -#define UDP_ENCAP_GTP1U 5 -#define UDP_ENCAP_L2TPINUDP 3 -#define UDP_ENCAP_RXRPC 6 -#define UDP_GRO 104 -#define UDP_NO_CHECK6_RX 102 -#define UDP_NO_CHECK6_TX 101 -#define UDP_SEGMENT 103 -#define UINT16_C(c) c -#define UINT16_MAX (0xffff) -#define UINT32_C(c) c ## U -#define UINT32_MAX (0xffffffffu) -#define UINT64_C(c) c ## ULL -#define UINT64_MAX (0xffffffffffffffffu) -#define UINT8_C(c) c -#define UINT8_MAX (0xff) -#define UINTMAX_C(c) c ## ULL -#define UINTMAX_MAX UINT64_MAX -#define UINTPTR_MAX UINT32_MAX -#define UINT_FAST16_MAX UINT16_MAX -#define UINT_FAST32_MAX UINT32_MAX -#define UINT_FAST64_MAX UINT64_MAX -#define UINT_FAST8_MAX UINT8_MAX -#define UINT_LEAST16_MAX UINT16_MAX -#define UINT_LEAST32_MAX UINT32_MAX -#define UINT_LEAST64_MAX UINT64_MAX -#define UINT_LEAST8_MAX UINT8_MAX -#define UINT_MAX 0xffffffffU -#define UIO_MAXIOV 1024 -#define ULLONG_MAX (2ULL*LLONG_MAX+1) -#define ULONG_MAX (2UL*LONG_MAX+1) -#define USHRT_MAX 0xffff -#define UTIME_NOW (-1) -#define UTIME_OMIT (-2) -#define WCHAR_MAX (0x7fffffff+L'\0') -#define WCHAR_MIN (-1-0x7fffffff+L'\0') -#define WEOF 0xffffffffU -#define WILL 251 -#define WINT_MAX UINT32_MAX -#define WINT_MIN 0U -#define WONT 252 -#define WORD_BIT 32 -#define WRQ 02 -#define W_OK (2) -#define X_OK (1) -#define YESEXPR 0x50000 -#define YESSTR 0x50002 -#define YXDOMAIN ns_r_yxdomain -#define YXRRSET ns_r_yxrrset -#define _ALLOCA_H -#define _ALL_SOURCE 1 -#define _ARPA_FTP_H -#define _ARPA_INET_H -#define _ARPA_NAMESER_H -#define _ARPA_TELNET_H -#define _ARPA_TFTP_H -#define _AR_H -#define _BYTESWAP_H -#define _COMPLEX_H -#define _CPIO_H -#define _CRYPT_H -#define _CS_GNU_LIBC_VERSION 2 -#define _CS_GNU_LIBPTHREAD_VERSION 3 -#define _CS_PATH 0 -#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 -#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 -#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 -#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 -#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 -#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 -#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 -#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 -#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 -#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 -#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 -#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 -#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 -#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 -#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 -#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 -#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 -#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 -#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 -#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 -#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 -#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 -#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 -#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 -#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 -#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 -#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 -#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 -#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 -#define _CS_V6_ENV 1148 -#define _CS_V7_ENV 1149 -#define _CTYPE_H -#define _Complex_I (0.0f+1.0fi) -#define _DIRENT_H -#define _DIRENT_HAVE_D_TYPE -#define _DLFCN_H -#define _ENDIAN_H -#define _ERRNO_H -#define _ERR_H -#define _FCNTL_H -#define _FEATURES_H -#define _FENV_H -#define _FLOAT_H -#define _FMTMSG_H -#define _FNMATCH_H -#define _FTW_H -#define _GETOPT_H -#define _GLOB_H -#define _GNU_SOURCE 1 -#define _ICONV_H -#define _IFADDRS_H -#define _INTTYPES_H -#define _IOFBF 0 -#define _IOLBF 1 -#define _IONBF 2 -#define _ISO646_H -#define _LANGINFO_H -#define _LIBGEN_H -#define _LIMITS_H -#define _LOCALE_H -#define _LP64 1 -#define _MALLOC_H -#define _MATH_H -#define _MONETARY_H -#define _MQUEUE_H -#define _NETINET_ICMP6_H -#define _NETINET_IGMP_H -#define _NETINET_IN_H -#define _NETINET_IN_SYSTM_H -#define _NETINET_IP6_H -#define _NETINET_IP_H -#define _NETINET_IP_ICMP_H -#define _NETINET_TCP_H -#define _NETINET_UDP_H -#define _NETPACKET_PACKET_H -#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) -#define _NL_TYPES_H -#define _PC_2_SYMLINKS 20 -#define _PC_ALLOC_SIZE_MIN 18 -#define _PC_ASYNC_IO 10 -#define _PC_CHOWN_RESTRICTED 6 -#define _PC_FILESIZEBITS 13 -#define _PC_LINK_MAX 0 -#define _PC_MAX_CANON 1 -#define _PC_MAX_INPUT 2 -#define _PC_NAME_MAX 3 -#define _PC_NO_TRUNC 7 -#define _PC_PATH_MAX 4 -#define _PC_PIPE_BUF 5 -#define _PC_PRIO_IO 11 -#define _PC_REC_INCR_XFER_SIZE 14 -#define _PC_REC_MAX_XFER_SIZE 15 -#define _PC_REC_MIN_XFER_SIZE 16 -#define _PC_REC_XFER_ALIGN 17 -#define _PC_SOCK_MAXBUF 12 -#define _PC_SYMLINK_MAX 19 -#define _PC_SYNC_IO 9 -#define _PC_VDISABLE 8 -#define _POLL_H -#define _POSIX2_BC_BASE_MAX 99 -#define _POSIX2_BC_DIM_MAX 2048 -#define _POSIX2_BC_SCALE_MAX 99 -#define _POSIX2_BC_STRING_MAX 1000 -#define _POSIX2_CHARCLASS_NAME_MAX 14 -#define _POSIX2_COLL_WEIGHTS_MAX 2 -#define _POSIX2_C_BIND _POSIX_VERSION -#define _POSIX2_EXPR_NEST_MAX 32 -#define _POSIX2_LINE_MAX 2048 -#define _POSIX2_RE_DUP_MAX 255 -#define _POSIX2_VERSION _POSIX_VERSION -#define _POSIX_ADVISORY_INFO _POSIX_VERSION -#define _POSIX_AIO_LISTIO_MAX 2 -#define _POSIX_AIO_MAX 1 -#define _POSIX_ARG_MAX 4096 -#define _POSIX_BARRIERS _POSIX_VERSION -#define _POSIX_CHILD_MAX 25 -#define _POSIX_CHOWN_RESTRICTED 1 -#define _POSIX_CLOCKRES_MIN 20000000 -#define _POSIX_CLOCK_SELECTION _POSIX_VERSION -#define _POSIX_CPUTIME _POSIX_VERSION -#define _POSIX_DELAYTIMER_MAX 32 -#define _POSIX_FSYNC _POSIX_VERSION -#define _POSIX_HOST_NAME_MAX 255 -#define _POSIX_IPV6 _POSIX_VERSION -#define _POSIX_LINK_MAX 8 -#define _POSIX_LOGIN_NAME_MAX 9 -#define _POSIX_MAX_CANON 255 -#define _POSIX_MAX_INPUT 255 -#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION -#define _POSIX_MQ_OPEN_MAX 8 -#define _POSIX_MQ_PRIO_MAX 32 -#define _POSIX_NAME_MAX 14 -#define _POSIX_NGROUPS_MAX 8 -#define _POSIX_NO_TRUNC 1 -#define _POSIX_OPEN_MAX 20 -#define _POSIX_PATH_MAX 256 -#define _POSIX_PIPE_BUF 512 -#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION -#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION -#define _POSIX_REGEXP 1 -#define _POSIX_RE_DUP_MAX 255 -#define _POSIX_RTSIG_MAX 8 -#define _POSIX_SEM_NSEMS_MAX 256 -#define _POSIX_SEM_VALUE_MAX 32767 -#define _POSIX_SIGQUEUE_MAX 32 -#define _POSIX_SPIN_LOCKS _POSIX_VERSION -#define _POSIX_SSIZE_MAX 32767 -#define _POSIX_SS_REPL_MAX 4 -#define _POSIX_STREAM_MAX 8 -#define _POSIX_SYMLINK_MAX 255 -#define _POSIX_SYMLOOP_MAX 8 -#define _POSIX_THREADS _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION -#define _POSIX_THREAD_CPUTIME _POSIX_VERSION -#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 -#define _POSIX_THREAD_KEYS_MAX 128 -#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION -#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION -#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION -#define _POSIX_THREAD_THREADS_MAX 64 -#define _POSIX_TIMEOUTS _POSIX_VERSION -#define _POSIX_TIMERS _POSIX_VERSION -#define _POSIX_TIMER_MAX 32 -#define _POSIX_TRACE_EVENT_NAME_MAX 30 -#define _POSIX_TRACE_NAME_MAX 8 -#define _POSIX_TRACE_SYS_MAX 8 -#define _POSIX_TRACE_USER_EVENT_MAX 32 -#define _POSIX_TTY_NAME_MAX 9 -#define _POSIX_TZNAME_MAX 6 -#define _POSIX_V6_ILP32_OFFBIG (1) -#define _POSIX_V7_ILP32_OFFBIG (1) -#define _POSIX_VDISABLE 0 -#define _POSIX_VERSION 200809L -#define _PTHREAD_H -#define _PTRDIFF_T -#define _REENTRANT 1 -#define _REGEX_H -#define _SCHED_H -#define _SC_2_CHAR_TERM 95 -#define _SC_2_C_BIND 47 -#define _SC_2_C_DEV 48 -#define _SC_2_FORT_DEV 49 -#define _SC_2_FORT_RUN 50 -#define _SC_2_LOCALEDEF 52 -#define _SC_2_PBS 168 -#define _SC_2_PBS_ACCOUNTING 169 -#define _SC_2_PBS_CHECKPOINT 175 -#define _SC_2_PBS_LOCATE 170 -#define _SC_2_PBS_MESSAGE 171 -#define _SC_2_PBS_TRACK 172 -#define _SC_2_SW_DEV 51 -#define _SC_2_UPE 97 -#define _SC_2_VERSION 46 -#define _SC_ADVISORY_INFO 132 -#define _SC_AIO_LISTIO_MAX 23 -#define _SC_AIO_MAX 24 -#define _SC_AIO_PRIO_DELTA_MAX 25 -#define _SC_ARG_MAX 0 -#define _SC_ASYNCHRONOUS_IO 12 -#define _SC_ATEXIT_MAX 87 -#define _SC_AVPHYS_PAGES 86 -#define _SC_BARRIERS 133 -#define _SC_BC_BASE_MAX 36 -#define _SC_BC_DIM_MAX 37 -#define _SC_BC_SCALE_MAX 38 -#define _SC_BC_STRING_MAX 39 -#define _SC_CHILD_MAX 1 -#define _SC_CLK_TCK 2 -#define _SC_CLOCK_SELECTION 137 -#define _SC_COLL_WEIGHTS_MAX 40 -#define _SC_CPUTIME 138 -#define _SC_DELAYTIMER_MAX 26 -#define _SC_EXPR_NEST_MAX 42 -#define _SC_FSYNC 15 -#define _SC_GETGR_R_SIZE_MAX 69 -#define _SC_GETPW_R_SIZE_MAX 70 -#define _SC_HOST_NAME_MAX 180 -#define _SC_IOV_MAX 60 -#define _SC_IPV6 235 -#define _SC_JOB_CONTROL 7 -#define _SC_LINE_MAX 43 -#define _SC_LOGIN_NAME_MAX 71 -#define _SC_MAPPED_FILES 16 -#define _SC_MEMLOCK 17 -#define _SC_MEMLOCK_RANGE 18 -#define _SC_MEMORY_PROTECTION 19 -#define _SC_MESSAGE_PASSING 20 -#define _SC_MONOTONIC_CLOCK 149 -#define _SC_MQ_OPEN_MAX 27 -#define _SC_MQ_PRIO_MAX 28 -#define _SC_NGROUPS_MAX 3 -#define _SC_NPROCESSORS_CONF 83 -#define _SC_NPROCESSORS_ONLN 84 -#define _SC_NZERO 109 -#define _SC_OPEN_MAX 4 -#define _SC_PAGESIZE 30 -#define _SC_PAGE_SIZE 30 -#define _SC_PASS_MAX 88 -#define _SC_PHYS_PAGES 85 -#define _SC_PRIORITIZED_IO 13 -#define _SC_PRIORITY_SCHEDULING 10 -#define _SC_RAW_SOCKETS 236 -#define _SC_READER_WRITER_LOCKS 153 -#define _SC_REALTIME_SIGNALS 9 -#define _SC_REGEXP 155 -#define _SC_RE_DUP_MAX 44 -#define _SC_RTSIG_MAX 31 -#define _SC_SAVED_IDS 8 -#define _SC_SEMAPHORES 21 -#define _SC_SEM_NSEMS_MAX 32 -#define _SC_SEM_VALUE_MAX 33 -#define _SC_SHARED_MEMORY_OBJECTS 22 -#define _SC_SHELL 157 -#define _SC_SIGQUEUE_MAX 34 -#define _SC_SPAWN 159 -#define _SC_SPIN_LOCKS 154 -#define _SC_SPORADIC_SERVER 160 -#define _SC_SS_REPL_MAX 241 -#define _SC_STREAMS 174 -#define _SC_STREAM_MAX 5 -#define _SC_SYMLOOP_MAX 173 -#define _SC_SYNCHRONIZED_IO 14 -#define _SC_THREADS 67 -#define _SC_THREAD_ATTR_STACKADDR 77 -#define _SC_THREAD_ATTR_STACKSIZE 78 -#define _SC_THREAD_CPUTIME 139 -#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 -#define _SC_THREAD_KEYS_MAX 74 -#define _SC_THREAD_PRIORITY_SCHEDULING 79 -#define _SC_THREAD_PRIO_INHERIT 80 -#define _SC_THREAD_PRIO_PROTECT 81 -#define _SC_THREAD_PROCESS_SHARED 82 -#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 -#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 -#define _SC_THREAD_SAFE_FUNCTIONS 68 -#define _SC_THREAD_SPORADIC_SERVER 161 -#define _SC_THREAD_STACK_MIN 75 -#define _SC_THREAD_THREADS_MAX 76 -#define _SC_TIMEOUTS 164 -#define _SC_TIMERS 11 -#define _SC_TIMER_MAX 35 -#define _SC_TRACE 181 -#define _SC_TRACE_EVENT_FILTER 182 -#define _SC_TRACE_EVENT_NAME_MAX 242 -#define _SC_TRACE_INHERIT 183 -#define _SC_TRACE_LOG 184 -#define _SC_TRACE_NAME_MAX 243 -#define _SC_TRACE_SYS_MAX 244 -#define _SC_TRACE_USER_EVENT_MAX 245 -#define _SC_TTY_NAME_MAX 72 -#define _SC_TYPED_MEMORY_OBJECTS 165 -#define _SC_TZNAME_MAX 6 -#define _SC_UIO_MAXIOV 60 -#define _SC_V6_ILP32_OFF32 176 -#define _SC_V6_ILP32_OFFBIG 177 -#define _SC_V6_LP64_OFF64 178 -#define _SC_V6_LPBIG_OFFBIG 179 -#define _SC_V7_ILP32_OFF32 237 -#define _SC_V7_ILP32_OFFBIG 238 -#define _SC_V7_LP64_OFF64 239 -#define _SC_V7_LPBIG_OFFBIG 240 -#define _SC_VERSION 29 -#define _SC_XBS5_ILP32_OFF32 125 -#define _SC_XBS5_ILP32_OFFBIG 126 -#define _SC_XBS5_LP64_OFF64 127 -#define _SC_XBS5_LPBIG_OFFBIG 128 -#define _SC_XOPEN_CRYPT 92 -#define _SC_XOPEN_ENH_I18N 93 -#define _SC_XOPEN_LEGACY 129 -#define _SC_XOPEN_REALTIME 130 -#define _SC_XOPEN_REALTIME_THREADS 131 -#define _SC_XOPEN_SHM 94 -#define _SC_XOPEN_STREAMS 246 -#define _SC_XOPEN_UNIX 91 -#define _SC_XOPEN_VERSION 89 -#define _SC_XOPEN_XCU_VERSION 90 -#define _SC_XOPEN_XPG2 98 -#define _SC_XOPEN_XPG3 99 -#define _SC_XOPEN_XPG4 100 -#define _SEARCH_H -#define _SEMAPHORE_H -#define _SIZE_T -#define _STDALIGN_H -#define _STDBOOL_H -#define _STDC_PREDEF_H -#define _STDINT_H -#define _STDIO_EXT_H -#define _STDIO_H -#define _STDLIB_H -#define _STDNORETURN_H -#define _STRINGS_H -#define _STRING_H -#define _STROPTS_H -#define _SYSEXITS_H -#define _SYS_EVENTFD_H -#define _SYS_FILE_H -#define _SYS_IOCTL_H -#define _SYS_PARAM_H -#define _SYS_RANDOM_H -#define _SYS_REG_H -#define _SYS_SELECT_H -#define _SYS_SOCKET_H -#define _SYS_STATVFS_H -#define _SYS_STAT_H -#define _SYS_SYSCALL_H -#define _SYS_SYSINFO_H -#define _SYS_TIMEB_H -#define _SYS_TIMEX_H -#define _SYS_TIME_H -#define _SYS_TTYDEFAULTS_H -#define _SYS_TYPES_H -#define _SYS_UIO_H -#define _SYS_UN_H -#define _SYS_UTSNAME_H -#define _TAR_H -#define _TGMATH_H -#define _THREADS_H -#define _TIME_H -#define _UCHAR_H -#define _UNISTD_H -#define _UTIME_H -#define _VALUES_H -#define _VA_LIST -#define _WCHAR_H -#define _WCHAR_T -#define _WCTYPE_H -#define _WINT_T -#define _XOPEN_ENH_I18N 1 -#define _XOPEN_IOV_MAX 16 -#define _XOPEN_NAME_MAX 255 -#define _XOPEN_PATH_MAX 1024 -#define _XOPEN_UNIX 1 -#define _XOPEN_VERSION 700 -#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) -#define __ATOMIC_ACQUIRE 2 -#define __ATOMIC_ACQ_REL 4 -#define __ATOMIC_CONSUME 1 -#define __ATOMIC_RELAXED 0 -#define __ATOMIC_RELEASE 3 -#define __ATOMIC_SEQ_CST 5 -#define __BIGGEST_ALIGNMENT__ 16 -#define __BIG_ENDIAN 4321 -#define __BIND 19950621 -#define __BYTE_ORDER __BYTE_ORDER__ -#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ -#define __CHAR16_TYPE__ unsigned short -#define __CHAR32_TYPE__ unsigned int -#define __CHAR_BIT__ 8 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __CLANG_MAX_ALIGN_T_DEFINED -#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) -#define __CONSTANT_CFSTRINGS__ 1 -#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) -#define __DBL_DECIMAL_DIG__ 17 -#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 -#define __DBL_DIG__ 15 -#define __DBL_EPSILON__ 2.2204460492503131e-16 -#define __DBL_HAS_DENORM__ 1 -#define __DBL_HAS_INFINITY__ 1 -#define __DBL_HAS_QUIET_NAN__ 1 -#define __DBL_MANT_DIG__ 53 -#define __DBL_MAX_10_EXP__ 308 -#define __DBL_MAX_EXP__ 1024 -#define __DBL_MAX__ 1.7976931348623157e+308 -#define __DBL_MIN_10_EXP__ (-307) -#define __DBL_MIN_EXP__ (-1021) -#define __DBL_MIN__ 2.2250738585072014e-308 -#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ -#define __DEFINED_FILE -#define __DEFINED___isoc_va_list -#define __DEFINED_blkcnt_t -#define __DEFINED_blksize_t -#define __DEFINED_clock_t -#define __DEFINED_clockid_t -#define __DEFINED_cnd_t -#define __DEFINED_dev_t -#define __DEFINED_double_t -#define __DEFINED_float_t -#define __DEFINED_fsblkcnt_t -#define __DEFINED_fsfilcnt_t -#define __DEFINED_gid_t -#define __DEFINED_id_t -#define __DEFINED_ino_t -#define __DEFINED_int16_t -#define __DEFINED_int32_t -#define __DEFINED_int64_t -#define __DEFINED_int8_t -#define __DEFINED_intmax_t -#define __DEFINED_intptr_t -#define __DEFINED_key_t -#define __DEFINED_locale_t -#define __DEFINED_mbstate_t -#define __DEFINED_mode_t -#define __DEFINED_mtx_t -#define __DEFINED_nlink_t -#define __DEFINED_off_t -#define __DEFINED_pid_t -#define __DEFINED_pthread_attr_t -#define __DEFINED_pthread_barrier_t -#define __DEFINED_pthread_barrierattr_t -#define __DEFINED_pthread_cond_t -#define __DEFINED_pthread_condattr_t -#define __DEFINED_pthread_key_t -#define __DEFINED_pthread_mutex_t -#define __DEFINED_pthread_mutexattr_t -#define __DEFINED_pthread_once_t -#define __DEFINED_pthread_rwlock_t -#define __DEFINED_pthread_rwlockattr_t -#define __DEFINED_pthread_spinlock_t -#define __DEFINED_pthread_t -#define __DEFINED_register_t -#define __DEFINED_regoff_t -#define __DEFINED_sa_family_t -#define __DEFINED_sigset_t -#define __DEFINED_size_t -#define __DEFINED_socklen_t -#define __DEFINED_ssize_t -#define __DEFINED_suseconds_t -#define __DEFINED_time_t -#define __DEFINED_timer_t -#define __DEFINED_u_int64_t -#define __DEFINED_uid_t -#define __DEFINED_uint16_t -#define __DEFINED_uint32_t -#define __DEFINED_uint64_t -#define __DEFINED_uint8_t -#define __DEFINED_uintmax_t -#define __DEFINED_uintptr_t -#define __DEFINED_useconds_t -#define __DEFINED_va_list -#define __DEFINED_wchar_t -#define __DEFINED_wctype_t -#define __DEFINED_wint_t -#define __FINITE_MATH_ONLY__ 0 -#define __FLOAT128__ 1 -#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) -#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) -#define __FLT_DECIMAL_DIG__ 9 -#define __FLT_DENORM_MIN__ 1.40129846e-45F -#define __FLT_DIG__ 6 -#define __FLT_EPSILON__ 1.19209290e-7F -#define __FLT_HAS_DENORM__ 1 -#define __FLT_HAS_INFINITY__ 1 -#define __FLT_HAS_QUIET_NAN__ 1 -#define __FLT_MANT_DIG__ 24 -#define __FLT_MAX_10_EXP__ 38 -#define __FLT_MAX_EXP__ 128 -#define __FLT_MAX__ 3.40282347e+38F -#define __FLT_MIN_10_EXP__ (-37) -#define __FLT_MIN_EXP__ (-125) -#define __FLT_MIN__ 1.17549435e-38F -#define __FLT_RADIX__ 2 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __GNUC_STDC_INLINE__ 1 -#define __GNUC_VA_LIST 1 -#define __GXX_ABI_VERSION 1002 -#define __INT16_C_SUFFIX__ -#define __INT16_FMTd__ "hd" -#define __INT16_FMTi__ "hi" -#define __INT16_MAX__ 32767 -#define __INT16_TYPE__ short -#define __INT32_C_SUFFIX__ -#define __INT32_FMTd__ "d" -#define __INT32_FMTi__ "i" -#define __INT32_MAX__ 2147483647 -#define __INT32_TYPE__ int -#define __INT64_C_SUFFIX__ LL -#define __INT64_FMTd__ "lld" -#define __INT64_FMTi__ "lli" -#define __INT64_MAX__ 9223372036854775807LL -#define __INT64_TYPE__ long long int -#define __INT8_C_SUFFIX__ -#define __INT8_FMTd__ "hhd" -#define __INT8_FMTi__ "hhi" -#define __INT8_MAX__ 127 -#define __INT8_TYPE__ signed char -#define __INTMAX_C_SUFFIX__ LL -#define __INTMAX_FMTd__ "lld" -#define __INTMAX_FMTi__ "lli" -#define __INTMAX_MAX__ 9223372036854775807LL -#define __INTMAX_TYPE__ long long int -#define __INTMAX_WIDTH__ 64 -#define __INTPTR_FMTd__ "ld" -#define __INTPTR_FMTi__ "li" -#define __INTPTR_MAX__ 9223372036854775807L -#define __INTPTR_TYPE__ long int -#define __INTPTR_WIDTH__ 64 -#define __INT_FAST16_FMTd__ "hd" -#define __INT_FAST16_FMTi__ "hi" -#define __INT_FAST16_MAX__ 32767 -#define __INT_FAST16_TYPE__ short -#define __INT_FAST32_FMTd__ "d" -#define __INT_FAST32_FMTi__ "i" -#define __INT_FAST32_MAX__ 2147483647 -#define __INT_FAST32_TYPE__ int -#define __INT_FAST64_FMTd__ "lld" -#define __INT_FAST64_FMTi__ "lli" -#define __INT_FAST64_MAX__ 9223372036854775807LL -#define __INT_FAST64_TYPE__ long long int -#define __INT_FAST8_FMTd__ "hhd" -#define __INT_FAST8_FMTi__ "hhi" -#define __INT_FAST8_MAX__ 127 -#define __INT_FAST8_TYPE__ signed char -#define __INT_LEAST16_FMTd__ "hd" -#define __INT_LEAST16_FMTi__ "hi" -#define __INT_LEAST16_MAX__ 32767 -#define __INT_LEAST16_TYPE__ short -#define __INT_LEAST32_FMTd__ "d" -#define __INT_LEAST32_FMTi__ "i" -#define __INT_LEAST32_MAX__ 2147483647 -#define __INT_LEAST32_TYPE__ int -#define __INT_LEAST64_FMTd__ "lld" -#define __INT_LEAST64_FMTi__ "lli" -#define __INT_LEAST64_MAX__ 9223372036854775807LL -#define __INT_LEAST64_TYPE__ long long int -#define __INT_LEAST8_FMTd__ "hhd" -#define __INT_LEAST8_FMTi__ "hhi" -#define __INT_LEAST8_MAX__ 127 -#define __INT_LEAST8_TYPE__ signed char -#define __INT_MAX__ 2147483647 -#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) -#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) -#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) -#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) -#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) -#define __LDBL_DECIMAL_DIG__ 36 -#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L -#define __LDBL_DIG__ 33 -#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L -#define __LDBL_HAS_DENORM__ 1 -#define __LDBL_HAS_INFINITY__ 1 -#define __LDBL_HAS_QUIET_NAN__ 1 -#define __LDBL_MANT_DIG__ 113 -#define __LDBL_MAX_10_EXP__ 4932 -#define __LDBL_MAX_EXP__ 16384 -#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L -#define __LDBL_MIN_10_EXP__ (-4931) -#define __LDBL_MIN_EXP__ (-16381) -#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L -#define __LITTLE_ENDIAN 1234 -#define __LITTLE_ENDIAN__ 1 -#define __LONG_LONG_MAX__ 9223372036854775807LL -#define __LONG_MAX __LONG_MAX__ -#define __LONG_MAX__ 9223372036854775807L -#define __LP64__ 1 -#define __NAMESER 19991006 -#define __NEED_FILE -#define __NEED___isoc_va_list -#define __NEED_blkcnt_t -#define __NEED_blksize_t -#define __NEED_clock_t -#define __NEED_clockid_t -#define __NEED_cnd_t -#define __NEED_dev_t -#define __NEED_double_t -#define __NEED_float_t -#define __NEED_fsblkcnt_t -#define __NEED_fsfilcnt_t -#define __NEED_gid_t -#define __NEED_id_t -#define __NEED_ino_t -#define __NEED_int16_t -#define __NEED_int32_t -#define __NEED_int64_t -#define __NEED_int8_t -#define __NEED_intmax_t -#define __NEED_intptr_t -#define __NEED_key_t -#define __NEED_locale_t -#define __NEED_mbstate_t -#define __NEED_mode_t -#define __NEED_mtx_t -#define __NEED_nlink_t -#define __NEED_off_t -#define __NEED_pid_t -#define __NEED_pthread_attr_t -#define __NEED_pthread_barrier_t -#define __NEED_pthread_barrierattr_t -#define __NEED_pthread_cond_t -#define __NEED_pthread_condattr_t -#define __NEED_pthread_key_t -#define __NEED_pthread_mutex_t -#define __NEED_pthread_mutexattr_t -#define __NEED_pthread_once_t -#define __NEED_pthread_rwlock_t -#define __NEED_pthread_rwlockattr_t -#define __NEED_pthread_spinlock_t -#define __NEED_pthread_t -#define __NEED_register_t -#define __NEED_regoff_t -#define __NEED_sa_family_t -#define __NEED_sigset_t -#define __NEED_size_t -#define __NEED_socklen_t -#define __NEED_ssize_t -#define __NEED_struct_iovec -#define __NEED_struct_timespec -#define __NEED_struct_timeval -#define __NEED_suseconds_t -#define __NEED_time_t -#define __NEED_timer_t -#define __NEED_u_int64_t -#define __NEED_uid_t -#define __NEED_uint16_t -#define __NEED_uint32_t -#define __NEED_uint64_t -#define __NEED_uint8_t -#define __NEED_uintmax_t -#define __NEED_uintptr_t -#define __NEED_useconds_t -#define __NEED_va_list -#define __NEED_wchar_t -#define __NEED_wctype_t -#define __NEED_wint_t -#define __OBJC_BOOL_IS_BOOL 0 -#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 -#define __OPENCL_MEMORY_SCOPE_DEVICE 2 -#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 -#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 -#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 -#define __ORDER_BIG_ENDIAN__ 4321 -#define __ORDER_LITTLE_ENDIAN__ 1234 -#define __ORDER_PDP_ENDIAN__ 3412 -#define __PDP_ENDIAN 3412 -#define __POINTER_WIDTH__ 64 -#define __PRAGMA_REDEFINE_EXTNAME 1 -#define __PTRDIFF_FMTd__ "ld" -#define __PTRDIFF_FMTi__ "li" -#define __PTRDIFF_MAX__ 9223372036854775807L -#define __PTRDIFF_TYPE__ long int -#define __PTRDIFF_WIDTH__ 64 -#define __REDIR(x,y) __typeof__(x) x __asm__(#y) -#define __RETCAST(x) -#define __RETCAST_2(x,y) -#define __RETCAST_3(x,y,z) -#define __RETCAST_CX(x) -#define __RETCAST_REAL(x) -#define __SCHAR_MAX__ 127 -#define __SHRT_MAX__ 32767 -#define __SID ('S' << 8) -#define __SIG_ATOMIC_MAX__ 9223372036854775807L -#define __SIG_ATOMIC_WIDTH__ 64 -#define __SIZEOF_DOUBLE__ 8 -#define __SIZEOF_FLOAT__ 4 -#define __SIZEOF_INT128__ 16 -#define __SIZEOF_INT__ 4 -#define __SIZEOF_LONG_DOUBLE__ 16 -#define __SIZEOF_LONG_LONG__ 8 -#define __SIZEOF_LONG__ 8 -#define __SIZEOF_POINTER__ 8 -#define __SIZEOF_PTRDIFF_T__ 8 -#define __SIZEOF_SHORT__ 2 -#define __SIZEOF_SIZE_T__ 8 -#define __SIZEOF_WCHAR_T__ 4 -#define __SIZEOF_WINT_T__ 4 -#define __SIZE_FMTX__ "lX" -#define __SIZE_FMTo__ "lo" -#define __SIZE_FMTu__ "lu" -#define __SIZE_FMTx__ "lx" -#define __SIZE_MAX__ 18446744073709551615UL -#define __SIZE_TYPE__ long unsigned int -#define __SIZE_WIDTH__ 64 -#define __STDARG_H -#define __STDC_HOSTED__ 1 -#define __STDC_IEC_559__ 1 -#define __STDC_ISO_10646__ 201206L -#define __STDC_UTF_16__ 1 -#define __STDC_UTF_32__ 1 -#define __STDC_VERSION__ 201710L -#define __STDC__ 1 -#define __STDDEF_H -#define __UAPI_DEF_IN6_ADDR 0 -#define __UAPI_DEF_IN6_ADDR_ALT 0 -#define __UAPI_DEF_IN6_PKTINFO 0 -#define __UAPI_DEF_IN_ADDR 0 -#define __UAPI_DEF_IN_CLASS 0 -#define __UAPI_DEF_IN_IPPROTO 0 -#define __UAPI_DEF_IN_PKTINFO 0 -#define __UAPI_DEF_IP6_MTUINFO 0 -#define __UAPI_DEF_IPHDR 0 -#define __UAPI_DEF_IPPROTO_V6 0 -#define __UAPI_DEF_IPV6_MREQ 0 -#define __UAPI_DEF_IPV6_OPTIONS 0 -#define __UAPI_DEF_IP_MREQ 0 -#define __UAPI_DEF_SOCKADDR_IN 0 -#define __UAPI_DEF_SOCKADDR_IN6 0 -#define __UINT16_C_SUFFIX__ -#define __UINT16_FMTX__ "hX" -#define __UINT16_FMTo__ "ho" -#define __UINT16_FMTu__ "hu" -#define __UINT16_FMTx__ "hx" -#define __UINT16_MAX__ 65535 -#define __UINT16_TYPE__ unsigned short -#define __UINT32_C_SUFFIX__ U -#define __UINT32_FMTX__ "X" -#define __UINT32_FMTo__ "o" -#define __UINT32_FMTu__ "u" -#define __UINT32_FMTx__ "x" -#define __UINT32_MAX__ 4294967295U -#define __UINT32_TYPE__ unsigned int -#define __UINT64_C_SUFFIX__ ULL -#define __UINT64_FMTX__ "llX" -#define __UINT64_FMTo__ "llo" -#define __UINT64_FMTu__ "llu" -#define __UINT64_FMTx__ "llx" -#define __UINT64_MAX__ 18446744073709551615ULL -#define __UINT64_TYPE__ long long unsigned int -#define __UINT8_C_SUFFIX__ -#define __UINT8_FMTX__ "hhX" -#define __UINT8_FMTo__ "hho" -#define __UINT8_FMTu__ "hhu" -#define __UINT8_FMTx__ "hhx" -#define __UINT8_MAX__ 255 -#define __UINT8_TYPE__ unsigned char -#define __UINTMAX_C_SUFFIX__ ULL -#define __UINTMAX_FMTX__ "llX" -#define __UINTMAX_FMTo__ "llo" -#define __UINTMAX_FMTu__ "llu" -#define __UINTMAX_FMTx__ "llx" -#define __UINTMAX_MAX__ 18446744073709551615ULL -#define __UINTMAX_TYPE__ long long unsigned int -#define __UINTMAX_WIDTH__ 64 -#define __UINTPTR_FMTX__ "lX" -#define __UINTPTR_FMTo__ "lo" -#define __UINTPTR_FMTu__ "lu" -#define __UINTPTR_FMTx__ "lx" -#define __UINTPTR_MAX__ 18446744073709551615UL -#define __UINTPTR_TYPE__ long unsigned int -#define __UINTPTR_WIDTH__ 64 -#define __UINT_FAST16_FMTX__ "hX" -#define __UINT_FAST16_FMTo__ "ho" -#define __UINT_FAST16_FMTu__ "hu" -#define __UINT_FAST16_FMTx__ "hx" -#define __UINT_FAST16_MAX__ 65535 -#define __UINT_FAST16_TYPE__ unsigned short -#define __UINT_FAST32_FMTX__ "X" -#define __UINT_FAST32_FMTo__ "o" -#define __UINT_FAST32_FMTu__ "u" -#define __UINT_FAST32_FMTx__ "x" -#define __UINT_FAST32_MAX__ 4294967295U -#define __UINT_FAST32_TYPE__ unsigned int -#define __UINT_FAST64_FMTX__ "llX" -#define __UINT_FAST64_FMTo__ "llo" -#define __UINT_FAST64_FMTu__ "llu" -#define __UINT_FAST64_FMTx__ "llx" -#define __UINT_FAST64_MAX__ 18446744073709551615ULL -#define __UINT_FAST64_TYPE__ long long unsigned int -#define __UINT_FAST8_FMTX__ "hhX" -#define __UINT_FAST8_FMTo__ "hho" -#define __UINT_FAST8_FMTu__ "hhu" -#define __UINT_FAST8_FMTx__ "hhx" -#define __UINT_FAST8_MAX__ 255 -#define __UINT_FAST8_TYPE__ unsigned char -#define __UINT_LEAST16_FMTX__ "hX" -#define __UINT_LEAST16_FMTo__ "ho" -#define __UINT_LEAST16_FMTu__ "hu" -#define __UINT_LEAST16_FMTx__ "hx" -#define __UINT_LEAST16_MAX__ 65535 -#define __UINT_LEAST16_TYPE__ unsigned short -#define __UINT_LEAST32_FMTX__ "X" -#define __UINT_LEAST32_FMTo__ "o" -#define __UINT_LEAST32_FMTu__ "u" -#define __UINT_LEAST32_FMTx__ "x" -#define __UINT_LEAST32_MAX__ 4294967295U -#define __UINT_LEAST32_TYPE__ unsigned int -#define __UINT_LEAST64_FMTX__ "llX" -#define __UINT_LEAST64_FMTo__ "llo" -#define __UINT_LEAST64_FMTu__ "llu" -#define __UINT_LEAST64_FMTx__ "llx" -#define __UINT_LEAST64_MAX__ 18446744073709551615ULL -#define __UINT_LEAST64_TYPE__ long long unsigned int -#define __UINT_LEAST8_FMTX__ "hhX" -#define __UINT_LEAST8_FMTo__ "hho" -#define __UINT_LEAST8_FMTu__ "hhu" -#define __UINT_LEAST8_FMTx__ "hhx" -#define __UINT_LEAST8_MAX__ 255 -#define __UINT_LEAST8_TYPE__ unsigned char -#define __USER_LABEL_PREFIX__ -#define __USE_TIME_BITS64 1 -#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) -#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) -#define __WASI_ADVICE_NORMAL (UINT8_C(0)) -#define __WASI_ADVICE_RANDOM (UINT8_C(2)) -#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) -#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) -#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) -#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) -#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) -#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) -#define __WASI_DIRCOOKIE_START (UINT64_C(0)) -#define __WASI_ERRNO_2BIG (UINT16_C(1)) -#define __WASI_ERRNO_ACCES (UINT16_C(2)) -#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) -#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) -#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) -#define __WASI_ERRNO_AGAIN (UINT16_C(6)) -#define __WASI_ERRNO_ALREADY (UINT16_C(7)) -#define __WASI_ERRNO_BADF (UINT16_C(8)) -#define __WASI_ERRNO_BADMSG (UINT16_C(9)) -#define __WASI_ERRNO_BUSY (UINT16_C(10)) -#define __WASI_ERRNO_CANCELED (UINT16_C(11)) -#define __WASI_ERRNO_CHILD (UINT16_C(12)) -#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) -#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) -#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) -#define __WASI_ERRNO_DEADLK (UINT16_C(16)) -#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) -#define __WASI_ERRNO_DOM (UINT16_C(18)) -#define __WASI_ERRNO_DQUOT (UINT16_C(19)) -#define __WASI_ERRNO_EXIST (UINT16_C(20)) -#define __WASI_ERRNO_FAULT (UINT16_C(21)) -#define __WASI_ERRNO_FBIG (UINT16_C(22)) -#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) -#define __WASI_ERRNO_IDRM (UINT16_C(24)) -#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) -#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) -#define __WASI_ERRNO_INTR (UINT16_C(27)) -#define __WASI_ERRNO_INVAL (UINT16_C(28)) -#define __WASI_ERRNO_IO (UINT16_C(29)) -#define __WASI_ERRNO_ISCONN (UINT16_C(30)) -#define __WASI_ERRNO_ISDIR (UINT16_C(31)) -#define __WASI_ERRNO_LOOP (UINT16_C(32)) -#define __WASI_ERRNO_MFILE (UINT16_C(33)) -#define __WASI_ERRNO_MLINK (UINT16_C(34)) -#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) -#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) -#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) -#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) -#define __WASI_ERRNO_NETRESET (UINT16_C(39)) -#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) -#define __WASI_ERRNO_NFILE (UINT16_C(41)) -#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) -#define __WASI_ERRNO_NODEV (UINT16_C(43)) -#define __WASI_ERRNO_NOENT (UINT16_C(44)) -#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) -#define __WASI_ERRNO_NOLCK (UINT16_C(46)) -#define __WASI_ERRNO_NOLINK (UINT16_C(47)) -#define __WASI_ERRNO_NOMEM (UINT16_C(48)) -#define __WASI_ERRNO_NOMSG (UINT16_C(49)) -#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) -#define __WASI_ERRNO_NOSPC (UINT16_C(51)) -#define __WASI_ERRNO_NOSYS (UINT16_C(52)) -#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) -#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) -#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) -#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) -#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) -#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) -#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) -#define __WASI_ERRNO_NOTTY (UINT16_C(59)) -#define __WASI_ERRNO_NXIO (UINT16_C(60)) -#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) -#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) -#define __WASI_ERRNO_PERM (UINT16_C(63)) -#define __WASI_ERRNO_PIPE (UINT16_C(64)) -#define __WASI_ERRNO_PROTO (UINT16_C(65)) -#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) -#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) -#define __WASI_ERRNO_RANGE (UINT16_C(68)) -#define __WASI_ERRNO_ROFS (UINT16_C(69)) -#define __WASI_ERRNO_SPIPE (UINT16_C(70)) -#define __WASI_ERRNO_SRCH (UINT16_C(71)) -#define __WASI_ERRNO_STALE (UINT16_C(72)) -#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) -#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) -#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) -#define __WASI_ERRNO_XDEV (UINT16_C(75)) -#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) -#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) -#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) -#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) -#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) -#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) -#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) -#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) -#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) -#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) -#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) -#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) -#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) -#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) -#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) -#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) -#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) -#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) -#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) -#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) -#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) -#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) -#define __WASI_NOEXCEPT -#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) -#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) -#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) -#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) -#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) -#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) -#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) -#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) -#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) -#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) -#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) -#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) -#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) -#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) -#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) -#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) -#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) -#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) -#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) -#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) -#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) -#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) -#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) -#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) -#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) -#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) -#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) -#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) -#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) -#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) -#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) -#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) -#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) -#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) -#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) -#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) -#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) -#define __WASI_WHENCE_CUR (UINT8_C(1)) -#define __WASI_WHENCE_END (UINT8_C(2)) -#define __WASI_WHENCE_SET (UINT8_C(0)) -#define __WCHAR_MAX__ 2147483647 -#define __WCHAR_TYPE__ int -#define __WCHAR_WIDTH__ 32 -#define __WINT_MAX__ 2147483647 -#define __WINT_TYPE__ int -#define __WINT_WIDTH__ 32 -#define __WORDSIZE 64 -#define __alignas_is_defined 1 -#define __alignof_is_defined 1 -#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) -#define __bool_true_false_are_defined 1 -#define __inline inline -#define __restrict restrict -#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) -#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) -#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) -#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) -#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) -#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) -#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) -#define __tm_gmtoff tm_gmtoff -#define __tm_zone tm_zone -#define __va_copy(d,s) __builtin_va_copy(d, s) -#define __wasi__ 1 -#define __wasi_api_h -#define __wasi_libc_environ_h -#define __wasi_libc_find_relpath_h -#define __wasi_libc_h -#define __wasi_libc_nocwd_h -#define __wasilibc___errno_h -#define __wasilibc___errno_values_h -#define __wasilibc___fd_set_h -#define __wasilibc___function___isatty_h -#define __wasilibc___functions_malloc_h -#define __wasilibc___functions_memcpy_h -#define __wasilibc___header_dirent_h -#define __wasilibc___header_fcntl_h -#define __wasilibc___header_netinet_in_h -#define __wasilibc___header_poll_h -#define __wasilibc___header_stdlib_h -#define __wasilibc___header_string_h -#define __wasilibc___header_sys_ioctl_h -#define __wasilibc___header_sys_resource_h -#define __wasilibc___header_sys_socket_h -#define __wasilibc___header_sys_stat_h -#define __wasilibc___header_time_h -#define __wasilibc___header_unistd_h -#define __wasilibc___include_inttypes_h -#define __wasilibc___macro_FD_SETSIZE_h -#define __wasilibc___macro_PAGESIZE_h -#define __wasilibc___mode_t_h -#define __wasilibc___seek_h -#define __wasilibc___struct_dirent_h -#define __wasilibc___struct_in6_addr_h -#define __wasilibc___struct_in_addr_h -#define __wasilibc___struct_iovec_h -#define __wasilibc___struct_msghdr_h -#define __wasilibc___struct_pollfd_h -#define __wasilibc___struct_rusage_h -#define __wasilibc___struct_sockaddr_h -#define __wasilibc___struct_sockaddr_in6_h -#define __wasilibc___struct_sockaddr_in_h -#define __wasilibc___struct_sockaddr_storage_h -#define __wasilibc___struct_sockaddr_un_h -#define __wasilibc___struct_stat_h -#define __wasilibc___struct_timespec_h -#define __wasilibc___struct_timeval_h -#define __wasilibc___struct_tm_h -#define __wasilibc___struct_tms_h -#define __wasilibc___typedef_DIR_h -#define __wasilibc___typedef_blkcnt_t_h -#define __wasilibc___typedef_blksize_t_h -#define __wasilibc___typedef_clock_t_h -#define __wasilibc___typedef_clockid_t_h -#define __wasilibc___typedef_dev_t_h -#define __wasilibc___typedef_fd_set_h -#define __wasilibc___typedef_gid_t_h -#define __wasilibc___typedef_in_addr_t_h -#define __wasilibc___typedef_in_port_t_h -#define __wasilibc___typedef_ino_t_h -#define __wasilibc___typedef_mode_t_h -#define __wasilibc___typedef_nfds_t_h -#define __wasilibc___typedef_nlink_t_h -#define __wasilibc___typedef_off_t_h -#define __wasilibc___typedef_sa_family_t_h -#define __wasilibc___typedef_sigset_t_h -#define __wasilibc___typedef_socklen_t_h -#define __wasilibc___typedef_ssize_t_h -#define __wasilibc___typedef_suseconds_t_h -#define __wasilibc___typedef_time_t_h -#define __wasilibc___typedef_uid_t_h -#define __wasm 1 -#define __wasm64 1 -#define __wasm64__ 1 -#define __wasm__ 1 -#define __wasm_atomics__ 1 -#define __wasm_bulk_memory__ 1 -#define _tolower(a) ((a)|0x20) -#define _toupper(a) ((a)&0x5f) -#define acos(x) __tg_real_complex(acos, (x)) -#define acosh(x) __tg_real_complex(acosh, (x)) -#define alignas _Alignas -#define alignof _Alignof -#define alloca __builtin_alloca -#define alphasort64 alphasort -#define and && -#define and_eq &= -#define asin(x) __tg_real_complex(asin, (x)) -#define asinh(x) __tg_real_complex(asinh, (x)) -#define atan(x) __tg_real_complex(atan, (x)) -#define atan2(x,y) __tg_real_2(atan2, (x), (y)) -#define atanh(x) __tg_real_complex(atanh, (x)) -#define be16toh(x) __bswap16(x) -#define be32toh(x) __bswap32(x) -#define be64toh(x) __bswap64(x) -#define betoh16(x) __bswap16(x) -#define betoh32(x) __bswap32(x) -#define betoh64(x) __bswap64(x) -#define bitand & -#define bitor | -#define blkcnt64_t blkcnt_t -#define bool _Bool -#define bswap_16(x) __bswap_16(x) -#define bswap_32(x) __bswap_32(x) -#define bswap_64(x) __bswap_64(x) -#define carg(x) __tg_complex_retreal(carg, (x)) -#define cbrt(x) __tg_real(cbrt, (x)) -#define ceil(x) __tg_real(ceil, (x)) -#define cimag(x) __tg_complex_retreal(cimag, (x)) -#define cimagf(x) (__builtin_cimagf(x)) -#define cimagl(x) (__builtin_cimagl(x)) -#define clrbit(x,i) __bitop(x,i,&=~) -#define compl ~ -#define complex _Complex -#define conj(x) __tg_complex(conj, (x)) -#define copysign(x,y) __tg_real_2(copysign, (x), (y)) -#define cos(x) __tg_real_complex(cos, (x)) -#define cosh(x) __tg_real_complex(cosh, (x)) -#define cproj(x) __tg_complex(cproj, (x)) -#define creal(x) __tg_complex_retreal(creal, (x)) -#define crealf(x) (__builtin_crealf(x)) -#define creall(x) (__builtin_creall(x)) -#define creat64 creat -#define d_fileno d_ino -#define direct dirent -#define dirent64 dirent -#define erf(x) __tg_real(erf, (x)) -#define erfc(x) __tg_real(erfc, (x)) -#define errno errno -#define exp(x) __tg_real_complex(exp, (x)) -#define exp2(x) __tg_real(exp2, (x)) -#define expm1(x) __tg_real(expm1, (x)) -#define fabs(x) __tg_real_complex_fabs(x) -#define false 0 -#define fdim(x,y) __tg_real_2(fdim, (x), (y)) -#define fgetpos64 fgetpos -#define floor(x) __tg_real(floor, (x)) -#define fma(x,y,z) __tg_real_fma((x), (y), (z)) -#define fmax(x,y) __tg_real_2(fmax, (x), (y)) -#define fmin(x,y) __tg_real_2(fmin, (x), (y)) -#define fmod(x,y) __tg_real_2(fmod, (x), (y)) -#define fopen64 fopen -#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) -#define fpos64_t fpos_t -#define freopen64 freopen -#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) -#define fsblkcnt64_t fsblkcnt_t -#define fseeko64 fseeko -#define fsetpos64 fsetpos -#define fsfilcnt64_t fsfilcnt_t -#define fstat64 fstat -#define fstatat64 fstatat -#define fstatvfs64 fstatvfs -#define ftello64 ftello -#define ftruncate64 ftruncate -#define getdents64 getdents -#define glob64 glob -#define glob64_t glob_t -#define globfree64 globfree -#define howmany(n,d) (((n)+((d)-1))/(d)) -#define htobe16(x) __bswap16(x) -#define htobe32(x) __bswap32(x) -#define htobe64(x) __bswap64(x) -#define htole16(x) (uint16_t)(x) -#define htole32(x) (uint32_t)(x) -#define htole64(x) (uint64_t)(x) -#define hypot(x,y) __tg_real_2(hypot, (x), (y)) -#define icmp6_data16 icmp6_dataun.icmp6_un_data16 -#define icmp6_data32 icmp6_dataun.icmp6_un_data32 -#define icmp6_data8 icmp6_dataun.icmp6_un_data8 -#define icmp6_id icmp6_data16[0] -#define icmp6_maxdelay icmp6_data16[0] -#define icmp6_mtu icmp6_data32[0] -#define icmp6_pptr icmp6_data32[0] -#define icmp6_seq icmp6_data16[1] -#define icmp_data icmp_dun.id_data -#define icmp_gwaddr icmp_hun.ih_gwaddr -#define icmp_id icmp_hun.ih_idseq.icd_id -#define icmp_ip icmp_dun.id_ip.idi_ip -#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime -#define icmp_mask icmp_dun.id_mask -#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu -#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs -#define icmp_otime icmp_dun.id_ts.its_otime -#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void -#define icmp_pptr icmp_hun.ih_pptr -#define icmp_radv icmp_dun.id_radv -#define icmp_rtime icmp_dun.id_ts.its_rtime -#define icmp_seq icmp_hun.ih_idseq.icd_seq -#define icmp_ttime icmp_dun.id_ts.its_ttime -#define icmp_void icmp_hun.ih_void -#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa -#define ifa_broadaddr ifa_ifu.ifu_broadaddr -#define ifa_dstaddr ifa_ifu.ifu_dstaddr -#define ilogb(x) __tg_real_nocast(ilogb, (x)) -#define ino64_t ino_t -#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow -#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt -#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen -#define ip6_vfc ip6_ctlun.ip6_un2_vfc -#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) -#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) -#define isclr(x,i) !isset(x,i) -#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) -#define isfinite(x) (__builtin_isfinite(x)) -#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) -#define isgreater(x,y) (__builtin_isgreater(x, y)) -#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) -#define isinf(x) (__builtin_isinf(x)) -#define isless(x,y) (__builtin_isless(x, y)) -#define islessequal(x,y) (__builtin_islessequal(x, y)) -#define islessgreater(x,y) (__builtin_islessgreater(x, y)) -#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) -#define isnan(x) (__builtin_isnan(x)) -#define isnormal(x) (__builtin_isnormal(x)) -#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) -#define isset(x,i) __bitop(x,i,&) -#define isspace(a) __isspace(a) -#define isunordered(x,y) (__builtin_isunordered(x, y)) -#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) -#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) -#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) -#define le16toh(x) (uint16_t)(x) -#define le32toh(x) (uint32_t)(x) -#define le64toh(x) (uint64_t)(x) -#define letoh16(x) (uint16_t)(x) -#define letoh32(x) (uint32_t)(x) -#define letoh64(x) (uint64_t)(x) -#define lgamma(x) __tg_real(lgamma, (x)) -#define llrint(x) __tg_real_nocast(llrint, (x)) -#define llround(x) __tg_real_nocast(llround, (x)) -#define loff_t off_t -#define log(x) __tg_real_complex(log, (x)) -#define log10(x) __tg_real(log10, (x)) -#define log1p(x) __tg_real(log1p, (x)) -#define log2(x) __tg_real(log2, (x)) -#define logb(x) __tg_real(logb, (x)) -#define lrint(x) __tg_real_nocast(lrint, (x)) -#define lround(x) __tg_real_nocast(lround, (x)) -#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) -#define lseek64 lseek -#define lstat64 lstat -#define math_errhandling 2 -#define mld_cksum mld_icmp6_hdr.icmp6_cksum -#define mld_code mld_icmp6_hdr.icmp6_code -#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] -#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] -#define mld_type mld_icmp6_hdr.icmp6_type -#define nd_na_cksum nd_na_hdr.icmp6_cksum -#define nd_na_code nd_na_hdr.icmp6_code -#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] -#define nd_na_type nd_na_hdr.icmp6_type -#define nd_ns_cksum nd_ns_hdr.icmp6_cksum -#define nd_ns_code nd_ns_hdr.icmp6_code -#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] -#define nd_ns_type nd_ns_hdr.icmp6_type -#define nd_ra_cksum nd_ra_hdr.icmp6_cksum -#define nd_ra_code nd_ra_hdr.icmp6_code -#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] -#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] -#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] -#define nd_ra_type nd_ra_hdr.icmp6_type -#define nd_rd_cksum nd_rd_hdr.icmp6_cksum -#define nd_rd_code nd_rd_hdr.icmp6_code -#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] -#define nd_rd_type nd_rd_hdr.icmp6_type -#define nd_rs_cksum nd_rs_hdr.icmp6_cksum -#define nd_rs_code nd_rs_hdr.icmp6_code -#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] -#define nd_rs_type nd_rs_hdr.icmp6_type -#define nearbyint(x) __tg_real(nearbyint, (x)) -#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) -#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) -#define nftw64 nftw -#define no_argument 0 -#define noreturn _Noreturn -#define not ! -#define not_eq != -#define ns_msg_base(handle) ((handle)._msg + 0) -#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) -#define ns_msg_end(handle) ((handle)._eom + 0) -#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) -#define ns_msg_id(handle) ((handle)._id + 0) -#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) -#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) -#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") -#define ns_rr_rdata(rr) ((rr).rdata + 0) -#define ns_rr_rdlen(rr) ((rr).rdlength + 0) -#define ns_rr_ttl(rr) ((rr).ttl + 0) -#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) -#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) -#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) -#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) -#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) -#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) -#define off64_t off_t -#define offsetof(t,d) __builtin_offsetof(t, d) -#define open64 open -#define openat64 openat -#define optional_argument 2 -#define or || -#define or_eq |= -#define posix_fadvise64 posix_fadvise -#define posix_fallocate64 posix_fallocate -#define pow(x,y) __tg_real_complex_pow((x), (y)) -#define powerof2(n) !(((n)-1) & (n)) -#define pread64 pread -#define preadv64 preadv -#define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) -#define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); -#define pthread_equal(x,y) ((x)==(y)) -#define pwrite64 pwrite -#define pwritev64 pwritev -#define readdir64 readdir -#define remainder(x,y) __tg_real_2(remainder, (x), (y)) -#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) -#define required_argument 1 -#define rint(x) __tg_real(rint, (x)) -#define round(x) __tg_real(round, (x)) -#define roundup(n,d) (howmany(n,d)*(d)) -#define rr_cksum rr_hdr.icmp6_cksum -#define rr_code rr_hdr.icmp6_code -#define rr_seqnum rr_hdr.icmp6_data32[0] -#define rr_type rr_hdr.icmp6_type -#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) -#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) -#define scandir64 scandir -#define setbit(x,i) __bitop(x,i,|=) -#define signbit(x) (__builtin_signbit(x)) -#define sin(x) __tg_real_complex(sin, (x)) -#define sinh(x) __tg_real_complex(sinh, (x)) -#define sqrt(x) __tg_real_complex(sqrt, (x)) -#define st_atime st_atim.tv_sec -#define st_ctime st_ctim.tv_sec -#define st_mtime st_mtim.tv_sec -#define stat64 stat -#define static_assert _Static_assert -#define statvfs64 statvfs -#define stderr (stderr) -#define stdin (stdin) -#define stdout (stdout) -#define strdupa(x) strcpy(alloca(strlen(x)+1),x) -#define tan(x) __tg_real_complex(tan, (x)) -#define tanh(x) __tg_real_complex(tanh, (x)) -#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) -#define tgamma(x) __tg_real(tgamma, (x)) -#define th_block th_u.tu_block -#define th_code th_u.tu_code -#define th_msg th_data -#define th_stuff th_u.tu_stuff -#define thrd_equal(A,B) ((A) == (B)) -#define thread_local _Thread_local -#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) -#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) -#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) -#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) -#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) -#define true 1 -#define trunc(x) __tg_real(trunc, (x)) -#define uh_dport dest -#define uh_sport source -#define uh_sum check -#define uh_ulen len -#define va_arg(ap,type) __builtin_va_arg(ap, type) -#define va_copy(dest,src) __builtin_va_copy(dest, src) -#define va_end(ap) __builtin_va_end(ap) -#define va_start(ap,param) __builtin_va_start(ap, param) -#define versionsort64 versionsort -#define xEOF 236 -#define xor ^ -#define xor_eq ^= diff --git a/expected/wasm64-wasi-threads/undefined-symbols.txt b/expected/wasm64-wasi-threads/undefined-symbols.txt deleted file mode 100644 index 938e64776..000000000 --- a/expected/wasm64-wasi-threads/undefined-symbols.txt +++ /dev/null @@ -1,76 +0,0 @@ -__addtf3 -__data_end -__divtf3 -__eqtf2 -__extenddftf2 -__extendsftf2 -__fixtfdi -__fixtfsi -__fixunstfsi -__floatditf -__floatsitf -__floatunsitf -__getf2 -__global_base -__gttf2 -__heap_base -__heap_end -__imported_wasi_snapshot_preview1_args_get -__imported_wasi_snapshot_preview1_args_sizes_get -__imported_wasi_snapshot_preview1_clock_res_get -__imported_wasi_snapshot_preview1_clock_time_get -__imported_wasi_snapshot_preview1_environ_get -__imported_wasi_snapshot_preview1_environ_sizes_get -__imported_wasi_snapshot_preview1_fd_advise -__imported_wasi_snapshot_preview1_fd_allocate -__imported_wasi_snapshot_preview1_fd_close -__imported_wasi_snapshot_preview1_fd_datasync -__imported_wasi_snapshot_preview1_fd_fdstat_get -__imported_wasi_snapshot_preview1_fd_fdstat_set_flags -__imported_wasi_snapshot_preview1_fd_fdstat_set_rights -__imported_wasi_snapshot_preview1_fd_filestat_get -__imported_wasi_snapshot_preview1_fd_filestat_set_size -__imported_wasi_snapshot_preview1_fd_filestat_set_times -__imported_wasi_snapshot_preview1_fd_pread -__imported_wasi_snapshot_preview1_fd_prestat_dir_name -__imported_wasi_snapshot_preview1_fd_prestat_get -__imported_wasi_snapshot_preview1_fd_pwrite -__imported_wasi_snapshot_preview1_fd_read -__imported_wasi_snapshot_preview1_fd_readdir -__imported_wasi_snapshot_preview1_fd_renumber -__imported_wasi_snapshot_preview1_fd_seek -__imported_wasi_snapshot_preview1_fd_sync -__imported_wasi_snapshot_preview1_fd_tell -__imported_wasi_snapshot_preview1_fd_write -__imported_wasi_snapshot_preview1_path_create_directory -__imported_wasi_snapshot_preview1_path_filestat_get -__imported_wasi_snapshot_preview1_path_filestat_set_times -__imported_wasi_snapshot_preview1_path_link -__imported_wasi_snapshot_preview1_path_open -__imported_wasi_snapshot_preview1_path_readlink -__imported_wasi_snapshot_preview1_path_remove_directory -__imported_wasi_snapshot_preview1_path_rename -__imported_wasi_snapshot_preview1_path_symlink -__imported_wasi_snapshot_preview1_path_unlink_file -__imported_wasi_snapshot_preview1_poll_oneoff -__imported_wasi_snapshot_preview1_proc_exit -__imported_wasi_snapshot_preview1_random_get -__imported_wasi_snapshot_preview1_sched_yield -__imported_wasi_snapshot_preview1_sock_accept -__imported_wasi_snapshot_preview1_sock_recv -__imported_wasi_snapshot_preview1_sock_send -__imported_wasi_snapshot_preview1_sock_shutdown -__imported_wasi_thread_spawn -__letf2 -__lttf2 -__netf2 -__stack_pointer -__subtf3 -__tls_align -__tls_base -__tls_size -__trunctfdf2 -__trunctfsf2 -__unordtf2 -__wasm_call_ctors -__wasm_init_tls diff --git a/expected/wasm64-wasi/defined-symbols.txt b/expected/wasm64-wasi/defined-symbols.txt deleted file mode 100644 index 8342dd5ee..000000000 --- a/expected/wasm64-wasi/defined-symbols.txt +++ /dev/null @@ -1,1211 +0,0 @@ -_CLOCK_MONOTONIC -_CLOCK_REALTIME -_Exit -_IO_feof_unlocked -_IO_ferror_unlocked -_IO_getc -_IO_getc_unlocked -_IO_putc -_IO_putc_unlocked -__EINVAL -__ENOMEM -__SIG_ERR -__SIG_IGN -__asctime_r -__assert_fail -__c_dot_utf8 -__c_dot_utf8_locale -__c_locale -__clock -__clock_gettime -__clock_nanosleep -__cos -__cosdf -__cosl -__crypt_blowfish -__crypt_des -__crypt_md5 -__crypt_r -__crypt_sha256 -__crypt_sha512 -__ctype_b_loc -__ctype_get_mb_cur_max -__ctype_tolower_loc -__ctype_toupper_loc -__cxa_atexit -__cxa_finalize -__des_setkey -__do_des -__duplocale -__env_rm_add -__errno_location -__exp2f_data -__exp_data -__expo2 -__expo2f -__fbufsize -__fclose_ca -__fdopen -__fesetround -__fgetwc_unlocked -__flbf -__floatscan -__fmodeflags -__fopen_rb_ca -__fpending -__fpurge -__fputwc_unlocked -__freadable -__freadahead -__freading -__freadptr -__freadptrinc -__freelocale -__fseeko -__fseeko_unlocked -__fseterr -__fsetlocking -__fsmu8 -__ftello -__ftello_unlocked -__funcs_on_exit -__funcs_on_quick_exit -__futimesat -__fwritable -__fwritex -__fwriting -__get_locale -__getdelim -__getentropy -__getopt_msg -__gmtime_r -__hwcap -__inet_aton -__init_ssp -__intscan -__invtrigl_R -__isalnum_l -__isalpha_l -__isatty -__isblank_l -__iscntrl_l -__isdigit_l -__isgraph_l -__islower_l -__isoc99_fscanf -__isoc99_fwscanf -__isoc99_scanf -__isoc99_sscanf -__isoc99_swscanf -__isoc99_vfscanf -__isoc99_vfwscanf -__isoc99_vscanf -__isoc99_vsscanf -__isoc99_vswscanf -__isoc99_vwscanf -__isoc99_wscanf -__isprint_l -__ispunct_l -__isspace_l -__isupper_l -__iswalnum_l -__iswalpha_l -__iswblank_l -__iswcntrl_l -__iswctype_l -__iswdigit_l -__iswgraph_l -__iswlower_l -__iswprint_l -__iswpunct_l -__iswspace_l -__iswupper_l -__iswxdigit_l -__isxdigit_l -__lctrans -__lctrans_cur -__lctrans_impl -__ldexp_cexp -__ldexp_cexpf -__lgamma_r -__lgammaf_r -__lgammal_r -__libc -__libc_calloc -__libc_free -__libc_malloc -__loc_is_allocated -__localtime_r -__log2_data -__log2f_data -__log_data -__logf_data -__lseek -__main_void -__math_divzero -__math_divzerof -__math_invalid -__math_invalidf -__math_invalidl -__math_oflow -__math_oflowf -__math_uflow -__math_uflowf -__math_xflow -__math_xflowf -__memrchr -__mo_lookup -__month_to_secs -__newlocale -__nl_langinfo -__nl_langinfo_l -__ofl_add -__ofl_lock -__ofl_unlock -__optpos -__optreset -__overflow -__p1evll -__pio2_hi -__pio2_lo -__pleval -__polevll -__posix_getopt -__pow_log_data -__powf_log2_data -__progname -__progname_full -__putenv -__qsort_r -__rand48_step -__reallocarray -__rem_pio2 -__rem_pio2_large -__rem_pio2f -__rem_pio2l -__rsqrt_tab -__secs_to_tm -__secs_to_zone -__seed48 -__shgetc -__shlim -__signgam -__sin -__sindf -__sinl -__small_printf -__stack_chk_fail -__stack_chk_fail_local -__stack_chk_guard -__stderr_FILE -__stderr_used -__stdin_FILE -__stdin_used -__stdio_close -__stdio_exit -__stdio_exit_needed -__stdio_read -__stdio_seek -__stdio_write -__stdout_FILE -__stdout_used -__stdout_write -__stpcpy -__stpncpy -__strcasecmp_l -__strchrnul -__strcoll_l -__strerror_l -__strftime_fmt_1 -__strftime_l -__strncasecmp_l -__strtod_l -__strtof_l -__strtoimax_internal -__strtol_internal -__strtold_l -__strtoll_internal -__strtoul_internal -__strtoull_internal -__strtoumax_internal -__strxfrm_l -__sysinfo -__sysv_signal -__tan -__tandf -__tanl -__tm_to_secs -__tm_to_tzname -__tolower_l -__toread -__toread_needs_stdio_exit -__toupper_l -__towctrans_l -__towlower_l -__towrite -__towrite_needs_stdio_exit -__towupper_l -__tre_mem_alloc_impl -__tre_mem_destroy -__tre_mem_new_impl -__tsearch_balance -__uflow -__unlist_locked_file -__uselocale -__utc -__wasi_args_get -__wasi_args_sizes_get -__wasi_clock_res_get -__wasi_clock_time_get -__wasi_environ_get -__wasi_environ_sizes_get -__wasi_fd_advise -__wasi_fd_allocate -__wasi_fd_close -__wasi_fd_datasync -__wasi_fd_fdstat_get -__wasi_fd_fdstat_set_flags -__wasi_fd_fdstat_set_rights -__wasi_fd_filestat_get -__wasi_fd_filestat_set_size -__wasi_fd_filestat_set_times -__wasi_fd_pread -__wasi_fd_prestat_dir_name -__wasi_fd_prestat_get -__wasi_fd_pwrite -__wasi_fd_read -__wasi_fd_readdir -__wasi_fd_renumber -__wasi_fd_seek -__wasi_fd_sync -__wasi_fd_tell -__wasi_fd_write -__wasi_path_create_directory -__wasi_path_filestat_get -__wasi_path_filestat_set_times -__wasi_path_link -__wasi_path_open -__wasi_path_readlink -__wasi_path_remove_directory -__wasi_path_rename -__wasi_path_symlink -__wasi_path_unlink_file -__wasi_poll_oneoff -__wasi_proc_exit -__wasi_random_get -__wasi_sched_yield -__wasi_sock_accept -__wasi_sock_recv -__wasi_sock_send -__wasi_sock_shutdown -__wasilibc_access -__wasilibc_cwd -__wasilibc_deinitialize_environ -__wasilibc_dttoif -__wasilibc_ensure_environ -__wasilibc_environ -__wasilibc_fd_renumber -__wasilibc_find_abspath -__wasilibc_find_relpath -__wasilibc_find_relpath_alloc -__wasilibc_get_environ -__wasilibc_iftodt -__wasilibc_initialize_environ -__wasilibc_link -__wasilibc_link_newat -__wasilibc_link_oldat -__wasilibc_maybe_reinitialize_environ_eagerly -__wasilibc_nocwd___wasilibc_rmdirat -__wasilibc_nocwd___wasilibc_unlinkat -__wasilibc_nocwd_faccessat -__wasilibc_nocwd_fstatat -__wasilibc_nocwd_linkat -__wasilibc_nocwd_mkdirat_nomode -__wasilibc_nocwd_openat_nomode -__wasilibc_nocwd_opendirat -__wasilibc_nocwd_readlinkat -__wasilibc_nocwd_renameat -__wasilibc_nocwd_scandirat -__wasilibc_nocwd_symlinkat -__wasilibc_nocwd_utimensat -__wasilibc_open_nomode -__wasilibc_populate_preopens -__wasilibc_register_preopened_fd -__wasilibc_rename_newat -__wasilibc_rename_oldat -__wasilibc_rmdirat -__wasilibc_stat -__wasilibc_tell -__wasilibc_unlinkat -__wasilibc_utimens -__wasm_call_dtors -__wcscoll_l -__wcsftime_l -__wcsxfrm_l -__wctrans_l -__wctype_l -__xpg_basename -__xpg_strerror_r -__year_to_secs -_environ -_exit -_flushlbf -_initialize -_start -a64l -abort -abs -accept -accept4 -access -acos -acosf -acosh -acoshf -acoshl -acosl -aligned_alloc -alphasort -alphasort64 -arc4random -arc4random_buf -arc4random_uniform -asctime -asctime_r -asin -asinf -asinh -asinhf -asinhl -asinl -asprintf -at_quick_exit -atan -atan2 -atan2f -atan2l -atanf -atanh -atanhf -atanhl -atanl -atexit -atof -atoi -atol -atoll -basename -bcmp -bcopy -bsd_signal -bsearch -btowc -bzero -c16rtomb -c32rtomb -cabs -cabsf -cabsl -cacos -cacosf -cacosh -cacoshf -cacoshl -cacosl -calloc -carg -cargf -cargl -casin -casinf -casinh -casinhf -casinhl -casinl -catan -catanf -catanh -catanhf -catanhl -catanl -catclose -catgets -catopen -cbrt -cbrtf -cbrtl -ccos -ccosf -ccosh -ccoshf -ccoshl -ccosl -ceil -ceilf -ceill -cexp -cexpf -cexpl -chdir -chmod -cimag -cimagf -cimagl -clearenv -clearerr -clearerr_unlocked -clock -clock_getres -clock_gettime -clock_nanosleep -clog -clogf -clogl -close -closedir -confstr -conj -conjf -conjl -copysign -copysignf -copysignl -cos -cosf -cosh -coshf -coshl -cosl -cpow -cpowf -cpowl -cproj -cprojf -cprojl -creal -crealf -creall -creat -creat64 -crypt -crypt_r -csin -csinf -csinh -csinhf -csinhl -csinl -csqrt -csqrtf -csqrtl -ctan -ctanf -ctanh -ctanhf -ctanhl -ctanl -ctime -ctime_r -difftime -dirfd -dirname -div -dprintf -drand48 -drem -dremf -duplocale -ecvt -encrypt -environ -erand48 -erf -erfc -erfcf -erfcl -erff -erfl -errno -exit -exp -exp10 -exp10f -exp10l -exp2 -exp2f -exp2l -expf -expl -explicit_bzero -expm1 -expm1f -expm1l -fabs -fabsf -fabsl -faccessat -fchmod -fchmodat -fclose -fcntl -fcvt -fdatasync -fdclosedir -fdim -fdimf -fdiml -fdopen -fdopendir -feclearexcept -fegetenv -fegetexceptflag -fegetround -feholdexcept -feof -feof_unlocked -feraiseexcept -ferror -ferror_unlocked -fesetenv -fesetexceptflag -fesetround -fetestexcept -feupdateenv -fflush -fflush_unlocked -ffs -ffsl -ffsll -fgetc -fgetc_unlocked -fgetln -fgetpos -fgetpos64 -fgets -fgets_unlocked -fgetwc -fgetwc_unlocked -fgetws -fgetws_unlocked -fileno -fileno_unlocked -finite -finitef -floor -floorf -floorl -fma -fmaf -fmal -fmax -fmaxf -fmaxl -fmemopen -fmin -fminf -fminl -fmod -fmodf -fmodl -fmtmsg -fnmatch -fopen -fopen64 -fopencookie -fpathconf -fprintf -fpurge -fputc -fputc_unlocked -fputs -fputs_unlocked -fputwc -fputwc_unlocked -fputws -fputws_unlocked -fread -fread_unlocked -free -freelocale -freopen -freopen64 -frexp -frexpf -frexpl -fscanf -fseek -fseeko -fseeko64 -fsetpos -fsetpos64 -fstat -fstatat -fstatvfs -fsync -ftell -ftello -ftello64 -ftime -ftruncate -futimens -futimesat -fwide -fwprintf -fwrite -fwrite_unlocked -fwscanf -gcvt -get_avphys_pages -get_nprocs -get_nprocs_conf -get_phys_pages -getc -getc_unlocked -getchar -getchar_unlocked -getcwd -getdate -getdate_err -getdelim -getdomainname -getentropy -getenv -gethostid -getline -getopt -getopt_long -getopt_long_only -getpagesize -getpid -getrusage -getsockopt -getsubopt -gettimeofday -getw -getwc -getwc_unlocked -getwchar -getwchar_unlocked -glob -glob64 -globfree -globfree64 -gmtime -gmtime_r -hcreate -hcreate_r -hdestroy -hdestroy_r -hsearch -hsearch_r -htonl -htons -hypot -hypotf -hypotl -iconv -iconv_close -iconv_open -ilogb -ilogbf -ilogbl -imaxabs -imaxdiv -in6addr_any -in6addr_loopback -index -inet_aton -inet_ntop -inet_pton -initstate -insque -ioctl -iprintf -isalnum -isalnum_l -isalpha -isalpha_l -isascii -isatty -isblank -isblank_l -iscntrl -iscntrl_l -isdigit -isdigit_l -isgraph -isgraph_l -islower -islower_l -isprint -isprint_l -ispunct -ispunct_l -isspace -isspace_l -isupper -isupper_l -iswalnum -iswalnum_l -iswalpha -iswalpha_l -iswblank -iswblank_l -iswcntrl -iswcntrl_l -iswctype -iswctype_l -iswdigit -iswdigit_l -iswgraph -iswgraph_l -iswlower -iswlower_l -iswprint -iswprint_l -iswpunct -iswpunct_l -iswspace -iswspace_l -iswupper -iswupper_l -iswxdigit -iswxdigit_l -isxdigit -isxdigit_l -j0 -j0f -j1 -j1f -jn -jnf -jrand48 -l64a -labs -lcong48 -ldexp -ldexpf -ldexpl -ldiv -lfind -lgamma -lgamma_r -lgammaf -lgammaf_r -lgammal -lgammal_r -link -linkat -llabs -lldiv -llrint -llrintf -llrintl -llround -llroundf -llroundl -localeconv -localtime -localtime_r -log -log10 -log10f -log10l -log1p -log1pf -log1pl -log2 -log2f -log2l -logb -logbf -logbl -logf -logl -lrand48 -lrint -lrintf -lrintl -lround -lroundf -lroundl -lsearch -lseek -lstat -malloc -malloc_usable_size -mblen -mbrlen -mbrtoc16 -mbrtoc32 -mbrtowc -mbsinit -mbsnrtowcs -mbsrtowcs -mbstowcs -mbtowc -memccpy -memchr -memcmp -memcpy -memmem -memmove -mempcpy -memrchr -memset -mkdir -mkdirat -mktime -mmap -modf -modff -modfl -mrand48 -munmap -nan -nanf -nanl -nanosleep -nearbyint -nearbyintf -nearbyintl -newlocale -nextafter -nextafterf -nextafterl -nexttoward -nexttowardf -nexttowardl -nftw -nftw64 -nl_langinfo -nl_langinfo_l -nrand48 -ntohl -ntohs -open -open_memstream -open_wmemstream -openat -opendir -opendirat -optarg -opterr -optind -optopt -optreset -pathconf -perror -poll -posix_close -posix_fadvise -posix_fallocate -posix_memalign -pow -pow10 -pow10f -pow10l -powf -powl -pread -preadv -printf -program_invocation_name -program_invocation_short_name -pselect -psignal -putc -putc_unlocked -putchar -putchar_unlocked -putenv -puts -putw -putwc -putwc_unlocked -putwchar -putwchar_unlocked -pwrite -pwritev -qsort -qsort_r -quick_exit -raise -rand -rand_r -random -read -readdir -readlink -readlinkat -readv -realloc -reallocarray -recv -regcomp -regerror -regexec -regfree -remainder -remainderf -remainderl -remove -remque -remquo -remquof -remquol -rename -renameat -rewind -rewinddir -rindex -rint -rintf -rintl -rmdir -round -roundf -roundl -sbrk -scalb -scalbf -scalbln -scalblnf -scalblnl -scalbn -scalbnf -scalbnl -scandir -scandirat -scanf -sched_yield -seed48 -seekdir -select -send -setbuf -setbuffer -setenv -setkey -setlinebuf -setlocale -setstate -setvbuf -shutdown -signal -signgam -significand -significandf -sin -sincos -sincosf -sincosl -sinf -sinh -sinhf -sinhl -sinl -sleep -snprintf -sprintf -sqrt -sqrtf -sqrtl -srand -srand48 -srandom -sscanf -stat -statvfs -stderr -stdin -stdout -stpcpy -stpncpy -strcasecmp -strcasecmp_l -strcasestr -strcat -strchr -strchrnul -strcmp -strcoll -strcoll_l -strcpy -strcspn -strdup -strerror -strerror_l -strerror_r -strfmon -strfmon_l -strftime -strftime_l -strlcat -strlcpy -strlen -strncasecmp -strncasecmp_l -strncat -strncmp -strncpy -strndup -strnlen -strpbrk -strptime -strrchr -strsep -strsignal -strspn -strstr -strtod -strtod_l -strtof -strtof_l -strtoimax -strtok -strtok_r -strtol -strtold -strtold_l -strtoll -strtoul -strtoull -strtoumax -strverscmp -strxfrm -strxfrm_l -swab -swprintf -swscanf -symlink -symlinkat -sysconf -tan -tanf -tanh -tanhf -tanhl -tanl -tdelete -tdestroy -telldir -tfind -tgamma -tgammaf -tgammal -thrd_sleep -time -timegm -times -timespec_get -toascii -tolower -tolower_l -toupper -toupper_l -towctrans -towctrans_l -towlower -towlower_l -towupper -towupper_l -trunc -truncate -truncf -truncl -tsearch -twalk -uname -ungetc -ungetwc -unlink -unlinkat -unsetenv -uselocale -usleep -utime -utimensat -utimes -vasprintf -vdprintf -versionsort -versionsort64 -vfprintf -vfscanf -vfwprintf -vfwscanf -vprintf -vscanf -vsnprintf -vsprintf -vsscanf -vswprintf -vswscanf -vwprintf -vwscanf -wcpcpy -wcpncpy -wcrtomb -wcscasecmp -wcscasecmp_l -wcscat -wcschr -wcscmp -wcscoll -wcscoll_l -wcscpy -wcscspn -wcsdup -wcsftime -wcsftime_l -wcslen -wcsncasecmp -wcsncasecmp_l -wcsncat -wcsncmp -wcsncpy -wcsnlen -wcsnrtombs -wcspbrk -wcsrchr -wcsrtombs -wcsspn -wcsstr -wcstod -wcstof -wcstoimax -wcstok -wcstol -wcstold -wcstoll -wcstombs -wcstoul -wcstoull -wcstoumax -wcswcs -wcswidth -wcsxfrm -wcsxfrm_l -wctob -wctomb -wctrans -wctrans_l -wctype -wctype_l -wcwidth -wmemchr -wmemcmp -wmemcpy -wmemmove -wmemset -wprintf -write -writev -wscanf -y0 -y0f -y1 -y1f -yn -ynf diff --git a/expected/wasm64-wasi/include-all.c b/expected/wasm64-wasi/include-all.c deleted file mode 100644 index 1040097ba..000000000 --- a/expected/wasm64-wasi/include-all.c +++ /dev/null @@ -1,172 +0,0 @@ -#include <__errno.h> -#include <__errno_values.h> -#include <__fd_set.h> -#include <__function___isatty.h> -#include <__functions_malloc.h> -#include <__functions_memcpy.h> -#include <__header_dirent.h> -#include <__header_fcntl.h> -#include <__header_inttypes.h> -#include <__header_netinet_in.h> -#include <__header_poll.h> -#include <__header_stdlib.h> -#include <__header_string.h> -#include <__header_sys_ioctl.h> -#include <__header_sys_resource.h> -#include <__header_sys_socket.h> -#include <__header_sys_stat.h> -#include <__header_time.h> -#include <__header_unistd.h> -#include <__macro_FD_SETSIZE.h> -#include <__macro_PAGESIZE.h> -#include <__mode_t.h> -#include <__seek.h> -#include <__struct_dirent.h> -#include <__struct_in6_addr.h> -#include <__struct_in_addr.h> -#include <__struct_iovec.h> -#include <__struct_msghdr.h> -#include <__struct_pollfd.h> -#include <__struct_rusage.h> -#include <__struct_sockaddr.h> -#include <__struct_sockaddr_in.h> -#include <__struct_sockaddr_in6.h> -#include <__struct_sockaddr_storage.h> -#include <__struct_sockaddr_un.h> -#include <__struct_stat.h> -#include <__struct_timespec.h> -#include <__struct_timeval.h> -#include <__struct_tm.h> -#include <__struct_tms.h> -#include <__typedef_DIR.h> -#include <__typedef_blkcnt_t.h> -#include <__typedef_blksize_t.h> -#include <__typedef_clock_t.h> -#include <__typedef_clockid_t.h> -#include <__typedef_dev_t.h> -#include <__typedef_fd_set.h> -#include <__typedef_gid_t.h> -#include <__typedef_in_addr_t.h> -#include <__typedef_in_port_t.h> -#include <__typedef_ino_t.h> -#include <__typedef_mode_t.h> -#include <__typedef_nfds_t.h> -#include <__typedef_nlink_t.h> -#include <__typedef_off_t.h> -#include <__typedef_sa_family_t.h> -#include <__typedef_sigset_t.h> -#include <__typedef_socklen_t.h> -#include <__typedef_ssize_t.h> -#include <__typedef_suseconds_t.h> -#include <__typedef_time_t.h> -#include <__typedef_uid_t.h> -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include diff --git a/expected/wasm64-wasi/predefined-macros.txt b/expected/wasm64-wasi/predefined-macros.txt deleted file mode 100644 index 06ca96d05..000000000 --- a/expected/wasm64-wasi/predefined-macros.txt +++ /dev/null @@ -1,3381 +0,0 @@ -#define ABDAY_1 0x20000 -#define ABDAY_2 0x20001 -#define ABDAY_3 0x20002 -#define ABDAY_4 0x20003 -#define ABDAY_5 0x20004 -#define ABDAY_6 0x20005 -#define ABDAY_7 0x20006 -#define ABMON_1 0x2000E -#define ABMON_10 0x20017 -#define ABMON_11 0x20018 -#define ABMON_12 0x20019 -#define ABMON_2 0x2000F -#define ABMON_3 0x20010 -#define ABMON_4 0x20011 -#define ABMON_5 0x20012 -#define ABMON_6 0x20013 -#define ABMON_7 0x20014 -#define ABMON_8 0x20015 -#define ABMON_9 0x20016 -#define ABORT 238 -#define ACK 04 -#define ADD ns_uop_add -#define ADJ_ESTERROR 0x0008 -#define ADJ_FREQUENCY 0x0002 -#define ADJ_MAXERROR 0x0004 -#define ADJ_MICRO 0x1000 -#define ADJ_NANO 0x2000 -#define ADJ_OFFSET 0x0001 -#define ADJ_OFFSET_SINGLESHOT 0x8001 -#define ADJ_OFFSET_SS_READ 0xa001 -#define ADJ_SETOFFSET 0x0100 -#define ADJ_STATUS 0x0010 -#define ADJ_TAI 0x0080 -#define ADJ_TICK 0x4000 -#define ADJ_TIMECONST 0x0020 -#define AF_INET PF_INET -#define AF_INET6 PF_INET6 -#define AF_UNIX 3 -#define AF_UNSPEC PF_UNSPEC -#define ALT_DIGITS 0x2002F -#define AM_STR 0x20026 -#define ANYMARK 0x01 -#define AO 245 -#define AREGTYPE '\0' -#define ARFMAG "`\n" -#define ARG_MAX 131072 -#define ARMAG "!\n" -#define AT_EACCESS (0x0) -#define AT_FDCWD (-2) -#define AT_REMOVEDIR (0x4) -#define AT_SYMLINK_FOLLOW (0x2) -#define AT_SYMLINK_NOFOLLOW (0x1) -#define AUTHTYPE_CNT 5 -#define AUTHTYPE_KERBEROS_V4 1 -#define AUTHTYPE_KERBEROS_V5 2 -#define AUTHTYPE_MINK 4 -#define AUTHTYPE_NAME(x) authtype_names[x] -#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) -#define AUTHTYPE_NULL 0 -#define AUTHTYPE_SPX 3 -#define AUTHTYPE_TEST 99 -#define AUTH_HOW_MASK 2 -#define AUTH_HOW_MUTUAL 2 -#define AUTH_HOW_ONE_WAY 0 -#define AUTH_WHO_CLIENT 0 -#define AUTH_WHO_MASK 1 -#define AUTH_WHO_SERVER 1 -#define AYT 246 -#define BIG_ENDIAN __BIG_ENDIAN -#define BITSPERBYTE CHAR_BIT -#define BLKTYPE '4' -#define BLK_BYTECOUNT 2 -#define BLK_EOF 0x40 -#define BLK_EOR 0x80 -#define BLK_ERRORS 0x20 -#define BLK_RESTART 0x10 -#define BREAK 243 -#define BUFSIZ 1024 -#define BYTE_ORDER __BYTE_ORDER -#define CANBSIZ 255 -#define CBRK CEOL -#define CDISCARD CTRL('o') -#define CDSUSP CTRL('y') -#define CEOF CTRL('d') -#define CEOL '\0' -#define CEOT CEOF -#define CERASE 0177 -#define CFLUSH CDISCARD -#define CHARBITS (sizeof(char) * 8) -#define CHARCLASS_NAME_MAX 14 -#define CHAR_BIT 8 -#define CHAR_MAX 127 -#define CHAR_MIN (-128) -#define CHRTYPE '3' -#define CINTR CTRL('c') -#define CKILL CTRL('u') -#define CLNEXT CTRL('v') -#define CLOCKS_PER_SEC ((clock_t)1000000000) -#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) -#define CLOCK_REALTIME (&_CLOCK_REALTIME) -#define CMIN 1 -#define CMPLX(x,y) __CMPLX(x, y, double) -#define CMPLXF(x,y) __CMPLX(x, y, float) -#define CMPLXL(x,y) __CMPLX(x, y, long double) -#define CODESET 14 -#define COLL_WEIGHTS_MAX 2 -#define COMPLETE 2 -#define CONTINUE 3 -#define CONTTYPE '7' -#define CQUIT 034 -#define CREPRINT CTRL('r') -#define CRNCYSTR 0x4000F -#define CRPRNT CREPRINT -#define CSTART CTRL('q') -#define CSTATUS '\0' -#define CSTOP CTRL('s') -#define CSUSP CTRL('z') -#define CTIME 0 -#define CTRL(x) ((x)&037) -#define CWERASE CTRL('w') -#define C_ANY ns_c_any -#define C_CHAOS ns_c_chaos -#define C_HS ns_c_hs -#define C_IN ns_c_in -#define C_IRGRP 000040 -#define C_IROTH 000004 -#define C_IRUSR 000400 -#define C_ISBLK 060000 -#define C_ISCHR 020000 -#define C_ISCTG 0110000 -#define C_ISDIR 040000 -#define C_ISFIFO 010000 -#define C_ISGID 002000 -#define C_ISLNK 0120000 -#define C_ISREG 0100000 -#define C_ISSOCK 0140000 -#define C_ISUID 004000 -#define C_ISVTX 001000 -#define C_IWGRP 000020 -#define C_IWOTH 000002 -#define C_IWUSR 000200 -#define C_IXGRP 000010 -#define C_IXOTH 000001 -#define C_IXUSR 000100 -#define C_NONE ns_c_none -#define DATA 03 -#define DAY_1 0x20007 -#define DAY_2 0x20008 -#define DAY_3 0x20009 -#define DAY_4 0x2000A -#define DAY_5 0x2000B -#define DAY_6 0x2000C -#define DAY_7 0x2000D -#define DBL_DECIMAL_DIG 17 -#define DBL_DIG 15 -#define DBL_EPSILON 2.22044604925031308085e-16 -#define DBL_HAS_SUBNORM 1 -#define DBL_MANT_DIG 53 -#define DBL_MAX 1.79769313486231570815e+308 -#define DBL_MAX_10_EXP 308 -#define DBL_MAX_EXP 1024 -#define DBL_MIN 2.22507385850720138309e-308 -#define DBL_MIN_10_EXP (-307) -#define DBL_MIN_EXP (-1021) -#define DBL_TRUE_MIN 4.94065645841246544177e-324 -#define DECIMAL_DIG 36 -#define DELAYTIMER_MAX 0x7fffffff -#define DELETE ns_uop_delete -#define DEV_BSIZE 512 -#define DIRTYPE '5' -#define DM 242 -#define DMAXEXP DBL_MAX_EXP -#define DMINEXP DBL_MIN_EXP -#define DO 253 -#define DONT 254 -#define DOUBLEBITS (sizeof(double) * 8) -#define DTTOIF(x) (__wasilibc_dttoif(x)) -#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE -#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE -#define DT_DIR __WASI_FILETYPE_DIRECTORY -#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM -#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK -#define DT_REG __WASI_FILETYPE_REGULAR_FILE -#define DT_SOCK 20 -#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN -#define D_FMT 0x20029 -#define D_T_FMT 0x20028 -#define E2BIG __WASI_ERRNO_2BIG -#define EACCES __WASI_ERRNO_ACCES -#define EACCESS 2 -#define EADDRINUSE __WASI_ERRNO_ADDRINUSE -#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL -#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT -#define EAGAIN __WASI_ERRNO_AGAIN -#define EALREADY __WASI_ERRNO_ALREADY -#define EBADF __WASI_ERRNO_BADF -#define EBADID 5 -#define EBADMSG __WASI_ERRNO_BADMSG -#define EBADOP 4 -#define EBUSY __WASI_ERRNO_BUSY -#define EC 247 -#define ECANCELED __WASI_ERRNO_CANCELED -#define ECHILD __WASI_ERRNO_CHILD -#define ECONNABORTED __WASI_ERRNO_CONNABORTED -#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED -#define ECONNRESET __WASI_ERRNO_CONNRESET -#define EDEADLK __WASI_ERRNO_DEADLK -#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ -#define EDOM __WASI_ERRNO_DOM -#define EDQUOT __WASI_ERRNO_DQUOT -#define EEXIST __WASI_ERRNO_EXIST -#define EEXISTS 6 -#define EFAULT __WASI_ERRNO_FAULT -#define EFBIG __WASI_ERRNO_FBIG -#define EFD_CLOEXEC O_CLOEXEC -#define EFD_NONBLOCK O_NONBLOCK -#define EFD_SEMAPHORE 1 -#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH -#define EIDRM __WASI_ERRNO_IDRM -#define EILSEQ __WASI_ERRNO_ILSEQ -#define EINPROGRESS __WASI_ERRNO_INPROGRESS -#define EINTR __WASI_ERRNO_INTR -#define EINVAL __WASI_ERRNO_INVAL -#define EIO __WASI_ERRNO_IO -#define EISCONN __WASI_ERRNO_ISCONN -#define EISDIR __WASI_ERRNO_ISDIR -#define EL 248 -#define ELOOP __WASI_ERRNO_LOOP -#define EMFILE __WASI_ERRNO_MFILE -#define EMLINK __WASI_ERRNO_MLINK -#define EMSGSIZE __WASI_ERRNO_MSGSIZE -#define EMULTIHOP __WASI_ERRNO_MULTIHOP -#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG -#define ENCRYPT_CNT 9 -#define ENCRYPT_DEC_KEYID 8 -#define ENCRYPT_ENC_KEYID 7 -#define ENCRYPT_END 4 -#define ENCRYPT_IS 0 -#define ENCRYPT_NAME(x) encrypt_names[x] -#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) -#define ENCRYPT_REPLY 2 -#define ENCRYPT_REQEND 6 -#define ENCRYPT_REQSTART 5 -#define ENCRYPT_START 3 -#define ENCRYPT_SUPPORT 1 -#define ENCTYPE_ANY 0 -#define ENCTYPE_CNT 3 -#define ENCTYPE_DES_CFB64 1 -#define ENCTYPE_DES_OFB64 2 -#define ENCTYPE_NAME(x) enctype_names[x] -#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) -#define ENETDOWN __WASI_ERRNO_NETDOWN -#define ENETRESET __WASI_ERRNO_NETRESET -#define ENETUNREACH __WASI_ERRNO_NETUNREACH -#define ENFILE __WASI_ERRNO_NFILE -#define ENOBUFS __WASI_ERRNO_NOBUFS -#define ENODEV __WASI_ERRNO_NODEV -#define ENOENT __WASI_ERRNO_NOENT -#define ENOEXEC __WASI_ERRNO_NOEXEC -#define ENOLCK __WASI_ERRNO_NOLCK -#define ENOLINK __WASI_ERRNO_NOLINK -#define ENOMEM __WASI_ERRNO_NOMEM -#define ENOMSG __WASI_ERRNO_NOMSG -#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT -#define ENOSPACE 3 -#define ENOSPC __WASI_ERRNO_NOSPC -#define ENOSYS __WASI_ERRNO_NOSYS -#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE -#define ENOTCONN __WASI_ERRNO_NOTCONN -#define ENOTDIR __WASI_ERRNO_NOTDIR -#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY -#define ENOTFOUND 1 -#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE -#define ENOTSOCK __WASI_ERRNO_NOTSOCK -#define ENOTSUP __WASI_ERRNO_NOTSUP -#define ENOTTY __WASI_ERRNO_NOTTY -#define ENOUSER 7 -#define ENV_ESC 2 -#define ENV_USERVAR 3 -#define ENXIO __WASI_ERRNO_NXIO -#define EOF (-1) -#define EOPNOTSUPP ENOTSUP -#define EOR 239 -#define EOVERFLOW __WASI_ERRNO_OVERFLOW -#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD -#define EPERM __WASI_ERRNO_PERM -#define EPIPE __WASI_ERRNO_PIPE -#define EPROTO __WASI_ERRNO_PROTO -#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT -#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE -#define ERA 0x2002C -#define ERANGE __WASI_ERRNO_RANGE -#define ERA_D_FMT 0x2002E -#define ERA_D_T_FMT 0x20030 -#define ERA_T_FMT 0x20031 -#define EROFS __WASI_ERRNO_ROFS -#define ERROR 05 -#define ESPIPE __WASI_ERRNO_SPIPE -#define ESRCH __WASI_ERRNO_SRCH -#define ESTALE __WASI_ERRNO_STALE -#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT -#define ETXTBSY __WASI_ERRNO_TXTBSY -#define EUNDEF 0 -#define EWOULDBLOCK EAGAIN -#define EXDEV __WASI_ERRNO_XDEV -#define EXIT_FAILURE 1 -#define EXIT_SUCCESS 0 -#define EX_CANTCREAT 73 -#define EX_CONFIG 78 -#define EX_DATAERR 65 -#define EX_IOERR 74 -#define EX_NOHOST 68 -#define EX_NOINPUT 66 -#define EX_NOPERM 77 -#define EX_NOUSER 67 -#define EX_OK 0 -#define EX_OSERR 71 -#define EX_OSFILE 72 -#define EX_PROTOCOL 76 -#define EX_SOFTWARE 70 -#define EX_TEMPFAIL 75 -#define EX_UNAVAILABLE 69 -#define EX_USAGE 64 -#define EX__BASE 64 -#define EX__MAX 78 -#define FD_CLOEXEC (1) -#define FD_CLR(fd,set) (FD_CLR((fd), (set))) -#define FD_COPY(from,to) (FD_COPY((from), (to))) -#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) -#define FD_SET(fd,set) (FD_SET((fd), (set))) -#define FD_SETSIZE 1024 -#define FD_ZERO(set) (FD_ZERO((set))) -#define FE_ALL_EXCEPT 0 -#define FE_DFL_ENV ((const fenv_t *) -1) -#define FE_TONEAREST 0 -#define FIFOTYPE '6' -#define FILENAME_MAX 4096 -#define FILESIZEBITS 64 -#define FIONBIO 2 -#define FIONREAD 1 -#define FLOATBITS (sizeof(float) * 8) -#define FLT_DECIMAL_DIG 9 -#define FLT_DIG 6 -#define FLT_EPSILON 1.1920928955078125e-07F -#define FLT_EVAL_METHOD 0 -#define FLT_HAS_SUBNORM 1 -#define FLT_MANT_DIG 24 -#define FLT_MAX 3.40282346638528859812e+38F -#define FLT_MAX_10_EXP 38 -#define FLT_MAX_EXP 128 -#define FLT_MIN 1.17549435082228750797e-38F -#define FLT_MIN_10_EXP (-37) -#define FLT_MIN_EXP (-125) -#define FLT_RADIX 2 -#define FLT_ROUNDS (__builtin_flt_rounds()) -#define FLT_TRUE_MIN 1.40129846432481707092e-45F -#define FLUSHBAND 0x04 -#define FLUSHR 0x01 -#define FLUSHRW 0x03 -#define FLUSHW 0x02 -#define FMAXEXP FLT_MAX_EXP -#define FMINEXP FLT_MIN_EXP -#define FMNAMESZ 8 -#define FNM_CASEFOLD 0x10 -#define FNM_FILE_NAME FNM_PATHNAME -#define FNM_LEADING_DIR 0x8 -#define FNM_NOESCAPE 0x2 -#define FNM_NOMATCH 1 -#define FNM_NOSYS (-1) -#define FNM_PATHNAME 0x1 -#define FNM_PERIOD 0x4 -#define FOPEN_MAX 1000 -#define FORMERR ns_r_formerr -#define FORM_C 3 -#define FORM_N 1 -#define FORM_T 2 -#define FP_ILOGB0 FP_ILOGBNAN -#define FP_ILOGBNAN (-1-0x7fffffff) -#define FP_INFINITE 1 -#define FP_NAN 0 -#define FP_NORMAL 4 -#define FP_SUBNORMAL 3 -#define FP_ZERO 2 -#define FSETLOCKING_BYCALLER 2 -#define FSETLOCKING_INTERNAL 1 -#define FSETLOCKING_QUERY 0 -#define FTW_CHDIR 4 -#define FTW_D 2 -#define FTW_DEPTH 8 -#define FTW_DNR 3 -#define FTW_DP 6 -#define FTW_F 1 -#define FTW_MOUNT 2 -#define FTW_NS 4 -#define FTW_PHYS 1 -#define FTW_SL 5 -#define FTW_SLN 7 -#define F_GETFD (1) -#define F_GETFL (3) -#define F_LOCK 1 -#define F_OK (0) -#define F_SETFD (2) -#define F_SETFL (4) -#define F_TEST 3 -#define F_TLOCK 2 -#define F_ULOCK 0 -#define GA 249 -#define GETLONG NS_GET32 -#define GETSHORT NS_GET16 -#define GLOB_ABORTED 2 -#define GLOB_APPEND 0x20 -#define GLOB_DOOFFS 0x08 -#define GLOB_ERR 0x01 -#define GLOB_MARK 0x02 -#define GLOB_NOCHECK 0x10 -#define GLOB_NOESCAPE 0x40 -#define GLOB_NOMATCH 3 -#define GLOB_NOSORT 0x04 -#define GLOB_NOSPACE 1 -#define GLOB_NOSYS 4 -#define GLOB_PERIOD 0x80 -#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) -#define HFIXEDSZ NS_HFIXEDSZ -#define HIBITL MINLONG -#define HIBITS MINSHORT -#define HOST_NAME_MAX 255 -#define HUGE 3.40282346638528859812e+38F -#define HUGE_VAL ((double)INFINITY) -#define HUGE_VALF INFINITY -#define HUGE_VALL ((long double)INFINITY) -#define I _Complex_I -#define IAC 255 -#define ICMP6_DST_UNREACH 1 -#define ICMP6_DST_UNREACH_ADDR 3 -#define ICMP6_DST_UNREACH_ADMIN 1 -#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 -#define ICMP6_DST_UNREACH_NOPORT 4 -#define ICMP6_DST_UNREACH_NOROUTE 0 -#define ICMP6_ECHO_REPLY 129 -#define ICMP6_ECHO_REQUEST 128 -#define ICMP6_FILTER 1 -#define ICMP6_FILTER_BLOCK 1 -#define ICMP6_FILTER_BLOCKOTHERS 3 -#define ICMP6_FILTER_PASS 2 -#define ICMP6_FILTER_PASSONLY 4 -#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) -#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) -#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) -#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) -#define ICMP6_INFOMSG_MASK 0x80 -#define ICMP6_PACKET_TOO_BIG 2 -#define ICMP6_PARAMPROB_HEADER 0 -#define ICMP6_PARAMPROB_NEXTHEADER 1 -#define ICMP6_PARAMPROB_OPTION 2 -#define ICMP6_PARAM_PROB 4 -#define ICMP6_ROUTER_RENUMBERING 138 -#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 -#define ICMP6_RR_FLAGS_PREVDONE 0x08 -#define ICMP6_RR_FLAGS_REQRESULT 0x40 -#define ICMP6_RR_FLAGS_SPECSITE 0x10 -#define ICMP6_RR_FLAGS_TEST 0x80 -#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 -#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 -#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 -#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 -#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 -#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 -#define ICMP6_TIME_EXCEEDED 3 -#define ICMP6_TIME_EXCEED_REASSEMBLY 1 -#define ICMP6_TIME_EXCEED_TRANSIT 0 -#define ICMP_ADDRESS 17 -#define ICMP_ADDRESSREPLY 18 -#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) -#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) -#define ICMP_DEST_UNREACH 3 -#define ICMP_ECHO 8 -#define ICMP_ECHOREPLY 0 -#define ICMP_EXC_FRAGTIME 1 -#define ICMP_EXC_TTL 0 -#define ICMP_FRAG_NEEDED 4 -#define ICMP_HOST_ANO 10 -#define ICMP_HOST_ISOLATED 8 -#define ICMP_HOST_UNKNOWN 7 -#define ICMP_HOST_UNREACH 1 -#define ICMP_HOST_UNR_TOS 12 -#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) -#define ICMP_INFO_REPLY 16 -#define ICMP_INFO_REQUEST 15 -#define ICMP_IREQ 15 -#define ICMP_IREQREPLY 16 -#define ICMP_MASKLEN 12 -#define ICMP_MASKREPLY 18 -#define ICMP_MASKREQ 17 -#define ICMP_MAXTYPE 18 -#define ICMP_MINLEN 8 -#define ICMP_NET_ANO 9 -#define ICMP_NET_UNKNOWN 6 -#define ICMP_NET_UNREACH 0 -#define ICMP_NET_UNR_TOS 11 -#define ICMP_PARAMETERPROB 12 -#define ICMP_PARAMPROB 12 -#define ICMP_PARAMPROB_OPTABSENT 1 -#define ICMP_PKT_FILTERED 13 -#define ICMP_PORT_UNREACH 3 -#define ICMP_PREC_CUTOFF 15 -#define ICMP_PREC_VIOLATION 14 -#define ICMP_PROT_UNREACH 2 -#define ICMP_REDIRECT 5 -#define ICMP_REDIRECT_HOST 1 -#define ICMP_REDIRECT_NET 0 -#define ICMP_REDIRECT_TOSHOST 3 -#define ICMP_REDIRECT_TOSNET 2 -#define ICMP_REDIR_HOST 1 -#define ICMP_REDIR_HOSTTOS 3 -#define ICMP_REDIR_NET 0 -#define ICMP_REDIR_NETTOS 2 -#define ICMP_ROUTERADVERT 9 -#define ICMP_ROUTERSOLICIT 10 -#define ICMP_SOURCEQUENCH 4 -#define ICMP_SOURCE_QUENCH 4 -#define ICMP_SR_FAILED 5 -#define ICMP_TIMESTAMP 13 -#define ICMP_TIMESTAMPREPLY 14 -#define ICMP_TIME_EXCEEDED 11 -#define ICMP_TIMXCEED 11 -#define ICMP_TIMXCEED_INTRANS 0 -#define ICMP_TIMXCEED_REASS 1 -#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) -#define ICMP_TSTAMP 13 -#define ICMP_TSTAMPREPLY 14 -#define ICMP_UNREACH 3 -#define ICMP_UNREACH_FILTER_PROHIB 13 -#define ICMP_UNREACH_HOST 1 -#define ICMP_UNREACH_HOST_PRECEDENCE 14 -#define ICMP_UNREACH_HOST_PROHIB 10 -#define ICMP_UNREACH_HOST_UNKNOWN 7 -#define ICMP_UNREACH_ISOLATED 8 -#define ICMP_UNREACH_NEEDFRAG 4 -#define ICMP_UNREACH_NET 0 -#define ICMP_UNREACH_NET_PROHIB 9 -#define ICMP_UNREACH_NET_UNKNOWN 6 -#define ICMP_UNREACH_PORT 3 -#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 -#define ICMP_UNREACH_PROTOCOL 2 -#define ICMP_UNREACH_SRCFAIL 5 -#define ICMP_UNREACH_TOSHOST 12 -#define ICMP_UNREACH_TOSNET 11 -#define IFTODT(x) (__wasilibc_iftodt(x)) -#define IGMP_AWAKENING_MEMBER 5 -#define IGMP_DELAYING_MEMBER 1 -#define IGMP_DVMRP 0x13 -#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP -#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY -#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT -#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT -#define IGMP_IDLE_MEMBER 2 -#define IGMP_LAZY_MEMBER 3 -#define IGMP_MAX_HOST_REPORT_DELAY 10 -#define IGMP_MEMBERSHIP_QUERY 0x11 -#define IGMP_MINLEN 8 -#define IGMP_MTRACE 0x1f -#define IGMP_MTRACE_RESP 0x1e -#define IGMP_PIM 0x14 -#define IGMP_SLEEPING_MEMBER 4 -#define IGMP_TIMER_SCALE 10 -#define IGMP_TRACE 0x15 -#define IGMP_V1_MEMBERSHIP_REPORT 0x12 -#define IGMP_V2_LEAVE_GROUP 0x17 -#define IGMP_V2_MEMBERSHIP_REPORT 0x16 -#define IGMP_v1_ROUTER 1 -#define IGMP_v2_ROUTER 2 -#define IN6ADDRSZ NS_IN6ADDRSZ -#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } -#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } -#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) -#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) -#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) -#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) -#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) -#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) -#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) -#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) -#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) -#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) -#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) -#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) -#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) -#define INADDRSZ NS_INADDRSZ -#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) -#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) -#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) -#define INADDR_ANY ((in_addr_t) 0x00000000) -#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) -#define INADDR_DUMMY ((in_addr_t) 0xc0000008) -#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) -#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) -#define INADDR_NONE ((in_addr_t) 0xffffffff) -#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) -#define INDIR_MASK NS_CMPRSFLGS -#define INET6_ADDRSTRLEN 46 -#define INET_ADDRSTRLEN 16 -#define INFINITY 1e5000f -#define INT16SZ NS_INT16SZ -#define INT16_C(c) c -#define INT16_MAX (0x7fff) -#define INT16_MIN (-1-0x7fff) -#define INT32SZ NS_INT32SZ -#define INT32_C(c) c -#define INT32_MAX (0x7fffffff) -#define INT32_MIN (-1-0x7fffffff) -#define INT64_C(c) c ## LL -#define INT64_MAX (0x7fffffffffffffff) -#define INT64_MIN (-1-0x7fffffffffffffff) -#define INT8SZ NS_INT8SZ -#define INT8_C(c) c -#define INT8_MAX (0x7f) -#define INT8_MIN (-1-0x7f) -#define INTBITS (sizeof(int) * 8) -#define INTMAX_C(c) c ## LL -#define INTMAX_MAX INT64_MAX -#define INTMAX_MIN INT64_MIN -#define INTPTR_MAX INT32_MAX -#define INTPTR_MIN INT32_MIN -#define INT_FAST16_MAX INT16_MAX -#define INT_FAST16_MIN INT16_MIN -#define INT_FAST32_MAX INT32_MAX -#define INT_FAST32_MIN INT32_MIN -#define INT_FAST64_MAX INT64_MAX -#define INT_FAST64_MIN INT64_MIN -#define INT_FAST8_MAX INT8_MAX -#define INT_FAST8_MIN INT8_MIN -#define INT_LEAST16_MAX INT16_MAX -#define INT_LEAST16_MIN INT16_MIN -#define INT_LEAST32_MAX INT32_MAX -#define INT_LEAST32_MIN INT32_MIN -#define INT_LEAST64_MAX INT64_MAX -#define INT_LEAST64_MIN INT64_MIN -#define INT_LEAST8_MAX INT8_MAX -#define INT_LEAST8_MIN INT8_MIN -#define INT_MAX 0x7fffffff -#define INT_MIN (-1-0x7fffffff) -#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) -#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) -#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) -#define IN_CLASSA_MAX 128 -#define IN_CLASSA_NET 0xff000000 -#define IN_CLASSA_NSHIFT 24 -#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) -#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) -#define IN_CLASSB_MAX 65536 -#define IN_CLASSB_NET 0xffff0000 -#define IN_CLASSB_NSHIFT 16 -#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) -#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) -#define IN_CLASSC_NET 0xffffff00 -#define IN_CLASSC_NSHIFT 8 -#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) -#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) -#define IN_LOOPBACKNET 127 -#define IN_MULTICAST(a) IN_CLASSD(a) -#define IOV_MAX 1024 -#define IP 244 -#define IP6F_MORE_FRAG 0x0100 -#define IP6F_OFF_MASK 0xf8ff -#define IP6F_RESERVED_MASK 0x0600 -#define IP6OPT_JUMBO 0xc2 -#define IP6OPT_JUMBO_LEN 6 -#define IP6OPT_NSAP_ADDR 0xc3 -#define IP6OPT_PAD1 0 -#define IP6OPT_PADN 1 -#define IP6OPT_ROUTER_ALERT 0x05 -#define IP6OPT_TUNNEL_LIMIT 0x04 -#define IP6OPT_TYPE(o) ((o) & 0xc0) -#define IP6OPT_TYPE_DISCARD 0x40 -#define IP6OPT_TYPE_FORCEICMP 0x80 -#define IP6OPT_TYPE_ICMP 0xc0 -#define IP6OPT_TYPE_MUTABLE 0x20 -#define IP6OPT_TYPE_SKIP 0x00 -#define IP6_ALERT_AN 0x0200 -#define IP6_ALERT_MLD 0x0000 -#define IP6_ALERT_RSVP 0x0100 -#define IPDEFTTL 64 -#define IPFRAGTTL 60 -#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) -#define IPOPT_CLASS_MASK 0x60 -#define IPOPT_CONTROL 0x00 -#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) -#define IPOPT_COPY 0x80 -#define IPOPT_DEBMEAS 0x40 -#define IPOPT_END IPOPT_EOL -#define IPOPT_EOL 0 -#define IPOPT_LSRR 131 -#define IPOPT_MEASUREMENT IPOPT_DEBMEAS -#define IPOPT_MINOFF 4 -#define IPOPT_NOOP IPOPT_NOP -#define IPOPT_NOP 1 -#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) -#define IPOPT_NUMBER_MASK 0x1f -#define IPOPT_OFFSET 2 -#define IPOPT_OLEN 1 -#define IPOPT_OPTVAL 0 -#define IPOPT_RA 148 -#define IPOPT_RESERVED1 0x20 -#define IPOPT_RESERVED2 0x60 -#define IPOPT_RR 7 -#define IPOPT_SATID 136 -#define IPOPT_SEC IPOPT_SECURITY -#define IPOPT_SECURITY 130 -#define IPOPT_SECUR_CONFID 0xf135 -#define IPOPT_SECUR_EFTO 0x789a -#define IPOPT_SECUR_MMMM 0xbc4d -#define IPOPT_SECUR_RESTR 0xaf13 -#define IPOPT_SECUR_SECRET 0xd788 -#define IPOPT_SECUR_TOPSECRET 0x6bc5 -#define IPOPT_SECUR_UNCLASS 0x0000 -#define IPOPT_SID IPOPT_SATID -#define IPOPT_SSRR 137 -#define IPOPT_TIMESTAMP IPOPT_TS -#define IPOPT_TS 68 -#define IPOPT_TS_PRESPEC 3 -#define IPOPT_TS_TSANDADDR 1 -#define IPOPT_TS_TSONLY 0 -#define IPPORT_RESERVED 1024 -#define IPPROTO_ICMP 1 -#define IPPROTO_IP 0 -#define IPPROTO_IPV6 41 -#define IPPROTO_RAW 255 -#define IPPROTO_TCP 6 -#define IPPROTO_UDP 17 -#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) -#define IPTOS_CLASS_CS0 0x00 -#define IPTOS_CLASS_CS1 0x20 -#define IPTOS_CLASS_CS2 0x40 -#define IPTOS_CLASS_CS3 0x60 -#define IPTOS_CLASS_CS4 0x80 -#define IPTOS_CLASS_CS5 0xa0 -#define IPTOS_CLASS_CS6 0xc0 -#define IPTOS_CLASS_CS7 0xe0 -#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 -#define IPTOS_CLASS_MASK 0xe0 -#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) -#define IPTOS_DSCP_AF11 0x28 -#define IPTOS_DSCP_AF12 0x30 -#define IPTOS_DSCP_AF13 0x38 -#define IPTOS_DSCP_AF21 0x48 -#define IPTOS_DSCP_AF22 0x50 -#define IPTOS_DSCP_AF23 0x58 -#define IPTOS_DSCP_AF31 0x68 -#define IPTOS_DSCP_AF32 0x70 -#define IPTOS_DSCP_AF33 0x78 -#define IPTOS_DSCP_AF41 0x88 -#define IPTOS_DSCP_AF42 0x90 -#define IPTOS_DSCP_AF43 0x98 -#define IPTOS_DSCP_EF 0xb8 -#define IPTOS_DSCP_MASK 0xfc -#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) -#define IPTOS_ECN_CE 0x03 -#define IPTOS_ECN_ECT0 0x02 -#define IPTOS_ECN_ECT1 0x01 -#define IPTOS_ECN_MASK 0x03 -#define IPTOS_ECN_NOT_ECT 0x00 -#define IPTOS_LOWCOST 0x02 -#define IPTOS_LOWDELAY 0x10 -#define IPTOS_MINCOST IPTOS_LOWCOST -#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) -#define IPTOS_PREC_CRITIC_ECP 0xa0 -#define IPTOS_PREC_FLASH 0x60 -#define IPTOS_PREC_FLASHOVERRIDE 0x80 -#define IPTOS_PREC_IMMEDIATE 0x40 -#define IPTOS_PREC_INTERNETCONTROL 0xc0 -#define IPTOS_PREC_MASK 0xe0 -#define IPTOS_PREC_NETCONTROL 0xe0 -#define IPTOS_PREC_PRIORITY 0x20 -#define IPTOS_PREC_ROUTINE 0x00 -#define IPTOS_RELIABILITY 0x04 -#define IPTOS_THROUGHPUT 0x08 -#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) -#define IPTOS_TOS_MASK 0x1E -#define IPTTLDEC 1 -#define IPV6_2292DSTOPTS 4 -#define IPV6_2292HOPLIMIT 8 -#define IPV6_2292HOPOPTS 3 -#define IPV6_2292PKTINFO 2 -#define IPV6_2292PKTOPTIONS 6 -#define IPV6_2292RTHDR 5 -#define IPV6_ADDRFORM 1 -#define IPV6_ADDR_PREFERENCES 72 -#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP -#define IPV6_AUTHHDR 10 -#define IPV6_AUTOFLOWLABEL 70 -#define IPV6_CHECKSUM 7 -#define IPV6_DONTFRAG 62 -#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP -#define IPV6_DSTOPTS 59 -#define IPV6_FREEBIND 78 -#define IPV6_HDRINCL 36 -#define IPV6_HOPLIMIT 52 -#define IPV6_HOPOPTS 54 -#define IPV6_IPSEC_POLICY 34 -#define IPV6_JOIN_ANYCAST 27 -#define IPV6_JOIN_GROUP 20 -#define IPV6_LEAVE_ANYCAST 28 -#define IPV6_LEAVE_GROUP 21 -#define IPV6_MINHOPCOUNT 73 -#define IPV6_MTU 24 -#define IPV6_MTU_DISCOVER 23 -#define IPV6_MULTICAST_ALL 29 -#define IPV6_MULTICAST_HOPS 18 -#define IPV6_MULTICAST_IF 17 -#define IPV6_MULTICAST_LOOP 19 -#define IPV6_NEXTHOP 9 -#define IPV6_ORIGDSTADDR 74 -#define IPV6_PATHMTU 61 -#define IPV6_PKTINFO 50 -#define IPV6_PMTUDISC_DO 2 -#define IPV6_PMTUDISC_DONT 0 -#define IPV6_PMTUDISC_INTERFACE 4 -#define IPV6_PMTUDISC_OMIT 5 -#define IPV6_PMTUDISC_PROBE 3 -#define IPV6_PMTUDISC_WANT 1 -#define IPV6_PREFER_SRC_CGA 0x0008 -#define IPV6_PREFER_SRC_COA 0x0004 -#define IPV6_PREFER_SRC_HOME 0x0400 -#define IPV6_PREFER_SRC_NONCGA 0x0800 -#define IPV6_PREFER_SRC_PUBLIC 0x0002 -#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 -#define IPV6_PREFER_SRC_TMP 0x0001 -#define IPV6_RECVDSTOPTS 58 -#define IPV6_RECVERR 25 -#define IPV6_RECVFRAGSIZE 77 -#define IPV6_RECVHOPLIMIT 51 -#define IPV6_RECVHOPOPTS 53 -#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR -#define IPV6_RECVPATHMTU 60 -#define IPV6_RECVPKTINFO 49 -#define IPV6_RECVRTHDR 56 -#define IPV6_RECVTCLASS 66 -#define IPV6_ROUTER_ALERT 22 -#define IPV6_ROUTER_ALERT_ISOLATE 30 -#define IPV6_RTHDR 57 -#define IPV6_RTHDRDSTOPTS 55 -#define IPV6_RTHDR_LOOSE 0 -#define IPV6_RTHDR_STRICT 1 -#define IPV6_RTHDR_TYPE_0 0 -#define IPV6_RXDSTOPTS IPV6_DSTOPTS -#define IPV6_RXHOPOPTS IPV6_HOPOPTS -#define IPV6_TCLASS 67 -#define IPV6_TRANSPARENT 75 -#define IPV6_UNICAST_HOPS 16 -#define IPV6_UNICAST_IF 76 -#define IPV6_V6ONLY 26 -#define IPV6_XFRM_POLICY 35 -#define IPVERSION 4 -#define IP_ADD_MEMBERSHIP 35 -#define IP_ADD_SOURCE_MEMBERSHIP 39 -#define IP_BIND_ADDRESS_NO_PORT 24 -#define IP_BLOCK_SOURCE 38 -#define IP_CHECKSUM 23 -#define IP_DEFAULT_MULTICAST_LOOP 1 -#define IP_DEFAULT_MULTICAST_TTL 1 -#define IP_DF 0x4000 -#define IP_DROP_MEMBERSHIP 36 -#define IP_DROP_SOURCE_MEMBERSHIP 40 -#define IP_FREEBIND 15 -#define IP_HDRINCL 3 -#define IP_IPSEC_POLICY 16 -#define IP_MAXPACKET 65535 -#define IP_MAX_MEMBERSHIPS 20 -#define IP_MF 0x2000 -#define IP_MINTTL 21 -#define IP_MSFILTER 41 -#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) -#define IP_MSS 576 -#define IP_MTU 14 -#define IP_MTU_DISCOVER 10 -#define IP_MULTICAST_ALL 49 -#define IP_MULTICAST_IF 32 -#define IP_MULTICAST_LOOP 34 -#define IP_MULTICAST_TTL 33 -#define IP_NODEFRAG 22 -#define IP_OFFMASK 0x1fff -#define IP_OPTIONS 4 -#define IP_ORIGDSTADDR 20 -#define IP_PASSSEC 18 -#define IP_PKTINFO 8 -#define IP_PKTOPTIONS 9 -#define IP_PMTUDISC 10 -#define IP_PMTUDISC_DO 2 -#define IP_PMTUDISC_DONT 0 -#define IP_PMTUDISC_INTERFACE 4 -#define IP_PMTUDISC_OMIT 5 -#define IP_PMTUDISC_PROBE 3 -#define IP_PMTUDISC_WANT 1 -#define IP_RECVERR 11 -#define IP_RECVERR_RFC4884 26 -#define IP_RECVFRAGSIZE 25 -#define IP_RECVOPTS 6 -#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR -#define IP_RECVRETOPTS IP_RETOPTS -#define IP_RECVTOS 13 -#define IP_RECVTTL 12 -#define IP_RETOPTS 7 -#define IP_RF 0x8000 -#define IP_ROUTER_ALERT 5 -#define IP_TOS 1 -#define IP_TRANSPARENT 19 -#define IP_TTL 2 -#define IP_UNBLOCK_SOURCE 37 -#define IP_UNICAST_IF 50 -#define IP_XFRM_POLICY 17 -#define IQUERY ns_o_iquery -#define I_ATMARK (__SID |31) -#define I_CANPUT (__SID |34) -#define I_CKBAND (__SID |29) -#define I_FDINSERT (__SID |16) -#define I_FIND (__SID |11) -#define I_FLUSH (__SID | 5) -#define I_FLUSHBAND (__SID |28) -#define I_GETBAND (__SID |30) -#define I_GETCLTIME (__SID |33) -#define I_GETSIG (__SID |10) -#define I_GRDOPT (__SID | 7) -#define I_GWROPT (__SID |20) -#define I_LINK (__SID |12) -#define I_LIST (__SID |21) -#define I_LOOK (__SID | 4) -#define I_NREAD (__SID | 1) -#define I_PEEK (__SID |15) -#define I_PLINK (__SID |22) -#define I_POP (__SID | 3) -#define I_PUNLINK (__SID |23) -#define I_PUSH (__SID | 2) -#define I_RECVFD (__SID |14) -#define I_SENDFD (__SID |17) -#define I_SETCLTIME (__SID |32) -#define I_SETSIG (__SID | 9) -#define I_SRDOPT (__SID | 6) -#define I_STR (__SID | 8) -#define I_SWROPT (__SID |19) -#define I_UNLINK (__SID |13) -#define LASTMARK 0x02 -#define LC_ALL 6 -#define LC_ALL_MASK 0x7fffffff -#define LC_COLLATE 3 -#define LC_COLLATE_MASK (1<(b))?(a):(b)) -#define MAXCDNAME NS_MAXCDNAME -#define MAXDNAME NS_MAXDNAME -#define MAXDOUBLE DBL_MAX -#define MAXFLOAT FLT_MAX -#define MAXHOSTNAMELEN 64 -#define MAXINT INT_MAX -#define MAXLABEL NS_MAXLABEL -#define MAXLONG LONG_MAX -#define MAXNAMLEN 255 -#define MAXPATHLEN 4096 -#define MAXSHORT SHRT_MAX -#define MAXSYMLINKS 20 -#define MAXTC 6 -#define MAXTTL 255 -#define MAX_IPOPTLEN 40 -#define MB_CUR_MAX (__ctype_get_mb_cur_max()) -#define MB_LEN_MAX 4 -#define MCAST_BLOCK_SOURCE 43 -#define MCAST_EXCLUDE 0 -#define MCAST_INCLUDE 1 -#define MCAST_JOIN_GROUP 42 -#define MCAST_JOIN_SOURCE_GROUP 46 -#define MCAST_LEAVE_GROUP 45 -#define MCAST_LEAVE_SOURCE_GROUP 47 -#define MCAST_MSFILTER 48 -#define MCAST_UNBLOCK_SOURCE 44 -#define MIN(a,b) (((a)<(b))?(a):(b)) -#define MINDOUBLE DBL_MIN -#define MINFLOAT FLT_MIN -#define MININT INT_MIN -#define MINLONG LONG_MIN -#define MINSHORT SHRT_MIN -#define MLD_LISTENER_QUERY 130 -#define MLD_LISTENER_REDUCTION 132 -#define MLD_LISTENER_REPORT 131 -#define MM_APPL 8 -#define MM_CONSOLE 512 -#define MM_ERROR 2 -#define MM_FIRM 4 -#define MM_HALT 1 -#define MM_HARD 1 -#define MM_INFO 4 -#define MM_NOCON 4 -#define MM_NOMSG 1 -#define MM_NOSEV 0 -#define MM_NOTOK (-1) -#define MM_NRECOV 128 -#define MM_NULLACT ((char*)0) -#define MM_NULLLBL ((char*)0) -#define MM_NULLMC 0L -#define MM_NULLSEV 0 -#define MM_NULLTAG ((char*)0) -#define MM_NULLTXT ((char*)0) -#define MM_OK 0 -#define MM_OPSYS 32 -#define MM_PRINT 256 -#define MM_RECOVER 64 -#define MM_SOFT 2 -#define MM_UTIL 16 -#define MM_WARNING 3 -#define MODE_ACK 0x04 -#define MODE_B 2 -#define MODE_C 3 -#define MODE_ECHO 0x0200 -#define MODE_EDIT 0x01 -#define MODE_FLOW 0x0100 -#define MODE_FORCE 0x1000 -#define MODE_INBIN 0x0400 -#define MODE_LIT_ECHO 0x10 -#define MODE_MASK 0x1f -#define MODE_OUTBIN 0x0800 -#define MODE_S 1 -#define MODE_SOFT_TAB 0x08 -#define MODE_TRAPSIG 0x02 -#define MOD_CLKA ADJ_OFFSET_SINGLESHOT -#define MOD_CLKB ADJ_TICK -#define MOD_ESTERROR ADJ_ESTERROR -#define MOD_FREQUENCY ADJ_FREQUENCY -#define MOD_MAXERROR ADJ_MAXERROR -#define MOD_MICRO ADJ_MICRO -#define MOD_NANO ADJ_NANO -#define MOD_OFFSET ADJ_OFFSET -#define MOD_STATUS ADJ_STATUS -#define MOD_TAI ADJ_TAI -#define MOD_TIMECONST ADJ_TIMECONST -#define MON_1 0x2001A -#define MON_10 0x20023 -#define MON_11 0x20024 -#define MON_12 0x20025 -#define MON_2 0x2001B -#define MON_3 0x2001C -#define MON_4 0x2001D -#define MON_5 0x2001E -#define MON_6 0x2001F -#define MON_7 0x20020 -#define MON_8 0x20021 -#define MON_9 0x20022 -#define MORECTL 1 -#define MOREDATA 2 -#define MSG_ANY 0x02 -#define MSG_BAND 0x04 -#define MSG_HIPRI 0x01 -#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK -#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED -#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL -#define MUXID_ALL (-1) -#define M_1_PI 0.31830988618379067154 -#define M_2_PI 0.63661977236758134308 -#define M_2_SQRTPI 1.12837916709551257390 -#define M_E 2.7182818284590452354 -#define M_LN10 2.30258509299404568402 -#define M_LN2 0.69314718055994530942 -#define M_LOG10E 0.43429448190325182765 -#define M_LOG2E 1.4426950408889634074 -#define M_PI 3.14159265358979323846 -#define M_PI_2 1.57079632679489661923 -#define M_PI_4 0.78539816339744830962 -#define M_SQRT1_2 0.70710678118654752440 -#define M_SQRT2 1.41421356237309504880 -#define NAMESERVER_PORT NS_DEFAULTPORT -#define NAME_MAX 255 -#define NAN (0.0f/0.0f) -#define NBBY 8 -#define NCARGS 131072 -#define ND_NA_FLAG_OVERRIDE 0x00000020 -#define ND_NA_FLAG_ROUTER 0x00000080 -#define ND_NA_FLAG_SOLICITED 0x00000040 -#define ND_NEIGHBOR_ADVERT 136 -#define ND_NEIGHBOR_SOLICIT 135 -#define ND_OPT_HOME_AGENT_INFO 8 -#define ND_OPT_MTU 5 -#define ND_OPT_PI_FLAG_AUTO 0x40 -#define ND_OPT_PI_FLAG_ONLINK 0x80 -#define ND_OPT_PI_FLAG_RADDR 0x20 -#define ND_OPT_PREFIX_INFORMATION 3 -#define ND_OPT_REDIRECTED_HEADER 4 -#define ND_OPT_RTR_ADV_INTERVAL 7 -#define ND_OPT_SOURCE_LINKADDR 1 -#define ND_OPT_TARGET_LINKADDR 2 -#define ND_RA_FLAG_HOME_AGENT 0x20 -#define ND_RA_FLAG_MANAGED 0x80 -#define ND_RA_FLAG_OTHER 0x40 -#define ND_REDIRECT 137 -#define ND_ROUTER_ADVERT 134 -#define ND_ROUTER_SOLICIT 133 -#define NEW_ENV_VALUE 1 -#define NEW_ENV_VAR 0 -#define NGROUPS 32 -#define NGROUPS_MAX 32 -#define NL_ARGMAX 9 -#define NL_CAT_LOCALE 1 -#define NL_LANGMAX 32 -#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) -#define NL_MSGMAX 32767 -#define NL_NMAX 16 -#define NL_SETD 1 -#define NL_SETMAX 255 -#define NL_TEXTMAX 2048 -#define NOERROR ns_r_noerror -#define NOEXPR 0x50001 -#define NOFILE 256 -#define NOGROUP (-1) -#define NOP 241 -#define NOSTR 0x50003 -#define NOTAUTH ns_r_notauth -#define NOTIMP ns_r_notimpl -#define NOTZONE ns_r_notzone -#define NR_ICMP_TYPES 18 -#define NR_ICMP_UNREACH 15 -#define NSLC 18 -#define NS_ALG_DH 2 -#define NS_ALG_DSA 3 -#define NS_ALG_DSS NS_ALG_DSA -#define NS_ALG_EXPIRE_ONLY 253 -#define NS_ALG_MD5RSA 1 -#define NS_ALG_PRIVATE_OID 254 -#define NS_CMPRSFLGS 0xc0 -#define NS_DEFAULTPORT 53 -#define NS_DSA_MAX_BYTES 405 -#define NS_DSA_MIN_SIZE 213 -#define NS_DSA_SIG_SIZE 41 -#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) -#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) -#define NS_HFIXEDSZ 12 -#define NS_IN6ADDRSZ 16 -#define NS_INADDRSZ 4 -#define NS_INT16SZ 2 -#define NS_INT32SZ 4 -#define NS_INT8SZ 1 -#define NS_KEY_EXTENDED_FLAGS 0x1000 -#define NS_KEY_NAME_ENTITY 0x0200 -#define NS_KEY_NAME_RESERVED 0x0300 -#define NS_KEY_NAME_TYPE 0x0300 -#define NS_KEY_NAME_USER 0x0000 -#define NS_KEY_NAME_ZONE 0x0100 -#define NS_KEY_NO_AUTH 0x8000 -#define NS_KEY_NO_CONF 0x4000 -#define NS_KEY_PROT_ANY 255 -#define NS_KEY_PROT_DNSSEC 3 -#define NS_KEY_PROT_EMAIL 2 -#define NS_KEY_PROT_IPSEC 4 -#define NS_KEY_PROT_TLS 1 -#define NS_KEY_RESERVED10 0x0020 -#define NS_KEY_RESERVED11 0x0010 -#define NS_KEY_RESERVED2 0x2000 -#define NS_KEY_RESERVED4 0x0800 -#define NS_KEY_RESERVED5 0x0400 -#define NS_KEY_RESERVED8 0x0080 -#define NS_KEY_RESERVED9 0x0040 -#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) -#define NS_KEY_RESERVED_BITMASK2 0xFFFF -#define NS_KEY_SIGNATORYMASK 0x000F -#define NS_KEY_TYPEMASK 0xC000 -#define NS_KEY_TYPE_AUTH_CONF 0x0000 -#define NS_KEY_TYPE_AUTH_ONLY 0x4000 -#define NS_KEY_TYPE_CONF_ONLY 0x8000 -#define NS_KEY_TYPE_NO_KEY 0xC000 -#define NS_MAXCDNAME 255 -#define NS_MAXDNAME 1025 -#define NS_MAXLABEL 63 -#define NS_MAXMSG 65535 -#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) -#define NS_MD5RSA_MAX_BITS 4096 -#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) -#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) -#define NS_MD5RSA_MIN_BITS 512 -#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) -#define NS_NOTIFY_OP ns_o_notify -#define NS_NXT_BITS 8 -#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_MAX 127 -#define NS_OPT_DNSSEC_OK 0x8000U -#define NS_OPT_NSID 3 -#define NS_PACKETSZ 512 -#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) -#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) -#define NS_QFIXEDSZ 4 -#define NS_RRFIXEDSZ 10 -#define NS_SIG_ALG 2 -#define NS_SIG_EXPIR 8 -#define NS_SIG_FOOT 16 -#define NS_SIG_LABELS 3 -#define NS_SIG_OTTL 4 -#define NS_SIG_SIGNED 12 -#define NS_SIG_SIGNER 18 -#define NS_SIG_TYPE 0 -#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" -#define NS_TSIG_ERROR_FORMERR -12 -#define NS_TSIG_ERROR_NO_SPACE -11 -#define NS_TSIG_ERROR_NO_TSIG -10 -#define NS_TSIG_FUDGE 300 -#define NS_TSIG_TCP_COUNT 100 -#define NS_UPDATE_OP ns_o_update -#define NTELOPTS (1+TELOPT_NEW_ENVIRON) -#define NULL ((void*)0) -#define NXDOMAIN ns_r_nxdomain -#define NXRRSET ns_r_nxrrset -#define NZERO 20 -#define OLD_ENV_VALUE 0 -#define OLD_ENV_VAR 1 -#define ONCE_FLAG_INIT 0 -#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) -#define O_APPEND __WASI_FDFLAGS_APPEND -#define O_CLOEXEC (0) -#define O_CREAT (__WASI_OFLAGS_CREAT << 12) -#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) -#define O_DSYNC __WASI_FDFLAGS_DSYNC -#define O_EXCL (__WASI_OFLAGS_EXCL << 12) -#define O_EXEC (0x02000000) -#define O_NOCTTY (0) -#define O_NOFOLLOW (0x01000000) -#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK -#define O_RDONLY (0x04000000) -#define O_RDWR (O_RDONLY | O_WRONLY) -#define O_RSYNC __WASI_FDFLAGS_RSYNC -#define O_SEARCH (0x08000000) -#define O_SYNC __WASI_FDFLAGS_SYNC -#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) -#define O_TTY_INIT (0) -#define O_WRONLY (0x10000000) -#define PACKETSZ NS_PACKETSZ -#define PACKET_ADD_MEMBERSHIP 1 -#define PACKET_AUXDATA 8 -#define PACKET_BROADCAST 1 -#define PACKET_COPY_THRESH 7 -#define PACKET_DROP_MEMBERSHIP 2 -#define PACKET_FANOUT 18 -#define PACKET_FANOUT_DATA 22 -#define PACKET_FASTROUTE 6 -#define PACKET_HDRLEN 11 -#define PACKET_HOST 0 -#define PACKET_IGNORE_OUTGOING 23 -#define PACKET_LOOPBACK 5 -#define PACKET_LOSS 14 -#define PACKET_MR_ALLMULTI 2 -#define PACKET_MR_MULTICAST 0 -#define PACKET_MR_PROMISC 1 -#define PACKET_MR_UNICAST 3 -#define PACKET_MULTICAST 2 -#define PACKET_ORIGDEV 9 -#define PACKET_OTHERHOST 3 -#define PACKET_OUTGOING 4 -#define PACKET_QDISC_BYPASS 20 -#define PACKET_RECV_OUTPUT 3 -#define PACKET_RESERVE 12 -#define PACKET_ROLLOVER_STATS 21 -#define PACKET_RX_RING 5 -#define PACKET_STATISTICS 6 -#define PACKET_TIMESTAMP 17 -#define PACKET_TX_HAS_OFF 19 -#define PACKET_TX_RING 13 -#define PACKET_TX_TIMESTAMP 16 -#define PACKET_VERSION 10 -#define PACKET_VNET_HDR 15 -#define PAGESIZE (0x10000) -#define PAGE_SIZE PAGESIZE -#define PATH_MAX 4096 -#define PDP_ENDIAN __PDP_ENDIAN -#define PF_INET 1 -#define PF_INET6 2 -#define PF_UNSPEC 0 -#define PM_STR 0x20027 -#define POLLERR 0x1000 -#define POLLHUP 0x2000 -#define POLLIN POLLRDNORM -#define POLLNVAL 0x4000 -#define POLLOUT POLLWRNORM -#define POLLRDNORM 0x1 -#define POLLWRNORM 0x2 -#define POSIX_CLOSE_RESTART 0 -#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED -#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE -#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL -#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM -#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL -#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED -#define PRELIM 1 -#define PRIX16 __UINT16_FMTX__ -#define PRIX32 __UINT32_FMTX__ -#define PRIX64 __UINT64_FMTX__ -#define PRIX8 __UINT8_FMTX__ -#define PRIXFAST16 __UINT_FAST16_FMTX__ -#define PRIXFAST32 __UINT_FAST32_FMTX__ -#define PRIXFAST64 __UINT_FAST64_FMTX__ -#define PRIXFAST8 __UINT_FAST8_FMTX__ -#define PRIXLEAST16 __UINT_LEAST16_FMTX__ -#define PRIXLEAST32 __UINT_LEAST32_FMTX__ -#define PRIXLEAST64 __UINT_LEAST64_FMTX__ -#define PRIXLEAST8 __UINT_LEAST8_FMTX__ -#define PRIXMAX __UINTMAX_FMTX__ -#define PRIXPTR __UINTPTR_FMTX__ -#define PRId16 __INT16_FMTd__ -#define PRId32 __INT32_FMTd__ -#define PRId64 __INT64_FMTd__ -#define PRId8 __INT8_FMTd__ -#define PRIdFAST16 __INT_FAST16_FMTd__ -#define PRIdFAST32 __INT_FAST32_FMTd__ -#define PRIdFAST64 __INT_FAST64_FMTd__ -#define PRIdFAST8 __INT_FAST8_FMTd__ -#define PRIdLEAST16 __INT_LEAST16_FMTd__ -#define PRIdLEAST32 __INT_LEAST32_FMTd__ -#define PRIdLEAST64 __INT_LEAST64_FMTd__ -#define PRIdLEAST8 __INT_LEAST8_FMTd__ -#define PRIdMAX __INTMAX_FMTd__ -#define PRIdPTR __INTPTR_FMTd__ -#define PRIi16 __INT16_FMTi__ -#define PRIi32 __INT32_FMTi__ -#define PRIi64 __INT64_FMTi__ -#define PRIi8 __INT8_FMTi__ -#define PRIiFAST16 __INT_FAST16_FMTi__ -#define PRIiFAST32 __INT_FAST32_FMTi__ -#define PRIiFAST64 __INT_FAST64_FMTi__ -#define PRIiFAST8 __INT_FAST8_FMTi__ -#define PRIiLEAST16 __INT_LEAST16_FMTi__ -#define PRIiLEAST32 __INT_LEAST32_FMTi__ -#define PRIiLEAST64 __INT_LEAST64_FMTi__ -#define PRIiLEAST8 __INT_LEAST8_FMTi__ -#define PRIiMAX __INTMAX_FMTi__ -#define PRIiPTR __INTPTR_FMTi__ -#define PRIo16 __UINT16_FMTo__ -#define PRIo32 __UINT32_FMTo__ -#define PRIo64 __UINT64_FMTo__ -#define PRIo8 __UINT8_FMTo__ -#define PRIoFAST16 __UINT_FAST16_FMTo__ -#define PRIoFAST32 __UINT_FAST32_FMTo__ -#define PRIoFAST64 __UINT_FAST64_FMTo__ -#define PRIoFAST8 __UINT_FAST8_FMTo__ -#define PRIoLEAST16 __UINT_LEAST16_FMTo__ -#define PRIoLEAST32 __UINT_LEAST32_FMTo__ -#define PRIoLEAST64 __UINT_LEAST64_FMTo__ -#define PRIoLEAST8 __UINT_LEAST8_FMTo__ -#define PRIoMAX __UINTMAX_FMTo__ -#define PRIoPTR __UINTPTR_FMTo__ -#define PRIu16 __UINT16_FMTu__ -#define PRIu32 __UINT32_FMTu__ -#define PRIu64 __UINT64_FMTu__ -#define PRIu8 __UINT8_FMTu__ -#define PRIuFAST16 __UINT_FAST16_FMTu__ -#define PRIuFAST32 __UINT_FAST32_FMTu__ -#define PRIuFAST64 __UINT_FAST64_FMTu__ -#define PRIuFAST8 __UINT_FAST8_FMTu__ -#define PRIuLEAST16 __UINT_LEAST16_FMTu__ -#define PRIuLEAST32 __UINT_LEAST32_FMTu__ -#define PRIuLEAST64 __UINT_LEAST64_FMTu__ -#define PRIuLEAST8 __UINT_LEAST8_FMTu__ -#define PRIuMAX __UINTMAX_FMTu__ -#define PRIuPTR __UINTPTR_FMTu__ -#define PRIx16 __UINT16_FMTx__ -#define PRIx32 __UINT32_FMTx__ -#define PRIx64 __UINT64_FMTx__ -#define PRIx8 __UINT8_FMTx__ -#define PRIxFAST16 __UINT_FAST16_FMTx__ -#define PRIxFAST32 __UINT_FAST32_FMTx__ -#define PRIxFAST64 __UINT_FAST64_FMTx__ -#define PRIxFAST8 __UINT_FAST8_FMTx__ -#define PRIxLEAST16 __UINT_LEAST16_FMTx__ -#define PRIxLEAST32 __UINT_LEAST32_FMTx__ -#define PRIxLEAST64 __UINT_LEAST64_FMTx__ -#define PRIxLEAST8 __UINT_LEAST8_FMTx__ -#define PRIxMAX __UINTMAX_FMTx__ -#define PRIxPTR __UINTPTR_FMTx__ -#define PTRBITS (sizeof(char *) * 8) -#define PTRDIFF_MAX INT32_MAX -#define PTRDIFF_MIN INT32_MIN -#define PUTLONG NS_PUT32 -#define PUTSHORT NS_PUT16 -#define QFIXEDSZ NS_QFIXEDSZ -#define QUERY ns_o_query -#define RADIXCHAR 0x10000 -#define RAND_MAX (0x7fffffff) -#define REC_EOF '\002' -#define REC_EOR '\001' -#define REC_ESC '\377' -#define REFUSED ns_r_refused -#define REGTYPE '0' -#define REG_BADBR 10 -#define REG_BADPAT 2 -#define REG_BADRPT 13 -#define REG_EBRACE 9 -#define REG_EBRACK 7 -#define REG_ECOLLATE 3 -#define REG_ECTYPE 4 -#define REG_EESCAPE 5 -#define REG_ENOSYS -1 -#define REG_EPAREN 8 -#define REG_ERANGE 11 -#define REG_ESPACE 12 -#define REG_ESUBREG 6 -#define REG_EXTENDED 1 -#define REG_ICASE 2 -#define REG_NEWLINE 4 -#define REG_NOMATCH 1 -#define REG_NOSUB 8 -#define REG_NOTBOL 1 -#define REG_NOTEOL 2 -#define REG_OK 0 -#define RE_DUP_MAX 255 -#define RMSGD 0x0001 -#define RMSGN 0x0002 -#define RNORM 0x0000 -#define RPM_PCO_ADD 1 -#define RPM_PCO_CHANGE 2 -#define RPM_PCO_SETGLOBAL 3 -#define RPROTDAT 0x0004 -#define RPROTDIS 0x0008 -#define RPROTMASK 0x001C -#define RPROTNORM 0x0010 -#define RRFIXEDSZ NS_RRFIXEDSZ -#define RRQ 01 -#define RS_HIPRI 0x01 -#define RTLD_DEFAULT ((void *)0) -#define RTLD_GLOBAL 256 -#define RTLD_LAZY 1 -#define RTLD_LOCAL 8 -#define RTLD_NEXT ((void *)-1) -#define RTLD_NODELETE 4096 -#define RTLD_NOLOAD 4 -#define RTLD_NOW 2 -#define RUSAGE_CHILDREN 2 -#define RUSAGE_SELF 1 -#define R_OK (4) -#define SARMAG 8 -#define SB 250 -#define SCHAR_MAX 127 -#define SCHAR_MIN (-128) -#define SCNd16 __INT16_FMTd__ -#define SCNd32 __INT32_FMTd__ -#define SCNd64 __INT64_FMTd__ -#define SCNd8 __INT8_FMTd__ -#define SCNdFAST16 __INT_FAST16_FMTd__ -#define SCNdFAST32 __INT_FAST32_FMTd__ -#define SCNdFAST64 __INT_FAST64_FMTd__ -#define SCNdFAST8 __INT_FAST8_FMTd__ -#define SCNdLEAST16 __INT_LEAST16_FMTd__ -#define SCNdLEAST32 __INT_LEAST32_FMTd__ -#define SCNdLEAST64 __INT_LEAST64_FMTd__ -#define SCNdLEAST8 __INT_LEAST8_FMTd__ -#define SCNdMAX __INTMAX_FMTd__ -#define SCNdPTR __INTPTR_FMTd__ -#define SCNi16 __INT16_FMTi__ -#define SCNi32 __INT32_FMTi__ -#define SCNi64 __INT64_FMTi__ -#define SCNi8 __INT8_FMTi__ -#define SCNiFAST16 __INT_FAST16_FMTi__ -#define SCNiFAST32 __INT_FAST32_FMTi__ -#define SCNiFAST64 __INT_FAST64_FMTi__ -#define SCNiFAST8 __INT_FAST8_FMTi__ -#define SCNiLEAST16 __INT_LEAST16_FMTi__ -#define SCNiLEAST32 __INT_LEAST32_FMTi__ -#define SCNiLEAST64 __INT_LEAST64_FMTi__ -#define SCNiLEAST8 __INT_LEAST8_FMTi__ -#define SCNiMAX __INTMAX_FMTi__ -#define SCNiPTR __INTPTR_FMTi__ -#define SCNo16 __UINT16_FMTo__ -#define SCNo32 __UINT32_FMTo__ -#define SCNo64 __UINT64_FMTo__ -#define SCNo8 __UINT8_FMTo__ -#define SCNoFAST16 __UINT_FAST16_FMTo__ -#define SCNoFAST32 __UINT_FAST32_FMTo__ -#define SCNoFAST64 __UINT_FAST64_FMTo__ -#define SCNoFAST8 __UINT_FAST8_FMTo__ -#define SCNoLEAST16 __UINT_LEAST16_FMTo__ -#define SCNoLEAST32 __UINT_LEAST32_FMTo__ -#define SCNoLEAST64 __UINT_LEAST64_FMTo__ -#define SCNoLEAST8 __UINT_LEAST8_FMTo__ -#define SCNoMAX __UINTMAX_FMTo__ -#define SCNoPTR __UINTPTR_FMTo__ -#define SCNu16 __UINT16_FMTu__ -#define SCNu32 __UINT32_FMTu__ -#define SCNu64 __UINT64_FMTu__ -#define SCNu8 __UINT8_FMTu__ -#define SCNuFAST16 __UINT_FAST16_FMTu__ -#define SCNuFAST32 __UINT_FAST32_FMTu__ -#define SCNuFAST64 __UINT_FAST64_FMTu__ -#define SCNuFAST8 __UINT_FAST8_FMTu__ -#define SCNuLEAST16 __UINT_LEAST16_FMTu__ -#define SCNuLEAST32 __UINT_LEAST32_FMTu__ -#define SCNuLEAST64 __UINT_LEAST64_FMTu__ -#define SCNuLEAST8 __UINT_LEAST8_FMTu__ -#define SCNuMAX __UINTMAX_FMTu__ -#define SCNuPTR __UINTPTR_FMTu__ -#define SCNx16 __UINT16_FMTx__ -#define SCNx32 __UINT32_FMTx__ -#define SCNx64 __UINT64_FMTx__ -#define SCNx8 __UINT8_FMTx__ -#define SCNxFAST16 __UINT_FAST16_FMTx__ -#define SCNxFAST32 __UINT_FAST32_FMTx__ -#define SCNxFAST64 __UINT_FAST64_FMTx__ -#define SCNxFAST8 __UINT_FAST8_FMTx__ -#define SCNxLEAST16 __UINT_LEAST16_FMTx__ -#define SCNxLEAST32 __UINT_LEAST32_FMTx__ -#define SCNxLEAST64 __UINT_LEAST64_FMTx__ -#define SCNxLEAST8 __UINT_LEAST8_FMTx__ -#define SCNxMAX __UINTMAX_FMTx__ -#define SCNxPTR __UINTPTR_FMTx__ -#define SE 240 -#define SEEK_CUR __WASI_WHENCE_CUR -#define SEEK_END __WASI_WHENCE_END -#define SEEK_SET __WASI_WHENCE_SET -#define SEGSIZE 512 -#define SEM_FAILED ((sem_t *)0) -#define SERVFAIL ns_r_servfail -#define SHORTBITS (sizeof(short) * 8) -#define SHRT_MAX 0x7fff -#define SHRT_MIN (-1-0x7fff) -#define SHUT_RD __WASI_SDFLAGS_RD -#define SHUT_RDWR (SHUT_RD | SHUT_WR) -#define SHUT_WR __WASI_SDFLAGS_WR -#define SIG_ATOMIC_MAX INT32_MAX -#define SIG_ATOMIC_MIN INT32_MIN -#define SIZE_MAX UINT32_MAX -#define SI_LOAD_SHIFT 16 -#define SLC_ABORT 7 -#define SLC_ACK 0x80 -#define SLC_AO 4 -#define SLC_AYT 5 -#define SLC_BRK 2 -#define SLC_CANTCHANGE 1 -#define SLC_DEFAULT 3 -#define SLC_EC 10 -#define SLC_EL 11 -#define SLC_EOF 8 -#define SLC_EOR 6 -#define SLC_EW 12 -#define SLC_FLAGS 1 -#define SLC_FLUSHIN 0x40 -#define SLC_FLUSHOUT 0x20 -#define SLC_FORW1 17 -#define SLC_FORW2 18 -#define SLC_FUNC 0 -#define SLC_IP 3 -#define SLC_LEVELBITS 0x03 -#define SLC_LNEXT 14 -#define SLC_NAME(x) slc_names[x] -#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, -#define SLC_NAMES SLC_NAMELIST -#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) -#define SLC_NOSUPPORT 0 -#define SLC_RP 13 -#define SLC_SUSP 9 -#define SLC_SYNCH 1 -#define SLC_VALUE 2 -#define SLC_VARIABLE 2 -#define SLC_XOFF 16 -#define SLC_XON 15 -#define SNDPIPE 0x002 -#define SNDZERO 0x001 -#define SOCK_CLOEXEC (0x00002000) -#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM -#define SOCK_NONBLOCK (0x00004000) -#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM -#define SOL_SOCKET 0x7fffffff -#define SOL_TCP 6 -#define SOL_UDP 17 -#define SO_TYPE 3 -#define SSIZE_MAX LONG_MAX -#define STATUS ns_o_status -#define STA_CLK 0x8000 -#define STA_CLOCKERR 0x1000 -#define STA_DEL 0x0020 -#define STA_FLL 0x0008 -#define STA_FREQHOLD 0x0080 -#define STA_INS 0x0010 -#define STA_MODE 0x4000 -#define STA_NANO 0x2000 -#define STA_PLL 0x0001 -#define STA_PPSERROR 0x0800 -#define STA_PPSFREQ 0x0002 -#define STA_PPSJITTER 0x0200 -#define STA_PPSSIGNAL 0x0100 -#define STA_PPSTIME 0x0004 -#define STA_PPSWANDER 0x0400 -#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) -#define STA_UNSYNC 0x0040 -#define STDERR_FILENO 2 -#define STDIN_FILENO 0 -#define STDOUT_FILENO 1 -#define STRU_F 1 -#define STRU_P 3 -#define STRU_R 2 -#define ST_APPEND 256 -#define ST_IMMUTABLE 512 -#define ST_MANDLOCK 64 -#define ST_NOATIME 1024 -#define ST_NODEV 4 -#define ST_NODIRATIME 2048 -#define ST_NOEXEC 8 -#define ST_NOSUID 2 -#define ST_RDONLY 1 -#define ST_RELATIME 4096 -#define ST_SYNCHRONOUS 16 -#define ST_WRITE 128 -#define SUN_LEN(s) (2+strlen((s)->sun_path)) -#define SUSP 237 -#define SYMLOOP_MAX 40 -#define SYMTYPE '2' -#define SYNCH 242 -#define S_ADDT ns_s_ar -#define S_BANDURG 0x0200 -#define S_ERROR 0x0010 -#define S_HANGUP 0x0020 -#define S_HIPRI 0x0002 -#define S_IEXEC S_IXUSR -#define S_IFBLK (0x6000) -#define S_IFCHR (0x2000) -#define S_IFDIR (0x4000) -#define S_IFIFO (0x1000) -#define S_IFLNK (0xa000) -#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) -#define S_IFREG (0x8000) -#define S_IFSOCK (0xc000) -#define S_INPUT 0x0001 -#define S_IREAD S_IRUSR -#define S_IRGRP (0x20) -#define S_IROTH (0x4) -#define S_IRUSR (0x100) -#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) -#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) -#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) -#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) -#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) -#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) -#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) -#define S_ISGID (0x400) -#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) -#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) -#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) -#define S_ISUID (0x800) -#define S_ISVTX (0x200) -#define S_IWGRP (0x10) -#define S_IWOTH (0x2) -#define S_IWRITE S_IWUSR -#define S_IWUSR (0x80) -#define S_IXGRP (0x8) -#define S_IXOTH (0x1) -#define S_IXUSR (0x40) -#define S_MSG 0x0008 -#define S_OUTPUT 0x0004 -#define S_PREREQ ns_s_pr -#define S_RDBAND 0x0080 -#define S_RDNORM 0x0040 -#define S_UPDATE ns_s_ud -#define S_WRBAND 0x0100 -#define S_WRNORM S_OUTPUT -#define S_ZONE ns_s_zn -#define TCPI_OPT_ECN 8 -#define TCPI_OPT_SACK 2 -#define TCPI_OPT_TIMESTAMPS 1 -#define TCPI_OPT_WSCALE 4 -#define TCPOLEN_MAXSEG 4 -#define TCPOLEN_SACK_PERMITTED 2 -#define TCPOLEN_TIMESTAMP 10 -#define TCPOLEN_WINDOW 3 -#define TCPOPT_EOL 0 -#define TCPOPT_MAXSEG 2 -#define TCPOPT_NOP 1 -#define TCPOPT_SACK 5 -#define TCPOPT_SACK_PERMITTED 4 -#define TCPOPT_TIMESTAMP 8 -#define TCPOPT_WINDOW 3 -#define TCP_CA_CWR 2 -#define TCP_CA_Disorder 1 -#define TCP_CA_Loss 4 -#define TCP_CA_Open 0 -#define TCP_CA_Recovery 3 -#define TCP_CC_INFO 26 -#define TCP_CLOSE 7 -#define TCP_CLOSE_WAIT 8 -#define TCP_CLOSING 11 -#define TCP_CM_INQ TCP_INQ -#define TCP_CONGESTION 13 -#define TCP_CORK 3 -#define TCP_DEFER_ACCEPT 9 -#define TCP_ENCAP_ESPINTCP 7 -#define TCP_ESTABLISHED 1 -#define TCP_FASTOPEN 23 -#define TCP_FASTOPEN_CONNECT 30 -#define TCP_FASTOPEN_KEY 33 -#define TCP_FASTOPEN_NO_COOKIE 34 -#define TCP_FIN_WAIT1 4 -#define TCP_FIN_WAIT2 5 -#define TCP_INFO 11 -#define TCP_INQ 36 -#define TCP_KEEPCNT 6 -#define TCP_KEEPIDLE 4 -#define TCP_KEEPINTVL 5 -#define TCP_LAST_ACK 9 -#define TCP_LINGER2 8 -#define TCP_LISTEN 10 -#define TCP_MAXSEG 2 -#define TCP_MD5SIG 14 -#define TCP_MD5SIG_EXT 32 -#define TCP_MD5SIG_FLAG_IFINDEX 0x2 -#define TCP_MD5SIG_FLAG_PREFIX 0x1 -#define TCP_MD5SIG_MAXKEYLEN 80 -#define TCP_NODELAY 1 -#define TCP_NOTSENT_LOWAT 25 -#define TCP_QUEUE_SEQ 21 -#define TCP_QUICKACK 12 -#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 -#define TCP_REPAIR 19 -#define TCP_REPAIR_OFF 0 -#define TCP_REPAIR_OFF_NO_WP -1 -#define TCP_REPAIR_ON 1 -#define TCP_REPAIR_OPTIONS 22 -#define TCP_REPAIR_QUEUE 20 -#define TCP_REPAIR_WINDOW 29 -#define TCP_SAVED_SYN 28 -#define TCP_SAVE_SYN 27 -#define TCP_SYNCNT 7 -#define TCP_SYN_RECV 3 -#define TCP_SYN_SENT 2 -#define TCP_THIN_DUPACK 17 -#define TCP_THIN_LINEAR_TIMEOUTS 16 -#define TCP_TIMESTAMP 24 -#define TCP_TIME_WAIT 6 -#define TCP_TX_DELAY 37 -#define TCP_ULP 31 -#define TCP_USER_TIMEOUT 18 -#define TCP_WINDOW_CLAMP 10 -#define TCP_ZEROCOPY_RECEIVE 35 -#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] -#define TELCMD_FIRST xEOF -#define TELCMD_LAST IAC -#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) -#define TELOPT_3270REGIME 29 -#define TELOPT_AUTHENTICATION 37 -#define TELOPT_BINARY 0 -#define TELOPT_BM 19 -#define TELOPT_DET 20 -#define TELOPT_ECHO 1 -#define TELOPT_ENCRYPT 38 -#define TELOPT_EOR 25 -#define TELOPT_EXOPL 255 -#define TELOPT_LFLOW 33 -#define TELOPT_LINEMODE 34 -#define TELOPT_LOGOUT 18 -#define TELOPT_NAMS 4 -#define TELOPT_NAOCRD 10 -#define TELOPT_NAOFFD 13 -#define TELOPT_NAOHTD 12 -#define TELOPT_NAOHTS 11 -#define TELOPT_NAOL 8 -#define TELOPT_NAOLFD 16 -#define TELOPT_NAOP 9 -#define TELOPT_NAOVTD 15 -#define TELOPT_NAOVTS 14 -#define TELOPT_NAWS 31 -#define TELOPT_NEW_ENVIRON 39 -#define TELOPT_OLD_ENVIRON 36 -#define TELOPT_OUTMRK 27 -#define TELOPT_RCP 2 -#define TELOPT_RCTE 7 -#define TELOPT_SGA 3 -#define TELOPT_SNDLOC 23 -#define TELOPT_STATUS 5 -#define TELOPT_SUPDUP 21 -#define TELOPT_SUPDUPOUTPUT 22 -#define TELOPT_TM 6 -#define TELOPT_TSPEED 32 -#define TELOPT_TTYLOC 28 -#define TELOPT_TTYPE 24 -#define TELOPT_TUID 26 -#define TELOPT_X3PAD 30 -#define TELOPT_XASCII 17 -#define TELOPT_XDISPLOC 35 -#define TELQUAL_INFO 2 -#define TELQUAL_IS 0 -#define TELQUAL_NAME 3 -#define TELQUAL_REPLY 2 -#define TELQUAL_SEND 1 -#define TGEXEC 00010 -#define TGREAD 00040 -#define TGWRITE 00020 -#define THOUSEP 0x10001 -#define TH_ACK 0x10 -#define TH_FIN 0x01 -#define TH_PUSH 0x08 -#define TH_RST 0x04 -#define TH_SYN 0x02 -#define TH_URG 0x20 -#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME -#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) -#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) -#define TIME_BAD TIME_ERROR -#define TIME_DEL 2 -#define TIME_ERROR 5 -#define TIME_INS 1 -#define TIME_OK 0 -#define TIME_OOP 3 -#define TIME_UTC 1 -#define TIME_WAIT 4 -#define TMAGIC "ustar" -#define TMAGLEN 6 -#define TOEXEC 00001 -#define TOREAD 00004 -#define TOWRITE 00002 -#define TRANSIENT 4 -#define TSGID 02000 -#define TSS_DTOR_ITERATIONS 4 -#define TSUID 04000 -#define TSVTX 01000 -#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) -#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) -#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) -#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) -#define TTYDEF_SPEED (B9600) -#define TTY_NAME_MAX 32 -#define TUEXEC 00100 -#define TUREAD 00400 -#define TUWRITE 00200 -#define TVERSION "00" -#define TVERSLEN 2 -#define TYPE_A 1 -#define TYPE_E 2 -#define TYPE_I 3 -#define TYPE_L 4 -#define TZNAME_MAX 6 -#define T_A ns_t_a -#define T_A6 ns_t_a6 -#define T_AAAA ns_t_aaaa -#define T_AFSDB ns_t_afsdb -#define T_ANY ns_t_any -#define T_ATMA ns_t_atma -#define T_AXFR ns_t_axfr -#define T_CNAME ns_t_cname -#define T_DNAME ns_t_dname -#define T_EID ns_t_eid -#define T_FMT 0x2002A -#define T_FMT_AMPM 0x2002B -#define T_GPOS ns_t_gpos -#define T_HINFO ns_t_hinfo -#define T_ISDN ns_t_isdn -#define T_IXFR ns_t_ixfr -#define T_KEY ns_t_key -#define T_LOC ns_t_loc -#define T_MAILA ns_t_maila -#define T_MAILB ns_t_mailb -#define T_MB ns_t_mb -#define T_MD ns_t_md -#define T_MF ns_t_mf -#define T_MG ns_t_mg -#define T_MINFO ns_t_minfo -#define T_MR ns_t_mr -#define T_MX ns_t_mx -#define T_NAPTR ns_t_naptr -#define T_NIMLOC ns_t_nimloc -#define T_NS ns_t_ns -#define T_NSAP ns_t_nsap -#define T_NSAP_PTR ns_t_nsap_ptr -#define T_NULL ns_t_null -#define T_NXT ns_t_nxt -#define T_PTR ns_t_ptr -#define T_PX ns_t_px -#define T_RP ns_t_rp -#define T_RT ns_t_rt -#define T_SIG ns_t_sig -#define T_SOA ns_t_soa -#define T_SRV ns_t_srv -#define T_TSIG ns_t_tsig -#define T_TXT ns_t_txt -#define T_WKS ns_t_wks -#define T_X25 ns_t_x25 -#define UCHAR_MAX 255 -#define UDP_CORK 1 -#define UDP_ENCAP 100 -#define UDP_ENCAP_ESPINUDP 2 -#define UDP_ENCAP_ESPINUDP_NON_IKE 1 -#define UDP_ENCAP_GTP0 4 -#define UDP_ENCAP_GTP1U 5 -#define UDP_ENCAP_L2TPINUDP 3 -#define UDP_ENCAP_RXRPC 6 -#define UDP_GRO 104 -#define UDP_NO_CHECK6_RX 102 -#define UDP_NO_CHECK6_TX 101 -#define UDP_SEGMENT 103 -#define UINT16_C(c) c -#define UINT16_MAX (0xffff) -#define UINT32_C(c) c ## U -#define UINT32_MAX (0xffffffffu) -#define UINT64_C(c) c ## ULL -#define UINT64_MAX (0xffffffffffffffffu) -#define UINT8_C(c) c -#define UINT8_MAX (0xff) -#define UINTMAX_C(c) c ## ULL -#define UINTMAX_MAX UINT64_MAX -#define UINTPTR_MAX UINT32_MAX -#define UINT_FAST16_MAX UINT16_MAX -#define UINT_FAST32_MAX UINT32_MAX -#define UINT_FAST64_MAX UINT64_MAX -#define UINT_FAST8_MAX UINT8_MAX -#define UINT_LEAST16_MAX UINT16_MAX -#define UINT_LEAST32_MAX UINT32_MAX -#define UINT_LEAST64_MAX UINT64_MAX -#define UINT_LEAST8_MAX UINT8_MAX -#define UINT_MAX 0xffffffffU -#define UIO_MAXIOV 1024 -#define ULLONG_MAX (2ULL*LLONG_MAX+1) -#define ULONG_MAX (2UL*LONG_MAX+1) -#define USHRT_MAX 0xffff -#define UTIME_NOW (-1) -#define UTIME_OMIT (-2) -#define WCHAR_MAX (0x7fffffff+L'\0') -#define WCHAR_MIN (-1-0x7fffffff+L'\0') -#define WEOF 0xffffffffU -#define WILL 251 -#define WINT_MAX UINT32_MAX -#define WINT_MIN 0U -#define WONT 252 -#define WORD_BIT 32 -#define WRQ 02 -#define W_OK (2) -#define X_OK (1) -#define YESEXPR 0x50000 -#define YESSTR 0x50002 -#define YXDOMAIN ns_r_yxdomain -#define YXRRSET ns_r_yxrrset -#define _ALLOCA_H -#define _ALL_SOURCE 1 -#define _ARPA_FTP_H -#define _ARPA_INET_H -#define _ARPA_NAMESER_H -#define _ARPA_TELNET_H -#define _ARPA_TFTP_H -#define _AR_H -#define _BYTESWAP_H -#define _COMPLEX_H -#define _CPIO_H -#define _CRYPT_H -#define _CS_GNU_LIBC_VERSION 2 -#define _CS_GNU_LIBPTHREAD_VERSION 3 -#define _CS_PATH 0 -#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 -#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 -#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 -#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 -#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 -#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 -#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 -#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 -#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 -#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 -#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 -#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 -#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 -#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 -#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 -#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 -#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 -#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 -#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 -#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 -#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 -#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 -#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 -#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 -#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 -#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 -#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 -#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 -#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 -#define _CS_V6_ENV 1148 -#define _CS_V7_ENV 1149 -#define _CTYPE_H -#define _Complex_I (0.0f+1.0fi) -#define _DIRENT_H -#define _DIRENT_HAVE_D_TYPE -#define _DLFCN_H -#define _ENDIAN_H -#define _ERRNO_H -#define _ERR_H -#define _FCNTL_H -#define _FEATURES_H -#define _FENV_H -#define _FLOAT_H -#define _FMTMSG_H -#define _FNMATCH_H -#define _FTW_H -#define _GETOPT_H -#define _GLOB_H -#define _GNU_SOURCE 1 -#define _ICONV_H -#define _IFADDRS_H -#define _INTTYPES_H -#define _IOFBF 0 -#define _IOLBF 1 -#define _IONBF 2 -#define _ISO646_H -#define _LANGINFO_H -#define _LIBGEN_H -#define _LIMITS_H -#define _LOCALE_H -#define _LP64 1 -#define _MALLOC_H -#define _MATH_H -#define _MONETARY_H -#define _MQUEUE_H -#define _NETINET_ICMP6_H -#define _NETINET_IGMP_H -#define _NETINET_IN_H -#define _NETINET_IN_SYSTM_H -#define _NETINET_IP6_H -#define _NETINET_IP_H -#define _NETINET_IP_ICMP_H -#define _NETINET_TCP_H -#define _NETINET_UDP_H -#define _NETPACKET_PACKET_H -#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) -#define _NL_TYPES_H -#define _PC_2_SYMLINKS 20 -#define _PC_ALLOC_SIZE_MIN 18 -#define _PC_ASYNC_IO 10 -#define _PC_CHOWN_RESTRICTED 6 -#define _PC_FILESIZEBITS 13 -#define _PC_LINK_MAX 0 -#define _PC_MAX_CANON 1 -#define _PC_MAX_INPUT 2 -#define _PC_NAME_MAX 3 -#define _PC_NO_TRUNC 7 -#define _PC_PATH_MAX 4 -#define _PC_PIPE_BUF 5 -#define _PC_PRIO_IO 11 -#define _PC_REC_INCR_XFER_SIZE 14 -#define _PC_REC_MAX_XFER_SIZE 15 -#define _PC_REC_MIN_XFER_SIZE 16 -#define _PC_REC_XFER_ALIGN 17 -#define _PC_SOCK_MAXBUF 12 -#define _PC_SYMLINK_MAX 19 -#define _PC_SYNC_IO 9 -#define _PC_VDISABLE 8 -#define _POLL_H -#define _POSIX2_BC_BASE_MAX 99 -#define _POSIX2_BC_DIM_MAX 2048 -#define _POSIX2_BC_SCALE_MAX 99 -#define _POSIX2_BC_STRING_MAX 1000 -#define _POSIX2_CHARCLASS_NAME_MAX 14 -#define _POSIX2_COLL_WEIGHTS_MAX 2 -#define _POSIX2_C_BIND _POSIX_VERSION -#define _POSIX2_EXPR_NEST_MAX 32 -#define _POSIX2_LINE_MAX 2048 -#define _POSIX2_RE_DUP_MAX 255 -#define _POSIX2_VERSION _POSIX_VERSION -#define _POSIX_ADVISORY_INFO _POSIX_VERSION -#define _POSIX_AIO_LISTIO_MAX 2 -#define _POSIX_AIO_MAX 1 -#define _POSIX_ARG_MAX 4096 -#define _POSIX_BARRIERS _POSIX_VERSION -#define _POSIX_CHILD_MAX 25 -#define _POSIX_CHOWN_RESTRICTED 1 -#define _POSIX_CLOCKRES_MIN 20000000 -#define _POSIX_CLOCK_SELECTION _POSIX_VERSION -#define _POSIX_CPUTIME _POSIX_VERSION -#define _POSIX_DELAYTIMER_MAX 32 -#define _POSIX_FSYNC _POSIX_VERSION -#define _POSIX_HOST_NAME_MAX 255 -#define _POSIX_IPV6 _POSIX_VERSION -#define _POSIX_LINK_MAX 8 -#define _POSIX_LOGIN_NAME_MAX 9 -#define _POSIX_MAX_CANON 255 -#define _POSIX_MAX_INPUT 255 -#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION -#define _POSIX_MQ_OPEN_MAX 8 -#define _POSIX_MQ_PRIO_MAX 32 -#define _POSIX_NAME_MAX 14 -#define _POSIX_NGROUPS_MAX 8 -#define _POSIX_NO_TRUNC 1 -#define _POSIX_OPEN_MAX 20 -#define _POSIX_PATH_MAX 256 -#define _POSIX_PIPE_BUF 512 -#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION -#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION -#define _POSIX_REGEXP 1 -#define _POSIX_RE_DUP_MAX 255 -#define _POSIX_RTSIG_MAX 8 -#define _POSIX_SEM_NSEMS_MAX 256 -#define _POSIX_SEM_VALUE_MAX 32767 -#define _POSIX_SIGQUEUE_MAX 32 -#define _POSIX_SPIN_LOCKS _POSIX_VERSION -#define _POSIX_SSIZE_MAX 32767 -#define _POSIX_SS_REPL_MAX 4 -#define _POSIX_STREAM_MAX 8 -#define _POSIX_SYMLINK_MAX 255 -#define _POSIX_SYMLOOP_MAX 8 -#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION -#define _POSIX_THREAD_CPUTIME _POSIX_VERSION -#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 -#define _POSIX_THREAD_KEYS_MAX 128 -#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION -#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION -#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION -#define _POSIX_THREAD_THREADS_MAX 64 -#define _POSIX_TIMEOUTS _POSIX_VERSION -#define _POSIX_TIMERS _POSIX_VERSION -#define _POSIX_TIMER_MAX 32 -#define _POSIX_TRACE_EVENT_NAME_MAX 30 -#define _POSIX_TRACE_NAME_MAX 8 -#define _POSIX_TRACE_SYS_MAX 8 -#define _POSIX_TRACE_USER_EVENT_MAX 32 -#define _POSIX_TTY_NAME_MAX 9 -#define _POSIX_TZNAME_MAX 6 -#define _POSIX_V6_ILP32_OFFBIG (1) -#define _POSIX_V7_ILP32_OFFBIG (1) -#define _POSIX_VDISABLE 0 -#define _POSIX_VERSION 200809L -#define _PTRDIFF_T -#define _REGEX_H -#define _SCHED_H -#define _SC_2_CHAR_TERM 95 -#define _SC_2_C_BIND 47 -#define _SC_2_C_DEV 48 -#define _SC_2_FORT_DEV 49 -#define _SC_2_FORT_RUN 50 -#define _SC_2_LOCALEDEF 52 -#define _SC_2_PBS 168 -#define _SC_2_PBS_ACCOUNTING 169 -#define _SC_2_PBS_CHECKPOINT 175 -#define _SC_2_PBS_LOCATE 170 -#define _SC_2_PBS_MESSAGE 171 -#define _SC_2_PBS_TRACK 172 -#define _SC_2_SW_DEV 51 -#define _SC_2_UPE 97 -#define _SC_2_VERSION 46 -#define _SC_ADVISORY_INFO 132 -#define _SC_AIO_LISTIO_MAX 23 -#define _SC_AIO_MAX 24 -#define _SC_AIO_PRIO_DELTA_MAX 25 -#define _SC_ARG_MAX 0 -#define _SC_ASYNCHRONOUS_IO 12 -#define _SC_ATEXIT_MAX 87 -#define _SC_AVPHYS_PAGES 86 -#define _SC_BARRIERS 133 -#define _SC_BC_BASE_MAX 36 -#define _SC_BC_DIM_MAX 37 -#define _SC_BC_SCALE_MAX 38 -#define _SC_BC_STRING_MAX 39 -#define _SC_CHILD_MAX 1 -#define _SC_CLK_TCK 2 -#define _SC_CLOCK_SELECTION 137 -#define _SC_COLL_WEIGHTS_MAX 40 -#define _SC_CPUTIME 138 -#define _SC_DELAYTIMER_MAX 26 -#define _SC_EXPR_NEST_MAX 42 -#define _SC_FSYNC 15 -#define _SC_GETGR_R_SIZE_MAX 69 -#define _SC_GETPW_R_SIZE_MAX 70 -#define _SC_HOST_NAME_MAX 180 -#define _SC_IOV_MAX 60 -#define _SC_IPV6 235 -#define _SC_JOB_CONTROL 7 -#define _SC_LINE_MAX 43 -#define _SC_LOGIN_NAME_MAX 71 -#define _SC_MAPPED_FILES 16 -#define _SC_MEMLOCK 17 -#define _SC_MEMLOCK_RANGE 18 -#define _SC_MEMORY_PROTECTION 19 -#define _SC_MESSAGE_PASSING 20 -#define _SC_MONOTONIC_CLOCK 149 -#define _SC_MQ_OPEN_MAX 27 -#define _SC_MQ_PRIO_MAX 28 -#define _SC_NGROUPS_MAX 3 -#define _SC_NPROCESSORS_CONF 83 -#define _SC_NPROCESSORS_ONLN 84 -#define _SC_NZERO 109 -#define _SC_OPEN_MAX 4 -#define _SC_PAGESIZE 30 -#define _SC_PAGE_SIZE 30 -#define _SC_PASS_MAX 88 -#define _SC_PHYS_PAGES 85 -#define _SC_PRIORITIZED_IO 13 -#define _SC_PRIORITY_SCHEDULING 10 -#define _SC_RAW_SOCKETS 236 -#define _SC_READER_WRITER_LOCKS 153 -#define _SC_REALTIME_SIGNALS 9 -#define _SC_REGEXP 155 -#define _SC_RE_DUP_MAX 44 -#define _SC_RTSIG_MAX 31 -#define _SC_SAVED_IDS 8 -#define _SC_SEMAPHORES 21 -#define _SC_SEM_NSEMS_MAX 32 -#define _SC_SEM_VALUE_MAX 33 -#define _SC_SHARED_MEMORY_OBJECTS 22 -#define _SC_SHELL 157 -#define _SC_SIGQUEUE_MAX 34 -#define _SC_SPAWN 159 -#define _SC_SPIN_LOCKS 154 -#define _SC_SPORADIC_SERVER 160 -#define _SC_SS_REPL_MAX 241 -#define _SC_STREAMS 174 -#define _SC_STREAM_MAX 5 -#define _SC_SYMLOOP_MAX 173 -#define _SC_SYNCHRONIZED_IO 14 -#define _SC_THREADS 67 -#define _SC_THREAD_ATTR_STACKADDR 77 -#define _SC_THREAD_ATTR_STACKSIZE 78 -#define _SC_THREAD_CPUTIME 139 -#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 -#define _SC_THREAD_KEYS_MAX 74 -#define _SC_THREAD_PRIORITY_SCHEDULING 79 -#define _SC_THREAD_PRIO_INHERIT 80 -#define _SC_THREAD_PRIO_PROTECT 81 -#define _SC_THREAD_PROCESS_SHARED 82 -#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 -#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 -#define _SC_THREAD_SAFE_FUNCTIONS 68 -#define _SC_THREAD_SPORADIC_SERVER 161 -#define _SC_THREAD_STACK_MIN 75 -#define _SC_THREAD_THREADS_MAX 76 -#define _SC_TIMEOUTS 164 -#define _SC_TIMERS 11 -#define _SC_TIMER_MAX 35 -#define _SC_TRACE 181 -#define _SC_TRACE_EVENT_FILTER 182 -#define _SC_TRACE_EVENT_NAME_MAX 242 -#define _SC_TRACE_INHERIT 183 -#define _SC_TRACE_LOG 184 -#define _SC_TRACE_NAME_MAX 243 -#define _SC_TRACE_SYS_MAX 244 -#define _SC_TRACE_USER_EVENT_MAX 245 -#define _SC_TTY_NAME_MAX 72 -#define _SC_TYPED_MEMORY_OBJECTS 165 -#define _SC_TZNAME_MAX 6 -#define _SC_UIO_MAXIOV 60 -#define _SC_V6_ILP32_OFF32 176 -#define _SC_V6_ILP32_OFFBIG 177 -#define _SC_V6_LP64_OFF64 178 -#define _SC_V6_LPBIG_OFFBIG 179 -#define _SC_V7_ILP32_OFF32 237 -#define _SC_V7_ILP32_OFFBIG 238 -#define _SC_V7_LP64_OFF64 239 -#define _SC_V7_LPBIG_OFFBIG 240 -#define _SC_VERSION 29 -#define _SC_XBS5_ILP32_OFF32 125 -#define _SC_XBS5_ILP32_OFFBIG 126 -#define _SC_XBS5_LP64_OFF64 127 -#define _SC_XBS5_LPBIG_OFFBIG 128 -#define _SC_XOPEN_CRYPT 92 -#define _SC_XOPEN_ENH_I18N 93 -#define _SC_XOPEN_LEGACY 129 -#define _SC_XOPEN_REALTIME 130 -#define _SC_XOPEN_REALTIME_THREADS 131 -#define _SC_XOPEN_SHM 94 -#define _SC_XOPEN_STREAMS 246 -#define _SC_XOPEN_UNIX 91 -#define _SC_XOPEN_VERSION 89 -#define _SC_XOPEN_XCU_VERSION 90 -#define _SC_XOPEN_XPG2 98 -#define _SC_XOPEN_XPG3 99 -#define _SC_XOPEN_XPG4 100 -#define _SEARCH_H -#define _SEMAPHORE_H -#define _SIZE_T -#define _STDALIGN_H -#define _STDBOOL_H -#define _STDC_PREDEF_H -#define _STDINT_H -#define _STDIO_EXT_H -#define _STDIO_H -#define _STDLIB_H -#define _STDNORETURN_H -#define _STRINGS_H -#define _STRING_H -#define _STROPTS_H -#define _SYSEXITS_H -#define _SYS_EVENTFD_H -#define _SYS_FILE_H -#define _SYS_IOCTL_H -#define _SYS_PARAM_H -#define _SYS_RANDOM_H -#define _SYS_REG_H -#define _SYS_SELECT_H -#define _SYS_SOCKET_H -#define _SYS_STATVFS_H -#define _SYS_STAT_H -#define _SYS_SYSCALL_H -#define _SYS_SYSINFO_H -#define _SYS_TIMEB_H -#define _SYS_TIMEX_H -#define _SYS_TIME_H -#define _SYS_TTYDEFAULTS_H -#define _SYS_TYPES_H -#define _SYS_UIO_H -#define _SYS_UN_H -#define _SYS_UTSNAME_H -#define _TAR_H -#define _TGMATH_H -#define _THREADS_H -#define _TIME_H -#define _UCHAR_H -#define _UNISTD_H -#define _UTIME_H -#define _VALUES_H -#define _VA_LIST -#define _WCHAR_H -#define _WCHAR_T -#define _WCTYPE_H -#define _WINT_T -#define _XOPEN_ENH_I18N 1 -#define _XOPEN_IOV_MAX 16 -#define _XOPEN_NAME_MAX 255 -#define _XOPEN_PATH_MAX 1024 -#define _XOPEN_UNIX 1 -#define _XOPEN_VERSION 700 -#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) -#define __ATOMIC_ACQUIRE 2 -#define __ATOMIC_ACQ_REL 4 -#define __ATOMIC_CONSUME 1 -#define __ATOMIC_RELAXED 0 -#define __ATOMIC_RELEASE 3 -#define __ATOMIC_SEQ_CST 5 -#define __BIGGEST_ALIGNMENT__ 16 -#define __BIG_ENDIAN 4321 -#define __BIND 19950621 -#define __BYTE_ORDER __BYTE_ORDER__ -#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ -#define __CHAR16_TYPE__ unsigned short -#define __CHAR32_TYPE__ unsigned int -#define __CHAR_BIT__ 8 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __CLANG_MAX_ALIGN_T_DEFINED -#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) -#define __CONSTANT_CFSTRINGS__ 1 -#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) -#define __DBL_DECIMAL_DIG__ 17 -#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 -#define __DBL_DIG__ 15 -#define __DBL_EPSILON__ 2.2204460492503131e-16 -#define __DBL_HAS_DENORM__ 1 -#define __DBL_HAS_INFINITY__ 1 -#define __DBL_HAS_QUIET_NAN__ 1 -#define __DBL_MANT_DIG__ 53 -#define __DBL_MAX_10_EXP__ 308 -#define __DBL_MAX_EXP__ 1024 -#define __DBL_MAX__ 1.7976931348623157e+308 -#define __DBL_MIN_10_EXP__ (-307) -#define __DBL_MIN_EXP__ (-1021) -#define __DBL_MIN__ 2.2250738585072014e-308 -#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ -#define __DEFINED_FILE -#define __DEFINED___isoc_va_list -#define __DEFINED_blkcnt_t -#define __DEFINED_blksize_t -#define __DEFINED_clock_t -#define __DEFINED_clockid_t -#define __DEFINED_cnd_t -#define __DEFINED_dev_t -#define __DEFINED_double_t -#define __DEFINED_float_t -#define __DEFINED_fsblkcnt_t -#define __DEFINED_fsfilcnt_t -#define __DEFINED_gid_t -#define __DEFINED_id_t -#define __DEFINED_ino_t -#define __DEFINED_int16_t -#define __DEFINED_int32_t -#define __DEFINED_int64_t -#define __DEFINED_int8_t -#define __DEFINED_intmax_t -#define __DEFINED_intptr_t -#define __DEFINED_key_t -#define __DEFINED_locale_t -#define __DEFINED_mbstate_t -#define __DEFINED_mode_t -#define __DEFINED_mtx_t -#define __DEFINED_nlink_t -#define __DEFINED_off_t -#define __DEFINED_pid_t -#define __DEFINED_pthread_attr_t -#define __DEFINED_pthread_barrier_t -#define __DEFINED_pthread_barrierattr_t -#define __DEFINED_pthread_cond_t -#define __DEFINED_pthread_condattr_t -#define __DEFINED_pthread_key_t -#define __DEFINED_pthread_mutex_t -#define __DEFINED_pthread_mutexattr_t -#define __DEFINED_pthread_once_t -#define __DEFINED_pthread_rwlock_t -#define __DEFINED_pthread_rwlockattr_t -#define __DEFINED_pthread_spinlock_t -#define __DEFINED_pthread_t -#define __DEFINED_register_t -#define __DEFINED_regoff_t -#define __DEFINED_sa_family_t -#define __DEFINED_sigset_t -#define __DEFINED_size_t -#define __DEFINED_socklen_t -#define __DEFINED_ssize_t -#define __DEFINED_suseconds_t -#define __DEFINED_time_t -#define __DEFINED_timer_t -#define __DEFINED_u_int64_t -#define __DEFINED_uid_t -#define __DEFINED_uint16_t -#define __DEFINED_uint32_t -#define __DEFINED_uint64_t -#define __DEFINED_uint8_t -#define __DEFINED_uintmax_t -#define __DEFINED_uintptr_t -#define __DEFINED_useconds_t -#define __DEFINED_va_list -#define __DEFINED_wchar_t -#define __DEFINED_wctype_t -#define __DEFINED_wint_t -#define __FINITE_MATH_ONLY__ 0 -#define __FLOAT128__ 1 -#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) -#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) -#define __FLT_DECIMAL_DIG__ 9 -#define __FLT_DENORM_MIN__ 1.40129846e-45F -#define __FLT_DIG__ 6 -#define __FLT_EPSILON__ 1.19209290e-7F -#define __FLT_HAS_DENORM__ 1 -#define __FLT_HAS_INFINITY__ 1 -#define __FLT_HAS_QUIET_NAN__ 1 -#define __FLT_MANT_DIG__ 24 -#define __FLT_MAX_10_EXP__ 38 -#define __FLT_MAX_EXP__ 128 -#define __FLT_MAX__ 3.40282347e+38F -#define __FLT_MIN_10_EXP__ (-37) -#define __FLT_MIN_EXP__ (-125) -#define __FLT_MIN__ 1.17549435e-38F -#define __FLT_RADIX__ 2 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __GNUC_STDC_INLINE__ 1 -#define __GNUC_VA_LIST 1 -#define __GXX_ABI_VERSION 1002 -#define __INT16_C_SUFFIX__ -#define __INT16_FMTd__ "hd" -#define __INT16_FMTi__ "hi" -#define __INT16_MAX__ 32767 -#define __INT16_TYPE__ short -#define __INT32_C_SUFFIX__ -#define __INT32_FMTd__ "d" -#define __INT32_FMTi__ "i" -#define __INT32_MAX__ 2147483647 -#define __INT32_TYPE__ int -#define __INT64_C_SUFFIX__ LL -#define __INT64_FMTd__ "lld" -#define __INT64_FMTi__ "lli" -#define __INT64_MAX__ 9223372036854775807LL -#define __INT64_TYPE__ long long int -#define __INT8_C_SUFFIX__ -#define __INT8_FMTd__ "hhd" -#define __INT8_FMTi__ "hhi" -#define __INT8_MAX__ 127 -#define __INT8_TYPE__ signed char -#define __INTMAX_C_SUFFIX__ LL -#define __INTMAX_FMTd__ "lld" -#define __INTMAX_FMTi__ "lli" -#define __INTMAX_MAX__ 9223372036854775807LL -#define __INTMAX_TYPE__ long long int -#define __INTMAX_WIDTH__ 64 -#define __INTPTR_FMTd__ "ld" -#define __INTPTR_FMTi__ "li" -#define __INTPTR_MAX__ 9223372036854775807L -#define __INTPTR_TYPE__ long int -#define __INTPTR_WIDTH__ 64 -#define __INT_FAST16_FMTd__ "hd" -#define __INT_FAST16_FMTi__ "hi" -#define __INT_FAST16_MAX__ 32767 -#define __INT_FAST16_TYPE__ short -#define __INT_FAST32_FMTd__ "d" -#define __INT_FAST32_FMTi__ "i" -#define __INT_FAST32_MAX__ 2147483647 -#define __INT_FAST32_TYPE__ int -#define __INT_FAST64_FMTd__ "lld" -#define __INT_FAST64_FMTi__ "lli" -#define __INT_FAST64_MAX__ 9223372036854775807LL -#define __INT_FAST64_TYPE__ long long int -#define __INT_FAST8_FMTd__ "hhd" -#define __INT_FAST8_FMTi__ "hhi" -#define __INT_FAST8_MAX__ 127 -#define __INT_FAST8_TYPE__ signed char -#define __INT_LEAST16_FMTd__ "hd" -#define __INT_LEAST16_FMTi__ "hi" -#define __INT_LEAST16_MAX__ 32767 -#define __INT_LEAST16_TYPE__ short -#define __INT_LEAST32_FMTd__ "d" -#define __INT_LEAST32_FMTi__ "i" -#define __INT_LEAST32_MAX__ 2147483647 -#define __INT_LEAST32_TYPE__ int -#define __INT_LEAST64_FMTd__ "lld" -#define __INT_LEAST64_FMTi__ "lli" -#define __INT_LEAST64_MAX__ 9223372036854775807LL -#define __INT_LEAST64_TYPE__ long long int -#define __INT_LEAST8_FMTd__ "hhd" -#define __INT_LEAST8_FMTi__ "hhi" -#define __INT_LEAST8_MAX__ 127 -#define __INT_LEAST8_TYPE__ signed char -#define __INT_MAX__ 2147483647 -#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) -#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) -#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) -#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) -#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) -#define __LDBL_DECIMAL_DIG__ 36 -#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L -#define __LDBL_DIG__ 33 -#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L -#define __LDBL_HAS_DENORM__ 1 -#define __LDBL_HAS_INFINITY__ 1 -#define __LDBL_HAS_QUIET_NAN__ 1 -#define __LDBL_MANT_DIG__ 113 -#define __LDBL_MAX_10_EXP__ 4932 -#define __LDBL_MAX_EXP__ 16384 -#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L -#define __LDBL_MIN_10_EXP__ (-4931) -#define __LDBL_MIN_EXP__ (-16381) -#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L -#define __LITTLE_ENDIAN 1234 -#define __LITTLE_ENDIAN__ 1 -#define __LONG_LONG_MAX__ 9223372036854775807LL -#define __LONG_MAX __LONG_MAX__ -#define __LONG_MAX__ 9223372036854775807L -#define __LP64__ 1 -#define __NAMESER 19991006 -#define __NEED_FILE -#define __NEED___isoc_va_list -#define __NEED_blkcnt_t -#define __NEED_blksize_t -#define __NEED_clock_t -#define __NEED_clockid_t -#define __NEED_cnd_t -#define __NEED_dev_t -#define __NEED_double_t -#define __NEED_float_t -#define __NEED_fsblkcnt_t -#define __NEED_fsfilcnt_t -#define __NEED_gid_t -#define __NEED_id_t -#define __NEED_ino_t -#define __NEED_int16_t -#define __NEED_int32_t -#define __NEED_int64_t -#define __NEED_int8_t -#define __NEED_intmax_t -#define __NEED_intptr_t -#define __NEED_key_t -#define __NEED_locale_t -#define __NEED_mbstate_t -#define __NEED_mode_t -#define __NEED_mtx_t -#define __NEED_nlink_t -#define __NEED_off_t -#define __NEED_pid_t -#define __NEED_pthread_attr_t -#define __NEED_pthread_barrier_t -#define __NEED_pthread_barrierattr_t -#define __NEED_pthread_cond_t -#define __NEED_pthread_condattr_t -#define __NEED_pthread_key_t -#define __NEED_pthread_mutex_t -#define __NEED_pthread_mutexattr_t -#define __NEED_pthread_once_t -#define __NEED_pthread_rwlock_t -#define __NEED_pthread_rwlockattr_t -#define __NEED_pthread_spinlock_t -#define __NEED_pthread_t -#define __NEED_register_t -#define __NEED_regoff_t -#define __NEED_sa_family_t -#define __NEED_sigset_t -#define __NEED_size_t -#define __NEED_socklen_t -#define __NEED_ssize_t -#define __NEED_struct_iovec -#define __NEED_struct_timespec -#define __NEED_struct_timeval -#define __NEED_suseconds_t -#define __NEED_time_t -#define __NEED_timer_t -#define __NEED_u_int64_t -#define __NEED_uid_t -#define __NEED_uint16_t -#define __NEED_uint32_t -#define __NEED_uint64_t -#define __NEED_uint8_t -#define __NEED_uintmax_t -#define __NEED_uintptr_t -#define __NEED_useconds_t -#define __NEED_va_list -#define __NEED_wchar_t -#define __NEED_wctype_t -#define __NEED_wint_t -#define __OBJC_BOOL_IS_BOOL 0 -#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 -#define __OPENCL_MEMORY_SCOPE_DEVICE 2 -#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 -#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 -#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 -#define __ORDER_BIG_ENDIAN__ 4321 -#define __ORDER_LITTLE_ENDIAN__ 1234 -#define __ORDER_PDP_ENDIAN__ 3412 -#define __PDP_ENDIAN 3412 -#define __POINTER_WIDTH__ 64 -#define __PRAGMA_REDEFINE_EXTNAME 1 -#define __PTRDIFF_FMTd__ "ld" -#define __PTRDIFF_FMTi__ "li" -#define __PTRDIFF_MAX__ 9223372036854775807L -#define __PTRDIFF_TYPE__ long int -#define __PTRDIFF_WIDTH__ 64 -#define __REDIR(x,y) __typeof__(x) x __asm__(#y) -#define __RETCAST(x) -#define __RETCAST_2(x,y) -#define __RETCAST_3(x,y,z) -#define __RETCAST_CX(x) -#define __RETCAST_REAL(x) -#define __SCHAR_MAX__ 127 -#define __SHRT_MAX__ 32767 -#define __SID ('S' << 8) -#define __SIG_ATOMIC_MAX__ 9223372036854775807L -#define __SIG_ATOMIC_WIDTH__ 64 -#define __SIZEOF_DOUBLE__ 8 -#define __SIZEOF_FLOAT__ 4 -#define __SIZEOF_INT128__ 16 -#define __SIZEOF_INT__ 4 -#define __SIZEOF_LONG_DOUBLE__ 16 -#define __SIZEOF_LONG_LONG__ 8 -#define __SIZEOF_LONG__ 8 -#define __SIZEOF_POINTER__ 8 -#define __SIZEOF_PTRDIFF_T__ 8 -#define __SIZEOF_SHORT__ 2 -#define __SIZEOF_SIZE_T__ 8 -#define __SIZEOF_WCHAR_T__ 4 -#define __SIZEOF_WINT_T__ 4 -#define __SIZE_FMTX__ "lX" -#define __SIZE_FMTo__ "lo" -#define __SIZE_FMTu__ "lu" -#define __SIZE_FMTx__ "lx" -#define __SIZE_MAX__ 18446744073709551615UL -#define __SIZE_TYPE__ long unsigned int -#define __SIZE_WIDTH__ 64 -#define __STDARG_H -#define __STDC_HOSTED__ 1 -#define __STDC_IEC_559__ 1 -#define __STDC_ISO_10646__ 201206L -#define __STDC_UTF_16__ 1 -#define __STDC_UTF_32__ 1 -#define __STDC_VERSION__ 201710L -#define __STDC__ 1 -#define __STDDEF_H -#define __UAPI_DEF_IN6_ADDR 0 -#define __UAPI_DEF_IN6_ADDR_ALT 0 -#define __UAPI_DEF_IN6_PKTINFO 0 -#define __UAPI_DEF_IN_ADDR 0 -#define __UAPI_DEF_IN_CLASS 0 -#define __UAPI_DEF_IN_IPPROTO 0 -#define __UAPI_DEF_IN_PKTINFO 0 -#define __UAPI_DEF_IP6_MTUINFO 0 -#define __UAPI_DEF_IPHDR 0 -#define __UAPI_DEF_IPPROTO_V6 0 -#define __UAPI_DEF_IPV6_MREQ 0 -#define __UAPI_DEF_IPV6_OPTIONS 0 -#define __UAPI_DEF_IP_MREQ 0 -#define __UAPI_DEF_SOCKADDR_IN 0 -#define __UAPI_DEF_SOCKADDR_IN6 0 -#define __UINT16_C_SUFFIX__ -#define __UINT16_FMTX__ "hX" -#define __UINT16_FMTo__ "ho" -#define __UINT16_FMTu__ "hu" -#define __UINT16_FMTx__ "hx" -#define __UINT16_MAX__ 65535 -#define __UINT16_TYPE__ unsigned short -#define __UINT32_C_SUFFIX__ U -#define __UINT32_FMTX__ "X" -#define __UINT32_FMTo__ "o" -#define __UINT32_FMTu__ "u" -#define __UINT32_FMTx__ "x" -#define __UINT32_MAX__ 4294967295U -#define __UINT32_TYPE__ unsigned int -#define __UINT64_C_SUFFIX__ ULL -#define __UINT64_FMTX__ "llX" -#define __UINT64_FMTo__ "llo" -#define __UINT64_FMTu__ "llu" -#define __UINT64_FMTx__ "llx" -#define __UINT64_MAX__ 18446744073709551615ULL -#define __UINT64_TYPE__ long long unsigned int -#define __UINT8_C_SUFFIX__ -#define __UINT8_FMTX__ "hhX" -#define __UINT8_FMTo__ "hho" -#define __UINT8_FMTu__ "hhu" -#define __UINT8_FMTx__ "hhx" -#define __UINT8_MAX__ 255 -#define __UINT8_TYPE__ unsigned char -#define __UINTMAX_C_SUFFIX__ ULL -#define __UINTMAX_FMTX__ "llX" -#define __UINTMAX_FMTo__ "llo" -#define __UINTMAX_FMTu__ "llu" -#define __UINTMAX_FMTx__ "llx" -#define __UINTMAX_MAX__ 18446744073709551615ULL -#define __UINTMAX_TYPE__ long long unsigned int -#define __UINTMAX_WIDTH__ 64 -#define __UINTPTR_FMTX__ "lX" -#define __UINTPTR_FMTo__ "lo" -#define __UINTPTR_FMTu__ "lu" -#define __UINTPTR_FMTx__ "lx" -#define __UINTPTR_MAX__ 18446744073709551615UL -#define __UINTPTR_TYPE__ long unsigned int -#define __UINTPTR_WIDTH__ 64 -#define __UINT_FAST16_FMTX__ "hX" -#define __UINT_FAST16_FMTo__ "ho" -#define __UINT_FAST16_FMTu__ "hu" -#define __UINT_FAST16_FMTx__ "hx" -#define __UINT_FAST16_MAX__ 65535 -#define __UINT_FAST16_TYPE__ unsigned short -#define __UINT_FAST32_FMTX__ "X" -#define __UINT_FAST32_FMTo__ "o" -#define __UINT_FAST32_FMTu__ "u" -#define __UINT_FAST32_FMTx__ "x" -#define __UINT_FAST32_MAX__ 4294967295U -#define __UINT_FAST32_TYPE__ unsigned int -#define __UINT_FAST64_FMTX__ "llX" -#define __UINT_FAST64_FMTo__ "llo" -#define __UINT_FAST64_FMTu__ "llu" -#define __UINT_FAST64_FMTx__ "llx" -#define __UINT_FAST64_MAX__ 18446744073709551615ULL -#define __UINT_FAST64_TYPE__ long long unsigned int -#define __UINT_FAST8_FMTX__ "hhX" -#define __UINT_FAST8_FMTo__ "hho" -#define __UINT_FAST8_FMTu__ "hhu" -#define __UINT_FAST8_FMTx__ "hhx" -#define __UINT_FAST8_MAX__ 255 -#define __UINT_FAST8_TYPE__ unsigned char -#define __UINT_LEAST16_FMTX__ "hX" -#define __UINT_LEAST16_FMTo__ "ho" -#define __UINT_LEAST16_FMTu__ "hu" -#define __UINT_LEAST16_FMTx__ "hx" -#define __UINT_LEAST16_MAX__ 65535 -#define __UINT_LEAST16_TYPE__ unsigned short -#define __UINT_LEAST32_FMTX__ "X" -#define __UINT_LEAST32_FMTo__ "o" -#define __UINT_LEAST32_FMTu__ "u" -#define __UINT_LEAST32_FMTx__ "x" -#define __UINT_LEAST32_MAX__ 4294967295U -#define __UINT_LEAST32_TYPE__ unsigned int -#define __UINT_LEAST64_FMTX__ "llX" -#define __UINT_LEAST64_FMTo__ "llo" -#define __UINT_LEAST64_FMTu__ "llu" -#define __UINT_LEAST64_FMTx__ "llx" -#define __UINT_LEAST64_MAX__ 18446744073709551615ULL -#define __UINT_LEAST64_TYPE__ long long unsigned int -#define __UINT_LEAST8_FMTX__ "hhX" -#define __UINT_LEAST8_FMTo__ "hho" -#define __UINT_LEAST8_FMTu__ "hhu" -#define __UINT_LEAST8_FMTx__ "hhx" -#define __UINT_LEAST8_MAX__ 255 -#define __UINT_LEAST8_TYPE__ unsigned char -#define __USER_LABEL_PREFIX__ -#define __USE_TIME_BITS64 1 -#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) -#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) -#define __WASI_ADVICE_NORMAL (UINT8_C(0)) -#define __WASI_ADVICE_RANDOM (UINT8_C(2)) -#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) -#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) -#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) -#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) -#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) -#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) -#define __WASI_DIRCOOKIE_START (UINT64_C(0)) -#define __WASI_ERRNO_2BIG (UINT16_C(1)) -#define __WASI_ERRNO_ACCES (UINT16_C(2)) -#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) -#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) -#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) -#define __WASI_ERRNO_AGAIN (UINT16_C(6)) -#define __WASI_ERRNO_ALREADY (UINT16_C(7)) -#define __WASI_ERRNO_BADF (UINT16_C(8)) -#define __WASI_ERRNO_BADMSG (UINT16_C(9)) -#define __WASI_ERRNO_BUSY (UINT16_C(10)) -#define __WASI_ERRNO_CANCELED (UINT16_C(11)) -#define __WASI_ERRNO_CHILD (UINT16_C(12)) -#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) -#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) -#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) -#define __WASI_ERRNO_DEADLK (UINT16_C(16)) -#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) -#define __WASI_ERRNO_DOM (UINT16_C(18)) -#define __WASI_ERRNO_DQUOT (UINT16_C(19)) -#define __WASI_ERRNO_EXIST (UINT16_C(20)) -#define __WASI_ERRNO_FAULT (UINT16_C(21)) -#define __WASI_ERRNO_FBIG (UINT16_C(22)) -#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) -#define __WASI_ERRNO_IDRM (UINT16_C(24)) -#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) -#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) -#define __WASI_ERRNO_INTR (UINT16_C(27)) -#define __WASI_ERRNO_INVAL (UINT16_C(28)) -#define __WASI_ERRNO_IO (UINT16_C(29)) -#define __WASI_ERRNO_ISCONN (UINT16_C(30)) -#define __WASI_ERRNO_ISDIR (UINT16_C(31)) -#define __WASI_ERRNO_LOOP (UINT16_C(32)) -#define __WASI_ERRNO_MFILE (UINT16_C(33)) -#define __WASI_ERRNO_MLINK (UINT16_C(34)) -#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) -#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) -#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) -#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) -#define __WASI_ERRNO_NETRESET (UINT16_C(39)) -#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) -#define __WASI_ERRNO_NFILE (UINT16_C(41)) -#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) -#define __WASI_ERRNO_NODEV (UINT16_C(43)) -#define __WASI_ERRNO_NOENT (UINT16_C(44)) -#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) -#define __WASI_ERRNO_NOLCK (UINT16_C(46)) -#define __WASI_ERRNO_NOLINK (UINT16_C(47)) -#define __WASI_ERRNO_NOMEM (UINT16_C(48)) -#define __WASI_ERRNO_NOMSG (UINT16_C(49)) -#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) -#define __WASI_ERRNO_NOSPC (UINT16_C(51)) -#define __WASI_ERRNO_NOSYS (UINT16_C(52)) -#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) -#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) -#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) -#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) -#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) -#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) -#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) -#define __WASI_ERRNO_NOTTY (UINT16_C(59)) -#define __WASI_ERRNO_NXIO (UINT16_C(60)) -#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) -#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) -#define __WASI_ERRNO_PERM (UINT16_C(63)) -#define __WASI_ERRNO_PIPE (UINT16_C(64)) -#define __WASI_ERRNO_PROTO (UINT16_C(65)) -#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) -#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) -#define __WASI_ERRNO_RANGE (UINT16_C(68)) -#define __WASI_ERRNO_ROFS (UINT16_C(69)) -#define __WASI_ERRNO_SPIPE (UINT16_C(70)) -#define __WASI_ERRNO_SRCH (UINT16_C(71)) -#define __WASI_ERRNO_STALE (UINT16_C(72)) -#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) -#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) -#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) -#define __WASI_ERRNO_XDEV (UINT16_C(75)) -#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) -#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) -#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) -#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) -#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) -#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) -#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) -#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) -#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) -#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) -#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) -#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) -#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) -#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) -#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) -#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) -#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) -#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) -#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) -#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) -#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) -#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) -#define __WASI_NOEXCEPT -#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) -#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) -#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) -#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) -#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) -#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) -#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) -#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) -#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) -#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) -#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) -#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) -#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) -#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) -#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) -#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) -#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) -#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) -#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) -#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) -#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) -#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) -#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) -#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) -#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) -#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) -#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) -#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) -#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) -#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) -#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) -#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) -#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) -#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) -#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) -#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) -#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) -#define __WASI_WHENCE_CUR (UINT8_C(1)) -#define __WASI_WHENCE_END (UINT8_C(2)) -#define __WASI_WHENCE_SET (UINT8_C(0)) -#define __WCHAR_MAX__ 2147483647 -#define __WCHAR_TYPE__ int -#define __WCHAR_WIDTH__ 32 -#define __WINT_MAX__ 2147483647 -#define __WINT_TYPE__ int -#define __WINT_WIDTH__ 32 -#define __WORDSIZE 64 -#define __alignas_is_defined 1 -#define __alignof_is_defined 1 -#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) -#define __bool_true_false_are_defined 1 -#define __inline inline -#define __restrict restrict -#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) -#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) -#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) -#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) -#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) -#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) -#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) -#define __tm_gmtoff tm_gmtoff -#define __tm_zone tm_zone -#define __va_copy(d,s) __builtin_va_copy(d, s) -#define __wasi__ 1 -#define __wasi_api_h -#define __wasi_libc_environ_h -#define __wasi_libc_find_relpath_h -#define __wasi_libc_h -#define __wasi_libc_nocwd_h -#define __wasilibc___errno_h -#define __wasilibc___errno_values_h -#define __wasilibc___fd_set_h -#define __wasilibc___function___isatty_h -#define __wasilibc___functions_malloc_h -#define __wasilibc___functions_memcpy_h -#define __wasilibc___header_dirent_h -#define __wasilibc___header_fcntl_h -#define __wasilibc___header_netinet_in_h -#define __wasilibc___header_poll_h -#define __wasilibc___header_stdlib_h -#define __wasilibc___header_string_h -#define __wasilibc___header_sys_ioctl_h -#define __wasilibc___header_sys_resource_h -#define __wasilibc___header_sys_socket_h -#define __wasilibc___header_sys_stat_h -#define __wasilibc___header_time_h -#define __wasilibc___header_unistd_h -#define __wasilibc___include_inttypes_h -#define __wasilibc___macro_FD_SETSIZE_h -#define __wasilibc___macro_PAGESIZE_h -#define __wasilibc___mode_t_h -#define __wasilibc___seek_h -#define __wasilibc___struct_dirent_h -#define __wasilibc___struct_in6_addr_h -#define __wasilibc___struct_in_addr_h -#define __wasilibc___struct_iovec_h -#define __wasilibc___struct_msghdr_h -#define __wasilibc___struct_pollfd_h -#define __wasilibc___struct_rusage_h -#define __wasilibc___struct_sockaddr_h -#define __wasilibc___struct_sockaddr_in6_h -#define __wasilibc___struct_sockaddr_in_h -#define __wasilibc___struct_sockaddr_storage_h -#define __wasilibc___struct_sockaddr_un_h -#define __wasilibc___struct_stat_h -#define __wasilibc___struct_timespec_h -#define __wasilibc___struct_timeval_h -#define __wasilibc___struct_tm_h -#define __wasilibc___struct_tms_h -#define __wasilibc___typedef_DIR_h -#define __wasilibc___typedef_blkcnt_t_h -#define __wasilibc___typedef_blksize_t_h -#define __wasilibc___typedef_clock_t_h -#define __wasilibc___typedef_clockid_t_h -#define __wasilibc___typedef_dev_t_h -#define __wasilibc___typedef_fd_set_h -#define __wasilibc___typedef_gid_t_h -#define __wasilibc___typedef_in_addr_t_h -#define __wasilibc___typedef_in_port_t_h -#define __wasilibc___typedef_ino_t_h -#define __wasilibc___typedef_mode_t_h -#define __wasilibc___typedef_nfds_t_h -#define __wasilibc___typedef_nlink_t_h -#define __wasilibc___typedef_off_t_h -#define __wasilibc___typedef_sa_family_t_h -#define __wasilibc___typedef_sigset_t_h -#define __wasilibc___typedef_socklen_t_h -#define __wasilibc___typedef_ssize_t_h -#define __wasilibc___typedef_suseconds_t_h -#define __wasilibc___typedef_time_t_h -#define __wasilibc___typedef_uid_t_h -#define __wasm 1 -#define __wasm64 1 -#define __wasm64__ 1 -#define __wasm__ 1 -#define _tolower(a) ((a)|0x20) -#define _toupper(a) ((a)&0x5f) -#define acos(x) __tg_real_complex(acos, (x)) -#define acosh(x) __tg_real_complex(acosh, (x)) -#define alignas _Alignas -#define alignof _Alignof -#define alloca __builtin_alloca -#define alphasort64 alphasort -#define and && -#define and_eq &= -#define asin(x) __tg_real_complex(asin, (x)) -#define asinh(x) __tg_real_complex(asinh, (x)) -#define atan(x) __tg_real_complex(atan, (x)) -#define atan2(x,y) __tg_real_2(atan2, (x), (y)) -#define atanh(x) __tg_real_complex(atanh, (x)) -#define be16toh(x) __bswap16(x) -#define be32toh(x) __bswap32(x) -#define be64toh(x) __bswap64(x) -#define betoh16(x) __bswap16(x) -#define betoh32(x) __bswap32(x) -#define betoh64(x) __bswap64(x) -#define bitand & -#define bitor | -#define blkcnt64_t blkcnt_t -#define bool _Bool -#define bswap_16(x) __bswap_16(x) -#define bswap_32(x) __bswap_32(x) -#define bswap_64(x) __bswap_64(x) -#define carg(x) __tg_complex_retreal(carg, (x)) -#define cbrt(x) __tg_real(cbrt, (x)) -#define ceil(x) __tg_real(ceil, (x)) -#define cimag(x) __tg_complex_retreal(cimag, (x)) -#define cimagf(x) (__builtin_cimagf(x)) -#define cimagl(x) (__builtin_cimagl(x)) -#define clrbit(x,i) __bitop(x,i,&=~) -#define compl ~ -#define complex _Complex -#define conj(x) __tg_complex(conj, (x)) -#define copysign(x,y) __tg_real_2(copysign, (x), (y)) -#define cos(x) __tg_real_complex(cos, (x)) -#define cosh(x) __tg_real_complex(cosh, (x)) -#define cproj(x) __tg_complex(cproj, (x)) -#define creal(x) __tg_complex_retreal(creal, (x)) -#define crealf(x) (__builtin_crealf(x)) -#define creall(x) (__builtin_creall(x)) -#define creat64 creat -#define d_fileno d_ino -#define direct dirent -#define dirent64 dirent -#define erf(x) __tg_real(erf, (x)) -#define erfc(x) __tg_real(erfc, (x)) -#define errno errno -#define exp(x) __tg_real_complex(exp, (x)) -#define exp2(x) __tg_real(exp2, (x)) -#define expm1(x) __tg_real(expm1, (x)) -#define fabs(x) __tg_real_complex_fabs(x) -#define false 0 -#define fdim(x,y) __tg_real_2(fdim, (x), (y)) -#define fgetpos64 fgetpos -#define floor(x) __tg_real(floor, (x)) -#define fma(x,y,z) __tg_real_fma((x), (y), (z)) -#define fmax(x,y) __tg_real_2(fmax, (x), (y)) -#define fmin(x,y) __tg_real_2(fmin, (x), (y)) -#define fmod(x,y) __tg_real_2(fmod, (x), (y)) -#define fopen64 fopen -#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) -#define fpos64_t fpos_t -#define freopen64 freopen -#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) -#define fsblkcnt64_t fsblkcnt_t -#define fseeko64 fseeko -#define fsetpos64 fsetpos -#define fsfilcnt64_t fsfilcnt_t -#define fstat64 fstat -#define fstatat64 fstatat -#define fstatvfs64 fstatvfs -#define ftello64 ftello -#define ftruncate64 ftruncate -#define getdents64 getdents -#define glob64 glob -#define glob64_t glob_t -#define globfree64 globfree -#define howmany(n,d) (((n)+((d)-1))/(d)) -#define htobe16(x) __bswap16(x) -#define htobe32(x) __bswap32(x) -#define htobe64(x) __bswap64(x) -#define htole16(x) (uint16_t)(x) -#define htole32(x) (uint32_t)(x) -#define htole64(x) (uint64_t)(x) -#define hypot(x,y) __tg_real_2(hypot, (x), (y)) -#define icmp6_data16 icmp6_dataun.icmp6_un_data16 -#define icmp6_data32 icmp6_dataun.icmp6_un_data32 -#define icmp6_data8 icmp6_dataun.icmp6_un_data8 -#define icmp6_id icmp6_data16[0] -#define icmp6_maxdelay icmp6_data16[0] -#define icmp6_mtu icmp6_data32[0] -#define icmp6_pptr icmp6_data32[0] -#define icmp6_seq icmp6_data16[1] -#define icmp_data icmp_dun.id_data -#define icmp_gwaddr icmp_hun.ih_gwaddr -#define icmp_id icmp_hun.ih_idseq.icd_id -#define icmp_ip icmp_dun.id_ip.idi_ip -#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime -#define icmp_mask icmp_dun.id_mask -#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu -#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs -#define icmp_otime icmp_dun.id_ts.its_otime -#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void -#define icmp_pptr icmp_hun.ih_pptr -#define icmp_radv icmp_dun.id_radv -#define icmp_rtime icmp_dun.id_ts.its_rtime -#define icmp_seq icmp_hun.ih_idseq.icd_seq -#define icmp_ttime icmp_dun.id_ts.its_ttime -#define icmp_void icmp_hun.ih_void -#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa -#define ifa_broadaddr ifa_ifu.ifu_broadaddr -#define ifa_dstaddr ifa_ifu.ifu_dstaddr -#define ilogb(x) __tg_real_nocast(ilogb, (x)) -#define ino64_t ino_t -#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow -#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt -#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen -#define ip6_vfc ip6_ctlun.ip6_un2_vfc -#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) -#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) -#define isclr(x,i) !isset(x,i) -#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) -#define isfinite(x) (__builtin_isfinite(x)) -#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) -#define isgreater(x,y) (__builtin_isgreater(x, y)) -#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) -#define isinf(x) (__builtin_isinf(x)) -#define isless(x,y) (__builtin_isless(x, y)) -#define islessequal(x,y) (__builtin_islessequal(x, y)) -#define islessgreater(x,y) (__builtin_islessgreater(x, y)) -#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) -#define isnan(x) (__builtin_isnan(x)) -#define isnormal(x) (__builtin_isnormal(x)) -#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) -#define isset(x,i) __bitop(x,i,&) -#define isspace(a) __isspace(a) -#define isunordered(x,y) (__builtin_isunordered(x, y)) -#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) -#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) -#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) -#define le16toh(x) (uint16_t)(x) -#define le32toh(x) (uint32_t)(x) -#define le64toh(x) (uint64_t)(x) -#define letoh16(x) (uint16_t)(x) -#define letoh32(x) (uint32_t)(x) -#define letoh64(x) (uint64_t)(x) -#define lgamma(x) __tg_real(lgamma, (x)) -#define llrint(x) __tg_real_nocast(llrint, (x)) -#define llround(x) __tg_real_nocast(llround, (x)) -#define loff_t off_t -#define log(x) __tg_real_complex(log, (x)) -#define log10(x) __tg_real(log10, (x)) -#define log1p(x) __tg_real(log1p, (x)) -#define log2(x) __tg_real(log2, (x)) -#define logb(x) __tg_real(logb, (x)) -#define lrint(x) __tg_real_nocast(lrint, (x)) -#define lround(x) __tg_real_nocast(lround, (x)) -#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) -#define lseek64 lseek -#define lstat64 lstat -#define math_errhandling 2 -#define mld_cksum mld_icmp6_hdr.icmp6_cksum -#define mld_code mld_icmp6_hdr.icmp6_code -#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] -#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] -#define mld_type mld_icmp6_hdr.icmp6_type -#define nd_na_cksum nd_na_hdr.icmp6_cksum -#define nd_na_code nd_na_hdr.icmp6_code -#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] -#define nd_na_type nd_na_hdr.icmp6_type -#define nd_ns_cksum nd_ns_hdr.icmp6_cksum -#define nd_ns_code nd_ns_hdr.icmp6_code -#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] -#define nd_ns_type nd_ns_hdr.icmp6_type -#define nd_ra_cksum nd_ra_hdr.icmp6_cksum -#define nd_ra_code nd_ra_hdr.icmp6_code -#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] -#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] -#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] -#define nd_ra_type nd_ra_hdr.icmp6_type -#define nd_rd_cksum nd_rd_hdr.icmp6_cksum -#define nd_rd_code nd_rd_hdr.icmp6_code -#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] -#define nd_rd_type nd_rd_hdr.icmp6_type -#define nd_rs_cksum nd_rs_hdr.icmp6_cksum -#define nd_rs_code nd_rs_hdr.icmp6_code -#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] -#define nd_rs_type nd_rs_hdr.icmp6_type -#define nearbyint(x) __tg_real(nearbyint, (x)) -#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) -#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) -#define nftw64 nftw -#define no_argument 0 -#define noreturn _Noreturn -#define not ! -#define not_eq != -#define ns_msg_base(handle) ((handle)._msg + 0) -#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) -#define ns_msg_end(handle) ((handle)._eom + 0) -#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) -#define ns_msg_id(handle) ((handle)._id + 0) -#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) -#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) -#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") -#define ns_rr_rdata(rr) ((rr).rdata + 0) -#define ns_rr_rdlen(rr) ((rr).rdlength + 0) -#define ns_rr_ttl(rr) ((rr).ttl + 0) -#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) -#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) -#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) -#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) -#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) -#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) -#define off64_t off_t -#define offsetof(t,d) __builtin_offsetof(t, d) -#define open64 open -#define openat64 openat -#define optional_argument 2 -#define or || -#define or_eq |= -#define posix_fadvise64 posix_fadvise -#define posix_fallocate64 posix_fallocate -#define pow(x,y) __tg_real_complex_pow((x), (y)) -#define powerof2(n) !(((n)-1) & (n)) -#define pread64 pread -#define preadv64 preadv -#define pwrite64 pwrite -#define pwritev64 pwritev -#define readdir64 readdir -#define remainder(x,y) __tg_real_2(remainder, (x), (y)) -#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) -#define required_argument 1 -#define rint(x) __tg_real(rint, (x)) -#define round(x) __tg_real(round, (x)) -#define roundup(n,d) (howmany(n,d)*(d)) -#define rr_cksum rr_hdr.icmp6_cksum -#define rr_code rr_hdr.icmp6_code -#define rr_seqnum rr_hdr.icmp6_data32[0] -#define rr_type rr_hdr.icmp6_type -#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) -#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) -#define scandir64 scandir -#define setbit(x,i) __bitop(x,i,|=) -#define signbit(x) (__builtin_signbit(x)) -#define sin(x) __tg_real_complex(sin, (x)) -#define sinh(x) __tg_real_complex(sinh, (x)) -#define sqrt(x) __tg_real_complex(sqrt, (x)) -#define st_atime st_atim.tv_sec -#define st_ctime st_ctim.tv_sec -#define st_mtime st_mtim.tv_sec -#define stat64 stat -#define static_assert _Static_assert -#define statvfs64 statvfs -#define stderr (stderr) -#define stdin (stdin) -#define stdout (stdout) -#define strdupa(x) strcpy(alloca(strlen(x)+1),x) -#define tan(x) __tg_real_complex(tan, (x)) -#define tanh(x) __tg_real_complex(tanh, (x)) -#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) -#define tgamma(x) __tg_real(tgamma, (x)) -#define th_block th_u.tu_block -#define th_code th_u.tu_code -#define th_msg th_data -#define th_stuff th_u.tu_stuff -#define thrd_equal(A,B) ((A) == (B)) -#define thread_local _Thread_local -#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) -#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) -#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) -#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) -#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) -#define true 1 -#define trunc(x) __tg_real(trunc, (x)) -#define uh_dport dest -#define uh_sport source -#define uh_sum check -#define uh_ulen len -#define va_arg(ap,type) __builtin_va_arg(ap, type) -#define va_copy(dest,src) __builtin_va_copy(dest, src) -#define va_end(ap) __builtin_va_end(ap) -#define va_start(ap,param) __builtin_va_start(ap, param) -#define versionsort64 versionsort -#define xEOF 236 -#define xor ^ -#define xor_eq ^= diff --git a/expected/wasm64-wasi/undefined-symbols.txt b/expected/wasm64-wasi/undefined-symbols.txt deleted file mode 100644 index e7c62031f..000000000 --- a/expected/wasm64-wasi/undefined-symbols.txt +++ /dev/null @@ -1,69 +0,0 @@ -__addtf3 -__divtf3 -__eqtf2 -__extenddftf2 -__extendsftf2 -__fixtfdi -__fixtfsi -__fixunstfsi -__floatditf -__floatsitf -__floatunsitf -__getf2 -__gttf2 -__heap_base -__heap_end -__imported_wasi_snapshot_preview1_args_get -__imported_wasi_snapshot_preview1_args_sizes_get -__imported_wasi_snapshot_preview1_clock_res_get -__imported_wasi_snapshot_preview1_clock_time_get -__imported_wasi_snapshot_preview1_environ_get -__imported_wasi_snapshot_preview1_environ_sizes_get -__imported_wasi_snapshot_preview1_fd_advise -__imported_wasi_snapshot_preview1_fd_allocate -__imported_wasi_snapshot_preview1_fd_close -__imported_wasi_snapshot_preview1_fd_datasync -__imported_wasi_snapshot_preview1_fd_fdstat_get -__imported_wasi_snapshot_preview1_fd_fdstat_set_flags -__imported_wasi_snapshot_preview1_fd_fdstat_set_rights -__imported_wasi_snapshot_preview1_fd_filestat_get -__imported_wasi_snapshot_preview1_fd_filestat_set_size -__imported_wasi_snapshot_preview1_fd_filestat_set_times -__imported_wasi_snapshot_preview1_fd_pread -__imported_wasi_snapshot_preview1_fd_prestat_dir_name -__imported_wasi_snapshot_preview1_fd_prestat_get -__imported_wasi_snapshot_preview1_fd_pwrite -__imported_wasi_snapshot_preview1_fd_read -__imported_wasi_snapshot_preview1_fd_readdir -__imported_wasi_snapshot_preview1_fd_renumber -__imported_wasi_snapshot_preview1_fd_seek -__imported_wasi_snapshot_preview1_fd_sync -__imported_wasi_snapshot_preview1_fd_tell -__imported_wasi_snapshot_preview1_fd_write -__imported_wasi_snapshot_preview1_path_create_directory -__imported_wasi_snapshot_preview1_path_filestat_get -__imported_wasi_snapshot_preview1_path_filestat_set_times -__imported_wasi_snapshot_preview1_path_link -__imported_wasi_snapshot_preview1_path_open -__imported_wasi_snapshot_preview1_path_readlink -__imported_wasi_snapshot_preview1_path_remove_directory -__imported_wasi_snapshot_preview1_path_rename -__imported_wasi_snapshot_preview1_path_symlink -__imported_wasi_snapshot_preview1_path_unlink_file -__imported_wasi_snapshot_preview1_poll_oneoff -__imported_wasi_snapshot_preview1_proc_exit -__imported_wasi_snapshot_preview1_random_get -__imported_wasi_snapshot_preview1_sched_yield -__imported_wasi_snapshot_preview1_sock_accept -__imported_wasi_snapshot_preview1_sock_recv -__imported_wasi_snapshot_preview1_sock_send -__imported_wasi_snapshot_preview1_sock_shutdown -__letf2 -__lttf2 -__netf2 -__stack_pointer -__subtf3 -__trunctfdf2 -__trunctfsf2 -__unordtf2 -__wasm_call_ctors From 2672d35f8746af131b96d0f423b791f7c26bb74b Mon Sep 17 00:00:00 2001 From: trcrsired Date: Sat, 16 Mar 2024 22:42:23 -0400 Subject: [PATCH 36/43] fix wasi32-wasi --- Makefile | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 26f61cd22..75196d860 100644 --- a/Makefile +++ b/Makefile @@ -46,8 +46,6 @@ BULK_MEMORY_THRESHOLD ?= 32 # Threaded version necessitates a different target, as objects from different # targets can't be mixed together while linking. - - ifeq ($(THREAD_MODEL), posix) THREADS_SUFFIX=-threads else @@ -61,7 +59,20 @@ WASM_SUFFIX=32 endif TARGET_TRIPLE = wasm${WASM_SUFFIX}-wasi$(WASI_SNAPSHOT)${THREADS_SUFFIX} -EXPECTED_TARGET_DIR = expected/${TARGET_TRIPLE} + +ifeq ($(TARGET_TRIPLE), wasm32-wasi) +EXPECTED_TARGET_TRIPLE = wasm32-wasip1 +else ifeq ($(TARGET_TRIPLE), wasm32-wasi-threads) +EXPECTED_TARGET_TRIPLE = wasm32-wasip1-threads +else ifeq ($(TARGET_TRIPLE), wasm64-wasi) +EXPECTED_TARGET_TRIPLE = wasm64-wasip1 +else ifeq ($(TARGET_TRIPLE), wasm64-wasi-threads) +EXPECTED_TARGET_TRIPLE = wasm64-wasip1-threads +else +EXPECTED_TARGET_TRIPLE = ${TARGET_TRIPLE} +endif + +EXPECTED_TARGET_DIR = expected/${EXPECTED_TARGET_TRIPLE} BUILTINS_LIB ?= $(shell ${CC} --print-libgcc-file-name) From bc5755da7da1bacb5561e7d0a16f5d36b5967f40 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 17:38:55 -0400 Subject: [PATCH 37/43] remove -D_WASI_EMULATED_PTHREAD since it breaks llvm even we enable posix threads --- libc-top-half/musl/include/pthread.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc-top-half/musl/include/pthread.h b/libc-top-half/musl/include/pthread.h index fa9f66ae8..5148f45bc 100644 --- a/libc-top-half/musl/include/pthread.h +++ b/libc-top-half/musl/include/pthread.h @@ -83,7 +83,7 @@ int pthread_detach(pthread_t); _Noreturn void pthread_exit(void *); int pthread_join(pthread_t, void **); #else -#if defined(_WASI_EMULATED_PTHREAD) || defined(_REENTRANT) +#if defined(_REENTRANT) int pthread_create(pthread_t *__restrict, const pthread_attr_t *__restrict, void *(*)(void *), void *__restrict); int pthread_detach(pthread_t); int pthread_join(pthread_t, void **); From 66491d24645a6ce1a66cb885ad86d6c9178e80c2 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 17:46:51 -0400 Subject: [PATCH 38/43] give back shit --- libc-top-half/musl/include/pthread.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc-top-half/musl/include/pthread.h b/libc-top-half/musl/include/pthread.h index 5148f45bc..799301a2e 100644 --- a/libc-top-half/musl/include/pthread.h +++ b/libc-top-half/musl/include/pthread.h @@ -83,7 +83,7 @@ int pthread_detach(pthread_t); _Noreturn void pthread_exit(void *); int pthread_join(pthread_t, void **); #else -#if defined(_REENTRANT) +#if defined(_REENTRANT) || defined(_WASI_EMULATED_PTHREAD) int pthread_create(pthread_t *__restrict, const pthread_attr_t *__restrict, void *(*)(void *), void *__restrict); int pthread_detach(pthread_t); int pthread_join(pthread_t, void **); From 0705ecfbe48fc8ebbcba05519a72a95238bd9afc Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 17:48:34 -0400 Subject: [PATCH 39/43] force enable feature --- libc-top-half/musl/include/features.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libc-top-half/musl/include/features.h b/libc-top-half/musl/include/features.h index 85cfb72a0..486e7665f 100644 --- a/libc-top-half/musl/include/features.h +++ b/libc-top-half/musl/include/features.h @@ -36,5 +36,8 @@ #endif #define __REDIR(x,y) __typeof__(x) x __asm__(#y) +#if !defined(_REENTRANT) && !defined(_WASI_EMULATED_PTHREAD) +#define _WASI_EMULATED_PTHREAD +#endif #endif From b12938132134e60c702eb6cd729c029918769a25 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 17:49:06 -0400 Subject: [PATCH 40/43] this is dogshit --- libc-top-half/musl/include/pthread.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libc-top-half/musl/include/pthread.h b/libc-top-half/musl/include/pthread.h index 799301a2e..fa9f66ae8 100644 --- a/libc-top-half/musl/include/pthread.h +++ b/libc-top-half/musl/include/pthread.h @@ -83,7 +83,7 @@ int pthread_detach(pthread_t); _Noreturn void pthread_exit(void *); int pthread_join(pthread_t, void **); #else -#if defined(_REENTRANT) || defined(_WASI_EMULATED_PTHREAD) +#if defined(_WASI_EMULATED_PTHREAD) || defined(_REENTRANT) int pthread_create(pthread_t *__restrict, const pthread_attr_t *__restrict, void *(*)(void *), void *__restrict); int pthread_detach(pthread_t); int pthread_join(pthread_t, void **); From 3992e732bb9fe78dc3d403135486cf00edf99848 Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 18:18:44 -0400 Subject: [PATCH 41/43] fix --- libc-bottom-half/sources/descriptor_table.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/libc-bottom-half/sources/descriptor_table.c b/libc-bottom-half/sources/descriptor_table.c index d45e7ce58..fd9dea23f 100644 --- a/libc-bottom-half/sources/descriptor_table.c +++ b/libc-bottom-half/sources/descriptor_table.c @@ -24,18 +24,24 @@ #include +#ifdef __wasm64__ +#define IMPORT_NAME(x) __import_name__(x "_wasm64") +#else +#define IMPORT_NAME(x) __import_name__(x) +#endif + __attribute__((__import_module__("wasi_snapshot_preview1"), - __import_name__("adapter_open_badfd"))) extern int32_t + IMPORT_NAME("adapter_open_badfd"))) extern int32_t __wasi_preview1_adapter_open_badfd(int32_t); static bool wasi_preview1_adapter_open_badfd(int *fd) { - return __wasi_preview1_adapter_open_badfd((int32_t)fd) == 0; + return __wasi_preview1_adapter_open_badfd((intptr_t)fd) == 0; } __attribute__((__import_module__("wasi_snapshot_preview1"), - __import_name__("adapter_close_badfd"))) extern int32_t - __wasi_preview1_adapter_close_badfd(int32_t); + IMPORT_NAME("adapter_close_badfd"))) extern int32_t + __wasi_preview1_adapter_close_badfd(intptr_t); static bool wasi_preview1_adapter_close_badfd(int fd) { From 0873325a4309826a7e181875feb4e146423b8c9e Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 18:18:59 -0400 Subject: [PATCH 42/43] fix --- libc-bottom-half/sources/descriptor_table.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libc-bottom-half/sources/descriptor_table.c b/libc-bottom-half/sources/descriptor_table.c index fd9dea23f..067cdfd6d 100644 --- a/libc-bottom-half/sources/descriptor_table.c +++ b/libc-bottom-half/sources/descriptor_table.c @@ -24,11 +24,13 @@ #include +#ifndef IMPORT_NAME #ifdef __wasm64__ #define IMPORT_NAME(x) __import_name__(x "_wasm64") #else #define IMPORT_NAME(x) __import_name__(x) #endif +#endif __attribute__((__import_module__("wasi_snapshot_preview1"), IMPORT_NAME("adapter_open_badfd"))) extern int32_t From 8f8dfe7262dc8ec80f319d4e4427793f1d9409fd Mon Sep 17 00:00:00 2001 From: trcrsired Date: Tue, 29 Oct 2024 18:20:30 -0400 Subject: [PATCH 43/43] fix issues --- .../predefined-macros.txt | 2 +- expected/wasm32-wasip1/predefined-macros.txt | 6 +- expected/wasm32-wasip2/predefined-macros.txt | 6 +- .../wasm64-wasip1-threads/defined-symbols.txt | 18 +- expected/wasm64-wasip1-threads/include-all.c | 1 + .../predefined-macros.txt | 45 +- .../undefined-symbols.txt | 1 - expected/wasm64-wasip1/defined-symbols.txt | 128 + expected/wasm64-wasip1/include-all.c | 2 + expected/wasm64-wasip1/predefined-macros.txt | 85 +- expected/wasm64-wasip2/defined-symbols.txt | 1206 ------ expected/wasm64-wasip2/include-all.c | 171 - expected/wasm64-wasip2/predefined-macros.txt | 3365 ----------------- expected/wasm64-wasip2/undefined-symbols.txt | 69 - 14 files changed, 271 insertions(+), 4834 deletions(-) delete mode 100644 expected/wasm64-wasip2/defined-symbols.txt delete mode 100644 expected/wasm64-wasip2/include-all.c delete mode 100644 expected/wasm64-wasip2/predefined-macros.txt delete mode 100644 expected/wasm64-wasip2/undefined-symbols.txt diff --git a/expected/wasm32-wasip1-threads/predefined-macros.txt b/expected/wasm32-wasip1-threads/predefined-macros.txt index fb5ceb93a..83f009794 100644 --- a/expected/wasm32-wasip1-threads/predefined-macros.txt +++ b/expected/wasm32-wasip1-threads/predefined-macros.txt @@ -3089,7 +3089,7 @@ #define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) #define __tm_gmtoff tm_gmtoff #define __tm_zone tm_zone -#define __va_copy(d,s) __builtin_va_copy(d,s) +#define __va_copy(d,s) __builtin_va_copy(d, s) #define __wasi__ 1 #define __wasi_api_h #define __wasi_libc_environ_h diff --git a/expected/wasm32-wasip1/predefined-macros.txt b/expected/wasm32-wasip1/predefined-macros.txt index 5679347ca..c0e20feeb 100644 --- a/expected/wasm32-wasip1/predefined-macros.txt +++ b/expected/wasm32-wasip1/predefined-macros.txt @@ -2419,6 +2419,7 @@ #define _UTIME_H #define _VALUES_H #define _VA_LIST +#define _WASI_EMULATED_PTHREAD #define _WCHAR_H #define _WCHAR_T #define _WCTYPE_H @@ -3390,12 +3391,7 @@ #define preadv64 preadv #define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) #define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); -#define pthread_create(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_detach(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) #define pthread_equal(x,y) ((x)==(y)) -#define pthread_join(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_timedjoin_np(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_tryjoin_np(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) #define pwrite64 pwrite #define pwritev64 pwritev #define readdir64 readdir diff --git a/expected/wasm32-wasip2/predefined-macros.txt b/expected/wasm32-wasip2/predefined-macros.txt index c68bb01e7..8b73ed043 100644 --- a/expected/wasm32-wasip2/predefined-macros.txt +++ b/expected/wasm32-wasip2/predefined-macros.txt @@ -2570,6 +2570,7 @@ #define _UTIME_H #define _VALUES_H #define _VA_LIST +#define _WASI_EMULATED_PTHREAD #define _WCHAR_H #define _WCHAR_T #define _WCTYPE_H @@ -3545,12 +3546,7 @@ #define preadv64 preadv #define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) #define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); -#define pthread_create(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_detach(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) #define pthread_equal(x,y) ((x)==(y)) -#define pthread_join(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_timedjoin_np(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) -#define pthread_tryjoin_np(...) ({ _Static_assert(0, "This mode of WASI does not have threads enabled; to enable stub functions which always fail, compile with -D_WASI_EMULATED_PTHREAD and link with -lwasi-emulated-pthread"); 0;}) #define pwrite64 pwrite #define pwritev64 pwritev #define readdir64 readdir diff --git a/expected/wasm64-wasip1-threads/defined-symbols.txt b/expected/wasm64-wasip1-threads/defined-symbols.txt index f3fc6d4a7..2218541b4 100644 --- a/expected/wasm64-wasip1-threads/defined-symbols.txt +++ b/expected/wasm64-wasip1-threads/defined-symbols.txt @@ -395,6 +395,7 @@ __wasilibc_pthread_self __wasilibc_register_preopened_fd __wasilibc_rename_newat __wasilibc_rename_oldat +__wasilibc_reset_preopens __wasilibc_rmdirat __wasilibc_stat __wasilibc_tell @@ -713,6 +714,11 @@ ftello64 ftime ftruncate ftrylockfile +fts_children +fts_close +fts_open +fts_read +fts_set funlockfile futimens futimesat @@ -927,6 +933,7 @@ mmap modf modff modfl +mprotect mrand48 munmap nan @@ -984,18 +991,23 @@ psignal pthread_attr_destroy pthread_attr_getdetachstate pthread_attr_getguardsize -pthread_attr_getinheritsched -pthread_attr_getscope +pthread_attr_getschedparam pthread_attr_getstack pthread_attr_getstacksize pthread_attr_init pthread_attr_setdetachstate +pthread_attr_setguardsize +pthread_attr_setschedparam pthread_attr_setstack pthread_attr_setstacksize pthread_barrier_destroy pthread_barrier_init pthread_barrier_wait +pthread_barrierattr_destroy pthread_barrierattr_getpshared +pthread_barrierattr_init +pthread_barrierattr_setpshared +pthread_cancel pthread_cond_broadcast pthread_cond_destroy pthread_cond_init @@ -1003,6 +1015,7 @@ pthread_cond_signal pthread_cond_timedwait pthread_cond_wait pthread_condattr_destroy +pthread_condattr_getclock pthread_condattr_getpshared pthread_condattr_init pthread_condattr_setclock @@ -1049,6 +1062,7 @@ pthread_rwlockattr_init pthread_rwlockattr_setpshared pthread_self pthread_setcancelstate +pthread_setcanceltype pthread_setspecific pthread_spin_destroy pthread_spin_init diff --git a/expected/wasm64-wasip1-threads/include-all.c b/expected/wasm64-wasip1-threads/include-all.c index 507337430..3fb02ee77 100644 --- a/expected/wasm64-wasip1-threads/include-all.c +++ b/expected/wasm64-wasip1-threads/include-all.c @@ -86,6 +86,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasip1-threads/predefined-macros.txt b/expected/wasm64-wasip1-threads/predefined-macros.txt index 64e6fa7f1..e22bcad8e 100644 --- a/expected/wasm64-wasip1-threads/predefined-macros.txt +++ b/expected/wasm64-wasip1-threads/predefined-macros.txt @@ -384,6 +384,40 @@ #define FSETLOCKING_BYCALLER 2 #define FSETLOCKING_INTERNAL 1 #define FSETLOCKING_QUERY 0 +#define FTS_AGAIN 1 +#define FTS_COMFOLLOW 0x001 +#define FTS_D 1 +#define FTS_DC 2 +#define FTS_DEFAULT 3 +#define FTS_DNR 4 +#define FTS_DONTCHDIR 0x01 +#define FTS_DOT 5 +#define FTS_DP 6 +#define FTS_ERR 7 +#define FTS_F 8 +#define FTS_FOLLOW 2 +#define FTS_INIT 9 +#define FTS_ISW 0x04 +#define FTS_LOGICAL 0x002 +#define FTS_NAMEONLY 0x100 +#define FTS_NOCHDIR 0x004 +#define FTS_NOINSTR 3 +#define FTS_NOSTAT 0x008 +#define FTS_NS 10 +#define FTS_NSOK 11 +#define FTS_OPTIONMASK 0x0ff +#define FTS_PHYSICAL 0x010 +#define FTS_ROOTLEVEL 0 +#define FTS_ROOTPARENTLEVEL -1 +#define FTS_SEEDOT 0x020 +#define FTS_SKIP 4 +#define FTS_SL 12 +#define FTS_SLNONE 13 +#define FTS_STOP 0x200 +#define FTS_SYMFOLLOW 0x02 +#define FTS_W 14 +#define FTS_WHITEOUT 0x080 +#define FTS_XDEV 0x040 #define FTW_CHDIR 4 #define FTW_D 2 #define FTW_DEPTH 8 @@ -2075,6 +2109,7 @@ #define _FLOAT_H #define _FMTMSG_H #define _FNMATCH_H +#define _FTS_H_ #define _FTW_H #define _GETOPT_H #define _GLOB_H @@ -2182,12 +2217,9 @@ #define _POSIX_SYMLINK_MAX 255 #define _POSIX_SYMLOOP_MAX 8 #define _POSIX_THREADS _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION #define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION -#define _POSIX_THREAD_CPUTIME _POSIX_VERSION #define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 #define _POSIX_THREAD_KEYS_MAX 128 -#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION #define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION #define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION #define _POSIX_THREAD_THREADS_MAX 64 @@ -3035,6 +3067,13 @@ #define __alignof_is_defined 1 #define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) #define __bool_true_false_are_defined 1 +#define __fts_dev_t dev_t +#define __fts_ino_t ino_t +#define __fts_length_t unsigned int +#define __fts_level_t int +#define __fts_nlink_t nlink_t +#define __fts_number_t int64_t +#define __fts_stat_t struct stat #define __inline inline #define __restrict restrict #define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) diff --git a/expected/wasm64-wasip1-threads/undefined-symbols.txt b/expected/wasm64-wasip1-threads/undefined-symbols.txt index 938e64776..838c4f711 100644 --- a/expected/wasm64-wasip1-threads/undefined-symbols.txt +++ b/expected/wasm64-wasip1-threads/undefined-symbols.txt @@ -67,7 +67,6 @@ __netf2 __stack_pointer __subtf3 __tls_align -__tls_base __tls_size __trunctfdf2 __trunctfsf2 diff --git a/expected/wasm64-wasip1/defined-symbols.txt b/expected/wasm64-wasip1/defined-symbols.txt index 13c10d7b5..6e06d64ff 100644 --- a/expected/wasm64-wasip1/defined-symbols.txt +++ b/expected/wasm64-wasip1/defined-symbols.txt @@ -11,6 +11,7 @@ __EINVAL __ENOMEM __SIG_ERR __SIG_IGN +__acquire_ptc __asctime_r __assert_fail __c_dot_utf8 @@ -34,7 +35,11 @@ __ctype_tolower_loc __ctype_toupper_loc __cxa_atexit __cxa_finalize +__default_guardsize +__default_stacksize __des_setkey +__do_cleanup_pop +__do_cleanup_push __do_des __duplocale __env_rm_add @@ -175,10 +180,34 @@ __pow_log_data __powf_log2_data __progname __progname_full +__pthread_cond_timedwait +__pthread_create +__pthread_detach +__pthread_join +__pthread_key_create +__pthread_key_delete +__pthread_mutex_consistent +__pthread_mutex_lock +__pthread_mutex_timedlock +__pthread_mutex_trylock +__pthread_mutex_unlock +__pthread_rwlock_rdlock +__pthread_rwlock_timedrdlock +__pthread_rwlock_timedwrlock +__pthread_rwlock_tryrdlock +__pthread_rwlock_trywrlock +__pthread_rwlock_unlock +__pthread_rwlock_wrlock +__pthread_setcancelstate +__pthread_testcancel +__pthread_tsd_main +__pthread_tsd_run_dtors +__pthread_tsd_size __putenv __qsort_r __rand48_step __reallocarray +__release_ptc __rem_pio2 __rem_pio2_large __rem_pio2f @@ -234,6 +263,9 @@ __sysv_signal __tan __tandf __tanl +__testcancel +__tl_lock +__tl_unlock __tm_to_secs __tm_to_tzname __tolower_l @@ -330,9 +362,11 @@ __wasilibc_nocwd_symlinkat __wasilibc_nocwd_utimensat __wasilibc_open_nomode __wasilibc_populate_preopens +__wasilibc_pthread_self __wasilibc_register_preopened_fd __wasilibc_rename_newat __wasilibc_rename_oldat +__wasilibc_reset_preopens __wasilibc_rmdirat __wasilibc_stat __wasilibc_tell @@ -351,6 +385,8 @@ _environ _exit _flushlbf _initialize +_pthread_cleanup_pop +_pthread_cleanup_push _start a64l abort @@ -647,6 +683,11 @@ ftello ftello64 ftime ftruncate +fts_children +fts_close +fts_open +fts_read +fts_set futimens futimesat fwide @@ -860,6 +901,7 @@ mmap modf modff modfl +mprotect mrand48 munmap nan @@ -914,6 +956,89 @@ program_invocation_name program_invocation_short_name pselect psignal +pthread_attr_destroy +pthread_attr_getdetachstate +pthread_attr_getguardsize +pthread_attr_getschedparam +pthread_attr_getstack +pthread_attr_getstacksize +pthread_attr_init +pthread_attr_setdetachstate +pthread_attr_setguardsize +pthread_attr_setschedparam +pthread_attr_setstack +pthread_attr_setstacksize +pthread_barrier_destroy +pthread_barrier_init +pthread_barrier_wait +pthread_barrierattr_destroy +pthread_barrierattr_getpshared +pthread_barrierattr_init +pthread_barrierattr_setpshared +pthread_cancel +pthread_cond_broadcast +pthread_cond_destroy +pthread_cond_init +pthread_cond_signal +pthread_cond_timedwait +pthread_cond_wait +pthread_condattr_destroy +pthread_condattr_getclock +pthread_condattr_getpshared +pthread_condattr_init +pthread_condattr_setclock +pthread_condattr_setpshared +pthread_create +pthread_detach +pthread_equal +pthread_exit +pthread_getspecific +pthread_join +pthread_key_create +pthread_key_delete +pthread_mutex_consistent +pthread_mutex_destroy +pthread_mutex_init +pthread_mutex_lock +pthread_mutex_timedlock +pthread_mutex_trylock +pthread_mutex_unlock +pthread_mutexattr_destroy +pthread_mutexattr_getprotocol +pthread_mutexattr_getpshared +pthread_mutexattr_getrobust +pthread_mutexattr_gettype +pthread_mutexattr_init +pthread_mutexattr_setprotocol +pthread_mutexattr_setpshared +pthread_mutexattr_setrobust +pthread_mutexattr_settype +pthread_once +pthread_rwlock_destroy +pthread_rwlock_init +pthread_rwlock_rdlock +pthread_rwlock_timedrdlock +pthread_rwlock_timedwrlock +pthread_rwlock_tryrdlock +pthread_rwlock_trywrlock +pthread_rwlock_unlock +pthread_rwlock_wrlock +pthread_rwlockattr_destroy +pthread_rwlockattr_getpshared +pthread_rwlockattr_init +pthread_rwlockattr_setpshared +pthread_self +pthread_setcancelstate +pthread_setcanceltype +pthread_setspecific +pthread_spin_destroy +pthread_spin_init +pthread_spin_lock +pthread_spin_trylock +pthread_spin_unlock +pthread_testcancel +pthread_timedjoin_np +pthread_tryjoin_np putc putc_unlocked putchar @@ -1095,6 +1220,8 @@ tfind tgamma tgammaf tgammal +thrd_current +thrd_equal thrd_sleep time timegm @@ -1116,6 +1243,7 @@ truncate truncf truncl tsearch +tss_get twalk uname ungetc diff --git a/expected/wasm64-wasip1/include-all.c b/expected/wasm64-wasip1/include-all.c index cd3b81720..3fb02ee77 100644 --- a/expected/wasm64-wasip1/include-all.c +++ b/expected/wasm64-wasip1/include-all.c @@ -86,6 +86,7 @@ #include #include #include +#include #include #include #include @@ -114,6 +115,7 @@ #include #include #include +#include #include #include #include diff --git a/expected/wasm64-wasip1/predefined-macros.txt b/expected/wasm64-wasip1/predefined-macros.txt index 901aa0c9b..514907b27 100644 --- a/expected/wasm64-wasip1/predefined-macros.txt +++ b/expected/wasm64-wasip1/predefined-macros.txt @@ -384,6 +384,40 @@ #define FSETLOCKING_BYCALLER 2 #define FSETLOCKING_INTERNAL 1 #define FSETLOCKING_QUERY 0 +#define FTS_AGAIN 1 +#define FTS_COMFOLLOW 0x001 +#define FTS_D 1 +#define FTS_DC 2 +#define FTS_DEFAULT 3 +#define FTS_DNR 4 +#define FTS_DONTCHDIR 0x01 +#define FTS_DOT 5 +#define FTS_DP 6 +#define FTS_ERR 7 +#define FTS_F 8 +#define FTS_FOLLOW 2 +#define FTS_INIT 9 +#define FTS_ISW 0x04 +#define FTS_LOGICAL 0x002 +#define FTS_NAMEONLY 0x100 +#define FTS_NOCHDIR 0x004 +#define FTS_NOINSTR 3 +#define FTS_NOSTAT 0x008 +#define FTS_NS 10 +#define FTS_NSOK 11 +#define FTS_OPTIONMASK 0x0ff +#define FTS_PHYSICAL 0x010 +#define FTS_ROOTLEVEL 0 +#define FTS_ROOTPARENTLEVEL -1 +#define FTS_SEEDOT 0x020 +#define FTS_SKIP 4 +#define FTS_SL 12 +#define FTS_SLNONE 13 +#define FTS_STOP 0x200 +#define FTS_SYMFOLLOW 0x02 +#define FTS_W 14 +#define FTS_WHITEOUT 0x080 +#define FTS_XDEV 0x040 #define FTW_CHDIR 4 #define FTW_D 2 #define FTW_DEPTH 8 @@ -1419,6 +1453,38 @@ #define PRIxLEAST8 __UINT_LEAST8_FMTx__ #define PRIxMAX __UINTMAX_FMTx__ #define PRIxPTR __UINTPTR_FMTx__ +#define PTHREAD_BARRIER_SERIAL_THREAD (-1) +#define PTHREAD_CANCELED ((void *)-1) +#define PTHREAD_CANCEL_ASYNCHRONOUS 1 +#define PTHREAD_CANCEL_DEFERRED 0 +#define PTHREAD_CANCEL_DISABLE 1 +#define PTHREAD_CANCEL_ENABLE 0 +#define PTHREAD_CANCEL_MASKED 2 +#define PTHREAD_COND_INITIALIZER {{{0}}} +#define PTHREAD_CREATE_DETACHED 1 +#define PTHREAD_CREATE_JOINABLE 0 +#define PTHREAD_DESTRUCTOR_ITERATIONS 4 +#define PTHREAD_EXPLICIT_SCHED 1 +#define PTHREAD_INHERIT_SCHED 0 +#define PTHREAD_KEYS_MAX 128 +#define PTHREAD_MUTEX_DEFAULT 0 +#define PTHREAD_MUTEX_ERRORCHECK 2 +#define PTHREAD_MUTEX_INITIALIZER {{{0}}} +#define PTHREAD_MUTEX_NORMAL 0 +#define PTHREAD_MUTEX_RECURSIVE 1 +#define PTHREAD_MUTEX_ROBUST 1 +#define PTHREAD_MUTEX_STALLED 0 +#define PTHREAD_NULL ((pthread_t)0) +#define PTHREAD_ONCE_INIT 0 +#define PTHREAD_PRIO_INHERIT 1 +#define PTHREAD_PRIO_NONE 0 +#define PTHREAD_PRIO_PROTECT 2 +#define PTHREAD_PROCESS_PRIVATE 0 +#define PTHREAD_PROCESS_SHARED 1 +#define PTHREAD_RWLOCK_INITIALIZER {{{0}}} +#define PTHREAD_SCOPE_PROCESS 1 +#define PTHREAD_SCOPE_SYSTEM 0 +#define PTHREAD_STACK_MIN 2048 #define PTRBITS (sizeof(char *) * 8) #define PTRDIFF_MAX INT64_MAX #define PTRDIFF_MIN INT64_MIN @@ -2041,6 +2107,7 @@ #define _FLOAT_H #define _FMTMSG_H #define _FNMATCH_H +#define _FTS_H_ #define _FTW_H #define _GETOPT_H #define _GLOB_H @@ -2147,14 +2214,8 @@ #define _POSIX_STREAM_MAX 8 #define _POSIX_SYMLINK_MAX 255 #define _POSIX_SYMLOOP_MAX 8 -#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION -#define _POSIX_THREAD_CPUTIME _POSIX_VERSION #define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 #define _POSIX_THREAD_KEYS_MAX 128 -#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION -#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION -#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION #define _POSIX_THREAD_THREADS_MAX 64 #define _POSIX_TIMEOUTS _POSIX_VERSION #define _POSIX_TIMERS _POSIX_VERSION @@ -2169,6 +2230,7 @@ #define _POSIX_V7_ILP32_OFFBIG (1) #define _POSIX_VDISABLE 0 #define _POSIX_VERSION 200809L +#define _PTHREAD_H #define _PTRDIFF_T #define _REGEX_H #define _SCHED_H @@ -2357,6 +2419,7 @@ #define _UTIME_H #define _VALUES_H #define _VA_LIST +#define _WASI_EMULATED_PTHREAD #define _WCHAR_H #define _WCHAR_T #define _WCTYPE_H @@ -2998,6 +3061,13 @@ #define __alignof_is_defined 1 #define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) #define __bool_true_false_are_defined 1 +#define __fts_dev_t dev_t +#define __fts_ino_t ino_t +#define __fts_length_t unsigned int +#define __fts_level_t int +#define __fts_nlink_t nlink_t +#define __fts_number_t int64_t +#define __fts_stat_t struct stat #define __inline inline #define __restrict restrict #define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) @@ -3319,6 +3389,9 @@ #define powerof2(n) !(((n)-1) & (n)) #define pread64 pread #define preadv64 preadv +#define pthread_cleanup_pop(r) _pthread_cleanup_pop(&__cb, (r)); } while(0) +#define pthread_cleanup_push(f,x) do { struct __ptcb __cb; _pthread_cleanup_push(&__cb, f, x); +#define pthread_equal(x,y) ((x)==(y)) #define pwrite64 pwrite #define pwritev64 pwritev #define readdir64 readdir diff --git a/expected/wasm64-wasip2/defined-symbols.txt b/expected/wasm64-wasip2/defined-symbols.txt deleted file mode 100644 index 6e743228b..000000000 --- a/expected/wasm64-wasip2/defined-symbols.txt +++ /dev/null @@ -1,1206 +0,0 @@ -_CLOCK_MONOTONIC -_CLOCK_REALTIME -_Exit -_IO_feof_unlocked -_IO_ferror_unlocked -_IO_getc -_IO_getc_unlocked -_IO_putc -_IO_putc_unlocked -__EINVAL -__ENOMEM -__SIG_ERR -__SIG_IGN -__asctime_r -__assert_fail -__c_dot_utf8 -__c_dot_utf8_locale -__c_locale -__clock -__clock_gettime -__clock_nanosleep -__cos -__cosdf -__cosl -__crypt_blowfish -__crypt_des -__crypt_md5 -__crypt_r -__crypt_sha256 -__crypt_sha512 -__ctype_b_loc -__ctype_get_mb_cur_max -__ctype_tolower_loc -__ctype_toupper_loc -__cxa_atexit -__cxa_finalize -__des_setkey -__do_des -__duplocale -__env_rm_add -__errno_location -__exp2f_data -__exp_data -__expo2 -__expo2f -__fbufsize -__fclose_ca -__fdopen -__fesetround -__fgetwc_unlocked -__flbf -__floatscan -__fmodeflags -__fopen_rb_ca -__fpending -__fpurge -__fputwc_unlocked -__freadable -__freadahead -__freading -__freadptr -__freadptrinc -__freelocale -__fseeko -__fseeko_unlocked -__fseterr -__fsetlocking -__fsmu8 -__ftello -__ftello_unlocked -__funcs_on_exit -__funcs_on_quick_exit -__futimesat -__fwritable -__fwritex -__fwriting -__get_locale -__getdelim -__getentropy -__getopt_msg -__gmtime_r -__hwcap -__inet_aton -__init_ssp -__intscan -__invtrigl_R -__isalnum_l -__isalpha_l -__isatty -__isblank_l -__iscntrl_l -__isdigit_l -__isgraph_l -__islower_l -__isoc99_fscanf -__isoc99_fwscanf -__isoc99_scanf -__isoc99_sscanf -__isoc99_swscanf -__isoc99_vfscanf -__isoc99_vfwscanf -__isoc99_vscanf -__isoc99_vsscanf -__isoc99_vswscanf -__isoc99_vwscanf -__isoc99_wscanf -__isprint_l -__ispunct_l -__isspace_l -__isupper_l -__iswalnum_l -__iswalpha_l -__iswblank_l -__iswcntrl_l -__iswctype_l -__iswdigit_l -__iswgraph_l -__iswlower_l -__iswprint_l -__iswpunct_l -__iswspace_l -__iswupper_l -__iswxdigit_l -__isxdigit_l -__lctrans -__lctrans_cur -__lctrans_impl -__ldexp_cexp -__ldexp_cexpf -__lgamma_r -__lgammaf_r -__lgammal_r -__libc -__libc_calloc -__libc_free -__libc_malloc -__loc_is_allocated -__localtime_r -__log2_data -__log2f_data -__log_data -__logf_data -__lseek -__main_void -__math_divzero -__math_divzerof -__math_invalid -__math_invalidf -__math_invalidl -__math_oflow -__math_oflowf -__math_uflow -__math_uflowf -__math_xflow -__math_xflowf -__memrchr -__mo_lookup -__month_to_secs -__newlocale -__nl_langinfo -__nl_langinfo_l -__ofl_add -__ofl_lock -__ofl_unlock -__optpos -__optreset -__overflow -__p1evll -__pio2_hi -__pio2_lo -__pleval -__polevll -__posix_getopt -__pow_log_data -__powf_log2_data -__progname -__progname_full -__putenv -__qsort_r -__rand48_step -__reallocarray -__rem_pio2 -__rem_pio2_large -__rem_pio2f -__rem_pio2l -__rsqrt_tab -__secs_to_tm -__secs_to_zone -__seed48 -__shgetc -__shlim -__signgam -__sin -__sindf -__sinl -__small_printf -__stack_chk_fail -__stack_chk_fail_local -__stack_chk_guard -__stderr_FILE -__stderr_used -__stdin_FILE -__stdin_used -__stdio_close -__stdio_exit -__stdio_exit_needed -__stdio_read -__stdio_seek -__stdio_write -__stdout_FILE -__stdout_used -__stdout_write -__stpcpy -__stpncpy -__strcasecmp_l -__strchrnul -__strcoll_l -__strerror_l -__strftime_fmt_1 -__strftime_l -__strncasecmp_l -__strtod_l -__strtof_l -__strtoimax_internal -__strtol_internal -__strtold_l -__strtoll_internal -__strtoul_internal -__strtoull_internal -__strtoumax_internal -__strxfrm_l -__sysinfo -__sysv_signal -__tan -__tandf -__tanl -__tm_to_secs -__tm_to_tzname -__tolower_l -__toread -__toread_needs_stdio_exit -__toupper_l -__towctrans_l -__towlower_l -__towrite -__towrite_needs_stdio_exit -__towupper_l -__tre_mem_alloc_impl -__tre_mem_destroy -__tre_mem_new_impl -__tsearch_balance -__uflow -__unlist_locked_file -__uselocale -__utc -__wasi_args_get -__wasi_args_sizes_get -__wasi_clock_res_get -__wasi_clock_time_get -__wasi_environ_get -__wasi_environ_sizes_get -__wasi_fd_advise -__wasi_fd_allocate -__wasi_fd_close -__wasi_fd_datasync -__wasi_fd_fdstat_get -__wasi_fd_fdstat_set_flags -__wasi_fd_fdstat_set_rights -__wasi_fd_filestat_get -__wasi_fd_filestat_set_size -__wasi_fd_filestat_set_times -__wasi_fd_pread -__wasi_fd_prestat_dir_name -__wasi_fd_prestat_get -__wasi_fd_pwrite -__wasi_fd_read -__wasi_fd_readdir -__wasi_fd_renumber -__wasi_fd_seek -__wasi_fd_sync -__wasi_fd_tell -__wasi_fd_write -__wasi_path_create_directory -__wasi_path_filestat_get -__wasi_path_filestat_set_times -__wasi_path_link -__wasi_path_open -__wasi_path_readlink -__wasi_path_remove_directory -__wasi_path_rename -__wasi_path_symlink -__wasi_path_unlink_file -__wasi_poll_oneoff -__wasi_proc_exit -__wasi_random_get -__wasi_sched_yield -__wasi_sock_accept -__wasi_sock_recv -__wasi_sock_send -__wasi_sock_shutdown -__wasilibc_access -__wasilibc_cwd -__wasilibc_deinitialize_environ -__wasilibc_dttoif -__wasilibc_ensure_environ -__wasilibc_environ -__wasilibc_fd_renumber -__wasilibc_find_abspath -__wasilibc_find_relpath -__wasilibc_find_relpath_alloc -__wasilibc_get_environ -__wasilibc_iftodt -__wasilibc_initialize_environ -__wasilibc_link -__wasilibc_link_newat -__wasilibc_link_oldat -__wasilibc_maybe_reinitialize_environ_eagerly -__wasilibc_nocwd___wasilibc_rmdirat -__wasilibc_nocwd___wasilibc_unlinkat -__wasilibc_nocwd_faccessat -__wasilibc_nocwd_fstatat -__wasilibc_nocwd_linkat -__wasilibc_nocwd_mkdirat_nomode -__wasilibc_nocwd_openat_nomode -__wasilibc_nocwd_opendirat -__wasilibc_nocwd_readlinkat -__wasilibc_nocwd_renameat -__wasilibc_nocwd_scandirat -__wasilibc_nocwd_symlinkat -__wasilibc_nocwd_utimensat -__wasilibc_open_nomode -__wasilibc_populate_preopens -__wasilibc_register_preopened_fd -__wasilibc_rename_newat -__wasilibc_rename_oldat -__wasilibc_rmdirat -__wasilibc_stat -__wasilibc_tell -__wasilibc_unlinkat -__wasilibc_utimens -__wasm_call_dtors -__wcscoll_l -__wcsftime_l -__wcsxfrm_l -__wctrans_l -__wctype_l -__xpg_basename -__xpg_strerror_r -__year_to_secs -_environ -_exit -_flushlbf -_initialize -_start -a64l -abort -abs -accept -accept4 -access -acos -acosf -acosh -acoshf -acoshl -acosl -aligned_alloc -alphasort -alphasort64 -arc4random -arc4random_buf -arc4random_uniform -asctime -asctime_r -asin -asinf -asinh -asinhf -asinhl -asinl -asprintf -at_quick_exit -atan -atan2 -atan2f -atan2l -atanf -atanh -atanhf -atanhl -atanl -atexit -atof -atoi -atol -atoll -basename -bcmp -bcopy -bsd_signal -bsearch -btowc -bzero -c16rtomb -c32rtomb -cabs -cabsf -cabsl -cacos -cacosf -cacosh -cacoshf -cacoshl -cacosl -calloc -carg -cargf -cargl -casin -casinf -casinh -casinhf -casinhl -casinl -catan -catanf -catanh -catanhf -catanhl -catanl -catclose -catgets -catopen -cbrt -cbrtf -cbrtl -ccos -ccosf -ccosh -ccoshf -ccoshl -ccosl -ceil -ceilf -ceill -cexp -cexpf -cexpl -chdir -cimag -cimagf -cimagl -clearenv -clearerr -clearerr_unlocked -clock -clock_getres -clock_gettime -clock_nanosleep -clog -clogf -clogl -close -closedir -confstr -conj -conjf -conjl -copysign -copysignf -copysignl -cos -cosf -cosh -coshf -coshl -cosl -cpow -cpowf -cpowl -cproj -cprojf -cprojl -creal -crealf -creall -creat -creat64 -crypt -crypt_r -csin -csinf -csinh -csinhf -csinhl -csinl -csqrt -csqrtf -csqrtl -ctan -ctanf -ctanh -ctanhf -ctanhl -ctanl -ctime -ctime_r -difftime -dirfd -dirname -div -dprintf -drand48 -drem -dremf -duplocale -ecvt -encrypt -environ -erand48 -erf -erfc -erfcf -erfcl -erff -erfl -errno -exit -exp -exp10 -exp10f -exp10l -exp2 -exp2f -exp2l -expf -expl -explicit_bzero -expm1 -expm1f -expm1l -fabs -fabsf -fabsl -faccessat -fclose -fcntl -fcvt -fdatasync -fdclosedir -fdim -fdimf -fdiml -fdopen -fdopendir -feclearexcept -fegetenv -fegetexceptflag -fegetround -feholdexcept -feof -feof_unlocked -feraiseexcept -ferror -ferror_unlocked -fesetenv -fesetexceptflag -fesetround -fetestexcept -feupdateenv -fflush -fflush_unlocked -ffs -ffsl -ffsll -fgetc -fgetc_unlocked -fgetln -fgetpos -fgetpos64 -fgets -fgets_unlocked -fgetwc -fgetwc_unlocked -fgetws -fgetws_unlocked -fileno -fileno_unlocked -finite -finitef -floor -floorf -floorl -fma -fmaf -fmal -fmax -fmaxf -fmaxl -fmemopen -fmin -fminf -fminl -fmod -fmodf -fmodl -fmtmsg -fnmatch -fopen -fopen64 -fopencookie -fpathconf -fprintf -fpurge -fputc -fputc_unlocked -fputs -fputs_unlocked -fputwc -fputwc_unlocked -fputws -fputws_unlocked -fread -fread_unlocked -free -freelocale -freopen -freopen64 -frexp -frexpf -frexpl -fscanf -fseek -fseeko -fseeko64 -fsetpos -fsetpos64 -fstat -fstatat -fsync -ftell -ftello -ftello64 -ftime -ftruncate -futimens -futimesat -fwide -fwprintf -fwrite -fwrite_unlocked -fwscanf -gcvt -get_avphys_pages -get_nprocs -get_nprocs_conf -get_phys_pages -getc -getc_unlocked -getchar -getchar_unlocked -getcwd -getdate -getdate_err -getdelim -getdomainname -getentropy -getenv -gethostid -getline -getopt -getopt_long -getopt_long_only -getpagesize -getpid -getrusage -getsockopt -getsubopt -gettimeofday -getw -getwc -getwc_unlocked -getwchar -getwchar_unlocked -glob -glob64 -globfree -globfree64 -gmtime -gmtime_r -hcreate -hcreate_r -hdestroy -hdestroy_r -hsearch -hsearch_r -htonl -htons -hypot -hypotf -hypotl -iconv -iconv_close -iconv_open -ilogb -ilogbf -ilogbl -imaxabs -imaxdiv -in6addr_any -in6addr_loopback -index -inet_aton -inet_ntop -inet_pton -initstate -insque -ioctl -iprintf -isalnum -isalnum_l -isalpha -isalpha_l -isascii -isatty -isblank -isblank_l -iscntrl -iscntrl_l -isdigit -isdigit_l -isgraph -isgraph_l -islower -islower_l -isprint -isprint_l -ispunct -ispunct_l -isspace -isspace_l -isupper -isupper_l -iswalnum -iswalnum_l -iswalpha -iswalpha_l -iswblank -iswblank_l -iswcntrl -iswcntrl_l -iswctype -iswctype_l -iswdigit -iswdigit_l -iswgraph -iswgraph_l -iswlower -iswlower_l -iswprint -iswprint_l -iswpunct -iswpunct_l -iswspace -iswspace_l -iswupper -iswupper_l -iswxdigit -iswxdigit_l -isxdigit -isxdigit_l -j0 -j0f -j1 -j1f -jn -jnf -jrand48 -l64a -labs -lcong48 -ldexp -ldexpf -ldexpl -ldiv -lfind -lgamma -lgamma_r -lgammaf -lgammaf_r -lgammal -lgammal_r -link -linkat -llabs -lldiv -llrint -llrintf -llrintl -llround -llroundf -llroundl -localeconv -localtime -localtime_r -log -log10 -log10f -log10l -log1p -log1pf -log1pl -log2 -log2f -log2l -logb -logbf -logbl -logf -logl -lrand48 -lrint -lrintf -lrintl -lround -lroundf -lroundl -lsearch -lseek -lstat -malloc -malloc_usable_size -mblen -mbrlen -mbrtoc16 -mbrtoc32 -mbrtowc -mbsinit -mbsnrtowcs -mbsrtowcs -mbstowcs -mbtowc -memccpy -memchr -memcmp -memcpy -memmem -memmove -mempcpy -memrchr -memset -mkdir -mkdirat -mktime -mmap -modf -modff -modfl -mrand48 -munmap -nan -nanf -nanl -nanosleep -nearbyint -nearbyintf -nearbyintl -newlocale -nextafter -nextafterf -nextafterl -nexttoward -nexttowardf -nexttowardl -nftw -nftw64 -nl_langinfo -nl_langinfo_l -nrand48 -ntohl -ntohs -open -open_memstream -open_wmemstream -openat -opendir -opendirat -optarg -opterr -optind -optopt -optreset -pathconf -perror -poll -posix_close -posix_fadvise -posix_fallocate -posix_memalign -pow -pow10 -pow10f -pow10l -powf -powl -pread -preadv -printf -program_invocation_name -program_invocation_short_name -pselect -psignal -putc -putc_unlocked -putchar -putchar_unlocked -putenv -puts -putw -putwc -putwc_unlocked -putwchar -putwchar_unlocked -pwrite -pwritev -qsort -qsort_r -quick_exit -raise -rand -rand_r -random -read -readdir -readlink -readlinkat -readv -realloc -reallocarray -recv -regcomp -regerror -regexec -regfree -remainder -remainderf -remainderl -remove -remque -remquo -remquof -remquol -rename -renameat -rewind -rewinddir -rindex -rint -rintf -rintl -rmdir -round -roundf -roundl -sbrk -scalb -scalbf -scalbln -scalblnf -scalblnl -scalbn -scalbnf -scalbnl -scandir -scandirat -scanf -sched_yield -seed48 -seekdir -select -send -setbuf -setbuffer -setenv -setkey -setlinebuf -setlocale -setstate -setvbuf -shutdown -signal -signgam -significand -significandf -sin -sincos -sincosf -sincosl -sinf -sinh -sinhf -sinhl -sinl -sleep -snprintf -sprintf -sqrt -sqrtf -sqrtl -srand -srand48 -srandom -sscanf -stat -stderr -stdin -stdout -stpcpy -stpncpy -strcasecmp -strcasecmp_l -strcasestr -strcat -strchr -strchrnul -strcmp -strcoll -strcoll_l -strcpy -strcspn -strdup -strerror -strerror_l -strerror_r -strfmon -strfmon_l -strftime -strftime_l -strlcat -strlcpy -strlen -strncasecmp -strncasecmp_l -strncat -strncmp -strncpy -strndup -strnlen -strpbrk -strptime -strrchr -strsep -strsignal -strspn -strstr -strtod -strtod_l -strtof -strtof_l -strtoimax -strtok -strtok_r -strtol -strtold -strtold_l -strtoll -strtoul -strtoull -strtoumax -strverscmp -strxfrm -strxfrm_l -swab -swprintf -swscanf -symlink -symlinkat -sysconf -tan -tanf -tanh -tanhf -tanhl -tanl -tdelete -tdestroy -telldir -tfind -tgamma -tgammaf -tgammal -thrd_sleep -time -timegm -times -timespec_get -toascii -tolower -tolower_l -toupper -toupper_l -towctrans -towctrans_l -towlower -towlower_l -towupper -towupper_l -trunc -truncate -truncf -truncl -tsearch -twalk -uname -ungetc -ungetwc -unlink -unlinkat -unsetenv -uselocale -usleep -utime -utimensat -utimes -vasprintf -vdprintf -versionsort -versionsort64 -vfprintf -vfscanf -vfwprintf -vfwscanf -vprintf -vscanf -vsnprintf -vsprintf -vsscanf -vswprintf -vswscanf -vwprintf -vwscanf -wcpcpy -wcpncpy -wcrtomb -wcscasecmp -wcscasecmp_l -wcscat -wcschr -wcscmp -wcscoll -wcscoll_l -wcscpy -wcscspn -wcsdup -wcsftime -wcsftime_l -wcslen -wcsncasecmp -wcsncasecmp_l -wcsncat -wcsncmp -wcsncpy -wcsnlen -wcsnrtombs -wcspbrk -wcsrchr -wcsrtombs -wcsspn -wcsstr -wcstod -wcstof -wcstoimax -wcstok -wcstol -wcstold -wcstoll -wcstombs -wcstoul -wcstoull -wcstoumax -wcswcs -wcswidth -wcsxfrm -wcsxfrm_l -wctob -wctomb -wctrans -wctrans_l -wctype -wctype_l -wcwidth -wmemchr -wmemcmp -wmemcpy -wmemmove -wmemset -wprintf -write -writev -wscanf -y0 -y0f -y1 -y1f -yn -ynf diff --git a/expected/wasm64-wasip2/include-all.c b/expected/wasm64-wasip2/include-all.c deleted file mode 100644 index 297e48b14..000000000 --- a/expected/wasm64-wasip2/include-all.c +++ /dev/null @@ -1,171 +0,0 @@ -#include <__errno.h> -#include <__errno_values.h> -#include <__fd_set.h> -#include <__function___isatty.h> -#include <__functions_malloc.h> -#include <__functions_memcpy.h> -#include <__header_dirent.h> -#include <__header_fcntl.h> -#include <__header_inttypes.h> -#include <__header_netinet_in.h> -#include <__header_poll.h> -#include <__header_stdlib.h> -#include <__header_string.h> -#include <__header_sys_ioctl.h> -#include <__header_sys_resource.h> -#include <__header_sys_socket.h> -#include <__header_sys_stat.h> -#include <__header_time.h> -#include <__header_unistd.h> -#include <__macro_FD_SETSIZE.h> -#include <__macro_PAGESIZE.h> -#include <__mode_t.h> -#include <__seek.h> -#include <__struct_dirent.h> -#include <__struct_in6_addr.h> -#include <__struct_in_addr.h> -#include <__struct_iovec.h> -#include <__struct_msghdr.h> -#include <__struct_pollfd.h> -#include <__struct_rusage.h> -#include <__struct_sockaddr.h> -#include <__struct_sockaddr_in.h> -#include <__struct_sockaddr_in6.h> -#include <__struct_sockaddr_storage.h> -#include <__struct_sockaddr_un.h> -#include <__struct_stat.h> -#include <__struct_timespec.h> -#include <__struct_timeval.h> -#include <__struct_tm.h> -#include <__struct_tms.h> -#include <__typedef_DIR.h> -#include <__typedef_blkcnt_t.h> -#include <__typedef_blksize_t.h> -#include <__typedef_clock_t.h> -#include <__typedef_clockid_t.h> -#include <__typedef_dev_t.h> -#include <__typedef_fd_set.h> -#include <__typedef_gid_t.h> -#include <__typedef_in_addr_t.h> -#include <__typedef_in_port_t.h> -#include <__typedef_ino_t.h> -#include <__typedef_mode_t.h> -#include <__typedef_nfds_t.h> -#include <__typedef_nlink_t.h> -#include <__typedef_off_t.h> -#include <__typedef_sa_family_t.h> -#include <__typedef_sigset_t.h> -#include <__typedef_socklen_t.h> -#include <__typedef_ssize_t.h> -#include <__typedef_suseconds_t.h> -#include <__typedef_time_t.h> -#include <__typedef_uid_t.h> -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include diff --git a/expected/wasm64-wasip2/predefined-macros.txt b/expected/wasm64-wasip2/predefined-macros.txt deleted file mode 100644 index dec1ead06..000000000 --- a/expected/wasm64-wasip2/predefined-macros.txt +++ /dev/null @@ -1,3365 +0,0 @@ -#define ABDAY_1 0x20000 -#define ABDAY_2 0x20001 -#define ABDAY_3 0x20002 -#define ABDAY_4 0x20003 -#define ABDAY_5 0x20004 -#define ABDAY_6 0x20005 -#define ABDAY_7 0x20006 -#define ABMON_1 0x2000E -#define ABMON_10 0x20017 -#define ABMON_11 0x20018 -#define ABMON_12 0x20019 -#define ABMON_2 0x2000F -#define ABMON_3 0x20010 -#define ABMON_4 0x20011 -#define ABMON_5 0x20012 -#define ABMON_6 0x20013 -#define ABMON_7 0x20014 -#define ABMON_8 0x20015 -#define ABMON_9 0x20016 -#define ABORT 238 -#define ACK 04 -#define ADD ns_uop_add -#define ADJ_ESTERROR 0x0008 -#define ADJ_FREQUENCY 0x0002 -#define ADJ_MAXERROR 0x0004 -#define ADJ_MICRO 0x1000 -#define ADJ_NANO 0x2000 -#define ADJ_OFFSET 0x0001 -#define ADJ_OFFSET_SINGLESHOT 0x8001 -#define ADJ_OFFSET_SS_READ 0xa001 -#define ADJ_SETOFFSET 0x0100 -#define ADJ_STATUS 0x0010 -#define ADJ_TAI 0x0080 -#define ADJ_TICK 0x4000 -#define ADJ_TIMECONST 0x0020 -#define AF_INET PF_INET -#define AF_INET6 PF_INET6 -#define AF_UNIX 3 -#define AF_UNSPEC PF_UNSPEC -#define ALT_DIGITS 0x2002F -#define AM_STR 0x20026 -#define ANYMARK 0x01 -#define AO 245 -#define AREGTYPE '\0' -#define ARFMAG "`\n" -#define ARG_MAX 131072 -#define ARMAG "!\n" -#define AT_EACCESS (0x0) -#define AT_FDCWD (-2) -#define AT_REMOVEDIR (0x4) -#define AT_SYMLINK_FOLLOW (0x2) -#define AT_SYMLINK_NOFOLLOW (0x1) -#define AUTHTYPE_CNT 5 -#define AUTHTYPE_KERBEROS_V4 1 -#define AUTHTYPE_KERBEROS_V5 2 -#define AUTHTYPE_MINK 4 -#define AUTHTYPE_NAME(x) authtype_names[x] -#define AUTHTYPE_NAME_OK(x) ((unsigned int)(x) < AUTHTYPE_CNT) -#define AUTHTYPE_NULL 0 -#define AUTHTYPE_SPX 3 -#define AUTHTYPE_TEST 99 -#define AUTH_HOW_MASK 2 -#define AUTH_HOW_MUTUAL 2 -#define AUTH_HOW_ONE_WAY 0 -#define AUTH_WHO_CLIENT 0 -#define AUTH_WHO_MASK 1 -#define AUTH_WHO_SERVER 1 -#define AYT 246 -#define BIG_ENDIAN __BIG_ENDIAN -#define BITSPERBYTE CHAR_BIT -#define BLKTYPE '4' -#define BLK_BYTECOUNT 2 -#define BLK_EOF 0x40 -#define BLK_EOR 0x80 -#define BLK_ERRORS 0x20 -#define BLK_RESTART 0x10 -#define BREAK 243 -#define BUFSIZ 1024 -#define BYTE_ORDER __BYTE_ORDER -#define CANBSIZ 255 -#define CBRK CEOL -#define CDISCARD CTRL('o') -#define CDSUSP CTRL('y') -#define CEOF CTRL('d') -#define CEOL '\0' -#define CEOT CEOF -#define CERASE 0177 -#define CFLUSH CDISCARD -#define CHARBITS (sizeof(char) * 8) -#define CHARCLASS_NAME_MAX 14 -#define CHAR_BIT 8 -#define CHAR_MAX 127 -#define CHAR_MIN (-128) -#define CHRTYPE '3' -#define CINTR CTRL('c') -#define CKILL CTRL('u') -#define CLNEXT CTRL('v') -#define CLOCKS_PER_SEC ((clock_t)1000000000) -#define CLOCK_MONOTONIC (&_CLOCK_MONOTONIC) -#define CLOCK_REALTIME (&_CLOCK_REALTIME) -#define CMIN 1 -#define CMPLX(x,y) __CMPLX(x, y, double) -#define CMPLXF(x,y) __CMPLX(x, y, float) -#define CMPLXL(x,y) __CMPLX(x, y, long double) -#define CODESET 14 -#define COLL_WEIGHTS_MAX 2 -#define COMPLETE 2 -#define CONTINUE 3 -#define CONTTYPE '7' -#define CQUIT 034 -#define CREPRINT CTRL('r') -#define CRNCYSTR 0x4000F -#define CRPRNT CREPRINT -#define CSTART CTRL('q') -#define CSTATUS '\0' -#define CSTOP CTRL('s') -#define CSUSP CTRL('z') -#define CTIME 0 -#define CTRL(x) ((x)&037) -#define CWERASE CTRL('w') -#define C_ANY ns_c_any -#define C_CHAOS ns_c_chaos -#define C_HS ns_c_hs -#define C_IN ns_c_in -#define C_IRGRP 000040 -#define C_IROTH 000004 -#define C_IRUSR 000400 -#define C_ISBLK 060000 -#define C_ISCHR 020000 -#define C_ISCTG 0110000 -#define C_ISDIR 040000 -#define C_ISFIFO 010000 -#define C_ISGID 002000 -#define C_ISLNK 0120000 -#define C_ISREG 0100000 -#define C_ISSOCK 0140000 -#define C_ISUID 004000 -#define C_ISVTX 001000 -#define C_IWGRP 000020 -#define C_IWOTH 000002 -#define C_IWUSR 000200 -#define C_IXGRP 000010 -#define C_IXOTH 000001 -#define C_IXUSR 000100 -#define C_NONE ns_c_none -#define DATA 03 -#define DAY_1 0x20007 -#define DAY_2 0x20008 -#define DAY_3 0x20009 -#define DAY_4 0x2000A -#define DAY_5 0x2000B -#define DAY_6 0x2000C -#define DAY_7 0x2000D -#define DBL_DECIMAL_DIG 17 -#define DBL_DIG 15 -#define DBL_EPSILON 2.22044604925031308085e-16 -#define DBL_HAS_SUBNORM 1 -#define DBL_MANT_DIG 53 -#define DBL_MAX 1.79769313486231570815e+308 -#define DBL_MAX_10_EXP 308 -#define DBL_MAX_EXP 1024 -#define DBL_MIN 2.22507385850720138309e-308 -#define DBL_MIN_10_EXP (-307) -#define DBL_MIN_EXP (-1021) -#define DBL_TRUE_MIN 4.94065645841246544177e-324 -#define DECIMAL_DIG 36 -#define DELAYTIMER_MAX 0x7fffffff -#define DELETE ns_uop_delete -#define DEV_BSIZE 512 -#define DIRTYPE '5' -#define DM 242 -#define DMAXEXP DBL_MAX_EXP -#define DMINEXP DBL_MIN_EXP -#define DO 253 -#define DONT 254 -#define DOUBLEBITS (sizeof(double) * 8) -#define DTTOIF(x) (__wasilibc_dttoif(x)) -#define DT_BLK __WASI_FILETYPE_BLOCK_DEVICE -#define DT_CHR __WASI_FILETYPE_CHARACTER_DEVICE -#define DT_DIR __WASI_FILETYPE_DIRECTORY -#define DT_FIFO __WASI_FILETYPE_SOCKET_STREAM -#define DT_LNK __WASI_FILETYPE_SYMBOLIC_LINK -#define DT_REG __WASI_FILETYPE_REGULAR_FILE -#define DT_UNKNOWN __WASI_FILETYPE_UNKNOWN -#define D_FMT 0x20029 -#define D_T_FMT 0x20028 -#define E2BIG __WASI_ERRNO_2BIG -#define EACCES __WASI_ERRNO_ACCES -#define EACCESS 2 -#define EADDRINUSE __WASI_ERRNO_ADDRINUSE -#define EADDRNOTAVAIL __WASI_ERRNO_ADDRNOTAVAIL -#define EAFNOSUPPORT __WASI_ERRNO_AFNOSUPPORT -#define EAGAIN __WASI_ERRNO_AGAIN -#define EALREADY __WASI_ERRNO_ALREADY -#define EBADF __WASI_ERRNO_BADF -#define EBADID 5 -#define EBADMSG __WASI_ERRNO_BADMSG -#define EBADOP 4 -#define EBUSY __WASI_ERRNO_BUSY -#define EC 247 -#define ECANCELED __WASI_ERRNO_CANCELED -#define ECHILD __WASI_ERRNO_CHILD -#define ECONNABORTED __WASI_ERRNO_CONNABORTED -#define ECONNREFUSED __WASI_ERRNO_CONNREFUSED -#define ECONNRESET __WASI_ERRNO_CONNRESET -#define EDEADLK __WASI_ERRNO_DEADLK -#define EDESTADDRREQ __WASI_ERRNO_DESTADDRREQ -#define EDOM __WASI_ERRNO_DOM -#define EDQUOT __WASI_ERRNO_DQUOT -#define EEXIST __WASI_ERRNO_EXIST -#define EEXISTS 6 -#define EFAULT __WASI_ERRNO_FAULT -#define EFBIG __WASI_ERRNO_FBIG -#define EFD_CLOEXEC O_CLOEXEC -#define EFD_NONBLOCK O_NONBLOCK -#define EFD_SEMAPHORE 1 -#define EHOSTUNREACH __WASI_ERRNO_HOSTUNREACH -#define EIDRM __WASI_ERRNO_IDRM -#define EILSEQ __WASI_ERRNO_ILSEQ -#define EINPROGRESS __WASI_ERRNO_INPROGRESS -#define EINTR __WASI_ERRNO_INTR -#define EINVAL __WASI_ERRNO_INVAL -#define EIO __WASI_ERRNO_IO -#define EISCONN __WASI_ERRNO_ISCONN -#define EISDIR __WASI_ERRNO_ISDIR -#define EL 248 -#define ELOOP __WASI_ERRNO_LOOP -#define EMFILE __WASI_ERRNO_MFILE -#define EMLINK __WASI_ERRNO_MLINK -#define EMSGSIZE __WASI_ERRNO_MSGSIZE -#define EMULTIHOP __WASI_ERRNO_MULTIHOP -#define ENAMETOOLONG __WASI_ERRNO_NAMETOOLONG -#define ENCRYPT_CNT 9 -#define ENCRYPT_DEC_KEYID 8 -#define ENCRYPT_ENC_KEYID 7 -#define ENCRYPT_END 4 -#define ENCRYPT_IS 0 -#define ENCRYPT_NAME(x) encrypt_names[x] -#define ENCRYPT_NAME_OK(x) ((unsigned int)(x) < ENCRYPT_CNT) -#define ENCRYPT_REPLY 2 -#define ENCRYPT_REQEND 6 -#define ENCRYPT_REQSTART 5 -#define ENCRYPT_START 3 -#define ENCRYPT_SUPPORT 1 -#define ENCTYPE_ANY 0 -#define ENCTYPE_CNT 3 -#define ENCTYPE_DES_CFB64 1 -#define ENCTYPE_DES_OFB64 2 -#define ENCTYPE_NAME(x) enctype_names[x] -#define ENCTYPE_NAME_OK(x) ((unsigned int)(x) < ENCTYPE_CNT) -#define ENETDOWN __WASI_ERRNO_NETDOWN -#define ENETRESET __WASI_ERRNO_NETRESET -#define ENETUNREACH __WASI_ERRNO_NETUNREACH -#define ENFILE __WASI_ERRNO_NFILE -#define ENOBUFS __WASI_ERRNO_NOBUFS -#define ENODEV __WASI_ERRNO_NODEV -#define ENOENT __WASI_ERRNO_NOENT -#define ENOEXEC __WASI_ERRNO_NOEXEC -#define ENOLCK __WASI_ERRNO_NOLCK -#define ENOLINK __WASI_ERRNO_NOLINK -#define ENOMEM __WASI_ERRNO_NOMEM -#define ENOMSG __WASI_ERRNO_NOMSG -#define ENOPROTOOPT __WASI_ERRNO_NOPROTOOPT -#define ENOSPACE 3 -#define ENOSPC __WASI_ERRNO_NOSPC -#define ENOSYS __WASI_ERRNO_NOSYS -#define ENOTCAPABLE __WASI_ERRNO_NOTCAPABLE -#define ENOTCONN __WASI_ERRNO_NOTCONN -#define ENOTDIR __WASI_ERRNO_NOTDIR -#define ENOTEMPTY __WASI_ERRNO_NOTEMPTY -#define ENOTFOUND 1 -#define ENOTRECOVERABLE __WASI_ERRNO_NOTRECOVERABLE -#define ENOTSOCK __WASI_ERRNO_NOTSOCK -#define ENOTSUP __WASI_ERRNO_NOTSUP -#define ENOTTY __WASI_ERRNO_NOTTY -#define ENOUSER 7 -#define ENV_ESC 2 -#define ENV_USERVAR 3 -#define ENXIO __WASI_ERRNO_NXIO -#define EOF (-1) -#define EOPNOTSUPP ENOTSUP -#define EOR 239 -#define EOVERFLOW __WASI_ERRNO_OVERFLOW -#define EOWNERDEAD __WASI_ERRNO_OWNERDEAD -#define EPERM __WASI_ERRNO_PERM -#define EPIPE __WASI_ERRNO_PIPE -#define EPROTO __WASI_ERRNO_PROTO -#define EPROTONOSUPPORT __WASI_ERRNO_PROTONOSUPPORT -#define EPROTOTYPE __WASI_ERRNO_PROTOTYPE -#define ERA 0x2002C -#define ERANGE __WASI_ERRNO_RANGE -#define ERA_D_FMT 0x2002E -#define ERA_D_T_FMT 0x20030 -#define ERA_T_FMT 0x20031 -#define EROFS __WASI_ERRNO_ROFS -#define ERROR 05 -#define ESPIPE __WASI_ERRNO_SPIPE -#define ESRCH __WASI_ERRNO_SRCH -#define ESTALE __WASI_ERRNO_STALE -#define ETIMEDOUT __WASI_ERRNO_TIMEDOUT -#define ETXTBSY __WASI_ERRNO_TXTBSY -#define EUNDEF 0 -#define EWOULDBLOCK EAGAIN -#define EXDEV __WASI_ERRNO_XDEV -#define EXIT_FAILURE 1 -#define EXIT_SUCCESS 0 -#define EX_CANTCREAT 73 -#define EX_CONFIG 78 -#define EX_DATAERR 65 -#define EX_IOERR 74 -#define EX_NOHOST 68 -#define EX_NOINPUT 66 -#define EX_NOPERM 77 -#define EX_NOUSER 67 -#define EX_OK 0 -#define EX_OSERR 71 -#define EX_OSFILE 72 -#define EX_PROTOCOL 76 -#define EX_SOFTWARE 70 -#define EX_TEMPFAIL 75 -#define EX_UNAVAILABLE 69 -#define EX_USAGE 64 -#define EX__BASE 64 -#define EX__MAX 78 -#define FD_CLOEXEC (1) -#define FD_CLR(fd,set) (FD_CLR((fd), (set))) -#define FD_COPY(from,to) (FD_COPY((from), (to))) -#define FD_ISSET(fd,set) (FD_ISSET((fd), (set))) -#define FD_SET(fd,set) (FD_SET((fd), (set))) -#define FD_SETSIZE 1024 -#define FD_ZERO(set) (FD_ZERO((set))) -#define FE_ALL_EXCEPT 0 -#define FE_DFL_ENV ((const fenv_t *) -1) -#define FE_TONEAREST 0 -#define FIFOTYPE '6' -#define FILENAME_MAX 4096 -#define FILESIZEBITS 64 -#define FIONBIO 2 -#define FIONREAD 1 -#define FLOATBITS (sizeof(float) * 8) -#define FLT_DECIMAL_DIG 9 -#define FLT_DIG 6 -#define FLT_EPSILON 1.1920928955078125e-07F -#define FLT_EVAL_METHOD 0 -#define FLT_HAS_SUBNORM 1 -#define FLT_MANT_DIG 24 -#define FLT_MAX 3.40282346638528859812e+38F -#define FLT_MAX_10_EXP 38 -#define FLT_MAX_EXP 128 -#define FLT_MIN 1.17549435082228750797e-38F -#define FLT_MIN_10_EXP (-37) -#define FLT_MIN_EXP (-125) -#define FLT_RADIX 2 -#define FLT_ROUNDS (__builtin_flt_rounds()) -#define FLT_TRUE_MIN 1.40129846432481707092e-45F -#define FLUSHBAND 0x04 -#define FLUSHR 0x01 -#define FLUSHRW 0x03 -#define FLUSHW 0x02 -#define FMAXEXP FLT_MAX_EXP -#define FMINEXP FLT_MIN_EXP -#define FMNAMESZ 8 -#define FNM_CASEFOLD 0x10 -#define FNM_FILE_NAME FNM_PATHNAME -#define FNM_LEADING_DIR 0x8 -#define FNM_NOESCAPE 0x2 -#define FNM_NOMATCH 1 -#define FNM_NOSYS (-1) -#define FNM_PATHNAME 0x1 -#define FNM_PERIOD 0x4 -#define FOPEN_MAX 1000 -#define FORMERR ns_r_formerr -#define FORM_C 3 -#define FORM_N 1 -#define FORM_T 2 -#define FP_ILOGB0 FP_ILOGBNAN -#define FP_ILOGBNAN (-1-0x7fffffff) -#define FP_INFINITE 1 -#define FP_NAN 0 -#define FP_NORMAL 4 -#define FP_SUBNORMAL 3 -#define FP_ZERO 2 -#define FSETLOCKING_BYCALLER 2 -#define FSETLOCKING_INTERNAL 1 -#define FSETLOCKING_QUERY 0 -#define FTW_CHDIR 4 -#define FTW_D 2 -#define FTW_DEPTH 8 -#define FTW_DNR 3 -#define FTW_DP 6 -#define FTW_F 1 -#define FTW_MOUNT 2 -#define FTW_NS 4 -#define FTW_PHYS 1 -#define FTW_SL 5 -#define FTW_SLN 7 -#define F_GETFD (1) -#define F_GETFL (3) -#define F_LOCK 1 -#define F_OK (0) -#define F_SETFD (2) -#define F_SETFL (4) -#define F_TEST 3 -#define F_TLOCK 2 -#define F_ULOCK 0 -#define GA 249 -#define GETLONG NS_GET32 -#define GETSHORT NS_GET16 -#define GLOB_ABORTED 2 -#define GLOB_APPEND 0x20 -#define GLOB_DOOFFS 0x08 -#define GLOB_ERR 0x01 -#define GLOB_MARK 0x02 -#define GLOB_NOCHECK 0x10 -#define GLOB_NOESCAPE 0x40 -#define GLOB_NOMATCH 3 -#define GLOB_NOSORT 0x04 -#define GLOB_NOSPACE 1 -#define GLOB_NOSYS 4 -#define GLOB_PERIOD 0x80 -#define GROUP_FILTER_SIZE(numsrc) (sizeof(struct group_filter) - sizeof(struct sockaddr_storage) + (numsrc) * sizeof(struct sockaddr_storage)) -#define HFIXEDSZ NS_HFIXEDSZ -#define HIBITL MINLONG -#define HIBITS MINSHORT -#define HOST_NAME_MAX 255 -#define HUGE 3.40282346638528859812e+38F -#define HUGE_VAL ((double)INFINITY) -#define HUGE_VALF INFINITY -#define HUGE_VALL ((long double)INFINITY) -#define I _Complex_I -#define IAC 255 -#define ICMP6_DST_UNREACH 1 -#define ICMP6_DST_UNREACH_ADDR 3 -#define ICMP6_DST_UNREACH_ADMIN 1 -#define ICMP6_DST_UNREACH_BEYONDSCOPE 2 -#define ICMP6_DST_UNREACH_NOPORT 4 -#define ICMP6_DST_UNREACH_NOROUTE 0 -#define ICMP6_ECHO_REPLY 129 -#define ICMP6_ECHO_REQUEST 128 -#define ICMP6_FILTER 1 -#define ICMP6_FILTER_BLOCK 1 -#define ICMP6_FILTER_BLOCKOTHERS 3 -#define ICMP6_FILTER_PASS 2 -#define ICMP6_FILTER_PASSONLY 4 -#define ICMP6_FILTER_SETBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) |= (1 << ((type) & 31)))) -#define ICMP6_FILTER_SETBLOCKALL(filterp) memset (filterp, 0xFF, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_SETPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) &= ~(1 << ((type) & 31)))) -#define ICMP6_FILTER_SETPASSALL(filterp) memset (filterp, 0, sizeof (struct icmp6_filter)); -#define ICMP6_FILTER_WILLBLOCK(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) != 0) -#define ICMP6_FILTER_WILLPASS(type,filterp) ((((filterp)->icmp6_filt[(type) >> 5]) & (1 << ((type) & 31))) == 0) -#define ICMP6_INFOMSG_MASK 0x80 -#define ICMP6_PACKET_TOO_BIG 2 -#define ICMP6_PARAMPROB_HEADER 0 -#define ICMP6_PARAMPROB_NEXTHEADER 1 -#define ICMP6_PARAMPROB_OPTION 2 -#define ICMP6_PARAM_PROB 4 -#define ICMP6_ROUTER_RENUMBERING 138 -#define ICMP6_RR_FLAGS_FORCEAPPLY 0x20 -#define ICMP6_RR_FLAGS_PREVDONE 0x08 -#define ICMP6_RR_FLAGS_REQRESULT 0x40 -#define ICMP6_RR_FLAGS_SPECSITE 0x10 -#define ICMP6_RR_FLAGS_TEST 0x80 -#define ICMP6_RR_PCOUSE_FLAGS_DECRPLTIME 0x40 -#define ICMP6_RR_PCOUSE_FLAGS_DECRVLTIME 0x80 -#define ICMP6_RR_PCOUSE_RAFLAGS_AUTO 0x10 -#define ICMP6_RR_PCOUSE_RAFLAGS_ONLINK 0x20 -#define ICMP6_RR_RESULT_FLAGS_FORBIDDEN 0x0100 -#define ICMP6_RR_RESULT_FLAGS_OOB 0x0200 -#define ICMP6_TIME_EXCEEDED 3 -#define ICMP6_TIME_EXCEED_REASSEMBLY 1 -#define ICMP6_TIME_EXCEED_TRANSIT 0 -#define ICMP_ADDRESS 17 -#define ICMP_ADDRESSREPLY 18 -#define ICMP_ADVLEN(p) (8 + ((p)->icmp_ip.ip_hl << 2) + 8) -#define ICMP_ADVLENMIN (8 + sizeof (struct ip) + 8) -#define ICMP_DEST_UNREACH 3 -#define ICMP_ECHO 8 -#define ICMP_ECHOREPLY 0 -#define ICMP_EXC_FRAGTIME 1 -#define ICMP_EXC_TTL 0 -#define ICMP_FRAG_NEEDED 4 -#define ICMP_HOST_ANO 10 -#define ICMP_HOST_ISOLATED 8 -#define ICMP_HOST_UNKNOWN 7 -#define ICMP_HOST_UNREACH 1 -#define ICMP_HOST_UNR_TOS 12 -#define ICMP_INFOTYPE(type) ((type) == ICMP_ECHOREPLY || (type) == ICMP_ECHO || (type) == ICMP_ROUTERADVERT || (type) == ICMP_ROUTERSOLICIT || (type) == ICMP_TSTAMP || (type) == ICMP_TSTAMPREPLY || (type) == ICMP_IREQ || (type) == ICMP_IREQREPLY || (type) == ICMP_MASKREQ || (type) == ICMP_MASKREPLY) -#define ICMP_INFO_REPLY 16 -#define ICMP_INFO_REQUEST 15 -#define ICMP_IREQ 15 -#define ICMP_IREQREPLY 16 -#define ICMP_MASKLEN 12 -#define ICMP_MASKREPLY 18 -#define ICMP_MASKREQ 17 -#define ICMP_MAXTYPE 18 -#define ICMP_MINLEN 8 -#define ICMP_NET_ANO 9 -#define ICMP_NET_UNKNOWN 6 -#define ICMP_NET_UNREACH 0 -#define ICMP_NET_UNR_TOS 11 -#define ICMP_PARAMETERPROB 12 -#define ICMP_PARAMPROB 12 -#define ICMP_PARAMPROB_OPTABSENT 1 -#define ICMP_PKT_FILTERED 13 -#define ICMP_PORT_UNREACH 3 -#define ICMP_PREC_CUTOFF 15 -#define ICMP_PREC_VIOLATION 14 -#define ICMP_PROT_UNREACH 2 -#define ICMP_REDIRECT 5 -#define ICMP_REDIRECT_HOST 1 -#define ICMP_REDIRECT_NET 0 -#define ICMP_REDIRECT_TOSHOST 3 -#define ICMP_REDIRECT_TOSNET 2 -#define ICMP_REDIR_HOST 1 -#define ICMP_REDIR_HOSTTOS 3 -#define ICMP_REDIR_NET 0 -#define ICMP_REDIR_NETTOS 2 -#define ICMP_ROUTERADVERT 9 -#define ICMP_ROUTERSOLICIT 10 -#define ICMP_SOURCEQUENCH 4 -#define ICMP_SOURCE_QUENCH 4 -#define ICMP_SR_FAILED 5 -#define ICMP_TIMESTAMP 13 -#define ICMP_TIMESTAMPREPLY 14 -#define ICMP_TIME_EXCEEDED 11 -#define ICMP_TIMXCEED 11 -#define ICMP_TIMXCEED_INTRANS 0 -#define ICMP_TIMXCEED_REASS 1 -#define ICMP_TSLEN (8 + 3 * sizeof (n_time)) -#define ICMP_TSTAMP 13 -#define ICMP_TSTAMPREPLY 14 -#define ICMP_UNREACH 3 -#define ICMP_UNREACH_FILTER_PROHIB 13 -#define ICMP_UNREACH_HOST 1 -#define ICMP_UNREACH_HOST_PRECEDENCE 14 -#define ICMP_UNREACH_HOST_PROHIB 10 -#define ICMP_UNREACH_HOST_UNKNOWN 7 -#define ICMP_UNREACH_ISOLATED 8 -#define ICMP_UNREACH_NEEDFRAG 4 -#define ICMP_UNREACH_NET 0 -#define ICMP_UNREACH_NET_PROHIB 9 -#define ICMP_UNREACH_NET_UNKNOWN 6 -#define ICMP_UNREACH_PORT 3 -#define ICMP_UNREACH_PRECEDENCE_CUTOFF 15 -#define ICMP_UNREACH_PROTOCOL 2 -#define ICMP_UNREACH_SRCFAIL 5 -#define ICMP_UNREACH_TOSHOST 12 -#define ICMP_UNREACH_TOSNET 11 -#define IFTODT(x) (__wasilibc_iftodt(x)) -#define IGMP_AWAKENING_MEMBER 5 -#define IGMP_DELAYING_MEMBER 1 -#define IGMP_DVMRP 0x13 -#define IGMP_HOST_LEAVE_MESSAGE IGMP_V2_LEAVE_GROUP -#define IGMP_HOST_MEMBERSHIP_QUERY IGMP_MEMBERSHIP_QUERY -#define IGMP_HOST_MEMBERSHIP_REPORT IGMP_V1_MEMBERSHIP_REPORT -#define IGMP_HOST_NEW_MEMBERSHIP_REPORT IGMP_V2_MEMBERSHIP_REPORT -#define IGMP_IDLE_MEMBER 2 -#define IGMP_LAZY_MEMBER 3 -#define IGMP_MAX_HOST_REPORT_DELAY 10 -#define IGMP_MEMBERSHIP_QUERY 0x11 -#define IGMP_MINLEN 8 -#define IGMP_MTRACE 0x1f -#define IGMP_MTRACE_RESP 0x1e -#define IGMP_PIM 0x14 -#define IGMP_SLEEPING_MEMBER 4 -#define IGMP_TIMER_SCALE 10 -#define IGMP_TRACE 0x15 -#define IGMP_V1_MEMBERSHIP_REPORT 0x12 -#define IGMP_V2_LEAVE_GROUP 0x17 -#define IGMP_V2_MEMBERSHIP_REPORT 0x16 -#define IGMP_v1_ROUTER 1 -#define IGMP_v2_ROUTER 2 -#define IN6ADDRSZ NS_IN6ADDRSZ -#define IN6ADDR_ANY_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 } } -#define IN6ADDR_LOOPBACK_INIT { { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01 } } -#define IN6_ARE_ADDR_EQUAL(a,b) __ARE_4_EQUAL((const uint32_t *)(a), (const uint32_t *)(b)) -#define IN6_IS_ADDR_LINKLOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0x80) -#define IN6_IS_ADDR_LOOPBACK(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[12] == 0 && ((uint8_t *) (a))[13] == 0 && ((uint8_t *) (a))[14] == 0 && ((uint8_t *) (a))[15] == 1 ) -#define IN6_IS_ADDR_MC_GLOBAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0xe)) -#define IN6_IS_ADDR_MC_LINKLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x2)) -#define IN6_IS_ADDR_MC_NODELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x1)) -#define IN6_IS_ADDR_MC_ORGLOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x8)) -#define IN6_IS_ADDR_MC_SITELOCAL(a) (IN6_IS_ADDR_MULTICAST(a) && ((((uint8_t *) (a))[1] & 0xf) == 0x5)) -#define IN6_IS_ADDR_MULTICAST(a) (((uint8_t *) (a))[0] == 0xff) -#define IN6_IS_ADDR_SITELOCAL(a) ((((uint8_t *) (a))[0]) == 0xfe && (((uint8_t *) (a))[1] & 0xc0) == 0xc0) -#define IN6_IS_ADDR_UNSPECIFIED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint32_t *) (a))[3] == 0) -#define IN6_IS_ADDR_V4COMPAT(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint32_t *) (a))[2] == 0 && ((uint8_t *) (a))[15] > 1) -#define IN6_IS_ADDR_V4MAPPED(a) (((uint32_t *) (a))[0] == 0 && ((uint32_t *) (a))[1] == 0 && ((uint8_t *) (a))[8] == 0 && ((uint8_t *) (a))[9] == 0 && ((uint8_t *) (a))[10] == 0xff && ((uint8_t *) (a))[11] == 0xff) -#define INADDRSZ NS_INADDRSZ -#define INADDR_ALLHOSTS_GROUP ((in_addr_t) 0xe0000001) -#define INADDR_ALLRTRS_GROUP ((in_addr_t) 0xe0000002) -#define INADDR_ALLSNOOPERS_GROUP ((in_addr_t) 0xe000006a) -#define INADDR_ANY ((in_addr_t) 0x00000000) -#define INADDR_BROADCAST ((in_addr_t) 0xffffffff) -#define INADDR_DUMMY ((in_addr_t) 0xc0000008) -#define INADDR_LOOPBACK ((in_addr_t) 0x7f000001) -#define INADDR_MAX_LOCAL_GROUP ((in_addr_t) 0xe00000ff) -#define INADDR_NONE ((in_addr_t) 0xffffffff) -#define INADDR_UNSPEC_GROUP ((in_addr_t) 0xe0000000) -#define INDIR_MASK NS_CMPRSFLGS -#define INET6_ADDRSTRLEN 46 -#define INET_ADDRSTRLEN 16 -#define INFINITY 1e5000f -#define INT16SZ NS_INT16SZ -#define INT16_C(c) c -#define INT16_MAX (0x7fff) -#define INT16_MIN (-1-0x7fff) -#define INT32SZ NS_INT32SZ -#define INT32_C(c) c -#define INT32_MAX (0x7fffffff) -#define INT32_MIN (-1-0x7fffffff) -#define INT64_C(c) c ## LL -#define INT64_MAX (0x7fffffffffffffff) -#define INT64_MIN (-1-0x7fffffffffffffff) -#define INT8SZ NS_INT8SZ -#define INT8_C(c) c -#define INT8_MAX (0x7f) -#define INT8_MIN (-1-0x7f) -#define INTBITS (sizeof(int) * 8) -#define INTMAX_C(c) c ## LL -#define INTMAX_MAX INT64_MAX -#define INTMAX_MIN INT64_MIN -#define INTPTR_MAX INT32_MAX -#define INTPTR_MIN INT32_MIN -#define INT_FAST16_MAX INT16_MAX -#define INT_FAST16_MIN INT16_MIN -#define INT_FAST32_MAX INT32_MAX -#define INT_FAST32_MIN INT32_MIN -#define INT_FAST64_MAX INT64_MAX -#define INT_FAST64_MIN INT64_MIN -#define INT_FAST8_MAX INT8_MAX -#define INT_FAST8_MIN INT8_MIN -#define INT_LEAST16_MAX INT16_MAX -#define INT_LEAST16_MIN INT16_MIN -#define INT_LEAST32_MAX INT32_MAX -#define INT_LEAST32_MIN INT32_MIN -#define INT_LEAST64_MAX INT64_MAX -#define INT_LEAST64_MIN INT64_MIN -#define INT_LEAST8_MAX INT8_MAX -#define INT_LEAST8_MIN INT8_MIN -#define INT_MAX 0x7fffffff -#define INT_MIN (-1-0x7fffffff) -#define IN_BADCLASS(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xf0000000) -#define IN_CLASSA(a) ((((in_addr_t)(a)) & 0x80000000) == 0) -#define IN_CLASSA_HOST (0xffffffff & ~IN_CLASSA_NET) -#define IN_CLASSA_MAX 128 -#define IN_CLASSA_NET 0xff000000 -#define IN_CLASSA_NSHIFT 24 -#define IN_CLASSB(a) ((((in_addr_t)(a)) & 0xc0000000) == 0x80000000) -#define IN_CLASSB_HOST (0xffffffff & ~IN_CLASSB_NET) -#define IN_CLASSB_MAX 65536 -#define IN_CLASSB_NET 0xffff0000 -#define IN_CLASSB_NSHIFT 16 -#define IN_CLASSC(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xc0000000) -#define IN_CLASSC_HOST (0xffffffff & ~IN_CLASSC_NET) -#define IN_CLASSC_NET 0xffffff00 -#define IN_CLASSC_NSHIFT 8 -#define IN_CLASSD(a) ((((in_addr_t)(a)) & 0xf0000000) == 0xe0000000) -#define IN_EXPERIMENTAL(a) ((((in_addr_t)(a)) & 0xe0000000) == 0xe0000000) -#define IN_LOOPBACKNET 127 -#define IN_MULTICAST(a) IN_CLASSD(a) -#define IOV_MAX 1024 -#define IP 244 -#define IP6F_MORE_FRAG 0x0100 -#define IP6F_OFF_MASK 0xf8ff -#define IP6F_RESERVED_MASK 0x0600 -#define IP6OPT_JUMBO 0xc2 -#define IP6OPT_JUMBO_LEN 6 -#define IP6OPT_NSAP_ADDR 0xc3 -#define IP6OPT_PAD1 0 -#define IP6OPT_PADN 1 -#define IP6OPT_ROUTER_ALERT 0x05 -#define IP6OPT_TUNNEL_LIMIT 0x04 -#define IP6OPT_TYPE(o) ((o) & 0xc0) -#define IP6OPT_TYPE_DISCARD 0x40 -#define IP6OPT_TYPE_FORCEICMP 0x80 -#define IP6OPT_TYPE_ICMP 0xc0 -#define IP6OPT_TYPE_MUTABLE 0x20 -#define IP6OPT_TYPE_SKIP 0x00 -#define IP6_ALERT_AN 0x0200 -#define IP6_ALERT_MLD 0x0000 -#define IP6_ALERT_RSVP 0x0100 -#define IPDEFTTL 64 -#define IPFRAGTTL 60 -#define IPOPT_CLASS(o) ((o) & IPOPT_CLASS_MASK) -#define IPOPT_CLASS_MASK 0x60 -#define IPOPT_CONTROL 0x00 -#define IPOPT_COPIED(o) ((o) & IPOPT_COPY) -#define IPOPT_COPY 0x80 -#define IPOPT_DEBMEAS 0x40 -#define IPOPT_END IPOPT_EOL -#define IPOPT_EOL 0 -#define IPOPT_LSRR 131 -#define IPOPT_MEASUREMENT IPOPT_DEBMEAS -#define IPOPT_MINOFF 4 -#define IPOPT_NOOP IPOPT_NOP -#define IPOPT_NOP 1 -#define IPOPT_NUMBER(o) ((o) & IPOPT_NUMBER_MASK) -#define IPOPT_NUMBER_MASK 0x1f -#define IPOPT_OFFSET 2 -#define IPOPT_OLEN 1 -#define IPOPT_OPTVAL 0 -#define IPOPT_RA 148 -#define IPOPT_RESERVED1 0x20 -#define IPOPT_RESERVED2 0x60 -#define IPOPT_RR 7 -#define IPOPT_SATID 136 -#define IPOPT_SEC IPOPT_SECURITY -#define IPOPT_SECURITY 130 -#define IPOPT_SECUR_CONFID 0xf135 -#define IPOPT_SECUR_EFTO 0x789a -#define IPOPT_SECUR_MMMM 0xbc4d -#define IPOPT_SECUR_RESTR 0xaf13 -#define IPOPT_SECUR_SECRET 0xd788 -#define IPOPT_SECUR_TOPSECRET 0x6bc5 -#define IPOPT_SECUR_UNCLASS 0x0000 -#define IPOPT_SID IPOPT_SATID -#define IPOPT_SSRR 137 -#define IPOPT_TIMESTAMP IPOPT_TS -#define IPOPT_TS 68 -#define IPOPT_TS_PRESPEC 3 -#define IPOPT_TS_TSANDADDR 1 -#define IPOPT_TS_TSONLY 0 -#define IPPORT_RESERVED 1024 -#define IPPROTO_ICMP 1 -#define IPPROTO_IP 0 -#define IPPROTO_IPV6 41 -#define IPPROTO_RAW 255 -#define IPPROTO_TCP 6 -#define IPPROTO_UDP 17 -#define IPTOS_CLASS(x) ((x) & IPTOS_CLASS_MASK) -#define IPTOS_CLASS_CS0 0x00 -#define IPTOS_CLASS_CS1 0x20 -#define IPTOS_CLASS_CS2 0x40 -#define IPTOS_CLASS_CS3 0x60 -#define IPTOS_CLASS_CS4 0x80 -#define IPTOS_CLASS_CS5 0xa0 -#define IPTOS_CLASS_CS6 0xc0 -#define IPTOS_CLASS_CS7 0xe0 -#define IPTOS_CLASS_DEFAULT IPTOS_CLASS_CS0 -#define IPTOS_CLASS_MASK 0xe0 -#define IPTOS_DSCP(x) ((x) & IPTOS_DSCP_MASK) -#define IPTOS_DSCP_AF11 0x28 -#define IPTOS_DSCP_AF12 0x30 -#define IPTOS_DSCP_AF13 0x38 -#define IPTOS_DSCP_AF21 0x48 -#define IPTOS_DSCP_AF22 0x50 -#define IPTOS_DSCP_AF23 0x58 -#define IPTOS_DSCP_AF31 0x68 -#define IPTOS_DSCP_AF32 0x70 -#define IPTOS_DSCP_AF33 0x78 -#define IPTOS_DSCP_AF41 0x88 -#define IPTOS_DSCP_AF42 0x90 -#define IPTOS_DSCP_AF43 0x98 -#define IPTOS_DSCP_EF 0xb8 -#define IPTOS_DSCP_MASK 0xfc -#define IPTOS_ECN(x) ((x) & IPTOS_ECN_MASK) -#define IPTOS_ECN_CE 0x03 -#define IPTOS_ECN_ECT0 0x02 -#define IPTOS_ECN_ECT1 0x01 -#define IPTOS_ECN_MASK 0x03 -#define IPTOS_ECN_NOT_ECT 0x00 -#define IPTOS_LOWCOST 0x02 -#define IPTOS_LOWDELAY 0x10 -#define IPTOS_MINCOST IPTOS_LOWCOST -#define IPTOS_PREC(tos) ((tos) & IPTOS_PREC_MASK) -#define IPTOS_PREC_CRITIC_ECP 0xa0 -#define IPTOS_PREC_FLASH 0x60 -#define IPTOS_PREC_FLASHOVERRIDE 0x80 -#define IPTOS_PREC_IMMEDIATE 0x40 -#define IPTOS_PREC_INTERNETCONTROL 0xc0 -#define IPTOS_PREC_MASK 0xe0 -#define IPTOS_PREC_NETCONTROL 0xe0 -#define IPTOS_PREC_PRIORITY 0x20 -#define IPTOS_PREC_ROUTINE 0x00 -#define IPTOS_RELIABILITY 0x04 -#define IPTOS_THROUGHPUT 0x08 -#define IPTOS_TOS(tos) ((tos) & IPTOS_TOS_MASK) -#define IPTOS_TOS_MASK 0x1E -#define IPTTLDEC 1 -#define IPV6_2292DSTOPTS 4 -#define IPV6_2292HOPLIMIT 8 -#define IPV6_2292HOPOPTS 3 -#define IPV6_2292PKTINFO 2 -#define IPV6_2292PKTOPTIONS 6 -#define IPV6_2292RTHDR 5 -#define IPV6_ADDRFORM 1 -#define IPV6_ADDR_PREFERENCES 72 -#define IPV6_ADD_MEMBERSHIP IPV6_JOIN_GROUP -#define IPV6_AUTHHDR 10 -#define IPV6_AUTOFLOWLABEL 70 -#define IPV6_CHECKSUM 7 -#define IPV6_DONTFRAG 62 -#define IPV6_DROP_MEMBERSHIP IPV6_LEAVE_GROUP -#define IPV6_DSTOPTS 59 -#define IPV6_FREEBIND 78 -#define IPV6_HDRINCL 36 -#define IPV6_HOPLIMIT 52 -#define IPV6_HOPOPTS 54 -#define IPV6_IPSEC_POLICY 34 -#define IPV6_JOIN_ANYCAST 27 -#define IPV6_JOIN_GROUP 20 -#define IPV6_LEAVE_ANYCAST 28 -#define IPV6_LEAVE_GROUP 21 -#define IPV6_MINHOPCOUNT 73 -#define IPV6_MTU 24 -#define IPV6_MTU_DISCOVER 23 -#define IPV6_MULTICAST_ALL 29 -#define IPV6_MULTICAST_HOPS 18 -#define IPV6_MULTICAST_IF 17 -#define IPV6_MULTICAST_LOOP 19 -#define IPV6_NEXTHOP 9 -#define IPV6_ORIGDSTADDR 74 -#define IPV6_PATHMTU 61 -#define IPV6_PKTINFO 50 -#define IPV6_PMTUDISC_DO 2 -#define IPV6_PMTUDISC_DONT 0 -#define IPV6_PMTUDISC_INTERFACE 4 -#define IPV6_PMTUDISC_OMIT 5 -#define IPV6_PMTUDISC_PROBE 3 -#define IPV6_PMTUDISC_WANT 1 -#define IPV6_PREFER_SRC_CGA 0x0008 -#define IPV6_PREFER_SRC_COA 0x0004 -#define IPV6_PREFER_SRC_HOME 0x0400 -#define IPV6_PREFER_SRC_NONCGA 0x0800 -#define IPV6_PREFER_SRC_PUBLIC 0x0002 -#define IPV6_PREFER_SRC_PUBTMP_DEFAULT 0x0100 -#define IPV6_PREFER_SRC_TMP 0x0001 -#define IPV6_RECVDSTOPTS 58 -#define IPV6_RECVERR 25 -#define IPV6_RECVFRAGSIZE 77 -#define IPV6_RECVHOPLIMIT 51 -#define IPV6_RECVHOPOPTS 53 -#define IPV6_RECVORIGDSTADDR IPV6_ORIGDSTADDR -#define IPV6_RECVPATHMTU 60 -#define IPV6_RECVPKTINFO 49 -#define IPV6_RECVRTHDR 56 -#define IPV6_RECVTCLASS 66 -#define IPV6_ROUTER_ALERT 22 -#define IPV6_ROUTER_ALERT_ISOLATE 30 -#define IPV6_RTHDR 57 -#define IPV6_RTHDRDSTOPTS 55 -#define IPV6_RTHDR_LOOSE 0 -#define IPV6_RTHDR_STRICT 1 -#define IPV6_RTHDR_TYPE_0 0 -#define IPV6_RXDSTOPTS IPV6_DSTOPTS -#define IPV6_RXHOPOPTS IPV6_HOPOPTS -#define IPV6_TCLASS 67 -#define IPV6_TRANSPARENT 75 -#define IPV6_UNICAST_HOPS 16 -#define IPV6_UNICAST_IF 76 -#define IPV6_V6ONLY 26 -#define IPV6_XFRM_POLICY 35 -#define IPVERSION 4 -#define IP_ADD_MEMBERSHIP 35 -#define IP_ADD_SOURCE_MEMBERSHIP 39 -#define IP_BIND_ADDRESS_NO_PORT 24 -#define IP_BLOCK_SOURCE 38 -#define IP_CHECKSUM 23 -#define IP_DEFAULT_MULTICAST_LOOP 1 -#define IP_DEFAULT_MULTICAST_TTL 1 -#define IP_DF 0x4000 -#define IP_DROP_MEMBERSHIP 36 -#define IP_DROP_SOURCE_MEMBERSHIP 40 -#define IP_FREEBIND 15 -#define IP_HDRINCL 3 -#define IP_IPSEC_POLICY 16 -#define IP_MAXPACKET 65535 -#define IP_MAX_MEMBERSHIPS 20 -#define IP_MF 0x2000 -#define IP_MINTTL 21 -#define IP_MSFILTER 41 -#define IP_MSFILTER_SIZE(numsrc) (sizeof(struct ip_msfilter) - sizeof(struct in_addr) + (numsrc) * sizeof(struct in_addr)) -#define IP_MSS 576 -#define IP_MTU 14 -#define IP_MTU_DISCOVER 10 -#define IP_MULTICAST_ALL 49 -#define IP_MULTICAST_IF 32 -#define IP_MULTICAST_LOOP 34 -#define IP_MULTICAST_TTL 33 -#define IP_NODEFRAG 22 -#define IP_OFFMASK 0x1fff -#define IP_OPTIONS 4 -#define IP_ORIGDSTADDR 20 -#define IP_PASSSEC 18 -#define IP_PKTINFO 8 -#define IP_PKTOPTIONS 9 -#define IP_PMTUDISC 10 -#define IP_PMTUDISC_DO 2 -#define IP_PMTUDISC_DONT 0 -#define IP_PMTUDISC_INTERFACE 4 -#define IP_PMTUDISC_OMIT 5 -#define IP_PMTUDISC_PROBE 3 -#define IP_PMTUDISC_WANT 1 -#define IP_RECVERR 11 -#define IP_RECVERR_RFC4884 26 -#define IP_RECVFRAGSIZE 25 -#define IP_RECVOPTS 6 -#define IP_RECVORIGDSTADDR IP_ORIGDSTADDR -#define IP_RECVRETOPTS IP_RETOPTS -#define IP_RECVTOS 13 -#define IP_RECVTTL 12 -#define IP_RETOPTS 7 -#define IP_RF 0x8000 -#define IP_ROUTER_ALERT 5 -#define IP_TOS 1 -#define IP_TRANSPARENT 19 -#define IP_TTL 2 -#define IP_UNBLOCK_SOURCE 37 -#define IP_UNICAST_IF 50 -#define IP_XFRM_POLICY 17 -#define IQUERY ns_o_iquery -#define I_ATMARK (__SID |31) -#define I_CANPUT (__SID |34) -#define I_CKBAND (__SID |29) -#define I_FDINSERT (__SID |16) -#define I_FIND (__SID |11) -#define I_FLUSH (__SID | 5) -#define I_FLUSHBAND (__SID |28) -#define I_GETBAND (__SID |30) -#define I_GETCLTIME (__SID |33) -#define I_GETSIG (__SID |10) -#define I_GRDOPT (__SID | 7) -#define I_GWROPT (__SID |20) -#define I_LINK (__SID |12) -#define I_LIST (__SID |21) -#define I_LOOK (__SID | 4) -#define I_NREAD (__SID | 1) -#define I_PEEK (__SID |15) -#define I_PLINK (__SID |22) -#define I_POP (__SID | 3) -#define I_PUNLINK (__SID |23) -#define I_PUSH (__SID | 2) -#define I_RECVFD (__SID |14) -#define I_SENDFD (__SID |17) -#define I_SETCLTIME (__SID |32) -#define I_SETSIG (__SID | 9) -#define I_SRDOPT (__SID | 6) -#define I_STR (__SID | 8) -#define I_SWROPT (__SID |19) -#define I_UNLINK (__SID |13) -#define LASTMARK 0x02 -#define LC_ALL 6 -#define LC_ALL_MASK 0x7fffffff -#define LC_COLLATE 3 -#define LC_COLLATE_MASK (1<(b))?(a):(b)) -#define MAXCDNAME NS_MAXCDNAME -#define MAXDNAME NS_MAXDNAME -#define MAXDOUBLE DBL_MAX -#define MAXFLOAT FLT_MAX -#define MAXHOSTNAMELEN 64 -#define MAXINT INT_MAX -#define MAXLABEL NS_MAXLABEL -#define MAXLONG LONG_MAX -#define MAXNAMLEN 255 -#define MAXPATHLEN 4096 -#define MAXSHORT SHRT_MAX -#define MAXSYMLINKS 20 -#define MAXTC 6 -#define MAXTTL 255 -#define MAX_IPOPTLEN 40 -#define MB_CUR_MAX (__ctype_get_mb_cur_max()) -#define MB_LEN_MAX 4 -#define MCAST_BLOCK_SOURCE 43 -#define MCAST_EXCLUDE 0 -#define MCAST_INCLUDE 1 -#define MCAST_JOIN_GROUP 42 -#define MCAST_JOIN_SOURCE_GROUP 46 -#define MCAST_LEAVE_GROUP 45 -#define MCAST_LEAVE_SOURCE_GROUP 47 -#define MCAST_MSFILTER 48 -#define MCAST_UNBLOCK_SOURCE 44 -#define MIN(a,b) (((a)<(b))?(a):(b)) -#define MINDOUBLE DBL_MIN -#define MINFLOAT FLT_MIN -#define MININT INT_MIN -#define MINLONG LONG_MIN -#define MINSHORT SHRT_MIN -#define MLD_LISTENER_QUERY 130 -#define MLD_LISTENER_REDUCTION 132 -#define MLD_LISTENER_REPORT 131 -#define MM_APPL 8 -#define MM_CONSOLE 512 -#define MM_ERROR 2 -#define MM_FIRM 4 -#define MM_HALT 1 -#define MM_HARD 1 -#define MM_INFO 4 -#define MM_NOCON 4 -#define MM_NOMSG 1 -#define MM_NOSEV 0 -#define MM_NOTOK (-1) -#define MM_NRECOV 128 -#define MM_NULLACT ((char*)0) -#define MM_NULLLBL ((char*)0) -#define MM_NULLMC 0L -#define MM_NULLSEV 0 -#define MM_NULLTAG ((char*)0) -#define MM_NULLTXT ((char*)0) -#define MM_OK 0 -#define MM_OPSYS 32 -#define MM_PRINT 256 -#define MM_RECOVER 64 -#define MM_SOFT 2 -#define MM_UTIL 16 -#define MM_WARNING 3 -#define MODE_ACK 0x04 -#define MODE_B 2 -#define MODE_C 3 -#define MODE_ECHO 0x0200 -#define MODE_EDIT 0x01 -#define MODE_FLOW 0x0100 -#define MODE_FORCE 0x1000 -#define MODE_INBIN 0x0400 -#define MODE_LIT_ECHO 0x10 -#define MODE_MASK 0x1f -#define MODE_OUTBIN 0x0800 -#define MODE_S 1 -#define MODE_SOFT_TAB 0x08 -#define MODE_TRAPSIG 0x02 -#define MOD_CLKA ADJ_OFFSET_SINGLESHOT -#define MOD_CLKB ADJ_TICK -#define MOD_ESTERROR ADJ_ESTERROR -#define MOD_FREQUENCY ADJ_FREQUENCY -#define MOD_MAXERROR ADJ_MAXERROR -#define MOD_MICRO ADJ_MICRO -#define MOD_NANO ADJ_NANO -#define MOD_OFFSET ADJ_OFFSET -#define MOD_STATUS ADJ_STATUS -#define MOD_TAI ADJ_TAI -#define MOD_TIMECONST ADJ_TIMECONST -#define MON_1 0x2001A -#define MON_10 0x20023 -#define MON_11 0x20024 -#define MON_12 0x20025 -#define MON_2 0x2001B -#define MON_3 0x2001C -#define MON_4 0x2001D -#define MON_5 0x2001E -#define MON_6 0x2001F -#define MON_7 0x20020 -#define MON_8 0x20021 -#define MON_9 0x20022 -#define MORECTL 1 -#define MOREDATA 2 -#define MSG_ANY 0x02 -#define MSG_BAND 0x04 -#define MSG_HIPRI 0x01 -#define MSG_PEEK __WASI_RIFLAGS_RECV_PEEK -#define MSG_TRUNC __WASI_ROFLAGS_RECV_DATA_TRUNCATED -#define MSG_WAITALL __WASI_RIFLAGS_RECV_WAITALL -#define MUXID_ALL (-1) -#define M_1_PI 0.31830988618379067154 -#define M_2_PI 0.63661977236758134308 -#define M_2_SQRTPI 1.12837916709551257390 -#define M_E 2.7182818284590452354 -#define M_LN10 2.30258509299404568402 -#define M_LN2 0.69314718055994530942 -#define M_LOG10E 0.43429448190325182765 -#define M_LOG2E 1.4426950408889634074 -#define M_PI 3.14159265358979323846 -#define M_PI_2 1.57079632679489661923 -#define M_PI_4 0.78539816339744830962 -#define M_SQRT1_2 0.70710678118654752440 -#define M_SQRT2 1.41421356237309504880 -#define NAMESERVER_PORT NS_DEFAULTPORT -#define NAME_MAX 255 -#define NAN (0.0f/0.0f) -#define NBBY 8 -#define NCARGS 131072 -#define ND_NA_FLAG_OVERRIDE 0x00000020 -#define ND_NA_FLAG_ROUTER 0x00000080 -#define ND_NA_FLAG_SOLICITED 0x00000040 -#define ND_NEIGHBOR_ADVERT 136 -#define ND_NEIGHBOR_SOLICIT 135 -#define ND_OPT_HOME_AGENT_INFO 8 -#define ND_OPT_MTU 5 -#define ND_OPT_PI_FLAG_AUTO 0x40 -#define ND_OPT_PI_FLAG_ONLINK 0x80 -#define ND_OPT_PI_FLAG_RADDR 0x20 -#define ND_OPT_PREFIX_INFORMATION 3 -#define ND_OPT_REDIRECTED_HEADER 4 -#define ND_OPT_RTR_ADV_INTERVAL 7 -#define ND_OPT_SOURCE_LINKADDR 1 -#define ND_OPT_TARGET_LINKADDR 2 -#define ND_RA_FLAG_HOME_AGENT 0x20 -#define ND_RA_FLAG_MANAGED 0x80 -#define ND_RA_FLAG_OTHER 0x40 -#define ND_REDIRECT 137 -#define ND_ROUTER_ADVERT 134 -#define ND_ROUTER_SOLICIT 133 -#define NEW_ENV_VALUE 1 -#define NEW_ENV_VAR 0 -#define NGROUPS 32 -#define NGROUPS_MAX 32 -#define NL_ARGMAX 9 -#define NL_CAT_LOCALE 1 -#define NL_LANGMAX 32 -#define NL_LOCALE_NAME(cat) _NL_LOCALE_NAME(cat) -#define NL_MSGMAX 32767 -#define NL_NMAX 16 -#define NL_SETD 1 -#define NL_SETMAX 255 -#define NL_TEXTMAX 2048 -#define NOERROR ns_r_noerror -#define NOEXPR 0x50001 -#define NOFILE 256 -#define NOGROUP (-1) -#define NOP 241 -#define NOSTR 0x50003 -#define NOTAUTH ns_r_notauth -#define NOTIMP ns_r_notimpl -#define NOTZONE ns_r_notzone -#define NR_ICMP_TYPES 18 -#define NR_ICMP_UNREACH 15 -#define NSLC 18 -#define NS_ALG_DH 2 -#define NS_ALG_DSA 3 -#define NS_ALG_DSS NS_ALG_DSA -#define NS_ALG_EXPIRE_ONLY 253 -#define NS_ALG_MD5RSA 1 -#define NS_ALG_PRIVATE_OID 254 -#define NS_CMPRSFLGS 0xc0 -#define NS_DEFAULTPORT 53 -#define NS_DSA_MAX_BYTES 405 -#define NS_DSA_MIN_SIZE 213 -#define NS_DSA_SIG_SIZE 41 -#define NS_GET16(s,cp) (void)((s) = ns_get16(((cp)+=2)-2)) -#define NS_GET32(l,cp) (void)((l) = ns_get32(((cp)+=4)-4)) -#define NS_HFIXEDSZ 12 -#define NS_IN6ADDRSZ 16 -#define NS_INADDRSZ 4 -#define NS_INT16SZ 2 -#define NS_INT32SZ 4 -#define NS_INT8SZ 1 -#define NS_KEY_EXTENDED_FLAGS 0x1000 -#define NS_KEY_NAME_ENTITY 0x0200 -#define NS_KEY_NAME_RESERVED 0x0300 -#define NS_KEY_NAME_TYPE 0x0300 -#define NS_KEY_NAME_USER 0x0000 -#define NS_KEY_NAME_ZONE 0x0100 -#define NS_KEY_NO_AUTH 0x8000 -#define NS_KEY_NO_CONF 0x4000 -#define NS_KEY_PROT_ANY 255 -#define NS_KEY_PROT_DNSSEC 3 -#define NS_KEY_PROT_EMAIL 2 -#define NS_KEY_PROT_IPSEC 4 -#define NS_KEY_PROT_TLS 1 -#define NS_KEY_RESERVED10 0x0020 -#define NS_KEY_RESERVED11 0x0010 -#define NS_KEY_RESERVED2 0x2000 -#define NS_KEY_RESERVED4 0x0800 -#define NS_KEY_RESERVED5 0x0400 -#define NS_KEY_RESERVED8 0x0080 -#define NS_KEY_RESERVED9 0x0040 -#define NS_KEY_RESERVED_BITMASK ( NS_KEY_RESERVED2 | NS_KEY_RESERVED4 | NS_KEY_RESERVED5 | NS_KEY_RESERVED8 | NS_KEY_RESERVED9 | NS_KEY_RESERVED10 | NS_KEY_RESERVED11 ) -#define NS_KEY_RESERVED_BITMASK2 0xFFFF -#define NS_KEY_SIGNATORYMASK 0x000F -#define NS_KEY_TYPEMASK 0xC000 -#define NS_KEY_TYPE_AUTH_CONF 0x0000 -#define NS_KEY_TYPE_AUTH_ONLY 0x4000 -#define NS_KEY_TYPE_CONF_ONLY 0x8000 -#define NS_KEY_TYPE_NO_KEY 0xC000 -#define NS_MAXCDNAME 255 -#define NS_MAXDNAME 1025 -#define NS_MAXLABEL 63 -#define NS_MAXMSG 65535 -#define NS_MD5RSA_MAX_BASE64 (((NS_MD5RSA_MAX_BYTES+2)/3)*4) -#define NS_MD5RSA_MAX_BITS 4096 -#define NS_MD5RSA_MAX_BYTES ((NS_MD5RSA_MAX_BITS+7/8)*2+3) -#define NS_MD5RSA_MAX_SIZE ((NS_MD5RSA_MAX_BITS+7)/8) -#define NS_MD5RSA_MIN_BITS 512 -#define NS_MD5RSA_MIN_SIZE ((NS_MD5RSA_MIN_BITS+7)/8) -#define NS_NOTIFY_OP ns_o_notify -#define NS_NXT_BITS 8 -#define NS_NXT_BIT_CLEAR(n,p) (p[(n)/NS_NXT_BITS] &= ~(0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_ISSET(n,p) (p[(n)/NS_NXT_BITS] & (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_BIT_SET(n,p) (p[(n)/NS_NXT_BITS] |= (0x80>>((n)%NS_NXT_BITS))) -#define NS_NXT_MAX 127 -#define NS_OPT_DNSSEC_OK 0x8000U -#define NS_OPT_NSID 3 -#define NS_PACKETSZ 512 -#define NS_PUT16(s,cp) ns_put16((s), ((cp)+=2)-2) -#define NS_PUT32(l,cp) ns_put32((l), ((cp)+=4)-4) -#define NS_QFIXEDSZ 4 -#define NS_RRFIXEDSZ 10 -#define NS_SIG_ALG 2 -#define NS_SIG_EXPIR 8 -#define NS_SIG_FOOT 16 -#define NS_SIG_LABELS 3 -#define NS_SIG_OTTL 4 -#define NS_SIG_SIGNED 12 -#define NS_SIG_SIGNER 18 -#define NS_SIG_TYPE 0 -#define NS_TSIG_ALG_HMAC_MD5 "HMAC-MD5.SIG-ALG.REG.INT" -#define NS_TSIG_ERROR_FORMERR -12 -#define NS_TSIG_ERROR_NO_SPACE -11 -#define NS_TSIG_ERROR_NO_TSIG -10 -#define NS_TSIG_FUDGE 300 -#define NS_TSIG_TCP_COUNT 100 -#define NS_UPDATE_OP ns_o_update -#define NTELOPTS (1+TELOPT_NEW_ENVIRON) -#define NULL ((void*)0) -#define NXDOMAIN ns_r_nxdomain -#define NXRRSET ns_r_nxrrset -#define NZERO 20 -#define OLD_ENV_VALUE 0 -#define OLD_ENV_VAR 1 -#define ONCE_FLAG_INIT 0 -#define O_ACCMODE (O_EXEC | O_RDWR | O_SEARCH) -#define O_APPEND __WASI_FDFLAGS_APPEND -#define O_CLOEXEC (0) -#define O_CREAT (__WASI_OFLAGS_CREAT << 12) -#define O_DIRECTORY (__WASI_OFLAGS_DIRECTORY << 12) -#define O_DSYNC __WASI_FDFLAGS_DSYNC -#define O_EXCL (__WASI_OFLAGS_EXCL << 12) -#define O_EXEC (0x02000000) -#define O_NOCTTY (0) -#define O_NOFOLLOW (0x01000000) -#define O_NONBLOCK __WASI_FDFLAGS_NONBLOCK -#define O_RDONLY (0x04000000) -#define O_RDWR (O_RDONLY | O_WRONLY) -#define O_RSYNC __WASI_FDFLAGS_RSYNC -#define O_SEARCH (0x08000000) -#define O_SYNC __WASI_FDFLAGS_SYNC -#define O_TRUNC (__WASI_OFLAGS_TRUNC << 12) -#define O_TTY_INIT (0) -#define O_WRONLY (0x10000000) -#define PACKETSZ NS_PACKETSZ -#define PACKET_ADD_MEMBERSHIP 1 -#define PACKET_AUXDATA 8 -#define PACKET_BROADCAST 1 -#define PACKET_COPY_THRESH 7 -#define PACKET_DROP_MEMBERSHIP 2 -#define PACKET_FANOUT 18 -#define PACKET_FANOUT_DATA 22 -#define PACKET_FASTROUTE 6 -#define PACKET_HDRLEN 11 -#define PACKET_HOST 0 -#define PACKET_IGNORE_OUTGOING 23 -#define PACKET_LOOPBACK 5 -#define PACKET_LOSS 14 -#define PACKET_MR_ALLMULTI 2 -#define PACKET_MR_MULTICAST 0 -#define PACKET_MR_PROMISC 1 -#define PACKET_MR_UNICAST 3 -#define PACKET_MULTICAST 2 -#define PACKET_ORIGDEV 9 -#define PACKET_OTHERHOST 3 -#define PACKET_OUTGOING 4 -#define PACKET_QDISC_BYPASS 20 -#define PACKET_RECV_OUTPUT 3 -#define PACKET_RESERVE 12 -#define PACKET_ROLLOVER_STATS 21 -#define PACKET_RX_RING 5 -#define PACKET_STATISTICS 6 -#define PACKET_TIMESTAMP 17 -#define PACKET_TX_HAS_OFF 19 -#define PACKET_TX_RING 13 -#define PACKET_TX_TIMESTAMP 16 -#define PACKET_VERSION 10 -#define PACKET_VNET_HDR 15 -#define PAGESIZE (0x10000) -#define PAGE_SIZE PAGESIZE -#define PATH_MAX 4096 -#define PDP_ENDIAN __PDP_ENDIAN -#define PF_INET 1 -#define PF_INET6 2 -#define PF_UNSPEC 0 -#define PM_STR 0x20027 -#define POLLERR 0x1000 -#define POLLHUP 0x2000 -#define POLLIN POLLRDNORM -#define POLLNVAL 0x4000 -#define POLLOUT POLLWRNORM -#define POLLRDNORM 0x1 -#define POLLWRNORM 0x2 -#define POSIX_CLOSE_RESTART 0 -#define POSIX_FADV_DONTNEED __WASI_ADVICE_DONTNEED -#define POSIX_FADV_NOREUSE __WASI_ADVICE_NOREUSE -#define POSIX_FADV_NORMAL __WASI_ADVICE_NORMAL -#define POSIX_FADV_RANDOM __WASI_ADVICE_RANDOM -#define POSIX_FADV_SEQUENTIAL __WASI_ADVICE_SEQUENTIAL -#define POSIX_FADV_WILLNEED __WASI_ADVICE_WILLNEED -#define PRELIM 1 -#define PRIX16 __UINT16_FMTX__ -#define PRIX32 __UINT32_FMTX__ -#define PRIX64 __UINT64_FMTX__ -#define PRIX8 __UINT8_FMTX__ -#define PRIXFAST16 __UINT_FAST16_FMTX__ -#define PRIXFAST32 __UINT_FAST32_FMTX__ -#define PRIXFAST64 __UINT_FAST64_FMTX__ -#define PRIXFAST8 __UINT_FAST8_FMTX__ -#define PRIXLEAST16 __UINT_LEAST16_FMTX__ -#define PRIXLEAST32 __UINT_LEAST32_FMTX__ -#define PRIXLEAST64 __UINT_LEAST64_FMTX__ -#define PRIXLEAST8 __UINT_LEAST8_FMTX__ -#define PRIXMAX __UINTMAX_FMTX__ -#define PRIXPTR __UINTPTR_FMTX__ -#define PRId16 __INT16_FMTd__ -#define PRId32 __INT32_FMTd__ -#define PRId64 __INT64_FMTd__ -#define PRId8 __INT8_FMTd__ -#define PRIdFAST16 __INT_FAST16_FMTd__ -#define PRIdFAST32 __INT_FAST32_FMTd__ -#define PRIdFAST64 __INT_FAST64_FMTd__ -#define PRIdFAST8 __INT_FAST8_FMTd__ -#define PRIdLEAST16 __INT_LEAST16_FMTd__ -#define PRIdLEAST32 __INT_LEAST32_FMTd__ -#define PRIdLEAST64 __INT_LEAST64_FMTd__ -#define PRIdLEAST8 __INT_LEAST8_FMTd__ -#define PRIdMAX __INTMAX_FMTd__ -#define PRIdPTR __INTPTR_FMTd__ -#define PRIi16 __INT16_FMTi__ -#define PRIi32 __INT32_FMTi__ -#define PRIi64 __INT64_FMTi__ -#define PRIi8 __INT8_FMTi__ -#define PRIiFAST16 __INT_FAST16_FMTi__ -#define PRIiFAST32 __INT_FAST32_FMTi__ -#define PRIiFAST64 __INT_FAST64_FMTi__ -#define PRIiFAST8 __INT_FAST8_FMTi__ -#define PRIiLEAST16 __INT_LEAST16_FMTi__ -#define PRIiLEAST32 __INT_LEAST32_FMTi__ -#define PRIiLEAST64 __INT_LEAST64_FMTi__ -#define PRIiLEAST8 __INT_LEAST8_FMTi__ -#define PRIiMAX __INTMAX_FMTi__ -#define PRIiPTR __INTPTR_FMTi__ -#define PRIo16 __UINT16_FMTo__ -#define PRIo32 __UINT32_FMTo__ -#define PRIo64 __UINT64_FMTo__ -#define PRIo8 __UINT8_FMTo__ -#define PRIoFAST16 __UINT_FAST16_FMTo__ -#define PRIoFAST32 __UINT_FAST32_FMTo__ -#define PRIoFAST64 __UINT_FAST64_FMTo__ -#define PRIoFAST8 __UINT_FAST8_FMTo__ -#define PRIoLEAST16 __UINT_LEAST16_FMTo__ -#define PRIoLEAST32 __UINT_LEAST32_FMTo__ -#define PRIoLEAST64 __UINT_LEAST64_FMTo__ -#define PRIoLEAST8 __UINT_LEAST8_FMTo__ -#define PRIoMAX __UINTMAX_FMTo__ -#define PRIoPTR __UINTPTR_FMTo__ -#define PRIu16 __UINT16_FMTu__ -#define PRIu32 __UINT32_FMTu__ -#define PRIu64 __UINT64_FMTu__ -#define PRIu8 __UINT8_FMTu__ -#define PRIuFAST16 __UINT_FAST16_FMTu__ -#define PRIuFAST32 __UINT_FAST32_FMTu__ -#define PRIuFAST64 __UINT_FAST64_FMTu__ -#define PRIuFAST8 __UINT_FAST8_FMTu__ -#define PRIuLEAST16 __UINT_LEAST16_FMTu__ -#define PRIuLEAST32 __UINT_LEAST32_FMTu__ -#define PRIuLEAST64 __UINT_LEAST64_FMTu__ -#define PRIuLEAST8 __UINT_LEAST8_FMTu__ -#define PRIuMAX __UINTMAX_FMTu__ -#define PRIuPTR __UINTPTR_FMTu__ -#define PRIx16 __UINT16_FMTx__ -#define PRIx32 __UINT32_FMTx__ -#define PRIx64 __UINT64_FMTx__ -#define PRIx8 __UINT8_FMTx__ -#define PRIxFAST16 __UINT_FAST16_FMTx__ -#define PRIxFAST32 __UINT_FAST32_FMTx__ -#define PRIxFAST64 __UINT_FAST64_FMTx__ -#define PRIxFAST8 __UINT_FAST8_FMTx__ -#define PRIxLEAST16 __UINT_LEAST16_FMTx__ -#define PRIxLEAST32 __UINT_LEAST32_FMTx__ -#define PRIxLEAST64 __UINT_LEAST64_FMTx__ -#define PRIxLEAST8 __UINT_LEAST8_FMTx__ -#define PRIxMAX __UINTMAX_FMTx__ -#define PRIxPTR __UINTPTR_FMTx__ -#define PTRBITS (sizeof(char *) * 8) -#define PTRDIFF_MAX INT32_MAX -#define PTRDIFF_MIN INT32_MIN -#define PUTLONG NS_PUT32 -#define PUTSHORT NS_PUT16 -#define QFIXEDSZ NS_QFIXEDSZ -#define QUERY ns_o_query -#define RADIXCHAR 0x10000 -#define RAND_MAX (0x7fffffff) -#define REC_EOF '\002' -#define REC_EOR '\001' -#define REC_ESC '\377' -#define REFUSED ns_r_refused -#define REGTYPE '0' -#define REG_BADBR 10 -#define REG_BADPAT 2 -#define REG_BADRPT 13 -#define REG_EBRACE 9 -#define REG_EBRACK 7 -#define REG_ECOLLATE 3 -#define REG_ECTYPE 4 -#define REG_EESCAPE 5 -#define REG_ENOSYS -1 -#define REG_EPAREN 8 -#define REG_ERANGE 11 -#define REG_ESPACE 12 -#define REG_ESUBREG 6 -#define REG_EXTENDED 1 -#define REG_ICASE 2 -#define REG_NEWLINE 4 -#define REG_NOMATCH 1 -#define REG_NOSUB 8 -#define REG_NOTBOL 1 -#define REG_NOTEOL 2 -#define REG_OK 0 -#define RE_DUP_MAX 255 -#define RMSGD 0x0001 -#define RMSGN 0x0002 -#define RNORM 0x0000 -#define RPM_PCO_ADD 1 -#define RPM_PCO_CHANGE 2 -#define RPM_PCO_SETGLOBAL 3 -#define RPROTDAT 0x0004 -#define RPROTDIS 0x0008 -#define RPROTMASK 0x001C -#define RPROTNORM 0x0010 -#define RRFIXEDSZ NS_RRFIXEDSZ -#define RRQ 01 -#define RS_HIPRI 0x01 -#define RTLD_DEFAULT ((void *)0) -#define RTLD_GLOBAL 256 -#define RTLD_LAZY 1 -#define RTLD_LOCAL 8 -#define RTLD_NEXT ((void *)-1) -#define RTLD_NODELETE 4096 -#define RTLD_NOLOAD 4 -#define RTLD_NOW 2 -#define RUSAGE_CHILDREN 2 -#define RUSAGE_SELF 1 -#define R_OK (4) -#define SARMAG 8 -#define SB 250 -#define SCHAR_MAX 127 -#define SCHAR_MIN (-128) -#define SCNd16 __INT16_FMTd__ -#define SCNd32 __INT32_FMTd__ -#define SCNd64 __INT64_FMTd__ -#define SCNd8 __INT8_FMTd__ -#define SCNdFAST16 __INT_FAST16_FMTd__ -#define SCNdFAST32 __INT_FAST32_FMTd__ -#define SCNdFAST64 __INT_FAST64_FMTd__ -#define SCNdFAST8 __INT_FAST8_FMTd__ -#define SCNdLEAST16 __INT_LEAST16_FMTd__ -#define SCNdLEAST32 __INT_LEAST32_FMTd__ -#define SCNdLEAST64 __INT_LEAST64_FMTd__ -#define SCNdLEAST8 __INT_LEAST8_FMTd__ -#define SCNdMAX __INTMAX_FMTd__ -#define SCNdPTR __INTPTR_FMTd__ -#define SCNi16 __INT16_FMTi__ -#define SCNi32 __INT32_FMTi__ -#define SCNi64 __INT64_FMTi__ -#define SCNi8 __INT8_FMTi__ -#define SCNiFAST16 __INT_FAST16_FMTi__ -#define SCNiFAST32 __INT_FAST32_FMTi__ -#define SCNiFAST64 __INT_FAST64_FMTi__ -#define SCNiFAST8 __INT_FAST8_FMTi__ -#define SCNiLEAST16 __INT_LEAST16_FMTi__ -#define SCNiLEAST32 __INT_LEAST32_FMTi__ -#define SCNiLEAST64 __INT_LEAST64_FMTi__ -#define SCNiLEAST8 __INT_LEAST8_FMTi__ -#define SCNiMAX __INTMAX_FMTi__ -#define SCNiPTR __INTPTR_FMTi__ -#define SCNo16 __UINT16_FMTo__ -#define SCNo32 __UINT32_FMTo__ -#define SCNo64 __UINT64_FMTo__ -#define SCNo8 __UINT8_FMTo__ -#define SCNoFAST16 __UINT_FAST16_FMTo__ -#define SCNoFAST32 __UINT_FAST32_FMTo__ -#define SCNoFAST64 __UINT_FAST64_FMTo__ -#define SCNoFAST8 __UINT_FAST8_FMTo__ -#define SCNoLEAST16 __UINT_LEAST16_FMTo__ -#define SCNoLEAST32 __UINT_LEAST32_FMTo__ -#define SCNoLEAST64 __UINT_LEAST64_FMTo__ -#define SCNoLEAST8 __UINT_LEAST8_FMTo__ -#define SCNoMAX __UINTMAX_FMTo__ -#define SCNoPTR __UINTPTR_FMTo__ -#define SCNu16 __UINT16_FMTu__ -#define SCNu32 __UINT32_FMTu__ -#define SCNu64 __UINT64_FMTu__ -#define SCNu8 __UINT8_FMTu__ -#define SCNuFAST16 __UINT_FAST16_FMTu__ -#define SCNuFAST32 __UINT_FAST32_FMTu__ -#define SCNuFAST64 __UINT_FAST64_FMTu__ -#define SCNuFAST8 __UINT_FAST8_FMTu__ -#define SCNuLEAST16 __UINT_LEAST16_FMTu__ -#define SCNuLEAST32 __UINT_LEAST32_FMTu__ -#define SCNuLEAST64 __UINT_LEAST64_FMTu__ -#define SCNuLEAST8 __UINT_LEAST8_FMTu__ -#define SCNuMAX __UINTMAX_FMTu__ -#define SCNuPTR __UINTPTR_FMTu__ -#define SCNx16 __UINT16_FMTx__ -#define SCNx32 __UINT32_FMTx__ -#define SCNx64 __UINT64_FMTx__ -#define SCNx8 __UINT8_FMTx__ -#define SCNxFAST16 __UINT_FAST16_FMTx__ -#define SCNxFAST32 __UINT_FAST32_FMTx__ -#define SCNxFAST64 __UINT_FAST64_FMTx__ -#define SCNxFAST8 __UINT_FAST8_FMTx__ -#define SCNxLEAST16 __UINT_LEAST16_FMTx__ -#define SCNxLEAST32 __UINT_LEAST32_FMTx__ -#define SCNxLEAST64 __UINT_LEAST64_FMTx__ -#define SCNxLEAST8 __UINT_LEAST8_FMTx__ -#define SCNxMAX __UINTMAX_FMTx__ -#define SCNxPTR __UINTPTR_FMTx__ -#define SE 240 -#define SEEK_CUR __WASI_WHENCE_CUR -#define SEEK_END __WASI_WHENCE_END -#define SEEK_SET __WASI_WHENCE_SET -#define SEGSIZE 512 -#define SEM_FAILED ((sem_t *)0) -#define SERVFAIL ns_r_servfail -#define SHORTBITS (sizeof(short) * 8) -#define SHRT_MAX 0x7fff -#define SHRT_MIN (-1-0x7fff) -#define SHUT_RD __WASI_SDFLAGS_RD -#define SHUT_RDWR (SHUT_RD | SHUT_WR) -#define SHUT_WR __WASI_SDFLAGS_WR -#define SIG_ATOMIC_MAX INT32_MAX -#define SIG_ATOMIC_MIN INT32_MIN -#define SIZE_MAX UINT32_MAX -#define SI_LOAD_SHIFT 16 -#define SLC_ABORT 7 -#define SLC_ACK 0x80 -#define SLC_AO 4 -#define SLC_AYT 5 -#define SLC_BRK 2 -#define SLC_CANTCHANGE 1 -#define SLC_DEFAULT 3 -#define SLC_EC 10 -#define SLC_EL 11 -#define SLC_EOF 8 -#define SLC_EOR 6 -#define SLC_EW 12 -#define SLC_FLAGS 1 -#define SLC_FLUSHIN 0x40 -#define SLC_FLUSHOUT 0x20 -#define SLC_FORW1 17 -#define SLC_FORW2 18 -#define SLC_FUNC 0 -#define SLC_IP 3 -#define SLC_LEVELBITS 0x03 -#define SLC_LNEXT 14 -#define SLC_NAME(x) slc_names[x] -#define SLC_NAMELIST "0", "SYNCH", "BRK", "IP", "AO", "AYT", "EOR", "ABORT", "EOF", "SUSP", "EC", "EL", "EW", "RP", "LNEXT", "XON", "XOFF", "FORW1", "FORW2", 0, -#define SLC_NAMES SLC_NAMELIST -#define SLC_NAME_OK(x) ((unsigned int)(x) <= NSLC) -#define SLC_NOSUPPORT 0 -#define SLC_RP 13 -#define SLC_SUSP 9 -#define SLC_SYNCH 1 -#define SLC_VALUE 2 -#define SLC_VARIABLE 2 -#define SLC_XOFF 16 -#define SLC_XON 15 -#define SNDPIPE 0x002 -#define SNDZERO 0x001 -#define SOCK_CLOEXEC (0x00002000) -#define SOCK_DGRAM __WASI_FILETYPE_SOCKET_DGRAM -#define SOCK_NONBLOCK (0x00004000) -#define SOCK_STREAM __WASI_FILETYPE_SOCKET_STREAM -#define SOL_SOCKET 0x7fffffff -#define SOL_TCP 6 -#define SOL_UDP 17 -#define SO_TYPE 3 -#define SSIZE_MAX LONG_MAX -#define STATUS ns_o_status -#define STA_CLK 0x8000 -#define STA_CLOCKERR 0x1000 -#define STA_DEL 0x0020 -#define STA_FLL 0x0008 -#define STA_FREQHOLD 0x0080 -#define STA_INS 0x0010 -#define STA_MODE 0x4000 -#define STA_NANO 0x2000 -#define STA_PLL 0x0001 -#define STA_PPSERROR 0x0800 -#define STA_PPSFREQ 0x0002 -#define STA_PPSJITTER 0x0200 -#define STA_PPSSIGNAL 0x0100 -#define STA_PPSTIME 0x0004 -#define STA_PPSWANDER 0x0400 -#define STA_RONLY (STA_PPSSIGNAL | STA_PPSJITTER | STA_PPSWANDER | STA_PPSERROR | STA_CLOCKERR | STA_NANO | STA_MODE | STA_CLK) -#define STA_UNSYNC 0x0040 -#define STDERR_FILENO 2 -#define STDIN_FILENO 0 -#define STDOUT_FILENO 1 -#define STRU_F 1 -#define STRU_P 3 -#define STRU_R 2 -#define SUN_LEN(s) (2+strlen((s)->sun_path)) -#define SUSP 237 -#define SYMLOOP_MAX 40 -#define SYMTYPE '2' -#define SYNCH 242 -#define S_ADDT ns_s_ar -#define S_BANDURG 0x0200 -#define S_ERROR 0x0010 -#define S_HANGUP 0x0020 -#define S_HIPRI 0x0002 -#define S_IEXEC S_IXUSR -#define S_IFBLK (0x6000) -#define S_IFCHR (0x2000) -#define S_IFDIR (0x4000) -#define S_IFIFO (0xc000) -#define S_IFLNK (0xa000) -#define S_IFMT (S_IFBLK | S_IFCHR | S_IFDIR | S_IFIFO | S_IFLNK | S_IFREG | S_IFSOCK) -#define S_IFREG (0x8000) -#define S_IFSOCK (0xc000) -#define S_INPUT 0x0001 -#define S_IREAD S_IRUSR -#define S_IRGRP (0x20) -#define S_IROTH (0x4) -#define S_IRUSR (0x100) -#define S_IRWXG (S_IXGRP | S_IWGRP | S_IRGRP) -#define S_IRWXO (S_IXOTH | S_IWOTH | S_IROTH) -#define S_IRWXU (S_IXUSR | S_IWUSR | S_IRUSR) -#define S_ISBLK(m) (((m)&S_IFMT) == S_IFBLK) -#define S_ISCHR(m) (((m)&S_IFMT) == S_IFCHR) -#define S_ISDIR(m) (((m)&S_IFMT) == S_IFDIR) -#define S_ISFIFO(m) (((m)&S_IFMT) == S_IFIFO) -#define S_ISGID (0x400) -#define S_ISLNK(m) (((m)&S_IFMT) == S_IFLNK) -#define S_ISREG(m) (((m)&S_IFMT) == S_IFREG) -#define S_ISSOCK(m) (((m)&S_IFMT) == S_IFSOCK) -#define S_ISUID (0x800) -#define S_ISVTX (0x200) -#define S_IWGRP (0x10) -#define S_IWOTH (0x2) -#define S_IWRITE S_IWUSR -#define S_IWUSR (0x80) -#define S_IXGRP (0x8) -#define S_IXOTH (0x1) -#define S_IXUSR (0x40) -#define S_MSG 0x0008 -#define S_OUTPUT 0x0004 -#define S_PREREQ ns_s_pr -#define S_RDBAND 0x0080 -#define S_RDNORM 0x0040 -#define S_UPDATE ns_s_ud -#define S_WRBAND 0x0100 -#define S_WRNORM S_OUTPUT -#define S_ZONE ns_s_zn -#define TCPI_OPT_ECN 8 -#define TCPI_OPT_SACK 2 -#define TCPI_OPT_TIMESTAMPS 1 -#define TCPI_OPT_WSCALE 4 -#define TCPOLEN_MAXSEG 4 -#define TCPOLEN_SACK_PERMITTED 2 -#define TCPOLEN_TIMESTAMP 10 -#define TCPOLEN_WINDOW 3 -#define TCPOPT_EOL 0 -#define TCPOPT_MAXSEG 2 -#define TCPOPT_NOP 1 -#define TCPOPT_SACK 5 -#define TCPOPT_SACK_PERMITTED 4 -#define TCPOPT_TIMESTAMP 8 -#define TCPOPT_WINDOW 3 -#define TCP_CA_CWR 2 -#define TCP_CA_Disorder 1 -#define TCP_CA_Loss 4 -#define TCP_CA_Open 0 -#define TCP_CA_Recovery 3 -#define TCP_CC_INFO 26 -#define TCP_CLOSE 7 -#define TCP_CLOSE_WAIT 8 -#define TCP_CLOSING 11 -#define TCP_CM_INQ TCP_INQ -#define TCP_CONGESTION 13 -#define TCP_CORK 3 -#define TCP_DEFER_ACCEPT 9 -#define TCP_ENCAP_ESPINTCP 7 -#define TCP_ESTABLISHED 1 -#define TCP_FASTOPEN 23 -#define TCP_FASTOPEN_CONNECT 30 -#define TCP_FASTOPEN_KEY 33 -#define TCP_FASTOPEN_NO_COOKIE 34 -#define TCP_FIN_WAIT1 4 -#define TCP_FIN_WAIT2 5 -#define TCP_INFO 11 -#define TCP_INQ 36 -#define TCP_KEEPCNT 6 -#define TCP_KEEPIDLE 4 -#define TCP_KEEPINTVL 5 -#define TCP_LAST_ACK 9 -#define TCP_LINGER2 8 -#define TCP_LISTEN 10 -#define TCP_MAXSEG 2 -#define TCP_MD5SIG 14 -#define TCP_MD5SIG_EXT 32 -#define TCP_MD5SIG_FLAG_IFINDEX 0x2 -#define TCP_MD5SIG_FLAG_PREFIX 0x1 -#define TCP_MD5SIG_MAXKEYLEN 80 -#define TCP_NODELAY 1 -#define TCP_NOTSENT_LOWAT 25 -#define TCP_QUEUE_SEQ 21 -#define TCP_QUICKACK 12 -#define TCP_RECEIVE_ZEROCOPY_FLAG_TLB_CLEAN_HINT 0x1 -#define TCP_REPAIR 19 -#define TCP_REPAIR_OFF 0 -#define TCP_REPAIR_OFF_NO_WP -1 -#define TCP_REPAIR_ON 1 -#define TCP_REPAIR_OPTIONS 22 -#define TCP_REPAIR_QUEUE 20 -#define TCP_REPAIR_WINDOW 29 -#define TCP_SAVED_SYN 28 -#define TCP_SAVE_SYN 27 -#define TCP_SYNCNT 7 -#define TCP_SYN_RECV 3 -#define TCP_SYN_SENT 2 -#define TCP_THIN_DUPACK 17 -#define TCP_THIN_LINEAR_TIMEOUTS 16 -#define TCP_TIMESTAMP 24 -#define TCP_TIME_WAIT 6 -#define TCP_TX_DELAY 37 -#define TCP_ULP 31 -#define TCP_USER_TIMEOUT 18 -#define TCP_WINDOW_CLAMP 10 -#define TCP_ZEROCOPY_RECEIVE 35 -#define TELCMD(x) telcmds[(x)-TELCMD_FIRST] -#define TELCMD_FIRST xEOF -#define TELCMD_LAST IAC -#define TELCMD_OK(x) ((unsigned int)(x) <= TELCMD_LAST && (unsigned int)(x) >= TELCMD_FIRST) -#define TELOPT_3270REGIME 29 -#define TELOPT_AUTHENTICATION 37 -#define TELOPT_BINARY 0 -#define TELOPT_BM 19 -#define TELOPT_DET 20 -#define TELOPT_ECHO 1 -#define TELOPT_ENCRYPT 38 -#define TELOPT_EOR 25 -#define TELOPT_EXOPL 255 -#define TELOPT_LFLOW 33 -#define TELOPT_LINEMODE 34 -#define TELOPT_LOGOUT 18 -#define TELOPT_NAMS 4 -#define TELOPT_NAOCRD 10 -#define TELOPT_NAOFFD 13 -#define TELOPT_NAOHTD 12 -#define TELOPT_NAOHTS 11 -#define TELOPT_NAOL 8 -#define TELOPT_NAOLFD 16 -#define TELOPT_NAOP 9 -#define TELOPT_NAOVTD 15 -#define TELOPT_NAOVTS 14 -#define TELOPT_NAWS 31 -#define TELOPT_NEW_ENVIRON 39 -#define TELOPT_OLD_ENVIRON 36 -#define TELOPT_OUTMRK 27 -#define TELOPT_RCP 2 -#define TELOPT_RCTE 7 -#define TELOPT_SGA 3 -#define TELOPT_SNDLOC 23 -#define TELOPT_STATUS 5 -#define TELOPT_SUPDUP 21 -#define TELOPT_SUPDUPOUTPUT 22 -#define TELOPT_TM 6 -#define TELOPT_TSPEED 32 -#define TELOPT_TTYLOC 28 -#define TELOPT_TTYPE 24 -#define TELOPT_TUID 26 -#define TELOPT_X3PAD 30 -#define TELOPT_XASCII 17 -#define TELOPT_XDISPLOC 35 -#define TELQUAL_INFO 2 -#define TELQUAL_IS 0 -#define TELQUAL_NAME 3 -#define TELQUAL_REPLY 2 -#define TELQUAL_SEND 1 -#define TGEXEC 00010 -#define TGREAD 00040 -#define TGWRITE 00020 -#define THOUSEP 0x10001 -#define TH_ACK 0x10 -#define TH_FIN 0x01 -#define TH_PUSH 0x08 -#define TH_RST 0x04 -#define TH_SYN 0x02 -#define TH_URG 0x20 -#define TIMER_ABSTIME __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME -#define TIMESPEC_TO_TIMEVAL(tv,ts) ( (tv)->tv_sec = (ts)->tv_sec, (tv)->tv_usec = (ts)->tv_nsec / 1000, (void)0 ) -#define TIMEVAL_TO_TIMESPEC(tv,ts) ( (ts)->tv_sec = (tv)->tv_sec, (ts)->tv_nsec = (tv)->tv_usec * 1000, (void)0 ) -#define TIME_BAD TIME_ERROR -#define TIME_DEL 2 -#define TIME_ERROR 5 -#define TIME_INS 1 -#define TIME_OK 0 -#define TIME_OOP 3 -#define TIME_UTC 1 -#define TIME_WAIT 4 -#define TMAGIC "ustar" -#define TMAGLEN 6 -#define TOEXEC 00001 -#define TOREAD 00004 -#define TOWRITE 00002 -#define TRANSIENT 4 -#define TSGID 02000 -#define TSS_DTOR_ITERATIONS 4 -#define TSUID 04000 -#define TSVTX 01000 -#define TTYDEF_CFLAG (CREAD | CS7 | PARENB | HUPCL) -#define TTYDEF_IFLAG (BRKINT | ISTRIP | ICRNL | IMAXBEL | IXON | IXANY) -#define TTYDEF_LFLAG (ECHO | ICANON | ISIG | IEXTEN | ECHOE|ECHOKE|ECHOCTL) -#define TTYDEF_OFLAG (OPOST | ONLCR | XTABS) -#define TTYDEF_SPEED (B9600) -#define TTY_NAME_MAX 32 -#define TUEXEC 00100 -#define TUREAD 00400 -#define TUWRITE 00200 -#define TVERSION "00" -#define TVERSLEN 2 -#define TYPE_A 1 -#define TYPE_E 2 -#define TYPE_I 3 -#define TYPE_L 4 -#define TZNAME_MAX 6 -#define T_A ns_t_a -#define T_A6 ns_t_a6 -#define T_AAAA ns_t_aaaa -#define T_AFSDB ns_t_afsdb -#define T_ANY ns_t_any -#define T_ATMA ns_t_atma -#define T_AXFR ns_t_axfr -#define T_CNAME ns_t_cname -#define T_DNAME ns_t_dname -#define T_EID ns_t_eid -#define T_FMT 0x2002A -#define T_FMT_AMPM 0x2002B -#define T_GPOS ns_t_gpos -#define T_HINFO ns_t_hinfo -#define T_ISDN ns_t_isdn -#define T_IXFR ns_t_ixfr -#define T_KEY ns_t_key -#define T_LOC ns_t_loc -#define T_MAILA ns_t_maila -#define T_MAILB ns_t_mailb -#define T_MB ns_t_mb -#define T_MD ns_t_md -#define T_MF ns_t_mf -#define T_MG ns_t_mg -#define T_MINFO ns_t_minfo -#define T_MR ns_t_mr -#define T_MX ns_t_mx -#define T_NAPTR ns_t_naptr -#define T_NIMLOC ns_t_nimloc -#define T_NS ns_t_ns -#define T_NSAP ns_t_nsap -#define T_NSAP_PTR ns_t_nsap_ptr -#define T_NULL ns_t_null -#define T_NXT ns_t_nxt -#define T_PTR ns_t_ptr -#define T_PX ns_t_px -#define T_RP ns_t_rp -#define T_RT ns_t_rt -#define T_SIG ns_t_sig -#define T_SOA ns_t_soa -#define T_SRV ns_t_srv -#define T_TSIG ns_t_tsig -#define T_TXT ns_t_txt -#define T_WKS ns_t_wks -#define T_X25 ns_t_x25 -#define UCHAR_MAX 255 -#define UDP_CORK 1 -#define UDP_ENCAP 100 -#define UDP_ENCAP_ESPINUDP 2 -#define UDP_ENCAP_ESPINUDP_NON_IKE 1 -#define UDP_ENCAP_GTP0 4 -#define UDP_ENCAP_GTP1U 5 -#define UDP_ENCAP_L2TPINUDP 3 -#define UDP_ENCAP_RXRPC 6 -#define UDP_GRO 104 -#define UDP_NO_CHECK6_RX 102 -#define UDP_NO_CHECK6_TX 101 -#define UDP_SEGMENT 103 -#define UINT16_C(c) c -#define UINT16_MAX (0xffff) -#define UINT32_C(c) c ## U -#define UINT32_MAX (0xffffffffu) -#define UINT64_C(c) c ## ULL -#define UINT64_MAX (0xffffffffffffffffu) -#define UINT8_C(c) c -#define UINT8_MAX (0xff) -#define UINTMAX_C(c) c ## ULL -#define UINTMAX_MAX UINT64_MAX -#define UINTPTR_MAX UINT32_MAX -#define UINT_FAST16_MAX UINT16_MAX -#define UINT_FAST32_MAX UINT32_MAX -#define UINT_FAST64_MAX UINT64_MAX -#define UINT_FAST8_MAX UINT8_MAX -#define UINT_LEAST16_MAX UINT16_MAX -#define UINT_LEAST32_MAX UINT32_MAX -#define UINT_LEAST64_MAX UINT64_MAX -#define UINT_LEAST8_MAX UINT8_MAX -#define UINT_MAX 0xffffffffU -#define UIO_MAXIOV 1024 -#define ULLONG_MAX (2ULL*LLONG_MAX+1) -#define ULONG_MAX (2UL*LONG_MAX+1) -#define USHRT_MAX 0xffff -#define UTIME_NOW (-1) -#define UTIME_OMIT (-2) -#define WCHAR_MAX (0x7fffffff+L'\0') -#define WCHAR_MIN (-1-0x7fffffff+L'\0') -#define WEOF 0xffffffffU -#define WILL 251 -#define WINT_MAX UINT32_MAX -#define WINT_MIN 0U -#define WONT 252 -#define WORD_BIT 32 -#define WRQ 02 -#define W_OK (2) -#define X_OK (1) -#define YESEXPR 0x50000 -#define YESSTR 0x50002 -#define YXDOMAIN ns_r_yxdomain -#define YXRRSET ns_r_yxrrset -#define _ALLOCA_H -#define _ALL_SOURCE 1 -#define _ARPA_FTP_H -#define _ARPA_INET_H -#define _ARPA_NAMESER_H -#define _ARPA_TELNET_H -#define _ARPA_TFTP_H -#define _AR_H -#define _BYTESWAP_H -#define _COMPLEX_H -#define _CPIO_H -#define _CRYPT_H -#define _CS_GNU_LIBC_VERSION 2 -#define _CS_GNU_LIBPTHREAD_VERSION 3 -#define _CS_PATH 0 -#define _CS_POSIX_V5_WIDTH_RESTRICTED_ENVS 4 -#define _CS_POSIX_V6_ILP32_OFF32_CFLAGS 1116 -#define _CS_POSIX_V6_ILP32_OFF32_LDFLAGS 1117 -#define _CS_POSIX_V6_ILP32_OFF32_LIBS 1118 -#define _CS_POSIX_V6_ILP32_OFF32_LINTFLAGS 1119 -#define _CS_POSIX_V6_ILP32_OFFBIG_CFLAGS 1120 -#define _CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS 1121 -#define _CS_POSIX_V6_ILP32_OFFBIG_LIBS 1122 -#define _CS_POSIX_V6_ILP32_OFFBIG_LINTFLAGS 1123 -#define _CS_POSIX_V6_LP64_OFF64_CFLAGS 1124 -#define _CS_POSIX_V6_LP64_OFF64_LDFLAGS 1125 -#define _CS_POSIX_V6_LP64_OFF64_LIBS 1126 -#define _CS_POSIX_V6_LP64_OFF64_LINTFLAGS 1127 -#define _CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS 1128 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS 1129 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LIBS 1130 -#define _CS_POSIX_V6_LPBIG_OFFBIG_LINTFLAGS 1131 -#define _CS_POSIX_V6_WIDTH_RESTRICTED_ENVS 1 -#define _CS_POSIX_V7_ILP32_OFF32_CFLAGS 1132 -#define _CS_POSIX_V7_ILP32_OFF32_LDFLAGS 1133 -#define _CS_POSIX_V7_ILP32_OFF32_LIBS 1134 -#define _CS_POSIX_V7_ILP32_OFF32_LINTFLAGS 1135 -#define _CS_POSIX_V7_ILP32_OFFBIG_CFLAGS 1136 -#define _CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS 1137 -#define _CS_POSIX_V7_ILP32_OFFBIG_LIBS 1138 -#define _CS_POSIX_V7_ILP32_OFFBIG_LINTFLAGS 1139 -#define _CS_POSIX_V7_LP64_OFF64_CFLAGS 1140 -#define _CS_POSIX_V7_LP64_OFF64_LDFLAGS 1141 -#define _CS_POSIX_V7_LP64_OFF64_LIBS 1142 -#define _CS_POSIX_V7_LP64_OFF64_LINTFLAGS 1143 -#define _CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS 1144 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS 1145 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LIBS 1146 -#define _CS_POSIX_V7_LPBIG_OFFBIG_LINTFLAGS 1147 -#define _CS_POSIX_V7_WIDTH_RESTRICTED_ENVS 5 -#define _CS_V6_ENV 1148 -#define _CS_V7_ENV 1149 -#define _CTYPE_H -#define _Complex_I (0.0f+1.0fi) -#define _DIRENT_H -#define _DIRENT_HAVE_D_TYPE -#define _DLFCN_H -#define _ENDIAN_H -#define _ERRNO_H -#define _ERR_H -#define _FCNTL_H -#define _FEATURES_H -#define _FENV_H -#define _FLOAT_H -#define _FMTMSG_H -#define _FNMATCH_H -#define _FTW_H -#define _GETOPT_H -#define _GLOB_H -#define _GNU_SOURCE 1 -#define _ICONV_H -#define _IFADDRS_H -#define _INTTYPES_H -#define _IOFBF 0 -#define _IOLBF 1 -#define _IONBF 2 -#define _ISO646_H -#define _LANGINFO_H -#define _LIBGEN_H -#define _LIMITS_H -#define _LOCALE_H -#define _LP64 1 -#define _MALLOC_H -#define _MATH_H -#define _MONETARY_H -#define _MQUEUE_H -#define _NETINET_ICMP6_H -#define _NETINET_IGMP_H -#define _NETINET_IN_H -#define _NETINET_IN_SYSTM_H -#define _NETINET_IP6_H -#define _NETINET_IP_H -#define _NETINET_IP_ICMP_H -#define _NETINET_TCP_H -#define _NETINET_UDP_H -#define _NETPACKET_PACKET_H -#define _NL_LOCALE_NAME(cat) (((cat)<<16) | 0xffff) -#define _NL_TYPES_H -#define _PC_2_SYMLINKS 20 -#define _PC_ALLOC_SIZE_MIN 18 -#define _PC_ASYNC_IO 10 -#define _PC_CHOWN_RESTRICTED 6 -#define _PC_FILESIZEBITS 13 -#define _PC_LINK_MAX 0 -#define _PC_MAX_CANON 1 -#define _PC_MAX_INPUT 2 -#define _PC_NAME_MAX 3 -#define _PC_NO_TRUNC 7 -#define _PC_PATH_MAX 4 -#define _PC_PIPE_BUF 5 -#define _PC_PRIO_IO 11 -#define _PC_REC_INCR_XFER_SIZE 14 -#define _PC_REC_MAX_XFER_SIZE 15 -#define _PC_REC_MIN_XFER_SIZE 16 -#define _PC_REC_XFER_ALIGN 17 -#define _PC_SOCK_MAXBUF 12 -#define _PC_SYMLINK_MAX 19 -#define _PC_SYNC_IO 9 -#define _PC_VDISABLE 8 -#define _POLL_H -#define _POSIX2_BC_BASE_MAX 99 -#define _POSIX2_BC_DIM_MAX 2048 -#define _POSIX2_BC_SCALE_MAX 99 -#define _POSIX2_BC_STRING_MAX 1000 -#define _POSIX2_CHARCLASS_NAME_MAX 14 -#define _POSIX2_COLL_WEIGHTS_MAX 2 -#define _POSIX2_C_BIND _POSIX_VERSION -#define _POSIX2_EXPR_NEST_MAX 32 -#define _POSIX2_LINE_MAX 2048 -#define _POSIX2_RE_DUP_MAX 255 -#define _POSIX2_VERSION _POSIX_VERSION -#define _POSIX_ADVISORY_INFO _POSIX_VERSION -#define _POSIX_AIO_LISTIO_MAX 2 -#define _POSIX_AIO_MAX 1 -#define _POSIX_ARG_MAX 4096 -#define _POSIX_BARRIERS _POSIX_VERSION -#define _POSIX_CHILD_MAX 25 -#define _POSIX_CHOWN_RESTRICTED 1 -#define _POSIX_CLOCKRES_MIN 20000000 -#define _POSIX_CLOCK_SELECTION _POSIX_VERSION -#define _POSIX_CPUTIME _POSIX_VERSION -#define _POSIX_DELAYTIMER_MAX 32 -#define _POSIX_FSYNC _POSIX_VERSION -#define _POSIX_HOST_NAME_MAX 255 -#define _POSIX_IPV6 _POSIX_VERSION -#define _POSIX_LINK_MAX 8 -#define _POSIX_LOGIN_NAME_MAX 9 -#define _POSIX_MAX_CANON 255 -#define _POSIX_MAX_INPUT 255 -#define _POSIX_MONOTONIC_CLOCK _POSIX_VERSION -#define _POSIX_MQ_OPEN_MAX 8 -#define _POSIX_MQ_PRIO_MAX 32 -#define _POSIX_NAME_MAX 14 -#define _POSIX_NGROUPS_MAX 8 -#define _POSIX_NO_TRUNC 1 -#define _POSIX_OPEN_MAX 20 -#define _POSIX_PATH_MAX 256 -#define _POSIX_PIPE_BUF 512 -#define _POSIX_READER_WRITER_LOCKS _POSIX_VERSION -#define _POSIX_REALTIME_SIGNALS _POSIX_VERSION -#define _POSIX_REGEXP 1 -#define _POSIX_RE_DUP_MAX 255 -#define _POSIX_RTSIG_MAX 8 -#define _POSIX_SEM_NSEMS_MAX 256 -#define _POSIX_SEM_VALUE_MAX 32767 -#define _POSIX_SIGQUEUE_MAX 32 -#define _POSIX_SPIN_LOCKS _POSIX_VERSION -#define _POSIX_SSIZE_MAX 32767 -#define _POSIX_SS_REPL_MAX 4 -#define _POSIX_STREAM_MAX 8 -#define _POSIX_SYMLINK_MAX 255 -#define _POSIX_SYMLOOP_MAX 8 -#define _POSIX_THREAD_ATTR_STACKADDR _POSIX_VERSION -#define _POSIX_THREAD_ATTR_STACKSIZE _POSIX_VERSION -#define _POSIX_THREAD_CPUTIME _POSIX_VERSION -#define _POSIX_THREAD_DESTRUCTOR_ITERATIONS 4 -#define _POSIX_THREAD_KEYS_MAX 128 -#define _POSIX_THREAD_PRIORITY_SCHEDULING _POSIX_VERSION -#define _POSIX_THREAD_PROCESS_SHARED _POSIX_VERSION -#define _POSIX_THREAD_SAFE_FUNCTIONS _POSIX_VERSION -#define _POSIX_THREAD_THREADS_MAX 64 -#define _POSIX_TIMEOUTS _POSIX_VERSION -#define _POSIX_TIMERS _POSIX_VERSION -#define _POSIX_TIMER_MAX 32 -#define _POSIX_TRACE_EVENT_NAME_MAX 30 -#define _POSIX_TRACE_NAME_MAX 8 -#define _POSIX_TRACE_SYS_MAX 8 -#define _POSIX_TRACE_USER_EVENT_MAX 32 -#define _POSIX_TTY_NAME_MAX 9 -#define _POSIX_TZNAME_MAX 6 -#define _POSIX_V6_ILP32_OFFBIG (1) -#define _POSIX_V7_ILP32_OFFBIG (1) -#define _POSIX_VDISABLE 0 -#define _POSIX_VERSION 200809L -#define _PTRDIFF_T -#define _REGEX_H -#define _SCHED_H -#define _SC_2_CHAR_TERM 95 -#define _SC_2_C_BIND 47 -#define _SC_2_C_DEV 48 -#define _SC_2_FORT_DEV 49 -#define _SC_2_FORT_RUN 50 -#define _SC_2_LOCALEDEF 52 -#define _SC_2_PBS 168 -#define _SC_2_PBS_ACCOUNTING 169 -#define _SC_2_PBS_CHECKPOINT 175 -#define _SC_2_PBS_LOCATE 170 -#define _SC_2_PBS_MESSAGE 171 -#define _SC_2_PBS_TRACK 172 -#define _SC_2_SW_DEV 51 -#define _SC_2_UPE 97 -#define _SC_2_VERSION 46 -#define _SC_ADVISORY_INFO 132 -#define _SC_AIO_LISTIO_MAX 23 -#define _SC_AIO_MAX 24 -#define _SC_AIO_PRIO_DELTA_MAX 25 -#define _SC_ARG_MAX 0 -#define _SC_ASYNCHRONOUS_IO 12 -#define _SC_ATEXIT_MAX 87 -#define _SC_AVPHYS_PAGES 86 -#define _SC_BARRIERS 133 -#define _SC_BC_BASE_MAX 36 -#define _SC_BC_DIM_MAX 37 -#define _SC_BC_SCALE_MAX 38 -#define _SC_BC_STRING_MAX 39 -#define _SC_CHILD_MAX 1 -#define _SC_CLK_TCK 2 -#define _SC_CLOCK_SELECTION 137 -#define _SC_COLL_WEIGHTS_MAX 40 -#define _SC_CPUTIME 138 -#define _SC_DELAYTIMER_MAX 26 -#define _SC_EXPR_NEST_MAX 42 -#define _SC_FSYNC 15 -#define _SC_GETGR_R_SIZE_MAX 69 -#define _SC_GETPW_R_SIZE_MAX 70 -#define _SC_HOST_NAME_MAX 180 -#define _SC_IOV_MAX 60 -#define _SC_IPV6 235 -#define _SC_JOB_CONTROL 7 -#define _SC_LINE_MAX 43 -#define _SC_LOGIN_NAME_MAX 71 -#define _SC_MAPPED_FILES 16 -#define _SC_MEMLOCK 17 -#define _SC_MEMLOCK_RANGE 18 -#define _SC_MEMORY_PROTECTION 19 -#define _SC_MESSAGE_PASSING 20 -#define _SC_MONOTONIC_CLOCK 149 -#define _SC_MQ_OPEN_MAX 27 -#define _SC_MQ_PRIO_MAX 28 -#define _SC_NGROUPS_MAX 3 -#define _SC_NPROCESSORS_CONF 83 -#define _SC_NPROCESSORS_ONLN 84 -#define _SC_NZERO 109 -#define _SC_OPEN_MAX 4 -#define _SC_PAGESIZE 30 -#define _SC_PAGE_SIZE 30 -#define _SC_PASS_MAX 88 -#define _SC_PHYS_PAGES 85 -#define _SC_PRIORITIZED_IO 13 -#define _SC_PRIORITY_SCHEDULING 10 -#define _SC_RAW_SOCKETS 236 -#define _SC_READER_WRITER_LOCKS 153 -#define _SC_REALTIME_SIGNALS 9 -#define _SC_REGEXP 155 -#define _SC_RE_DUP_MAX 44 -#define _SC_RTSIG_MAX 31 -#define _SC_SAVED_IDS 8 -#define _SC_SEMAPHORES 21 -#define _SC_SEM_NSEMS_MAX 32 -#define _SC_SEM_VALUE_MAX 33 -#define _SC_SHARED_MEMORY_OBJECTS 22 -#define _SC_SHELL 157 -#define _SC_SIGQUEUE_MAX 34 -#define _SC_SPAWN 159 -#define _SC_SPIN_LOCKS 154 -#define _SC_SPORADIC_SERVER 160 -#define _SC_SS_REPL_MAX 241 -#define _SC_STREAMS 174 -#define _SC_STREAM_MAX 5 -#define _SC_SYMLOOP_MAX 173 -#define _SC_SYNCHRONIZED_IO 14 -#define _SC_THREADS 67 -#define _SC_THREAD_ATTR_STACKADDR 77 -#define _SC_THREAD_ATTR_STACKSIZE 78 -#define _SC_THREAD_CPUTIME 139 -#define _SC_THREAD_DESTRUCTOR_ITERATIONS 73 -#define _SC_THREAD_KEYS_MAX 74 -#define _SC_THREAD_PRIORITY_SCHEDULING 79 -#define _SC_THREAD_PRIO_INHERIT 80 -#define _SC_THREAD_PRIO_PROTECT 81 -#define _SC_THREAD_PROCESS_SHARED 82 -#define _SC_THREAD_ROBUST_PRIO_INHERIT 247 -#define _SC_THREAD_ROBUST_PRIO_PROTECT 248 -#define _SC_THREAD_SAFE_FUNCTIONS 68 -#define _SC_THREAD_SPORADIC_SERVER 161 -#define _SC_THREAD_STACK_MIN 75 -#define _SC_THREAD_THREADS_MAX 76 -#define _SC_TIMEOUTS 164 -#define _SC_TIMERS 11 -#define _SC_TIMER_MAX 35 -#define _SC_TRACE 181 -#define _SC_TRACE_EVENT_FILTER 182 -#define _SC_TRACE_EVENT_NAME_MAX 242 -#define _SC_TRACE_INHERIT 183 -#define _SC_TRACE_LOG 184 -#define _SC_TRACE_NAME_MAX 243 -#define _SC_TRACE_SYS_MAX 244 -#define _SC_TRACE_USER_EVENT_MAX 245 -#define _SC_TTY_NAME_MAX 72 -#define _SC_TYPED_MEMORY_OBJECTS 165 -#define _SC_TZNAME_MAX 6 -#define _SC_UIO_MAXIOV 60 -#define _SC_V6_ILP32_OFF32 176 -#define _SC_V6_ILP32_OFFBIG 177 -#define _SC_V6_LP64_OFF64 178 -#define _SC_V6_LPBIG_OFFBIG 179 -#define _SC_V7_ILP32_OFF32 237 -#define _SC_V7_ILP32_OFFBIG 238 -#define _SC_V7_LP64_OFF64 239 -#define _SC_V7_LPBIG_OFFBIG 240 -#define _SC_VERSION 29 -#define _SC_XBS5_ILP32_OFF32 125 -#define _SC_XBS5_ILP32_OFFBIG 126 -#define _SC_XBS5_LP64_OFF64 127 -#define _SC_XBS5_LPBIG_OFFBIG 128 -#define _SC_XOPEN_CRYPT 92 -#define _SC_XOPEN_ENH_I18N 93 -#define _SC_XOPEN_LEGACY 129 -#define _SC_XOPEN_REALTIME 130 -#define _SC_XOPEN_REALTIME_THREADS 131 -#define _SC_XOPEN_SHM 94 -#define _SC_XOPEN_STREAMS 246 -#define _SC_XOPEN_UNIX 91 -#define _SC_XOPEN_VERSION 89 -#define _SC_XOPEN_XCU_VERSION 90 -#define _SC_XOPEN_XPG2 98 -#define _SC_XOPEN_XPG3 99 -#define _SC_XOPEN_XPG4 100 -#define _SEARCH_H -#define _SEMAPHORE_H -#define _SIZE_T -#define _STDALIGN_H -#define _STDBOOL_H -#define _STDC_PREDEF_H -#define _STDINT_H -#define _STDIO_EXT_H -#define _STDIO_H -#define _STDLIB_H -#define _STDNORETURN_H -#define _STRINGS_H -#define _STRING_H -#define _STROPTS_H -#define _SYSEXITS_H -#define _SYS_EVENTFD_H -#define _SYS_FILE_H -#define _SYS_IOCTL_H -#define _SYS_PARAM_H -#define _SYS_RANDOM_H -#define _SYS_REG_H -#define _SYS_SELECT_H -#define _SYS_SOCKET_H -#define _SYS_STAT_H -#define _SYS_SYSCALL_H -#define _SYS_SYSINFO_H -#define _SYS_TIMEB_H -#define _SYS_TIMEX_H -#define _SYS_TIME_H -#define _SYS_TTYDEFAULTS_H -#define _SYS_TYPES_H -#define _SYS_UIO_H -#define _SYS_UN_H -#define _SYS_UTSNAME_H -#define _TAR_H -#define _TGMATH_H -#define _THREADS_H -#define _TIME_H -#define _UCHAR_H -#define _UNISTD_H -#define _UTIME_H -#define _VALUES_H -#define _VA_LIST -#define _WCHAR_H -#define _WCHAR_T -#define _WCTYPE_H -#define _WINT_T -#define _XOPEN_ENH_I18N 1 -#define _XOPEN_IOV_MAX 16 -#define _XOPEN_NAME_MAX 255 -#define _XOPEN_PATH_MAX 1024 -#define _XOPEN_UNIX 1 -#define _XOPEN_VERSION 700 -#define __ARE_4_EQUAL(a,b) (!( (0[a]-0[b]) | (1[a]-1[b]) | (2[a]-2[b]) | (3[a]-3[b]) )) -#define __ATOMIC_ACQUIRE 2 -#define __ATOMIC_ACQ_REL 4 -#define __ATOMIC_CONSUME 1 -#define __ATOMIC_RELAXED 0 -#define __ATOMIC_RELEASE 3 -#define __ATOMIC_SEQ_CST 5 -#define __BIGGEST_ALIGNMENT__ 16 -#define __BIG_ENDIAN 4321 -#define __BIND 19950621 -#define __BYTE_ORDER __BYTE_ORDER__ -#define __BYTE_ORDER__ __ORDER_LITTLE_ENDIAN__ -#define __CHAR16_TYPE__ unsigned short -#define __CHAR32_TYPE__ unsigned int -#define __CHAR_BIT__ 8 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __CLANG_MAX_ALIGN_T_DEFINED -#define __CMPLX(x,y,t) (__builtin_complex((t)(x), (t)(y))) -#define __CONSTANT_CFSTRINGS__ 1 -#define __DBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(double complex)) -#define __DBL_DECIMAL_DIG__ 17 -#define __DBL_DENORM_MIN__ 4.9406564584124654e-324 -#define __DBL_DIG__ 15 -#define __DBL_EPSILON__ 2.2204460492503131e-16 -#define __DBL_HAS_DENORM__ 1 -#define __DBL_HAS_INFINITY__ 1 -#define __DBL_HAS_QUIET_NAN__ 1 -#define __DBL_MANT_DIG__ 53 -#define __DBL_MAX_10_EXP__ 308 -#define __DBL_MAX_EXP__ 1024 -#define __DBL_MAX__ 1.7976931348623157e+308 -#define __DBL_MIN_10_EXP__ (-307) -#define __DBL_MIN_EXP__ (-1021) -#define __DBL_MIN__ 2.2250738585072014e-308 -#define __DECIMAL_DIG__ __LDBL_DECIMAL_DIG__ -#define __DEFINED_FILE -#define __DEFINED___isoc_va_list -#define __DEFINED_blkcnt_t -#define __DEFINED_blksize_t -#define __DEFINED_clock_t -#define __DEFINED_clockid_t -#define __DEFINED_cnd_t -#define __DEFINED_dev_t -#define __DEFINED_double_t -#define __DEFINED_float_t -#define __DEFINED_fsblkcnt_t -#define __DEFINED_fsfilcnt_t -#define __DEFINED_gid_t -#define __DEFINED_id_t -#define __DEFINED_ino_t -#define __DEFINED_int16_t -#define __DEFINED_int32_t -#define __DEFINED_int64_t -#define __DEFINED_int8_t -#define __DEFINED_intmax_t -#define __DEFINED_intptr_t -#define __DEFINED_key_t -#define __DEFINED_locale_t -#define __DEFINED_mbstate_t -#define __DEFINED_mode_t -#define __DEFINED_mtx_t -#define __DEFINED_nlink_t -#define __DEFINED_off_t -#define __DEFINED_pid_t -#define __DEFINED_pthread_attr_t -#define __DEFINED_pthread_barrier_t -#define __DEFINED_pthread_barrierattr_t -#define __DEFINED_pthread_cond_t -#define __DEFINED_pthread_condattr_t -#define __DEFINED_pthread_key_t -#define __DEFINED_pthread_mutex_t -#define __DEFINED_pthread_mutexattr_t -#define __DEFINED_pthread_once_t -#define __DEFINED_pthread_rwlock_t -#define __DEFINED_pthread_rwlockattr_t -#define __DEFINED_pthread_spinlock_t -#define __DEFINED_pthread_t -#define __DEFINED_register_t -#define __DEFINED_regoff_t -#define __DEFINED_sa_family_t -#define __DEFINED_sigset_t -#define __DEFINED_size_t -#define __DEFINED_socklen_t -#define __DEFINED_ssize_t -#define __DEFINED_suseconds_t -#define __DEFINED_time_t -#define __DEFINED_timer_t -#define __DEFINED_u_int64_t -#define __DEFINED_uid_t -#define __DEFINED_uint16_t -#define __DEFINED_uint32_t -#define __DEFINED_uint64_t -#define __DEFINED_uint8_t -#define __DEFINED_uintmax_t -#define __DEFINED_uintptr_t -#define __DEFINED_useconds_t -#define __DEFINED_va_list -#define __DEFINED_wchar_t -#define __DEFINED_wctype_t -#define __DEFINED_wint_t -#define __FINITE_MATH_ONLY__ 0 -#define __FLOAT128__ 1 -#define __FLT(x) (__IS_REAL(x) && sizeof(x) == sizeof(float)) -#define __FLTCX(x) (__IS_CX(x) && sizeof(x) == sizeof(float complex)) -#define __FLT_DECIMAL_DIG__ 9 -#define __FLT_DENORM_MIN__ 1.40129846e-45F -#define __FLT_DIG__ 6 -#define __FLT_EPSILON__ 1.19209290e-7F -#define __FLT_HAS_DENORM__ 1 -#define __FLT_HAS_INFINITY__ 1 -#define __FLT_HAS_QUIET_NAN__ 1 -#define __FLT_MANT_DIG__ 24 -#define __FLT_MAX_10_EXP__ 38 -#define __FLT_MAX_EXP__ 128 -#define __FLT_MAX__ 3.40282347e+38F -#define __FLT_MIN_10_EXP__ (-37) -#define __FLT_MIN_EXP__ (-125) -#define __FLT_MIN__ 1.17549435e-38F -#define __FLT_RADIX__ 2 -#define __compiler_ATOMIC_BOOL_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR16_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR32_T_LOCK_FREE 2 -#define __compiler_ATOMIC_CHAR_LOCK_FREE 2 -#define __compiler_ATOMIC_INT_LOCK_FREE 2 -#define __compiler_ATOMIC_LLONG_LOCK_FREE 2 -#define __compiler_ATOMIC_LONG_LOCK_FREE 2 -#define __compiler_ATOMIC_POINTER_LOCK_FREE 2 -#define __compiler_ATOMIC_SHORT_LOCK_FREE 2 -#define __GCC_ATOMIC_TEST_AND_SET_TRUEVAL 1 -#define __compiler_ATOMIC_WCHAR_T_LOCK_FREE 2 -#define __GNUC_STDC_INLINE__ 1 -#define __GNUC_VA_LIST 1 -#define __GXX_ABI_VERSION 1002 -#define __INT16_C_SUFFIX__ -#define __INT16_FMTd__ "hd" -#define __INT16_FMTi__ "hi" -#define __INT16_MAX__ 32767 -#define __INT16_TYPE__ short -#define __INT32_C_SUFFIX__ -#define __INT32_FMTd__ "d" -#define __INT32_FMTi__ "i" -#define __INT32_MAX__ 2147483647 -#define __INT32_TYPE__ int -#define __INT64_C_SUFFIX__ LL -#define __INT64_FMTd__ "lld" -#define __INT64_FMTi__ "lli" -#define __INT64_MAX__ 9223372036854775807LL -#define __INT64_TYPE__ long long int -#define __INT8_C_SUFFIX__ -#define __INT8_FMTd__ "hhd" -#define __INT8_FMTi__ "hhi" -#define __INT8_MAX__ 127 -#define __INT8_TYPE__ signed char -#define __INTMAX_C_SUFFIX__ LL -#define __INTMAX_FMTd__ "lld" -#define __INTMAX_FMTi__ "lli" -#define __INTMAX_MAX__ 9223372036854775807LL -#define __INTMAX_TYPE__ long long int -#define __INTMAX_WIDTH__ 64 -#define __INTPTR_FMTd__ "ld" -#define __INTPTR_FMTi__ "li" -#define __INTPTR_MAX__ 9223372036854775807L -#define __INTPTR_TYPE__ long int -#define __INTPTR_WIDTH__ 64 -#define __INT_FAST16_FMTd__ "hd" -#define __INT_FAST16_FMTi__ "hi" -#define __INT_FAST16_MAX__ 32767 -#define __INT_FAST16_TYPE__ short -#define __INT_FAST32_FMTd__ "d" -#define __INT_FAST32_FMTi__ "i" -#define __INT_FAST32_MAX__ 2147483647 -#define __INT_FAST32_TYPE__ int -#define __INT_FAST64_FMTd__ "lld" -#define __INT_FAST64_FMTi__ "lli" -#define __INT_FAST64_MAX__ 9223372036854775807LL -#define __INT_FAST64_TYPE__ long long int -#define __INT_FAST8_FMTd__ "hhd" -#define __INT_FAST8_FMTi__ "hhi" -#define __INT_FAST8_MAX__ 127 -#define __INT_FAST8_TYPE__ signed char -#define __INT_LEAST16_FMTd__ "hd" -#define __INT_LEAST16_FMTi__ "hi" -#define __INT_LEAST16_MAX__ 32767 -#define __INT_LEAST16_TYPE__ short -#define __INT_LEAST32_FMTd__ "d" -#define __INT_LEAST32_FMTi__ "i" -#define __INT_LEAST32_MAX__ 2147483647 -#define __INT_LEAST32_TYPE__ int -#define __INT_LEAST64_FMTd__ "lld" -#define __INT_LEAST64_FMTi__ "lli" -#define __INT_LEAST64_MAX__ 9223372036854775807LL -#define __INT_LEAST64_TYPE__ long long int -#define __INT_LEAST8_FMTd__ "hhd" -#define __INT_LEAST8_FMTi__ "hhi" -#define __INT_LEAST8_MAX__ 127 -#define __INT_LEAST8_TYPE__ signed char -#define __INT_MAX__ 2147483647 -#define __IS_CX(x) (__IS_FP(x) && sizeof(x) == sizeof((x)+I)) -#define __IS_FP(x) (sizeof((x)+1ULL) == sizeof((x)+1.0f)) -#define __IS_REAL(x) (__IS_FP(x) && 2*sizeof(x) == sizeof((x)+I)) -#define __LDBL(x) (__IS_REAL(x) && sizeof(x) == sizeof(long double) && sizeof(long double) != sizeof(double)) -#define __LDBLCX(x) (__IS_CX(x) && sizeof(x) == sizeof(long double complex) && sizeof(long double) != sizeof(double)) -#define __LDBL_DECIMAL_DIG__ 36 -#define __LDBL_DENORM_MIN__ 6.47517511943802511092443895822764655e-4966L -#define __LDBL_DIG__ 33 -#define __LDBL_EPSILON__ 1.92592994438723585305597794258492732e-34L -#define __LDBL_HAS_DENORM__ 1 -#define __LDBL_HAS_INFINITY__ 1 -#define __LDBL_HAS_QUIET_NAN__ 1 -#define __LDBL_MANT_DIG__ 113 -#define __LDBL_MAX_10_EXP__ 4932 -#define __LDBL_MAX_EXP__ 16384 -#define __LDBL_MAX__ 1.18973149535723176508575932662800702e+4932L -#define __LDBL_MIN_10_EXP__ (-4931) -#define __LDBL_MIN_EXP__ (-16381) -#define __LDBL_MIN__ 3.36210314311209350626267781732175260e-4932L -#define __LITTLE_ENDIAN 1234 -#define __LITTLE_ENDIAN__ 1 -#define __LONG_LONG_MAX__ 9223372036854775807LL -#define __LONG_MAX __LONG_MAX__ -#define __LONG_MAX__ 9223372036854775807L -#define __LP64__ 1 -#define __NAMESER 19991006 -#define __NEED_FILE -#define __NEED___isoc_va_list -#define __NEED_blkcnt_t -#define __NEED_blksize_t -#define __NEED_clock_t -#define __NEED_clockid_t -#define __NEED_cnd_t -#define __NEED_dev_t -#define __NEED_double_t -#define __NEED_float_t -#define __NEED_fsblkcnt_t -#define __NEED_fsfilcnt_t -#define __NEED_gid_t -#define __NEED_id_t -#define __NEED_ino_t -#define __NEED_int16_t -#define __NEED_int32_t -#define __NEED_int64_t -#define __NEED_int8_t -#define __NEED_intmax_t -#define __NEED_intptr_t -#define __NEED_key_t -#define __NEED_locale_t -#define __NEED_mbstate_t -#define __NEED_mode_t -#define __NEED_mtx_t -#define __NEED_nlink_t -#define __NEED_off_t -#define __NEED_pid_t -#define __NEED_pthread_attr_t -#define __NEED_pthread_barrier_t -#define __NEED_pthread_barrierattr_t -#define __NEED_pthread_cond_t -#define __NEED_pthread_condattr_t -#define __NEED_pthread_key_t -#define __NEED_pthread_mutex_t -#define __NEED_pthread_mutexattr_t -#define __NEED_pthread_once_t -#define __NEED_pthread_rwlock_t -#define __NEED_pthread_rwlockattr_t -#define __NEED_pthread_spinlock_t -#define __NEED_pthread_t -#define __NEED_register_t -#define __NEED_regoff_t -#define __NEED_sa_family_t -#define __NEED_sigset_t -#define __NEED_size_t -#define __NEED_socklen_t -#define __NEED_ssize_t -#define __NEED_struct_iovec -#define __NEED_struct_timespec -#define __NEED_struct_timeval -#define __NEED_suseconds_t -#define __NEED_time_t -#define __NEED_timer_t -#define __NEED_u_int64_t -#define __NEED_uid_t -#define __NEED_uint16_t -#define __NEED_uint32_t -#define __NEED_uint64_t -#define __NEED_uint8_t -#define __NEED_uintmax_t -#define __NEED_uintptr_t -#define __NEED_useconds_t -#define __NEED_va_list -#define __NEED_wchar_t -#define __NEED_wctype_t -#define __NEED_wint_t -#define __OBJC_BOOL_IS_BOOL 0 -#define __OPENCL_MEMORY_SCOPE_ALL_SVM_DEVICES 3 -#define __OPENCL_MEMORY_SCOPE_DEVICE 2 -#define __OPENCL_MEMORY_SCOPE_SUB_GROUP 4 -#define __OPENCL_MEMORY_SCOPE_WORK_GROUP 1 -#define __OPENCL_MEMORY_SCOPE_WORK_ITEM 0 -#define __ORDER_BIG_ENDIAN__ 4321 -#define __ORDER_LITTLE_ENDIAN__ 1234 -#define __ORDER_PDP_ENDIAN__ 3412 -#define __PDP_ENDIAN 3412 -#define __POINTER_WIDTH__ 64 -#define __PRAGMA_REDEFINE_EXTNAME 1 -#define __PTRDIFF_FMTd__ "ld" -#define __PTRDIFF_FMTi__ "li" -#define __PTRDIFF_MAX__ 9223372036854775807L -#define __PTRDIFF_TYPE__ long int -#define __PTRDIFF_WIDTH__ 64 -#define __REDIR(x,y) __typeof__(x) x __asm__(#y) -#define __RETCAST(x) -#define __RETCAST_2(x,y) -#define __RETCAST_3(x,y,z) -#define __RETCAST_CX(x) -#define __RETCAST_REAL(x) -#define __SCHAR_MAX__ 127 -#define __SHRT_MAX__ 32767 -#define __SID ('S' << 8) -#define __SIG_ATOMIC_MAX__ 9223372036854775807L -#define __SIG_ATOMIC_WIDTH__ 64 -#define __SIZEOF_DOUBLE__ 8 -#define __SIZEOF_FLOAT__ 4 -#define __SIZEOF_INT128__ 16 -#define __SIZEOF_INT__ 4 -#define __SIZEOF_LONG_DOUBLE__ 16 -#define __SIZEOF_LONG_LONG__ 8 -#define __SIZEOF_LONG__ 8 -#define __SIZEOF_POINTER__ 8 -#define __SIZEOF_PTRDIFF_T__ 8 -#define __SIZEOF_SHORT__ 2 -#define __SIZEOF_SIZE_T__ 8 -#define __SIZEOF_WCHAR_T__ 4 -#define __SIZEOF_WINT_T__ 4 -#define __SIZE_FMTX__ "lX" -#define __SIZE_FMTo__ "lo" -#define __SIZE_FMTu__ "lu" -#define __SIZE_FMTx__ "lx" -#define __SIZE_MAX__ 18446744073709551615UL -#define __SIZE_TYPE__ long unsigned int -#define __SIZE_WIDTH__ 64 -#define __STDARG_H -#define __STDC_HOSTED__ 1 -#define __STDC_IEC_559__ 1 -#define __STDC_ISO_10646__ 201206L -#define __STDC_UTF_16__ 1 -#define __STDC_UTF_32__ 1 -#define __STDC_VERSION__ 201710L -#define __STDC__ 1 -#define __STDDEF_H -#define __UAPI_DEF_IN6_ADDR 0 -#define __UAPI_DEF_IN6_ADDR_ALT 0 -#define __UAPI_DEF_IN6_PKTINFO 0 -#define __UAPI_DEF_IN_ADDR 0 -#define __UAPI_DEF_IN_CLASS 0 -#define __UAPI_DEF_IN_IPPROTO 0 -#define __UAPI_DEF_IN_PKTINFO 0 -#define __UAPI_DEF_IP6_MTUINFO 0 -#define __UAPI_DEF_IPHDR 0 -#define __UAPI_DEF_IPPROTO_V6 0 -#define __UAPI_DEF_IPV6_MREQ 0 -#define __UAPI_DEF_IPV6_OPTIONS 0 -#define __UAPI_DEF_IP_MREQ 0 -#define __UAPI_DEF_SOCKADDR_IN 0 -#define __UAPI_DEF_SOCKADDR_IN6 0 -#define __UINT16_C_SUFFIX__ -#define __UINT16_FMTX__ "hX" -#define __UINT16_FMTo__ "ho" -#define __UINT16_FMTu__ "hu" -#define __UINT16_FMTx__ "hx" -#define __UINT16_MAX__ 65535 -#define __UINT16_TYPE__ unsigned short -#define __UINT32_C_SUFFIX__ U -#define __UINT32_FMTX__ "X" -#define __UINT32_FMTo__ "o" -#define __UINT32_FMTu__ "u" -#define __UINT32_FMTx__ "x" -#define __UINT32_MAX__ 4294967295U -#define __UINT32_TYPE__ unsigned int -#define __UINT64_C_SUFFIX__ ULL -#define __UINT64_FMTX__ "llX" -#define __UINT64_FMTo__ "llo" -#define __UINT64_FMTu__ "llu" -#define __UINT64_FMTx__ "llx" -#define __UINT64_MAX__ 18446744073709551615ULL -#define __UINT64_TYPE__ long long unsigned int -#define __UINT8_C_SUFFIX__ -#define __UINT8_FMTX__ "hhX" -#define __UINT8_FMTo__ "hho" -#define __UINT8_FMTu__ "hhu" -#define __UINT8_FMTx__ "hhx" -#define __UINT8_MAX__ 255 -#define __UINT8_TYPE__ unsigned char -#define __UINTMAX_C_SUFFIX__ ULL -#define __UINTMAX_FMTX__ "llX" -#define __UINTMAX_FMTo__ "llo" -#define __UINTMAX_FMTu__ "llu" -#define __UINTMAX_FMTx__ "llx" -#define __UINTMAX_MAX__ 18446744073709551615ULL -#define __UINTMAX_TYPE__ long long unsigned int -#define __UINTMAX_WIDTH__ 64 -#define __UINTPTR_FMTX__ "lX" -#define __UINTPTR_FMTo__ "lo" -#define __UINTPTR_FMTu__ "lu" -#define __UINTPTR_FMTx__ "lx" -#define __UINTPTR_MAX__ 18446744073709551615UL -#define __UINTPTR_TYPE__ long unsigned int -#define __UINTPTR_WIDTH__ 64 -#define __UINT_FAST16_FMTX__ "hX" -#define __UINT_FAST16_FMTo__ "ho" -#define __UINT_FAST16_FMTu__ "hu" -#define __UINT_FAST16_FMTx__ "hx" -#define __UINT_FAST16_MAX__ 65535 -#define __UINT_FAST16_TYPE__ unsigned short -#define __UINT_FAST32_FMTX__ "X" -#define __UINT_FAST32_FMTo__ "o" -#define __UINT_FAST32_FMTu__ "u" -#define __UINT_FAST32_FMTx__ "x" -#define __UINT_FAST32_MAX__ 4294967295U -#define __UINT_FAST32_TYPE__ unsigned int -#define __UINT_FAST64_FMTX__ "llX" -#define __UINT_FAST64_FMTo__ "llo" -#define __UINT_FAST64_FMTu__ "llu" -#define __UINT_FAST64_FMTx__ "llx" -#define __UINT_FAST64_MAX__ 18446744073709551615ULL -#define __UINT_FAST64_TYPE__ long long unsigned int -#define __UINT_FAST8_FMTX__ "hhX" -#define __UINT_FAST8_FMTo__ "hho" -#define __UINT_FAST8_FMTu__ "hhu" -#define __UINT_FAST8_FMTx__ "hhx" -#define __UINT_FAST8_MAX__ 255 -#define __UINT_FAST8_TYPE__ unsigned char -#define __UINT_LEAST16_FMTX__ "hX" -#define __UINT_LEAST16_FMTo__ "ho" -#define __UINT_LEAST16_FMTu__ "hu" -#define __UINT_LEAST16_FMTx__ "hx" -#define __UINT_LEAST16_MAX__ 65535 -#define __UINT_LEAST16_TYPE__ unsigned short -#define __UINT_LEAST32_FMTX__ "X" -#define __UINT_LEAST32_FMTo__ "o" -#define __UINT_LEAST32_FMTu__ "u" -#define __UINT_LEAST32_FMTx__ "x" -#define __UINT_LEAST32_MAX__ 4294967295U -#define __UINT_LEAST32_TYPE__ unsigned int -#define __UINT_LEAST64_FMTX__ "llX" -#define __UINT_LEAST64_FMTo__ "llo" -#define __UINT_LEAST64_FMTu__ "llu" -#define __UINT_LEAST64_FMTx__ "llx" -#define __UINT_LEAST64_MAX__ 18446744073709551615ULL -#define __UINT_LEAST64_TYPE__ long long unsigned int -#define __UINT_LEAST8_FMTX__ "hhX" -#define __UINT_LEAST8_FMTo__ "hho" -#define __UINT_LEAST8_FMTu__ "hhu" -#define __UINT_LEAST8_FMTx__ "hhx" -#define __UINT_LEAST8_MAX__ 255 -#define __UINT_LEAST8_TYPE__ unsigned char -#define __USER_LABEL_PREFIX__ -#define __USE_TIME_BITS64 1 -#define __WASI_ADVICE_DONTNEED (UINT8_C(4)) -#define __WASI_ADVICE_NOREUSE (UINT8_C(5)) -#define __WASI_ADVICE_NORMAL (UINT8_C(0)) -#define __WASI_ADVICE_RANDOM (UINT8_C(2)) -#define __WASI_ADVICE_SEQUENTIAL (UINT8_C(1)) -#define __WASI_ADVICE_WILLNEED (UINT8_C(3)) -#define __WASI_CLOCKID_MONOTONIC (UINT32_C(1)) -#define __WASI_CLOCKID_PROCESS_CPUTIME_ID (UINT32_C(2)) -#define __WASI_CLOCKID_REALTIME (UINT32_C(0)) -#define __WASI_CLOCKID_THREAD_CPUTIME_ID (UINT32_C(3)) -#define __WASI_DIRCOOKIE_START (UINT64_C(0)) -#define __WASI_ERRNO_2BIG (UINT16_C(1)) -#define __WASI_ERRNO_ACCES (UINT16_C(2)) -#define __WASI_ERRNO_ADDRINUSE (UINT16_C(3)) -#define __WASI_ERRNO_ADDRNOTAVAIL (UINT16_C(4)) -#define __WASI_ERRNO_AFNOSUPPORT (UINT16_C(5)) -#define __WASI_ERRNO_AGAIN (UINT16_C(6)) -#define __WASI_ERRNO_ALREADY (UINT16_C(7)) -#define __WASI_ERRNO_BADF (UINT16_C(8)) -#define __WASI_ERRNO_BADMSG (UINT16_C(9)) -#define __WASI_ERRNO_BUSY (UINT16_C(10)) -#define __WASI_ERRNO_CANCELED (UINT16_C(11)) -#define __WASI_ERRNO_CHILD (UINT16_C(12)) -#define __WASI_ERRNO_CONNABORTED (UINT16_C(13)) -#define __WASI_ERRNO_CONNREFUSED (UINT16_C(14)) -#define __WASI_ERRNO_CONNRESET (UINT16_C(15)) -#define __WASI_ERRNO_DEADLK (UINT16_C(16)) -#define __WASI_ERRNO_DESTADDRREQ (UINT16_C(17)) -#define __WASI_ERRNO_DOM (UINT16_C(18)) -#define __WASI_ERRNO_DQUOT (UINT16_C(19)) -#define __WASI_ERRNO_EXIST (UINT16_C(20)) -#define __WASI_ERRNO_FAULT (UINT16_C(21)) -#define __WASI_ERRNO_FBIG (UINT16_C(22)) -#define __WASI_ERRNO_HOSTUNREACH (UINT16_C(23)) -#define __WASI_ERRNO_IDRM (UINT16_C(24)) -#define __WASI_ERRNO_ILSEQ (UINT16_C(25)) -#define __WASI_ERRNO_INPROGRESS (UINT16_C(26)) -#define __WASI_ERRNO_INTR (UINT16_C(27)) -#define __WASI_ERRNO_INVAL (UINT16_C(28)) -#define __WASI_ERRNO_IO (UINT16_C(29)) -#define __WASI_ERRNO_ISCONN (UINT16_C(30)) -#define __WASI_ERRNO_ISDIR (UINT16_C(31)) -#define __WASI_ERRNO_LOOP (UINT16_C(32)) -#define __WASI_ERRNO_MFILE (UINT16_C(33)) -#define __WASI_ERRNO_MLINK (UINT16_C(34)) -#define __WASI_ERRNO_MSGSIZE (UINT16_C(35)) -#define __WASI_ERRNO_MULTIHOP (UINT16_C(36)) -#define __WASI_ERRNO_NAMETOOLONG (UINT16_C(37)) -#define __WASI_ERRNO_NETDOWN (UINT16_C(38)) -#define __WASI_ERRNO_NETRESET (UINT16_C(39)) -#define __WASI_ERRNO_NETUNREACH (UINT16_C(40)) -#define __WASI_ERRNO_NFILE (UINT16_C(41)) -#define __WASI_ERRNO_NOBUFS (UINT16_C(42)) -#define __WASI_ERRNO_NODEV (UINT16_C(43)) -#define __WASI_ERRNO_NOENT (UINT16_C(44)) -#define __WASI_ERRNO_NOEXEC (UINT16_C(45)) -#define __WASI_ERRNO_NOLCK (UINT16_C(46)) -#define __WASI_ERRNO_NOLINK (UINT16_C(47)) -#define __WASI_ERRNO_NOMEM (UINT16_C(48)) -#define __WASI_ERRNO_NOMSG (UINT16_C(49)) -#define __WASI_ERRNO_NOPROTOOPT (UINT16_C(50)) -#define __WASI_ERRNO_NOSPC (UINT16_C(51)) -#define __WASI_ERRNO_NOSYS (UINT16_C(52)) -#define __WASI_ERRNO_NOTCAPABLE (UINT16_C(76)) -#define __WASI_ERRNO_NOTCONN (UINT16_C(53)) -#define __WASI_ERRNO_NOTDIR (UINT16_C(54)) -#define __WASI_ERRNO_NOTEMPTY (UINT16_C(55)) -#define __WASI_ERRNO_NOTRECOVERABLE (UINT16_C(56)) -#define __WASI_ERRNO_NOTSOCK (UINT16_C(57)) -#define __WASI_ERRNO_NOTSUP (UINT16_C(58)) -#define __WASI_ERRNO_NOTTY (UINT16_C(59)) -#define __WASI_ERRNO_NXIO (UINT16_C(60)) -#define __WASI_ERRNO_OVERFLOW (UINT16_C(61)) -#define __WASI_ERRNO_OWNERDEAD (UINT16_C(62)) -#define __WASI_ERRNO_PERM (UINT16_C(63)) -#define __WASI_ERRNO_PIPE (UINT16_C(64)) -#define __WASI_ERRNO_PROTO (UINT16_C(65)) -#define __WASI_ERRNO_PROTONOSUPPORT (UINT16_C(66)) -#define __WASI_ERRNO_PROTOTYPE (UINT16_C(67)) -#define __WASI_ERRNO_RANGE (UINT16_C(68)) -#define __WASI_ERRNO_ROFS (UINT16_C(69)) -#define __WASI_ERRNO_SPIPE (UINT16_C(70)) -#define __WASI_ERRNO_SRCH (UINT16_C(71)) -#define __WASI_ERRNO_STALE (UINT16_C(72)) -#define __WASI_ERRNO_SUCCESS (UINT16_C(0)) -#define __WASI_ERRNO_TIMEDOUT (UINT16_C(73)) -#define __WASI_ERRNO_TXTBSY (UINT16_C(74)) -#define __WASI_ERRNO_XDEV (UINT16_C(75)) -#define __WASI_EVENTRWFLAGS_FD_READWRITE_HANGUP ((__wasi_eventrwflags_t)(1 << 0)) -#define __WASI_EVENTTYPE_CLOCK (UINT8_C(0)) -#define __WASI_EVENTTYPE_FD_READ (UINT8_C(1)) -#define __WASI_EVENTTYPE_FD_WRITE (UINT8_C(2)) -#define __WASI_FDFLAGS_APPEND ((__wasi_fdflags_t)(1 << 0)) -#define __WASI_FDFLAGS_DSYNC ((__wasi_fdflags_t)(1 << 1)) -#define __WASI_FDFLAGS_NONBLOCK ((__wasi_fdflags_t)(1 << 2)) -#define __WASI_FDFLAGS_RSYNC ((__wasi_fdflags_t)(1 << 3)) -#define __WASI_FDFLAGS_SYNC ((__wasi_fdflags_t)(1 << 4)) -#define __WASI_FILETYPE_BLOCK_DEVICE (UINT8_C(1)) -#define __WASI_FILETYPE_CHARACTER_DEVICE (UINT8_C(2)) -#define __WASI_FILETYPE_DIRECTORY (UINT8_C(3)) -#define __WASI_FILETYPE_REGULAR_FILE (UINT8_C(4)) -#define __WASI_FILETYPE_SOCKET_DGRAM (UINT8_C(5)) -#define __WASI_FILETYPE_SOCKET_STREAM (UINT8_C(6)) -#define __WASI_FILETYPE_SYMBOLIC_LINK (UINT8_C(7)) -#define __WASI_FILETYPE_UNKNOWN (UINT8_C(0)) -#define __WASI_FSTFLAGS_ATIM ((__wasi_fstflags_t)(1 << 0)) -#define __WASI_FSTFLAGS_ATIM_NOW ((__wasi_fstflags_t)(1 << 1)) -#define __WASI_FSTFLAGS_MTIM ((__wasi_fstflags_t)(1 << 2)) -#define __WASI_FSTFLAGS_MTIM_NOW ((__wasi_fstflags_t)(1 << 3)) -#define __WASI_LOOKUPFLAGS_SYMLINK_FOLLOW ((__wasi_lookupflags_t)(1 << 0)) -#define __WASI_NOEXCEPT -#define __WASI_OFLAGS_CREAT ((__wasi_oflags_t)(1 << 0)) -#define __WASI_OFLAGS_DIRECTORY ((__wasi_oflags_t)(1 << 1)) -#define __WASI_OFLAGS_EXCL ((__wasi_oflags_t)(1 << 2)) -#define __WASI_OFLAGS_TRUNC ((__wasi_oflags_t)(1 << 3)) -#define __WASI_PREOPENTYPE_DIR (UINT8_C(0)) -#define __WASI_RIFLAGS_RECV_PEEK ((__wasi_riflags_t)(1 << 0)) -#define __WASI_RIFLAGS_RECV_WAITALL ((__wasi_riflags_t)(1 << 1)) -#define __WASI_RIGHTS_FD_ADVISE ((__wasi_rights_t)(1 << 7)) -#define __WASI_RIGHTS_FD_ALLOCATE ((__wasi_rights_t)(1 << 8)) -#define __WASI_RIGHTS_FD_DATASYNC ((__wasi_rights_t)(1 << 0)) -#define __WASI_RIGHTS_FD_FDSTAT_SET_FLAGS ((__wasi_rights_t)(1 << 3)) -#define __WASI_RIGHTS_FD_FILESTAT_GET ((__wasi_rights_t)(1 << 21)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 22)) -#define __WASI_RIGHTS_FD_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 23)) -#define __WASI_RIGHTS_FD_READ ((__wasi_rights_t)(1 << 1)) -#define __WASI_RIGHTS_FD_READDIR ((__wasi_rights_t)(1 << 14)) -#define __WASI_RIGHTS_FD_SEEK ((__wasi_rights_t)(1 << 2)) -#define __WASI_RIGHTS_FD_SYNC ((__wasi_rights_t)(1 << 4)) -#define __WASI_RIGHTS_FD_TELL ((__wasi_rights_t)(1 << 5)) -#define __WASI_RIGHTS_FD_WRITE ((__wasi_rights_t)(1 << 6)) -#define __WASI_RIGHTS_PATH_CREATE_DIRECTORY ((__wasi_rights_t)(1 << 9)) -#define __WASI_RIGHTS_PATH_CREATE_FILE ((__wasi_rights_t)(1 << 10)) -#define __WASI_RIGHTS_PATH_FILESTAT_GET ((__wasi_rights_t)(1 << 18)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_SIZE ((__wasi_rights_t)(1 << 19)) -#define __WASI_RIGHTS_PATH_FILESTAT_SET_TIMES ((__wasi_rights_t)(1 << 20)) -#define __WASI_RIGHTS_PATH_LINK_SOURCE ((__wasi_rights_t)(1 << 11)) -#define __WASI_RIGHTS_PATH_LINK_TARGET ((__wasi_rights_t)(1 << 12)) -#define __WASI_RIGHTS_PATH_OPEN ((__wasi_rights_t)(1 << 13)) -#define __WASI_RIGHTS_PATH_READLINK ((__wasi_rights_t)(1 << 15)) -#define __WASI_RIGHTS_PATH_REMOVE_DIRECTORY ((__wasi_rights_t)(1 << 25)) -#define __WASI_RIGHTS_PATH_RENAME_SOURCE ((__wasi_rights_t)(1 << 16)) -#define __WASI_RIGHTS_PATH_RENAME_TARGET ((__wasi_rights_t)(1 << 17)) -#define __WASI_RIGHTS_PATH_SYMLINK ((__wasi_rights_t)(1 << 24)) -#define __WASI_RIGHTS_PATH_UNLINK_FILE ((__wasi_rights_t)(1 << 26)) -#define __WASI_RIGHTS_POLL_FD_READWRITE ((__wasi_rights_t)(1 << 27)) -#define __WASI_RIGHTS_SOCK_ACCEPT ((__wasi_rights_t)(1 << 29)) -#define __WASI_RIGHTS_SOCK_SHUTDOWN ((__wasi_rights_t)(1 << 28)) -#define __WASI_ROFLAGS_RECV_DATA_TRUNCATED ((__wasi_roflags_t)(1 << 0)) -#define __WASI_SDFLAGS_RD ((__wasi_sdflags_t)(1 << 0)) -#define __WASI_SDFLAGS_WR ((__wasi_sdflags_t)(1 << 1)) -#define __WASI_SUBCLOCKFLAGS_SUBSCRIPTION_CLOCK_ABSTIME ((__wasi_subclockflags_t)(1 << 0)) -#define __WASI_WHENCE_CUR (UINT8_C(1)) -#define __WASI_WHENCE_END (UINT8_C(2)) -#define __WASI_WHENCE_SET (UINT8_C(0)) -#define __WCHAR_MAX__ 2147483647 -#define __WCHAR_TYPE__ int -#define __WCHAR_WIDTH__ 32 -#define __WINT_MAX__ 2147483647 -#define __WINT_TYPE__ int -#define __WINT_WIDTH__ 32 -#define __WORDSIZE 64 -#define __alignas_is_defined 1 -#define __alignof_is_defined 1 -#define __bitop(x,i,o) ((x)[(i)/8] o (1<<(i)%8)) -#define __bool_true_false_are_defined 1 -#define __inline inline -#define __restrict restrict -#define __tg_complex(fun,x) (__RETCAST_CX(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_complex_retreal(fun,x) (__RETCAST_REAL(x)( __FLTCX((x)+I) && __IS_FP(x) ? fun ## f (x) : __LDBLCX((x)+I) ? fun ## l (x) : fun(x) )) -#define __tg_real(fun,x) (__RETCAST(x)__tg_real_nocast(fun, x)) -#define __tg_real_2(fun,x,y) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? fun ## f (x, y) : __LDBL((x)+(y)) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_2_1(fun,x,y) (__RETCAST(x)( __FLT(x) ? fun ## f (x, y) : __LDBL(x) ? fun ## l (x, y) : fun(x, y) )) -#define __tg_real_complex(fun,x) (__RETCAST(x)( __FLTCX(x) ? c ## fun ## f (x) : __DBLCX(x) ? c ## fun (x) : __LDBLCX(x) ? c ## fun ## l (x) : __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) )) -#define __tg_real_complex_fabs(x) (__RETCAST_REAL(x)( __FLTCX(x) ? cabsf(x) : __DBLCX(x) ? cabs(x) : __LDBLCX(x) ? cabsl(x) : __FLT(x) ? fabsf(x) : __LDBL(x) ? fabsl(x) : fabs(x) )) -#define __tg_real_complex_pow(x,y) (__RETCAST_2(x, y)( __FLTCX((x)+(y)) && __IS_FP(x) && __IS_FP(y) ? cpowf(x, y) : __FLTCX((x)+(y)) ? cpow(x, y) : __DBLCX((x)+(y)) ? cpow(x, y) : __LDBLCX((x)+(y)) ? cpowl(x, y) : __FLT(x) && __FLT(y) ? powf(x, y) : __LDBL((x)+(y)) ? powl(x, y) : pow(x, y) )) -#define __tg_real_fma(x,y,z) (__RETCAST_3(x, y, z)( __FLT(x) && __FLT(y) && __FLT(z) ? fmaf(x, y, z) : __LDBL((x)+(y)+(z)) ? fmal(x, y, z) : fma(x, y, z) )) -#define __tg_real_nocast(fun,x) ( __FLT(x) ? fun ## f (x) : __LDBL(x) ? fun ## l (x) : fun(x) ) -#define __tg_real_remquo(x,y,z) (__RETCAST_2(x, y)( __FLT(x) && __FLT(y) ? remquof(x, y, z) : __LDBL((x)+(y)) ? remquol(x, y, z) : remquo(x, y, z) )) -#define __tm_gmtoff tm_gmtoff -#define __tm_zone tm_zone -#define __va_copy(d,s) __builtin_va_copy(d, s) -#define __wasi__ 1 -#define __wasi_api_h -#define __wasi_libc_environ_h -#define __wasi_libc_find_relpath_h -#define __wasi_libc_h -#define __wasi_libc_nocwd_h -#define __wasilibc___errno_h -#define __wasilibc___errno_values_h -#define __wasilibc___fd_set_h -#define __wasilibc___function___isatty_h -#define __wasilibc___functions_malloc_h -#define __wasilibc___functions_memcpy_h -#define __wasilibc___header_dirent_h -#define __wasilibc___header_fcntl_h -#define __wasilibc___header_netinet_in_h -#define __wasilibc___header_poll_h -#define __wasilibc___header_stdlib_h -#define __wasilibc___header_string_h -#define __wasilibc___header_sys_ioctl_h -#define __wasilibc___header_sys_resource_h -#define __wasilibc___header_sys_socket_h -#define __wasilibc___header_sys_stat_h -#define __wasilibc___header_time_h -#define __wasilibc___header_unistd_h -#define __wasilibc___include_inttypes_h -#define __wasilibc___macro_FD_SETSIZE_h -#define __wasilibc___macro_PAGESIZE_h -#define __wasilibc___mode_t_h -#define __wasilibc___seek_h -#define __wasilibc___struct_dirent_h -#define __wasilibc___struct_in6_addr_h -#define __wasilibc___struct_in_addr_h -#define __wasilibc___struct_iovec_h -#define __wasilibc___struct_msghdr_h -#define __wasilibc___struct_pollfd_h -#define __wasilibc___struct_rusage_h -#define __wasilibc___struct_sockaddr_h -#define __wasilibc___struct_sockaddr_in6_h -#define __wasilibc___struct_sockaddr_in_h -#define __wasilibc___struct_sockaddr_storage_h -#define __wasilibc___struct_sockaddr_un_h -#define __wasilibc___struct_stat_h -#define __wasilibc___struct_timespec_h -#define __wasilibc___struct_timeval_h -#define __wasilibc___struct_tm_h -#define __wasilibc___struct_tms_h -#define __wasilibc___typedef_DIR_h -#define __wasilibc___typedef_blkcnt_t_h -#define __wasilibc___typedef_blksize_t_h -#define __wasilibc___typedef_clock_t_h -#define __wasilibc___typedef_clockid_t_h -#define __wasilibc___typedef_dev_t_h -#define __wasilibc___typedef_fd_set_h -#define __wasilibc___typedef_gid_t_h -#define __wasilibc___typedef_in_addr_t_h -#define __wasilibc___typedef_in_port_t_h -#define __wasilibc___typedef_ino_t_h -#define __wasilibc___typedef_mode_t_h -#define __wasilibc___typedef_nfds_t_h -#define __wasilibc___typedef_nlink_t_h -#define __wasilibc___typedef_off_t_h -#define __wasilibc___typedef_sa_family_t_h -#define __wasilibc___typedef_sigset_t_h -#define __wasilibc___typedef_socklen_t_h -#define __wasilibc___typedef_ssize_t_h -#define __wasilibc___typedef_suseconds_t_h -#define __wasilibc___typedef_time_t_h -#define __wasilibc___typedef_uid_t_h -#define __wasm 1 -#define __wasm64 1 -#define __wasm64__ 1 -#define __wasm__ 1 -#define _tolower(a) ((a)|0x20) -#define _toupper(a) ((a)&0x5f) -#define acos(x) __tg_real_complex(acos, (x)) -#define acosh(x) __tg_real_complex(acosh, (x)) -#define alignas _Alignas -#define alignof _Alignof -#define alloca __builtin_alloca -#define alphasort64 alphasort -#define and && -#define and_eq &= -#define asin(x) __tg_real_complex(asin, (x)) -#define asinh(x) __tg_real_complex(asinh, (x)) -#define atan(x) __tg_real_complex(atan, (x)) -#define atan2(x,y) __tg_real_2(atan2, (x), (y)) -#define atanh(x) __tg_real_complex(atanh, (x)) -#define be16toh(x) __bswap16(x) -#define be32toh(x) __bswap32(x) -#define be64toh(x) __bswap64(x) -#define betoh16(x) __bswap16(x) -#define betoh32(x) __bswap32(x) -#define betoh64(x) __bswap64(x) -#define bitand & -#define bitor | -#define blkcnt64_t blkcnt_t -#define bool _Bool -#define bswap_16(x) __bswap_16(x) -#define bswap_32(x) __bswap_32(x) -#define bswap_64(x) __bswap_64(x) -#define carg(x) __tg_complex_retreal(carg, (x)) -#define cbrt(x) __tg_real(cbrt, (x)) -#define ceil(x) __tg_real(ceil, (x)) -#define cimag(x) __tg_complex_retreal(cimag, (x)) -#define cimagf(x) (__builtin_cimagf(x)) -#define cimagl(x) (__builtin_cimagl(x)) -#define clrbit(x,i) __bitop(x,i,&=~) -#define compl ~ -#define complex _Complex -#define conj(x) __tg_complex(conj, (x)) -#define copysign(x,y) __tg_real_2(copysign, (x), (y)) -#define cos(x) __tg_real_complex(cos, (x)) -#define cosh(x) __tg_real_complex(cosh, (x)) -#define cproj(x) __tg_complex(cproj, (x)) -#define creal(x) __tg_complex_retreal(creal, (x)) -#define crealf(x) (__builtin_crealf(x)) -#define creall(x) (__builtin_creall(x)) -#define creat64 creat -#define d_fileno d_ino -#define direct dirent -#define dirent64 dirent -#define erf(x) __tg_real(erf, (x)) -#define erfc(x) __tg_real(erfc, (x)) -#define errno errno -#define exp(x) __tg_real_complex(exp, (x)) -#define exp2(x) __tg_real(exp2, (x)) -#define expm1(x) __tg_real(expm1, (x)) -#define fabs(x) __tg_real_complex_fabs(x) -#define false 0 -#define fdim(x,y) __tg_real_2(fdim, (x), (y)) -#define fgetpos64 fgetpos -#define floor(x) __tg_real(floor, (x)) -#define fma(x,y,z) __tg_real_fma((x), (y), (z)) -#define fmax(x,y) __tg_real_2(fmax, (x), (y)) -#define fmin(x,y) __tg_real_2(fmin, (x), (y)) -#define fmod(x,y) __tg_real_2(fmod, (x), (y)) -#define fopen64 fopen -#define fpclassify(x) (__builtin_fpclassify(FP_NAN, FP_INFINITE, FP_NORMAL, FP_SUBNORMAL, FP_ZERO, x)) -#define fpos64_t fpos_t -#define freopen64 freopen -#define frexp(x,y) __tg_real_2_1(frexp, (x), (y)) -#define fsblkcnt64_t fsblkcnt_t -#define fseeko64 fseeko -#define fsetpos64 fsetpos -#define fsfilcnt64_t fsfilcnt_t -#define fstat64 fstat -#define fstatat64 fstatat -#define ftello64 ftello -#define ftruncate64 ftruncate -#define getdents64 getdents -#define glob64 glob -#define glob64_t glob_t -#define globfree64 globfree -#define howmany(n,d) (((n)+((d)-1))/(d)) -#define htobe16(x) __bswap16(x) -#define htobe32(x) __bswap32(x) -#define htobe64(x) __bswap64(x) -#define htole16(x) (uint16_t)(x) -#define htole32(x) (uint32_t)(x) -#define htole64(x) (uint64_t)(x) -#define hypot(x,y) __tg_real_2(hypot, (x), (y)) -#define icmp6_data16 icmp6_dataun.icmp6_un_data16 -#define icmp6_data32 icmp6_dataun.icmp6_un_data32 -#define icmp6_data8 icmp6_dataun.icmp6_un_data8 -#define icmp6_id icmp6_data16[0] -#define icmp6_maxdelay icmp6_data16[0] -#define icmp6_mtu icmp6_data32[0] -#define icmp6_pptr icmp6_data32[0] -#define icmp6_seq icmp6_data16[1] -#define icmp_data icmp_dun.id_data -#define icmp_gwaddr icmp_hun.ih_gwaddr -#define icmp_id icmp_hun.ih_idseq.icd_id -#define icmp_ip icmp_dun.id_ip.idi_ip -#define icmp_lifetime icmp_hun.ih_rtradv.irt_lifetime -#define icmp_mask icmp_dun.id_mask -#define icmp_nextmtu icmp_hun.ih_pmtu.ipm_nextmtu -#define icmp_num_addrs icmp_hun.ih_rtradv.irt_num_addrs -#define icmp_otime icmp_dun.id_ts.its_otime -#define icmp_pmvoid icmp_hun.ih_pmtu.ipm_void -#define icmp_pptr icmp_hun.ih_pptr -#define icmp_radv icmp_dun.id_radv -#define icmp_rtime icmp_dun.id_ts.its_rtime -#define icmp_seq icmp_hun.ih_idseq.icd_seq -#define icmp_ttime icmp_dun.id_ts.its_ttime -#define icmp_void icmp_hun.ih_void -#define icmp_wpa icmp_hun.ih_rtradv.irt_wpa -#define ifa_broadaddr ifa_ifu.ifu_broadaddr -#define ifa_dstaddr ifa_ifu.ifu_dstaddr -#define ilogb(x) __tg_real_nocast(ilogb, (x)) -#define ino64_t ino_t -#define ip6_flow ip6_ctlun.ip6_un1.ip6_un1_flow -#define ip6_hlim ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_hops ip6_ctlun.ip6_un1.ip6_un1_hlim -#define ip6_nxt ip6_ctlun.ip6_un1.ip6_un1_nxt -#define ip6_plen ip6_ctlun.ip6_un1.ip6_un1_plen -#define ip6_vfc ip6_ctlun.ip6_un2_vfc -#define isalpha(a) (0 ? isalpha(a) : (((unsigned)(a)|32)-'a') < 26) -#define isascii(a) (0 ? isascii(a) : (unsigned)(a) < 128) -#define isclr(x,i) !isset(x,i) -#define isdigit(a) (0 ? isdigit(a) : ((unsigned)(a)-'0') < 10) -#define isfinite(x) (__builtin_isfinite(x)) -#define isgraph(a) (0 ? isgraph(a) : ((unsigned)(a)-0x21) < 0x5e) -#define isgreater(x,y) (__builtin_isgreater(x, y)) -#define isgreaterequal(x,y) (__builtin_isgreaterequal(x, y)) -#define isinf(x) (__builtin_isinf(x)) -#define isless(x,y) (__builtin_isless(x, y)) -#define islessequal(x,y) (__builtin_islessequal(x, y)) -#define islessgreater(x,y) (__builtin_islessgreater(x, y)) -#define islower(a) (0 ? islower(a) : ((unsigned)(a)-'a') < 26) -#define isnan(x) (__builtin_isnan(x)) -#define isnormal(x) (__builtin_isnormal(x)) -#define isprint(a) (0 ? isprint(a) : ((unsigned)(a)-0x20) < 0x5f) -#define isset(x,i) __bitop(x,i,&) -#define isspace(a) __isspace(a) -#define isunordered(x,y) (__builtin_isunordered(x, y)) -#define isupper(a) (0 ? isupper(a) : ((unsigned)(a)-'A') < 26) -#define iswdigit(a) (0 ? iswdigit(a) : ((unsigned)(a)-'0') < 10) -#define ldexp(x,y) __tg_real_2_1(ldexp, (x), (y)) -#define le16toh(x) (uint16_t)(x) -#define le32toh(x) (uint32_t)(x) -#define le64toh(x) (uint64_t)(x) -#define letoh16(x) (uint16_t)(x) -#define letoh32(x) (uint32_t)(x) -#define letoh64(x) (uint64_t)(x) -#define lgamma(x) __tg_real(lgamma, (x)) -#define llrint(x) __tg_real_nocast(llrint, (x)) -#define llround(x) __tg_real_nocast(llround, (x)) -#define loff_t off_t -#define log(x) __tg_real_complex(log, (x)) -#define log10(x) __tg_real(log10, (x)) -#define log1p(x) __tg_real(log1p, (x)) -#define log2(x) __tg_real(log2, (x)) -#define logb(x) __tg_real(logb, (x)) -#define lrint(x) __tg_real_nocast(lrint, (x)) -#define lround(x) __tg_real_nocast(lround, (x)) -#define lseek(fd,offset,whence) ({ off_t __f = (fd); off_t __o = (offset); off_t __w = (whence); __builtin_constant_p((offset)) && __builtin_constant_p((whence)) && __o == 0 && __w == SEEK_CUR ? __wasilibc_tell(__f) : lseek(__f, __o, __w); }) -#define lseek64 lseek -#define lstat64 lstat -#define math_errhandling 2 -#define mld_cksum mld_icmp6_hdr.icmp6_cksum -#define mld_code mld_icmp6_hdr.icmp6_code -#define mld_maxdelay mld_icmp6_hdr.icmp6_data16[0] -#define mld_reserved mld_icmp6_hdr.icmp6_data16[1] -#define mld_type mld_icmp6_hdr.icmp6_type -#define nd_na_cksum nd_na_hdr.icmp6_cksum -#define nd_na_code nd_na_hdr.icmp6_code -#define nd_na_flags_reserved nd_na_hdr.icmp6_data32[0] -#define nd_na_type nd_na_hdr.icmp6_type -#define nd_ns_cksum nd_ns_hdr.icmp6_cksum -#define nd_ns_code nd_ns_hdr.icmp6_code -#define nd_ns_reserved nd_ns_hdr.icmp6_data32[0] -#define nd_ns_type nd_ns_hdr.icmp6_type -#define nd_ra_cksum nd_ra_hdr.icmp6_cksum -#define nd_ra_code nd_ra_hdr.icmp6_code -#define nd_ra_curhoplimit nd_ra_hdr.icmp6_data8[0] -#define nd_ra_flags_reserved nd_ra_hdr.icmp6_data8[1] -#define nd_ra_router_lifetime nd_ra_hdr.icmp6_data16[1] -#define nd_ra_type nd_ra_hdr.icmp6_type -#define nd_rd_cksum nd_rd_hdr.icmp6_cksum -#define nd_rd_code nd_rd_hdr.icmp6_code -#define nd_rd_reserved nd_rd_hdr.icmp6_data32[0] -#define nd_rd_type nd_rd_hdr.icmp6_type -#define nd_rs_cksum nd_rs_hdr.icmp6_cksum -#define nd_rs_code nd_rs_hdr.icmp6_code -#define nd_rs_reserved nd_rs_hdr.icmp6_data32[0] -#define nd_rs_type nd_rs_hdr.icmp6_type -#define nearbyint(x) __tg_real(nearbyint, (x)) -#define nextafter(x,y) __tg_real_2(nextafter, (x), (y)) -#define nexttoward(x,y) __tg_real_2(nexttoward, (x), (y)) -#define nftw64 nftw -#define no_argument 0 -#define noreturn _Noreturn -#define not ! -#define not_eq != -#define ns_msg_base(handle) ((handle)._msg + 0) -#define ns_msg_count(handle,section) ((handle)._counts[section] + 0) -#define ns_msg_end(handle) ((handle)._eom + 0) -#define ns_msg_getflag(handle,flag) (((handle)._flags & _ns_flagdata[flag].mask) >> _ns_flagdata[flag].shift) -#define ns_msg_id(handle) ((handle)._id + 0) -#define ns_msg_size(handle) ((handle)._eom - (handle)._msg) -#define ns_rr_class(rr) ((ns_class)((rr).rr_class + 0)) -#define ns_rr_name(rr) (((rr).name[0] != '\0') ? (rr).name : ".") -#define ns_rr_rdata(rr) ((rr).rdata + 0) -#define ns_rr_rdlen(rr) ((rr).rdlength + 0) -#define ns_rr_ttl(rr) ((rr).ttl + 0) -#define ns_rr_type(rr) ((ns_type)((rr).type + 0)) -#define ns_t_mrr_p(t) ((t) == ns_t_tsig || (t) == ns_t_opt) -#define ns_t_qt_p(t) (ns_t_xfr_p(t) || (t) == ns_t_any || (t) == ns_t_mailb || (t) == ns_t_maila) -#define ns_t_rr_p(t) (!ns_t_qt_p(t) && !ns_t_mrr_p(t)) -#define ns_t_udp_p(t) ((t) != ns_t_axfr && (t) != ns_t_zxfr) -#define ns_t_xfr_p(t) ((t) == ns_t_axfr || (t) == ns_t_ixfr || (t) == ns_t_zxfr) -#define off64_t off_t -#define offsetof(t,d) __builtin_offsetof(t, d) -#define open64 open -#define openat64 openat -#define optional_argument 2 -#define or || -#define or_eq |= -#define posix_fadvise64 posix_fadvise -#define posix_fallocate64 posix_fallocate -#define pow(x,y) __tg_real_complex_pow((x), (y)) -#define powerof2(n) !(((n)-1) & (n)) -#define pread64 pread -#define preadv64 preadv -#define pwrite64 pwrite -#define pwritev64 pwritev -#define readdir64 readdir -#define remainder(x,y) __tg_real_2(remainder, (x), (y)) -#define remquo(x,y,z) __tg_real_remquo((x), (y), (z)) -#define required_argument 1 -#define rint(x) __tg_real(rint, (x)) -#define round(x) __tg_real(round, (x)) -#define roundup(n,d) (howmany(n,d)*(d)) -#define rr_cksum rr_hdr.icmp6_cksum -#define rr_code rr_hdr.icmp6_code -#define rr_seqnum rr_hdr.icmp6_data32[0] -#define rr_type rr_hdr.icmp6_type -#define scalbln(x,y) __tg_real_2_1(scalbln, (x), (y)) -#define scalbn(x,y) __tg_real_2_1(scalbn, (x), (y)) -#define scandir64 scandir -#define setbit(x,i) __bitop(x,i,|=) -#define signbit(x) (__builtin_signbit(x)) -#define sin(x) __tg_real_complex(sin, (x)) -#define sinh(x) __tg_real_complex(sinh, (x)) -#define sqrt(x) __tg_real_complex(sqrt, (x)) -#define st_atime st_atim.tv_sec -#define st_ctime st_ctim.tv_sec -#define st_mtime st_mtim.tv_sec -#define stat64 stat -#define static_assert _Static_assert -#define stderr (stderr) -#define stdin (stdin) -#define stdout (stdout) -#define strdupa(x) strcpy(alloca(strlen(x)+1),x) -#define tan(x) __tg_real_complex(tan, (x)) -#define tanh(x) __tg_real_complex(tanh, (x)) -#define telcmds ((char [][6]){ "EOF", "SUSP", "ABORT", "EOR", "SE", "NOP", "DMARK", "BRK", "IP", "AO", "AYT", "EC", "EL", "GA", "SB", "WILL", "WONT", "DO", "DONT", "IAC", 0 }) -#define tgamma(x) __tg_real(tgamma, (x)) -#define th_block th_u.tu_block -#define th_code th_u.tu_code -#define th_msg th_data -#define th_stuff th_u.tu_stuff -#define thrd_equal(A,B) ((A) == (B)) -#define thread_local _Thread_local -#define timeradd(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec + (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec + (t)->tv_usec) >= 1000000 && ((a)->tv_usec -= 1000000, (a)->tv_sec++) ) -#define timerclear(t) ((t)->tv_sec = (t)->tv_usec = 0) -#define timercmp(s,t,op) ((s)->tv_sec == (t)->tv_sec ? (s)->tv_usec op (t)->tv_usec : (s)->tv_sec op (t)->tv_sec) -#define timerisset(t) ((t)->tv_sec || (t)->tv_usec) -#define timersub(s,t,a) (void) ( (a)->tv_sec = (s)->tv_sec - (t)->tv_sec, ((a)->tv_usec = (s)->tv_usec - (t)->tv_usec) < 0 && ((a)->tv_usec += 1000000, (a)->tv_sec--) ) -#define true 1 -#define trunc(x) __tg_real(trunc, (x)) -#define uh_dport dest -#define uh_sport source -#define uh_sum check -#define uh_ulen len -#define va_arg(ap,type) __builtin_va_arg(ap, type) -#define va_copy(dest,src) __builtin_va_copy(dest, src) -#define va_end(ap) __builtin_va_end(ap) -#define va_start(ap,param) __builtin_va_start(ap, param) -#define versionsort64 versionsort -#define xEOF 236 -#define xor ^ -#define xor_eq ^= diff --git a/expected/wasm64-wasip2/undefined-symbols.txt b/expected/wasm64-wasip2/undefined-symbols.txt deleted file mode 100644 index e7c62031f..000000000 --- a/expected/wasm64-wasip2/undefined-symbols.txt +++ /dev/null @@ -1,69 +0,0 @@ -__addtf3 -__divtf3 -__eqtf2 -__extenddftf2 -__extendsftf2 -__fixtfdi -__fixtfsi -__fixunstfsi -__floatditf -__floatsitf -__floatunsitf -__getf2 -__gttf2 -__heap_base -__heap_end -__imported_wasi_snapshot_preview1_args_get -__imported_wasi_snapshot_preview1_args_sizes_get -__imported_wasi_snapshot_preview1_clock_res_get -__imported_wasi_snapshot_preview1_clock_time_get -__imported_wasi_snapshot_preview1_environ_get -__imported_wasi_snapshot_preview1_environ_sizes_get -__imported_wasi_snapshot_preview1_fd_advise -__imported_wasi_snapshot_preview1_fd_allocate -__imported_wasi_snapshot_preview1_fd_close -__imported_wasi_snapshot_preview1_fd_datasync -__imported_wasi_snapshot_preview1_fd_fdstat_get -__imported_wasi_snapshot_preview1_fd_fdstat_set_flags -__imported_wasi_snapshot_preview1_fd_fdstat_set_rights -__imported_wasi_snapshot_preview1_fd_filestat_get -__imported_wasi_snapshot_preview1_fd_filestat_set_size -__imported_wasi_snapshot_preview1_fd_filestat_set_times -__imported_wasi_snapshot_preview1_fd_pread -__imported_wasi_snapshot_preview1_fd_prestat_dir_name -__imported_wasi_snapshot_preview1_fd_prestat_get -__imported_wasi_snapshot_preview1_fd_pwrite -__imported_wasi_snapshot_preview1_fd_read -__imported_wasi_snapshot_preview1_fd_readdir -__imported_wasi_snapshot_preview1_fd_renumber -__imported_wasi_snapshot_preview1_fd_seek -__imported_wasi_snapshot_preview1_fd_sync -__imported_wasi_snapshot_preview1_fd_tell -__imported_wasi_snapshot_preview1_fd_write -__imported_wasi_snapshot_preview1_path_create_directory -__imported_wasi_snapshot_preview1_path_filestat_get -__imported_wasi_snapshot_preview1_path_filestat_set_times -__imported_wasi_snapshot_preview1_path_link -__imported_wasi_snapshot_preview1_path_open -__imported_wasi_snapshot_preview1_path_readlink -__imported_wasi_snapshot_preview1_path_remove_directory -__imported_wasi_snapshot_preview1_path_rename -__imported_wasi_snapshot_preview1_path_symlink -__imported_wasi_snapshot_preview1_path_unlink_file -__imported_wasi_snapshot_preview1_poll_oneoff -__imported_wasi_snapshot_preview1_proc_exit -__imported_wasi_snapshot_preview1_random_get -__imported_wasi_snapshot_preview1_sched_yield -__imported_wasi_snapshot_preview1_sock_accept -__imported_wasi_snapshot_preview1_sock_recv -__imported_wasi_snapshot_preview1_sock_send -__imported_wasi_snapshot_preview1_sock_shutdown -__letf2 -__lttf2 -__netf2 -__stack_pointer -__subtf3 -__trunctfdf2 -__trunctfsf2 -__unordtf2 -__wasm_call_ctors