In fact, I believe that the scheduling engine will not handle this number of threads, since the management tables in the kernel will become quite large.
If possible, I suggest rewriting the application to use asynchronous I / O, select (), or something similar in the OS of your choice.
source
share