Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Added mem-dbg as optional feature #19

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

Open
LucaCappelletti94 wants to merge 7 commits into alecmocatta:master
base: master
Choose a base branch
Loading
from LucaCappelletti94:mem_dbg

Conversation

@LucaCappelletti94
Copy link

@LucaCappelletti94 LucaCappelletti94 commented Aug 8, 2024

Mem-dbg is a crate that allows to compute the size of a struct. I have added the derives through the crate as an optional feature, so as to use it to compare this implementation with others easily.

Cheers!

alecmocatta reacted with heart emoji
Copy link
Author

FYI, the errors are caused by the CI configuration being old. Consider updating it.

alecmocatta reacted with thumbs up emoji

Copy link
Owner

Thanks for this! Let me know when done and will merge despite the outdated CI.

Copy link
Author

Hi @alecmocatta, sure - I am running some benchmarks so I may add some other small edits.

Copy link
Author

Why are you checking whether the estimates are three-sorted? I see that you run a binary search but that requires the estimates to be completely sorted, and I recently discovered that the estimates provided from the HLL++ paper are not sorted (they nearly are). I will be providing a fix for that shortly.

fn is_three_sorted<T>(data: &[T]) -> bool
where
T: PartialOrd + Debug,
{
data.windows(3).all(|w| {
let ret = w[0].partial_cmp(&w[2]).unwrap() != Ordering::Greater;
if !ret {
println!("{:?}", w);
}
ret
})
}
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /