Monday 8 September 2014

vfork() in linux

vfork():


This function creates a child process and block parent (calling process).

It is used to create new processes without copying the page tables of the parent process. This system call avoids the address space and page table copying by suspending the parent process until the child terminates or executes a new binary image. 

It may be useful in performance-sensitive applications where a child is 
created which then immediately issues an execve().


Prototype:
#include <sys/types.h>#include <unistd.h>
pid_t vfork(void);
return type is similar to fork  

No comments:

Post a Comment