Commit Graph

1401 Commits

Author SHA1 Message Date
ahmed siddique
ed4205eb31 fix issue with non ASIS android packages failing to resume from a GAndroidWindowLock_Lock
#rb matthew.sorrels

[CL 31031855 by ahmed siddique in ue5-main branch]
2024-01-30 19:41:27 -05:00
ahmed siddique
2af857e2c1 Android SingleInstanceService fixes for crash and activity switching.Also updated ASISStub and output ASISProject
#rb Chris.Babcock, matthew.sorrels
#android

[CL 31009144 by ahmed siddique in ue5-main branch]
2024-01-30 11:45:19 -05:00
Luke Thatcher
10cdd4a111 Merging //UE5/Dev-ParallelRendering/... (up to CL 30965645) to //UE5/Main/... (base CL 30962637)
Significant refactor of RHI command list management and submission, and RHI breadcrumbs / RenderGraph (RDG) scopes, to allow for parallel translation of most RHI command lists.
See individual changelists in //UE5/Dev-ParallelRendering for details. A summary of the changes is as follows:

This work's primary goal was to allow as many RHI command lists as possible to be parallel translated, to make more efficient use of many-core systems. To achieve this:
 - The submission code paths for the immediate and parallel RHI command lists have been merged into a single function: FRHICommandListExecutor::Submit().
 - A "dispatch thread" (which is simply a series of chained task graph tasks) is used to decide which command lists are batched together in a single parallel translate job.
 - Individual command lists can disable parallel translate, which forces them to be executed on the RHI thread. This happens automatically if an RHI command list performs an operation that is not thread safe (e.g. buffer lock, or low-level resource transition).

One of the primary blockers for parallel translation was the RHI breadcrumb system, and the way RDG builds scopes. This was also refactored to remove these limitations:
 - RDG could only push/pop events on the immediate command list, which resulted in parallel and immediate work being interleaved, breaking any opportunity for parallelism.
 - Platform RHI implementations of breadcrumbs (e.g. in D3D12 RHI) was not correct across multiple RHI contexts. Push/pop operations aren't necessarily balanced within any one RHI context given that RDG builds "parallel pass sets" containing arbitrary ranges of renderer passes.

A summary of the new RHI breadcrumb system is as follows:
 - A tree of breadcrumb nodes is built by the render thread and RDG. Each node contains the node name, and pointers to the parent and next nodes. When fully built, the nodes form a depth-first linked list which is used for traversing the tree for GPU crash debugging.
 - The memory for breadcrumb nodes is provided by ref-counted allocator objects. These allocators are pipelined through the RHI, allowing the platform RHI implementation to extend their lifetime for GPU crash debugging purposes.
 - RHIPushEvent / RHIPopEvent have been removed, replaced with RHIBeginBreadcrumbGPU / RHIEndBreadcrumbGPU. Platform RHIs implement these functions to perform GPU immediate writes using the unique ID of each node, for tracking GPU progress.
 - Format string arguments are captured by-value to remove the cost of string formatting while building the breadcrumb tree. String formatting only occurs when the actual formatted string is required (e.g. during GPU crash breadcrumb stack traversal, or when calling platform GPU profiling APIs).

RenderGraph scopes have been simplified:
 - The separate scope trees / arrays of ops have been combined. There is now a single tree of RDG scopes containing all types.
 - Each RDG pass holds a pointer to the scope it was created under.
 - BeginCPU / EndCPU is called on each RDG scope as the various RDG threads enter / exit them. This allows us to mark-up each worker thread with the relevant Unreal Insights scopes.

Other changes include:
 - Fixes for bugs uncovered when parallel translate was enabled.
 - Adjusted platform affinities necessary due to the new layout of thread tasks in the renderer.
 - Refactored RHI draw call stats to better fit the new pipeline design.

#rb jeannoe.morissette, zach.bethel
#jira UE-139543

[CL 30973133 by Luke Thatcher in ue5-main branch]
2024-01-29 12:47:28 -05:00
marc audy
a1b9077dc5 Update engine version to 5.5
#lockdown Aurel.Cordonnier

[CL 30972647 by marc audy in ue5-main branch]
2024-01-29 12:21:19 -05:00
rafa lecina
114db4f379 Fix always attempt to restart the app after receiving onStop command
[REVIEW] [at]Chris.Babcock, [at]Michael.Atchison, [at]Ahmed.Siddique
#rb ahmed.siddique, Chris.Babcock

[CL 30970374 by rafa lecina in ue5-main branch]
2024-01-29 11:05:41 -05:00
rafa lecina
6a39de8a9f Update GooglePlay games dependencies. This includes
- Create our own JNI wrapper on top of latest play-services-games-v2 classes
 - Adapt OSSGooglePlay to use this wrapper
 - Remove deprecated/unsupported functionality
 - Fix some issues with JNI support

