Difference between the fork and vfork system call

Write a short note on the difference between the fork() and vfork() system call?

E

Expert

Verified

All through the fork() system call the Kernel creates a copy of the parent process's address space and attaches it to the child process.

However the vfork() system call don’t creates any copy of the parent's address space, therefore it is faster than the fork() system call. The child process as a outcome of the vfork() system call executes exec() system call. Child process from vfork() system call executes in the parent's address space (or this can overwrite the parent's data and stack) that suspends the parent process till the child process ways out.

   Related Questions in Basic Computer Science

©TutorsGlobe All rights reserved 2022-2023.