CUDA 2d stencil computations for the jacobi method

  • Authors:
  • José María Cecilia;José Manuel García;Manuel Ujaldón

  • Affiliations:
  • Computer Engineering and Technology Department, University of Murcia, Spain;Computer Engineering and Technology Department, University of Murcia, Spain;Computer Architecture Department, University of Malaga, Spain

  • Venue:
  • PARA'10 Proceedings of the 10th international conference on Applied Parallel and Scientific Computing - Volume Part I
  • Year:
  • 2010

Quantified Score

Hi-index 0.00

Visualization

Abstract

We are witnessing the consolidation of the GPUs streaming paradigm in parallel computing. This paper explores stencil operations in CUDA to optimize on GPUs the Jacobi method for solving Laplace's differential equation. The code keeps constant the access pattern through a large number of loop iterations, that way being representative of a wide set of iterative linear algebra algorithms. Optimizations are focused on data parallelism, threads deployment and the GPU memory hierarchy, whose management is explicit by the CUDA programmer. Experimental results are shown on Nvidia Teslas C870 and C1060 GPUs and compared to a counterpart version optimized on a quadcore Intel CPU. The speed-up factor for our set of GPU optimizations reaches 3-4x and the execution times defeat those of the CPU by a wide margin, also showing great scalability when moving towards a more sophisticated GPU architecture and/or more demanding problem sizes.