+91 80401 38000[email protected]24/7 Expert Support
[email protected]Client Portal →
ServerGurus
← All posts
AI/MLInferenceGPU CloudIndustry News

GLM Built Its Own Inference Stack on 100,000 Non-NVIDIA Accelerators - What GPU-Cloud Operators Should Steal

By ServerGurus Team18 September 202613 min read
GLM Built Its Own Inference Stack on 100,000 Non-NVIDIA Accelerators - What GPU-Cloud Operators Should Steal

On September 17, Z.ai published a post titled "Toward Recursive Self-Improvement: How GLM Built Its Own Inference Infrastructure." Strip the framing and it is one of the more detailed inference-engineering writeups to appear this year: how GLM-5.3-Flash went from its first successful run on unfamiliar silicon to a production serving stack in under two weeks, with an agent doing most of the engineering.

The framing, briefly, because it will color how you read the post: Z.ai frames this as an early form of Recursive Self-Improvement - the model helping build the infrastructure that trains its successors. They explicitly say they are not there yet ("Choosing objectives, setting boundaries, and assessing risk remain human responsibilities"), but note that "the numbers, two weeks, threefold throughput, and 100,000 accelerators, tell us that progress at this boundary will not slow down simply because we want it to." Treat that as the vendor's narrative wrapper. The engineering underneath stands on its own.

Whether or not you ever touch non-NVIDIA hardware, the methodology in this post is directly portable to a vLLM or SGLang fleet. That is what this post is about - what they published, and what an operator renting GPUs should take from it.

What Z.ai Says They Built

The headline claim: GLM-5.3-Flash launched as a complete production inference service built from scratch on a cluster of more than 100,000 Chinese-made AI accelerators. Z.ai does not name the chip. All production inference for GLM-5.3-Flash runs on this system.

The constraints they list are honest about how rough the hardware was: relatively limited chip memory capacity and bandwidth, a new model architecture with a 1M-token context window, multimodal requests, an immature software ecosystem, and incomplete kernel support. In their words, "much of what should have been documented had to be guessed."

The serving techniques they name: intra-node tensor parallelism for linear attention and the LM Head, ReplaySSM (trading compute for memory), W8A8 quantization, mixed-precision cache quantization using INT8/FP8/BF16, and Layer Split - plus an Encode-Prefill-Decode (EPD) disaggregated architecture on top. Together they claim roughly 3x end-to-end throughput versus the initial baseline, with hardware utilization and per-token cost reaching levels "comparable to mainstream NVIDIA GPUs."

Much of the build was done by an "Infra Agent" powered by GLM-5.3. Engineers defined objectives and system boundaries and reviewed risk-critical changes; the agent proposed hypotheses, wrote code, and ran experiments.

The market-receipt footnote: the model launched anonymously as "Ox-Alpha" on OpenCode and OpenRouter, became the most-used model on both within a week, and processed more than 62 trillion tokens in six days.

The Serving Stack, Translated

For operators who have not lived in inference-kernel land this quarter, here is what each named technique is actually doing, in one line each:

  • Intra-node tensor parallelism for linear attention and the LM Head. Split the two memory-hungry parts of the model - the linear-attention layers and the final output projection - across the GPUs inside one node, because a chip with "relatively limited memory capacity" cannot hold them whole.
  • ReplaySSM. A state-space-model trick that recomputes state instead of storing it: spend FLOPs you have to save memory bandwidth and capacity you do not. It is the concrete form of their stated trade: "compute for bandwidth, communication for device memory."
  • W8A8 quantization. Weights and activations at 8-bit instead of 16, halving memory traffic per token and using INT8 tensor paths the chip can execute fast.
  • Mixed-precision cache quantization (INT8/FP8/BF16). Not one KV-cache format but three, applied where each is safe. Aggressive enough to fit long contexts in small chips, careful enough not to corrupt the math.
  • Layer Split. Partition the model's layers across devices so each device's slice fits its memory.
  • EPD disaggregation. Encode, Prefill, and Decode run as separate services on separate pools, instead of one GPU doing all three. Prefill bursts stop stealing decode latency; each stage scales and optimizes independently.

None of these are exotic in the vLLM/SGLang world - most map to work you can run today. What is notable is the combination being pushed to its limit on hardware with no NVIDIA-grade memory bandwidth and no mature kernel library, under a 1M-token context requirement.

The Central Idea: Dense Feedback, Not More Logs

The most useful part of the post is not the hardware story. It is their answer to a question every agent-and-infra effort runs into: an end-to-end metric can tell you things got worse, but it cannot explain why. "TTFT increased 30%" leaves an engineer - or an agent - guessing about which of a dozen layers is responsible.

Their diagnosis of why this is harder than it looks: a codebase provides only static context. Numerical discrepancies, performance regressions, and missed targets in an inference system come from dynamic interactions across kernels, parallelism strategies, communication behavior, memory management, and serving orchestration. An agent can read all of it and still not know which layer broke.

