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

object/bos: reduce memory allocation in bos #5642

Closed
wants to merge 3 commits into from
Closed

Conversation

zhijian-pro
Copy link
Contributor

No description provided.

pkg/utils/dynamic_alloc.go Outdated Show resolved Hide resolved
pkg/utils/alloc.go Show resolved Hide resolved
Copy link

codecov bot commented Feb 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 21.47%. Comparing base (58cf613) to head (b8fc8b4).
Report is 10 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #5642       +/-   ##
===========================================
- Coverage   54.78%   21.47%   -33.32%     
===========================================
  Files         165       29      -136     
  Lines       48361    19187    -29174     
===========================================
- Hits        26495     4120    -22375     
+ Misses      18956    14576     -4380     
+ Partials     2910      491     -2419     

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

}

func FloorPowerOf2(s int) int {
var bits int
Copy link
Contributor

Choose a reason for hiding this comment

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

if s <= 0 {
return 0
}

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