Skip to content

Conversation

pascalkuthe
Copy link
Owner

closes #32

Should slightly reduce number of iterations (one less search step which results in up to 2d search iterations) during diffing and therefore speedup the diff a bit. May change the results slightly in edgecase but overall the old results where still correct, this would only affect edgecases with multiple correct results, very unlikely to be noticeable in practice.

closes #32

should slightly reduce number of iterations during diffing and therefore
slightly speedup the diff. May change the results slightly in edgecase
(but overall the old results where still correct, this would only affect
edgecases with multiple correct results, very unlikely to be noticed
in practice)
Copy link
Collaborator

@Byron Byron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's great, thanks a lot!

I wonder what's preventing this PR from being merged? When it is, I think I'd backport it to an 0.1 maintenance branch for which ultimately a release would have to be created as well to keep supporting gitoxide.

Comment on lines +158 to +162
// if the check for is_odd incorrectly always true then we take a fastpath
// when we shouldn't which always leads to inifite iterations/recursion
// still we check the number of iterations here in case the search
// is buggy in more subtle ways
cov_mark::check_count!(SPLIT_SEARCH_ITER, 15);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am loving these tests! TIL cov_mark - very useful.

@pascalkuthe
Copy link
Owner Author

Nothing really just wanted you to be aware and CI to pass. I think backporting this should be easy as it's just a 1-line change (the myers diff is exactly the same as 0.1). The tests would need extra work but considering how small of a change this is it may not be necessary to backport those

@pascalkuthe pascalkuthe merged commit ed12517 into master Oct 5, 2025
5 checks passed
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.

myers.rs - is_odd is always false

2 participants