pub struct V41Runtime {Show 38 fields
pub attn_cfg: AttnV41Cfg,
pub moe_cfg: MoeV41Cfg,
pub attn: Mutex<AttnV41>,
pub moe: Mutex<MoeV41>,
pub engram: Mutex<EngramV41>,
pub lru: Mutex<ExpertLru>,
pub arena: ExpertArena,
pub slices: Arc<ExpertSliceMap>,
pub rows: EngramRowReader,
pub tables: Arc<EngramHashTables>,
pub hasher: Mutex<EngramHasher>,
pub shared: Mutex<SharedV41>,
pub step_hashes: Mutex<Option<Vec<i64>>>,
pub pre_prev: DevicePtr,
pub mixes_s: DevicePtr,
pub reader_threads: usize,
pub n_layers: usize,
pub hc_mult: usize,
pub hidden: usize,
pub sinkhorn_iters: usize,
pub hc_eps: f32,
pub norm_eps: f32,
pub pre_a: DevicePtr,
pub pre_f: DevicePtr,
pub post_s: DevicePtr,
pub comb_s: DevicePtr,
pub attn_in: DevicePtr,
pub max_tokens: usize,
pub step_moe: Mutex<MoeV41Timing>,
pub step_attn_ms: Mutex<f64>,
pub step_engram_ms: Mutex<f64>,
pub step_start: Mutex<Option<Instant>>,
pub graph_disabled: AtomicBool,
pub seg: Mutex<SegState>,
pub roles: Mutex<Vec<Option<LayerRole>>>,
pub engram_layers: Mutex<Vec<(usize, usize)>>,
pub pred_x: DevicePtr,
pub pred_trace: Mutex<Option<BufWriter<File>>>,
}Expand description
Everything the forty layers share for the ONE sequence in flight.
Fields§
§attn_cfg: AttnV41Cfg§moe_cfg: MoeV41Cfg§attn: Mutex<AttnV41>§moe: Mutex<MoeV41>§engram: Mutex<EngramV41>§lru: Mutex<ExpertLru>§arena: ExpertArenaKept alive for the cache’s lifetime; freed with the runtime.
slices: Arc<ExpertSliceMap>§rows: EngramRowReader§tables: Arc<EngramHashTables>§hasher: Mutex<EngramHasher>§step_hashes: Mutex<Option<Vec<i64>>>The step’s engram hashes [tokens, n_engram_layers, cols], computed by
the first engram layer and reused by the second.
pre_prev: DevicePtrThe delayed pre mix [max_tokens, hc] f32 on the device.
mixes_s: DevicePtr[max_tokens, (2 + hc) * hc] f32 scratch for the hc mixes (dot -> finish)
reader_threads: usize§n_layers: usize§hc_mult: usize§sinkhorn_iters: usize§hc_eps: f32§norm_eps: f32§pre_a: DevicePtr§pre_f: DevicePtr§post_s: DevicePtr§comb_s: DevicePtr§attn_in: DevicePtr§max_tokens: usize§step_moe: Mutex<MoeV41Timing>per-step totals across layers, printed by the last layer when ATLAS_DS41_DIAG=1
step_attn_ms: Mutex<f64>§step_engram_ms: Mutex<f64>§step_start: Mutex<Option<Instant>>§graph_disabled: AtomicBoolSet when a capture failed: every segment from then on runs eagerly (graphs already captured keep replaying; they are valid).
seg: Mutex<SegState>The whole-step segment graphs (ATLAS_DS41_STEP_GRAPH=1, step_seg.rs).
roles: Mutex<Vec<Option<LayerRole>>>Every layer’s role, filled as the layers are built (the segment owner reads the roles of the layers its graph spans).
engram_layers: Mutex<Vec<(usize, usize)>>(layer, hash index) of the engram layers.
pred_x: DevicePtrATLAS_DS41_PREDICT_TRACE: the last three layers’ MoE inputs
([3, hidden] bf16, slot layer % 3) and the trace file.
pred_trace: Mutex<Option<BufWriter<File>>>