跳到正文
arXiv cs.AI· Pushkar Patel, Romit Jain, Tejesh Bhalla·· 3 小时前AI 评分43

被掩码的未来并非隐形的未来:让 MXFP8 注意力保持因果性

A Masked Future Is Not a Hidden Future: Keeping MXFP8 Attention Causal

AI 导读

一篇 arXiv 论文指出,NVIDIA Blackwell GPU 上 Transformer Engine 的 MXFP8 注意力因跨 token 共享量化尺度会破坏因果性,被掩码的未来 token 可能改变早前预测,并提出使用 token 局部尺度的因果注意力 kernel 加以修复。

正文 · 原文

View PDF HTML (experimental)

Abstract:Causal attention must prevent future tokens from influencing earlier predictions, including during parallel training and prompt prefill. Its cost grows quadratically with sequence length, making lower-precision arithmetic an attractive way to accelerate these computations. MXFP8 enables fast eight-bit matrix products on NVIDIA Blackwell GPUs, but sharing quantization scales across tokens can break causality. In Transformer Engine's stock MXFP8 attention, a masked future token can change how an earlier value is rounded and alter an earlier prediction. We demonstrate this dependency in released language models and present a causal attention kernel that removes it. Within value blocks containing both visible and future tokens, our kernel uses token-local scales and folds them into the corresponding attention weights, retaining native MXFP8 for both forward matrix products. We support training with a causal dequantized-input backward and inference with an MXFP8 KV cache. On Qwen3-4B-Base at 32K context, our kernel reduces full-sequence versus prefix disagreement on the most likely next token from 0.416% to 0.021%, close to the BF16 reference of 0.015%. In end-to-end Qwen3-4B training at 32K, our recipe improves throughput by 4.9% and reduces peak memory by 5.2% relative to BF16. For single-request inference, it improves Qwen3-4B decode throughput by 3.8-9.9% over vLLM with FP8 attention and an FP8 KV cache at 4K-32K context, with broadly comparable throughput on Qwen3-14B.
Comments: All authors contributed equally and are listed alphabetically by given name
Subjects: Machine Learning (cs.LG); Artificial Intelligence (cs.AI)
Cite as: arXiv:2611.36044 [cs.LG]
  (or arXiv:2611.36044v1 [cs.LG] for this version)
  https://doi.org/10.48550/arXiv.2611.36044

arXiv-issued DOI via DataCite (pending registration)

Submission history

From: Romit Jain [view email]
[v1] Thu, 26 Nov 2026 13:04:03 UTC (219 KB)

来源:arXiv cs.AI · arxiv.org