Multiple Resumptions and Local Mutable State, Directly
summary
A compilation strategy and runtime implement lexical effect handlers that support multiple resumptions plus stack-allocated mutable state by using a linked meta-stack of stack chunks and stable prompts, copying stacks only when reference counts require it. The system uses garbage-free reference counting to avoid copies, achieves constant-time capture/resume for single-shot handlers and constant-time state access, provides an LLVM backend for Effekt, shows competitive benchmarks (checkpointing forces copies and is slow in competitors), and forbids resuming inside an active resumption (runtime abort).
AI-written summary · about
chapters (12)
- 0:00Multiple resumptions intro
- 1:48Effect handlers basics
- 3:57Multi-shot handlers with flip
- 5:43Local mutable state challenges
- 8:16Efficient implementation goals
- 10:51Call stack and reset
- 12:19Multi-shot resumptions handling
- 15:58Local mutable state implementation
- 16:41Benchmarking languages
- 18:53Runtime limitations
- 19:37Summary
- 20:21Q&A
related talks
45mThe simplest way to build resilient applications
27mThe simplest way to build resilient applications
48mThe simplest way to build resilient applications
44mThe Simplest Way to Build Resilient Applications
38mContinuations: what have they ever done for us?
27mRecurrence Sets for Proving Fair Non-termination under Axiomatic Memory Consistency Models
21mHow a reborn determinism will disrupt multiplayer games development
01h 06mTransient: Unrestricted Algebraic and Monadic Composability
