Vyre is an experimental whole-program GPU compiler and runtime for parsing, matching, graph, dataflow, and numerical workloads.
The production lifecycle is:
frontend Program(s)
-> validated ProgramGraph
-> vyre-megakernel Compiler
-> immutable Artifact + TargetPayload
-> driver admission and materialization
-> ArtifactInstance
-> typed Submission
-> completion and readback
Raw Program execution is reserved for the independent reference and
conformance paths. Production targets compile compiler-selected artifact modules
and admit authenticated payloads before submission.
cargo add vyreLink the concrete driver crate for each production target you ship:
cargo add vyre-driver-cuda
cargo add vyre-driver-wgpuA missing or incompatible target fails with a structured diagnostic. Vyre does not silently replace it with CPU execution.
use std::collections::BTreeMap;
use vyre::compiler::{compile, CompileRequest, Digest, ExternalFacts, SearchBudget};
use vyre::ir::{
BufferAccess, BufferDecl, DataType, Program, ProgramGraph, ShapeDim,
ValueContract, ValueLifetime,
};
let mut graph = ProgramGraph::new();
graph.add_external_value(
"out",
ValueContract {
dtype: DataType::U32,
shape: vec![ShapeDim::Known(1)],
access: BufferAccess::WriteOnly,
lifetime: ValueLifetime::Output,
},
)?;
graph.add_node(
"main",
Program::wrapped(
vec![BufferDecl::output("out", 0, DataType::U32).with_count(1)],
[1, 1, 1],
Vec::new(),
),
Vec::new(),
Vec::new(),
)?;
let request = CompileRequest::new(
graph,
ExternalFacts::new(Digest([0; 32]), BTreeMap::new()),
SearchBudget::new(1, 1, 1, 0, 1_000_000),
1_000_000,
)
.validate()?;
let artifact = compile(&request)?;
assert!(!artifact.to_bytes()?.is_empty());
# Ok::<(), Box<dyn std::error::Error>>(())Attach a payload through the selected registered target compiler. Construct an
ArtifactSession with the matching registered materializer, bind values through
BindingSet, submit, and wait for typed readback.
vyre-foundationowns semantic IR, validation, diagnostics, and optimization.vyre-megakernelowns whole-graph planning, artifact identity, canonical ABI, and target payload attachment.vyre-driverowns backend-neutral compiler, materializer, device, binding, submission, and completion contracts.- Concrete driver crates own target compilation, device acquisition, materialization, and native submission.
vyre-runtimeowns artifact sessions, recovery, persistence, residency, and readback.vyre-scanowns scan compilation, database framing, paging, residency, execution, and readback.vyre-aotpackages canonical artifacts without reconstructing them.vyre-conformcompares production artifact execution with the independent reference engine.
The machine-readable ownership source is
docs/CRATE_OWNERSHIP.toml.
Build the documentation book:
mdbook buildStart with docs/ARCHITECTURE.md. The documentation
manifest at docs/DOCS.toml classifies current, generated,
superseded, and archived pages.
Use the repository Cargo wrapper so builds remain bounded:
./cargo_full test -p vyre --test artifact_workflow
./cargo_full test -p vyre-conform --test production_route
python3 scripts/docs_manifest.py --checkGPU probe failures are configuration failures. GPU-required gates fail loudly when the required device or driver is unavailable.
MIT OR Apache-2.0.