5 I/O model in network programming

There are 2 main periods in a networking call:

  1. check if the data ready in kernel space
  2. copy data from kernel space to user space (the system function: revcfrom)

Linux provides 5 network programming I/O models

  1. Blocking I/O
  2. Non-Blocking I/O
  3. I/O multiplexing (select, poll and epoll)
  4. Signal Driven I/O
  5. Asynchronous I/O (aio_* functions)

1. Blocking I/O

2. Non-Blocking I/O

3. I/O multiplexing (select, poll and epoll)

4. Signal Driven I/O

5. Asynchronous I/O (aio_* functions)

6. Compare above 5 models


documents:

networkprogrammingmodels.ods

Reference:
https://www.cnblogs.com/jiujuan/p/16564610.html