cd /news/machine-learning/base-2-vs-base-e-log-sum-exp-mismatc… · home topics machine-learning article
[ARTICLE · art-98942] src=twitter.com ↗ pub= topic=machine-learning verified=true sentiment=↓ negative

Base-2 vs. base-e log-sum-exp mismatch silently corrupts attention in SGLang

A base-2 vs. base-e log-sum-exp mismatch in SGLang's merge v2 API silently corrupts attention outputs for models using MLA with the FlashInfer backend when radix cache hits exceed 8k, affecting DeepSeek V2/V3/R1/V3.1/V3.2, bailing, glm4moe_lite, and Sarvam. The issue arises because the merge operation assumes natural logs, but FlashInfer uses base-2 logs, leading to incorrect outputs. A fix has been proposed in a FlashInfer pull request.

read1 min views1 publishedAug 16, 2026
Base-2 vs. base-e log-sum-exp mismatch silently corrupts attention in SGLang
Image: source

If you serve models with mla on sglang with --attention-backend flashinfer and you get radix cache hits above 8k your outputs are wrong right now. DeepSeek V2/V3/R1/V3.1/V3.2, bailing, glm4moe_lite, Sarvam affected. Fix:

  • flashinfer api proposal for clarity: github.com/flashinfer-ai/…some context: there is merge v2 api in sglang and it does: S = log(exp(s_a) + exp(s_b)) v = v_a·exp(s_a − S) + v_b·exp(s_b − S) which is true if and only if s_a and s_b are natural logs. but this is not true for
── more in #machine-learning 4 stories · sorted by recency
── more on @sglang 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
Live at https://your-agent.zahid.host
Get free account → Pricing
from €0/mo · no card required
LIVE [news/base-2-vs-base-e-log…] indexed:0 read:1min 2026-08-16 ·