Skip to main content
QUICK REVIEW

[Paper Review] dMath: A Scalable Linear Algebra and Math Library for Heterogeneous GP-GPU Architectures

Steven Eliuk, Cameron Upright|arXiv (Cornell University)|Apr 5, 2016
Parallel Computing and Optimization TechniquesComputer Science34 references6 citations
TL;DR

dMath is a scalable, high-performance linear algebra and math library for heterogeneous GPU-GPU architectures that enables efficient distributed deep learning by persistently storing data in GPU memory, minimizing CPU-GPU transfers through advanced memory management, and supporting hybrid intranode/intranode parallelism with MPI and GPU-Direct RDMA. It achieves leading strong and weak scaling in distributed DNN training, outperforming existing frameworks by abstracting low-level parallelism while maintaining high productivity.

ABSTRACT

A new scalable parallel math library, dMath, is presented in this paper that demonstrates leading scaling when using intranode, or internode, hybrid-parallelism for deep-learning. dMath provides easy-to-use distributed base primitives and a variety of domain-specific algorithms. These include matrix multiplication, convolutions, and others allowing for rapid development of highly scalable applications, including Deep Neural Networks (DNN), whereas previously one was restricted to libraries that provided effective primitives for only a single GPU, like Nvidia cublas and cudnn or DNN primitives from Nervana neon framework. Development of HPC software is difficult, labor-intensive work, requiring a unique skill set. dMath allows a wide range of developers to utilize parallel and distributed hardware easily. One contribution of this approach is that data is stored persistently on the GPU hardware, avoiding costly transfers between host and device. Advanced memory management techniques are utilized, including caching of transferred data and memory reuse through pooling. A key contribution of dMath is that it delivers performance, portability, and productivity to its specific domain of support. It enables algorithm and application programmers to quickly solve problems without managing the significant complexity associated with multi-level parallelism.

Motivation & Objective

  • To address the challenge of developing high-performance, scalable deep learning applications on heterogeneous GPU-GPU clusters without requiring deep expertise in low-level parallel programming.
  • To reduce the performance bottleneck caused by frequent CPU-GPU memory transfers by persistently caching data in GPU device memory.
  • To provide a high-level, user-transparent programming model that abstracts multi-GPU and distributed computing complexity while supporting mixed-precision arithmetic and efficient data reorganization.
  • To enable strong and weak scaling in distributed deep neural network training using hybrid parallelism (MPI + CUDA) on COTS GPU-dense clusters.
  • To improve performance and productivity in HPC and machine learning workloads by integrating advanced memory management, caching, and optimized communication via GPU-Direct RDMA.

Proposed method

  • dMath employs persistent GPU memory storage to keep operands resident on the GPU, eliminating repeated CPU-GPU data transfers and reducing latency.
  • It implements a client-server model where the user’s main thread drives backend computations, and data remains cached in GPU memory across operations.
  • The library uses an object-oriented design with abstract matrix and vector classes that support multiple precisions (single, double, half), layouts, and computational targets (CPU, GPU, distributed).
  • It provides a data reorganization and replication service to efficiently remap matrices between different parallel layouts, optimizing performance across pipeline stages in DNNs.
  • dMath integrates with MPI and leverages GPU-Direct Remote Direct Memory Access (RDMA) to accelerate inter-GPU communication, reducing latency and increasing bandwidth.
  • It includes advanced memory management techniques such as data caching, memory pooling, and efficient type conversion to support mixed-precision operations and lossy compression.

Experimental results

Research questions

  • RQ1How can a linear algebra library achieve leading strong and weak scaling in distributed deep learning workloads on GPU-dense clusters?
  • RQ2To what extent can persistent GPU memory storage and advanced memory management reduce CPU-GPU data transfer overhead in large-scale machine learning?
  • RQ3Can a high-level abstraction layer effectively hide the complexity of hybrid parallelism (MPI + CUDA) while maintaining high performance in distributed DNN training?
  • RQ4How does GPU-Direct RDMA improve inter-GPU communication performance compared to traditional MPI over PCIe in multi-GPU systems?
  • RQ5What role does data reorganization and layout transformation play in optimizing performance across sequential operations in deep neural network pipelines?

Key findings

  • dMath demonstrates superior strong and weak scaling compared to open-source frameworks, with experimental results showing improved performance on distributed DNN training via the Expresso framework.
  • The library achieves significant performance gains by persistently caching data in GPU memory, eliminating costly CPU-GPU transfers and reducing latency in iterative algorithms like GEMM.
  • GPU-Direct RDMA integration with OpenMPI and MVAPICH2 reduced communication latency and increased bandwidth, enabling efficient inter-node and intra-node GPU communication.
  • The data reorganization and replication service enables efficient layout transformations between parallel data distributions, optimizing performance across DNN pipeline stages.
  • dMath supports mixed-precision operations (half, single, double) with efficient type conversion and lossy compression, reducing memory bandwidth usage without sacrificing accuracy in suitable numerical algorithms.
  • The library enables high productivity by abstracting low-level details of MPI, CUDA, and data layout management, allowing developers to focus on algorithmic design rather than system-level complexity.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.