Timing Insights

An Overview of the Timing Insights Window in Unreal Insights.

Choose your operating system:

Windows

macOS

Linux

The Timing Insights window is where you can find per-frame performance data for different tracks, including the CPU and GPU tracks. The Timing view has a new toolbar, splitting the Tracks drop-down menu into multiple menus where you can look at different visualizations of the time your project spends on various tasks.

The Timing Insights window features the Frames panel (1), the Timing panel (2), the Log panel (3), the Timers and Counters tabs (4), and the Callers and Callees panels (5).

Timing Insights Main Toolbar

The toolbarprovides the capability to select blocks of time to view in groups, sort, or categorize data, and review log output.

You can toggle the visibility to display data for that frame in the Timing, Timers, Callers, Callees, Counters, and Log tracks by clicking on each respective track.

main-toolbar-insights

You can select blocks of time to view in aggregate, show or hide the respective panels. sort or categorize data, and review log output. To do this, click on a single frame in the Frames panel, or click and drag a section of the scrub bar at the top of the Timing panel, known as the Time Ruler.

Frames

The Frames panel displays the total time taken by each frame using a bar graph format. This is useful for identifying general trends, such as low performance or framerate drops when a level is loaded, an unoptimized scene is visible, or spawning a large number of Actors simultaneously.

frames-panel

The frames panel displays the Frames, Timing, Timers, Callers, Callees, Counters, and Log tracks.

Hovering the cursor over a bar causes that frame's index and running time to appear.

frames-index

If you right-click on on the bar, the following Zoom context menu options will appear:

zoom-context-menu

Option

Description

Auto Zoom

Toggles auto zoom, which fits the entire session time range into the frames display window.

Zoom Timing View on Frame Selection

Toggles whether the timing view is zoomed when a frame is selected.

These options are also available to edit in the UnrealInsightsSettings.ini file.

Timing

You can show or hide each track individually by clicking the arrow next to it.

timing-tracks

All Tracks

Clicking the All Tracks dropdown arrow displays a list of all available tracks.

all-tracks-menu

CPU/GPU

Clicking the CPU/GPU dropdown arrow displays theCPU and GPU tracks and thread group options.

cpu-gpu-menu

Other

Clicking the Other dropdown arrow displays options for visibility of the Main Graph, File Activity, Asset Loading, and Frames Tracks.

other-menu

Plugins

Clicking the Plugins dropdown arrow displays Tracks and options that are exposed by plugins, including information about Slate, Gameplay, Animation, and RDG Tracks.

plugins-menu

View Mode

The View Mode dropdown arrow displays controls for various options for the Timing View.

view-mode-options

Timing View Option

Description

Compact Mode (key shortcut: C)

Toggles compact mode which displays the timing tracks with reduced height supporting tracks.

Auto Hide Empty Tracks (key shortcut: V)

Auto-hides empty tracks without timing events. This option is persistent to the UnrealInsightsSettings.ini file.

Depth Limit (key shortcut: X) * Unlimited / 4 Lanes / Single Lane

Toggles the display of different CPU depth options. The X key can be used as a shortcut to cycle through the different CPU depth options.

Coloring Mode (CPU Thread tracks)

You can assign a color to CPU / GPU timing events based on their duration (inclusive time).

The color key is as follows:

  • ≥ 10ms : red.

  • ≥ 1ms : yellow.

  • ≥ 100μs : green.

  • ≥ 10μs : cyan.

  • ≥ 1μs : blue.

  • < 1μs : grey.

Allow Panning on Screen Edges

When enabled, panning continues when the mouse cursor reaches the edges of the screen.

Quick Find Widget

The Quick Find widget is used to search and filter events displayed in the Timing view. The widget can be opened from the Timing view context menu by right-clicking on a Timing event or by using the CTRL + F shortcut when the Timing view has focus.

quick-find-widget

