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

[PATCH 0/5] refs: designated init & missing debug in ps/fetch-mirror-optim

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Mar 17, 2022, 17:27 UTC
Message-ID
<cover-0.5-00000000000-20220317T171618Z-avarab@gmail.com>

When I recently submitted a topic[1] to convert various things to designated initializers Junio (presumably) ejected the refs changes due to conflicts with ps/fetch-mirror-optim. The rest of the series was down already in 20d34c07ea4 (Merge branch 'ab/c99-designated-initializers', 2022-03-06)

Now that that series has landed 1-3/5 are those previous patches re-submitted (with a minor change for the new "read_symbolic_ref").

The 4/5 is then a deletion of packed-backend.c stub functions that I think are not worth carrying anymore, and which has the fringe benefit of squashing a noisy warning under SunCC.

5/5 is then a minor fix-up for ps/fetch-mirror-optim: It didn't define a debug wrapper for refs_read_symbolic_ref(). Now that we do we don't need an implementation that'll ever fall back on refs_read_raw_ref(). It's now a stand-alone API function without a fallback (which in effect it was before, sans debug backend).

Aside: It seems that the GIT_TRACE_REFS facility has been broken since
it was added, i.e. running the test site with e.g.:
    GIT_TRACE_REFS=/tmp/log.txt make test

Will fail, and not due to a test being confused about the logs. I think something in how the iterators are wrapped is confusing it, but that's a long-standing issue in any case...

1. https://lore.kernel.org/git/cover-00.12-00000000000-20220224T092805Z-avarab@gmail.com
Ævar Arnfjörð Bjarmason (5):
  refs: use designated initializers for "struct ref_storage_be"
  refs: use designated initializers for "struct ref_iterator_vtable"
  misc *.c: use designated initializers for struct assignments
  packed-backend: remove stub BUG(...) functions
  refs debug: add a wrapper for "read_symbolic_ref"
 attr.c                |   2 +-
 notes-merge.c         |   1 +
 object-file.c         |   9 +--
 refs.c                |  13 +----
 refs/debug.c          |  82 ++++++++++++++++++---------
 refs/files-backend.c  |  64 ++++++++++-----------
 refs/iterator.c       |  18 +++---
 refs/packed-backend.c | 128 ++++++++++--------------------------------
 refs/ref-cache.c      |   6 +-
 9 files changed, 135 insertions(+), 188 deletions(-)
-- 
2.35.1.1384.g7d2906948a1
Next: Ævar Arnfjörð Bjarmason
Message 1 of 11 in “refs: designated init & missing debug in ps/fetch-mirror-optim”
  1. 0/5 refs: designated init & missing debug in ps/fetch-mirror-optimÆvar Arnfjörð Bjarmason, Mar 17, 2022
  2. 1/5 refs: use designated initializers for "struct ref_storage_be"Ævar Arnfjörð Bjarmason, Mar 17, 2022
  3. 2/5 refs: use designated initializers for "struct ref_iterator_vtable"Ævar Arnfjörð Bjarmason, Mar 17, 2022
  4. 3/5 misc *.c: use designated initializers for struct assignmentsÆvar Arnfjörð Bjarmason, Mar 17, 2022
  5. 4/5 packed-backend: remove stub BUG(...) functionsÆvar Arnfjörð Bjarmason, Mar 17, 2022
  6. Junio C HamanoMar 17, 2022
  7. 5/5 refs debug: add a wrapper for "read_symbolic_ref"Ævar Arnfjörð Bjarmason, Mar 17, 2022
  8. Han-Wen NienhuysMar 17, 2022
  9. Ævar Arnfjörð BjarmasonMar 18, 2022
  10. Patrick SteinhardtMar 21, 2022
  11. Junio C HamanoMar 21, 2022

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.