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
Spike: hot reload for compiled programs (fast restart vs in-process patching) #500
Can a compiled Manticore program pick up a source change without a full restart ("hot reload"), and at what cost in complexity? Time-boxed research, not a delivery commitment. Part of epic #498.
Hypotheses to test
Fast restart (baseline): watch → incremental build → relink → exec, with the listening socket handed over (fd inheritance / SO_REUSEPORT). Measure end-to-end latency and whether clients see a gap. Depends on Epic: incremental compilation #498 layers 3 and 5.
In-process patching: changed units built as .so/.dylib, loaded with dlopen, calls routed through a pointer table. Dev-mode only (-O0, no inlining, no monomorphization across units). Patch function bodies whose signature and class layout are unchanged; anything else falls back to (1).
Known blockers to investigate for (2)
Static link vs dlopen (needs a dynamic dev build).
Class layout from MemoryAbi: live objects of a changed class.
Cross-unit code from Monomorphize, InlineClosures, linkonce_odr.
Static props as external-linkage globals.
macOS code signing on loaded images.
Deliverable
A short write-up (docs/design/hot-reload.md) with: a minimal prototype of (1), a feasibility verdict on (2) with a toy example (one function body swapped in a running process), measured latencies, and a go/no-go recommendation. No production code required.
Exit criteria
(1) prototype works on Linux and reports latency.
(2) either a working toy swap, or the specific blocker that kills it, documented.
Activity