Operating system IO model

First of all, we have to distinguish the following IO model:

Blocking IO

Classmate A is waiting for the letter and has been waiting by the mailbox

Non-blocking IO

Classmate B waits for the letter, check the mailbox every other time, wait for the letter to come

Asynchronous IO

Classmate C told classmate E that he would tell me after he got a letter, and then classmate C flew a plane
( as long as he waited, it was all synchronized IO )

IO multiplexing

Classmate F is from a wealthy family and has a bunch of mailboxes.
Classmate F asks classmate G to see someone sending a letter and tells him (the kernel select function, if it is the epoll function, is more efficient),
then F waits for each mailbox and waits for someone to load the letter Into the mailbox. (Recv function)

Signal drive IO

H students to the students I say, it was to deliver the letter to the play signal , the signal went to see H-mail and other letter.


Guess you like

Origin blog.csdn.net/qq_42882717/article/details/112856798