add compressed reading and writing of cache entries