Skip to main content
QUICK REVIEW

[Paper Review] A GEMM-based direct solver for finite-difference Poisson problems in non-uniform grids

Pedro Filipe da Silva Costa, Duarte Palancha|arXiv (Cornell University)|Mar 10, 2026
Parallel Computing and Optimization TechniquesComputer Science0 citations
TL;DR

This paper introduces a direct Poisson solver for 3D non-uniform grids that diagonalizes the operator in two directions via eigen-decomposition and solves the third direction directly, with forward/backward transforms implemented as GEMMs for CPU/GPU efficiency.

ABSTRACT

We present a direct Poisson solver for massively parallel simulations on three-dimensional Cartesian grids with non-uniform spacing. The method uses a tensor-based formulation in which the operator is diagonalized numerically along two directions through one-dimensional eigendecompositions, while the third direction is solved directly. The resulting dense transforms are evaluated efficiently as GEMMs (General Matrix--Matrix Multiplications), allowing many independent one-dimensional operations to be combined into matrix-matrix products that map well to modern CPU and GPU hardware. For uniform grids, the method reduces to the classical eigenfunction-expansion approach, and it naturally supports hybrid combinations of FFT-based and GEMM-based transforms depending on grid uniformity. After coupling the solver to an incompressible Navier-Stokes code, we assess its accuracy and performance against geometric multigrid and block cyclic reduction with FFT diagonalization. The results show that the proposed method is robust and consistently achieves the best time-to-solution. In strong scaling, the more compute-intensive GEMM-based variants attain higher parallel efficiency by better amortizing communication costs, while weak scaling highlights the expected trade-off between FFT-based and dense-transform formulations. Overall, the method enables efficient high-resolution stretched-mesh simulations on modern heterogeneous systems.

Motivation & Objective

  • Motivate the need for fast Poisson solvers to enforce incompressibility in DNS of incompressible flows.
  • Extend eigenfunction-based direct solvers to non-uniform grids while maintaining GPU-friendly kernels.
  • Develop a GEMM-based implementation that integrates with existing CaNS infrastructure and supports hybrid synthesis (FFT for uniform directions, GEMM for non-uniform directions).
  • Evaluate performance against state-of-the-art methods (geometric multigrid and block cyclic reduction with FFT).
  • Demonstrate scalability (strong and weak) on CPUs and GPUs for high-resolution stretched meshes.

Proposed method

  • Formulate the 1D Poisson operator on non-uniform grids as a tridiagonal system and symmetrize it via a diagonal scaling D to obtain a symmetric surrogate T̃ with T̃ = D^{1/2} T D^{-1/2}.
  • Eigendecompose the symmetric surrogate T̃ = Q̃ Λ Q̃^T and recover Q from Q = D^{-1/2} Q̃, Q^{-1} = Q̃^T D^{1/2}.
  • Extend to 3D by Kronecker sums: T = T_x ⊗ I ⊗ I + I ⊗ T_y ⊗ I + I ⊗ I ⊗ T_z; diagonalize along x and y (T_x, T_y) and solve a set of independent 1D tridiagonal problems along z.
  • Forward eigenbasis transform and backward inverse transforms are performed in x and y directions using GEMMs (or FFTs for uniform directions); along z, a direct tridiagonal solve (TDMA) is used.
  • The method preserves the same domain decomposition and communication pattern as FFT-based diagonalization, enabling hybrid synthesis (FFT for uniform grids, GEMM for non-uniform grids).
  • The Poisson solver is integrated with a Navier–Stokes solver using a fractional-step RK3 scheme with optional implicit diffusion solved via the same Poisson-based/Helmholtz framework.

Experimental results

Research questions

  • RQ1Can a GEMM-based diagonalization along two directions provide competitive or superior time-to-solution for 3D Poisson problems on non-uniform grids compared to FFT-based and multigrid approaches?
  • RQ2How does the hybrid FFT/GEMM approach perform on CPUs and GPUs in terms of strong and weak scaling for stretched meshes?
  • RQ3What is the trade-off between flexibility (non-uniform grids) and asymptotic cost when using GEMM-based transforms as the problem size grows?
  • RQ4How does the solver integrate with an incompressible Navier–Stokes workflow and what is the overhead of non-uniform-grid capability on modern hardware?

Key findings

  • The GEMM-based approach delivers the best time-to-solution on a single CPU core among tested alternatives, especially on strongly graded meshes.
  • Strong scaling on CPU and GPU shows the compute-intensive GEMM-based variants better amortize transpose and communication overheads than FFT-heavy variants.
  • Weak scaling reveals a trade-off: using FFTs along the growing direction yields milder time growth, while GEMM-based transforms incur higher cost as resolution increases.
  • On GPUs, full non-uniform-grid capability incurs only moderate overhead and maintains strong scaling up to many GPUs.
  • Overall, the method enables major wall-clock savings for turbulent-flow simulations on stretched meshes compared to uniform-grid runs, with robust performance in heterogeneous hardware.

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.