"Comparing Network Architectures: InfiniBand vs. RoCE and the LightLLM Framework"
Hatched by Kevin Di
Feb 25, 2024
4 min read
17 views
"Comparing Network Architectures: InfiniBand vs. RoCE and the LightLLM Framework"
Introduction:
In the world of networking, choosing the right architecture is crucial for achieving optimal performance and reducing latency. This article will delve into two popular network architectures, InfiniBand and RoCE, and also explore the innovative LightLLM framework. By understanding their key features, benefits, and use cases, readers can make informed decisions when selecting a network architecture for their specific needs.
InfiniBand vs. RoCE: Reducing End-to-End Communication Latency
One of the critical technologies in reducing latency between multiple machines and multiple GPUs is RDMA (Remote Direct Memory Access). RDMA allows one host to directly access the memory of another host, bypassing the operating system kernel. There are four ways to implement RDMA: InfiniBand, RoCEv1, RoCEv2, and iWARP. RoCEv1 has become obsolete, and iWARP is less commonly used. Currently, the two main solutions for RDMA technology are InfiniBand and RoCEv2.
Both InfiniBand and RoCEv2 bypass the kernel protocol stack, resulting in significantly improved latency performance compared to traditional TCP/IP networks. In lab tests for scenarios where communication is within the same cluster, the end-to-end latency at the application layer can be reduced from 50us (TCP/IP) to 5us (RoCE) or 2us (InfiniBand) when bypassing the kernel protocol stack.
InfiniBand Network Architecture
The key components of an InfiniBand network include the Subnet Manager (SM), InfiniBand network cards, InfiniBand switches, and InfiniBand cables. In 2021, NVIDIA introduced the Quantum-2 series switches with a speed of 400Gbps (64*400G). These switches have 32 800G OSFP (Octal Small Form Factor Pluggable) ports, which need to be converted into 64 400G QSFP ports using cables. InfiniBand switches do not run any routing protocols. The forwarding table of the entire network is calculated and distributed by the centralized Subnet Manager (SM). In addition to the forwarding table, the SM is responsible for managing InfiniBand subnet configurations such as Partition and QoS. InfiniBand networks require dedicated cables and optical modules for interconnection between switches and between switches and network cards. InfiniBand's Adaptive Routing, based on per-packet dynamic routing, ensures optimal network utilization in ultra-large-scale networks. InfiniBand networks have been widely adopted in the industry for large GPU clusters, including Baidu Intelligent Cloud and Microsoft Azure.
InfiniBand Market and Suppliers
The major InfiniBand network solution providers and equipment suppliers in the market include NVIDIA, Intel Corporation, Cisco Systems, and Hewlett Packard Enterprise. NVIDIA holds the highest market share, accounting for over 70% of the market. NVIDIA offers various InfiniBand adapters, switches, and related products. Intel Corporation is another important InfiniBand supplier, providing a range of InfiniBand network products and solutions. Cisco Systems, a well-known network equipment manufacturer, also offers InfiniBand switches and other related products. Hewlett Packard Enterprise (HPE), a large IT company, provides various InfiniBand network solutions and products, including adapters, switches, and servers.
RoCE: A More Universal and Cost-Effective Alternative
RoCE stands out as a more versatile and cost-effective alternative to InfiniBand. It can be used not only in high-performance RDMA networks but also in traditional Ethernet networks. However, configuring parameters related to Headroom, PFC (Priority Flow Control), and ECN (Explicit Congestion Notification) on switches can be more complex. In ultra-large-scale scenarios, such as those with thousands of GPUs, the throughput performance of RoCE networks may be slightly weaker than InfiniBand networks.
Key Suppliers of RoCE Solutions
Several switch manufacturers support RoCE, with notable companies including H3C and Huawei. NVIDIA's ConnectX series of network cards currently holds a high market share in the RoCE-compatible network card market.
LightLLM: A Python-Based Lightweight High-Performance LLM Inference Framework
LightLLM introduces a more fine-grained kv cache management algorithm called TokenAttention and designs an Efficient Router scheduling implementation that works efficiently with TokenAttention. With the interaction between TokenAttention and Efficient Router, LightLLM achieves higher throughput compared to vLLM and Text Generation Inference in most scenarios. In some cases, LightLLM can provide up to a four-fold performance improvement.
Conclusion:
Choosing the right network architecture is crucial for achieving optimal performance and reducing latency in various computing scenarios. InfiniBand and RoCE offer different advantages, with InfiniBand excelling in ultra-large-scale GPU clusters and RoCE providing a more versatile and cost-effective solution. Additionally, the introduction of the LightLLM framework showcases the potential for innovation in the field of network inference. When making decisions about network architectures, it is essential to consider factors such as performance requirements, scalability, and cost-effectiveness.
Actionable Advice:
- Assess your specific network requirements: Understand the scale and performance demands of your computing infrastructure to determine whether InfiniBand or RoCE is the best fit.
- Consider cost-effectiveness: Evaluate the overall cost of implementing and maintaining the network architecture, including equipment, cables, and compatibility with existing infrastructure.
- Explore innovative frameworks: Stay updated on emerging frameworks like LightLLM that offer significant performance improvements, as they may provide unique advantages for your specific use cases.
By carefully considering the features, benefits, and use cases of InfiniBand, RoCE, and the LightLLM framework, organizations can make informed decisions to optimize their network performance and meet their computing needs.
Sources
Hatch New Ideas with Glasp AI 🐣
Glasp AI allows you to hatch new ideas based on your curated content. Let's curate and create with Glasp AI :)
Start Hatching 🐣