Commit Graph

3340 Commits

Author SHA1 Message Date
Martin Ridgers
e9e06de7cb Put a workaround in place for a limitation when using memory tracing with other systems, who may allocate memory while writing fields of events they trace. Havoc ensues.
#rb jt
#rnx

[CL 16247685 by Martin Ridgers in ue5-main branch]
2021-05-10 09:16:33 -04:00
Jamie Dale
b2714a5f29 Fixed FMemberReference::ResolveMember failing to resolve fields from a parent interface
This was due to TFieldIterator skipping interfaces by default, which is what the various FindField/Property functions use internally.

This change also cleans-up TFieldIterator so that you can control its behavior with a single flags value (rather than 3), via a new constructor that takes a EFieldIterationFlags value (now the default constructor), with the older-style EFieldIteratorFlags values being proxied from the older multi-parameter constructor.

#preflight 60947bffc6c42e0001298c56
#rb Marc.Audy

[CL 16238110 by Jamie Dale in ue5-main branch]
2021-05-07 11:17:07 -04:00
Matt Peters
804a5c489d Add PreObjectSaveContext to OnObjectSaved delegate. Use the information to skip the recalculate of Actor descriptions when making an EditorDomainSave; this was causing dangling pointers since EditorDomainSaves can occur during a load.
#rb Francis.Hurteau, Jean-Francois.Dube
#rnx

[CL 16225862 by Matt Peters in ue5-main branch]
2021-05-06 16:45:52 -04:00
Andrew Davidson
3ddc3a4da3 Merge up from //UE5/Dev-LargeWorldCoordinates
#rb none

[CL 16211417 by Andrew Davidson in ue5-main branch]
2021-05-05 15:07:25 -04:00
Matt Peters
988f40e081 FUnversionedStructSchema: fix Address Sanitzer's warning about calling delete on a pointer that was not allocated with new.
#rb Johan.Torp
#rnx

[CL 16206906 by Matt Peters in ue5-main branch]
2021-05-05 10:03:10 -04:00
JeanFrancois Dube
e9b4ddd759 Add support for objects that changed class in LinkerLoad.
- With external actors, it is now possible for an actor to change class and be saved without it's referencer objects to be resaved.
- That was impossible to happen in standard levels, as you would have resaved the level and all possible referencers were resaved at the same time.
- To fix that, change how exports are hashed in the linker, to be able to resolve imports solely by name (removed the class and class package filters).
- Object properties will properly filter incompatible objects based on their expected class.

#jira none
#rb francis.hurteau
#preflight 60919d1f90631e0001dc3f0f

[CL 16205807 by JeanFrancois Dube in ue5-main branch]
2021-05-05 07:49:48 -04:00
Matt Peters
358cc205fd #jira FORT-370001 Speculatively disable IsPossiblyAllocatedUObjectPointer; it might be producing false positive errors on valid pointers.
#rb None (Slack discussion with Steve Robb and others)
#rnx

#ushell-cherrypick of 16202495 by Matt.Peters

[CL 16202707 by Matt Peters in ue5-main branch]
2021-05-04 23:31:34 -04:00
Matt Peters
230a874f39 Fix AssetRegistry error "UpdateAssetData called with a change in ObjectPath" when cooking a package and moving an actor asset out of the external package into the main package.
#rb Francis.Hurteau
#rnx

[CL 16193905 by Matt Peters in ue5-main branch]
2021-05-04 10:57:11 -04:00
Matt Peters
99b03f82ae GetSchemaHash: Fix buildbreak with programs that have WITH_EDITOR_DATA but not CACHE_UNVERSIONED_PROPERTY_SCHEMA.
#rb None, trivial
#fyi Johan.Torp
#rnx

[CL 16192085 by Matt Peters in ue5-main branch]
2021-05-04 08:00:09 -04:00
Matt Peters
6935c29d01 Create function UStruct::GetSchemaHash. This function provides a hash that can be used to check whether tagged property serialization stored in a saved package is a match for the current binary's UClasses. This hash can be used to test whether versioned tagged property serialization will produce unchanged results, and whether unversioned property serialization will succeed.
#rb Johan.Torp
#rnx

[CL 16186852 by Matt Peters in ue5-main branch]
2021-05-03 16:54:05 -04:00
paul chipchase
71b969d9c4 Cherrypicking Mirage code base (disabled) from Dev-Cooker
- The mirage specific code is disabled behind the define UE_USE_VIRTUALBULKDATA, this means that some code paths in Texture/Mesh are much more complex than they need to be as we support both old and new paths. Once the system has been turned on and confirmed to cause no issues then this will be stripped out.
- SavePackageUtilities.cpp, SavePackage.cpp and SavePackage2.cpp are editgrates rather than integrations as those files have changes in DevCooker that we don't want to bring over immediately.
- Also includes a prototype system for storing bulkdata in a sidecar file in the workspace domain rather than in the .uasset/.umap file which although has been discontinued as part of mirage, will have applications for future work for non-virtualized projects and/or text based assets.

#rb Patrick.Finegan (all changes have been reviewed when submitted to Dev-Cooker)
#tests Cooking and running ShooterGame/Frosty and other sample programs using megascan assets
#rnx
#preflight  608be50d870cf400013ff99d

[CL 16167285 by paul chipchase in ue5-main branch]
2021-04-30 08:14:54 -04:00
aurel cordonnier
50944fd712 Merge UE5/RES @ 16162155 to UE5/Main
This represents UE4/Main @ 16130047 and Dev-PerfTest @ 16126156

