git/list[1] front-page[2] threads[3] people[4] search[5] about
 

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

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Apr 11, 2017, 21:29 UTC
Message-ID
<20170411212955.GP8741@aiede.mtv.corp.google.com>
In-Reply-To
<20170411200802.31638-2-git@jeffhostetler.com>
git@jeffhostetler.com wrote:
Show 18 quoted lines
> During status on a very large repo and there are many changes,
> a significant percentage of the total run time is spent
> reallocing the wt_status.changes array.
>
> This change decreases the time in wt_status_collect_changes_worktree()
> from 125 seconds to 45 seconds on my very large repository.
>
> This produced a modest gain on my 1M file artificial repo, but
> broke even on linux.git.
>
> Test                                            HEAD^^            HEAD
> ---------------------------------------------------------------------------------------
> 0005.2: read-tree status br_ballast (1000001)   8.29(5.62+2.62)   8.22(5.57+2.63) -0.8%
>
> Signed-off-by: Jeff Hostetler <jeffhost@microsoft.com>
> ---
>  string-list.c | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)

Nice. After rebasing (or just squashing together) with the p0005 patch as peff suggested,

Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Previous: git@jeffhostetler.comNext: Jeff King
Message 5 of 6 in “string-list: use ALLOC_GROW macro when reallocing”
  1. 0/2 string-list: use ALLOC_GROW macro when reallocinggit@jeffhostetler.com, Apr 11, 2017
  2. 2/2 p0005-status: time status on very large repogit@jeffhostetler.com, Apr 11, 2017
  3. Jonathan NiederApr 11, 2017
  4. 1/2 string-list: use ALLOC_GROW macro when reallocing string_listgit@jeffhostetler.com, Apr 11, 2017
  5. Jonathan NiederApr 11, 2017
  6. Jeff KingApr 11, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.