On Thu, Sep 26, 2013 at 10:14:28PM +0800, Shaohua Li wrote: > Hi, > > This is a cleancache backend which caches page to disk, usually a SSD. The > usage model is similar like Windows readyboost. Eg, user plugs a USB drive, > and we use the USB drive to cache clean pages to reduce IO to hard disks. Very interesting! A few thoughts: It seems that this is doing at the page level what bcache/dm-cache do at the block layer. What is the advantage of doing it this way? I've always had an issue with cleancache. It hooks into the page cache eviction code which is an otherwise fast path. Clean page cache eviction is the cheapest kind of memory reclaim. However, cleancache introduces overhead into this path for an uncertain benefit; namely that a future page access, if done before it is dropped from the secondary cache, will be faster. Another side effect of introducing overhead here is in the case of a large memory allocation, the reclaim system can evict a LOT of page cache pages. It seems that with this model, the eviction/reclaim speed is throttled by the SSD write speed. It looks like this set makes quite a few changes outside of the backend itself. I'm sure we would have to come up with some convincing use case in order to justify introducing changes into these highly used paths. I can see this burning out your SSD as well. If someone enabled this on a machine that did large (relative to the size of the SDD) streaming reads, you'd be writing to the SSD continuously and never have a cache hit. Thanks, Seth > > So far I only did some micro benchmark, for example, access files with size > excess memory size. The result is positive. Of course we need solid data for > more real workloads. I'd like some comments/suggestions before I put more time > on it. > > Thanks, > Shaohua > > -- > To unsubscribe, send a message with 'unsubscribe linux-mm' in > the body to majordomo@xxxxxxxxx. For more info on Linux MM, > see: http://www.linux-mm.org/ . > Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a> > -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>