aboutsummaryrefslogtreecommitdiff
path: root/docs/ACTOR.md
diff options
context:
space:
mode:
authorGravatar zinc <zinc@downsta.ir> 2026-10-15 14:36:10 +0330
committerGravatar zinc <zinc@downsta.ir> 2026-10-15 14:36:10 +0330
commit24a21f7520ce91681e573833b7f33156e308964a (patch)
tree9b2684173ee515649f4209192d9ed7f4acda6754 /docs/ACTOR.md
parentlsp: hold and shared hovers, completion of the keywords, shared variables mar... (diff)
docs: hold blocks in LEARN.md (36-hold), spec 5.16, ACTOR.md; TODO: m:n scheduler and follow-ups
Diffstat (limited to 'docs/ACTOR.md')
-rw-r--r--docs/ACTOR.md2
1 files changed, 2 insertions, 0 deletions
diff --git a/docs/ACTOR.md b/docs/ACTOR.md
index 2dc6158..629de20 100644
--- a/docs/ACTOR.md
+++ b/docs/ACTOR.md
@@ -4,6 +4,8 @@
actors run asynchronously in separate operating-system processes on the native and portable micro interpreters on posix hosts. each worker has its own vm stack, heap, globals and captured handler state. workers can execute in parallel. these are isolated worker processes, rather than shared-memory threads.
+a worker starts from a copy-on-write snapshot of its parent's vm: the code, the compiler and every page the parent hasn't changed since the snapshot are one set of physical pages for all workers, and an idle worker costs well under a megabyte. globals are still each worker's own. state every actor sees is declared `shared` in a top-level `hold` block, whose functions use it under the block's lock (spec 5.16, LEARN.md "hold blocks").
+
```zc
namespace;
include rt, actor;