From owner-freebsd-threads@FreeBSD.ORG Fri Nov 19 18:09:35 2004 Return-Path: Delivered-To: freebsd-threads@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0C8C316A4CE; Fri, 19 Nov 2004 18:09:35 +0000 (GMT) Received: from mail.ntplx.net (mail.ntplx.net [204.213.176.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id A4B1843D41; Fri, 19 Nov 2004 18:09:34 +0000 (GMT) (envelope-from deischen@freebsd.org) Received: from sea.ntplx.net (sea.ntplx.net [204.213.176.11]) iAJI9V6f006854; Fri, 19 Nov 2004 13:09:31 -0500 (EST) Date: Fri, 19 Nov 2004 13:09:31 -0500 (EST) From: Daniel Eischen X-X-Sender: eischen@sea.ntplx.net To: Joe Marcus Clarke In-Reply-To: <419E32EC.8070400@FreeBSD.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Scanned: by AMaViS and Clam AntiVirus (mail.ntplx.net) cc: Alexander Nedotsukov cc: freebsd-threads@freebsd.org Subject: Re: Question about our default pthread stack size X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Daniel Eischen List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Nov 2004 18:09:35 -0000 On Fri, 19 Nov 2004, Joe Marcus Clarke wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Daniel Eischen wrote: > | On Fri, 19 Nov 2004, Alexander Nedotsukov wrote: > | > | > |>Hey guys, > |> > |>After squashing yet another "too small thread stack size" bug in > |>software developed on Linux. I decided to ask gurus for the comment. Why > |>we still insist that 64K is good enough for 32bit archs? I do understand > | > | > | I suggested we double the stack size for 64-bit archs (making it > | 128K). I could see going to 256K for 32-bit and 512K for 64-bit. > > ia64 already uses a 256 KB default stack size. However, I argue that is > is "too small." Linux has a much higher default (inline with the > document bland referenced), and thus, most popular multithreaded > applications are developed with that in mind. > > It has become some problematic for GNOME, for example, that I have > hacked glib20 to allocate a default 1 MB stack on all architectures > (this is, of course, configurable). The thing I worry about is these piggy applications being the driving force behind our stack size. If they really are designed to need a huge stack size, they should be the ones that change to support it, not the other way around. Do they know their own stack space requirements or do they just ignore it because it isn't a problem so far (on Linux)? What if they need more than 1MB in a few months (Bill Gates -- who's ever going to need more than 64K ;-)? Are we going to change again? I can see raising the default stack size, but 1MB (32-bit) and 2MB (64-bit) seem kinda large. -- DE