|
|
|
|
|
by abiloe
1333 days ago
|
|
> If you really think about it, the only real difference between main memory blocking and disk blocking is the amount of time they may block. This is a somewhat confusing analysis you have here. Direct read/write from memory for all intents and purposes doesn't block. Why do you say that reads and writes may also block? The reason memory blocks is because it needs to page in or out from secondary storage - which makes this statement "the only real difference between main memory blocking and disk blocking is the amount of time they may block." not really true |
|
Sure it does! Main memory is much slower than cache so on a cache miss the CPU has to stop and wait for main memory to respond. The CPU may even switch to executing some other thread in the meantime (that's what hyperthreading is). But if there isn't another hyperthread ready, the CPU sits idle, wasting resources.
It's not a form of blocking implemented by the OS scheduler, but it's pretty similar conceptually.
> The reason memory blocks is because it needs to page in or out from secondary storage
Nope, that's not what I was referring to (other than in the line mentioning swap).