Commit Graph

1701 Commits

Author SHA1 Message Date
Matt Peters
07a0af0f5b BulkDataRegistry
Updating FVirtualizedUntypedBulkData and textures to use the BulkDataRegistry.
BulkDataRegistry: Add get/put accessors for the cached BulkDataList of packages.
EditorDomain: Move ClassDigests into a global variable that can be shared with BulkDataRegistry.
EditorDomain: Improve performance of GetFileSize by fetching metadata only.
Tickable Cook Objects, for systems used by the cooker that need to be ticked.
Implementation of the the BulkDataRegistry that uses the DDC cache for persistent storage of the BulkDataList.

#rb Devin.Doucette, Paul.Chipchase, Zousar.Shaker

[CL 16768772 by Matt Peters in ue5-main branch]
2021-06-24 00:50:53 -04:00
aurel cordonnier
d17d20ca36 Merge from Release-Engine-Test @ 16758890 to UE5/Main
This represents UE4/Main @ 16738161 and Dev-PerfTest @ 16737719 (and Release-17.00 @ 16658211)

[CL 16763350 by aurel cordonnier in ue5-main branch]
2021-06-23 17:51:32 -04:00
PJ Kack
93ab2dcb43 GarbageCollection: Improve GC reachability analysis wall time by letting the GT do work using a ParallelFor instead of waiting.
#jira UE-116567
#rb danny.couture
#rnx

[CL 16755950 by PJ Kack in ue5-main branch]
2021-06-23 08:53:57 -04:00
danny couture
0c5673e3f3 Optimize the ddc fill job
- Avoid redundant iterations and processing of UPackages by implementing a listener instead
  - Process many packages asynchronously (not just one) by keeping them in memory longer and finishing them later
  - Make the ddc fill job wait for async tasks properly
  - Fix texture always being single threaded by allowing async at all time for ddc fill jobs
  - Avoid calling IsCachedCookedPlatformDataLoaded too often on objects still being compiled
  - Use a more sensible max memory usage in WorldPartitionHelpers to avoid calling the GC too often

  - 30m16s to 7m44s when running -run=DerivedDataCache -fill -map=P_Construct_WP -mapsonly -projectonly with hot cache
  - 2h30m to 1h11s when running -run=DerivedDataCache -fill -map=P_Construct_WP -mapsonly -projectonly with cold cache

#rb Zousar.Shaker, Devin.Doucette
#preflight 60d1fd5571002f0001b8880e

[CL 16745009 by danny couture in ue5-main branch]
2021-06-22 12:50:20 -04:00
paul chipchase
1178d572e0 Remove UE_USE_VIRTUALBULKDATA and the associated code path, there is now no easy way to revert back to old bulkdata format for StaticMesh/Textures.
#rb Danny.Couture
#rnx
#preflight 60d0386978c3b00001d06c06

* Macro removal
- UE_USE_VIRTUALBULKDATA: Asssumed to be 1.
- UE_VBD_TO_OLD_BULKDATA_PATH: Assumed to be 0 and code paths entirely deleted.
- UE_VBD_CONST: Assumed to be'const'
- Now that these macros are no longer in use some includes of VirtualizationManager.h can be removed (or moved to the cpp).

