And if you could treat swap identically with main memory (i.e. access data
directly in swap), that would make sense. Problem is, swap has to be loaded
into main memory to be accessed... so now you need to reserve blocks of main
memory so you have places for swap pages to go. (There is no way to
simultaneously copy a page out to swap and reload it from another block, so
you have to reserve free space for this.)
In effect this is the same problem "in reverse" --- and trying to make it
work leads you to the same kind of situation we have now, except that now it
looks like "RAM overcommit" (= no space to page swap in to) instead of "swap
overcommit" (= no space to page RAM out to). And, swap being more plentiful
and generally cheaper than RAM, no-overcommit is not an option.
(And I'm sure the MM experts all fainted at my attempts at description....)
-- brandon s. allbery [os/2][linux][solaris][japh] allbery@kf8nh.apk.net system administrator [WAY too many hats] allbery@ece.cmu.edu electrical and computer engineering KF8NH carnegie mellon university
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/