What would the kernel be locked while waiting on disk I/O? Shouldn't it
be running another process? It's not DOING anything. The whole idea
behind a multitasking OS is to overlap the I/O of one process with the
CPU usage of another whenever possible. Swapping is an I/O operation.
And for that matter, if every runnable process has pages swapped out so
that they cannot run, then the CPU should be IDLE.
Am I wrong?
>
> If you can't afford to buy more memory, recode the thing. So much thrashing
> looks like you access your data very randomly. Try to process the data
> in a more sequential way, so you just fault after processing a big bunch
> of data. With 700Mb of data and a 512Mb box, at least half of your data
> fit in memory, so under an ideal sequential access you just would page
> 300Mb one time...
>
The process got that large because of a bug in my program. But a
side-effect of that was kernel behavior that didn't make sense to me. I
decided to ask about it.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/