public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] git-receive-pack(1): optimize `assign_shallow_commits_to_refs()`
@ 2026-02-16 15:38 Patrick Steinhardt
  2026-02-16 15:38 ` [PATCH 1/3] commit: avoid parsing non-commits in `lookup_commit_reference_gently()` Patrick Steinhardt
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Patrick Steinhardt @ 2026-02-16 15:38 UTC (permalink / raw)
  To: git; +Cc: Matt Smiley

Hi,

this patch series optimizes how git-receive-pack(1) handles shallow
pushes in `assign_shallow_commits_to_refs()`. This covers some edge
cases that we have hit in a production repository, where shallow pushes
could take many minutes and allocate a ton of memory.

Thanks!

Patrick

---
Patrick Steinhardt (3):
      commit: avoid parsing non-commits in `lookup_commit_reference_gently()`
      commit: make `repo_parse_commit_no_graph()` more robust
      commit: use commit graph in `lookup_commit_reference_gently()`

 commit.c                        | 32 +++++++++++++++++++++++++++-----
 commit.h                        | 14 ++++++++++++--
 contrib/coccinelle/commit.cocci |  2 +-
 object.c                        | 23 ++++++++++++++++++-----
 object.h                        |  5 +++++
 5 files changed, 63 insertions(+), 13 deletions(-)


---
base-commit: 852829b3dd2fe4e7c7fc4d8badde644cf1b66c74
change-id: 20260216-b4-pks-receive-pack-optimize-shallow-0a6cc508549d


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2026-02-19 17:35 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-16 15:38 [PATCH 0/3] git-receive-pack(1): optimize `assign_shallow_commits_to_refs()` Patrick Steinhardt
2026-02-16 15:38 ` [PATCH 1/3] commit: avoid parsing non-commits in `lookup_commit_reference_gently()` Patrick Steinhardt
2026-02-18 18:26   ` Justin Tobler
2026-02-19 17:35     ` Junio C Hamano
2026-02-16 15:38 ` [PATCH 2/3] commit: make `repo_parse_commit_no_graph()` more robust Patrick Steinhardt
2026-02-18 19:23   ` Justin Tobler
2026-02-19  7:18     ` Patrick Steinhardt
2026-02-16 15:38 ` [PATCH 3/3] commit: use commit graph in `lookup_commit_reference_gently()` Patrick Steinhardt
2026-02-18 19:34   ` Justin Tobler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox