Boost.threads: Setting stack size

Is it possible to set Boost thread stack size? How much is the default thread stack size? In the past also this question has been asked and I saw some answers which indicates that some work was in progress to set thread attributes at the time of its creation. http://lists.boost.org/Archives/boost/2002/06/30327.php Thanks

"Rajpal Dangi" <rajpal.dangi@transerainc.com> writes:
Is it possible to set Boost thread stack size? How much is the default thread stack size?
No, it is not possible to set the stack size. The default is whatever default your OS provides.
In the past also this question has been asked and I saw some answers which indicates that some work was in progress to set thread attributes at the time of its creation. http://lists.boost.org/Archives/boost/2002/06/30327.php
That work has been abandoned. I have plans to allow setting of attributes, such as stack size and priority, but these are not on the cards for now. Anthony -- Anthony Williams | Just Software Solutions Ltd Custom Software Development | http://www.justsoftwaresolutions.co.uk Registered in England, Company Number 5478976. Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL

I second this query. boost.thread is pretty much unusable on AIX as you end up with thread having a stack size of about 96K.
From what I've seen in the code, no stack size (or any other attributes) is specified on thread creation. Unless I'm mistaken, this means the thread is created with whatever the OS assumes to be a reasonnable default. This can be fairly low on some platforms...
IMHO, either an API should be provided to set the stack size or some "more pratical/portable default" should be hard-coded in thread creation. Baptiste. ----- Original Message ----- From: "Rajpal Dangi" <rajpal.dangi@transerainc.com> To: <boost@lists.boost.org> Sent: Thursday, August 14, 2008 3:38 AM Subject: [boost] Boost.threads: Setting stack size
Is it possible to set Boost thread stack size? How much is the default thread stack size?
In the past also this question has been asked and I saw some answers which indicates that some work was in progress to set thread attributes at the time of its creation. http://lists.boost.org/Archives/boost/2002/06/30327.php
participants (3)
-
Anthony Williams
-
Baptiste Lepilleur
-
Rajpal Dangi