Skip to content

Speedup#23

Merged
kit-ty-kate merged 4 commits intohannesm:mainfrom
kit-ty-kate:speedup
Apr 23, 2025
Merged

Speedup#23
kit-ty-kate merged 4 commits intohannesm:mainfrom
kit-ty-kate:speedup

Conversation

@kit-ty-kate
Copy link
Copy Markdown
Collaborator

@kit-ty-kate kit-ty-kate commented Apr 19, 2025

This unlocks parsing large diff files. I'll add tests on Monday.

The first commit alone allows opam update of opam-repository at 2025-01-before-archiving-phase1 to master to be made in < 7s (including just 0.1s of Patch.parse), compared to +infinity (several hours) before.

@kit-ty-kate kit-ty-kate marked this pull request as ready for review April 22, 2025 00:46
@kit-ty-kate
Copy link
Copy Markdown
Collaborator Author

@hannesm what do you think about adding such large files to the repository? They add 40MB to the project uncompressed (3.4MB compressed using gzip). Alternatively we could have another repository to store these kind of test files.

@hannesm
Copy link
Copy Markdown
Owner

hannesm commented Apr 22, 2025

it would be great to have this huge thing external.. maybe a separate git repo, or a download url that is fetched unless it is present during the testrun (if that's possible with dune rules and the opam sandbox) -- could be an extra-files in the opam file (though that won't work for local development)..

@kit-ty-kate
Copy link
Copy Markdown
Collaborator Author

Done. I've created a new repository at https://codeberg.org/kit-ty-kate/ocaml-patch-tests, linked it using git submodules and the tests now explicitly skip these if the files are missing or if the platform doesn't support the large strings necessary to load them (e.g. 32bit platforms)

@hannesm
Copy link
Copy Markdown
Owner

hannesm commented Apr 23, 2025

this looks good, thanks. would you mind to document in README what to do for development in terms of git submodule? and does CI test the big file test?

@kit-ty-kate
Copy link
Copy Markdown
Collaborator Author

and does CI test the big file test?

yes, ocaml-ci fetches every submodules

@kit-ty-kate
Copy link
Copy Markdown
Collaborator Author

kit-ty-kate commented Apr 23, 2025

would you mind to document in README what to do for development in terms of git submodule?

done

kit-ty-kate and others added 4 commits April 23, 2025 14:37
Here the diff is between 2025-01-before-archiving-phase1 and 999bff3ed88d26f76ff7eaddbfa7af49ed4737dc from opam-repository
@kit-ty-kate kit-ty-kate merged commit 1d86823 into hannesm:main Apr 23, 2025
1 check passed
@kit-ty-kate kit-ty-kate deleted the speedup branch April 23, 2025 14:07
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