digraph ipu_stack_package_partition {
  graph [rankdir=LR, bgcolor="white", fontname="DejaVu Sans", fontsize=17,
         label="ipu_elf — 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="#eadcf8"; style="rounded";
    f4 [label="ipu_elf::KernelArtifact::inspect", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="pub fn inspect(&self) -> Result<ObjectSummary, ElfError> — crates/ipu-elf/src/lib.rs:216"];
    f0 [label="ipu_elf::Toolchain::cached_artifact", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn cached_artifact(&self, source: &Path, flags: &[String]) -> Result<KernelArtifact, ElfError> — crates/ipu-elf/src/lib.rs:141"];
    f14 [label="ipu_elf::Toolchain::compile", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="pub fn compile( &self, source: impl AsRef<Path>, name: &str, flags: &[String], ) -> Result<KernelArtifact, ElfError> — crates/ipu-elf/src/lib.rs:85"];
    f9 [label="ipu_elf::align", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn align(value: usize, alignment: usize) -> Result<usize, ElfError> — crates/ipu-elf/src/lib.rs:637"];
    f10 [label="ipu_elf::align_address", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn align_address(address: u32, alignment: usize) -> Result<u32, ElfError> — crates/ipu-elf/src/lib.rs:647"];
    f11 [label="ipu_elf::apply_relocation", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="pub fn apply_relocation( image: &mut [u8], offset: usize, relocation: u32, mut value: u64, image_base: u32, ) -> Result<(), ElfError> — crates/ipu-elf/src/lib.rs:652"];
    f2 [label="ipu_elf::hash_tool_identity", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn hash_tool_identity(digest: &mut Sha256, path: &Path) -> Result<(), ElfError> — crates/ipu-elf/src/lib.rs:184"];
    f5 [label="ipu_elf::inspect_object", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="pub fn inspect_object(bytes: &[u8]) -> Result<ObjectSummary, ElfError> — crates/ipu-elf/src/lib.rs:233"];
    f1 [label="ipu_elf::kernel_cache_root", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn kernel_cache_root() -> PathBuf — crates/ipu-elf/src/lib.rs:171"];
    f6 [label="ipu_elf::link", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="pub fn link(objects: &[Vec<u8>], options: &LinkOptions) -> Result<LinkedImage, ElfError> — crates/ipu-elf/src/lib.rs:321"];
    f8 [label="ipu_elf::placement", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn placement( placements: &[PlacedSection], object_index: usize, section_index: object::SectionIndex, ) -> Result<&PlacedSection, ElfError> — crates/ipu-elf/src/lib.rs:624"];
    f7 [label="ipu_elf::reachable_sections", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn reachable_sections( objects: &[object::File<'_>], root_symbols: &[&str], ) -> Result<HashSet<(usize, object::SectionIndex)>, ElfError> — crates/ipu-elf/src/lib.rs:568"];
    f12 [label="ipu_elf::read_u32", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn read_u32(image: &[u8], offset: usize) -> Result<u32, ElfError> — crates/ipu-elf/src/lib.rs:768"];
    f3 [label="ipu_elf::run", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn run(command: &mut Command, name: &str) -> Result<(), ElfError> — crates/ipu-elf/src/lib.rs:198"];
    f13 [label="ipu_elf::write", shape=box, fillcolor="#eadcf8", color="#2166ac", tooltip="fn write(image: &mut [u8], offset: usize, bytes: &[u8]) -> Result<(), ElfError> — crates/ipu-elf/src/lib.rs:777"];
    t6 [label="ipu_elf::ElfError\n«enum»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:56"];
    t0 [label="ipu_elf::KernelArtifact\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:209"];
    t2 [label="ipu_elf::LinkOptions\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:285"];
    t3 [label="ipu_elf::LinkedImage\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:298"];
    t4 [label="ipu_elf::LinkedSegment\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:307"];
    t1 [label="ipu_elf::ObjectSummary\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:226"];
    t5 [label="ipu_elf::PlacedSection\n«struct»", shape=ellipse, style="filled,dashed", fillcolor="#eadcf8", color="#7b8794", tooltip="crates/ipu-elf/src/lib.rs:314"];
  }
  subgraph cluster_external { label="outgoing references — click to open target partition"; color="#d9d9d9"; style="rounded,dashed";
    xf0 [label="ipu_codegen::low::format", shape=box, fillcolor="#f5f5f5", color="#9aa5b1", style="rounded,filled,dashed", URL="ipu-codegen-low-part-1.svg", target="_top", tooltip="open target partition"];
    xf1 [label="ipu_codegen::mid::format", shape=box, fillcolor="#f5f5f5", color="#9aa5b1", style="rounded,filled,dashed", URL="ipu-codegen-mid.svg", target="_top", tooltip="open target partition"];
  }
  f0 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f0 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f0 -> f1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f0 -> f2 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f0 -> t0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f0 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f2 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f3 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f3 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f3 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f4 -> f5 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f4 -> t1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f4 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f5 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f5 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f5 -> t1 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f5 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f6 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> f7 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> f8 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> f10 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> f11 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f6 -> t2 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f6 -> t3 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f6 -> t4 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f6 -> t5 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f6 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f7 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f7 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f7 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f8 -> t5 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f8 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f9 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f10 -> f9 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f10 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f11 -> xf0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f11 -> xf1 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f11 -> f12 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f11 -> f13 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f11 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f12 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f13 -> t6 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f14 -> f0 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f14 -> f3 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f14 -> f4 [color="#2166ac", style="solid", tooltip="rustc MIR call edge"];
  f14 -> t0 [style=dashed, color="#9aa5b1", arrowhead=none, constraint=false, tooltip="uses workspace type"];
  f14 -> t6 [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"];
}
