Extract the messaging vocabulary (arenas, MSG-*/CH-*/MBR-* words) out of capsules/hermes/init.4th into a new shared capsules/common/messaging.4th that Hermes and Artemis each load at birth, giving every VM its own private MSG-ARENA/CH-ARENA instead of only Hermes having one. Hermes stays the owner of the one real, canonical COMMON-CH; Artemis subscribes into it via VM-EXEC at her own birth, and Hermes proactively subscribes Hera (idx 0) since Hera always exists first. Hera does NOT get her own copy: register_child_vm_words()'s own doc comment explains why the STADIUM-* primitives common:messaging.4th depends on are deliberately never registered in her dictionary (keeps her dict_hash off item 4.1's baseline). Confirmed live by loading it into her dictionary anyway first -- every colon-definition referencing an unregistered Stadium primitive was silently dropped (MSG-HEAT@/!, CH-HEAT@/!, MSG-COOL-ALL, MSG-TICK all missing after boot). Reverted that path; she orchestrates via BIRTH/VM-EXEC/VM-CALL instead. Added capsule_vm_registry_get_by_index() (capsule_birth.c/.h) for registry enumeration by birth-order position, and a pump in repl.c's existing idle hook that walks every live VM once per idle beat and VM-EXECs MSG-TICK into each one except Hera's own entry. Verified clean (no UNKNOWN WORD / VM-EXEC errors after birth) on all three architectures. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019ZGkimpfyh63EZyRkNbkPD
23 lines
780 B
Forth
23 lines
780 B
Forth
Block 4855
|
|
( Hermes v1 -- WELCOME. Generic messaging vocab moved to )
|
|
( common:messaging.4th, FABRIC-3.md Phase C 2026-08-28. )
|
|
: WELCOME ( -- ) LOG-INFO" Hermes: loaded" ;
|
|
WELCOME
|
|
Block 4153
|
|
( LOAD-DOE: pulls in doe.4th's word-level DOE-WORK )
|
|
( workload, for doe-campaign.4th's remote VM-EXEC. )
|
|
: LOAD-DOE ( -- ) S" doe.4th" EXEC ;
|
|
Block 5116
|
|
( Hermes owns the one real, canonical COMMON-CH. Every )
|
|
( other VM subscribes into it via VM-EXEC (see Artemis's )
|
|
( and Hera's own init.4th); Hera always exists first, so )
|
|
( Hermes adds her here rather than Hera subscribing to a )
|
|
( VM that doesn't exist yet at Hera's own birth. )
|
|
S" common:messaging.4th" EXEC
|
|
MSG-CD-INIT
|
|
S" lib.4th" EXEC
|
|
1 COMMON-CH @ CH-ADD-MBR
|
|
0 COMMON-CH @ CH-ADD-MBR
|
|
LOG-INFO" Hermes: ready"
|
|
STARTUP-BANNER
|