public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
* Perf bug: rev-list w/ 2+ paths relatively slow with commit-graph
@ 2025-06-23 17:58 Kai Koponen
  2025-06-23 18:04 ` Kai Koponen
  2025-06-23 19:36 ` Junio C Hamano
  0 siblings, 2 replies; 7+ messages in thread
From: Kai Koponen @ 2025-06-23 17:58 UTC (permalink / raw)
  To: git, Kai Koponen

Reproduce steps:
```
git clone https://github.com/golang/go.git
cd go
git config core.commitGraph true
git commit-graph write --split --reachable --changed-paths  # Without
this, all calls equally slow (~1s)
time git rev-list -10 3730814f2f2bf24550920c39a16841583de2dac1 --
src/clean.bash > /dev/null  # ~90ms
time git rev-list -10 3730814f2f2bf24550920c39a16841583de2dac1 --
src/Make.dist > /dev/null  # ~100ms
time git rev-list -10 3730814f2f2bf24550920c39a16841583de2dac1 --
src/clean.bash src/Make.dist > /dev/null  # ~650ms
```

The rev-list call with multiple paths takes over 3x longer than the
sum of individual calls to it for the same files.

Expectation: rev-list with multiple paths should take <= the sum of
the time it takes to call it with each path individually (ideally <,
since with the count limit it should be able to early-exit and search
less commits for either path).

Also reproduces without the -10 arg, or with a lower count (double
instead of triple w/ -1), but these results are perhaps most
surprising with a count present.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2025-06-24 13:32 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-23 17:58 Perf bug: rev-list w/ 2+ paths relatively slow with commit-graph Kai Koponen
2025-06-23 18:04 ` Kai Koponen
2025-06-23 19:36 ` Junio C Hamano
2025-06-23 20:19   ` Kai Koponen
2025-06-23 21:00     ` Junio C Hamano
2025-06-24  3:16       ` Lidong Yan
2025-06-24 13:32         ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox