1.3.4 status?

Christopher Faylor cgf@redhat.com
Tue Oct 23 10:07:00 GMT 2001

On Tue, Oct 23, 2001 at 01:15:25PM +1000, Robert Collins wrote:
>----- Original Message -----
>From: "Christopher Faylor" <cgf@redhat.com>
>To: <cygwin-developers@cygwin.com>
>Sent: Tuesday, October 23, 2001 12:23 PM
>Subject: Re: 1.3.4 status?
>> It is possible that a function would call __chkstk when it needed to
>> allocate space beyond a certain limit.  Not every function begins with
>> call to __chkstk/alloca, though.
>objdump shows a large number of calls to __chkstk - particularly in
>functions using inline variables that are large. My 2c is that somewhere
>in gcc there is a heuristic that says "over size x variables get

Right.  gcc has to do a stack probe, causing a guard page exception (on
NT, anyway) which will cause the OS to allocate more space for the
stack.  So, to allocate beyond the current page, you have to touch each
page of the potential new space that you want to allocate.  This causes
new stack space to show up automatically.


More information about the Cygwin-developers mailing list