c++ - Increasing MAXIMUM_WAIT_OBJECTS for WaitforMultipleObjects -


what simplest way wait more objects maximum_wait_objects? msdn lists this:

  • create thread wait on maximum_wait_objects handles, wait on thread plus other handles. use technique break handles groups of maximum_wait_objects.
  • call registerwaitforsingleobject wait on each handle. wait thread thread pool waits on maximum_wait_objects registered objects , assigns worker thread after object signaled or time-out interval expires.

but neither them clear. situation waiting array of on thousand handles threads.

if find waiting on tons of objects might want io completion ports instead. large numbers of parallel operations iocp more efficient.

and name iocp misleading, can use iocp own synchronization structures well.


Comments

Popular posts from this blog

c# - How to set Z index when using WPF DrawingContext? -

razor - Is this a bug in WebMatrix PageData? -

visual c++ - Using relative values in array sorting ( asm ) -