Process API
This lesson briefly discusses the APIs of a process that are available in an operating system.
We'll cover the following
Though we defer discussion of a real process API until a subsequent chapter, here we first give some idea of what must be included in any interface of an operating system. These APIs, in some form, are available on any modern operating system.
Create
An operating system must include some method to create new processes. When you type a command into the shell, or double-click on an application icon, the OS is invoked to create a new process to run the program you have indicated.
Destroy
As there is an interface for process creation, systems also provide an interface to destroy processes forcefully. Of course, many processes will run and just exit by themselves when complete; when they don’t, however, the user may wish to kill them, and thus an interface to halt a runaway process is quite useful.
Wait
Sometimes it is useful to wait for a process to stop running; thus some kind of waiting interface is often provided.
Get hands-on with 1400+ tech skills courses.