When model parameters exceed the High Bandwidth Memory (HBM) capacity of a single GPU, the model must be partitioned and distributed across a cluster of interconnected accelerators.
For example, serving the unquantized Llama 3 70B model in 16-bit precision requires of static weight memory plus of dynamic KV cache—far exceeding the capacity of a single NVIDIA H100. Similarly, serving frontier models like Llama 3.1 405B ( in FP16) or DeepSeek-V3 671B requires sharding across at least 8 to 16 GPUs.
However, distributing neural network computation across multiple GPUs introduces a severe performance penalty: Inter-GPU Communication Latency. This lesson explores cluster topologies, communication bottlenecks, and the physical limits of NVLink vs PCIe.
1. The Scaling Threshold: When Does a Model Exceed Single-GPU Limits?
A model must be sharded across multiple GPUs whenever:
Hardware Allocation Rule of Thumb
| Model Size | Precision | Minimum Weight Memory | Target Single GPU (80GB) | Minimum Sharding Required |
|---|---|---|---|---|
| 8B (Llama 3) | FP16 (16-bit) | 16 GB | Fits easily (Leaves 60GB for KV cache) | 1 GPU (No Sharding) |
| 8B (Llama 3) | INT4 (4-bit) | 4 GB | Fits on budget GPU (RTX 4090 / L4) | 1 GPU (No Sharding) |
| 70B (Llama 3) | FP16 (16-bit) | 140 GB | Exceeds 80GB by 60 GB | 2 to 4 GPUs (Tensor Parallelism TP=2/4) |
| 70B (Llama 3) | INT4 (4-bit) | 35 GB | Fits on 1x 80GB GPU (Leaves 40GB KV) | 1 GPU (Quantized Single-Node) |
| 405B (Llama 3.1) | FP8 (8-bit) | 405 GB | Exceeds single node | 8 GPUs (TP=8 on HGX H100) |
| 405B (Llama 3.1) | FP16 (16-bit) | 810 GB | Exceeds 8x 80GB node | 16 GPUs (TP=8, PP=2 across 2 Nodes) |
2. Inter-GPU Communication: NVLink vs PCIe vs InfiniBand
When an LLM layer is sharded across GPUs, the intermediate activation tensors must be synchronized at every single transformer layer using collective communication primitives (such as All-Reduce or All-to-All).
The latency of this synchronization is governed by the physical interconnect:
Why PCIe Fails for Tensor Parallelism
In Tensor Parallelism (TP), every transformer layer executes two All-Reduce operations.
- For an 80-layer model generating 1 token: .
- Over NVLink 4 ( latency): 160 synchronizations take total.
- Over PCIe Gen4 ( latency): 160 synchronizations take total—completely destroying real-time streaming performance.
3. The Multi-GPU Parallelism Taxonomy
To scale across multiple GPUs and nodes, AI infrastructure relies on four distinct parallelism strategies:
4. Production Failure Modes and Troubleshooting Runbook
Failure Mode: NCCL Ring Deadlock During Multi-GPU Server Initialization
- Symptom: Launching a multi-GPU vLLM instance (
--tensor-parallel-size 8) hangs indefinitely on startup with no error messages, and GPU utilization sits at 100% on core 0. - Root Cause: The NVIDIA Collective Communications Library (NCCL) attempted to route inter-GPU communication over an misconfigured virtual network interface or blocked port (e.g. firewall blocking NCCL sockets).
- Resolution: Set the explicit NCCL network interface and debugging environment variables in your launch scripts:
5. Summary & Key Takeaways
- Sharding is Required for Large Models: Models exceeding 80GB of combined weight and KV cache memory must be distributed across multiple accelerators.
- Interconnect Bandwidth Dictates Performance: NVLink 4 () provides the ultra-low latency required for intra-layer Tensor Parallelism.
- Never Run Tensor Parallelism Over PCIe: 160 synchronization barriers per token over PCIe will degrade generation speed by up to .
- Combine Strategies for Scale: Frontier architectures combine Tensor Parallelism (intra-node NVLink) with Pipeline/Expert Parallelism (inter-node InfiniBand) to scale beyond 1,000 GPUs.