gnustep-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSThread limits?


From: Marc Wan
Subject: NSThread limits?
Date: Mon, 7 Apr 2008 10:30:36 +0800

hello!

  I am looking to create a server that maintains a pool of a few
hundred threads at a time, and being a fan of objective-c, i had hoped
to be able to use GNUStep to do this on non-mac platforms.

  unfortunately, I don't seem to be able to fork more than about
150-160 threads using
NSThread::detachNewThreadSelector:toTarget:withObject.  on my macs
here, i can easily do 1000 (i didn't test higher).

  after this on Linux, I get:

: Uncaught exception NSInternalInconsistencyException, reason: Unable
to detach thread (unknown error)


  i had worried that this was a linux (ubuntu 6.10 LTS Server) issue,
but /proc/sys/kernel/thread-max says that it'll handle over 143000
threads ... some casual browsing of NSThread.m didn't immediately show
any limitations.

  any idea why this might be happening?

  thanks,
  mark.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]