TCC, the Tiny C Compiler, has been successfully compiled to WebAssembly with the help of Zig Compiler. This allows TCC to run in a web browser, which is quite an achievement. However, there were some challenges along the way. The WebAssembly platform lacks certain POSIX functions that TCC relies on, so the missing functions had to be added manually. File input and output also had to be emulated since WebAssembly doesn’t have direct file access. Additionally, handling fprintf and similar functions turned out to be tricky due to the complexity of C format strings. Despite these challenges, TCC has been successfully compiled and tested on the Apache NuttX RTOS.
https://lupyuen.codeberg.page/articles/tcc.html