Skip to content

Examples of WebAssembly Text WAT + NodeJS WASI in TypeScript

License

Notifications You must be signed in to change notification settings

mishimastar/wat-wasi

Repository files navigation

wat-wasi

About

I decided to learn WASI, but I faced the fact that for WebAssembly Text (WAT) there is no description of the functions that WASI provides.

(I found nothing for NodeJS runtime)

I got all the functions names, but the interfaces are not described, as well as what it does.

Therefore, I began to collect knowledge, mainly from the C resources of the NodeJS, the meaning of functions from the docks of Wasmtime runtime (it differs from the NodeJS's API for WASI).

I write down knowledge in the form of primitive work with functions in this repo.


Done:

Function name Status Description
args_get ✔️ Folder
args_sizes_get ✔️ Folder
clock_res_get ✔️ Folder
clock_time_get ✔️ Folder
environ_get ✔️ Folder
environ_sizes_get ✔️ Folder
fd_advise
fd_allocate
fd_close
fd_datasync
fd_fdstat_get
fd_fdstat_set_flags
fd_fdstat_set_rights
fd_filestat_get
fd_filestat_set_size
fd_filestat_set_times
fd_pread
fd_prestat_get
fd_prestat_dir_name
fd_pwrite
fd_read ✔️ Folder
fd_readdir
fd_renumber
fd_seek
fd_sync
fd_tell
fd_write ✔️ Folder
path_create_directory
path_filestat_get
path_filestat_set_times
path_link
path_open
path_readlink
path_remove_directory
path_rename
path_symlink
path_unlink_file
poll_oneoff
proc_exit
proc_raise
random_get ✔️ Folder
sched_yield
sock_recv
sock_send
sock_shutdown

About

Examples of WebAssembly Text WAT + NodeJS WASI in TypeScript

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published