[CL 16163576 by aurel cordonnier in ue5-main branch]
2021-04-29 19:32:06 -04:00
Francis Hurteau
0ea177a8fc Re-enable Save2 in editor now that reported problems and issues are fixed
#rb trivial
#fyi Matt.Peters

[CL 16148696 by Francis Hurteau in ue5-main branch]
2021-04-28 16:52:52 -04:00
Matt Peters
c917563040 EditorDomain - Add in-process save, enable asynchronous EditorDomain loading, and add some cleanup for EditorDomainSave.
#rb Zousar.Shaker
#rnx

[CL 16145373 by Matt Peters in ue5-main branch]
2021-04-28 12:34:08 -04:00
Francis Hurteau
23fbb14332 Disable Save2 in editor temporarily until recent reported problems are confirmed fixed.
#rb trivial
#fyi Matt.Peters

[CL 16143597 by Francis Hurteau in ue5-main branch]
2021-04-28 10:31:18 -04:00
PJ Kack
6d27dd246d Clang compile fix for 15735615 to avoid deprecation warning for FPackageFileSummary::Guid in implicit constructors
#jira none
#rb none
#rnx

#ROBOMERGE-OWNER: pj.kack
#ROBOMERGE-AUTHOR: pj.kack
#ROBOMERGE-SOURCE: CL 16139414 in //UE4/Release-4.27/... via CL 16139466
#ROBOMERGE-BOT: STARSHIP (Main -> Release-Engine-Staging) (v789-15992632)

#ushell-cherrypick of 16142572 by pj.kack
#preflight 60895997f1a052000177199d

[CL 16143405 by PJ Kack in ue5-main branch]
2021-04-28 10:17:05 -04:00
Johan Torp
e21134f375 Optimize asset registry UpdateTemporaryCaches()
Saves 100ms in Engine::Init() w/o UAssetManager::Push/PopBulkScanning optimization and 35ms with it, measured on Gen5 for an internal project.

#rb matt.peters

[CL 16142419 by Johan Torp in ue5-main branch]
2021-04-28 07:53:44 -04:00
Marc Audy
3cfedaade8 Fix PVS warning V502 when comparing against NAME_None in a trinary
[CL 16137741 by Marc Audy in ue5-main branch]
2021-04-28 01:58:36 -04:00
Francis Hurteau
7cca09843e Add a way to set an output device to record error during linker save serialization
Error out when there is an error on the linker save during export serialization
LinkerSave will now set an error on the archive when a name is unable to be mapped and during serialization
Still run save cleanup for a package if errors are encountered

#rb Matt.Peters
#jira FROST-2374
#preflight 608882a038dfe40001edf3dd

[CL 16133989 by Francis Hurteau in ue5-main branch]
2021-04-27 18:25:03 -04:00
Jamie Dale
4afb7ce6bb Made EName an enum class to prevent implicit conversion to int
The following code would call the int overload rather than the name overload when passed an EName constant, which could easily lead to confusion and bugs:
    using FMyId = uint8;
    void DoThing(FName);
    void DoThing(FMyId);
    DoThing(NAME_Actor);

The change to use enum class requires that any code that actually deals with EName as an int (mostly internal name code and serialisation) be updated to explicitly cast, but prevents the implicit conversion that causes the issue above.

In order to preserve the NAME_X aliases that the old-style enum added to the global scope, new aliases have been added that point to the EName scoped versions. Unfortunately these can cause shadowing warnings if NAME_X is defined in the local scope, as the old-style enum used to allow that without shadowing, however there is no way to prevent this so we'll just need to fix any warnings that occur.

#rb Johan.Torp
#preflight 6087e06349a9840001414708

[CL 16126708 by Jamie Dale in ue5-main branch]
2021-04-27 10:11:18 -04:00
Matt Peters
c6e158a201 Reduce FName memory usage when saving thumbnails.
#rb Danny.Couture
#rnx

[CL 16123199 by Matt Peters in ue5-main branch]
2021-04-27 07:55:56 -04:00
Tim Smith
8b9fd4e009 Fixing ClassPrivate nullptr deref bug
#rb trivial
#rnx

[CL 16119070 by Tim Smith in ue5-main branch]
2021-04-26 17:31:30 -04:00
Tim Smith
5fb833c5c1 Added support for more arbitrary property changes to live coding.
1) Changed the pre/post compile notifications from module notifications to process commands.
2) Added server command to notify that we want re-instance patching (two phase)
3) Added support for two phase patching to enable re-instancing without all the limitations.
4) Added a null CDO check for old blueprint classes (approved by Phillip)

#rb ben.marsh
#rnx
#preflight 6086e3481046fb000183c2d4

[CL 16115620 by Tim Smith in ue5-main branch]
2021-04-26 12:49:25 -04:00
Matt Peters
384daee94f Fix SavePackage ensure that can occur if there is an Asset object in a package that is not the primary Asset and is not standalone.
#rb Francis.Hurteau
#rnx

[CL 16113956 by Matt Peters in ue5-main branch]
2021-04-26 10:12:58 -04:00
Marc Audy
38cdce1b97 Reenable ability to override native class from blueprint
Added a config variable to allow it to be turned off, but it will default to on.
#rb Phillip.Kavan

[CL 16095004 by Marc Audy in ue5-main branch]
2021-04-22 13:00:25 -04:00