Documente Academic
Documente Profesional
Documente Cultură
Process creation:
A process may create several new processes using
create-process system call during the execution of
process. The creating process is called parent process
and the new processes are called children of that
processes, forming a tree of processes.
Most OS identify the processes according to a unique
process identifier (pid), which is typically an integer
number
Parent and children can share all resources. Children
share subset of parents resources, but parent and child
share no resources.
When a process creates a new process, two possibilities
exist in terms of execution:
Parent and children execute concurrently.
Parent waits until children terminate.
Process Termination:
Process executes last statement and asks the OS to
delete it by using the exit system call.
Output data from child to parent via wait system call.
Processs resources are deallocated by OS
Parent may terminate execution of children processes
via abort system call for a variety of reasons, such as:
Child has exceeded allocated resources.
Task assigned to child is no longer required.
Parent is exiting, and the operating system does not
allow a child to continue if its parent terminates.
A UNIX example to terminate a process is system call
exit().
Contiguous Allocation:
Main memory usually into two partitions:
1. Resident OS, usually held in low memory
with interrupt vector.
2. User processes held in high memory
Non-Contiguous Allocation:
Paging:
Memory-management scheme that permits the
physical address space of a process to be
noncontiguous.
Process is allocated physical memory whenever it
is available.
Paging avoids external fragmentation and the
need for compaction.
Divide physical memory into fixed-sized blocks
called frames (size is power of 2, between 512
bytes and 8192 bytes).
Divide logical memory into blocks of same size
called pages.
Ans: