I / O completion port vs QueueUserApc?

On Windows, there are two ways to insert work items to avoid too many threads:

Tools 1: Use IOCP;

Tool 2: Use QueueUserApc.

However, tool 1 is much more complicated than tool 2.

So my question is: what are the benefits of funds 1 relative to the values ​​of funds 2?

+5
source share
1 answer

When you call QueueUserApc, you must specify a specific thread.

IOCP , QueueUserApc , . ( ) ( ).

Windows , IOCP. , , . , - , , IOCP, , .

, IOCP I/O, - , IOCP. - Windows.

+7

All Articles