Dual-Server 16-Card Domestic AI Chip Cluster: LLM Training Validation
This article reports a 400-step training validation of a multi-billion-parameter Transformer LLM on a dual-server, 16-card domestic AI chip cluster. It explains why this scale was selected, the hybrid tensor/data parallel topology, framework and operator adaptation, memory and communication optimizations, checkpointing and slow-node handling, and an environment checklist for reproduction. The conclusions are limited to this specific configuration, and the article outlines lessons learned and next steps for scaling.
1. Why Use a Dual-Server, 16-Card Configuration for Validation
The validation target was a Transformer-based large language model with billions of parameters. The training flow included the forward pass, backpropagation, gradient synchronization, and optimizer updates. The run covered 400 steps. That is not a large number of steps, but it was enough to expose issues in framework stability, communication efficiency, and resource utilization.
“Dual-server, 16-card” means two servers with eight cards each. Cards within each server are connected through a high-speed interconnect, and the two servers are connected through RDMA or high-speed Ethernet. This scale has three advantages. First, a small cluster can quickly expose software and hardware adaptation issues, and debugging cycles are short. Second, the communication pattern between two servers differs from that of a large cluster, so the parallel strategy needs to be designed separately. Third, resource overhead is manageable, so the team can iterate repeatedly.
Readers should note that the conclusions in this article apply only to this configuration. Different models, sequence lengths, or networks will produce different results.
2. Parallel Strategy: Define the Topology Before Optimization
Large model training commonly uses three parallel approaches: data parallelism, tensor parallelism, and pipeline parallelism. At the 16-card scale, pure data parallelism requires each card to hold a full model replica, which creates high memory pressure. Pure model parallelism involves frequent cross-card communication and can easily reduce throughput.
This validation used a hybrid approach: data parallelism plus tensor parallelism. The eight cards in each server formed a tensor parallel group, splitting intra-layer parameters across those eight cards. Data parallelism was used across the two servers, and gradients were synchronized through all-reduce after each iteration.
The key to this topology is the distribution of communication time. Intra-server bandwidth between cards is much higher than inter-server network bandwidth, so most tensor parallel communication stays within a server. Inter-server gradient synchronization grows with model size and is the main bottleneck. The team adjusted batch size and gradient accumulation steps to keep the amount of data per synchronization within what the network could handle.
3. Framework Adaptation and Operator Mapping
Whether the training pipeline runs successfully depends heavily on how well the framework is adapted to the chip. Mainstream deep learning frameworks provide custom device backend interfaces. This validation extended a standard framework with an operator library for the chip.
There were three main adaptation challenges. The first was mapping common operators such as matrix multiplication, attention, and normalization to the chip’s compute units. The second was ensuring efficient memory allocation and data movement. The third was handling missing operators.
For missing operators, the team used a tiered fallback mechanism. When a high-level operator could not execute efficiently on the current chip, it was broken down into combinations of more basic instructions. For example, the fused attention operator was rewritten as a segmented implementation with manual on-chip cache management to reduce global memory access. This increased development effort but improved compatibility and made the training pipeline more stable.
4. Memory Optimization
Memory is the primary constraint in large model training. Model parameters plus optimizer states can easily exceed single-card capacity. This validation used two main techniques.
The first was mixed-precision training. Weights and gradients were stored in half precision, while optimizer states kept a full-precision copy, balancing speed and numerical stability.
The second was activation recomputation. Intermediate activations were not saved for every layer during the forward pass; they were recomputed during backpropagation. This trades additional computation for memory space.
The team also introduced a custom memory pool that merged tensor allocation requests of different sizes to reduce memory fragmentation.
The memory savings from these measures depend on model structure and batch size. This article does not provide a uniform percentage. Readers should measure peak memory in their own environments with the same tool and compare it against a baseline without the optimizations enabled.
5. Communication Optimization
Inter-server gradient synchronization is key to scaling efficiency. Bandwidth between two servers typically ranges from 25 Gbps to 100 Gbps, depending on the NIC and switch configuration.
The team tried gradient sparsification: only gradient elements above a threshold were transmitted, while untransmitted elements were kept locally for residual accumulation and sent in the next round. Sparsification can reduce communication volume but introduces accuracy risk. Its effect must be evaluated separately on the target task and validation set, with random seeds and baseline metrics recorded. A conclusion from one task cannot be directly generalized to other tasks.
Another measure was topology-aware scheduling. The training framework first probed inter-server bandwidth and paths, then adjusted the order of gradient aggregation so that data traveled along shorter paths. In a two-server scenario, two-level reduction can be used: complete local reduction within each server first, then merge the local results across servers, reducing cross-server data volume.
6. Stability: Checkpoints and Slow-Node Handling
A 400-step training run is not long, but hardware failures or software exceptions can still interrupt the job. The team saved model parameters, optimizer states, and random seeds every 50 steps. Checkpoint writes used asynchronous I/O and overlapped with computation. The extra overhead of asynchronous writes must be measured in the actual environment; this article does not provide a fixed value.
Slow nodes are another issue. When the per-step time of one card is clearly higher than average, the entire training job waits for it to finish. The team monitored the iteration time of each card and triggered alerts and adjustments when a card exceeded the average by 15%. The adjustment method depends on whether the framework supports rescheduling or shard adjustment. If supported, the compute share assigned to the slow card can be reduced, or microbatches can be rearranged. Every adjustment has a migration cost and should be recorded so the team can judge whether the adjustment is worthwhile.
In this 400-step run, the maximum fluctuation in single-step time stayed within 5%, and training completed successfully. This result represents only this run.
7. Environment Checklist Before Reproduction
Readers who want to reproduce a similar validation should first record the following information. Without it, results cannot be compared with other approaches.
- Framework name and version, plus the version of the custom device backend.
- Chip driver version and operator library version.
- Server model, number of cards per server, and inter-card interconnect.
- Inter-server network type, bandwidth, NIC model, and driver version.
- Parallel configuration, including tensor parallel and data parallel grouping, launch parameters, and key environment variables.
- Model parameter count, sequence length, batch size, optimizer type, learning rate, and warmup steps.
- Random seed, checkpoint save frequency, and write method.
- Performance measurement method, including the time window used for statistics, throughput formula, and baseline configuration.
Only when all of the above information is available are performance data comparable.
8. Lessons and Recommendations
The following lessons are useful in similar hardware environments.
- Keep tensor parallel groups within the same server as much as possible to reduce cross-server communication.
- Mixed precision must be paired with loss scaling. The scaling factor should be adjusted dynamically based on gradient statistics to prevent overflow or underflow.
- Do not rush to increase batch size. First validate gradient stability with a small batch, then increase it gradually while adjusting the learning rate warmup steps.
- Short validation runs do not require frequent checkpointing. For long-running jobs, asynchronous persistence should be used.
9. Next Steps for Scaling
This validation ran 400 steps on two servers with 16 cards. Supporting larger models and longer training requires work in three areas.
First, introduce pipeline parallelism to divide model layers into stages across different servers, reducing the synchronization pressure of pure data parallelism. Second, use multidimensional parallel combinations that schedule data, tensor, and pipeline parallelism together; this requires the framework to provide more flexible communication primitives. Third, strengthen chip-compiler co-design so that fused operators can be generated automatically by the compiler, reducing the amount of hand-written kernel work.
The results show that, under the current model scale and configuration, this pipeline can complete the training flow. They do not directly prove that the same approach applies to larger mainstream models; that requires separate validation.
Conclusion
The 400-step training run on two servers with 16 cards provides a reference engineering path. Small teams doing model fine-tuning or cloud service providers doing chip adaptation can learn from the topology design, memory techniques, and stability measures. When reproducing the work, first check the environment checklist, then measure performance using a consistent methodology, and finally determine whether the conclusions apply to your own scenario.
