This is the mail archive of the
mailing list for the Cygwin project.
Re: Failure with fork()
- From: Corinna Vinschen <corinna-cygwin at cygwin dot com>
- To: cygwin at cygwin dot com
- Date: Fri, 28 Jun 2013 10:41:57 +0200
- Subject: Re: Failure with fork()
- References: <alpine dot DEB dot 2 dot 02 dot 1306272257220 dot 27492 at enira dot zlyna dot ubzr> <51CD4177 dot 1040708 at gmail dot com>
- Reply-to: cygwin at cygwin dot com
On Jun 28 09:55, marco atzeri wrote:
> Il 6/28/2013 8:42 AM, Alan W. Irwin ha scritto:
> >I am getting absolutely nowhere.
> >I didn't get these hangs a month ago when I tried all this
> >before with wine-1.5.19. Instead, at that time I got the exact error
> >message when running the above script concerning an unhandled page
> >fault that others have described at
> >http://bugs.winehq.org/show_bug.cgi?id=24018 and which the fork-fixed
> >cygwin1.dll is supposed to fix. So presumably Cygwin's
> >bash.exe or some application executed by the above script has
> >changed in the last month to cause the different wine symptoms.
> >Or I am inadvertently doing something different than I did a month
> >So unless someone can suggest a method to get around the "Can't open
> >package database for writing. File exists." message, and assuming
> >that method doesn't subsequently run into the script hang (which is a
> >big if), then I think it is time for someone with a lot more wine and
> >cygwin expertise than me to take over here to attempt to try and
> >figure out a way to run setup.exe on Wine with fork-fixed cygwin1.dll
> >overwriting the buggy version.
> Hi Alan,
> I assume you are not testing on wine for fun, but cygwin on wine
> seems a real problem as the bug can be in any of the two platforms.
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.
> Could you clarify the original scope ?
> Eventually we can test in your behalf.
> As alternative to wine, if I am not wrong, Corinna when testing
> cygwin on several platforms (32/64, XP, W7, W8 , Server...) is
> using some VM
Yes, I'm running VMs using Qemu/KVM with each Windows version since NT4
as guests. Of course, that doesn't mean Cygwin should not run under
Wine, but it's not exactly a pressing issue from my POV. I appreciate
any debugging efforts, but that probably requires somebody more fluent
with Wine internals.
Corinna Vinschen Please, send mails regarding Cygwin to
Cygwin Maintainer cygwin AT cygwin DOT com
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple