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

[PATCH 0/3] index-pack threading defaults

From
Jeff King <peff@peff.net>
Date
Aug 21, 2020, 17:51 UTC
Message-ID
<20200821175153.GA3263018@coredump.intra.peff.net>

I decided to revisit index-pack's hard-coded default of 3 threads. And it turns out that higher numbers perform much better. :)

That value was determined experimentally in 2012. I'm not sure of the exact reason it's different now (modern processors are better at parallelism, or modern git is better at parallelism, or the original experiment was just a fluke). But regardless, I can get on the order of a two-to-one speedup by bumping the thread count. See the final patch for timings and more specific discussion.

The first two patches are just perf-test improvements (actually, the slowness to value ratio of p5302 from the first patch is why I was looking at this at all).

  [1/3]: p5302: disable thread-count parameter tests by default
  [2/3]: p5302: count up to online-cpus for thread tests
  [3/3]: index-pack: adjust default threading cap
 builtin/index-pack.c       | 19 ++++++++++++---
 t/perf/README              |  9 ++++++++
 t/perf/p5302-pack-index.sh | 47 +++++++++++++++++++-------------------
 t/perf/perf-lib.sh         |  2 ++
 4 files changed, 51 insertions(+), 26 deletions(-)
-Peff
Next: Jeff King
Message 1 of 13 in “index-pack threading defaults”
  1. 0/3 index-pack threading defaultsJeff King, Aug 21, 2020
  2. 1/3 p5302: disable thread-count parameter tests by defaultJeff King, Aug 21, 2020
  3. 2/3 p5302: count up to online-cpus for thread testsJeff King, Aug 21, 2020
  4. Jeff KingAug 21, 2020
  5. 3/3 index-pack: adjust default threading capJeff King, Aug 21, 2020
  6. Eric SunshineAug 21, 2020
  7. Jeff KingAug 21, 2020
  8. brian m. carlsonAug 22, 2020
  9. Jeff KingAug 24, 2020
  10. Eric SunshineAug 24, 2020
  11. Jeff KingAug 21, 2020
  12. Junio C HamanoAug 21, 2020
  13. Jeff KingAug 21, 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.