THREAD_STACK_SIZE and python performance?

  • Thread starter Stein Morten Sandbech
  • Start date
S

Stein Morten Sandbech

Hi,

I've been googling for any info on the (possible)
effects on python and python applications with
varying values on the THREAD_STACK_SIZE
with respect to performance etc.

The default 0x20000 is way to low when running
a Zope 2.7.4 and Plone 2.0.5 site.

The FreeBSD patch, setting the value to 0x100000
seems to be enough for most of our zope servers,
however, I've noticed that we get an occasional
server death even with this value. This is on normal
load, but handling many and large CMS operations
in zope/plone.

So, any thoughts on even larger thread stacks?

On beforehand, thank you

Stein M. Sandbech

--sms
 
C

Courageous

The FreeBSD patch, setting the value to 0x100000
seems to be enough for most of our zope servers,...

Is that value in /bytes/? In modern solaris implementations
of posix threads, the default stack size is 2 megabytes fo 64
bit machines.

I can't fathom what your performance consideration would be;
I'd think there'd not be one, with any reasonable amount of
memory on your server.

C//
 
J

jfj

Stein said:
The FreeBSD patch, setting the value to 0x100000
seems to be enough for most of our zope servers,
however, I've noticed that we get an occasional
server death even with this value. This is on normal
load, but handling many and large CMS operations
in zope/plone.

Just curious. How much recursion are we talking about here???
Those CMS operations. 100 calls? 1000 calls?

If it's not near that, then the problem should be somewhere else.
So, any thoughts on even larger thread stacks?

Generally there should be no problems. The only case where the
stack size *may* matter AFAIK, may be threads. Because each thread
has its own stack --in non-stackless python-- stack size may be an issue
if it's too much and there are **many** threads. Otherwise, it should
not have any impact on performance.

jfj

# cure to insomnia: when you lay down, try to figure out
# WTF is wrong with you.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,219
Messages
2,571,118
Members
47,737
Latest member
CarleyHarm

Latest Threads

Top