Re: thread limit in python

2005-08-13 Thread Bryan Olson
Peter Hansen wrote: > Bryan Olson wrote: > >> Peter Hansen wrote: >> > My question was in the context of the OP's situation. What >> possible use >> > for 1000 OS threads could he have? >> >> Is this a language thing? Surely you realize that "what possible >> use could be" carries an i

Re: thread limit in python

2005-08-13 Thread Peter Hansen
Bryan Olson wrote: > Peter Hansen wrote: > > My question was in the context of the OP's situation. What possible use > > for 1000 OS threads could he have? > > Is this a language thing? Surely you realize that "what possible > use could be" carries an insinuation that is not > such a good ide

Re: thread limit in python

2005-08-13 Thread Bryan Olson
Peter Hansen wrote: > My question was in the context of the OP's situation. What possible use > for 1000 OS threads could he have? Is this a language thing? Surely you realize that "what possible use could be" carries an insinuation that is not such a good idea. Possible uses are many and per

Re: thread limit in python

2005-08-13 Thread Peter Hansen
Bryan Olson wrote: > Peter Hansen wrote: > > Probably, but I haven't yet seen anyone ask the real important question. > > What possible use could you have for more than 1000 *simultaneously > > active* threads? There are very likely several alternative approaches > > that will fit your use ca

Re: thread limit in python

2005-08-12 Thread Christopher Subich
[EMAIL PROTECTED] wrote: > i modified my C test program (included below) to explicitly set the > default thread stack size, and i'm still running into the same > problem. can you think of any other thing that would possibly be > limiting me? Hrm, you're on an A64, so that might very well mean you

Re: thread limit in python

2005-08-12 Thread Bryan Olson
Peter Hansen wrote: > Probably, but I haven't yet seen anyone ask the real important question. > What possible use could you have for more than 1000 *simultaneously > active* threads? There are very likely several alternative approaches > that will fit your use case and have better characteri

Re: thread limit in python

2005-08-12 Thread Peter Hansen
[EMAIL PROTECTED] wrote: > and sorry to continue to post here. since this is occurring in both c > and python, i think there's no question i'm running into an os limit. Probably, but I haven't yet seen anyone ask the real important question. What possible use could you have for more than 1000

Re: thread limit in python

2005-08-12 Thread danieldsmith
i modified my C test program (included below) to explicitly set the default thread stack size, and i'm still running into the same problem. can you think of any other thing that would possibly be limiting me? and sorry to continue to post here. since this is occurring in both c and python, i thi

Re: thread limit in python

2005-08-11 Thread Bryan Olson
[EMAIL PROTECTED] wrote: > disregard the C example. wasn't checking the return code of > pthread_create. the C program breaks in the same place, when creating > the 1021st thread. So that's pretty good evidence that it's an OS limit, not a Python limit. The most likely problem is that the sta

Re: thread limit in python

2005-08-11 Thread danieldsmith
disregard the C example. wasn't checking the return code of pthread_create. the C program breaks in the same place, when creating the 1021st thread. -- http://mail.python.org/mailman/listinfo/python-list

Re: thread limit in python

2005-08-11 Thread danieldsmith
also, on the same box a similar C program (posted below) has no problem starting 5000+ threads. #include #include #include #include void * run (void *arg) { sleep(1000); } int main(int argc, char *argv[]) { int j; pthread_t tid; int num_threads = atoi(argv[1]); for (j=0; j

thread limit in python

2005-08-11 Thread danieldsmith
hello all, i have run into a problem where i cannot start more than 1021 threads in a python program, no matter what my ulimit or kernel settings are. my program crashes with 'thread.error: can't start new thread' when it tries to start the 1021st thread. in addition to tweaking my ulimit setting