~/talk

Compiling Scala js to WebAssembly

Talkat Scala Days 2025 · 2025-08-19..08-21· [webassembly, scala, web-platform]
slides:none on file

Since Scala.js 1.17.0 (Sept 2024) a single build switch produces WebAssembly plus a small JS bridge while preserving Scala.js semantics (except @JSExport). The work adds ~10,000 lines for the WASM backend, redesigns the IR for lambdas to avoid expensive JS crossings, and proposes new WASM features (JS primitive builtins and custom descriptors). Benchmarks show ~30% faster than JS on average, about 2× slower than the JVM, and 10k LOC for the backend with most features working end-to-end.

AI-written summary · about

  1. 0:00Scala.js architecture
  2. 2:28Moving to WebAssembly
  3. 5:13Performance benchmarks
  4. 7:37IR and type system
  5. 12:36JavaScript interoperability
  6. 19:12Boxing and performance
  7. 29:55Language limitations and fixes
  8. 37:00Async and future work
~/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.