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

Re: [PATCH 1/3] csum-file: add hashwrite_be64()

From
Taylor Blau <me@ttaylorr.com>
Date
Nov 12, 2020, 14:47 UTC
Message-ID
<X61LEUBDyhnboZAv@nand.local>
In-Reply-To
<fcebe67f-f1d7-0069-01de-12844508cae1@gmail.com>
On Thu, Nov 12, 2020 at 08:52:24AM -0500, Derrick Stolee wrote:
Show 14 quoted lines
> On 11/12/2020 7:20 AM, René Scharfe wrote:
> > Add a helper function for hashing and writing 64-bit integers in network
> > byte order.  It returns the number of written bytes.  This simplifies
> > callers that keep track of the file offset, even though this number is a
> > constant.
> >
> > Suggested-by: Derrick Stolee <dstolee@microsoft.com>
> > Original-patch-by: Taylor Blau <me@ttaylorr.com>
>
> These patches are absolutely correct, and I'm glad to see them show up
> in a very clear presentation. I had to go look to see why these were
> not already present, with [1] being the last instance of these showing
> up on-list. They did not get into the new version after a significant
> refactor [2].

That's right. What happened was we stopped writing the uncompressed "has an unpresentable Bloom filter" bitmap between the two versions you're talking about. Since we wrote each word as a big-endian 8-byte unsigned value, introducing hashwrite_be64() was useful in the earlier version.

But in the rewritten version, there were no _new_ callers that would have wanted hashwrite_be64(), so I dropped those patches since the series was already large.

That all being said, these are definitely useful patches to have, so I'm glad to see them being dug back up. Thanks, René :-).

Show 5 quoted lines
> Thanks,
> -Stolee
>
> [1] https://lore.kernel.org/git/20200904202226.GA21837@nand.local/
> [2] https://lore.kernel.org/git/cover.1599664389.git.me@ttaylorr.com/

Thanks, Taylor

Previous: Derrick StoleeNext: Taylor Blau
Message 5 of 6 in “csum-file: add hashwrite_be64()”
  1. 1/3 csum-file: add hashwrite_be64()René Scharfe, Nov 12, 2020
  2. 2/3 midx: use hashwrite_be64()René Scharfe, Nov 12, 2020
  3. 3/3 pack-write: use hashwrite_be64()René Scharfe, Nov 12, 2020
  4. Derrick StoleeNov 12, 2020
  5. Taylor BlauNov 12, 2020
  6. Taylor BlauNov 12, 2020

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.