Faster solving of many tiny linear systems on Nvidia GPUs for material laws
Accelerating the Solving of Many Tiny General Linear Systems on GPUs: Application to Constitutive Laws
Distributed, Parallel, and Cluster Computing
Summary
Solving many very small math problems called linear systems is important for simulating materials, but it can be slow on graphics processors (GPUs). The authors studied different ways to solve these tiny problems quickly on GPUs, especially for updating material models during simulations. They found that specially designed methods can be much faster, sometimes over six times quicker than existing tools, depending on the problem size and context. Their work helps speed up material simulations that rely on solving many small independent math problems in parallel.
What this means in practice
- •For simulation software engineers: Speed up material model evaluations in finite element simulations by using specialized GPU solvers for tiny linear systems.
- •For graphics hardware developers: Design GPU hardware features favoring efficient tiny matrix factorizations for scientific computing applications.
Authors
Tristan Chenaille, Francesca Cuteri, Rapha{ë}l Prat, Guillaume Latu, Thomas Helfer
Abstract
Many applications require solving large numbers of independent linear systems on GPUs. While this need is well addressed for small to large systems, tiny ones, understood here as systems of dimension below 32, remain challenging. This is especially relevant in constitutive law evaluation, where millions of integration points are handled independently, and where each constitutive update generally relies on a Newton iterative method. Each iteration then requires the double-precision solution of a tiny general square linear system using LU factorization with partial pivoting (LUpp). The present study was conducted within a closed-source prototype, which serves as a demonstrator for porting to NVIDIA GPUs constitutive law evaluations currently provided on CPUs by TFEL/MFront, an open-source code generation tool for material knowledge. We compare several double-precision LUpp solvers, including implementations from GPU linear algebra libraries as well as custom-designed CUDA kernels. The comparison is performed first on large batches of standalone linear systems, and then within the full constitutive-law evaluation workflow, where each integration point requires a sequence of distinct linear systems, one per iteration of its own Newton loop. The study shows that the best LUpp solving strategy strongly depends on several factors including system size and application context. We discuss several key aspects, including register pressure, occupancy, the ability to invoke the LUpp solver directly from device code, and whether assigning several threads to each system is the most efficient strategy. Experiments on an NVIDIA H100 GPU show that the specialized LUpp solvers proposed in this work can outperform existing state-of-the-art approaches for this class of workloads, with speedups of up to 6.5x over cuSolverDx, and up to 17.7x over MAGMA.