3 ms·
Sorry I replied to the wrong comment, check one child later please ;) The best representation in memory and on disk are usually completely different, while VM w
by antirez 16y ago
Sorry I replied to the wrong comment, check one child later please ;) The best representation in memory and on disk are usually completely different, while VM will force you to use the same for both the worlds.
- btilly 16y agoI can't find the "one child later" that you're referring to. As for the best representation, I am not sure I agree. I agree that the best representation for frequently accessed data and seldom accessed data are frequently very different. Of course normally the former is in RAM while the latter is on disk. However it is not obvious to me that it is at all a bad thing to have some space used in RAM by infrequently accessed data. And if it is not, then you wind up with the solution I suggested. Just write out the data as you want it on disk, into RAM, don't touch it, and let the VM worry about when (and if) it needs to actually be paged to disk. Of course this doesn't work if you're not using virtual memory. :-)