Skip to content

pkg/stack: Add benchmark for unwind table generation#925

Merged
javierhonduco merged 1 commit intomainfrom
add-benchmark-for-unwind-table-generation
Oct 18, 2022
Merged

pkg/stack: Add benchmark for unwind table generation#925
javierhonduco merged 1 commit intomainfrom
add-benchmark-for-unwind-table-generation

Conversation

@javierhonduco
Copy link
Contributor

@javierhonduco javierhonduco commented Oct 18, 2022

Adding a benchmark for our table generation code to track its performance over time

$ go test -v github.com/parca-dev/parca-agent/pkg/stack/unwind -bench=.

=== RUN   TestBuildUnwindTable
--- PASS: TestBuildUnwindTable (0.00s)
goos: linux
goarch: amd64
pkg: github.com/parca-dev/parca-agent/pkg/stack/unwind
cpu: Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz
BenchmarkParsingLibcDwarfUnwindInformation
BenchmarkParsingLibcDwarfUnwindInformation-12    	      58	  57819288 ns/op	32710616 B/op	  149598 allocs/op
PASS
ok  	github.com/parca-dev/parca-agent/pkg/stack/unwind	3.380s

cc @brancz @v-thakkar

Signed-off-by: Francisco Javier Honduvilla Coto javierhonduco@gmail.com

```
$ go test -v github.com/parca-dev/parca-agent/pkg/stack/unwind -bench=.

=== RUN   TestBuildUnwindTable
--- PASS: TestBuildUnwindTable (0.00s)
goos: linux
goarch: amd64
pkg: github.com/parca-dev/parca-agent/pkg/stack/unwind
cpu: Intel(R) Core(TM) i7-8700K CPU @ 3.70GHz
BenchmarkParsingLibcDwarfUnwindInformation
BenchmarkParsingLibcDwarfUnwindInformation-12    	      58	  57819288 ns/op	32710616 B/op	  149598 allocs/op
PASS
ok  	github.com/parca-dev/parca-agent/pkg/stack/unwind	3.380s
```

Signed-off-by: Francisco Javier Honduvilla Coto <javierhonduco@gmail.com>
@javierhonduco javierhonduco requested a review from a team as a code owner October 18, 2022 12:45
Copy link
Member

@brancz brancz left a comment

Choose a reason for hiding this comment

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

Nice!! At <100ms on relatively modern hardware I'm not worried for now that we need to think about trading off storage for CPU time.

@javierhonduco javierhonduco changed the title pkg/stack: Add benchmark unwind table generation pkg/stack: Add benchmark for unwind table generation Oct 18, 2022
@javierhonduco
Copy link
Contributor Author

This is just one dynamic library though. Will do some napkin math in the next couple of weeks to see what performance might look like for a big cluster w.r.t. the idea of backend-driven tables

@javierhonduco javierhonduco merged commit 03ca59b into main Oct 18, 2022
@javierhonduco javierhonduco deleted the add-benchmark-for-unwind-table-generation branch October 18, 2022 15:22
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

Comments