Showing content from https://github.com/tbfleming/cib below:
tbfleming/cib: clang running in browser (wasm)
Skip to content Navigation Menu
Search code, repositories, users, issues, pull requests...
Saved searches Use saved searches to filter your results more quickly
Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert tbfleming/cib Repository files navigation
Try it at https://tbfleming.github.io/cib/
I'm trying to see how far wasm can go. Is it possible to compile clang to wasm and have it generate code within the browser?
Current status:
- Works in Firefox 57 and Chrome 63
Change log:
- Build EOS contracts: https://tbfleming.github.io/cib/eos.html
- Integrate with user HTML
- Load gists
- Load header libraries in .zip files
- The runtime now consumes much less memory with each press of the Run button
- Standard library globals (e.g.
cout
)
- Global constructors
- Function pointers and virtual functions
- RTTI
Currently missing:
- Global destructors
- Exception handling
- stdin / cin. Waiting on browsers to restore SharedArrayBuffer.
- Create a fresh VM to build with. The build will probably fail if you already have emscripten or clang installed.
- Consider using a high thread-count VM; e.g. an EC2 c5.9xlarge.
- I put the repo in a dedicated volume while building; this aids using spot instances. 100 GB.
Ubuntu 16.04:
sudo apt update
sudo apt upgrade
sudo apt install build-essential cmake ninja-build python nodejs-legacy libncurses-dev unzip libboost1.58-tools-dev
This script:
- Clones needed repos
- Builds an llvm toolchain for targeting WASM
- Builds emscripten
- Invokes emscripten to:
- set up environment
- build emscripten's dependances
- Uses emscripten to build llvm libraries
- Builds the apps
About
clang running in browser (wasm)
Topics Resources Stars Watchers Forks
You can’t perform that action at this time.
RetroSearch is an open source project built by @garambo
| Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4