Repository navigation
log: Reuse loaded branch state in listings - #1490
Merged
Merged
Conversation
Branch graph construction loads tracked state, but restack checks then look up each branch again. Pass the graph's existing branch records to `CheckLoadedBranchRestacked` so listings avoid those repeated reads. Keep graph loading behind `Service.BranchGraph` and share restack reconciliation with `CheckRestacked`, including the recovered base hash used to render a healed boundary. On the macOS arm64 demo repository with 103 local branches, hyperfine uses 3 warmups and 15 runs of `log short` and `log long`, each with `--all --json`. Compared with the parent branch-batching commit: | Listing | Parent mean +/- SD (s) | New mean +/- SD (s) | | --- | ---: | ---: | | Short | 1.043 +/- 0.127 | 0.590 +/- 0.157 | | Long | 1.178 +/- 0.096 | 0.684 +/- 0.030 |
Owner
Author
|
This change is part of the following stack: Change managed by git-spice. |
This was referenced Oct 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Branch graph construction loads tracked state, but restack checks then
look up each branch again.
Pass the graph's existing branch records to
CheckLoadedBranchRestackedso listings avoid those repeated reads.Keep graph loading behind
Service.BranchGraphand share restackreconciliation with
CheckRestacked, including the recovered base hashused to render a healed boundary.
On the macOS arm64 demo repository with 103 local branches, hyperfine
uses 3 warmups and 15 runs of
log shortandlog long, each with--all --json.Compared with the parent branch-batching commit:
The collective effect of this stack is: