Fork and Vfork Analysis:
Before the fork has implemented copy on write, the UNIX designer is concerned about the wasted address space caused by exec immediately after the fork, that is, the efficiency problem when copying the process address space, so the introduction of vfork system calls.
Vfork has a limit, the child process must immediately execute the _exit or EXEC function.
Even if the fork implemented copy on write, the efficiency is not vfork high, but now it is not recommended to use vfork, because almost every vfork implementation, there are more or less a certain problem.
Fork: The child process copies the data segment of the parent process; Vfork: The child process shares the data segment with the parent process.
Fork: The execution order of the parent-child process is indeterminate; Vfork: The child process runs first and then runs after the parent process.
Process---in linux analysis of Fork, vfork, exec function family, process exit mode, etc.