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

Re: [RFC PATCH 0/6] Hash Abstraction

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 21, 2017, 00:18 UTC
Message-ID
<xmqqefs57ozd.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<20170821000022.26729-1-sandals@crustytoothpaste.net>
"brian m. carlson" <sandals@crustytoothpaste.net> writes:
Show 7 quoted lines
> brian m. carlson (6):
>   vcs-svn: remove unused prototypes
>   vcs-svn: rename repo functions to "svn_repo"
>   setup: expose enumerated repo info
>   Add structure representing hash algorithm
>   Integrate hash algorithm support with repo setup
>   Switch empty tree and blob lookups to use hash abstraction

The first two are about very quiescent code that can go in and sail thru 'next' very quickly without problems, I would think.

After the third one alone, the discovered format information may not be fully plumbed through (i.e. after setup finishes there is no way for outside callers to peek at the repo_fmt instance that was on stack), but it seems that this is sufficient for the purpose of this step and it looks a very sensible first step.,

As to patch 4, I tend to agree with the analysis you had in this cover letter--it did make me wonder if we want to have union of hash contenxt structures, for example. But the enumeration of virtual functions looks about right.

I wondered if we wanted "binery size" and "hex size" separately, because the latter will always be twice as big as the former as long as the latter's definition is "hex", but that is a minor point.

Thanks for starting this.
Show 18 quoted lines
>  builtin/am.c        |  2 +-
>  builtin/checkout.c  |  2 +-
>  builtin/diff.c      |  2 +-
>  builtin/pull.c      |  2 +-
>  cache.h             | 48 ++++++++++++++++++++++++++++++++++++++++++++----
>  diff-lib.c          |  2 +-
>  merge-recursive.c   |  2 +-
>  notes-merge.c       |  2 +-
>  repository.c        |  7 +++++++
>  repository.h        |  5 +++++
>  sequencer.c         |  6 +++---
>  setup.c             | 48 +++++++++++++++++++++++++++---------------------
>  sha1_file.c         | 29 +++++++++++++++++++++++++++++
>  submodule.c         |  2 +-
>  vcs-svn/repo_tree.c |  6 +++---
>  vcs-svn/repo_tree.h | 13 +++----------
>  vcs-svn/svndump.c   |  8 ++++----
>  17 files changed, 133 insertions(+), 53 deletions(-)
Previous: brian m. carlsonNext: Stefan Beller
Message 10 of 11 in “Hash Abstraction”
  1. 0/6 Hash Abstractionbrian m. carlson, Aug 21, 2017
  2. 1/6 vcs-svn: remove unused prototypesbrian m. carlson, Aug 21, 2017
  3. 6/6 Switch empty tree and blob lookups to use hash abstractionbrian m. carlson, Aug 21, 2017
  4. 5/6 Integrate hash algorithm support with repo setupbrian m. carlson, Aug 21, 2017
  5. Stefan BellerAug 21, 2017
  6. 4/6 Add structure representing hash algorithmbrian m. carlson, Aug 21, 2017
  7. Stefan BellerAug 21, 2017
  8. 3/6 setup: expose enumerated repo infobrian m. carlson, Aug 21, 2017
  9. 2/6 vcs-svn: rename repo functions to "svn_repo"brian m. carlson, Aug 21, 2017
  10. Junio C HamanoAug 21, 2017
  11. Stefan BellerAug 21, 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.