foundry
Foundry OS: the operating system built on the Rustbelt kernel
| author | Tyler Fowler <tyler@localhost> | 2026-10-30 09:46:08 -0700 |
|---|---|---|
| commit | b28995537b66202cae352b31939c1e03b17cdf51 | |
| parent | 692032b71003255489565505a1c124761ac3bc7a | |
| tree | browse files at this commit | |
Stage 14: processes (0.14.0) fork with copy-on-write (refcounted frames, CoW page faults, CR0.WP), vfork and fork-style clone; execve with Linux's argv/envp/auxv stack (AT_PHDR, AT_PAGESZ, AT_ENTRY, AT_RANDOM from virtio-rng, AT_EXECFN...); mmap/munmap/mprotect/brk with VMAs and demand paging (anonymous private and shared, file-backed private); signals: rt_sigaction, rt_sigprocmask, rt_sigreturn with Linux rt_sigframes, kill, pause, default actions incl. stop/continue, SIGSEGV on bad accesses, SIGCHLD, SIGPIPE, EINTR and SA_RESTART; wait4 with Linux status encoding; getppid, exit_group, dup, dup2, dup3, pipe2, fcntl, O_CLOEXEC; process groups and a tty foreground group (Ctrl+C -> SIGINT, Ctrl+Z -> SIGTSTP). Syscalls now return via iretq through a common TrapFrame. The shell uses fork + exec with job control: Ctrl+C, kill, fg, bg. New user programs forktest, cowtest, mmaptest, sigtest and tests/process.rs (11 tests). README: learner chapter on fork/exec, copy-on-write, memory maps and signals; roadmap updated. New boot.png.
| M | scripts/selftest.sh | +11 -0 |
1 file changed, 11 insertions, 0 deletions
@@ -89,6 +89,17 @@ random -d 6 5 getty -1 /dev/hvc0 tile tile -r+# Stage 14: processes. Every program above was started with fork + execve;+# these check the process model itself (each prints "all checks passed").+# Then a background job ended with the kill builtin (SIGTERM: 128+15).+forktest+cowtest+mmaptest+sigtest+start spin 1000+kill %1+wait+kill -l nosuchprogram cd Q: cd A:/tmp