rfcs
wasmtime
Our great sponsors
rfcs | wasmtime | |
---|---|---|
7 | 141 | |
44 | 11,803 | |
- | 4.4% | |
4.0 | 9.9 | |
18 days ago | 4 days ago | |
Rust | ||
Apache License 2.0 | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
rfcs
-
Blog Post: Next Rust Compiler
I think with Cranelift's investment into an e-graph based optimizer (https://github.com/bytecodealliance/rfcs/blob/main/accepted/cranelift-egraph.md) they are well positioned to have quite competitive performance as a backend.
-
Inko in 2023
They're also actively working in this area, for example the recently added equality saturation framework and the pattern matching DSL it builds on.
-
Wasmtime Reaches 1.0: Fast, Safe and Production Ready!
There's an RFC here: https://github.com/bytecodealliance/rfcs/pull/28 and Saúl Cabrera, the person who is leading this effort and implementing the compiler tier, has a work-in-progress draft PR here: https://github.com/bytecodealliance/wasmtime/pull/4907
We discussed that a bunch in the RFC: https://github.com/bytecodealliance/rfcs/pull/14 . The conclusion was, in short, that the current Wasmtime production users didn't yet require an LTS release process, and the maintenance of an LTS is pretty onerous, so we would come up with one in the future as those requirements become more clear: https://github.com/bytecodealliance/rfcs/pull/14#discussion\_r708638804
wasmtime
-
How to Debug WASI Pipelines with ITK-Wasm
A full debugging session is also possible after LLDB >= 13 and Wasmtime are installed.
-
Using WASM for a plugin system in Rust? (generate code at runtime and then hot reloading it as a library)
The only runtime that at least partially implements component model is wasmtime. But, as everything with component model, it is still WIP.
-
How to run WebAssembly from your Rust Program
//Original Code from https://github.com/bytecodealliance/wasmtime/blob/main/examples/hello.rs //Adapted for brevity use anyhow::Result; use wasmtime::*; fn main() -> Result<()> { println!("Compiling module..."); let engine = Engine::default(); let module = Module::from_file(&engine, "hello.wat")?; //(1) println!("Initializing..."); let mut store = Store::new( &engine, () ); //(2) println!("Creating callback..."); let hello_func = Func::wrap(&mut store, |_caller: Caller<'_, ()>| { println!("Calling back..."); }); //(3) println!("Instantiating module..."); let imports = [hello_func.into()]; let instance = Instance::new(&mut store, &module, &imports)?; println!("Extracting export..."); let run = instance.get_typed_func::<(), ()>(&mut store, "run")?; //(4) println!("Calling export..."); run.call(&mut store, ())?; //(5) println!("Done."); Ok(()) }
-
Ruby Adds Support for WebAssembly: What is WebAssembly and how it benefits Ruby devs?
Running a Wasm application outside the browser requires an appropriate runtime that implements the WebAssembly VM and provides interfaces to the underlying system. There are a few competing solutions in this field, the most popular being wasmtime, wasmer, and WAMR.
-
Blog Post: Next Rust Compiler
In 2022, we merged a project that has a huge impact on compile times in the right scenarios: incremental compilation. The basic idea is to cache the result of compiling individual functions, keyed on a hash of the IR. This way, when the compiler input only changes slightly – which is a common occurrence when developing or debugging a program – most of the compilation can reuse cached results. The actual design is much more subtle and interesting: we split the IR into two parts, a “stencil” and “parameters”, such that compilation only depends on the stencil (and this is enforced at the type level in the compiler). The cache records the stencil-to-machine-code compilation. The parameters can be applied to the machine code as “fixups”, and if they change, they do not spoil the cache. We put things like function-reference relocations and debug source locations in the parameters, because these frequently change in a global but superficial way (i.e., a mass renumbering) when modifying a compiler input. We devised a way to fuzz this framework for correctness by mutating a function and comparing incremental to from-scratch compilation, and so far have not found any miscompilation bugs.
-
Cranelift's Instruction Selector DSL, ISLE: Term-Rewriting Made Practical
If you've got more thoughts on this, filing an issue is always a good way to either start a discussion or at least put the information in a permanent place we can find later! It looks like we don't have any issues related to this in our tracker at the moment.
-
Kernel-WASM: Sandboxed kernel mode WebAssembly runtime for Linux
This actually seems to be experimentally supported by some runtimes, like wasmtime[0].
-
Allocating Heap with Cranelift
So, does someone know how to allocate memory on the heap using Cranelift? I've seen instructions like heap_addr, heap_load and heap_store so there should be some way (altrough I don't understand why we can't use the normal load and store here..). create_heap would be my best guess, but it takes a HeapData which confuses me. Dafuq is an index_type, HeapStyle and offset_guard_size? How do I get a GlobalValue for it? How do I free it? Or maybe I should just use C's malloc/free instead... On the other hand direct support for heaps seems to be removed? Sigh. I'm confused.
-
Is coding in Rust as bad as in C++? A practical comparison
The only path forward here would be to bend rustc/MIR for streaming codegen (and then bolt it to something like lightbeam).
-
Hey Rustaceans! Got a question? Ask here (1/2023)!
But, am I mistaken in thinking that it isn't available for armv6 (based on the releases seen here)
What are some alternatives?
wasmer - 🚀 The leading WebAssembly Runtime supporting WASI and Emscripten
SSVM - WasmEdge is a lightweight, high-performance, and extensible WebAssembly runtime for cloud native, edge, and decentralized applications. It powers serverless apps, embedded functions, microservices, smart contracts, and IoT devices.
quickjs-emscripten - Safely execute untrusted Javascript in your Javascript, and execute synchronous code that uses async functions
wasm-bindgen - Facilitating high-level interactions between Wasm modules and JavaScript
wasm3 - 🚀 A fast WebAssembly interpreter and the most universal WASM runtime
wasm-pack - 📦✨ your favorite rust -> wasm workflow tool!
godot-wasm-engine
trunk - Build, bundle & ship your Rust WASM application to the web.
mold - Mold: A Modern Linker 🦠
pybind11 - Seamless operability between C++11 and Python
PyO3 - Rust bindings for the Python interpreter
wasi-libc - WASI libc implementation for WebAssembly