Skip to content

Latest commit

 

History

History
16 lines (12 loc) · 784 Bytes

codebase.md

File metadata and controls

16 lines (12 loc) · 784 Bytes
  • The root of the codebase is in main.zig where it inits the VFS, SyscallHandler, and Scheduler (Only one of each of those).
  • You create a new process that runs on the scheduler by calling Scheduler.createProcess().
    • Each Process is run in its own Web Worker.
  • SharedWorkerState is the shared memory between all processes.
  • Remeber the memory for all workers is shared (So your not copying memory into each worker).
  • You can start the testing server using npx serve --config serve.json
  • zig build -Dwasm=false to build in native mode

Scheduling:

  • The Scheduler wraps either the Thread Pool (Native) or the Worker Pool (WASM)
  • The Scheduler should be the main function that controls the array of processes.

Process

  • Resources are part of the process not seperate.