1
1
mirror of https://github.com/walles/moar.git synced 2024-09-11 12:15:43 +03:00

More generic profile name

This name will work for -cpuprofile profiles as well.
This commit is contained in:
Johan Walles 2022-11-04 22:19:22 +01:00
parent 62322e6cc0
commit 76f8c39100

View File

@ -169,7 +169,7 @@ Profiling `BenchmarkPlainTextSearch()`. Try replacing `-alloc_objects` with
`-alloc_space` or change the `-focus` function:
```bash
go test -memprofilerate 1 -memprofile memprofile.out -benchmem -run='^$' -bench '^BenchmarkPlainTextSearch$' github.com/walles/moar/m && go tool pprof -alloc_objects -focus findFirstHit -relative_percentages -web memprofile.out
go test -memprofilerate 1 -memprofile profile.out -benchmem -run='^$' -bench '^BenchmarkPlainTextSearch$' github.com/walles/moar/m && go tool pprof -alloc_objects -focus findFirstHit -relative_percentages -web profile.out
```
Build + run: