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

[PATCH 0/3] xdiff: speedup histogram diff

From
PGPhillip Wood via GitGitGadget <gitgitgadget@gmail.com>
Date
Nov 17, 2021, 11:20 UTC
Message-ID
<pull.1079.git.1637148025.gitgitgadget@gmail.com>

Histogram is the only diff algorithm not to call xdl_classify_record(). Calling xdl_classify_record() means that it is not necessary to use xdl_recmatch() when comparing lines, all that is necessary is to compare the hash values. This gives a 7% reduction in the runtime of "git log --patch" when using the histogram diff algorithm.

Phillip Wood (3):
  diff histogram: intern strings
  xdiff: avoid unnecessary memory allocations
  xdiff: simplify comparison
 xdiff/xdiffi.c     |  5 +----
 xdiff/xhistogram.c |  5 ++---
 xdiff/xprepare.c   | 35 +++++++++++++++--------------------
 3 files changed, 18 insertions(+), 27 deletions(-)
base-commit: cd3e606211bb1cf8bc57f7d76bab98cc17a150bc
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1079%2Fphillipwood%2Fwip%2Fhistogram-speedup-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1079/phillipwood/wip/histogram-speedup-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/1079
-- 
gitgitgadget
Next: Phillip Wood via GitGitGadget
Message 1 of 15 in “xdiff: speedup histogram diff”
  1. 0/3 xdiff: speedup histogram diffPhillip Wood via GitGitGadget, Nov 17, 2021
  2. 1/3 diff histogram: intern stringsPhillip Wood via GitGitGadget, Nov 17, 2021
  3. Derrick StoleeNov 17, 2021
  4. Jeff KingNov 17, 2021
  5. Phillip WoodNov 17, 2021
  6. Johannes SchindelinNov 18, 2021
  7. Jeff KingNov 18, 2021
  8. Phillip WoodNov 19, 2021
  9. Jeff KingNov 19, 2021
  10. Ævar Arnfjörð BjarmasonNov 19, 2021
  11. Jeff KingNov 19, 2021
  12. Johannes SchindelinNov 19, 2021
  13. 2/3 xdiff: avoid unnecessary memory allocationsPhillip Wood via GitGitGadget, Nov 17, 2021
  14. 3/3 xdiff: simplify comparisonPhillip Wood via GitGitGadget, Nov 17, 2021
  15. Johannes SchindelinNov 18, 2021

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.