------- Additional Comments From d dot yu dot bolkhovityanov at inp dot nsk dot su 2004-10-15 09:46 ------- > Use of vfork is still a win if you are going to call execve anyway because the > address space does not need to be copied.
Yes, it is a tiny win, since vfork() doesn't require copying of page tables, as opposed to fork(). But address space isn't copied anyway, thanks to copy-on-write strategy. > > - At least in Linux, vfork()s can't be followed by strace/ltrace, which makes > > debugging obscure situations MUCH harder. > > This is wrong. At least strace has no problem following vfork. >From strace(1) (Fedora Core 2): "Currently (Linux 2.3.25), strace(1) cannot follow vfork() and requires a kernel patch." That is true at least under 2.4; 2.6 shows somewhat better behaviour. But there is a HUGE amount of 2.4 installations, which will remain for long time. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18006