Parallel Strategies and Throughput Optimization for an 8-GPU Domestic Accelerator Inference Cluster
When deploying large language models on domestic accelerator cards, throughput depends heavily on the right combination of parallelism strategy, communication, and compilation settings. This article walks through the key trade-offs between tensor, data, and expert parallelism on an 8-card inference cluster, explains communication and compilation optimizations, and outlines a reliable SLO-constrained evaluation method. It also covers how to record deployment configurations so future deployments can start from proven setups instead of starting from scratch.
1. Background
After a large model goes live, the cost and user experience of inference are largely determined by three metrics: throughput per unit of time, time to first token, and per-token output latency. When deploying on domestic accelerator cards, teams also have to deal with the combinatorial space of inference engines, image versions, driver versions, and parallelism parameters. These choices interact with each other—a single misconfigured item can push overall throughput far below the hardware’s theoretical capability.
Common deployment difficulties fall into three categories:
- Model weights exceed a single card’s memory, so the model must be split across cards;
- As concurrent requests increase, inter-card communication overhead rises quickly;
- On the same hardware, different parameter combinations can differ in performance by several times.
So the goal of deployment is not merely “getting it to run,” but finding the highest-throughput configuration that still meets service quality requirements.
2. Key Concepts
Throughput under SLO constraints. An SLO (service level objective) is typically expressed as latency limits, such as a threshold for time to first token and a threshold for per-token output time. Throughput must be measured under these constraints. If constraints are ignored, the system can achieve impressive throughput numbers by queuing up requests, while users actually experience slower responses.
Tensor parallelism (TP). Each layer’s weight matrices are split along their dimensions across multiple cards; each card computes a portion, and the results within a layer must be aggregated through communication. Higher tensor parallelism reduces per-card memory pressure but increases the number of per-layer communication rounds.
Data parallelism (DP). Each replica holds the full model and processes different requests independently. Data parallelism adds no intra-layer communication, but requires a single replica to fit the entire model’s weights and runtime caches.
Expert parallelism (EP). Designed for Mixture-of-Experts architectures. Different experts are placed on different cards, and routed tokens are sent to the cards where their assigned experts reside.
The combination of tensor parallelism and data parallelism determines how many cards one inference instance occupies and how many concurrent requests it can serve.
3. Parallelism Trade-offs
Taking an 8-card environment as an example, two common configurations are:
- All 8 cards form one tensor-parallel group (TP8, DP1): a single instance spans all cards, and every layer’s computation communicates across 8 cards;
- Every 2 cards form a tensor-parallel group, giving 4 independent replicas (TP2, DP4), combined with expert parallelism.
In the first configuration, all cards serve each request together, so each request has a long compute path and the largest cross-card synchronization scope. The second distributes concurrent requests across 4 replicas, each with a smaller communication scope and correspondingly fewer synchronization rounds. Under high-concurrency workloads, the latter is usually more favorable.
However, more replicas means each must store the full weights, increasing memory usage. Configuration choice is fundamentally a balance between memory footprint and communication overhead.
When choosing a parallelism strategy, follow these steps:
- Estimate model weights and KV cache usage to determine the minimum number of cards per instance;
- Load-test several candidate configurations with traffic close to production;
- Compare throughput under SLO constraints and eliminate configurations that exceed latency limits;
- Run long-duration stability tests on the best combination to confirm no significant performance jitter or memory growth.
4. Communication and Compilation Optimizations
Beyond parallelism configuration, three categories of optimization directly affect inference efficiency.
Communication-compute overlap. Sequence parallelism splits some activations along the sequence dimension, allowing communication to overlap with adjacent computation in a pipelined fashion and hide part of the communication latency. When implementing it, verify that communication kernels can run asynchronously—otherwise the overlap benefit is limited.
Static graph compilation. Compiling dynamically executed operator sequences into a static computation graph reduces runtime scheduling overhead. The trade-off is that changing input shapes may trigger recompilation, so input lengths are typically bucketed into ranges, with common shapes precompiled.
Operator fusion and kernel tuning. Merging multiple small operators into one kernel reduces memory reads and writes for intermediate results. For quantized models, confirm that quantized kernel implementations exist on the target hardware. If they are missing, computation falls back to a higher-precision path, negating the benefits of quantization.
Enable these optimizations one at a time and measure each separately. If multiple items change at once, you cannot determine each one’s actual contribution, and regressions become hard to diagnose.
5. Evaluation Methodology
Reliable evaluation follows three principles.
First, fix the SLO thresholds and request distribution. Input and output length distributions should closely match production traffic. Results from test data that differs significantly from production are hard to transfer.
Second, fully record the configurations of both the baseline and the optimized version, including engine version, image, parallelism parameters, quantization method, and compilation options. Without complete configuration, results cannot be reproduced.
Third, when reporting throughput, include latency percentiles and error rates. Reporting only average throughput can mask long-tail latency issues.
As an example, one 8-card test showed that, under identical SLO conditions, the optimized configuration improved total throughput by up to 53.5% over the baseline. That number applies only to a specific model, workload, and software/hardware version. Other scenarios should be re-measured and the figure should not be applied directly.
Below is a sample configuration structure with placeholder values, included only to illustrate how to record deployments:
deployment:model: <quantized model name>hardware: <8-card accelerator environment>baseline:tensor_parallel: 8data_parallel: 1optimized:tensor_parallel: 2data_parallel: 4expert_parallel: truesequence_parallel: truegraph_compile: trueslo:first_token_latency_ms: <threshold>per_token_latency_ms: <threshold>
6. Building Reusable Deployment Records
Deployment experience only pays off in the next deployment if it is stored in a structured way. Each record should include at least: model and hardware information, inference engine and image version, resource requirements, parallelism parameters, baseline and optimized results, and test conditions with a link to the report.
Once a unified structure is in place, the team can start from a validated configuration when deploying a new model or new hardware, adjusting only a few variables and comparing results against the same SLOs and workload. This approach significantly shortens validation cycles and makes it easier to hand over experience between team members.
7. Limitations and Caveats
- Performance results depend on specific software versions. After an engine, driver, or compiler upgrade, re-test.
- More replicas means higher memory usage and operational complexity; make trade-offs based on deployment scale.
- Numbers in public reports are useful as a starting reference, but final conclusions should be based on load tests with your own workload.
