Accelerating Sparse DNNs Based on Tiled GEMM

Cong Guo, Fengchen Xue, Jingwen Leng, Yuxian Qiu, Yue Guan, Weihao Cui, Quan Chen, Minyi Guo · DOI

Introduction

Deep Learning models continue to grow in size, necessitating pruning techniques to remove unimportant weights for improved efficiency. However, a persistent challenge exists: the trade-off between accuracy and hardware performance. Unstructured pruning offers high accuracy by removing individual weights but leads to irregular memory access patterns that GPUs—optimized for dense matrix multiplications (GEMM)—cannot execute efficiently. Conversely, structured pruning removes entire blocks or rows, ensuring hardware speed at the cost of significant accuracy degradation.

Tile-Wise and Tile-Vector-Wise Sparsity

To bridge this gap, this research introduces Tile-Wise (TW) Sparsity. Modern GPU accelerators process large matrices by subdividing them into smaller "tiles" for parallel execution. TW pruning exploits this hierarchy by pruning entire rows or columns within these specific tiles. This approach maintains regular computation inside each tile, allowing the use of high-speed dense math units, while the global irregularity across different tiles preserves the model's overall accuracy.

Tile-vector sparsity pattern illustrating the alignment with hardware tiling structures.

The researchers further developed a Tile-Vector-Wise (TVW) Hybrid pattern. This method layers TW sparsity with NVIDIA’s hardware-native 2:4 structured sparsity. In this configuration, TW handles coarse-grained pruning at the memory level, while the 2:4 pattern manages fine-grained pruning at the register level within the Tensor Core.

Hardware Implementation

Efficient execution is achieved through a custom CUDA kernel utilizing a Compressed Tile Offset (CTO). This mechanism allows the GPU to skip pruned regions entirely, avoiding the overhead typically associated with traditional sparse formats like CSR.

NVIDIA Tensor Core architecture supporting 2:4 structured sparsity and the proposed sparse execution flow.

By exploiting the orthogonality of memory-level (tile-wise) and register-level (vector-wise) pruning, the system can achieve deeper sparsity without the typical accuracy collapse. Load imbalance, a common issue in sparse computing where some cores finish early, is mitigated through batching tile computations and concurrent kernel execution.

Performance Evaluation

The proposed methods were evaluated on an NVIDIA A100 GPU across various benchmarks, including ImageNet (VGG, ResNet) and GLUE/SQuAD (BERT).

Key results include:

  • 1.85x average speedup over original dense models.
  • 22.18x speedup over element-wise unstructured sparsity.
  • Pareto-optimal performance: The TVW pattern consistently provided the best speed-to-accuracy trade-off. For instance, BERT on MNLI reached 75% sparsity with only a ~1.6% accuracy loss.

Conclusion

Tile-Wise sparsity represents a significant step toward making sparse DNNs practical on commodity hardware. By aligning pruning patterns with the tiling hierarchy of modern GPUs, researchers can leverage the throughput of dense accelerators while maintaining the flexibility needed for high accuracy. Future work will explore dynamic activation pruning and further automation of tile-size hyperparameter tuning.

Summary updated

BibTeX
@article{guo2024accelerating,
  author = {Cong Guo and Fengchen Xue and Jingwen Leng and Yuxian Qiu and Yue Guan and Weihao Cui and Quan Chen and Minyi Guo},
  title = {{Accelerating Sparse DNNs Based on Tiled GEMM}},
  journal = {IEEE Transactions on Computers},
  year = {2024},
  url = {https://openreview.net/forum?id=NRvHy8TmU4},
}
Figure