Explain the advantage of copy-on-write region copying for UNIX, where a call to fork is typically
followed by a call to exec. What should happen if a region that has been copied using copy-on
write is itself copied?

What will be an ideal response?

It would be wasteful to copy the forked process’s address space contents, since they are immediately replaced.
With copy-on-write, only those few pages that are actually needed before calling exec will be copied.
Assume now that exec is not called. When a process forks, its child may in turn fork a child. Call these the
parent, child and grandchild. Pages in the grandchild are logically copied from the child, whose pages are in
turn logically copied from the parent. Initially, the grandchild’s pages may share a frame with the parent’s
page. If, say, the child modifies a page, however, then the grandchild’s page must be made to share the child’s
frame. A way must be found to manage chains of page dependencies, which have to be altered when pages are
modified.

Computer Science & Information Technology

You might also like to view...

What is the output of the following loop?count = 5;cout

A. St B. Sto C. Stop D. This is an infinite loop.

Computer Science & Information Technology

_______ refers to the computer network a business uses to let employees communicate with customers, vendors, and other employees.

A. Enterprise computing B. E-commerce C. BYOD  D. Business management system

Computer Science & Information Technology