Question of the necessity of rebaseall
Fri May 15 06:01:00 GMT 2009
On Thu, May 14, 2009 at 7:37 PM, Christopher Faylor wrote:
> On Thu, May 14, 2009 at 11:23:08PM +0000, Eric Blake wrote:
>>Christopher Faylor writes:
>>We can't say it enough:
>>>>>Read the source.
>>>>Is this a place where using vfork() instead of fork() helps (where it's
>>>>applicable, of course)? If so, we might be able to reduce the number
>>>>of rebase failures in the future just by trying to push other projects
>>>>to use vfork wherever it's substitutable for fork...
>>>In Cygwin vfork == fork.
>>But, if you really wanted to be nice, instead of forcing us to respond
>>to your uneducated guesses, you could implement posix_spawn, and push
>>for more upstream projects (particularly bash) to use it. That is at
>>least one case where people have already implemented posix_spawn on top
>>of fork (and in fact, gnulib has already done so, and m4 uses the
>>gnulib implementation), but where you can also implement it more
>>efficiently on top of native windows semantics if you do it right. And
>>maybe, in the process of seeing how many loose ends there are to get it
>>to have posix_spawn work correctly, you will start to understand why we
>>haven't already implemented it, and why cygwin does fork/vfork the way
> Yes. What he said.
> I meant to reiterate the "Read the source" advice. It really isn't very
> polite to keep asking us to explain things to you when 1) any reasonable
> person would conclude that most of these issues had already been
> discussed to death and 2) there is source code available.
*nod* - didn't mean to stress the tolerance of people who knew better,
just figured I'd try jumping on the asking questions bandwagon while
smarter people were still answering. :) I looked at the source
before asking, noticed that it had a vfork implementation surrounded
that did something other than wrap fork(), and couldn't piece together
if that code is usually compiled with NEWVFORK defined or not. And
since I couldn't think of any reason why the vfork would need to put
the libraries or the rest of the heap in the child's address space
(since it's explicitly undefined behavior if the child tries to call
any functions or assign any variables in them), I figured it was worth
asking. When I couldn't find the answers by checking the list
archives, I figured it wouldn't hurt to ask.
Hope I didn't inconvenience anyone too much; I must just not see why
vfork needs to keep the cygheap.
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
More information about the Cygwin