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

benchmark: add primivites benchmark for Unlocking via defer vs. inline #1534

Merged
merged 2 commits into from
Sep 21, 2017

Conversation

dfawley
Copy link
Member

@dfawley dfawley commented Sep 21, 2017

Results:

$ go test -benchtime=3s -benchmem -bench=Defer benchmark/primitives/*.go
goos: linux
goarch: amd64
BenchmarkMutexWithDefer-12       	100000000	        50.2 ns/op	       0 B/op	       0 allocs/op
BenchmarkMutexWithoutDefer-12    	300000000	        16.3 ns/op	       0 B/op	       0 allocs/op

@dfawley dfawley merged commit d4b75eb into grpc:master Sep 21, 2017
@menghanl menghanl added this to the 1.7 Release milestone Sep 21, 2017
@dfawley dfawley deleted the benchdefer branch September 21, 2017 22:19
@lock lock bot locked as resolved and limited conversation to collaborators Jan 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants