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
{{ message }}
Repository navigation
doc: wasm docs wrongly say the backend never sees fused opcodes #607
docsDocumentationengineIssues with the rust-based simulation enginehygieneToil, but its useful to get get too behind on itrustPull requests that update Rust code
Three sentences still say the wasm backend only ever sees un-fused opcodes, which is wrong.
The peephole pass in ByteCodeBuilder::finish() emits AssignConstCurr, BinOpAssignCurr and BinOpAssignNext before the bytecode is cached, so the wasm backend sees them in nearly every model; only fuse_three_address in Vm::new is private to the VM.
The code handles this, and src/simlin-engine/src/wasmgen/lower.rs documents both passes correctly.
Fix
Reword to match lower.rs:
docs/design-plans/2026-05-20-wasm-backend.md, lines 106 and 130
the rustdoc in src/simlin-engine/src/wasmgen/module.rs around line 550 ("plain, un-fused scalar set")
changed the title [-]wasm-backend plan: false 'CompiledSimulation is fully un-fused' premise misleads un-executed phases 2-8[/-][+]doc: wasm design plan wrongly says the backend never sees fused opcodes[/+]on Oct 12, 2026
changed the title [-]doc: wasm design plan wrongly says the backend never sees fused opcodes[/-][+]doc: wasm docs wrongly say the backend never sees fused opcodes[/+]on Oct 12, 2026
Closing: 12b1df5 corrects the design plan and the rustdoc in wasmgen/module.rs to say the backend sees the peephole-fused assignments; only the late 3-address fusion is private to the VM.
docsDocumentationengineIssues with the rust-based simulation enginehygieneToil, but its useful to get get too behind on itrustPull requests that update Rust code
Activity
engine: WebAssembly simulation backend with full VM parity (#620)
[-]wasm-backend plan: false 'CompiledSimulation is fully un-fused' premise misleads un-executed phases 2-8[/-][+]doc: wasm design plan wrongly says the backend never sees fused opcodes[/+][-]doc: wasm design plan wrongly says the backend never sees fused opcodes[/-][+]doc: wasm docs wrongly say the backend never sees fused opcodes[/+]bpowers commentedon Oct 12, 2026
Closing: 12b1df5 corrects the design plan and the rustdoc in
wasmgen/module.rsto say the backend sees the peephole-fused assignments; only the late 3-address fusion is private to the VM.