Neo Async Loading ScreenDocsNeo Settings
EngineDiagnostics

Diagnostics

Outside Shipping builds, each loading screen keeps a journal of what it presented and what froze it, and its report names the longest freeze.

On this page
  1. The report of each screen
  2. Where to read it
  3. In an Insights trace
  4. Checking it on your project
  5. The screen's content
  6. Video tips
  7. The status line

In a game on Direct3D 12, Windows 64-bit, Neo Async Loading Screen's own thread draws the loading screen while the engine loads (While the Engine Loads).

This page says what the report holds, where to read it, how to check a video, and what the optional status line says. Every code it cites has its entry in Troubleshooting.

The report of each screen

Each loading screen keeps a journal of what the window presented and of what froze it: garbage collections, the game thread waiting for the render thread, synchronous loads (with the package's name), PSOs created at render, blocks the game declared (FNeoLoadingScreenBlockingScope), the screen's own thread waiting for the render thread or for the Slate resource lock. When the screen goes, its report says the longest freeze and, when it is known, its cause. A freeze is a gap between two frames longer than the recipe's warn_gap (Recipes). The report gives these notes, one for each kind it met and, for synchronous loads, one for each package; a freeze caused by an async loading flush or a window resize gets none:

  • HLP410: a synchronous load, with the package's name;
  • HLP411: a garbage collection;
  • HLP412: the game thread waited for the render thread (FlushRenderingCommands);
  • HLP413: PSOs created at render;
  • HLP414: frozen time with no known cause, when it is more than a small share of the time the screen was frozen;
  • HLP415: a block the game declared, while the screen's own thread was not drawing (see also HLP406);
  • HLP416 and HLP417: a lever not given back as it was, or refused;
  • HLP418: the handover from the screen's thread to the game thread at the end of a load;
  • HLP419 and HLP420: the screen's own thread waited for the render thread, or for the Slate resource lock;
  • HLP421: the garbage collection pause was ended by the engine's guards;
  • HLP430 to HLP433: the music.

How a freeze gets its cause: the cause whose time covers most of it; else a cause of one instant inside it; else one that came at most two frames before it (the frame shown when a freeze begins is often the one before it); else none (its time counts toward HLP414). A synchronous load lasts from its start to the loader's last step it waited for: the work the game does after it in the same frame is not counted as the load's.

A game's log with one loading screen's report: the synchronous load it names and the advice, its figures masked.
A screen's report in the log: notes on freezes longer than the recipe's warn_gap, with their cause when known (numbers masked).

Where to read it

  • Get Last Loading Report gives the last screen's report to Blueprint and C++ (Diagnostics, one note per line).
  • The log, category LogNeoLoadingScreen, follows each screen as it goes (show, fade in, waiting, fade out) and ends it with one line, hidden ...: why it went, how long it showed, its frames and its longest freeze (with Advanced > Report: Off, no hidden line). Category LogNeoLoadingScreenLevers has one line per note, with its code.
  • With Advanced > Report: Log And File, each screen also writes Saved/Logs/NeoLoadingScreen/<time>.hlrun.json, which the Setup tab's Advanced > Reports shows.
  • NeoLoadingScreen.Report logs the last report again, with the state of the screen and the recipe's diagnostics.

Shipping builds write no log, and the report has not been checked there: read your screens' reports in a Development build.

In an Insights trace

-trace=cpu,frame,bookmark,counters,loadtime,NeoLoadingScreen shows the plugin's scopes, a bookmark and its counters at each report, and the engine's loads beside them. On the game thread: NeoLoadingScreen.Flow.Frame (each frame of a screen: its ready checks, its state machine and its journal), NeoLoadingScreen.Flow.Extensions (the status line, the levers, the music, each frame), NeoLoadingScreen.Status.Callback (the status line during a load) and NeoLoadingScreen.Diagnostics.SyncLoad; on the render thread, NeoLoadingScreen.Journal.Present (each present); once a screen, NeoLoadingScreen.Levers.Report. To read the plugin's own share of each frame, keep NeoLoadingScreen.Trace.Detail 0 (the default): 1 adds finer scopes inside the frame, which take time of their own.

Checking it on your project

Not in Shipping: show a screen (NeoLoadingScreen.Show), then NeoLoadingScreen.Debug.Stall gc | sync <package> [...] | flush <ms> | block <ms>, then NeoLoadingScreen.Hide: each freeze is in the report with its cause. NeoLoadingScreen.Debug.BlockGameThread <milliseconds> blocks the game thread under a screen of its own.

The screen's content

Two warnings in the log (category LogNeoLoadingScreen) are about what a screen shows: an image that is missing or cannot be read (HLP402, the style's plate shows instead), and a Set Next Loading Screen Tip that names a key no tip has (HLP405, the recipe's pick shows).

The Setup tab's checklist finds before the game runs a tip's image file or video that is missing or outside Config/NeoLoadingScreen (HLP025), a tip with a video and no image (HLP024), and an image that a 1920 x 1080 screen would draw soft (HLP029).

Video tips

A tip's video plays over the tip's image on Windows. The image shows instead under Reduce Motion and whenever the video cannot play, and the log says why: video turned off or Media Foundation missing (HLP440), a file that cannot play (HLP441), a video that stopped while it played (HLP442).

The Setup tab reads each tip's video when you pick it, and its checklist says before the game runs what HLP441 would say at run time (HLP028), and whether the video flashes more than the thresholds of WCAG 2.3.1 allow, the red flash as WCAG 2.0 defines it (HLP026, an estimate; Setup Tab).

When its screen ends, each video writes one line in the log (Neo Async Loading Screen: video ...): the frames decoded, what decoding and uploading them took (the first upload on its own, with whether the pipeline that converts the frames was ready then, when the video drew a frame at all), how many frames a new style converted again, and the memory it held.

To check a video on your project (not in Shipping):

  1. NeoLoadingScreen.Debug.Video <file> makes the screen of NeoLoadingScreen.Debug.BlockGameThread play that video over a black image while the game thread is blocked. A relative file is read under Saved/NeoLoadingScreen/Video/.
  2. NeoLoadingScreen.Debug.BlockGameThread <milliseconds>, then read the video's line in the log.
  3. NeoLoadingScreen.Debug.VideoBench <file> and NeoLoadingScreen.Debug.VideoPlay <file> log what decoding the video takes on this machine, as fast as possible and at its own pace. NeoLoadingScreen.Debug.WriteVideo <file> writes a test video whose frames show their number. NeoLoadingScreen.Debug.VideoFlashes <file> checks a video for flashes as the Setup tab does (without a style's grade) and logs its worst second.

The status line

Off by default. Recipe: screen { status themes | counts | developer }; Project Settings > Plugins > Neo Async Loading Screen > Look > Status Line; Blueprint: Set Loading Status Line, Reset Loading Status Line.

A loading screen in the Vanguard style: the level's name BEACON RIDGE, its tip, and the status line LOADING THE MAP under it.
With the status line set to Themes, players read what the engine is doing, not a percentage.
  • Themes: what the engine does, from real engine events, without a number: "Loading the map", "Starting the world", "Getting ready", then what the screen still waits for: "Loading assets", "Streaming the world", "Preparing shaders", "Streaming textures", "Waiting for players", "Warming up".
  • Counts: and real counts while the screen waits: "Compiling shaders: 1,204 left", "Loading assets: 37 left", "Textures to stream: 12", "Players ready: 1 of 2". Never a percentage: the engine cannot tell how much is left in time.
  • Developer: and the name of the package being loaded synchronously. Never in Shipping, where it reads as Counts.

A theme shows only once it has lasted a moment, and the line stays on screen long enough to be read, counted from the frame that first showed it, so that it does not flicker, also when a frame of the game comes late. The screen's own thread keeps the line's time while the engine works: a long step without a pause for the game (the new world's actors being initialized) shows its theme while it runs. A count that is over goes with the theme that follows it. A garbage collection stops the screen's thread too (it holds Slate's resource lock): nothing can draw the line during it, so its theme ("Freeing memory") is not shown, during it or after it. A screen that starts at Themes or above keeps the line's room under the tip, empty or not, so that the title does not move when the line appears; so does a joining screen from Connect on. The texts are the loading_status_* strings of the recipe: replace them in your own strings block, or translate them (Localization). World Partition streaming has a theme but no count (the engine only says whether it is complete).

Your game can also write its own line under the tip with Set Loading Status (API Reference). A line set before the screen shows has its room from the screen's first frame. When the screen kept no room for a line (it started below Themes with no line set, and your game sets a line or raises the level while it shows: your level's own setup under a hold, say), the line comes right under the tip and runs on into the bottom margin when the tip's room leaves too little space: the title and the tip do not move. Only a line too long for the bottom margin as well raises them, by what it lacks and as far as there is room above them: keep such a line short, or set it before the screen shows. A known limit: when a long name in a small window (or at a large Interface Size) leaves the tip less room than the set's tallest tip needs (Recipes), the line comes under the tip shown, kept room or not; while the set's tallest tip shows and grows into the bottom margin, the line can run past the window's bottom edge, or lie below it. Keep the tips short for such windows.

Something not as described? Every code the editor or the log shows has its own entry in Troubleshooting.