### Notes
Many other platforms already do this, this just brings parity to Windows.
I think by design the error message is meant to be reported via a call to HandleError() or LogFormattedMessageWithCallstack(), but sometimes neither happens. The reasons are unclear due to lack of information.
This print may be redundant (the message be printed twice in some situations, once with a callstack and once without), but that's better than not having it at all in edge cases.
#rnx
#rb joe.kirchoff
#jira UE-151094
#preflight 6283ed244106f5854a6e4dae
[CL 20248920 by geoff evans in ue5-main branch]
### Notes
The check() message and callstack is actually printed in FWindowsErrorOutputDevice::HandleError which is called in the __except block after we RaiseException() inside ReportAssert(). However, RenderingThread's __except doesn't do this, so the contents of GErrorHist are lost to everyone except for CrashReporter. This change adds this necessary logging.
Also, add Windows Launch support for -IgnoreDebugger when choosing __try/__except or not (this precedes initialization of GIgnoreDebugger). This makes debugging easier for this class of issue.
### Testing
Repro steps are in the JIRA. Tested at that change (which has a reliable RenderingThread check() failure), and at #head where no defect exists. Tests fail and pass, respectively, as expected.
#rnx
#rb francis.hurteau
#jira UE-151056
#preflight 627b0b4ac42338be653745e6
[CL 20140980 by geoff evans in ue5-main branch]
Also adds support for detecting Windows Server 2022.
#jira UE-149576
#rnx
#lockdown Michal.Valient
#preflight https://horde.devtools.epicgames.com/job/625ec6259c09ef439d96bc85
#rb Christopher.Waters
#ROBOMERGE-AUTHOR: mihnea.balta
#ROBOMERGE-SOURCE: CL 19936502 in //UE5/Release-5.0/... via CL 19936683
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)
[CL 19937373 by mihnea balta in ue5-main branch]
#rb none
#ROBOMERGE-AUTHOR: robert.millar
#ROBOMERGE-SOURCE: CL 19928610 via CL 19930155 via CL 19931144 via CL 19931272
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)
[CL 19932829 by robert millar in ue5-main branch]
#rb david.harvey
#ROBOMERGE-AUTHOR: robert.millar
#ROBOMERGE-SOURCE: CL 19920967 via CL 19923246 via CL 19924138 via CL 19924689
#ROBOMERGE-BOT: UE5 (Release-Engine-Staging -> Main) (v943-19904690)
[CL 19927818 by robert millar in ue5-main branch]
Fix error handling, make PreloadHint respect in parameters and overload SupportsMemoryMappedFiles
#rb robert.seiver
#preflight yes
[CL 19898968 by Johan Torp in ue5-main branch]
The crash reporter thread was calling GLog->Panic() which would make it the panic thread and prevent subsequent logging from any other thread. Panic from ReportCrash to ensure that the thread handling the exception is the panic thread, which allows it to log the callstack after the crash reporter finishes.
#jira UE-148406
#preflight 6255f4d6647ad886b3693531
#rb Zousar.Shaker
#rnx
[CL 19738619 by Devin Doucette in ue5-main branch]
Panic allows only one thread to become the panic thread. In panic mode, logs are only sent to panic-safe output devices. Each call to Panic flushes buffered logs to panic-safe output devices, and flushes panic-safe output devices.
#jira UE-147152
#preflight 62424814292f228e09d8a612
#rb Zousar.Shaker
#fyi Brandon.Schaefer
[CL 19545093 by Devin Doucette in ue5-main branch]
- This restore proper prioritization support that was lost with the new task backend while keeping a sane number of threads
- This helps to prevent latency sensitive tasks from going to efficient cores for Alder Lake
- This fixes performance problems caused by high prio task getting picked up by background threads and being preempted under high-load, causing FPS hiccups.
- SetThreadPriority takes ~20us on average on Windows System and is only paid for background work
- Longer SetThreadPriority can be expected when lowering the priority of a task under heavy load, which might cause the caller to be preempted right away, this is expected.
- Can be A/B tested from command-line with -TaskGraphUseDynamicPrioritization=1/0
#rb Andriy.Tylychko, Arne.Schober, Stefan.Boberg
#preflight 622786a7e83598518f3745a1
[CL 19314282 by danny couture in ue5-main branch]
- this change prevents gauntlet from running tasks on Xbox so I am backing it out
- instance of Horde failure: https://horde.devtools.epicgames.com/job/61f43b2f74510448a686da51?step=72cc
- the XboxConsoleInputReader thread is created and immediately terminates
- this change introduced a null out of Runnable in the Xbox version of FRunnableThreadWin::Run()
- this causes FRunnableThread::SetupCreatedThread() to assert on startup that a valid runnable thread was created but has no Runnable
#rb none
#preflight 61f47fb6801201ab389bb311
[FYI] ionut.matasaru
Original CL Desc
-----------------------------------------------------------------
[Insights]
- Fixed memory tracking for an FRunnableThread to emit a free event when the thread ends.
- Fixed memory tracking for "ProgramSize" of loaded modules (dlls), to emit a free event when dll is unloaded.
#jira UE-140358
#rb Johan.Berg
#preflight 61f40923f628752a568b292b
#ROBOMERGE-AUTHOR: eric.mcdaniel
#ROBOMERGE-SOURCE: CL 18781656 in //UE5/Release-5.0/... via CL 18781895 via CL 18781943
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)
[CL 18781953 by eric mcdaniel in ue5-main branch]
- Fixed memory tracking for an FRunnableThread to emit a free event when the thread ends.
- Fixed memory tracking for "ProgramSize" of loaded modules (dlls), to emit a free event when dll is unloaded.
#jira UE-140358
#rb Johan.Berg
#preflight 61f40923f628752a568b292b
#ROBOMERGE-AUTHOR: ionut.matasaru
#ROBOMERGE-SOURCE: CL 18771801 in //UE5/Release-5.0/... via CL 18771806 via CL 18771881
#ROBOMERGE-BOT: UE5 (Release-Engine-Test -> Main) (v903-18687472)
[CL 18771891 by ionut matasaru in ue5-main branch]