Re: [PATCH] remove over-eager caching in sha1_file_name
Jeff King <peff@peff.net> writes:
Show 8 quoted lines
> Actually, thinking on it more, micro-optimizing this is really
> pointless. I was thinking that it would get called a lot, so we need to
> care. But the next step is almost certainly to open, mmap, and zlib
> decompress the resulting object, which is way more expensive.
>
> So here it is with caching ripped out. More readable and more robust,
> and I'm sure we can afford an extra strlen() and memcpy() on each object
> lookup.