*VirtualizedBulkData
- No longer need need to include VirtualizationManager.h in the bulkdata header file so that is moved to the cpp.
- Removed ::GetBulkDataSize which was only added to keep compatibility to older code paths. This method has not yet been released publicly(it's not in EA) so we don't need to worry that anyone is actually using it.
- Add a new method ::HasPayloadData that allows the caller to poll if the payload exists and if it has a valid data length rather than calling ::GetPayloadSize (I'd like to move away from the need for calling code to know how large the payload is until the payload is actually pulled as it will make eventual thread safety code easier to do in the future).
- Added a method ::SetCompressionFormat that allows the compression format to be changed. Normally this should only be done when ::UpdatePayload is called but we need a way to fix old textures that were saved with the wrong compression flags for a time and to do that we need to be able to 'reset' the compression format in some cases. The method is documented to try and make it clear that this is not really intended for general use. At some point in the future if the engine mandates that packages be resaved to a specific version we can look into deprecating this call.

*StaticMeshSourceData
- MESHDATAKEY_STATICMESH_DERIVEDDATA_VER is currently 1 character shorter than it should be, but that doesn't seem worth changing the key to fix.

*Texture
- When accessing data from IImageWrapper we can take the data pointer directly from the TArray and give it's ownership to the FSharedBuffer being returned rather than cloning it.
- Deprecated FTextureSource::LoadBulkDataWithFileReader as with VBD it will always return true.
- FMipAllocation cannot yet be deleted as it is still required for Lock/Unlock but we can remove the support for old style FByteBulkData for now. There is further clean up work to be done here but we would have to make bigger changes to the FTextureSource api.
- FMipData can now store the data in FSharedBuffer format. In the future we can allow people to access mips via views rather than always taking copies to reduce unnecessary data transfer. This also eliminates the need to pass in a lock.
- FTextureSource::InitLayered still supports the parameter 'NewData' potentially being nullptr (in which case we set the texture data to uninitialized memory) this is another candidate for a future code clean up.
- Added a ::HasPayloadData to use instead of ::GetSizeOnDisk as in many cases the calling code is only interested if there is data at all and not what the exact size is.

* Testing
- Ran benchmarks before/after for cold cooks of an internal project showing overall cook times going from 1:54:28 down to 1:49:36 on average.

[CL 16727381 by paul chipchase in ue5-main branch]
2021-06-21 08:53:20 -04:00
Per Larsson
03c092dbba Fix non unity Crash reporter compile error
#rb none
#rnx

[CL 16725383 by Per Larsson in ue5-main branch]
2021-06-21 03:37:23 -04:00
Per Larsson
c3b3499a99 Remove dependency to CookOnTheFly module from CoreUObject and Launch when compiling programs
#rb Paul.Chipchase

[CL 16725292 by Per Larsson in ue5-main branch]
2021-06-21 02:42:49 -04:00
Matt Hoffman
afdbbebef0 Matinee: Misc cleanup (code comment changes, etc.)
#jira UE-105313
#rb Trivial
#preflight 60cb86666092ba00014e413d

[CL 16708963 by Matt Hoffman in ue5-main branch]
2021-06-17 14:56:54 -04:00
Zousar Shaker
cf116088ae Integrating //UE5/Dev-Cooker @ 16678003 to //UE5/Main (Zousar.Shaker-YEG-0943-Quaternary)
Non-DevIteration_ShooterGame

[CL 16678907 by Zousar Shaker in ue5-main branch]
2021-06-15 16:36:57 -04:00
Cody Albert
ab69b2a835 Exposed FInt32Interval to blueprints
#rb jamie.dale

[CL 16675762 by Cody Albert in ue5-main branch]
2021-06-15 13:21:53 -04:00
justin hare
eae9293bff Repair-style fix for issue where deferred dependency class placeholders could remain in blueprints after loading. This is seen in an example project with complicated circular dependencies intertwining many assets.
#rb phillip.kavan
#jira UE-112428

[CL 16660126 by justin hare in ue5-main branch]
2021-06-14 12:53:34 -04:00
ionut matasaru
6bfb55b3bd [Insights]
- Fixed tracing of UObject names and function names (UObject::CallFunction, FScopeCycleCounterUObject) when "stat named events" toggle is enabled (-statnamedevents, "stat NamedEvents" console command).
  - Added FCpuProfilerTrace::OutputBeginDynamicEvent(const FName), in addition to existing API that receives const ANSICHAR*  or const TCHAR*. It uses a separate DynamicFNameScopeNamesMap.

#rb Johan.Berg
#fyi Jeff.Farris

[CL 16657504 by ionut matasaru in ue5-main branch]
2021-06-14 08:51:02 -04:00
Matt Peters
7c9ccbd78d VirtualizedBulkData: Support serializing out references to legacy bulk data when saving to the editor domain, to avoid the disk space and cpu costs of upgrading it and saving a copy.
#rb Paul.Chipchase
#rnx

[CL 16657428 by Matt Peters in ue5-main branch]
2021-06-14 08:40:14 -04:00
Marc Audy
1d4ce4f57a Shrink FObjectImport
#rb Michael.Noland

[CL 16644166 by Marc Audy in ue5-main branch]
2021-06-11 13:49:31 -04:00
aurel cordonnier
e0ad4e25df Merge from Release-Engine-Test @ 16624776 to UE5/Main
This represents UE4/Main @ 16579691 and Dev-PerfTest @ 16579576

[CL 16625248 by aurel cordonnier in ue5-main branch]
2021-06-10 13:13:24 -04:00
CarlMagnus Nordin
f21e594dd0 Added support for storing shaders in iostore.
Opt-In with core setting AllowShadersInIoStore
#review-16450322

[CL 16622428 by CarlMagnus Nordin in ue5-main branch]
2021-06-10 09:29:05 -04:00
Johan Torp
58695040f5 Removed superfluous include in preparation for iterating on that header
#rb trivial
#preflight 60c1c1511ab0310001a7d633

[CL 16619938 by Johan Torp in ue5-main branch]
2021-06-10 04:27:26 -04:00
Tim Smith
c21dd493c5 Fixed global delegate functions to support changes when doing live coding.
Fixed issue where changing a function signature in an interface wouldn't update nodes in a blueprint.
Changed the API of the deferred registry to be more inline with UE coding standards.

#rb ben.marsh phillip.kavan
#rnx
#jira UE-113662
#preflight 60c0c0fdc61264000190e16a

[CL 16606206 by Tim Smith in ue5-main branch]
2021-06-09 11:42:43 -04:00
PJ Kack
e7c06e9e13 Add trace scopes for garbage collection and memory trim
#rb carlmagnus.nordin
#jira none
#rnx

[CL 16567410 by PJ Kack in ue5-main branch]
2021-06-07 03:14:13 -04:00
Matt Peters
b2660eae6b EditorDomain: Mark that package flag PKG_ReloadingForCooker is transient; it should not be saved to or loaded from the PackageFileSummary.
Add an enum value for transient package flags and clear them all on load from PackageFileSummary in addition to the current clearing on save, so that newly-marked transient flags that were previously saved out can still avoid being set when loading.

#rnx
#rb Francis.Hurteau

[CL 16547525 by Matt Peters in ue5-main branch]
2021-06-03 10:50:00 -04:00
paul chipchase
6958a4faa7 Add some basic profile data to Mirage to make it easier for people to see when payloads are being pushed to or pulled from the various backends.
#rb Per.Larsson
#rnx

* VirtualizationManager
- Add method ::IsEnabled which allows the caller to poll if content virtualization is enabled or not.
- Add method ::GetPayloadActivityInfo to return profiling data
- Added a new Profiling namespace containing all of the profiling code.
-- The idea is to try and keep all profiling data contained in the virtualization manager and not require the backends to be aware of it.
- The actual pull/push operations have been moved to new private methods ::TryPushDataToBackend and ::PullDataFromBackend, by limiting the scolpe of where the actual operation occur makes it easier to add the profiling code.
- We use the cooking stats system for recording our profiling data. Currently this adds no real value and we could've implemented our own but longer term this code might get hooked into FCookStatsManager:: CookStatsCallbacks to add it to our telemetry systems and this will be easier to do if it is already in the cooking stats formats.

* SVirtualizationStaticIndicator
- The widget is based on SDDCStatusIndicator for the DDC and is placed just before it in the UI.
- The widget will only be shown if the content virtualization system is enabled, so functions as an easy way to check that (maybe in the future it can be on all the time in which case we'd need the widget to reflect when the systems are disabled)
- Currently shows a green down arrow when a payload has been pulled and a green up arrow when a payload has been pushed.
- The tool tip shown on mouse over will show the total data sizes pulled and pushed from the backends.
#preflight 60b87c34ae46a100017d5334

[CL 16544645 by paul chipchase in ue5-main branch]
2021-06-03 04:35:17 -04:00
Francis Hurteau
87fd0a4157 Harvest soft object path package on save for cooker to handle save permutations such as the world partition grid cell split:
* Added a function to RedirectCollector to ingest soft package references
* Push the harevest soft package references from save to the redirect collector on a succesful save
* Moved the processing of soft package reference associated with a package during cook to after that package has been saved

#rb Matt.Peters
#jira UE-115137

[CL 16534223 by Francis Hurteau in ue5-main branch]
2021-06-02 10:28:45 -04:00
danny couture
d255f4532a Add GeneratedCppIncludes in PCH as it is one of the most included files from vcperf profile runs
Add missing CoreMinimal.h when compiling core
  - 251s -> 245s for QAGame Win64 Development with -NoXGE on AMD TR 3970X

#rb Ben.Marsh

[CL 16527504 by danny couture in ue5-main branch]
2021-06-01 21:34:02 -04:00
paul chipchase
99848fd49b Removed UE::Virtualization::IVirtualizedData from core now that there is no need for it.
#preflight 60b6432d6073fb00010d8e11

[CL 16514905 by paul chipchase in ue5-main branch]
2021-06-01 11:44:14 -04:00
aurel cordonnier
43fa62fcd8 Merge from Release-Engine-Test @ 16487383 to UE5/Main
This represents UE4/Main @ 16445039 and Dev-PerfTest @ 16444526

[CL 16488106 by aurel cordonnier in ue5-main branch]
2021-05-27 13:40:37 -04:00