The simple memory cache from Randall's article provides data expiration. It never returns cached data older than the timeout period. With its 15x speed improvement over simple MySQL queries, it could be useful for caching simple persistent objects that require only a simple select by primary key to load. It could also be easily extended to limit memory usage (rudimentarily) by limiting the number of entries in the cache. Whether it is worthwhile in a particular application would depend on several factors (memory availability, size of elements being cached, locality of reference, expiration time limit, others?).
I agree that (at least with MySQL as the DB, accessed through Unix sockets) it would only be beneficial to use Cache::MemoryCache or *::FileCache to cache more complex queries or data that require a significant amount of perl execution time to construct. (Example: complex joins, selects that return many rows which must be iterated over to retrieve the data, or data structures that are built by combining the results of several queries). Another possible use is in a multi-server environment, where caching lets you transfer part of the work load from an overloaded database server to an less overloaded application server even without a single process performance gain.
Any ideas why there is so little performance difference between Cache::FileCache and Cache::MemoryCache in this benchmark? Is that realistic?