about summary refs log tree commit diff stats
path: root/linux/vocabulary.md
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2021-03-09 00:24:03 -0800
committerKartik K. Agaram <vc@akkartik.com>2021-03-09 00:24:03 -0800
commita77643c66a28bd633ee78ade65a83d2c95ea1835 (patch)
tree371d5a85733da41ac0d4f8ce40745373c20f255c /linux/vocabulary.md
parentcec5ef31b3e383b7bdffe049a8c502a563f6b491 (diff)
downloadmu-a77643c66a28bd633ee78ade65a83d2c95ea1835.tar.gz
.
Diffstat (limited to 'linux/vocabulary.md')
-rw-r--r--linux/vocabulary.md49
1 files changed, 14 insertions, 35 deletions
diff --git a/linux/vocabulary.md b/linux/vocabulary.md
index 81be5238..1356d1d0 100644
--- a/linux/vocabulary.md
+++ b/linux/vocabulary.md
@@ -49,14 +49,7 @@
 
 ### 'system calls'
 
-As I said at the top, a primary design goal of SubX (and Mu more broadly) is
-to explore ways to turn arbitrary manual tests into reproducible automated
-tests. SubX aims for this goal by baking testable interfaces deep into the
-stack, at the OS syscall level. The idea is that every syscall that interacts
-with hardware (and so the environment) should be *dependency injected* so that
-it's possible to insert fake hardware in tests.
-
-But those are big goals. Here are the syscalls I have so far:
+Low-level testable primitives for unsafe SubX code.
 
 - `write`: takes two arguments, a file `f` and an address to array `s`.
 
@@ -89,12 +82,6 @@ But those are big goals. Here are the syscalls I have so far:
   For more details on exit descriptors and how to create one, see [the
   comments before the implementation](http://akkartik.github.io/mu/html/059stop.subx.html).
 
-- `new-segment`
-
-  Allocates a whole new segment of memory for the program, discontiguous with
-  both existing code and data (heap) segments. Just a more opinionated form of
-  [`mmap`](http://man7.org/linux/man-pages/man2/mmap.2.html).
-
 - `allocate`: takes two arguments, an address to allocation-descriptor `ad`
   and an integer `n`
 
@@ -108,22 +95,6 @@ But those are big goals. Here are the syscalls I have so far:
   management, where a sub-system gets a chunk of memory and further parcels it
   out to individual allocations. Particularly helpful for (surprise) tests.
 
-- `time`: returns the time in seconds since the epoch.
-
-- `ntime`: returns the number of nanoseconds since some arbitrary point.
-  Saturates at 32 bits. Useful for fine-grained measurements over relatively
-  short durations.
-
-- `sleep`: sleep for some number of whole seconds and some fraction of a
-  second expressed in nanoseconds. Not having decimal literals can be awkward
-  here.
-
-- ... _(to be continued)_
-
-I will continue to import syscalls over time from [the old Mu VM in the parent
-directory](https://github.com/akkartik/mu), which has experimented with
-interfaces for the screen, keyboard, mouse, disk and network.
-
 ### Functions
 
 The most useful functions from 400.mu and later .mu files. Look for definitions
@@ -180,8 +151,8 @@ doesn't yet parse floating-point literals:
 #### arrays and strings
 
 - `populate`: allocates space for `n` objects of the appropriate type.
-- `copy-array`: allocates enough space and writes out a copy of an array of
-  some type.
+- `copy-array-object`: allocates enough space and writes out a copy of an
+  array of some type.
 - `slice-to-string`: allocates space for an array of bytes and copies the
   slice into it.
 
@@ -189,8 +160,6 @@ doesn't yet parse floating-point literals:
 - `substring`: string, start, length -> string
 - `split-string`: string, delimiter -> array of strings
 
-- `copy-array-object`
-
 #### predicates
 
 - `kernel-string-equal?`: compares a kernel string with a string
@@ -363,6 +332,16 @@ from a slice:
 - `skip-chars-matching-in-slice`: curr, end, delimiter byte -> new-curr (in `eax`)
 - `skip-chars-not-matching-in-slice`:  curr, end, delimiter byte -> new-curr (in `eax`)
 
-#### file system
+#### miscellaneous sensors and actuators
 
 - `open`: filename, write? -> buffered-file
+
+- `time`: returns the time in seconds since the epoch.
+
+- `ntime`: returns the number of nanoseconds since some arbitrary point.
+  Saturates at 32 bits. Useful for fine-grained measurements over relatively
+  short durations.
+
+- `sleep`: sleep for some number of whole seconds and some fraction of a
+  second expressed in nanoseconds. Not having decimal literals can be awkward
+  here.