Cache Optimization and Performance Modeling of Batched, Small, and Rectangular Matrix Multiplication on Intel, AMD, and Fujitsu Processors
-
Published:2023-09-19
Issue:3
Volume:49
Page:1-29
-
ISSN:0098-3500
-
Container-title:ACM Transactions on Mathematical Software
-
language:en
-
Short-container-title:ACM Trans. Math. Softw.
Author:
Deshmukh Sameer1ORCID,
Yokota Rio1ORCID,
Bosilca George2ORCID
Affiliation:
1. School of Computing, Tokyo Institute of Technology, AIST, Japan
2. Innovative Computing Laboratory, University of Tennessee at Knoxville, USA
Abstract
Factorization and multiplication of dense matrices and tensors are critical, yet extremely expensive pieces of the scientific toolbox. Careful use of low rank approximation can drastically reduce the computation and memory requirements of these operations. In addition to a lower arithmetic complexity, such methods can, by their structure, be designed to efficiently exploit modern hardware architectures. The majority of existing work relies on batched BLAS libraries to handle the computation of many small dense matrices. We show that through careful analysis of the cache utilization, register accumulation using SIMD registers and a redesign of the implementation, one can achieve significantly higher throughput for these types of batched low-rank matrices across a large range of block and batch sizes. We test our algorithm on three CPUs using diverse ISAs – the Fujitsu A64FX using ARM SVE, the Intel Xeon 6148 using AVX-512, and AMD EPYC 7502 using AVX-2, and show that our new batching methodology is able to obtain more than twice the throughput of vendor optimized libraries for all CPU architectures and problem sizes.
Funder
JSPS KAKENHI
Joint Usage/Research Center for Interdisciplinary Large-scale Information Infrastructures in Japan
Publisher
Association for Computing Machinery (ACM)
Subject
Applied Mathematics,Software
Reference64 articles.
1. High-performance Tensor Contractions for GPUs
2. On the Development of Variable Size Batched Computation for Heterogeneous Parallel Architectures
3. An analytic performance model for overlapping execution of memory-bound loop kernels on multicore CPUs;Afzal Ayesha;arXiv:2011.00243 [cs],2020
4. High Performance Computing
5. ECM modeling and performance tuning of SpMV and lattice QCD on A64FX;Alappat Christie;arXiv:2103.03013 [hep-lat],2021