fork \- spawn new process
are the only ways new processes are created.
the new process's core image is a copy of
that the value returned in the old (parent) process
of the new (child) process,
while the value returned in the child is 0.
Process ID's range from 1 to 30,000.
This process ID is used by
Files open before the fork
are shared, and have a common read-write pointer.
this is the way that standard input and output
files are passed and also how
is the most efficient way of creating a new process
when the fork is to be followed shortly by an exec,
but is not suitable when the fork is not to be followed
wait(2), exec(2), vfork(2)
Returns \-1 and fails to create a process if:
there is inadequate swap space,
the user is not super-user and has too many processes,
or the system's process table is full.
Only the super-user can take the last process-table slot.
(old process return, new process ID in r0)
The return locations in the old and new process
The C-bit is set in the old process if a new
process could not be created.