This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Failure with fork()


on Fri, 28 Jun 2013, at 01:41, Corinna Vinschen thusly quipped:
> I think it's a misconception that this very bug is the culprit of
> Cygwin not running under wine.  Here's why:
> 
> What this bug did was very simple.  On each fork, the child process
> committed 4K more stack than its parent.  The default stacksize for the
> main thread of a process is 2 Megs.  It's a long way for a process to
> take that much space on the stack.  So this problem should be visible
> only in rare circumstances wher the main thread of a parent process
> is already filled and then the child crashes because the 2 Megs are
> overrun.  As I mentioned in my first post to this thread, the testcase
> took almost 500 forks until the problem occured, 485 to be exact.
> 485*4K = 1.9 Megs.
> 
> If anything keeps Cygwin from running under Wine, it's probably some
> different problem, which still need investigating.

At a glance, http://bugs.winehq.org/show_bug.cgi?id=24018#c9 describes a seemingly plausible etiology involving the dcrt0.cc code and differing stack-allocation semantics between wine and windows.

-gmt


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]