Re: [PATCH v1 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-05 Thread Jonathan Nieder
Hi, g...@jeffhostetler.com wrote: > During status on a very large repo and there are many changes, > a significant percentage of the total run time was spent > reallocing the wt_status.changes array. Nit: commit messages tend to use the present tense instead of the past when describing Git's cur

Re: [PATCH v1 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-05 Thread Jeff Hostetler
On 4/5/2017 4:09 PM, Jeff King wrote: On Wed, Apr 05, 2017 at 07:55:59PM +, g...@jeffhostetler.com wrote: From: Jeff Hostetler Use ALLOC_GROW() macro when reallocing a string_list array rather than simply increasing it by 32. This is a performance optimization. During status on a very

Re: [PATCH v1 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-05 Thread Jeff King
On Wed, Apr 05, 2017 at 07:55:59PM +, g...@jeffhostetler.com wrote: > From: Jeff Hostetler > > Use ALLOC_GROW() macro when reallocing a string_list array > rather than simply increasing it by 32. This is a performance > optimization. > > During status on a very large repo and there are man

Re: [PATCH v1 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-05 Thread Stefan Beller
On Wed, Apr 5, 2017 at 12:55 PM, wrote: > + if (list->nr + 1 >= list->alloc) > + ALLOC_GROW(list->items, list->nr+1, list->alloc); No need for the condition here as it is part of the macro as well. Thanks for spotting this fix! Stefan

[PATCH v1 1/2] string-list: use ALLOC_GROW macro when reallocing string_list

2017-04-05 Thread git
From: Jeff Hostetler Use ALLOC_GROW() macro when reallocing a string_list array rather than simply increasing it by 32. This is a performance optimization. During status on a very large repo and there are many changes, a significant percentage of the total run time was spent reallocing the wt_s