digraph ipu_stack_package_partition {
  graph [rankdir=LR, bgcolor="white", fontname="DejaVu Sans", fontsize=17,
         label="ipu_exchange::diagnostic — package build/run detail", labelloc=t, labeljust=l, pad=0.2, nodesep=0.3, ranksep=0.75, newrank=true, overlap=false, splines=polyline, outputorder=edgesfirst];
  node [fontname="DejaVu Sans", fontsize=9, style="rounded,filled", color="#52606d", penwidth=0.8];
  edge [fontname="DejaVu Sans", fontsize=7, color="#52606d", arrowsize=0.55, penwidth=0.8];
  subgraph cluster_primary { label="primary nodes"; color="#d8f0dd"; style="rounded";
    f3 [label="ipu_exchange::diagnostic::control_key", shape=box, fillcolor="#d8f0dd", color="#2166ac", tooltip="fn control_key(control: IncomingControl) -> (u8, u32) — crates/ipu-exchange/src/diagnostic.rs:409"];
    f1 [label="ipu_exchange::diagnostic::decode_operation", shape=box, fillcolor="#d8f0dd", color="#2166ac", tooltip="fn decode_operation( words: &[u32], offset: usize, ) -> Result<(PlanOperation, u32, usize), ExchangeError> — crates/ipu-exchange/src/diagnostic.rs:165"];
    f0 [label="ipu_exchange::diagnostic::diagnose_plan_program", shape=box, fillcolor="#d8f0dd", color="#2166ac", tooltip="/// Decodes one synchronization-free exchange row. `base_address` is optional /// because provisional rows do not have placement yet. pub fn diagnose_plan_program( words: &[u32], base_address: Option<u32>, ) -> Result<PlanProgramDiagnostic, ExchangeError> — crates/ipu-exchange/src/diagnostic.rs:127"];
    f2 [label="ipu_exchange::diagnostic::validate_tile_program", shape=box, fillcolor="#d8f0dd", color="#2166ac", tooltip="pub(super) fn validate_tile_program( tile: usize, schedule: &TileProgramSchedule, words: &[u32], ) -> Result<PlanProgramDiagnostic, ExchangeError> — crates/ipu-exchange/src/diagnostic.rs:286"];
    t4 [label="ipu_exchange::diagnostic::DecodedPlanInstruction\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:52"];
    t1 [label="ipu_exchange::diagnostic::IncomingControl\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:17"];
    t0 [label="ipu_exchange::diagnostic::IncomingControlStream\n«enum»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:11"];
    t3 [label="ipu_exchange::diagnostic::PlanOperation\n«enum»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:32"];
    t5 [label="ipu_exchange::diagnostic::PlanProgramDiagnostic\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:61"];
    t2 [label="ipu_exchange::diagnostic::SendEncoding\n«enum»", shape=ellipse, style="filled,dashed", fillcolor="#d8f0dd", color="#7b8794", tooltip="crates/ipu-exchange/src/diagnostic.rs:24"];
  }
  subgraph cluster_external { label="outgoing references — click to open target partition"; color="#d9d9d9"; style="rounded,dashed";
    xf0 [label="ipu_exchange::is_send_control", shape=box, fillcolor="#f5f5f5", color="#9aa5b1", style="rounded,filled,dashed", URL="ipu-exchange-part-1.svg", target="_top", tooltip="open target partition"];
    xf1 [label="ipu_exchange::is_send_control_pair", shape=box, fillcolor="#f5f5f5", color="#9aa5b1", style="rounded,filled,dashed", URL="ipu-exchange-part-1.svg", target="_top", tooltip="open target partition"];
    xf2 [label="ipu_exchange::is_send_off", shape=box, fillcolor="#f5f5f5", color="#9aa5b1", style="rounded,filled,dashed", URL="ipu-exchange-part-1.svg", target="_top", tooltip="open target partition"];
    xt0 [label="ipu_exchange::ExchangeError\n«enum»", shape=ellipse, fillcolor="#f5f5f5", color="#9aa5b1", style="filled,dashed", URL="ipu-exchange-part-2.svg", target="_top", tooltip="open defining partition"];
    xt2 [label="ipu_exchange::ReceiveEventKind\n«enum»", shape=ellipse, fillcolor="#f5f5f5", color="#9aa5b1", style="filled,dashed", URL="ipu-exchange-part-2.svg", target="_top", tooltip="open defining partition"];
    xt1 [label="ipu_exchange::TileProgramSchedule\n«struct»", shape=ellipse, fillcolor="#f5f5f5", color="#9aa5b1", style="filled,dashed", URL="ipu-exchange-part-2.svg", target="_top", tooltip="open defining partition"];
  }
  f0 -> f1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f0 -> t4 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f0 -> t5 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f0 -> xt0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f1 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f1 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f1 -> xf2 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f1 -> t0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f1 -> t1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f1 -> t2 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f1 -> t3 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f1 -> xt0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> f0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f2 -> f3 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f2 -> t0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> t1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> t3 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> t5 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> xt0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> xt1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> xt2 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f3 -> t0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f3 -> t1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  legend [shape=note, style="filled", fillcolor="#ffffff", color="#9aa5b1", fontsize=8,
          label="Solid: MIR-resolved call   Dotted: source fallback\nDashed, no arrow: uses type   Dashed node: link to another partition\nBlue: build   Green: run   Purple: shared"];
}
