IO
Operating Systems / Linux · 4 notes
- I/O Modelshistorical
[toc] 1. Synchronous vs Asynchronous When an application invokes a system call, who handles the process? In the former, I ask you Synchronous means the application handles it itself. In the latter, you notify me Asynchronous means the operating syste
- select, poll, epollhistorical
1. select Several major disadvantages of select: Every time select is called, the fd set needs to be copied from user space to kernel space. This overhead becomes large when there are many fds. At the same time, each select call requires the kernel t
- I/Ohistorical
1. What Is a File? A file consists of a sequence of bytes. Under Linux, everything is a file. All I/O devices are files. /dev/sda2 (/usr disk partition) /dev/tty2 (terminal) The kernel is also a file. /boot/vmlinuz 3.13.0 55 generic (kernel image) /p
- Zero-Copy Mechanismhistorical
[toc] 1. Traditional I/O The normal data processing flow is: 1. Use DMA copy (CPU participation is not required) to copy data from disk to the disk buffer. 2. Use CPU copy to copy data from the disk buffer to user space. 3. Process it in user space.