PGPROF/en: Difference between revisions

Updating to match new version of source page
(Updating to match new version of source page)
(Updating to match new version of source page)
Line 6: Line 6:
= Quickstart guide =
= Quickstart guide =
Using PGPROF usually consists of two steps:  
Using PGPROF usually consists of two steps:  
# Data collection: Run the application with profiling enabled.
# '''Data collection''': Run the application with profiling enabled.
# Analysis: Visualize the data produced in the first step.
# '''Analysis''': Visualize the data produced in the first step.
Both steps can be accomplished in either command-line mode or graphical mode.  
Both steps can be accomplished in either command-line mode or graphical mode.  


Line 26: Line 26:
== Command-line mode ==
== Command-line mode ==


Data collection: Use PGPROF to run the application and save the performance data in a file.  In this example, the application
'''Data collection''': Use PGPROF to run the application and save the performance data in a file.  In this example, the application
is <code>a.out</code> and we choose to save the data in <code>a.prof</code>.  
is <code>a.out</code> and we choose to save the data in <code>a.prof</code>.  
{{Command|pgprof -o a.prof ./a.out}}
{{Command|pgprof -o a.prof ./a.out}}


You can optionally save the data file and analyze it in graphical mode (see below) using ''File | Import''.
You can optionally save the data file and analyze it in graphical mode (see below) using ''File | Import''.
<br>Analysis: To visualize the performance data in command-line mode:
<br>'''Analysis''': To visualize the performance data in command-line mode:
{{Command|pgprof -i a.prof}}
{{Command|pgprof -i a.prof}}
The results are usually divided into several categories, for example:
The results are usually divided into several categories, for example:
Line 113: Line 113:


[[File:pgprof2.png|thumbnail|300px|Visualizing performance data (click for a larger image)|left  ]]
[[File:pgprof2.png|thumbnail|300px|Visualizing performance data (click for a larger image)|left  ]]
Take note of these four panes in the graphical interface (see the image "Visualizing performance data", to the left):
The visualization window is comprised of four panes:
* The Timeline: shows all the events ordered by the time they executed
* The Timeline: shows all the events ordered by the time they executed
* '''GPU Details''': shows performance details for the GPU kernels
* '''GPU Details''': shows performance details for the GPU kernels
38,897

edits