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

optimize: use bits.Len64 instead of bsr #128

Closed
wants to merge 1 commit into from

Conversation

Hchenn
Copy link
Collaborator

@Hchenn Hchenn commented Apr 12, 2022

This PR want to solve issue #34 and #97 , And the Benchmark like:

goos: linux
goarch: amd64
pkg: github.com/bytedance/gopkg/lang/mcache
BenchmarkBsr_origin
BenchmarkBsr_origin-48     	643503000	         1.86 ns/op	       0 B/op	       0 allocs/op
BenchmarkBsr_bits
BenchmarkBsr_bits-48    	1000000000	         0.373 ns/op	       0 B/op	       0 allocs/op

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.

1 participant