flowG & TEI Fabric: Typed FunctionGraph IR and Cost-Surface Dispatch Across Physics Dialects

June 10, 2026 Wave II compiler and thermodynamic-fabric specifications uniting ~90 flowg-* Rust crates (dtype-explicit FunctionGraph IR) with TEI Fabric's 6 literature-anchored physics cost surfaces from 36 pJ/MAC CMOS to 1 fJ/sample p-bits.

Compiler graph lowering across digital GPU/AMX backends and post-CMOS physics dialects
Compiler graph lowering across digital GPU/AMX backends and post-CMOS physics dialects

Temporal & Archival Scope: Era 0 Historical Whitepaper (Originally dated June 10, 2026; verbatim historical summary followed below by dated November 25, 2026 Errata & Related Work Addendum) · Canonical OpenIE Chronicle Entry: https://blog.openie.dev/posts/wp-flowg-tei-fabric-physics-dispatch/

Provenance & Telemetry Hygiene: Signed Provenance · Self-Checked (automated OpenIE internal gates; not externally peer-reviewed) · Energy Class: est_j (measured_j ⊥ reported_j ⊥ est_j ⊥ unmetered — Verification, Licensing & AI-Use Disclosure · Glossary & Non-Mixing Rules).

Part I: Contemporary Historical Summary (As Written in June 2026)

Historical Source Provenance (Original Date: June 10, 2026): David Jean Charlot, PhD · Open Interface Engineering. Synthesizes the June 2026 flowG compiler IR whitepaper and TEI Fabric (Apache-2.0) cost-dialect specification (Public repositories: openIE-dev/flow-g and openIE-dev/tei-fabric).

Convergence: One Typed Graph IR for Languages, Models, and Cost Surfaces

By June 2026, OpenIE maintained three language frontends—lux-lang, math-oriented jmax-lang, and the ~15.5 kloc self-hosted bootstrap of joule-lang—alongside ONNX model pipelines (MobileNetV2, quantized BERT, and a 1.6 GB Stable Diffusion UNet). Maintaining separate lowering stacks for scalar control code and tensor graphs duplicated optimization passes and introduced marshaling overhead wherever application logic met matrix operations.

flowG (~90 modular flowg-* Rust 2024 crates) unified scalar and tensor lowering into a single capability-gated FunctionGraph DAG:

Frontends:  joule-lang (~15.5 kloc) · jmax-lang · lux-lang · Real ONNX (MobileNetV2, BERT, 1.6 GB SD UNet)
               │
               ▼
flowG `FunctionGraph` IR  (Nodes: `Apply` · `Literal` · `Param` · `CodeBlock` · `CapabilityRef`)
   • Object-capability isolation enforced at the VM boundary by `flowg-vm-cap` (no ambient IO/network authority)
   • Canonical dtype-explicit fused op names: `fused_<chain>_<f32|f16|bf16>` (bans implicit f16 -> f32 widening)
   • Two-method backend trait `OpDispatch`: `claims(op_name)` + `execute(graph_slice, buffers)`
               │
               ├──► Digital Silicon Backends : Apple Metal (runtime MSL) · MPS · Apple AMX (5-15 TFLOPS) ·
               │                               CUDA · BLAS · WGPU · WASM · Bit-Reference CPU
               └──► TEI Fabric Cost Simulator: 258 Periodic Primitives (33 families) -> 6 Physics Dialects

Two design rules in flowG targeted recurring runtime inefficiencies:

  1. Banning Silent Dtype Widening: Encoding wire precision directly into canonical operator identifiers (fused_<chain>_<f32|f16|bf16>) prevented backends from silently widening f16/bf16 intermediates to f32 across LayerNorm/SiLU fusions (which otherwise doubles memory traffic).
  2. Routing Small Dense Tiles to CPU-Coupled AMX: On Apple Silicon, dispatching sub-millisecond small-batch matrix tiles to Accelerate / AMX (5–15 TFLOPS) avoided Metal GPU command-buffer submission and wakeup overhead, reducing modeled per-op dispatch energy 23–55x relative to single-tile GPU kernel launch on tiny matrices (<= 128 x 128).

TEI Fabric: Simulating Real ONNX Graphs Across Six Physics Cost Dialects

Above digital CMOS execution, TEI Fabric (258 operator primitives across 33 families) ingested production ONNX graphs—including a 1.6 GB Stable Diffusion UNet—into a software cost-surface partitioner parameterized by published device-physics energy anchors:

The Boundary Conversion Finding: Array fJ vs. ADC/DAC Interface pJ

Partitioning the 1.6 GB Stable Diffusion UNet across heterogeneous dialects surfaced a sobering systems result: while an optical MZI array (~30 fJ/MAC) or RRAM crossbar (2–5 fJ/MAC) is 1,000–10,000x lower than digital CMOS (~36 pJ/MAC) inside the array core, analog-to-digital (ADC/DAC) and electrical-to-optical (E-O-E) conversion at subgraph boundaries consumes 1–50 pJ per converted sample—frequently exceeding the array-core savings by 10–100x unless large contiguous subgraphs remain inside one physical domain.


Methods, Simulator Scope & Licensing Box (est_j)

  1. Software Cost-Surface Simulation vs. Physical Post-CMOS Hardware (est_j): While flowG executed functional workloads on real digital backends (Metal, AMX/Accelerate, CUDA, WGPU, WASM, CPU), all five non-CMOS tei-d-* dialects (photonic, in-memory, stochastic, reversible, neuromorphic) are analytical cost-surface models (est_j) parameterized from peer-reviewed device papers, not physical photonic, RRAM, or sMTJ hardware owned or fabricated by OpenIE.
  2. Denominator Scope on the 23–55x AMX Dispatch Figure: The 23–55x modeled energy ratio compares CPU-resident AMX execution (denominator) against unbatched single-kernel Metal GPU command-queue wakeup and synchronization (numerator) on small sub-millisecond tiles; on large sustained matrix batches where GPU launch cost amortizes, discrete/integrated GPU shaders outperform CPU AMX throughput.
  3. Artifact & Licensing Status: Core graph IR and cost-surface crates are publicly available under Apache-2.0 at openIE-dev/flow-g and openIE-dev/tei-fabric (and joule-lang at openIE-dev/joule-lang); companion experimental language frontends (lux-lang, jmax-lang) remain internal repositories.

Chronological Evolution Within OpenIE Research

  1. Zero-ADC Digital Lookup on Commodity CMOS/FPGAs (Downward LUT6 Compilation & 64-Codon LUT6): Because TEI Fabric’s simulator showed that ADC/DAC conversion wipes out small-subgraph analog PIM gains, our late-2026 hardware experiments focused on purely digital zero-multiply LUT6 boolean and {-1, 0, +1} ternary operators, which stay inside standard CMOS/FPGA logic with zero ADC/DAC boundary tax (125–176 nJ inline DC board shunt measured_j on Jetson Thor).
  2. Metered Digital Substrate Profiling (Eco-Compute & The Eco-Stack): Carried flowG’s explicit precision naming and flowg-vm-cap capability isolation forward while anchoring digital backend comparisons on reported_j chip counters and measured_j shunts.

Changelog (2026-11-25)


Canonical Provenance, Primary Artifacts & Independent Replication