More improvements to the cache system