Date: Tue, 11 Jan 2000 21:56:58 -0800 (PST) From: Matthew Dillon <dillon@apollo.backplane.com> To: Alexander Litvin <archer@lucky.net> Cc: "Scott Hess" <scott@avantgo.com>, hackers@FreeBSD.ORG Subject: Re: rfork() [was: Concept check] Message-ID: <200001120556.VAA67332@apollo.backplane.com> References: <200001120534.AAA10170@unknown.nowhere.org>
next in thread | previous in thread | raw e-mail | index | archive | help
:> fork1() in the kernel]. rfork(RFMEM) means that the processes share all :> memory - current AND FUTURE. You could use minherit() before fork() to :> share current memory, but not future memory. : :BTW, concerning rfork(RFMEM). Could somebody explain me, why the :following simple program is coredumping: You cannot call rfork() with RFMEM directly from a C program. You have to use assembly (has anyone created a native clone() call yet to do all the hard work?). The reason is that rfork(RFMEM) does not give the new process a new stack, so both the old and new processes wind up on the same original stack and stomp all over each other. -Matt To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200001120556.VAA67332>