#jira UE-201481
[REVIEW] [at]Michael.Kirzinger, [at]Chris.Babcock, [at]Bertrand.Carre
#rb Chris.Babcock, Michael.Kirzinger, Sam.Zamani

[CL 30963393 by rafa lecina in ue5-main branch]
2024-01-29 03:39:53 -05:00
steve robb
f029468598 Fixed up a lot of bool-taking container resize functions to take EAllowShrinking instead.
[CL 30729174 by steve robb in ue5-main branch]
2024-01-19 16:41:35 -05:00
ahmed siddique
5fc600c0bf fix linux compile issue with include upper case lower case name.
#android

[CL 30717671 by ahmed siddique in ue5-main branch]
2024-01-19 11:48:50 -05:00
ahmed siddique
81e2dbfee7 Android SingleInstance Services fixes to address crash and activity/surface binding issues.
known issues remaining: have to pause before switching surface binding (should be handled internally eventually)
need to finish up the changes for compiling reference ASIS android studio project samlple. This will be in another submit.
#rb chris.babcock
#android

[CL 30685682 by ahmed siddique in ue5-main branch]
2024-01-18 11:23:13 -05:00
jodon karlik
4250442a43 Improving multiple PIE session VisLog capabilities. The TimeStamp used is now a global Engine TimeStamp. The WorldTimeStamp is also recorded separately for ease of debugging. By using this Engine TimeStamp during PIE sesions, we can correctly record the time for client & server events, allowing us to see the effects of replicated data more clearly on the timeline.
When using bForceUniqueLogNames, we record offsets to an initial Engine TimeStamp which gives us similar functionality to just using WorldTimeStamp in the Log Visualizer (i.e. multiple runs will line-up at time 0).
When not using bForceUniqueLogNames, we only record the offset when the data is cleared in the Log Visualizer.  That will allow multiple runs to record properly on a single timeline (rather than having new data overwrite old data).

bForceUniqueLogNames is now the default setting.

#jira UE-203873
#rb ben.hoffman, Mieszko.Zielinski, Yoan.StAmant
#lockdown marc.audy

[CL 30639009 by jodon karlik in ue5-main branch]
2024-01-16 13:55:38 -05:00
saim80
4cc46194f1 Safer NSApp terminate: call.
#jira UE-203315
#rb Josh.Adams
#11271

[CL 30623430 by saim80 in ue5-main branch]
2024-01-15 15:06:30 -05:00
joe andresen
70ff48725b AndroidSingleInstance Window Fix
#rb ahmed.siddique


[FYI] Chris.Babcock

[CL 30428984 by joe andresen in ue5-main branch]
2023-12-21 11:46:35 -05:00
jason hoerner
83fd93e740 [Backout Resubmit with missing include build fix]
SlackReport debug command for TArray slack tracking.
* Requires ENABLE_ARRAY_SLACK_TRACKING define to be enabled at compile time (enabling the tracking all the time would be too significant a performance hit, as it requires a function call per array count change).
* Generates TSV (tab separated value) reports in Shared/Logs/SlackReport, which can be loaded into a spreadsheet program.  A filename can be specified to the command, or a default one with an incrementing index will be used.
* Switch -Stack=N controls the number of stack frames used for sorting.  Setting a value less than the maximum (9 levels) can coalesce instances of the same allocation from slightly different call stacks.  Switch -Verbose=0 enables a more condensed report that only shows the largest unique Num / Max bucket per call stack.

#rb Steve.Robb

[CL 30346075 by jason hoerner in ue5-main branch]
2023-12-15 06:58:37 -05:00
justin peterson
b84c432245 [Backout] - CL30332333 - CIS Compile Error
[FYI] jason.hoerner
Original CL Desc
-----------------------------------------------------------------
SlackReport debug command for TArray slack tracking.
* Requires ENABLE_ARRAY_SLACK_TRACKING define to be enabled at compile time (enabling the tracking all the time would be too significant a performance hit, as it requires a function call per array count change).
* Generates TSV (tab separated value) reports in Shared/Logs/SlackReport, which can be loaded into a spreadsheet program.  A filename can be specified to the command, or a default one with an incrementing index will be used.
* Switch -Stack=N controls the number of stack frames used for sorting.  Setting a value less than the maximum (9 levels) can coalesce instances of the same allocation from slightly different call stacks.  Switch -Verbose=0 enables a more condensed report that only shows the largest unique Num / Max bucket per call stack.

#rb Steve.Robb

[CL 30336635 by justin peterson in ue5-main branch]
2023-12-14 18:42:26 -05:00
jason hoerner
290975eb21 SlackReport debug command for TArray slack tracking.
* Requires ENABLE_ARRAY_SLACK_TRACKING define to be enabled at compile time (enabling the tracking all the time would be too significant a performance hit, as it requires a function call per array count change).
* Generates TSV (tab separated value) reports in Shared/Logs/SlackReport, which can be loaded into a spreadsheet program.  A filename can be specified to the command, or a default one with an incrementing index will be used.
* Switch -Stack=N controls the number of stack frames used for sorting.  Setting a value less than the maximum (9 levels) can coalesce instances of the same allocation from slightly different call stacks.  Switch -Verbose=0 enables a more condensed report that only shows the largest unique Num / Max bucket per call stack.

