diff options
Diffstat (limited to '')
| -rw-r--r-- | CONTEXT.md | 35 |
1 files changed, 35 insertions, 0 deletions
| @@ -116,6 +116,41 @@ message queue. A GUI program is an app; there is no separate "process" | |||
| 116 | concept — the app is its task plus its window. The home terminal is app 0 | 116 | concept — the app is its task plus its window. The home terminal is app 0 |
| 117 | (window 0). | 117 | (window 0). |
| 118 | 118 | ||
| 119 | ## Binary | ||
| 120 | |||
| 121 | A PE32+ file holding executable code that the kernel can load and run | ||
| 122 | without being recompiled into the kernel image. A binary runs against | ||
| 123 | the kernel's exported interface, never by linking kernel state directly. | ||
| 124 | Binaries come in two kinds, separated by **launch surface** rather than | ||
| 125 | implementation: **CLI binaries** live in /bin/cli and run inside a | ||
| 126 | terminal session (invoked by a shell, inheriting its input/output); | ||
| 127 | **GUI binaries** live in /bin/gui and are launchable with no terminal at | ||
| 128 | all — they own their windows — which makes enumerating launchable apps | ||
| 129 | as simple as listing /bin/gui. Every binary runs as its own task — a CLI binary's task is | ||
| 130 | waited on by the calling terminal, a GUI binary's task owns its window. | ||
| 131 | |||
| 132 | ## System image | ||
| 133 | |||
| 134 | The single dd-able FAT filesystem image the build produces: bootloader, | ||
| 135 | kernel, /bin, /etc and seed content on one volume. Imaging it onto a disk | ||
| 136 | yields a complete installed system. Binaries live on the system image | ||
| 137 | under /bin/cli and /bin/gui; the shell finds them by scanning mounted | ||
| 138 | volumes — no volume is privileged. | ||
| 139 | |||
| 140 | ## Loader | ||
| 141 | |||
| 142 | The kernel facility that takes a binary from disk, places it in memory, | ||
| 143 | and starts it. Loading changes no address-space setup — binaries run in | ||
| 144 | the one shared identity-mapped space. | ||
| 145 | |||
| 146 | ## Exports table | ||
| 147 | |||
| 148 | The interface between a binary and the kernel: a versioned table of | ||
| 149 | functions the kernel hands to a binary at entry (output, filesystem, | ||
| 150 | memory, …). The caller constructs it per invocation, so the same binary's | ||
| 151 | output can be aimed at a terminal or into the shell's filter pipeline. | ||
| 152 | All kernel state stays behind the table — a binary never owns a copy of it. | ||
| 153 | |||
| 119 | ## Terminal | 154 | ## Terminal |
| 120 | 155 | ||
| 121 | A program that presents a command line in a window: a text terminal | 156 | A program that presents a command line in a window: a text terminal |
