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

Potential Perf Opportunity: Remove collect on BTreeMap #1443

Open
eriktaubeneck opened this issue Nov 18, 2024 · 0 comments
Open

Potential Perf Opportunity: Remove collect on BTreeMap #1443

eriktaubeneck opened this issue Nov 18, 2024 · 0 comments

Comments

@eriktaubeneck
Copy link
Member

eriktaubeneck commented Nov 18, 2024

I think this refactoring made it less efficient as you now need to collect the intermediates. I didn't think we need that, but you want to have a function, maybe you can make it borrowing from reports and producing an iterator, like this

fn group_report_pairs<'a, BK, V>(
    reports: &'a [PrfHybridReport<BK, V>],
) -> impl Iterator<Item = [AggregateableHybridReport<BK, V>; 2]>> + 'a

Originally posted by @akoshelev in #1434 (comment)

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

No branches or pull requests

1 participant