@@ -118,6 +118,8 @@ Word grpc_stream(Word service_ptr, Word service_size, Word service_name_ptr, Wor
118118Word grpc_cancel (Word token);
119119Word grpc_close (Word token);
120120Word grpc_send (Word token, Word message_ptr, Word message_size, Word end_stream);
121+ Word secure_getenv (Word name);
122+ Word getpid ();
121123
122124Word set_tick_period_milliseconds (Word tick_period_milliseconds);
123125Word get_current_time_nanoseconds (Word result_uint64_ptr);
@@ -146,6 +148,12 @@ Word wasi_unstable_args_sizes_get(Word argc_ptr, Word argv_buf_size_ptr);
146148void wasi_unstable_proc_exit (Word);
147149Word wasi_unstable_clock_time_get (Word, uint64_t , Word);
148150Word wasi_unstable_random_get (Word, Word);
151+ Word wasi_unstable_fd_filestat_get (Word fd, Word statOut);
152+ Word wasi_unstable_fd_readdir (Word fd, Word buf, Word buf_len, int64_t cookie, Word bufused);
153+ Word wasi_unstable_path_filestat_get (Word fd, Word flags, Word path, Word path_len, Word statOut);
154+ Word wasi_unstable_fd_fdstat_set_flags (Word fd, Word flags);
155+ Word wasi_unstable_sched_yield ();
156+ Word wasi_unstable_poll_oneoff (Word in, Word out, Word nsubscriptions, Word nevents);
149157Word pthread_equal (Word left, Word right);
150158void emscripten_notify_memory_growth (Word);
151159
@@ -163,7 +171,8 @@ void emscripten_notify_memory_growth(Word);
163171 _f (get_current_time_nanoseconds) _f(define_metric) \
164172 _f (increment_metric) _f(record_metric) _f(get_metric) \
165173 _f (set_effective_context) _f(done) \
166- _f (call_foreign_function)
174+ _f (call_foreign_function) _f(getpid) \
175+ _f (secure_getenv)
167176
168177#define FOR_ALL_HOST_FUNCTIONS_ABI_SPECIFIC (_f ) \
169178 _f (get_configuration) _f(continue_request) _f(continue_response) _f(clear_route_cache) \
@@ -172,7 +181,9 @@ void emscripten_notify_memory_growth(Word);
172181#define FOR_ALL_WASI_FUNCTIONS (_f ) \
173182 _f (fd_write) _f(fd_read) _f(fd_seek) _f(fd_close) _f(fd_fdstat_get) _f(environ_get) \
174183 _f (environ_sizes_get) _f(args_get) _f(args_sizes_get) _f(clock_time_get) _f(random_get) \
175- _f (proc_exit) _f(path_open) _f(fd_prestat_get) _f(fd_prestat_dir_name)
184+ _f (proc_exit) _f(path_open) _f(fd_prestat_get) _f(fd_prestat_dir_name) \
185+ _f (fd_filestat_get) _f(fd_readdir) _f(path_filestat_get) _f(fd_fdstat_set_flags) \
186+ _f (sched_yield) _f(poll_oneoff)
176187
177188// Helpers to generate a stub to pass to VM, in place of a restricted proxy-wasm capability.
178189#define _CREATE_PROXY_WASM_STUB (_fn ) \
0 commit comments