Implement JS filesystem bridge layer for Emscripten
- Mentors
- Sreeja Kamishetty, Alon Zakai, Thomas Lively
- Organization
- Chromium
- Technologies
- javascript, c++
- Topics
- compilers, web, filesystem
Emscripten is an open-source tool used to translate C/C++ code to WebAssembly, allowing web apps to run with near-native performance. WebAssembly is especially popular for web games and other performance-oriented applications. As of March 2023, Emscripten uses an emulated file system written in JavaScript to support C/C++ file system operations in compiled WebAssembly code. Currently, the mentors are working on WasmFS, an emulated file system built in C++/WebAssembly, for Emscripten. However, WasmFS lacks the JavaScript required to connect the existing JS API to the new C++/WebAssembly file system operations.
The central goal of this project is to build a new JavaScript library modeled after Emscripten’s existing file system library that will call WasmFS functions instead of JavaScript routines. This approach aims to speed up filesystem operations and lay the foundation to add multithreading in the future. That being said, this project does not aim to redesign the filesystem implementation for Emscripten. This project also will not add new functionality to the Emscripten file system. Finally, this project will not attempt to add full multithreading functionality yet.