Commit Graph

91 Commits

Author SHA1 Message Date
jack cai
1b79e3f7e2 [Deformer Graph] Added support for array type variables
UI work to follow next

#rb halfdan.ingvarsson

[CL 34125617 by jack cai in ue5-main branch]
2024-06-05 11:04:31 -04:00
huw bowles
37137d2999 [Compute Framework] Added missing member initialisation
[CL 34066240 by huw bowles in ue5-main branch]
2024-06-03 10:50:45 -04:00
huw bowles
f37c9866b0 [Compute Framework] Add readback support as API through data interface
Readbacks are executed via FRHIGPUBufferReadback. FComputeGraphTaskWorker creates the readbacks and polls active readbacks each frame.

#rb Jeremy.Moore

[CL 34065992 by huw bowles in ue5-main branch]
2024-06-03 10:45:45 -04:00
anton dunchev
8b0b461407 [RHI] Added shader map and shader library listing commands that let you analyse the memory footprint of those structures.
[FYI] j.baumgartner
#rb serge.bernier
#tests local

[CL 34035856 by anton dunchev in ue5-main branch]
2024-05-31 13:17:18 -04:00
kenzo terelst
3df923dab2 - Add FShaderBindingLayout as RenderCore wrapper for FRHIShaderBindingLayout which can also cache static uniform buffer declerations used during shader code gen
- Add option for ShaderType to declare which FShaderBindingLayout needs to be used for shader gen and runtime binding
- Add helper function to generate FShaderBindingLayoutContainer from array of uniform buffers and EShaderResourceTableFlags (only supports bindless mode right now)
- Serialize the FRHIShaderBindingLayout in FShaderCompilerEnvironment so it can be used by the shader compiler backends
- FShaderBindingLayout can add required symbols to the FShaderCompilerInput which shouldn't be dead code eliminated (required for Shader resource table building)
- Serialize the hash of RHIShaderResourceTable in the platform specific shader binary data so it can be used during runtime RTPSO validation (all shaders in the RTPSO need the same RHIShaderResourceTable)
- Renamed pRootSignaure member to RootSignature (style guide)

#jira UE-212347

[CL 33624453 by kenzo terelst in ue5-main branch]
2024-05-14 04:49:23 -04:00
jack cai
c1f56dace8 [Compute Framework] added newline before kernel includes to avoid preprocessor failing to process those includes if a data interface's shader file does not end with an extra empty line
[CL 32798372 by jack cai in ue5-main branch]
2024-04-08 13:43:49 -04:00
kenzo terelst
f1c87d59e6 Add ShouldPrecachePermutation to FShaderType to check if shader permutation needs PSO precaching on startup - by default ShouldCompilePermutation is used
EShaderPermutationPrecacheRequest is returned to define if a permutation is required, not required or development only. Only required PSOs are precached.
DevelopmentOnly should be used for debug permutations and won't trigger an ensure when permutation is used at runtime which isn't requested for precaching.
Validation also runs in editor builds.

#rb christopher.waters

[CL 32297715 by kenzo terelst in ue5-main branch]
2024-03-18 07:49:34 -04:00
jack cai
84381e970c [Compute Graph] Additional fix to generated function shim hlsl when the Function Implementation has fewer input param than the wrap function
#jira UE-209301
#rb Jeremy.Moore

[CL 32134780 by jack cai in ue5-main branch]
2024-03-08 17:38:27 -05:00
jack cai
2ff63aa55f [Compute Framework] fix incorrect parameter indexing in function shim hlsl for data interface function with a return value.
#jira UE-209301
#rb Jeremy.Moore

[CL 32128573 by jack cai in ue5-main branch]
2024-03-08 14:53:42 -05:00
jack cai
3eb861f699 [Compute Framework & Deformer Graph] fix incorrect function shim shader code generated when a paramter pin connects to a resource pin, the index arugment should be ignored
#jira UE-208855
#rb Jeremy.Moore

[CL 32119353 by jack cai in ue5-main branch]
2024-03-08 10:09:36 -05:00
bob tellez
b9a0ee14a3 [Backout] - CL31423450
[FYI] dan.elksnitis
Original CL Desc
-----------------------------------------------------------------
[shaders]
- store shadertype associations for each shader in a shadermap in the editor only data
- output a debug artifact containing per-shadertype permutation/memory stats; note that this is not directly representative of final shader memory usage since it doesn't account for shader library deduplication or shader library chunk re-duplication; it is only intended to be used as a tool for tracking/identifying shader growth due to added/modified shadertypes
- remove the old "dumpshadercodestats" path from the shader library, as well as the stats tracking "unique" shaders and shader memory; the former is no longer used and the latter does not correctly account for library chunking
- bump shader version due to shadermap editoronly data change

#rb Arciel.Rekman

[CL 31780302 by bob tellez in ue5-main branch]
2024-02-23 17:25:34 -05:00
jeremy moore
ce8dde9313 Fix compute graph Abort skipping enqueued items, leading to potential crashes when stale items are left in the invocation array.
Also changed use of RemoveAtSwap() to RemoveAt() so that ordering of enqueued items is respected when executing.
#rb henry.falconer
#jira UE-207601, FORT-684813

