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

possible to remove the allocations? make it 0? #57

Open
superdolt opened this issue Jul 24, 2021 · 4 comments
Open

possible to remove the allocations? make it 0? #57

superdolt opened this issue Jul 24, 2021 · 4 comments

Comments

@superdolt
Copy link

if cant remove the big cache, maybe the normal cache? there's 2allocs/op now... is it possible to remove it?

BenchmarkBigCacheSet-4 2000 10566656 ns/op 6.20 MB/s 4660369 B/op 6 allocs/op
BenchmarkBigCacheGet-4 2000 6902694 ns/op 9.49 MB/s 684169 B/op 131076 allocs/op
BenchmarkBigCacheSetGet-4 1000 17579118 ns/op 7.46 MB/s 5046744 B/op 131083 allocs/op
BenchmarkCacheSet-4 5000 3808874 ns/op 17.21 MB/s 1142 B/op 2 allocs/op
BenchmarkCacheGet-4 5000 3293849 ns/op 19.90 MB/s 1140 B/op 2 allocs/op
BenchmarkCacheSetGet-4 2000 8456061 ns/op 15.50 MB/s 2857 B/op 5 allocs/op

@cristaloleg
Copy link

Is this a theoretical questions or a real obstacle? Can you clarify, please.

@superdolt
Copy link
Author

real obstacle. hope to have complete zero allocation to the benchmark

@cristaloleg
Copy link

Can you be more precise, please? What is the problem with this allocs? how bad it's for you, so...just the details to better understand the case. Thank you.

@superdolt
Copy link
Author

just garbage collection? 0 alloc/ op will not have any gc

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

No branches or pull requests

2 participants