Skip to content

UPSTREAM PR #2409: [WIP] Add functionality to execute Rust closures on directories#17

Open
loci-dev wants to merge 1 commit intomainfrom
loci/pr-2409-copilot-add-execute-rust-closures
Open

UPSTREAM PR #2409: [WIP] Add functionality to execute Rust closures on directories#17
loci-dev wants to merge 1 commit intomainfrom
loci/pr-2409-copilot-add-execute-rust-closures

Conversation

@loci-dev
Copy link
Copy Markdown

@loci-dev loci-dev commented Feb 3, 2026

Note

Source pull request: GitoxideLabs/gitoxide#2409

Thanks for asking me to work on this. I will get started on it and keep this PR's description up to date as I form a plan and make progress.

Original prompt

Add a way to execute Rust closures on a given directory, fully integrated into the existing ways of creating fixtures with scripts. The key here is to let the caller provide a version number (simple integer), that needs to be incremented manually to allow caching.
With it, it should be possible to make a fixture something like this:

let dir = gix_testtools::rust_fixture_read_only(1, |dir| { …create the fixture in Rust here })?;

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@loci-dev loci-dev force-pushed the main branch 3 times, most recently from 4168df6 to ead683a Compare February 3, 2026 13:24
@loci-review
Copy link
Copy Markdown

loci-review bot commented Feb 3, 2026

Overview

Analysis of 26,353 functions across two Gitoxide binaries reveals stable performance between versions. 53 functions modified, 152 added, 152 removed, and 25,996 unchanged. Power consumption shows marginal improvements: target.aarch64-unknown-linux-gnu.release.gix decreased 0.011% (790,293 → 790,203 nanojoules), and target.aarch64-unknown-linux-gnu.release.ein decreased 0.005% (294,086 → 294,072 nanojoules).

Function Analysis

Only one function met the analysis threshold: parse_from (clap_builder CLI parser) in the ein binary. Response time improved from 65,069,468ns to 65,060,176ns (-9,292ns, -0.014%), and throughput time improved from 148.76ns to 145.77ns (-2.99ns, -2.01%). This one-time initialization function is non-critical, called once per program invocation. No source code changes were detected in the repository; improvements are attributed to compiler optimization variations. Performance-critical areas identified in project insights—object database operations, pack file handling, parallel processing, and diffing algorithms—show no significant changes, maintaining stable performance for core Git operations.

🔎 Full breakdown: Loci Inspector.
💬 Questions? Tag @loci-dev.

@loci-dev loci-dev force-pushed the main branch 7 times, most recently from 002971b to a4396e6 Compare February 10, 2026 07:22
@loci-dev loci-dev force-pushed the main branch 5 times, most recently from 9af85dc to 8124417 Compare February 16, 2026 07:50
@loci-dev loci-dev force-pushed the main branch 5 times, most recently from 1a1cf0a to f045646 Compare February 25, 2026 07:50
@loci-dev loci-dev force-pushed the main branch 2 times, most recently from e746ced to fe5de3e Compare March 4, 2026 07:46
@loci-dev loci-dev force-pushed the main branch 4 times, most recently from 2c4a72b to 167bdd1 Compare March 13, 2026 07:48
@loci-dev loci-dev force-pushed the main branch 5 times, most recently from 0223bcb to bfaee00 Compare March 24, 2026 07:50
@loci-dev loci-dev force-pushed the main branch 3 times, most recently from a9e7940 to d9d8ccd Compare March 28, 2026 07:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants