Optimized file reading.