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

Make frequently allocated string a constant #1275

Merged
merged 4 commits into from
Dec 7, 2020

Conversation

callumj
Copy link
Contributor

@callumj callumj commented Dec 5, 2020

This string appears to be allocated a lot but can be moved to a constant. This only improves memory for versions below Ruby 2.3 because I belive Ruby has optimizations going forward that allow it to re-use these immutable strings.

This string appears to be allocated a lot but can be moved to a constant. This only improves memory for versions below Ruby 2.3 because I belive Ruby has optimizations going forward that allow it to re-use these immutable strings.
@callumj callumj requested a review from a team December 5, 2020 00:07
Copy link
Contributor

@ericmustin ericmustin left a comment

Choose a reason for hiding this comment

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

👍 lgtm, ty for the contribution!

@ericmustin ericmustin added the performance Involves performance (e.g. CPU, memory, etc) label Dec 7, 2020
@ericmustin ericmustin added this to the 0.44.0 milestone Dec 7, 2020
@ericmustin
Copy link
Contributor

@callumj hm it looks like circleci may have been having some issues when u made the pr, would u mind pushing a no-op commit or something to that effect to kick the ci? sorry for the hassle

@callumj
Copy link
Contributor Author

callumj commented Dec 7, 2020

@marcotc @ericmustin do you know why this might fail on JRuby?

@callumj
Copy link
Contributor Author

callumj commented Dec 7, 2020

Fixed it

@ericmustin ericmustin merged commit 8784076 into DataDog:master Dec 7, 2020
@ericmustin
Copy link
Contributor

@callumj sorry about the hassle there, the CI has some flakiness we've been working on improving but still have a ways to go clearly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Involves performance (e.g. CPU, memory, etc)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants