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

Re: [RFC PATCH 01/14] midx: use `string_list` for retained MIDX files

From
Taylor Blau <me@ttaylorr.com>
Date
Feb 27, 2026, 03:02 UTC
Message-ID
<aaEJVDoUyL/QbY9O@nand.local>
In-Reply-To
<xmqqldgf1c65.fsf@gitster.g>
On Thu, Feb 26, 2026 at 12:29:22PM -0800, Junio C Hamano wrote:
Show 7 quoted lines
> > Replace the bare array with a `string_list` which can be passed around
> > as a single parameter. Though it improves lookup performance, the
> > difference is likely immeasurable given how small the keep_hashes array
> > typically is.
>
> And if it the lookup performance turns out to be an issue, we can
> switch to strmap or something more appropriate.

True. In practice these should have at most tens of entries, so I suspect the string_list will be completely fine.

If we are cleaning up so many stale MIDX files that we need a more efficient data structure just to keep track of those files, we likely have far greater problems to worry about ;-).

Thanks, Taylor

Previous: Junio C HamanoNext: Taylor Blau
Message 6 of 21 in “repack: incremental MIDX/bitmap-based repacking”
  1. 00/14 repack: incremental MIDX/bitmap-based repackingTaylor Blau, Feb 25, 2026
  2. 06/14 repack: track the ODB source via existing_packsTaylor Blau, Feb 25, 2026
  3. Taylor BlauFeb 25, 2026
  4. 01/14 midx: use `string_list` for retained MIDX filesTaylor Blau, Feb 25, 2026
  5. Junio C HamanoFeb 26, 2026
  6. Taylor BlauFeb 27, 2026
  7. 02/14 strvec: introduce `strvec_init_alloc()`Taylor Blau, Feb 25, 2026
  8. Junio C HamanoFeb 26, 2026
  9. Junio C HamanoFeb 26, 2026
  10. Taylor BlauFeb 27, 2026
  11. 03/14 midx: use `strvec` for `keep_hashes`Taylor Blau, Feb 25, 2026
  12. 04/14 midx: introduce `--checksum-only` for incremental MIDX writesTaylor Blau, Feb 25, 2026
  13. 05/14 midx: support custom `--base` for incremental MIDX writesTaylor Blau, Feb 25, 2026
  14. 07/14 midx: expose `midx_layer_contains_pack()`Taylor Blau, Feb 25, 2026
  15. 08/14 repack-midx: factor out `repack_prepare_midx_command()`Taylor Blau, Feb 25, 2026
  16. 09/14 repack-midx: extract `repack_fill_midx_stdin_packs()`Taylor Blau, Feb 25, 2026
  17. 10/14 repack-geometry: prepare for incremental MIDX repackingTaylor Blau, Feb 25, 2026
  18. 11/14 builtin/repack.c: convert `--write-midx` to an `OPT_CALLBACK`Taylor Blau, Feb 25, 2026
  19. 12/14 repack: implement incremental MIDX repackingTaylor Blau, Feb 25, 2026
  20. 13/14 repack: introduce `--write-midx=incremental`Taylor Blau, Feb 25, 2026
  21. 14/14 repack: allow `--write-midx=incremental` without `--geometric`Taylor Blau, Feb 25, 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.