webassembly-examples-eratosthenes
Note
This project is just in progress.
Breaking changes will be made sometimes.
This repository provides some examples of WebAssembly implementation compiled from other languages.
Sample programs implement the Sieve of Eratosthenes and calculate max prime below "N" which is given by argument.
Run samples
Check my pages (https://t-katsumura.github.io/webassembly-examples-eratosthenes/).
How to compile or how to run the samples are briefly described there.
Demos
Demos are available for these languages.
To compare WebAssembly and JavaScript, there are also demos of JavaScript and TypeScript
- C (Compiled with emcc)
- C++ (Compiled with em++)
- Go (Compiled with Go)
- Go (Compiled with TinyGo)
- Rust (Compiled with wasm-pack)
- AssemblyScript (Compiled with asc)
- Java (Compiled with JWebAssembly)
- Python (Using pyodide WASM interpreter)
- TypeScript (Not WASM)
- JavaScript (Not WASM)
Contributing
Any contributions are always be appreciated!
- Fork it
- Create feature branch (
git checkout -b <your branch name>
) - Develop on the branch
- Commit your changes (
git commit -m "<commit comment>"
) - Push to the branch (
git push -u origin <your branch name>
) - Create new Pull Request on Github
Git pages are created using docusaurus.
When updating the pages,
- change or add markdown in
website/docs/
- resources of demos are in
website/static/demos/
- run
npm run build
to generate static pages indocs/