delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2009/07/05/09:46:32

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.2 required=5.0 tests=AWL,BAYES_00,J_CHICKENPOX_52,J_CHICKENPOX_83
X-Spam-Check-By: sourceware.org
Date: Sun, 5 Jul 2009 15:45:24 +0200 (CEST)
From: Klaus Grue <grue AT diku DOT dk>
To: Dave Korn <dave DOT korn DOT cygwin AT googlemail DOT com>
Cc: cygwin AT cygwin DOT com
Subject: Re: How to spawn from big-stack program
In-Reply-To: <4A509DC5.6070506@gmail.com>
Message-ID: <Pine.LNX.4.64.0907051527190.3589@tyr.diku.dk>
References: <af075b00906260708h674121f3s63fdc79af5675a44 AT mail DOT gmail DOT com> <416096c60906270139y33e2888cq148430eebb744b71 AT mail DOT gmail DOT com> <20090628103010 DOT GT30864 AT calimero DOT vinschen DOT de> <af075b00907020941i666bed61vc450315c662b757a AT mail DOT gmail DOT com> <20090702174425 DOT GC9839 AT ednor DOT casa DOT cgf DOT cx> <af075b00907030218p54b606ds813e824422de04fa AT mail DOT gmail DOT com> <20090703104423 DOT GA18746 AT calimero DOT vinschen DOT de> <20090703150212 DOT GA26858 AT ednor DOT casa DOT cgf DOT cx> <20090704161431 DOT GB11034 AT ednor DOT casa DOT cgf DOT cx> <20090705001152 DOT GA2510 AT ednor DOT casa DOT cgf DOT cx> <416096c60907050233q344d37cds41859c611c7ab660 AT mail DOT gmail DOT com> <Pine DOT LNX DOT 4 DOT 64 DOT 0907051226240 DOT 2008 AT tyr DOT diku DOT dk> <4A509DC5 DOT 6070506 AT gmail DOT com>
MIME-Version: 1.0
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Hi Dave,

>> Can anyone tell me how to invoke a program from a big-stack program ...
> The problem is not spawning the new executable.  The problem is ...
Thanks for the explanation.

> ...
> 955 cygthread *h = new cygthread (proc_waiter, 0, this, "proc_waiter");
> ...
And thanks for the very accurate file/line references into the Cygwin 
source. I first tried making a patch but lost track in spawn.cc.

> It's possible we could tweak cygwin to not use the default thread stack size
> for these internal threads.

Sounds like a good solution.

> If you want a workaround, you could try leaving the default thread size in
> your executable, and in your main() function use pthread_create to spawn a
> worker thread to do the real processing, having set a large stacksize for it
> using the related pthread_attr_setstacksize function.

I will try that.

>> On the Vista machine I did
>>   cygcheck -s -v -r > cygcheck.out
>> I stopped it after it had generated 10MB of output...

> Hmm, are you running with a slightly outdated version? ...

Maybe - but then that would be a problem in itself: I installed Cygwin 
on my Vista machine yesterday by clicking setup.exe on cygwin.com. That 
machine has never run Cygwin before, so my cygcheck must be the cygcheck 
of yesterday.

In any case: thanks for the help.

Cheers,
Klaus

--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019