pub fn nvfp4_grouped_gate_up(
a: u64,
gate_packed_ptrs: &[u64],
gate_scale_ptrs: &[u64],
gate_scale2_vals: &[f32],
up_packed_ptrs: &[u64],
up_scale_ptrs: &[u64],
up_scale2_vals: &[f32],
c_gate: u64,
c_up: u64,
expert_offsets: &[i32],
n: u32,
k: u32,
stream: u64,
) -> Result<()>Expand description
Grouped (per-expert) NVFP4 fused gate_up GEMM — Holo MoE Phase-1
escape-hatch path. Dispatches the proven Sm120 NVFP4 collective once per
active expert over its token slice; bit-faithful to
nvfp4_gemm_bf16_act_weight_t (it IS that collective), at one launch per
expert. Used to validate that the FP4 math integrates correctly in grouped
form before the hand-rolled block-scaled mma (Phase 2).
a is bf16 [M_total, K]; expert e owns rows
[expert_offsets[e], expert_offsets[e+1]). *_packed_ptrs/*_scale_ptrs
are device-pointer arrays (one per expert) in the
pack_bf16_weight_to_nvfp4_t layout ([N,K/2] + [K/16,N]); the
*_scale2_vals and expert_offsets slices are HOST arrays.