Skip to content
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

[wip] trying to implement (b *BtIndex) keyCmp with MatchCmp #11377

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

JkLondon
Copy link
Member

closes #11376

@JkLondon JkLondon self-assigned this Jul 28, 2024
Copy link
Collaborator

@AskAlexSharov AskAlexSharov left a comment

Choose a reason for hiding this comment

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

i think - it doesn't make sense to merge this PR without #11378 - because it will make perf worse.

//TODO: use `b.getter.Match` after https://github.com/erigontech/erigon/issues/7855
return bytes.Compare(res, k), res, nil
//return b.getter.Match(k), result, nil
return -1 * cmp, res, nil
Copy link
Member

Choose a reason for hiding this comment

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

why need to invert comparison with *-1?

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.

Use MatchCmp in btree_index.go
3 participants