> You write "It's all the same "clone" code in the kernel."
> and that may be true, but I'm thinking about the glibc wrappers around them.

I only made that point in response to your contrasts between "a dedicated
vfork syscall number" and "a clone call passed CLONE_VFORK | CLONE_VM |
SIGCHLD", for which the kernel's semantics are completely identical.

> In particular, it seems to me that vfork and clone(CLONE_VM|CLONE_VFORK)
> should have similar assembly wrappers around them.  But the
> vfork code uses SAVE_PID/RESTORE_PID which frobs only the pid, not the tid,
> while clone used RESET_PID which frobs both the pid and tid.
> It seems to me they should share common infrastructure.

That makes sense to me, but I have not looked closely at that logic.


Thanks,
Roland

Reply via email to