8000 Add benchmarks for blame by ethomson · Pull Request #6920 · libgit2/libgit2 · GitHub
[go: up one dir, main page]

Skip to content

Add benchmarks for blame #6920

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 14 commits into from
Oct 21, 2024
Merged

Add benchmarks for blame #6920

merged 14 commits into from
Oct 21, 2024

Conversation

ethomson
Copy link
Member

You can't improve what you can't measure; our blame implementation has historically been a poor performer. Add a benchmark suite so that we can start to track improvements.

Callers may wish to show all the options, even hidden ones, when showing
usage. In particular, showing generic help for the CLI should show
global options (those that are generally "hidden"). But showing help for
a particular command should keep them hidden. Instrument a mechanism to
deal with this.
When the `help` command is invoked (because no command was specifi
8000
ed) we
may need to clean up the arguments, in particular, to avoid passing
`--help` (so that the help command isn't confused, and assumes that it's
being invoked as `help --help`).
Move the common option information to a global place, and reuse them.
Common options will be global variables.

Specify them as _hidden_ for all commands (the main command will pass
the SHOW_HIDDEN flag to the usage printer, so that they're visible).
Add a `--no-pager` option for git compatibility.
Teach the benchmark script how to clone the git or kernel repositories,
which is useful to have a larger corpus of test data. If a benchmark
script wants to `clone git` or `clone linux`, then this will be done.
Callers probably want to specify `BENCHMARK_GIT_REPOSITORY` to a
previously cloned local repository so that the script does not download
the repository repeatedly.
It will never be a good user experience to clone the git or kernel repos
from a remote; don't even have a default.
When running without a local test repository, show a helpful error
message.
Allow for workflow_dispatch jobs to run, but don't publish their test
results; this is useful for testing workflows themselves.
blame on torvalds/linux is too punishing for our current implementation;
don't run it (yet).
If a test needs a repo that isn't provide it, mark it as skipped and
avoid failing the execution.
@ethomson ethomson merged commit 533ec83 into main Oct 21, 2024
23 checks passed
@ethomson ethomson deleted the ethomson/blame_benchmarks branch October 21, 2024 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0