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

perf: mesgdef clear array pool #478

Merged
merged 2 commits into from
Oct 4, 2024
Merged

Conversation

muktihari
Copy link
Owner

  • Clear fields' array pool after we are done using it. A field may be an unknown field and field's Value may contains pointer to a slice. In the case of unknown field, its FieldBase object is newly created, it's not referencing factory's defined object, so it needs to be freed. Previously, those objects can only be freed after the array pool is freed first since the array pool is still referencing them. Now those objects can be freed right after we clear the array pool.
  • Minor clean code, update mesgdef code documentation for SetUnknownFields and SetDeveloperFields.

@muktihari muktihari added the performance Changes related to performance improvement label Oct 4, 2024
@muktihari muktihari self-assigned this Oct 4, 2024
@muktihari muktihari added this to the v0.24.1 milestone Oct 4, 2024
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (dfc5d4e) to head (b7bb55d).

Additional details and impacted files
@@            Coverage Diff            @@
##            master      #478   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           42        42           
  Lines         3810      3810           
=========================================
  Hits          3810      3810           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@muktihari muktihari merged commit b85b163 into master Oct 4, 2024
5 checks passed
@muktihari muktihari deleted the perf/mesgdef-clear-array-pool branch October 4, 2024 11:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Changes related to performance improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants