class
SushiAI::Graph::CompiledStep
Manages the lowered and compiled execution plan for a graph.
- Declared in
include/SushiAI/graph/compiled_step.hpp
Public member functions
CompiledStep(SushiBLAS::Engine &engine, const Graph &graph, TensorPool &pool, IStepRecorder *trailing=nullptr, const IFusionSelector *selector=nullptr)Lowers graph, compiles it once, and arms it for execution.
Parameters
engineRecording engine; must outlive this step.
graphThe graph to lower.
poolMemory pool behind values; must outlive this step.
trailingOptional extra recorder for trailing replay work.
selectorFusion selector, or null for default.
CompiledStep(const CompiledStep &)=deleteCompiledStep & operator=(const CompiledStep &)=deleteCompiledStep(CompiledStep &&)=deleteCompiledStep & operator=(CompiledStep &&)=deletevoid run()Re-arms the plan, executes it, and waits for completion.
bool has_trailing_work() const noexceptWhether extra non-IR work was folded into this plan.
std::size_t compile_count() const noexceptHow many times this step has been compiled.
One, always, for the life of the object - that is the point. Exposed so a test can hold the guarantee to account.
std::size_t run_count() const noexceptHow many times run() has executed the plan.
bool empty() const noexceptWhether the graph lowered to no runnable work at all.
std::size_t operation_count() const noexceptHow many SushiBLAS calls the step is made of.
SushiRuntime::span< const FusionSelection > selections() const noexceptWhat the selector chose for each fused node; see Lowering.
SushiRuntime::Execution::CompiledGraph & plan() noexceptThe compiled plan, for profiling.
Exposed only so a caller can hand it to IExecutionEngine::reset_profiling / collect_profiling. Do not compile, rearm or execute it yourself.