They call their approach "dense feedback," and "dense" explicitly does not mean more logs. It means feedback with three properties:

  1. Local and attributable. Tied to a specific kernel, code path, input shape, thread, or launch parameter - not a dashboard aggregate.
  2. Cheap and fast to obtain. If a kernel test or microbenchmark can answer the question, you should not need a full deployment and a load test.
  3. Objectively verifiable. Reference implementations, controlled experiments, comparable metrics. Correlations in runtime signals suggest causes; experiments confirm them.

They sort feedback into three classes: correctness ("is the math right"), system behavior ("where is the time going"), and performance ("which approach wins, under which conditions"). Local validation and end-to-end testing play different roles: local tests kill bad or ineffective changes early; end-to-end runs confirm whether local gains survive real serving workloads and check for new regressions.

Then they walk through one case per class. All three are worth reading even if you never use an agent.

Three Cases, And Why They Matter To You

Case 1 - correctness: a silent precision bug in a parallel path. The KDA kernel's Context-Parallel path used Triton's tl.dot with its default TF32 precision even when inputs were FP32. In the shard-state merging math (M = tl.dot(M_chunk, M) and S_next = tl.dot(M, S) + H), errors accumulated across merges and got worse at long context. The fix was explicitly setting input_precision="tf32x3" - three TF32 tensor-core operations combined for near-FP32 accuracy while keeping most of the tensor-core speed. The interesting part is how it was found: they tested partitioned execution paths against unpartitioned ones for identical inputs, aligning semantics and output positions and checking error tolerances - a coverage gap most kernel test suites have, because everyone tests the happy path only. The fix was merged upstream into Flash Linear Attention (PR #1180), so if you run that library on tensor-core hardware, this one is already yours.

Case 2 - behavior: the GIL was starving KV transfer. Engineers set an acceptance budget: under the same workload, Prefill + KV Transfer should stay within 5% of Prefill-only. The agent measured a gap over 20% in some scenarios. Execution timelines showed Python-side Mooncake KV Transfer never overlapping DeepEP dispatch/combine intervals - the two components simply never ran at the same time. Root cause: in DeepEP v1.2.1, intranode_dispatch and intranode_combine never release the Python GIL, and dispatch additionally CPU-waits on the GPU to return token counts. Meanwhile internode_dispatch in the same version does release the GIL, with a source comment explaining it exists to avoid blocking KV transfer in other threads - a built-in confession that the intra-node path had the bug. Entering C++ does not automatically drop the lock; while these calls held it, the transfer thread could not submit work. Releasing the GIL during those intervals closed the gap to under 1%. The transfer mechanism was always asynchronous - the starvation was one layer up, where no kernel profiler looks.

Case 3 - performance: profiling beats blind optimization. The agent distilled "optimization skeletons" - applicability conditions, transforms, resource constraints, and evidence - from kernels in SGLang, Flash Linear Attention, and DeepGEMM. Applied to a KDA decode kernel: ReplaySSM made it slower by design (that was the compute-for-memory trade), a division optimization cut 9.6%, then profiling said the kernel was compute-bound. The cause: tiling along the V dimension repeated the same FP32 normalization and gating computation four times. Merging the tiles into one thread block with register-resident intermediates and a single warp-level reduction - trading parallelism for eliminated redundancy - gave 1.71x over v2.

The closing frame: "The model optimizes the system; the system runs the model." Z.ai is careful to say this is not recursive self-improvement - humans own objectives, boundaries, and risk assessment. Their summary numbers: two weeks, 3x throughput, 100,000 accelerators.

What GPU-Cloud Operators Should Actually Steal

This is our analysis, not theirs.

1. The acceptance-budget pattern costs you a page of documentation and pays for itself immediately. "Prefill + KV Transfer within 5% of Prefill-only" is one sentence - and it turned a vague "not fast enough" into a measurable discrepancy with a defined pass/fail. Write budgets per stage for your own stack before you start tuning, then isolate the stages (prefill-only, prefill+transfer, decode-only) against the same workload. This works on vLLM and SGLang today, agent or no agent.

2. Cross-layer attribution beats metric-spam. The GIL case is the reminder: serving bottlenecks hide in Python/C++ boundaries, thread scheduling, and orchestrators - not in kernels. A throughput dashboard cannot see a starved transfer thread. Capture execution timelines, not just dashboards. When "everything is healthy but slow," the answer usually lives between the layers your monitoring covers.

3. CUDA lock-in is weaker as an absolute than the industry talks about it. A 100,000-accelerator non-NVIDIA production fleet reportedly reaching NVIDIA-comparable utilization and cost-per-token is significant for sourcing and pricing conversations - alternative silicon is no longer hypothetical at this scale. Big caveats below. Treat it as direction, not as a benchmark you can quote to your CFO.

4. The two-week cold-start is the real headline, and the reason was scaffolding, not model IQ. A new model on undocumented hardware with incomplete kernels, in production in under two weeks - what made that fast was the harness: kernel-level correctness comparisons, microbenchmarks, timelines, and budgets wired into the loop. Concretely, the harness they describe has four pieces you can build for your own stack: a mapping from parallelism configurations to the kernels they exercise (so partitioned paths get tested, not just the happy path), microbenchmarks per kernel per input-shape class, execution timelines that capture compute/wait/communication overlap, and per-stage acceptance budgets. An agent without cheap attributable feedback is just a faster way to generate bad hypotheses. With the harness, it is an amplifier.

5. EPD disaggregation and cache quantization validate the roadmap most of us are already on. Prefill/decode separation and INT8/FP8 KV-cache compression are exactly where the vLLM/SGLang ecosystem is heading. Z.ai shipping it at this scale, with claimed 3x end-to-end, is another data point that this is where inference economics improve next.

And what this does not mean. It does not mean you should buy unnamed Chinese accelerators tomorrow - the entire business case here rests on software maturity that took a frontier lab's kernel team two weeks to bootstrap, on a model that lab controls end to end. It does not mean agent-driven tuning replaces your inference engineers; on Z.ai's own account, humans still owned every risk-critical review. And it does not mean NVIDIA's moat is gone - it means the moat is now mostly ecosystem maturity, which is the kind of moat that erodes fastest when enough buyers are price-hiking-averse.

Who Does What: Engineers, Agent, Environment

Worth noting how explicitly Z.ai divides the labor, because it is a clean operating model for anyone deploying agents on infrastructure work:

  • Engineers own three things: defining optimization objectives and system constraints, building the feedback environment the agent can use directly, and reviewing critical changes - anything touching system architecture, asynchronous concurrency, or production risk.
  • The agent proposes hypotheses, implements changes, runs experiments, and uses the feedback to retain, revise, or reject its current approach.
  • The experimental environment provides layered, timely, verifiable feedback: kernel comparisons for numerics, microbenchmarks for local performance, execution traces and runtime events for timing relationships.

Correctness, stability, and end-to-end performance jointly define final acceptance. The agent never grades its own homework at the system level. If you are handing a serving stack partly to an agent, that split - human owns objectives, boundaries, and risk review; the harness owns verification - is the version worth copying.

The Honesty Section

Every number in this post is Z.ai's own. There is no independent benchmark of GLM-5.3-Flash's throughput or cost. The accelerator is unnamed - you cannot evaluate the silicon claim without knowing the silicon. "Comparable to mainstream NVIDIA GPUs" is an unmeasured, self-reported comparison. The 62-trillion-tokens-in-six-days figure is platform-reported usage under an anonymous model name, which is a popularity signal, not an efficiency one. And the "Infra Agent did much of the work" framing comes from the party selling GLM-5.3 as a coding model.

None of that makes the engineering writeup less useful. The TF32 bug, the GIL fix, and the acceptance-budget method are checkable, portable ideas - you can verify them on your own cluster this week. The upstream Flash Linear Attention PR is public; the DeepEP GIL behavior is readable in the source; the budget methodology needs no hardware at all to evaluate. We flagged the claims we could not check and lean on the ones that stand independent of the vendor's incentives.

If You Want To Copy This, Start Here

Not an agent. Not new hardware. A weekend of harness work on the stack you already run:

  1. Pick three stages of your serving path - prefill-only, prefill + any transfer/queueing you have, decode-only - and pin the same synthetic workload through each.
  2. Write acceptance budgets between them. Ours typically start as: prefill+transfer within 5% of prefill-only; decode inter-token latency within 10% of an idle-cache baseline. Adjust to your SLA; the number matters less than having one.
  3. Capture one execution timeline per stage with compute, wait, and communication events visible together (CUDA/PyTorch profiler traces are enough to start). Look for intervals where two components that should overlap never do.
  4. Add one kernel-level test that compares a partitioned path against its unpartitioned twin for your highest-risk parallelism setting. That single test is what caught the TF32 bug above.

If you get through this and your budgets pass with room to spare, congratulations, your stack is healthier than most. If a budget fails, you have just reproduced Z.ai's Case 2 with a fraction of their effort - a bounded, attributable problem instead of "the site feels slow."

The Bottom Line

Z.ai claims they put a frontier model into production on 100,000+ unglamorous accelerators in two weeks by making feedback cheap, local, and verifiable - and by letting the model tune the system that runs it. The methodology survives the vendor-claim filter: write your per-stage acceptance budgets, capture timelines across layer boundaries, and build the test harness before you point an agent at your inference stack.

If you are running inference on rented or dedicated GPUs and want help putting that loop in place - stage isolation, budget definition, timeline capture - talk to ServerGurus. We run GPU infrastructure for production AI workloads, and we would rather debug your GIL problem than sell you another dashboard.

Ready to build your infrastructure?

Get a quote from our Hyderabad-based team - Tier IV datacenter, real support, INR or USD billing.

View pricingRequest a quoteWhatsApp sales