Commit 17425c50 authored by Leena Miettinen's avatar Leena Miettinen
Browse files

Doc: changes to QML profiler



Change-Id: I2320c81897202b8ce1a3c6d48d3ad786b9826d02
Reviewed-by: default avatarChristiaan Janssen <christiaan.janssen@nokia.com>
parent 079fc49e
......@@ -50,25 +50,22 @@
\o Select \gui {Analyze > QML Profiler} to profile the current
application.
\image qtcreator-qml-performance-monitor-toolbar.png "QML Profiler toolbar"
\o Select the \gui Start button (1) to start the application from the
QML Profiler.
\o Select the
\inlineimage qtcreator-analyze-start-button.png "Start button"
button to start the application from the QML Profiler.
\image qtcreator-qml-performance-monitor-toolbar.png "QML Profiler toolbar"
\note If data collection does not start automatically, select the
\inlineimage qtcreator-analyzer-button.png "Analyzer button"
button.
\gui {Enable Profiling} button (3).
\endlist
When you start analyzing an application, the application is launched, and
the QML Profiler immediately begins to collect data. This is indicated by
the time running in the \gui Elapsed field.
the time running in the \gui Elapsed field (4).
Data is collected until you select the
\inlineimage qtcreator-analyzer-stop-button.png "Stop button"
button. Data collection takes time, and therefore, there might be a delay
Data is collected until you select the \gui Stop button (2). Data collection
takes time, and therefore, there might be a delay
before the data is displayed.
Do not use application commands to exit the application, because data is
......@@ -76,11 +73,16 @@
The application continues to run for some seconds, after which it is stopped
automatically. If you exit the application, the data is not sent.
Select the \inlineimage qtcreator-analyzer-button.png "Analyzer button"
button to disable the automatic start of the data collection when an
Select the \gui {Disable Profiling} button (3) to disable the automatic
start of the data collection when an
application is launched. Data collection starts when you select the button
again.
To save all the collected data, right-click any QML Profiler view to open
the context menu, and then select \gui {Save QML Trace}. To view the saved
data, select \gui {Load QML Trace}. You can also deliver the saved data to
other developers for examination or load data saved by them.
\section1 Attaching to Running Qt Quick Applications
To profile Qt Quick applications that are not launched by \QC, select
......@@ -113,22 +115,41 @@
\image qtcreator-qml-performance-monitor.png "QML Profiler"
The outline summarizes the period for which data was collected. Drag the
zoom range or click the outline to move on the outline. You can also move
between events by clicking the \gui Previous and \gui Next buttons.
Each row in the timeline (6) describes a type of QML events that were
recorded. Move the cursor on an event on a row to see how long it takes and
where in the source it is being called. To display the information only when
an event is selected, disable the \gui {View Event Information on Mouseover}
button (5).
The outline (10) summarizes the period for which data was collected. Drag
the zoom range (8) or click the outline to move on the outline. You can
also move between events by selecting the \gui {Jump to Previous Event} (1)
and \gui {Jump to Next Event} (2) buttons.
Select the \gui {Show Zoom Slider} button (3) to open a slider that you can
use to set the zoom level. You can also drag the zoom handles (9). To reset
the default zoom level, right-click the timeline to open the context menu,
and select \gui {Reset Zoom}.
\section2 Selecting Event Ranges
You can select an event range (7) to view the frame rate of events and to
compare it with the frame rate of similar events. Select the
\gui {Select Range} button (4) to activate the selection tool. Then click in
the timeline to specify the beginning of the event range. Drag the selection
handle to define the end of the range. The length of the range indicates the
frame rate of the event.
You can use event ranges also to measure delays between two subsequent
events. Place a range between the end of the first event and the beginning
of the second event. The \gui Duration field displays the delay between the
events in milliseconds.
Click the zoom buttons or drag the zoom handles to zoom in and out.
To zoom into an event range, double-click it.
You can define an event range to view the frame rate of events and to
compare it with the frame rate of similar events. Click on the timeline to
specify the beginning of the event range. Drag the cursor to define the end
of the range. The length of the range indicates the frame rate of the event.
You can drag the timeline below the event range to compare events.
To remove an event range, close the \gui Selection dialog.
Additional information is displayed on the rows above the outline.
Each row in the timeline describes a type of QML events that were recorded.
Move the cursor on an event on a row to see how long it takes and where
in the source it is being called.
\section2 Evaluating Bindings
On the \gui Binding row, you can see when a binding is evaluated and how
long the evaluation takes. Move the mouse over the binding for details
......@@ -138,9 +159,6 @@
Click the binding to move the cursor in the code editor to the part of the
code where the binding is called.
The time bar at the top of the \gui Timeline view displays the time in
seconds. To see the time in milliseconds, move the mouse on the time bar.
\section1 Viewing Events
The \gui Events view displays the number of times each binding is called
......@@ -151,30 +169,35 @@
\image qtcreator-analyzer-bindings.png "Events view"
\section1 Viewing Calling and Called Events
The \gui Callees and \gui Callers views show dependencies between events.
The \gui Callers and \gui Callees panes show dependencies between events.
They allow you to examine the internal functions of the application.
The \gui Callees view summarizes the QML events that a binding triggers.
The \gui Callers pane summarizes the QML events that trigger a binding.
This tells you what caused a change in a binding.
The \gui Callees pane summarizes the QML events that a binding triggers.
This tells you which QML events are affected if you change a binding.
\image qtcreator-qml-performance-monitor-callees.png "Callees view"
Click on a binding to move to it in the source code in the code editor.
The \gui Callers view summarizes the QML events that trigger a binding.
This tells you what caused a change in a binding.
When you select an event in the \gui Timeline view, information about it is
displayed in the \gui Events view. To view an event range in the \gui Events
view, select \gui {Limit Events Pane to Current Range} in the context menu
in the \gui Timeline view.
\image qtcreator-qml-performance-monitor-callers.png "Callers view"
To copy the contents of one view or row to the clipboard, select
\gui {Copy Table} or \gui {Copy Row} in the context menu.
Click on a binding to move to it in the source code in the code editor.
You can view similar information about JavaScript events in the
\gui JavaScript view.
\image qml-profiler-javascript.png "JavaScript view"
\section2 Viewing More Data
The QML JavaScript engine optimizes trivial bindings. The QML Profiler
does not receive information about optimized bindings, and
therefore, it displays the text \gui {<bytecode>} and the message
\gui {Source code not available} in the \gui Callees and \gui {Callers}
views.
\gui {Source code not available} in the \gui Callers and \gui {Callees}
panes.
To inspect the optimized bindings, turn off the QML optimizer by setting the
environment variable QML_DISABLE_OPTIMIZER to 1. To set the environment
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment