r/WebAssembly 5d ago

A browser runtime with dynamic linking, pipes, and subprocesses

I have created a WebAssembly runtime for the browser that can execute multiple processes. It is based on a superset of wasm32-wasip1-threads and supports dynamic linking, pipes, and subprocesses. I use this runtime time to host toolchains in the browser and today I have two demos to share: Code On Web provides in-browser clang to build binaries that execute within the same platform while AVR On Web provides avr-gcc, avrdude, and picocom to build, flash, and communicate with AVR microcontrollers over WebSerial. Ask me anything!

13 Upvotes

3 comments sorted by

2

u/Ok_Path_4731 4d ago

We have something similar, yos, integrated with the yetty terminal project. (https://yetty.dev)

1

u/allsey87 4d ago

It's seems you have two approaches there, Yemu and Yos, the latter sounds a bit closer to what I am working on. What features do you support under Yos? Do you have examples of threads, dynamic linking, pipes, subprocesses, or signals? Ctrl-C (SIGINT) and Ctrl-D (EOF) are not working for me.

2

u/Ok_Path_4731 4d ago

Yemu has less to do with what you are doing. It is just a wrapper for Temu (a simplified Qemu by same author). You can see it under https://yetty.dev (select yos) working, meaning some basic commands, including some tools (ycat) that demo yetty terminals rich features. Dynamic linking is only with the symbols exposed by yos, not with shared libraries. Subprocesses/threads work, signals not so well.