IsActionGraph() is complicated: recursively evaluating a graph, modifying data at each node (ActionHistory.UpdateProducingAttributes) making it easy to introduce hard-to-see race conditions, and difficult to optimize.
This change splits the function into two parts:
IsIndividualActionOutdated(): finds nodes that are out of date, based on the node's own data - able to be run in parallel, with less cross-thread contention.
IsActionOutdatedDueToPrerequisites(): recursively traverse the graph, to determine if an action is out of date based on its prerequisites. Does not run in parallel, but is fast (processes ~6000 actions in 2-3ms).
For a clean, simple project editor build, total runtime is <100ms, compared to ~150ms previously.
#jira none
#fyi ben.marsh
[CL 17553054 by jonathan adamczewski in ue5-main branch]
Can be used to reduce the number of build actions that will be run in parallel by ParallelExecutor or TaskExecutor.
Example use, in MyProject.Target.cs:
public class MyProjectTarget : TargetRules
{
public MyProjectTarget(TargetInfo Target) : base(Target)
{
Type = TargetType.Game;
DefaultBuildSettings = BuildSettingsVersion.V2;
ExtraModuleNames.AddRange( new string[] { "MyProject" } );
MemoryPerActionGB = 4;
}
}
#jira none
[CL 17546182 by jonathan adamczewski in ue5-main branch]
This adds support for running Editor in BuildGraph Command and Commandlet tasks where the Project at hand has it's own BuildEnvironment.
#jira none
#rb ben.marsh
#preflight 6143be8d9bba9a0001dfc9ee
[CL 17546102 by geoff evans in ue5-main branch]
#fyi Joe.Kirchoff
Original CL Desc
-----------------------------------------------------------------
ProjectGeneration: Don't filter out engine by default for -game
#jira UE-122365
#rb none
#rnx
[CL 17543744 by joe kirchoff in ue5-main branch]