Expressing Sparse Matrix Computations for Productive Performance on Spatial Architectures

10/12/2018
by   Hongbo Rong, et al.
0

This paper addresses spatial programming of sparse matrix computations for productive performance. The challenge is how to express an irregular computation and its optimizations in a regular way. A sparse matrix has (non-zero) values and a structure. In this paper, we propose to classify the implementations of a computation on a sparse matrix into two categories: (1) structure-driven, or top-down, approach, which traverses the structure with given row and column indices and locates the corresponding values, and (2) values-driven, or bottom-up, approach, which loads and processes the values in parallel streams, and decodes the structure for the values' corresponding row and column indices. On a spatial architecture like FPGAs, the values-driven approach is the norm. We show how to express a sparse matrix computation and its optimizations for a values-driven implementation. A compiler automatically synthesizes a code to decode the structure. In this way, programmers focus on optimizing the processing of the values, using familiar optimizations for dense matrices, while leaving the complex, irregular structure traversal to an automatic compiler. We also attempt to regularize the optimizations of the reduction for a dynamic number of values, which is common in a sparse matrix computation.

READ FULL TEXT

page 1

page 2

page 3

page 4

research
07/04/2023

SpComp: A Sparsity Structure-Specific Compilation of Matrix Operations

Sparse matrix operations involve a large number of zero operands which m...
research
03/16/2018

Leveraging Sparsity to Speed Up Polynomial Feature Expansions of CSR Matrices Using K-Simplex Numbers

We provide an algorithm that speeds up polynomial and interaction featur...
research
11/24/2021

Vectorizing Sparse Matrix Codes with Dependency Driven Trace Analysis

Sparse computations frequently appear in scientific simulations and the ...
research
04/28/2022

Programming Matrices as Staged Sparse Rows to Generate Efficient Matrix-free Differential Equation Solver

Solving differential equations is a critical task in scientific computin...
research
03/04/2023

Optimization of SpGEMM with Risc-V vector instructions

The Sparse GEneral Matrix-Matrix multiplication (SpGEMM) C = A × B is a ...
research
07/26/2020

Optimizing Block-Sparse Matrix Multiplications on CUDA with TVM

We implemented and optimized matrix multiplications between dense and bl...
research
01/21/2022

Bit-GraphBLAS: Bit-Level Optimizations of Matrix-Centric Graph Processing on GPU

In a general graph data structure like an adjacency matrix, when edges a...

Please sign up or login with your details

Forgot password? Click here to reset