当前位置:网站首页>Synchronous / asynchronous, blocking / non blocking and IO
Synchronous / asynchronous, blocking / non blocking and IO
2022-07-29 07:18:00 【HTmonster】
Synchronous and asynchronous
- The key : Can you Work at the same time

Blocking and non blocking
- The key : Can you dynamic

A combination of two
Synchronous blocking
- Possible performance : A thread is waiting

Synchronous nonblocking
- Possible performance : A thread is running normally

Asynchronous blocking
- Possible performance : Multiple threads are waiting

Asynchronous non-blocking
- Possible performance : Multiple threads are running normally

I/O operation
- The process 1: Wait for the data
- The process 2: Reading and writing 、 Copy the data
Blocking IO And non blocking IO
Blocking IO: User processes participate in the above two processes , Blocked in IO Process

Non blocking IO: User processes do not need to participate in the above two processes , When it's done , The kernel notifies the user thread

asynchronous IO And signal driven IO
- Signal driven IO: When descriptor data is ready , By producing SIGIO The signal initiates a call to the application signal correlation function , Applications can be accessed through recvfrom Copy data ( You also need to copy it yourself )

- asynchronous IO: The application program can return immediately after triggering the system call , The kernel sends a signal to the application after the data copy is completed , Trigger application logic .( You don't need to copy it yourself )

Model comparison

边栏推荐
猜你喜欢

CVPR2021| 基于自监督学习的多视图立体匹配 (CVPR2021)

同步/异步、阻塞/非阻塞 与 IO

Ethernet interface introduction

实现改变一段文字的部分颜色效果

个人博客系统(附源码)

Use vscode to configure Mysql to realize connection, query, and other functions

Operator3-设计一个operator

上采样之反卷积操作

Win11 system error: code execution cannot continue because ierutil.dll cannot be found. Reinstalling the program may fix this problem

接口测试实战项目03:执行测试用例
随机推荐
数组的子集不能累加出的最小正数
Nodejs installation tutorial
Use vscode to configure Mysql to realize connection, query, and other functions
Leetcode 879. profit plan
Win11vmware turns on the virtual machine and restarts on the blue screen and the solution that cannot be started
win11VMware打开虚拟机就蓝屏重启以及启动不了的解决方案
2022-07-28:以下go语言代码输出什么?A:AA;B:AB;C:BA;D:BB。 package main import ( “fmt“ ) func main() { f
Flink real-time warehouse DWD layer (transaction domain - additional purchase dimension degradation processing) template code
Unity sends a post request to the golang server for parsing and returning
pytest合集(7)— 参数化
太空射击第17课: Game Over (結束)
Nodejs安装教程
DM data guard cluster setup
JS 鸡生蛋与蛋生鸡问题,Object与Function究竟谁出现的更早?Function算不算Function的实例?
接口测试实战项目03:执行测试用例
Vmware16 create virtual machine: win11 cannot be installed
Operator3 - design an operator
route的meta配置项
Comparison of advantages between can & canfd integrated test analysis software lkmaster and PCA Explorer 6 analysis software
Record - step on the pit - real-time data warehouse development - doris/pg/flink