The Quick Find widget search logic is defined using Groups and Filters. Group nodes contain child Filter nodes and define the logic applied to the children's result. Filter nodes are leaf nodes and contain a filter each.

Each filter contains:

  • The filter type, that can be selected from a drop down menu.

  • The filter operator, also selectable using a drop down menu.

  • The filter value, that can be entered using a text box.

Once the filter logic is created, it can be used to search for events or filter the tracks from the Timing View.

Filter

Description

Find First

Searches for the first event matching the filter in the order of the event's start time. If a match is found it is selected and the Timing view brings it into view.

Find Previous

Searches for the previous event matching the filter starting from the current selected event's start time. If no event is selected, it acts as a Find First.

Find Next

Searches for the next event matching the filter starting from the current selected event's start time. If no event is selected, it acts as a Find Last.

Find Last

Searches for the last event matching the filter in the order of the event's start time. If a match is found it is selected and the Timing view brings it into view.

Apply Filter

Highlights all timing events that pass the filter logic from the tracks.

Clear filters

Stops highlighting events based on the filter's logic.

If you make changes to the filter's logic, you must click Apply Filter again to highlight events based on the new logic.

Timers

The Timers panel lists all timer events that run within the time range designated in the Timing panel. In addition to grouped data based on time range, the list can be sorted in ascending or descending order by the values in any active column.

Group Name

Description

Flat

Creates a single group. Includes all Timers.

Timer Name

Creates one group for one letter.

Timer Type

Creates one group for each timer type.

Instance Count

Creates one group for each logarithmic range(1-10,10-100, 100-1000.)

To change sort order, or to activate or deactivate columns, right-click on the column. The following options are available:

Sorting Option

Additional Sort Option

Description

Sort Ascending (by Timer, Group Name, Instance Count, Total exclusive, Total inclusive.)

Sorts Column by Ascending order.

Sort Descending (by Timer, Group Name, Instance Count, Total exclusive, Total inclusive.)

Sorts Column by Descending order.

Sort By:

  • Timer or Group Name

  • Instance Count

  • Total Inclusive Time

  • Total Exclusive Time

  • Sort Ascending

  • Sort Descending

  • Name of timer or group.

  • Number of select instances.

  • Total inclusive duration of selected timer's instances.

  • Total exclusive duration of selected timer's instances.

Column Visibility Group

Description

View Column

Hides or shows the following columns.

  • Timer Or Group Name

  • Meta Group Name

  • Type

  • Instance Count

  • Total Inclusive Time

  • Max Inclusive Time

  • Average Inclusive Time

  • Median Inclusive Time

  • Min Inclusive Time

  • Total Exclusive Time

  • Max Exclusive Time

  • Acerga Exclusive Time

  • Median Exclusive Time

  • Min Exclusive Time

Show All Columns

Resets tree view to show all columns.

Reset Columns to Min/Max/Median Preset

Resets columns to Min/Max/Median Preset.

Reset Columns to Default

Resets columns to default.

Export Functionality

The Timers panel includes the capability to export your timing event data by selecting one or more timers and right-clicking on the context menu.

Timer Options Include:

Option

Description

Open Source in Visual Studio

Opens the source file of the selected message in Visual Studio.

Visual Studio must already be open before using this option otherwise it may only open its Start page.

Other Miscellaneous export options include the following:

Option

Description

Copy To Clipboard (CTRL+C)

Copies the selection of timers and their events to clipboard.

Export (CTRL+S)

Exports the selected timers and their grouped statistics to a text file.

  1. You can navigate to the Timing view and mark the time you are interested in saving from the main timeline view by clicking and dragging on the Time bar.

  2. Observe the grouped stats are updated in the Timers panel to reflect the time selection.

  3. From the Timers panel, manually select the timers you are interested in saving or use Ctrl+A to select all timers.

  4. Next, press CTRL+S or select Export from the context menu and choose a *.tsv,*.txt or *.csv file to save the selected timers and their aggregated statistics (for selected time range).

