onnx-runtime-optimizer 0.1.0-dev.4

Device-independent graph→graph optimization passes for the ORT 2.0 runtime: dead-node elimination, bounded constant folding, and op fusion over onnx-runtime-ir
Documentation

onnx-runtime-optimizer

Device-independent graph→graph optimization passes for the ORT 2.0 runtime (see docs/ORT2.md §18 "Optimization Passes"). This is the first Phase-2 crate: pure, safe Rust graph rewriting over [onnx_runtime_ir] — no CUDA, no ORT C library, no FFI.

What lives here

Concept Type
Pass contract [OptimizationPass], [PassContext], [run_passes]
Dead-code removal [DeadNodeElimination]
Bounded constant folding [ConstantFolding]
Operator fusion [OpFusion], [FusionPattern], [PatternMatch]
Errors [OptimizerError], [Result]

Pipeline

[default_passes] returns only the device-independent passes implemented here, in pipeline order: ConstantFolding → DeadNodeElimination → OpFusion.

Deferred (Phase 2b / Phase 3)

The full pipeline in docs/ORT2.md §18.1 also lists passes that depend on crates or analyses not yet built. They are intentionally not implemented here and are listed in [default_passes]'s source in their eventual pipeline position: ShapeInference (the loader owns inference for now), AttentionFusionPass, LayoutPropagation, PlacementOptimizer, TransferInsertion, InPlaceDetection, MemoryPlanning, CudaGraphRegionDetection, and OverlapScheduling.