-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
perf: add page #1561
perf: add page #1561
Conversation
pages/linux/perf.md
Outdated
|
||
> Framework for linux performance counter measurements. | ||
|
||
- Gather basic performance counter stats for a command: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It also displays the stats in the console right ? So maybe Display is a better word than Gather. Since Gather does not specify whether it will be showed or not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure..
pages/linux/perf.md
Outdated
|
||
- Gather basic performance counter stats for a command: | ||
|
||
`perf stat {{command}}` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it might be clearer to mention an actual command so that users can get a better idea. Also add a -
after stat so that extra options can be applied to a command.
pages/linux/perf.md
Outdated
|
||
`sudo perf top` | ||
|
||
- Run a command and record its profile into perf.data: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perf.data within quotes("")
pages/linux/perf.md
Outdated
|
||
`sudo perf record {{command}}` | ||
|
||
- Read perf.data (created by perf record) and display the profile: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perf.data within quotes("") and perf record within backticks.
pages/linux/perf.md
Outdated
|
||
> Framework for linux performance counter measurements. | ||
|
||
- Display basic performance counter stats for a command `gcc -c -O3 hello.c`: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No need to mention the gcc command in the description.
pages/linux/perf.md
Outdated
|
||
- Display basic performance counter stats for a command `gcc -c -O3 hello.c`: | ||
|
||
`perf stat {{gcc -c -O3 hello.c}}` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a - after stat. Also, would you like to remove the -c and -O3 flags to keep it simple ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure, I would.
I can't add -
after stat, as it works without it, whatever you write after perf stat
is taken as an executable.
Also adding a -
throws an error as the program is not written to handle it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I must have been looking at older documentation.
Thanks, @mfrw! 😺 |
The page (if new), does not already exist in the repo.
The page (if new), has been added to the correct platform folder:
common/
if it's common to all platforms,linux/
if it's Linux-specific, and so on.The page has 8 or fewer examples.
The PR is appropriately titled:
<command name>: add page
for new pages, or<command name>: <description of changes>
for pages being editedThe page follows the contributing guidelines