How LLM Inference Depends on AI Infrastructure: Bottlenecks and Solutions

    This article explains why large language model inference relies heavily on AI infrastructure, and examines three major bottlenecks of traditional cloud-native architectures: single-machine limits that force distributed parallelism, long cold starts that break conventional autoscaling, and multi-node tasks that are hard to operate atomically. It then presents the key engineering responses: atomic instances that unify distributed lifecycle, topology-aware placement, and group-level rollout; second-level resource activation through weight and runtime prewarming, pooled silent instances, and tiered warm-up policies; and high-performance request scheduling based on load awareness, batching, and prefix affinity. The article closes with the stability and observability practices that infrastructure must own, including tiered health checks, whole-instance recovery, full-link metrics, and capacity guardrails.

    1. Why LLM Inference Cannot Work Without AI Infrastructure

    Once large language models grew from tens of billions to hundreds of billions and even trillions of parameters, the engineering focus of the inference stage shifted from “how the model is written” to “how compute is organized.” The model architecture itself is relatively stable. What really determines the quality of online serving is whether the underlying AI infrastructure can package scattered accelerators, networks, and storage into a service unit that is schedulable, observable, and elastically scalable. Put differently, the upper bound of inference performance is set by the model, while the throughput, latency, and cost actually delivered are determined almost entirely by the capabilities of the infrastructure.

    In industry practice, the inference side usually has to balance three mutually constraining goals. It can be understood as an “impossible triangle”:

    • Model scale: whether the model fits, can be split, and can run;
    • Cost and elasticity: whether resources are wasted during traffic troughs and whether the system holds up during peaks;
    • Efficiency and stability: whether low latency and high throughput can be sustained, with failures kept under control.

    Traditional cloud-native architectures gradually show strain in the face of this triangle, mainly in three types of challenges.

    2. Three Bottlenecks of Traditional Architectures in LLM Inference

    2.1 Model Scale Approaches the Single-Machine Limit, Making Distribution Inevitable

    A single machine with multiple GPUs can no longer hold the weights and intermediate activations of a giant model. In engineering practice, tensor parallelism (TP) is usually applied first to split the computation of a single layer across multiple cards, reducing per-GPU memory pressure. Expert parallelism (EP) and data parallelism (DP) are then layered on top to form a hybrid parallel topology. Once the degree of parallelism increases, the communication pattern extends from “intra-machine high-speed interconnect” to “inter-machine networks,” which places far higher demands on the infrastructure’s networking, topology awareness, health checking, and batch operations than a conventional stateless service does.

    2.2 Long Cold Starts Break Traditional Autoscaling

    Bringing a giant model instance from zero to serviceable usually involves several stages: image and runtime preparation, weight pulling and loading, distributed networking and handshakes, computation graph compilation, and GPU memory warm-up. The cumulative time can reach the order of several minutes. Online traffic, however, generally shows a clear tidal effect: daytime peaks need a large number of instances, while nighttime troughs may need only a very small scale. With fixed resource deployment, compute sits idle during troughs. If you rely on traditional horizontal Pod autoscaling (HPA) to scale replicas up and down quickly, new replicas are not ready before the traffic peak has already passed, so scaling out is “too late” and scaling in is “hard to bear.”

    2.3 A Single Inference Task Spans Multiple Machines, Making Operations Hard to Atomize

    One distributed inference task may contain dozens of process units spread across different physical machines, with strict startup ordering and communication dependencies between them. Traditional operations treat each unit as an independent object. The result: inconsistent versions at release time, only partial recovery during failures, and mixed old and new topologies during canary rollouts, which makes problem diagnosis extremely difficult.

    3. The Key Idea: Making Distributed Instances “Atomic”

    The core abstraction for solving the problems above is to elevate “a group of distributed units that must live and die together” into the smallest unit of scheduling and operations, namely the atomic instance. It has three characteristics:

    • Unified lifecycle: all members either become ready together or are judged as failed together and rebuilt as a whole, avoiding a “partially available” topology;
    • Topology-aware orchestration: the scheduler understands the communication relationships among members and tries to place members with high-bandwidth communication in the same high-interconnect domain, reducing cross-domain hops;
    • Group-level canary and rollback: versions switch at the granularity of the “instance group,” eliminating member version drift.

    A schematic declaration structure can be understood as follows (pseudocode, expressing the abstraction only):

    1. atomicInstance:
    2. name: llm-infer-70b
    3. topology: { tp: 8, ep: 2, dp: 1 } # parallel topology
    4. members: 16 # total units
    5. placement: preferSameHighBandwidthDomain
    6. lifecycle:
    7. allOrNothing: true # all ready or full rebuild
    8. healthCheck: { interval: 5s, failureThreshold: 3 }
    9. rollout:
    10. strategy: groupCanary # canary at group granularity
    11. maxUnavailable: 0

    Once both scheduling and operations use the atomic instance as the unit, the complexity of cross-node management is significantly reduced: users face one service instead of a dozen processes that must be manually aligned.

    4. Second-Level Resource Activation: Making Elasticity Usable Again

    To make elasticity work again in the face of minute-level cold starts, the idea is to change “prepare at startup” into “prepare in advance, activate on demand.” Common general practices in the industry include:

    1. Prewarming and local caching of weights and runtime: distribute large weights to node-local high-speed storage in advance, and prefer local copies at load time to reduce remote pulling;
    2. Resource pooling and silent instances: pre-start a batch of “silent instances” that have completed runtime initialization but have not yet joined the serving topology, so that when traffic arrives only the incremental steps of networking and graph loading remain, compressing activation time to seconds;
    3. Tiered warm-up policies: warm up in batches ahead of time according to historical tidal patterns, turning predictable peaks into planned actions and leaving unpredictable bursts to silent instances as a fallback.

    The activation decision can be described with the following pseudo-logic:

    1. if predicted_qps > current_capacity * 0.8: # tidal peak predicted
    2. pool.prewarm(target=expected_members) # warm up in advance
    3. elif burst_detected and pool.silent > 0: # burst traffic with silent instances available
    4. pool.activate(pool.silent[:need]) # activate in seconds and join the topology

    It is worth emphasizing that silent instances are not “free compute”; they themselves consume resources. They must therefore be paired with utilization monitoring and automatic reclamation policies that release them promptly during troughs, so that cost and elasticity are genuinely balanced.

    5. High-Performance Traffic Scheduling: Squeezing Cluster Utilization to the Limit

    Once resources are ready, what determines actual efficiency is how requests are distributed. Request costs in LLM inference vary enormously: input length, output length, and whether the prefix cache is hit all cause per-request latency to fluctuate. Simple round robin easily leads to a situation where some instances pile up while others idle.

    More reasonable scheduling usually focuses on three points:

    • Load awareness: score instances dynamically based on in-flight requests, queue length, and GPU memory watermark rather than static round robin;
    • Batch scheduling (understandable as a “shuttle bus” approach): accumulate requests that arrive within a short time window and share similar characteristics into a batch and dispatch them together, trading higher batching efficiency and memory utilization within latency constraints;
    • Affinity optimization: route requests sharing the same prefix to the same instance as much as possible, improving prefix cache hit rates and reducing repeated computation.

    A simplified scoring function can be expressed as:

    1. def score(instance, request):
    2. load = instance.inflight / instance.max_inflight
    3. mem = instance.kv_cache_used / instance.kv_cache_total
    4. prefix_gain = 1.0 if request.prefix in instance.cache else 0.0
    5. return 0.5 * load + 0.4 * mem - 0.3 * prefix_gain # lower is better

    Combined with atomic orchestration, second-level activation, and load-aware scheduling, engineering practice typically observes improvements on the order of a roughly 30-40% reduction in time to first token (TTFT) and a roughly 10-20% increase in overall throughput (the specific numbers vary with model scale, parallel strategy, and traffic characteristics, and should be based on actual load testing).

    6. Stability and Observability Are Also Infrastructure Responsibilities

    Efficiency gains must not come at the cost of stability. Production environments should cover at least:

    • Tiered health checks: distinguish three levels of state, namely process liveness, communication link connectivity, and model inference capability, to avoid false judgments;
    • Whole-instance failure recovery: rebuild at the granularity of the atomic instance when any member is abnormal, preventing long-term operation on a degraded topology;
    • Full-link metrics: bring queueing latency, time to first token, per-output-token latency, GPU memory usage, and batch size into unified monitoring and alerting;
    • Capacity guardrails: set thresholds for the number of silent instances, maximum batch size, and concurrency limits to prevent overload avalanches.

    7. Conclusion

    The relationship between LLM inference and AI infrastructure is essentially a bridge between “algorithmic possibility” and “engineering feasibility.” Unifying the distributed lifecycle with atomic instances, trading prewarming and silent instances for second-level elasticity, improving cluster utilization with load-aware and batch scheduling, and supplementing all of this with complete observability and guardrail mechanisms is what makes a sustainable balance possible among model scale, cost elasticity, and efficiency stability, providing a solid compute foundation for the long-term stable operation of ultra-large models on cloud platforms such as Baidu AI Cloud.