pub struct Env {Show 13 fields
pub commit_sha: String,
pub hw_id: String,
pub driver: Option<String>,
pub cuda: Option<String>,
pub rust: String,
pub ferrum_features: Vec<String>,
pub gpu_clock_lock_mhz: Option<u32>,
pub gpu_power_limit_w: Option<u32>,
pub gpu_persistence_mode: Option<bool>,
pub gpu_auto_boost: Option<bool>,
pub ferrum_env: BTreeMap<String, String>,
pub runtime_config: RuntimeConfigSnapshot,
pub vllm_args: Option<Vec<String>>,
}Expand description
Snapshot of everything we expect to affect bench outcomes.
BTreeMap (not HashMap) for ferrum_env so JSON serialization
is deterministic — required for env_hash reproducibility.
Fields§
§commit_sha: Stringferrum git commit short SHA.
hw_id: StringStable hardware identifier (e.g. rtx-4090, m1-max-32gb).
driver: Option<String>NVIDIA driver version (e.g. 555.42.06). Omitted on non-CUDA hosts.
cuda: Option<String>CUDA toolkit version (e.g. 12.4). Omitted on non-CUDA hosts.
rust: StringRust toolchain version (e.g. 1.78.0).
ferrum_features: Vec<String>Cargo features enabled on the ferrum build (sorted).
gpu_clock_lock_mhz: Option<u32>GPU clock lock value in MHz (nvidia-smi -lgc <mhz>,<mhz>).
gpu_power_limit_w: Option<u32>Power limit in watts (nvidia-smi -pl <W>).
gpu_persistence_mode: Option<bool>Persistence mode state (nvidia-smi -pm 1).
gpu_auto_boost: Option<bool>Auto-boost state (false ⇒ disabled).
ferrum_env: BTreeMap<String, String>Selected FERRUM_* env vars affecting runtime (sorted by BTreeMap).
runtime_config: RuntimeConfigSnapshotStable sorted runtime config snapshot for non-default FERRUM_* values.
vllm_args: Option<Vec<String>>vllm serve effective args, populated only for vLLM cells. None
for ferrum cells — used by the config-parity report block.
Implementations§
Source§impl Env
impl Env
Sourcepub fn hash(&self) -> EnvHash
pub fn hash(&self) -> EnvHash
Compute the env_hash. Deterministic given:
BTreeMap(sorted) forferrum_env- explicit struct field order (serde serializes in declaration order)
Vec<String>fields are caller-sorted (we don’t sort here so the raw order is preserved for display — callers should sortferrum_featuresbefore constructingEnvif they want order-independent hashes).
Sourcepub fn capture_minimal(commit_sha: String, ferrum_features: Vec<String>) -> Self
pub fn capture_minimal(commit_sha: String, ferrum_features: Vec<String>) -> Self
Capture commit + rust + features + auto-detected hw/driver/cuda.
On CUDA hosts populates GPU driver + CUDA toolkit versions via
nvidia-smi and nvcc --version; on macOS uses sysctl.