LLM Inference Tuning on 8 Domestic AI Accelerators: A 53.5% Throughput Gain

    This article presents a vendor-neutral framework for tuning large language model inference on an 8-card domestic accelerator server. It explains why deployment is difficult, how to organize reusable model deployment plans, and the three optimization steps—parallelism strategy, sequence parallelism with communication tuning, and graph/operator compilation—that delivered up to 53.5% higher throughput under a fixed SLO. It also outlines a validation loop for reproducing and recording performance results.

    1. Why LLM Inference Deployment Is Hard on Domestic Compute

    Deploying a large language model on domestic compute platforms usually starts with picking a model. What actually determines time to production and final performance is a chain of engineering decisions: matching the inference engine to the container image, deciding how many accelerators the model needs, choosing how to split the parallelism strategy, and identifying which compilation and communication optimizations genuinely fit the workload. A wrong call at any step shows up as missed throughput targets, latency jitter, or idle resources.

    Consider a common scenario on an 8-card server built with the latest model of a domestic accelerator. When deploying a quantized MoE (Mixture of Experts) LLM, the baseline configuration runs, but as concurrency rises, throughput saturates quickly under the defined SLO (Service Level Objective, typically covering a first-token latency ceiling and a per-token latency ceiling). This article abstracts a brand-agnostic tuning framework from that scenario and explains the engineering logic behind a 53.5% throughput gain.

    2. Turning Deployment Experience into a Browseable Solution Catalog

    Mature default configurations are scarce in domestic computing environments, which makes experience reuse extremely valuable. A practical approach is to organize each deployment as a structured “model deployment plan” bound to a specific model and hardware, recording four categories of information:

    • Inference engine and image version;
    • Resource requirements (card count, memory, CPU-to-memory ratio);
    • Parallelism and quantization configuration;
    • A baseline vs. optimized comparison report under existing performance data.

    An illustrative plan structure looks like this:

    1. model: llm-moe-quant
    2. hardware: domestic-accelerator-8x
    3. engine: vllm-style-ascend-backend
    4. resources: {cards: 8, mem_per_card: 64G}
    5. baseline: {tp: 8, dp: 1}
    6. optimized: {tp: 2, dp: 4, ep: true, seq_parallel: true}
    7. slo: {ttft_ms: 2000, tpot_ms: 50}
    8. result: {throughput_gain: "up to 53.5%"}

    The value of the catalog is that new team members can search by model or hardware and compare configurations side by side, while the deployment backend can automatically sync parameters from the catalog, reducing the drift caused by word-of-mouth handoffs.

    3. Optimization Case Study: Three Steps on 8 Cards

    3.1 Adjust the Parallelism Strategy to Handle Concurrency Better

    The baseline uses pure tensor parallelism (tp8, dp1): a single model instance spans all eight cards, inter-card communication is heavy, and all concurrent requests hit the same instance, causing obvious queuing. The optimized setup switches to tp2, dp4—each card handles a smaller tensor slice while four data-parallel replicas run, with expert parallelism layered on to handle MoE routing.

    1. Baseline: [==== TP8 single instance ====] -> heavy communication, request queuing
    2. Optimized: [TP2][TP2][TP2][TP2] -> 4 replicas + expert parallelism

    The benefit is a smaller communication domain and concurrency split across multiple replicas, leading to more balanced scheduling.

    3.2 Enable Sequence Parallelism and Communication Optimization

    Under long contexts and high concurrency, splitting along the sequence dimension significantly reduces per-card activation pressure. Combined with collective communication optimization, it cuts the waiting bubbles in all-reduce/all-to-all operations and increases the overlap between computation and communication.

    3.3 Graph and Operator Compilation Optimization

    With graph mode and operator compilation caching enabled, the framework can turn dynamic execution into a static graph, reducing scheduling overhead and enabling fuller operator fusion, which yields smoother steady-state latency.

    4. Interpreting the Results and Closing the Validation Loop

    Under the same SLO, this combination improved total throughput by up to 53.5% over the baseline. Note that this figure depends on the specific model, quantization method, card type, and workload distribution, and cannot be directly extrapolated. The recommended validation loop is: fix the SLO → stress-test the baseline → adjust one variable at a time (parallelism first, then communication, then compilation) → record throughput and latency curves → write results back to the solution catalog. Baidu AI Cloud also emphasizes in related engineering practice that performance conclusions must be tied to reproducible configurations and stress-test conditions to become transferable tuning assets.