Alexander Schreiber <a…@usenet.thangorodrim.de> wrote:
> Yeah, it has to read an entire block from storage (512/4096 bytes depending > on details). All because the inode on ext4 by default is an absolutely massive > 256 bytes. And that assumes fully cold caches.
Right. And *you're about to read the inode anyway* since you're about to read the file. So the marginal cost of stat() is utterly negligible. Oh, and by the way, to get to the point where you can call lseek() *you've also read the inode*!
-- tfeb.org/computer/