3 ms·
Technically true, but nobody ever does this because it is a massive waste of CPU cycles. Both OS and "green" threads are meant to switch when doing i/o.
by otabdeveloper4 3y ago
Technically true, but nobody ever does this because it is a massive waste of CPU cycles.
Both OS and "green" threads are meant to switch when doing i/o.
- gpderetta 3y agoUserspace IO is a thing though. Even with traditional kernel side IO, you might not want to attempt a syscall if the socket is known not to be ready. Also when implementing purely userspace synchronization primitives, being able to swap to a different context purely in userspace is nice.