[CL 31737927 by jeremy moore in ue5-main branch]
2024-02-22 17:36:10 -05:00
steve robb
f8d47335a4 Replaced RemoveAt(N, 1, EAllowShrinking::*) with RemoveAt(N, EAllowShrinking::*).
[CL 31626444 by steve robb in ue5-main branch]
2024-02-19 16:51:58 -05:00
dan elksnitis
6f11179f09 [shaders]
- store shadertype associations for each shader in a shadermap in the editor only data
- output a debug artifact containing per-shadertype permutation/memory stats; note that this is not directly representative of final shader memory usage since it doesn't account for shader library deduplication or shader library chunk re-duplication; it is only intended to be used as a tool for tracking/identifying shader growth due to added/modified shadertypes
- remove the old "dumpshadercodestats" path from the shader library, as well as the stats tracking "unique" shaders and shader memory; the former is no longer used and the latter does not correctly account for library chunking
- bump shader version due to shadermap editoronly data change

#rb Arciel.Rekman

[CL 31423534 by dan elksnitis in ue5-main branch]
2024-02-13 09:09:37 -05:00
bob tellez
bb4b933b0b [Backout] - CL30979008
#fyi bob.tellez
Original CL Desc
-----------------------------------------------------------------
[Backout] - CL30976715
#fyi Luke.Thatcher
Original CL Desc
-----------------------------------------------------------------
Remove "r.RecompileRenderer", STORE_ONLY_ACTIVE_SHADERMAPS, and all associated dead code paths that are no longer used.
 - r.RecompileRenderer has been broken since at least August 2019 when CL 8231930 disabled the implementation of BackupGlobalShaderMap etc
 - STORE_ONLY_ACTIVE_SHADERMAPS was disabled in 14363137 (September 2020) to resolve FORT-312158 (enabling the new loader). Fortnite was the only user of this code path.
 - This is a delete-only change.

#jira UE-167133
#rb Arciel.Rekman, Jason.Nadro

[CL 30987478 by bob tellez in ue5-main branch]
2024-01-29 23:48:09 -05:00
bob tellez
9abacf237b [Backout] - CL30976715
#fyi Luke.Thatcher
Original CL Desc
-----------------------------------------------------------------
Remove "r.RecompileRenderer", STORE_ONLY_ACTIVE_SHADERMAPS, and all associated dead code paths that are no longer used.
 - r.RecompileRenderer has been broken since at least August 2019 when CL 8231930 disabled the implementation of BackupGlobalShaderMap etc
 - STORE_ONLY_ACTIVE_SHADERMAPS was disabled in 14363137 (September 2020) to resolve FORT-312158 (enabling the new loader). Fortnite was the only user of this code path.
 - This is a delete-only change.

#jira UE-167133
#rb Arciel.Rekman, Jason.Nadro

[CL 30979008 by bob tellez in ue5-main branch]
2024-01-29 17:22:09 -05:00
Luke Thatcher
4eb84944ad Remove "r.RecompileRenderer", STORE_ONLY_ACTIVE_SHADERMAPS, and all associated dead code paths that are no longer used.
- r.RecompileRenderer has been broken since at least August 2019 when CL 8231930 disabled the implementation of BackupGlobalShaderMap etc
 - STORE_ONLY_ACTIVE_SHADERMAPS was disabled in 14363137 (September 2020) to resolve FORT-312158 (enabling the new loader). Fortnite was the only user of this code path.
 - This is a delete-only change.

#jira UE-167133
#rb Arciel.Rekman, Jason.Nadro

[CL 30976715 by Luke Thatcher in ue5-main branch]
2024-01-29 15:42:08 -05:00
jack cai
a6b39830c0 [Deformer Graph] fix issues with uninitialized resources after compilation.
#rnx

[CL 30852464 by jack cai in ue5-main branch]
2024-01-24 13:15:26 -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
marc audy
108a901160 Fix V1078 warnings
[CL 30583619 by marc audy in ue5-main branch]
2024-01-11 19:36:42 -05:00
christopher waters
e9661bc768 Preparing for dependency cleanup.
[CL 30244022 by christopher waters in ue5-main branch]
2023-12-11 13:55:22 -05:00
jack cai
a2405ce04a ComputeFramework: fixed a typo when serialzing kernel resource set
#rb jeremy.moore

[CL 29851153 by jack cai in ue5-main branch]
2023-11-20 16:34:45 -05:00
graham matuszewski
5416740e7b Fixing a crash that occurs when you add a ComputeGraphComponent to a Character. This was happening because DestroyRenderState_Concurrent was not calling Super
#jira UE-196447
#rb ben.hoffman

[CL 28463714 by graham matuszewski in ue5-main branch]
2023-10-04 13:25:12 -04:00
ionut matasaru
57769f8235 Fixed usage of TRACE_CPUPROFILER_EVENT_SCOPE macros in engine plugins.
* TRACE_CPUPROFILER_EVENT_SCOPE(ScopeName) --> to be used with a plain text as scope name (not a string!). If the parameter is a string ("abc" or TEXT("abc")), the quotes (and the TEXT prefix) will be included in the actual timer name.
* TRACE_CPUPROFILER_EVENT_SCOPE_STR("scope name") --> to be used with a static string (const ANSICHAR* or const TCHAR*); ex: when the scope name needs to include a space char
* TRACE_CPUPROFILER_EVENT_SCOPE_TEXT(*MyScopeName) --> to be used with a dynamic string (const ANSICHAR* or const TCHAR*)
See also the comments for these macros in ProfilingDebugging\CpuProfilerTrace.h.

#rb Catalin.Dragoiu

[CL 28337738 by ionut matasaru in ue5-main branch]
2023-09-29 04:29:47 -04:00
zach bethel
6473b91df9 Hardened thread safety of render command pipe system and added ability to sync specific pipes.
- Added additional sync scopes to handle VT standalone path.

#jira UE-194136, FORT-648678, UE-194553, PLAY-12828

[CL 27691097 by zach bethel in ue5-main branch]
2023-09-07 17:51:23 -04:00