You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

How can I increase the hard limit of the stack size?

Hi,
My process gives an error of segmentation fault (SIGSEGV) that is caused because the stack limit is reached. I have a doubt about how to increase the stack size. I have tried change it with "ulimit - hard" but this size is 65532kb, and is very low for my process. How can I increase the hard limit?
Thanks.

Xserve, Mac OS X (10.6.5)

Posted on Dec 30, 2010 4:34 AM

Reply
Question marked as Top-ranking reply

Posted on Dec 30, 2010 5:40 AM

When last I checked, the kernel had a fixed stack size limit.

Do you have the source code to this application? If so, [see this Tiger stack size article|http://homepage.mac.com/eric.c/hpc/contents/documentation/How%20to%20in crease%20the%20stack%20size%20on%20Mac%20OS%20X.pdf], and specifically have a look at the +ld -stack_size+ mechanism; rebuild the code with a bigger limit.

Entirely FWIW, this question would be more typical over in the developer forums or maybe in the Unix forum if you don't have Apple developer access. Better audience for application development and for software-related questions over there.
1 reply
Question marked as Top-ranking reply

Dec 30, 2010 5:40 AM in response to carmen-uv

When last I checked, the kernel had a fixed stack size limit.

Do you have the source code to this application? If so, [see this Tiger stack size article|http://homepage.mac.com/eric.c/hpc/contents/documentation/How%20to%20in crease%20the%20stack%20size%20on%20Mac%20OS%20X.pdf], and specifically have a look at the +ld -stack_size+ mechanism; rebuild the code with a bigger limit.

Entirely FWIW, this question would be more typical over in the developer forums or maybe in the Unix forum if you don't have Apple developer access. Better audience for application development and for software-related questions over there.

How can I increase the hard limit of the stack size?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.