The number of threads a process can create is limited by the available virtual memory. By default, every thread has one megabyte of stack space. Therefore, you can create at most 2028 threads. If you reduce the default stack size, you can create more threads. However, your application will have better performance if you create one thread per processor and build queues of requests for which the application maintains the context information. A thread would process all requests in a queue before processing requests in the next queue.
多谢楼上,^_^ 不过how to reduce stack size呢? 而且好像没建立一个CCocket的对象系统就自动创建一个线程,那这些线程的堆栈大小又改如何改变呢?怎么取得这些线程的ID?
不过how to reduce stack size呢?
而且好像没建立一个CCocket的对象系统就自动创建一个线程,那这些线程的堆栈大小又改如何改变呢?怎么取得这些线程的ID?
WIN98之类更少