Skip to content

Commit

Permalink
docs: clarifying the help message and documentation for aggregate-cal…
Browse files Browse the repository at this point in the history
…lees in CLI.
  • Loading branch information
JansonLv committed Oct 19, 2024
1 parent 603dd14 commit 702e20d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmd/profilecli/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ func addQueryGoPGOParams(queryCmd commander) *queryGoPGOParams {
params := new(queryGoPGOParams)
params.queryProfileParams = addQueryProfileParams(queryCmd)
queryCmd.Flag("keep-locations", "Number of leaf locations to keep.").Default("5").Uint32Var(&params.KeepLocations)
queryCmd.Flag("aggregate-callees", "Default: false. Aggregate samples for the same callee by ignoring the line numbers in the leaf locations. Use --aggregate-callees to enable or --no-aggregate-callees to disable.").Default("false").BoolVar(&params.AggregateCallees)
queryCmd.Flag("aggregate-callees", "Default: true. Aggregate samples for the same callee by ignoring the line numbers in the leaf locations. Use --aggregate-callees to enable or --no-aggregate-callees to disable.").Default("true").BoolVar(&params.AggregateCallees)
return params
}

Expand Down
2 changes: 1 addition & 1 deletion docs/sources/view-and-analyze-profile-data/profile-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ By default, it looks for samples within the last hour, though this can be contro
- You can provide a custom time range using the `--from` and `--to` flags, for example, `--from="now-3h" --to="now"`.
- You can specify the profile type via the `--profile-type` flag. The available profile types are listed in the output of the `profilecli query series` command.
- You can specify the number of leaf locations to keep via the `--keep-locations` flag. The default value is `5`. The Go compiler does not use the full stack trace. Reducing the number helps to minimize the profile size.
- You can specify whether the callee aggregation should be used via the `--aggregate-callees` flag. By default, samples are aggregated by the leaf location, ignoring callee line number. Go compiler ignores this information.
- You can specify whether the callee aggregation should be used via the `--aggregate-callees` flag. By default, this setting is true, samples are aggregated by the leaf location, ignoring callee line number. Go compiler ignores this information. You can use `--no-aggregate-callees` to disable aggregation. Try both options to see which gives better for your PGO.

2. Construct and execute the command.

Expand Down

0 comments on commit 702e20d

Please sign in to comment.