An MLIR Dialect for WebAssembly
summary
Describes an implemented MLIR WebAssembly dialect and a compiler pipeline that skips the LLVM backend by lowering higher-level MLIR dialects (e.g., scf, tensor, memref) directly to a Wasm-like dialect, avoiding Relooper reabstraction. Demonstrates compiling an intermittent-computing DSL to Wasm using the stack-switching proposal for context switches, runs benchmarks AOT on an Apollo4 Cortex-M4 microcontroller, and reports comparable binary-size/performance with some kernels unexpectedly faster despite no pipeline optimizations yet.
AI-written summary · about
chapters (19)
- 0:00Introduction
- 0:29MLIR and WebAssembly background
- 1:33WebAssembly on microcontrollers
- 2:58Compiler infrastructure problems
- 4:00MLIR compilation pipeline
- 6:49Problem and motivation
- 7:10Intermittent computing example
- 9:19Context switching challenges
- 10:01Stack switching proposal
- 11:05Custom compilers for WebAssembly
- 11:47LLVM limitations for WebAssembly
- 13:39MLIR advantages and solution
- 14:23MLIR WebAssembly dialect
- 15:26Tensor and memory conversion
- 16:33Intermittent computing case study
- 17:40MLIR WebAssembly benefits
- 18:45Performance evaluation
- 20:37Future work
- 21:21Q&A
related talks
35mJavaScript ∩ WebAssembly
51mScala.js and WebAssembly, a tale of the dangers of the sea
01h 06mAs low-level as possible, but no lower
37mDecoding the hype behind WebAssembly: Looking under the hood
48mCross-Domain Compilation: Exploiting Synergies Across the CS Community
01h 08mOn WebAssembly
14mI compiled WebAssembly to lambda calculus! A journey into esoteric programming
55mFast And Portable LLM Inference With WebAssembly And Rust
