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

Re: [PATCH 4/5] repack-promisor: extract function to remove redundant packs

From
Taylor Blau <me@ttaylorr.com>
Date
Jan 9, 2026, 23:40 UTC
Message-ID
<aWGR1r5PlLL3rWWd@nand.local>
In-Reply-To
<20260105-pks-geometric-repack-with-promisors-v1-4-c4660573437e@pks.im>
On Mon, Jan 05, 2026 at 02:16:44PM +0100, Patrick Steinhardt wrote:
Show 13 quoted lines
> @@ -226,6 +227,15 @@ void pack_geometry_remove_redundant(struct pack_geometry *geometry,
>  	strbuf_release(&buf);
>  }
>
> +void pack_geometry_remove_redundant(struct pack_geometry *geometry,
> +				    struct string_list *names,
> +				    struct existing_packs *existing,
> +				    const char *packdir)
> +{
> +	remove_redundant_packs(geometry->pack, geometry->split,
> +			       names, existing, packdir);
> +}
> +
The refactoring up to this point looks all good to me.

As a side-note, I would love to get rid of the pack_geometry_remove_redundant() function altogether. It is kind of a hack that we handle determining which packs are made redundant by a repacking operation in two different ways depending on whether or not we are doing a geometric repack.

I have some patches to do this in a series that implements the "reachability-guided" geometric repacking technique that I have talked above[^1] previously. I think (having skimmed the next patch but not yet fully reviewed it) that this should still all be doable with your patches. We just have to take two passes (once through the existing non-promisor packs and then another pass through the promisor ones).

So I think that this all looks good to me and shouldn't interfere with that effort, though I'll make a note to rebase those patches on top of these to make it easier for the maintainer to queue both of them.

Thanks, Taylor

[^1]: Well, I was pretty sure that I had mentioned it on the list, but
  can't seem to find anything corresponding to it in my "sent" folder.
  In case I haven't talked above it before, the gist is a special mode
  of --stdin-packs that only packs objects from the included set of
  packs which are reachable. If repack generates a cruft pack after the
  fact, that allows us to "incrementally" build up the cruft pack over
  time.
Previous: Patrick SteinhardtNext: Patrick Steinhardt
Message 9 of 11 in “builtin/repack: make geometric repacking compatible with promisors”
  1. 0/5 builtin/repack: make geometric repacking compatible with promisorsPatrick Steinhardt, Jan 5, 2026
  2. 1/5 builtin/pack-objects: exclude promisor objects with "--stdin-packs"Patrick Steinhardt, Jan 5, 2026
  3. Taylor BlauJan 9, 2026
  4. Patrick SteinhardtJan 12, 2026
  5. 2/5 repack-geometry: extract function to compute repacking splitPatrick Steinhardt, Jan 5, 2026
  6. Toon ClaesJan 14, 2026
  7. 3/5 repack-promisor: extract function to finalize repackingPatrick Steinhardt, Jan 5, 2026
  8. 4/5 repack-promisor: extract function to remove redundant packsPatrick Steinhardt, Jan 5, 2026
  9. Taylor BlauJan 9, 2026
  10. 5/5 builtin/repack: handle promisor packs with geometric repackingPatrick Steinhardt, Jan 5, 2026
  11. Toon ClaesJan 14, 2026

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.