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

utils/map: preallocate memory #729

Merged
merged 1 commit into from
Oct 9, 2023
Merged

utils/map: preallocate memory #729

merged 1 commit into from
Oct 9, 2023

Conversation

florianl
Copy link
Member

@florianl florianl commented Oct 9, 2023

Preallocate memory for result of MapKeys and MapValues to avoid expensive reallocations and further GC actions.

Preallocate memory for result of MapKeys and MapValues to avoid expensive reallocations and further GC actions.

Signed-off-by: Florian Lehner <florian.lehner@elastic.co>
@florianl florianl requested a review from Anaethelion October 9, 2023 08:24
Copy link
Contributor

@Anaethelion Anaethelion left a comment

Choose a reason for hiding this comment

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

LGTM!

@Anaethelion Anaethelion merged commit 0d88838 into main Oct 9, 2023
8 checks passed
@Anaethelion Anaethelion deleted the flo-allocations branch October 9, 2023 09:49
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