CH 3
CH 3
• Processes : A program becomes a process when an executable file is loaded into the memory and
then becomes an active entity.
• Program : is a passive entity such as the file that contains the list of instructions stored on a disk
always referred to as an executable file.
• Processes include not only a text but also include a set of resources such as open files and pending
signals.
• Processes also contain internal kernel data, processor state, an address space, and a data section.
• OS must allocate resources to processes enable sharing of information, protect resources, and enable
the synchronization among processes.
• Process Control Block (PCB): contains information associated with each process: process state, PC,
CPU registers, scheduling information, accounting information, I/O status information
• Accounting information >CPU used, clock time elapsed since start, time limits
• I/O status information >I/O devices allocated to process, list of open files
As a process executes, it changes state
Process Scheduling
• Job queue: set of all processes in the system
• Medium-term scheduler
#◦ Remove process from memory, store on disk, bring back in from disk to continue execution: swapping
• Processes within a system may be independent or cooperating
Shared memory
Message passing