Skip to main content

vyre_conform/
lib.rs

1#![deny(unsafe_code)]
2#![deny(missing_docs)]
3#![cfg_attr(not(test), deny(clippy::todo, clippy::unimplemented))]
4
5//! # vyre-conform — Conformance suite for the vyre GPU compute specification
6//!
7//! Maintainer-only harness. End users consume `vyre` + `vyre-reference` + a
8//! backend (e.g. `vyre-wgpu`). This crate proves that any vyre backend
9//! produces byte-identical output to the CPU reference for every operation,
10//! every input, every time.
11//!
12//! Public surface — exactly ten items:
13//!
14//! ```text
15//! certify, Certificate, Violation, VyreBackend, Finding, EnforceGate,
16//! Oracle, Archetype, MutationClass, {Category, AlgebraicLaw, OpSpec}
17//! ```
18//!
19//! Everything else is implementation detail.
20
21// ─── Public API (ten items) ────────────────────────────────────────────────
22
23pub use crate::enforce::EnforceGate;
24pub use crate::generate::archetypes::Archetype;
25pub use crate::pipeline::certify::certify;
26pub use crate::pipeline::certify::Certificate;
27pub use crate::pipeline::certify::Violation;
28pub use crate::proof::oracles::Oracle;
29pub use crate::spec::types::MutationClass;
30pub use crate::spec::types::OpSpec;
31pub use crate::spec::Finding;
32pub use vyre::VyreBackend;
33pub use vyre_spec::{AlgebraicLaw, Category};
34
35// ─── Internal module declarations ──────────────────────────────────────────
36
37pub(crate) mod adversarial;
38pub(crate) mod enforce;
39pub(crate) mod generate;
40pub(crate) mod meta;
41pub(crate) mod pipeline;
42pub(crate) mod proof;
43pub(crate) mod spec;
44pub(crate) mod verify;
45
46// ─── Internal-only re-exports (not part of the public 10-item API) ─────────
47// These make `crate::<Name>` resolve from anywhere inside the crate without
48// forcing every enforcer/pipeline file to spell the full `crate::spec::types::`
49// path. They are NOT `pub use` — they do not escape the crate.
50//
51// `DataType` stays here intentionally: conform code should use
52// `crate::DataType` as the single internal spelling for the canonical
53// `vyre_spec::DataType`. That avoids mixing the equivalent core IR path into
54// new conform code while preserving the existing crate-local imports.
55
56pub(crate) use crate::meta::contribute;
57pub(crate) use crate::pipeline::execution::InputCase;
58pub(crate) use crate::pipeline::reporter;
59pub(crate) use crate::spec::op_registry;
60pub(crate) use crate::spec::registry;
61pub(crate) use crate::spec::types::{
62    BufferAccess, ChainSpec, Convention, DataType, OpSignature, ParityFailure, Strictness,
63};
64pub(crate) use crate::verify::regression;