HitGNN: High-throughput GNN Training Framework on CPU+Multi-FPGA Heterogeneous Platform

Yi-Chien Lin, Bingyi Zhang, Viktor K. Prasanna

Abstract

As the size of real-world graphs increases, training Graph Neural Networks (GNNs) has become time-consuming and requires acceleration. While previous works have demonstrated the potential of utilizing FPGA for accelerating GNN training, few works have been carried out to accelerate GNN training with multiple FPGAs due to the necessity of hardware expertise and substantial development effort. To this end, we propose HitGNN, a framework that enables users to effortlessly map GNN training workloads onto a CPU-Multi-FPGA platform for acceleration. HitGNN consists of high-level APIs, a software generator, and an accelerator generator with optimized datapath and memory organization. Compared with state-of-the-art multi-GPU platforms, HitGNN achieves up to 27.21x bandwidth efficiency and up to 4.26x speedup while demonstrating good scalability to 16 FPGAs.

Introduction

Training Graph Neural Networks (GNNs) on massive real-world graphs presents a significant computational challenge. While GPUs are the standard workhorse, they often struggle with the irregular, sparse memory access patterns inherent in graph data, leading to poor memory bandwidth utilization. FPGAs (Field-Programmable Gate Arrays) offer a promising alternative because their hardware can be customized to match specific data access patterns. However, deploying GNN training on multi-FPGA systems is notoriously difficult due to the required hardware expertise, the complexity of workload balancing, and the development effort needed to map complex algorithms like DistDGL or PaGraph to hardware.

HitGNN bridges this gap by automating the deployment of GNN training onto heterogeneous CPU+Multi-FPGA platforms. By combining high-level APIs with automated hardware generation and smart workload balancing, it achieves significant performance gains over state-of-the-art multi-GPU systems.

Methods

The HitGNN framework is built upon three main pillars designed to abstract hardware complexity while maximizing performance:

  1. High-Level APIs: Users define GNN models (e.g., GCN, GraphSAGE) and training algorithms using Python-like APIs, requiring only a few lines of code.
  2. Automated Generators:
    • Software Generator: Creates the host program to manage mini-batch sampling, CPU-FPGA communication, and workload balancing.
  3. Accelerator Generator: Utilizes a Design Space Exploration (DSE) engine to automatically determine optimal hardware parameters (e.g., processing elements) based on available FPGA resources.
  4. Multi-FPGA Optimizations:
    • Two-Stage Task Scheduling: Implements a dynamic scheduler to redistribute mini-batches from busy to idle FPGAs, preventing workload imbalance.
  5. Direct CPU Data Fetching: Leverages the host CPU's large memory as a central hub. FPGAs pull missing vertex features directly via PCIe, reducing the overhead associated with complex chip-to-chip communication.
HitGNN framework workflow from user-defined GNN models to multi-FPGA deployment.

Key Insights and Results

The evaluation of HitGNN on large-scale datasets like Reddit, Yelp, Amazon, and ogbn-products revealed several critical insights. First, customization often outweighs raw peak power; despite having lower peak TFLOPS than high-end GPUs, HitGNN's hardware-specific optimization for GNN memory access patterns leads to higher effective performance. Second, the framework's DSE engine identifies and mitigates shifting bottlenecks between the "Aggregation" and "Update" steps of GNN layers.

System overview of HitGNN showing the interaction between Host CPU and FPGAs during training.

Empirical results show that HitGNN achieves a geometric mean speedup of 2.11× to 2.34× over a 4-GPU baseline, with peak speedups reaching 4.26×. Notably, it demonstrates up to 27.21× higher bandwidth efficiency, performing more work with significantly less memory bandwidth. The system also exhibits near-linear scalability up to 16 FPGAs, proving its capability for industrial-scale graph processing.

Conclusion

HitGNN successfully automates the deployment of GNN training on CPU+Multi-FPGA platforms, overcoming traditional barriers of hardware expertise and development effort. While the current implementation identifies CPU memory bandwidth as a potential future bottleneck (around 12-16 FPGAs), future work in data prefetching and high-speed interconnects (like SmartNICs) could further extend these performance gains.

Summary updated

Abstract

As the size of real-world graphs increases, training Graph Neural Networks (GNNs) has become time-consuming and requires acceleration. While previous works have demonstrated the potential of utilizing FPGA for accelerating GNN training, few works have been carried out to accelerate GNN training with multiple FPGAs due to the necessity of hardware expertise and substantial development effort. To this end, we propose HitGNN, a framework that enables users to effortlessly map GNN training workloads onto a CPU-Multi-FPGA platform for acceleration. In particular, HitGNN takes the user-defined synchronous GNN training algorithm, GNN model, and platform metadata as input, determines the design parameters based on the platform metadata, and performs hardware mapping onto the CPU+Multi-FPGA platform, automatically. HitGNN consists of the following building blocks: (1) high-level application programming interfaces (APIs) that allow users to specify various synchronous GNN training algorithms and GNN models with only a handful of lines of code; (2) a software generator that generates a host program that performs mini-batch sampling, manages CPU-FPGA communication, and handles workload balancing among the FPGAs; (3) an accelerator generator that generates GNN kernels with optimized datapath and memory organization. We show that existing synchronous GNN training algorithms such as DistDGL and PaGraph can be easily deployed on a CPU+Multi-FPGA platform using our framework, while achieving high training throughput. Compared with the state-of-the-art frameworks that accelerate synchronous GNN training on a multi-GPU platform, HitGNN achieves up to 27.21x bandwidth efficiency, and up to 4.26x speedup using much less compute power and memory bandwidth than GPUs. In addition, HitGNN demonstrates good scalability to 16 FPGAs on a CPU+Multi-FPGA platform.
BibTeX
@article{lin2024hitgnn,
  author = {Yi-Chien Lin and Bingyi Zhang and Viktor K. Prasanna},
  title = {{HitGNN: High-throughput GNN Training Framework on CPU+Multi-FPGA Heterogeneous Platform}},
  journal = {IEEE Trans. Parallel Distributed Syst.},
  year = {2024},
  url = {https://openreview.net/forum?id=vhDY3Aj9Bt},
}
Figure