Professional Documents
Culture Documents
OS Individual Exam
OS Individual Exam
Programmed I/O
Interrupt Driven I/O
Direct Memory Access(DMA)
While reading and writing large block of data it is
recommended to use Direct Memory Access(DMA).
Concurrency:
Concurrency means where two different tasks or threads start
working together in an overlapped time period does not mean
they run at same instant.
Parallelism:
Parallelism is where two or more different tasks start their
execution at the same time.It means that the two tasks or
threads start working simultaneously.
6.
Here balance is shared variable between two
processes.Race condition occurs when both processtry to use
the shared variable balance.
Only one process can use the resource at a time , we use binary
semaphore. so that only one process can use it. We add process
to an associated queue of processes that are waiting on that
semaphore allowing the semaphore to block the process and
then again wake it when semaphore is incremented. The
process should be added according to the timestamp of arrival.
We need a maximum allowed time for process to complete
after which resource is snatched otherwise it will process
forever.
9.