▲ | Joker_vD 3 days ago | ||||||||||||||||
> disks are not considered "slow devices". And neither are the tapes. But the pipes, apparently, are. Well, unfortunately, disk^H^H^H^H large persistent storage I/O is actually slow, or people wouldn't have been writing thread-pools to make it look asynchrnous, or sometimes even process-pools to convert disk I/O to pipe I/O, for the last two decades. | |||||||||||||||||
▲ | jstimpfle 2 days ago | parent | next [-] | ||||||||||||||||
There is a misunderstanding. "Slow device" in the POSIX sense is about unpredictability, not maximal possible bandwidth. Reading from a spinning disk might be comparably slow in the bandwidth sense, but it's actually quite deterministic how much data you can shovel to or from it. A pipe on the other hand might easily stall for an hour. The kernel generally can't know how long it will have to wait for more data. That's why pipe reads (as well as writes) are interruptible. The absolute bandwidth number of a harddisk doesn't matter --- in principle you can overload any system such that it fails to schedule and complete all processes in time. Putting aside possible system overload, the "slow device" terminology makes a lot of sense. | |||||||||||||||||
| |||||||||||||||||
▲ | jcalvinowens 21 hours ago | parent | prev [-] | ||||||||||||||||
>> disks are not considered "slow devices". > And neither are the tapes. But the pipes, apparently, are. The "slow vs fast" language is really unfortunate, I realize it's traditional but it's unnecessarily confusing. A better way to conceptualize it IMHO is bounded vs unbounded: a file or a tape contains a fixed amount of data known a priori, a socket or a pipe does not. |