7#ifndef PXR_EXEC_VDF_SCHEDULER_H
8#define PXR_EXEC_VDF_SCHEDULER_H
14#include "pxr/exec/vdf/api.h"
17PXR_NAMESPACE_OPEN_SCOPE
20using VdfMaskedOutputVector = std::vector<VdfMaskedOutput>;
26class VdfScheduleOutput;
39 std::pair<VdfPoolChainIndex, const VdfOutput *>
50 bool topologicallySort);
78 const VdfRequest &request,
80 PoolPriorityVector *poolOutputs);
94 const VdfRequest &request,
108 const VdfRequest &request,
110 const PoolPriorityVector &sortedPoolOutputs);
118 const PoolPriorityVector &sortedPoolOutputs);
126 const PoolPriorityVector &sortedPoolOutputs);
138 const VdfRequest &request,
140 const PoolPriorityVector &sortedPoolOutputs);
183PXR_NAMESPACE_CLOSE_SCOPE
Class to hold on to an externally owned output and a mask.
A VdfNetwork is a collection of VdfNodes and their connections.
This is the base class for all nodes in a VdfNetwork.
A VdfOutput represents an output on a node.
Contains a specification of how to execute a particular VdfNetwork.
This class contains scheduling information necessary to run a single VdfNode.
Used to make a VdfSchedule.
static VDF_API void _InitializeRequestMasks(const VdfRequest &request, VdfSchedule *schedule, PoolPriorityVector *poolOutputs)
Initializes the request masks for all the outputs that will be computed as a result of request.
static VDF_API void _MarkSmallSchedule(VdfSchedule *schedule)
Marks the schedule as small if it is indeed small.
static VDF_API void _ApplyAffectsMasks(VdfSchedule *schedule)
Applies the affects mask to the schedule.
static VDF_API void _ScheduleBufferPasses(const VdfRequest &request, VdfSchedule *schedule)
Method to schedule the buffer passes and the "keep" masks for the scheduled nodes.
static VDF_API void _SetScheduleValid(VdfSchedule *schedule, const VdfNetwork *network)
Method to signal that a schedule is done being built and that it is now valid for the given network.
static VDF_API void Schedule(const VdfRequest &request, VdfSchedule *schedule, bool topologicallySort)
Generates a schedule.
static VDF_API void _UpdateLockMaskForNode(VdfSchedule *schedule, VdfScheduleNode *node)
Updates schedule for node if the lock mask changed.
static VDF_API void _ScheduleForPassThroughs(const VdfRequest &request, VdfSchedule *schedule, const PoolPriorityVector &sortedPoolOutputs)
Schedule the outputs from which buffers should be passed.
static VDF_API void _ComputeLockMasks(const VdfRequest &request, VdfSchedule *schedule, const PoolPriorityVector &sortedPoolOutputs)
Setup the lock masks require for sparse mung buffer locking for all the outputs in the pool chain.
static VDF_API bool _ApplyAffectsMasksForNode(VdfScheduleNode *node)
Applies the affects masks to the scheduled node.
static VDF_API void _UpdateAffectsMaskForInvocation(VdfSchedule *schedule, VdfScheduleNode *node)
Updates the affects mask on an existing scheduled node invocation.
static VDF_API bool _UpdateAffectsMasksForNode(VdfSchedule *schedule, VdfScheduleNode *node)
Updates schedule for node if affects mask changed.
static VDF_API void _ScheduleTaskGraph(VdfSchedule *schedule, const PoolPriorityVector &sortedPoolOutputs)
Schedule the task graph for multi-threaded munging.
static VDF_API bool UpdateAffectsMaskForOutput(VdfSchedule *schedule, const VdfOutput &output)
Update schedule after the affects mask changed on output.
static VDF_API void _GenerateTasks(VdfSchedule *schedule, const PoolPriorityVector &sortedPoolOutputs)
Generate tasks for the scheduled task graph.
TfHashMap< const VdfNode *, VdfMaskedOutputVector, TfHash > NodeToRequestMap
A map from VdfNode * to VdfMaskedOutputVector.