~/talk

Continuing Stack Switching in Wasmtime

Talkat WAW 2025 · on Monday, 2025-01-20· [webassembly, compilers-and-language-design]
links:none on file
slides:none on file

Implements the WebAssembly stack switching proposal in Wasmtime by prototyping with the existing Wasmtime-fiber hand‑written assembly library and runtime FFI calls, then adding a new cranelift instruction that encodes platform‑independent control contexts so generated code performs the switch directly. Development followed prototype → parallel design and incremental replacement → optimized implementation, with an upstream PR pending. Microbenchmarks show a surprising 6x improvement on a hot suspend/resume loop after removing the FFI call overhead.

AI-written summary · about

  1. 0:00Stack switching in Wasmtime
  2. 1:28Stack switching proposal overview
  3. 3:15Asymmetric vs symmetric stacks
  4. 6:06Implementation challenges
  5. 9:38Prototype with fibers and libcalls
  6. 12:06Optimized stack switch instruction
  7. 15:19Benchmarking performance
  8. 16:48Incremental optimization
  9. 18:14Upstreaming and final steps
  10. 18:34Q&A on CPU prediction
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.