C + + / C #
Communicate with the device in two ways:
Synchronization: When you call ReadFile, the function will wait for the system executing the requested operation, before returning.
Asynchronous: ReadFile returned these functions directly, the system yourself to complete the operation on the device, and then notice to complete the operation in some way.
Overlapped I / O
I / O completion ports provide an effective model for handling multiple threads asynchronous I / O requests in the multi-processor systems.
The difference between synchronous and asynchronous:
Synchronization: After I finish one thing and do it again another matter.
Asynchronous: simultaneously dry and more things.
I / O completion ports = IOCP
IOCP are the way in which an app uses a pool of threads to process asynchronous I / O requests. These threads are kernel threads and their only job in life is to process I / O requests. Applications that process many concurrent asynchronous I / O requests can do more quickly and efficiently by using IOCP than by creating threads at the time of the I / O request. When you create a completion port, you can specify a concurrency value which limits the # threads associated with the port. Typically this number = # processors.