#rb Steve.Robb

[CL 30332344 by jason hoerner in ue5-main branch]
2023-12-14 16:52:04 -05:00
ahmed siddique
d70352cd9b Android SingleInstance Service
Tested on Android with Lyra and also preflight checks.

#android
#rb chris.babcock

[CL 30244258 by ahmed siddique in ue5-main branch]
2023-12-11 13:59:52 -05:00
dan elksnitis
880311d64f [shaders] generate brdf headers for the default platform before initializing shader types (the latter now has a side-effect of pre-loading and caching shader source file information for this platform, which means if the brdf headers need to change it will cache an outdated version)
#rb massimo.tristano

[CL 30154026 by dan elksnitis in ue5-main branch]
2023-12-06 09:41:04 -05:00
christopher waters
7b1717159f Dependency Cleanup
- Moving IAssetCompilingManager to its own header
- Changing FAsyncCompilationNotification members to TUniquePtr<FAsyncCompilationNotification> to remove dependencies on AsyncCompilationHelpers.h
- Removing includes of AsyncCompilationHelpers.h and AssetCompilingManager.h removes 3s of compile time per file on a 3990x

#rb henrik.karlsson

[CL 30094069 by christopher waters in ue5-main branch]
2023-12-04 16:06:02 -05:00
alex kahn
eee2dd4151 [Backout] - CL30051221 - CIS Compile Error
[FYI] christopher.waters
Original CL Desc
-----------------------------------------------------------------
Dependency Cleanup
- Moving IAssetCompilingManager to its own header
- Changing FAsyncCompilationNotification members to TUniquePtr<FAsyncCompilationNotification> to remove dependencies on AsyncCompilationHelpers.h
- Removing includes of AsyncCompilationHelpers.h and AssetCompilingManager.h removes 3s of compile time per file on a 3990x

#rb henrik.karlsson

[CL 30054260 by alex kahn in ue5-main branch]
2023-12-01 16:35:33 -05:00
christopher waters
f665a777c7 Dependency Cleanup
- Moving IAssetCompilingManager to its own header
- Changing FAsyncCompilationNotification members to TUniquePtr<FAsyncCompilationNotification> to remove dependencies on AsyncCompilationHelpers.h
- Removing includes of AsyncCompilationHelpers.h and AssetCompilingManager.h removes 3s of compile time per file on a 3990x

#rb henrik.karlsson

[CL 30051281 by christopher waters in ue5-main branch]
2023-12-01 15:32:12 -05:00
ben marsh
c56b317cbd Add support for JSON log events from stdout to Gauntlet, and re-enable automatically turning on JSON output when UE_LOG_JSON_TO_STDOUT environment variable is set.
[FYI] Devin.Doucette

[CL 30039040 by ben marsh in ue5-main branch]
2023-12-01 09:12:43 -05:00
ben zeigler
6e81a09c2a Remove broken blueprint performance tracking code now that Insights works well:
BlueprintCompileAndLoadTimerData has been wrong ever since the compilation manager was added
FScopedCompilerEvent was broken because there are two active compilation logs in many cases
Delete unused stats and replace a few with trace scopes
#rb dan.oconnor

[CL 29996340 by ben zeigler in ue5-main branch]
2023-11-29 14:53:02 -05:00
devin doucette
fccbcacdee Logging: Backed out support for UE_LOG_JSON_TO_STDOUT
#rnx

[CL 29912178 by devin doucette in ue5-main branch]
2023-11-23 13:09:34 -05:00
devin doucette
2c7e07838e Logging: Added env var UE_LOG_JSON_TO_STDOUT=1 to enable structured logging on stdout for consistency with other tools
#rb Zousar.Shaker

[CL 29910379 by devin doucette in ue5-main branch]
2023-11-23 10:36:46 -05:00
ionut matasaru
62c44bba97 [Insights] Fixed "Frame" CPU timing events for the Render thread to not be added when the "RenderCommands" trace channel is on. This is because the "BeginFrame" and "EndFrame" commands will define CPU scopes (when "RenderCommands" channel is on) and will overlap with the "Frame" timing event (resulting in incorrect timestamps for both "BeginFrame" and "Frame" timing events). Also renamed "Frame" to "RenderingFrame" for the timer to not be merged with one used in the Game thread.
#jira UE-201035
#rb Johan.Berg, Catalin.Dragoiu

[CL 29908662 by ionut matasaru in ue5-main branch]
2023-11-23 08:18:10 -05:00