Re: [PATCH 2/5] hashmap: allow memihash computation to be continued

2017-02-20 Thread Junio C Hamano
Johannes Schindelin writes: >> If an extra call level really matters, its "inline" equivalent in >> the header would probably be good. > > Well, the hashing is supposed to be as fast as possible, so I would like > to avoid that extra call level. However, the end result is not so pretty > because

Re: [PATCH 2/5] hashmap: allow memihash computation to be continued

2017-02-20 Thread Johannes Schindelin
Hi Junio, On Fri, 17 Feb 2017, Junio C Hamano wrote: > Johannes Schindelin writes: > > > diff --git a/hashmap.c b/hashmap.c > > index b10b642229c..061b7d61da6 100644 > > --- a/hashmap.c > > +++ b/hashmap.c > > @@ -50,6 +50,20 @@ unsigned int memihash(const void *buf, size_t len) > > return

Re: [PATCH 2/5] hashmap: allow memihash computation to be continued

2017-02-17 Thread Junio C Hamano
Johannes Schindelin writes: > diff --git a/hashmap.c b/hashmap.c > index b10b642229c..061b7d61da6 100644 > --- a/hashmap.c > +++ b/hashmap.c > @@ -50,6 +50,20 @@ unsigned int memihash(const void *buf, size_t len) > return hash; > } > > +/* Incoporate another chunk of data into a memihash

[PATCH 2/5] hashmap: allow memihash computation to be continued

2017-02-14 Thread Johannes Schindelin
From: Jeff Hostetler There are times when we compute the hash on a full path and then the hash on just the path to the parent directory. This can be expensive on large repositories. With the new memihash_continue() function, we can hash the parent directory first, and reuse that computed hash fo