Export Timing Events

Exports the timing events to a text file.

  1. Navigate to the Timing view, and mark the time you are interested in exporting from the main timeline view, by clicking and dragging on the Time bar.

    If no time selection is made, the entire timeline will be exported.

  2. In the Timing panel, click on the CPU/GPU thread tracks to show or hide the tracks you want to export.

  3. Select the timers you are interested in, or use Ctrl+A to select all timers.

  4. Select Export Timing Events (Selection)... from context menu and choose a tab-seperated value (*.tsv/*.txt) or comma-seperated value (*.csv) file.

  5. You can export the "Threads" and "Timers" in order to match the thread id and timer id with the names of threads and timers.

More Export Options / Export Threads

Exports the list of timers to a text file. (.tsv or .csv).

More Export Options / Export Timing Events (All)

Exports all the timing events for all CPU/GPU threads to a text file (.tsv or .csv).

The exported file can be massive in size, Even a small session could have several million timing events.

Source File For CPU Timers

In the Timers panel, the source file and line number is visible in the tooltip of each timer.

source-files-for-cpu-timers

Callers and Callees

The Callers and the Callees panels display a hierarchical list of task events. When you select an event from the Timing view hovering over the information icon of an individual task will display the Id, Name, Type, Source, Number of instances (Num Instances) including detailed information on the Instance count, and total Inclusive and Exclusive time.

callers-callee-panel

Counters

The Counters panel lists all stats incremented during the same time period as the Timers panel. You can rearrange the panel by updating the sort order and column organization.

The following Groups are available:

Group Name

Description

Flat

Creates a single group. Includes all Counters.

Stats Name

Creates one group for one letter.

Meta Group Name

Creates groups based on metadata group names of counters.

Counter Type

Creates one group for each counter type.

Data Type

Creates one group for each data type.

Count

Creates one group for each logarithmic range.(1-10,10-100, 100simplecode

Log

The Log view displays all logs generated by calls to the macro UE_LOG from the Trace session. The logs can be filtered by verbosity and category, similar to the Output Log window in the Editor.

log-view

Selecting a time period in the Timing panel highlights all log entries that fall within that time. If you select multiple log entries, the Timing panel highlights the time range between those entries. The log panel features a search box that filters out all log messages that don't match the text you enter. In addition to filtering, clicking any row will pan the Timing panel to the time when that row's text was logged. You can save logs by selecting one or more messages and right-clicking on the context menu and selecting one of the following options from the drop down menu:

Menu Option

Description

Copy (CTRL+C)

Copies the selected log (with all its properties) to clipboard.

Copy Message (SHIFT+C)

Copies the message text of the selected log to clipboard

Copy Range (CTRL+SHIFT+C)

Copies all the logs in the selected time range (highlighted in blue) to the clipboard.

Copy All

Copies all the logs to clipboard

Save Range As… (CTRL+S)

Saves all the logs in the selected time range (highlighted in blue) to a text file (tab-separated values or comma-separated values).

Save All As…

Saves all the (filtered) logs to a text file (tab-separated values or comma separated values)

Open Source in Visual Studio

Task Graph Insights

Enabling CPU Task Trace

Follow the steps below to profile a CPU Task:

  1. Enable the Task and CPU trace channels when running your application from the command line by using the following command:

    -trace=default,task
  2. Navigate to the Unreal Insights Session Browser. and open your .trace file in Unreal Insights by selecting a trace from the Trace Store directory. If a session has Task events, the following functionality is available in the Timing Insights view.

a) When hovering over a Timing Event, if the current event is inside a task, extra information is displayed in the tooltip.

b) Navigate to the Other > Tasks submenu from the Timing View track. You can use this to display task graph related visualizations.

Tasks Submenu Option

Description

Show Task Critical Path

Show or Hide relations representing the critical task containing the current path.

Show Task Transitions

Show or hide transitions between the stages of the current task.

Show Task Connections

Show or hide task connections between the following options:

  • The current task's prerequisites completed time and the current task's started time.

  • The current task's completed time and the current task's subsequent started time.

  • The current task's nested tasks added time and their started time.

Show Transitions of Prerequisites

Show or hide stage transitions for the current task's prerequisites.

Show Transitions of Subsequents

Show or hide stage transitions for the current task's subsequents.

Show Transitions of Nested Tasks

Show or hide stage transitions for the current task's nested tasks.

Show Task Overview Track

Show or hide the Task Overview Track when a task is selected.

Show Detailed Info on the Task Overview Track

Shows the current task's prerequisites/nested tasks/ subsequent in the Task Overview Track.

c) Right-click anywhere in the Timing View panel to open the timing view context menu. This menu is used to display new options that can be used to sort tracks on the Task graph.

Menu Option

Description

Top Docked

Docks this track to the top.

Scrollable

Moves this track to the list of scrollable tracks.

Bottom Docked

Docks this track to the bottom.

d) When you navigate to Tasks, the Show Task Dependencies menu options display in the drop-down menu, when a timing event is selected, and if there is a task that encompasses the selected timing event.

The following data is displayed:

  • Relations in the form of arrows are drawn on the timing view to show the lifetime and stages of the task. This includes information on when it was created, launched, scheduled, started, finished and completed.

lifetime-stages-data

  • Relations are drawn between the current task and its prerequisite, subsequent, and nested tasks.

task-relations-display

  • A new top docked track appears showing the stages of the task as timing events.

Task Dependencies

When activating one or more of these options, all of the relations mentioned in the previous section are drawn for the prerequisite, subsequent, and nested tasks of the current task.

As an example, instead of a single relation from the prerequisite task's Completed Time to the current task's Scheduled Time, you now see the relations depicting the created, launched, scheduled, started, finished and completed stages of each prerequisite task enabled:

When analyzing your data, we recommend trying to activate each option one at a time as the number of relations can quickly become overwhelming.

  1. When the Critical Path option is enabled, relations showing the critical path of the current task are drawn. The critical path is defined as the execution chain in the current task's graph that has the longest execution time. Each component task's execution time is defined as the difference between the component's FinishedTime and StartTime (FinishedTime - StartTime).

This Engine feature is new, therefore the formula is subject to change with optimizations in the future.

  1. If a trace has Task data, then the Tasks minor tab becomes visible. To populate the tab, select an interval on the timing view. The tab updates to show all the tasks in the selected interval. The tab shows each of the included timestamp options: created, launched, scheduled, started, finished, and completed timestamps. By default, these timestamps are shown Relative to previous, which means they are relative to the previous stage, for instance scheduled is relative to launched. Double-clicking on a task in the table draws its relations as if it was selected by selecting a timing event in the timing view.

relations-of-timing-event

Context Switches

Context Switches are supported on Windows, XB1/XSX, and PS4/PS5 platforms.

  1. You can enable the ContextSwitch trace channel in the command line:

    -trace=default,ContextSwitch

    On Windows, depending on your user permission settings your project runtime should be "run as administrator".

  2. Open your trace file in Unreal Insights, If a session has the ContextSwitch trace event enabled, then the following information will be displayed in the Timing Insights view:

a) Additional CPU Core tracks. One for each CPU core in the recorded trace; shows timing events indicating what thread does execute on the respective CPU core. "Unknown" timing events indicate execution of threads from other applications / processes or from the OS.

b) Each CPU Thread has a header lane with core number events indicating on which core the respective thread is executing. The time range when a thread is executing and when it is preempted it is highlighted.

cpu-thread

c) CPU/GPU drop down menu shows additional options re Context Switches:

cou-gpu-context-menu

d). The context menu of a "Core" timing event in a Cpu Thread track shows additional options:

core-timing-event-track

e). The context menu of a "Thread" timing event in a CPU Core track shows additional options:

thread-timing-event