lkml.org 
[lkml]   [1999]   [Nov]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: vfork
"Theodore Y. Ts'o" wrote:

> Date: Mon, 1 Nov 1999 14:26:26 +0100 (MET)
> From: Andries.Brouwer@cwi.nl
>
> People tell me that vfork() no longer is equivalent to fork()
> as the manpage states. Unfortunately, they are right, so I
> wrote a new page - see below.
>
> I consider the introduction of vfork into Linux a very bad move
> (as will be clear from the text I wrote), but since there were
> people writing code and submitting patches there must be some
> positive side to this horrible kludge.
>
> While in general, I agree with you that vfork is not the nicest thing in
> the world, it's not necessarily much worse than some of the other things
> you can do with sys_clone(), which also allows two processes to share
> virtual memory space.
>
> Despite BSD's man page warning off folks from depending on vfork's
> semantics, there were programs --- including BSD's csh, which did use
> vfork() so that the path hashing statistics could be accurately updated.
> So, there is some excuse for actually implementing vfork() in the
> traditional bad old way.
>
> I think you were being a little bit too harsh, myself, but it is true
> that warning people that using it compromises the portability of their
> programs is perfectly fair.

Concur, all round. However, we've now had 'vfork() == fork()' being generally
advertised for some time. I know programmers, therefore (many of whom I'd not
care to share an office with, but that's another thing entirely) who
reflexively have used vfork() everywhere 'because it's the same as fork, but
might be better than fork one day'.

Post _big_ warnings. Some things will break. Things that should have been
written differently to begin with, mind you.

D


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:54    [W:0.109 / U:0.228 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site