The BLAS API of BLASFEO: optimizing performance for small matrices

Gianluca Frison, Tommaso Sartor, Andrea Zanelli, Moritz Diehl
2/21/2019
cs.MS

Official code: giaf/blasfeo (426 stars, Assembly, last commit 2026-10-14).

Abstract

BLASFEO is a dense linear algebra library providing high-performance implementations of BLAS- and LAPACK-like routines for use in embedded optimization and other applications targeting relatively small matrices. BLASFEO defines an API which uses a packed matrix format as its native format.

Show full abstract

This format is analogous to the internal memory buffers of optimized BLAS, but it is exposed to the user and it removes the packing cost from the routine call. For matrices fitting in cache, BLASFEO outperforms optimized BLAS implementations, both open-source and proprietary. This paper investigates the addition of a standard BLAS API to the BLASFEO framework, and proposes an implementation switching between two or more algorithms optimized for different matrix sizes. Thanks to the modular assembly framework in BLASFEO, tailored linear algebra kernels with mixed column- and panel-major arguments are easily developed. This BLAS API has lower performance than the BLASFEO API, but it nonetheless outperforms optimized BLAS and especially LAPACK libraries for matrices fitting in cache. Therefore, it can boost a wide range of applications, where standard BLAS and LAPACK libraries are employed and the matrix size is moderate. In particular, this paper investigates the benefits in scientific programming languages such as Octave, SciPy and Julia.

View on arXivView PDF

Code Implementations(1)

giaf/blasfeoOfficial100%

Basic linear algebra subroutines for embedded optimization

426105Assembly, COct 6, 20161 months agoNOASSERTION
blashigh-performancelinear-algebra

Similar Papers

Cite this paper

@article{frison2019blas,
  title  = {The BLAS API of BLASFEO: optimizing performance for small matrices},
  author = {Gianluca Frison and Tommaso Sartor and Andrea Zanelli and Moritz Diehl},
  year   = {2019},
  eprint = {1902.08115},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/1902.08115}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/1902.08115.svg)](https://codeofpaper.com/paper/1902.08115)

Discussion