### Features
We can now write tailing memory to a utrace file. Snapshotting while tracing to a file or socket is supported.
This change introduces a new console command: Trace.SnapshotFile. It writes the profiling data from memory into an optionally specified a utrace file.
### Testing
Run Editor with -tracefile
Run Editor with -trace, connect live with insights
Run Editor without -trace (this does generate a very small utrace since there is memory and data in the tail even though default channels are not enabled)
#rb johan.berg
#jira UE-150302,UE-150292
#preflight 6272a3213e1f2a9d3a88ee3d
#ROBOMERGE-OWNER: geoff.evans
#ROBOMERGE-AUTHOR: geoff.evans
#ROBOMERGE-SOURCE: CL 20124258 via CL 20125717 via CL 20126082
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)
[CL 20129506 by geoff evans in ue5-main branch]
Adds a new field type for trace events which contains a reference to a previously emitted event. In order to create a reference, the referenced event type needs to be declared with a new "definition" flag. The definition flag also defines type of id that is used for the reference, 8, 16, 32 and 64 bit values are supported.
#rb ionut.matasaru, martin.ridgers
#preflight 627393ea4e24dbee173d42c5
[CL 20055730 by Johan Berg in ue5-main branch]
* Added 'Trace.Enable' and 'Trace.Disable' console commands to control channels.
* 'Trace.Start' is marked as deprecated in favor of Trace.File.
* For 'Trace.File' both arguments are now optional, and heuristic for detecting a file argument implemented.
* 'Trace.Stop' no longer disables channels.
* 'Trace.Pause/Resume' now keeps a list of the current active channels which will be restored. Logic for enabling channels has been separated from EnableChannels which is used in initialization sequence.
* Changed FChannel toggling to directly write the state. This change was done to reduce confusion around enabling/disabling channels and preset that overlaps.
* Refactored some methods internal to FTraceAuxilliaryImpl
#jira UE-136002
#preflight 61d80f13430de36baa590e55
#ROBOMERGE-OWNER: johan.berg
#ROBOMERGE-AUTHOR: johan.berg
#ROBOMERGE-SOURCE: CL 18540924 in //UE5/Release-5.0/... via CL 18540956
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v899-18417669)
[CL 18540960 by johan berg in ue5-release-engine-test branch]
Added console command to print status of trace to in game console. In order to list the available channels a enumeration method was added.
#rb martin.ridgers
#jira UE-136018
#preflight 61b32d0dc01c89f906dc3dbd
#ROBOMERGE-AUTHOR: johan.berg
#ROBOMERGE-SOURCE: CL 18429738 in //UE5/Release-5.0/... via CL 18429749
#ROBOMERGE-BOT: STARSHIP (Release-Engine-Staging -> Release-Engine-Test) (v897-18405271)
[CL 18429751 by johan berg in ue5-release-engine-test branch]
Bonus; analysis can get going quicker if a sync is added directly after the tails been sent to a new connection.
#preflight 61936d13f65efa9243c8959c
#ROBOMERGE-AUTHOR: martin.ridgers
#ROBOMERGE-SOURCE: CL 18203841 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v895-18170469)
[CL 18203845 by martin ridgers in ue5-release-engine-test branch]
This represents UE4/Main @18073326, Release-5.0 @18081140 and Dev-PerfTest @18045971
[CL 18081471 by aurel cordonnier in ue5-release-engine-test branch]
This represents UE4/Main @17911760, Release-5.0 @17915875 and Dev-PerfTest @17914035
[CL 17918595 by aurel cordonnier in ue5-release-engine-test branch]
Cache wasted was calculated incorrectly. Bytes-sent was missing some bytes. Memory was bumped to 64 bits just in case a 4GB accident happens.
#rb jb
#rnx
#preflight 616e6b616e12ff00011bb806
#ROBOMERGE-AUTHOR: martin.ridgers
#ROBOMERGE-SOURCE: CL 17857934 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v883-17842818)
[CL 17857943 by martin ridgers in ue5-release-engine-test branch]
LZ4 compression needs one contiguous piece of memory of worst-case size. This can result in not insignificant waste at the end of each page of cached important event data. By bumping the size the wastage happens less often. Perhaps a better way would be to check if LZ4 can compress in two steps.
#rb jb
#rnx
#ROBOMERGE-AUTHOR: martin.ridgers
#ROBOMERGE-SOURCE: CL 17828411 in //UE5/Main/...
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Test) (v881-17767770)
[CL 17828416 by martin ridgers in ue5-release-engine-test branch]