Optimizes cache handling.