DOI QR코드

DOI QR Code

A Study on GPU Computing of Bi-conjugate Gradient Method for Finite Element Analysis of the Incompressible Navier-Stokes Equations

유한요소 비압축성 유동장 해석을 위한 이중공액구배법의 GPU 기반 연산에 대한 연구

  • Yoon, Jong Seon (Dept. of Mechanical Engineering, Seoul Nat'l Univ. of Science and Technology) ;
  • Jeon, Byoung Jin (Integrative Cardiovascular Imaging Research Center, Yonsei Cardiovascular Center, College of Medicine, Yonsei Univ.) ;
  • Jung, Hye Dong (Embedded & Software Research Center, Korea Electronics Technology Institute) ;
  • Choi, Hyoung Gwon (Dept. of Mechanical and Automotive Engineering, Seoul Nat'l Univ. of Science and Technology)
  • 윤종선 (서울과학기술대학교 기계공학과) ;
  • 전병진 (연세대학교 의과대학 심혈관영상연구센터) ;
  • 정혜동 (전자부품연구원 임베디드&소프트웨어 연구센터) ;
  • 최형권 (서울과학기술대학교 기계.자동차공학과)
  • Received : 2016.04.13
  • Accepted : 2016.06.08
  • Published : 2016.09.01

Abstract

A parallel algorithm of bi-conjugate gradient method was developed based on CUDA for parallel computation of the incompressible Navier-Stokes equations. The governing equations were discretized using splitting P2P1 finite element method. Asymmetric stenotic flow problem was solved to validate the proposed algorithm, and then the parallel performance of the GPU was examined by measuring the elapsed times. Further, the GPU performance for sparse matrix-vector multiplication was also investigated with a matrix of fluid-structure interaction problem. A kernel was generated to simultaneously compute the inner product of each row of sparse matrix and a vector. In addition, the kernel was optimized to improve the performance by using both parallel reduction and memory coalescing. In the kernel construction, the effect of warp on the parallel performance of the present CUDA was also examined. The present GPU computation was more than 7 times faster than the single CPU by double precision.

본 연구에서는 GPU를 이용한 비압축성 유동장의 병렬연산을 위하여, P2P1 유한요소를 이용한 분리 알고리즘 내의 행렬 해법인 이중공액구배법(Bi-Conjugate Gradient)의 CUDA 기반 알고리즘을 개발하였다. 개발된 알고리즘을 이용해 비대칭 협착관 유동을 해석하고, 단일 CPU와의 계산시간을 비교하여 GPU 병렬 연산의 성능 향상을 측정하였다. 또한, 비대칭 협착관 유동 문제와 다른 행렬 패턴을 가지는 유체구조 상호작용 문제에 대하여 이중공액구배법 내의 희소 행렬과 벡터의 곱에 대한 GPU의 병렬성능을 확인하였다. 개발된 코드는 희소 행렬의 1개의 행과 벡터의 내적을 병렬 연산하는 커널(Kernel)로 구성되며, 최적화는 병렬 감소 연산(Parallel Reduction), 메모리 코얼레싱(Coalescing) 효과를 이용하여 구현하였다. 또한, 커널 생성 시 워프(Warp)의 크기에 따른 성능 차이를 확인하였다. 표준예제들에 대한 GPU 병렬연산속도는 CPU 대비 약 7배 이상 향상됨을 확인하였다.

Keywords

References

  1. Temem, O. and Jalby, W., 1992, "Charact-erizing the Behavior of Sparse Algorithms on Caches," Proceedings of the 1992 ACM/IEEE Conference on Supercomputing, pp. 578-587.
  2. Richard, V., Demmel, J. W., Yelick, K. A., Kamil, S., Nishtala, R. and Lee, B. J., 2002, "Performance Optimizations and Bounds for Sparse Matrix-Vector Multiply," Proceedings of the IEEE/ACM SC2002 Conference.
  3. Jeon, B. J. and Choi, H. G., 2014, "Comparison of Message Passing Interface and Hybrid Programming Models to Solve Pressure Equation in Distributed Memory System," Trans. Korean Soc. Mech. Eng. B, Vol. 39, No. 2, pp. 191-197. https://doi.org/10.3795/KSME-B.2015.39.2.191
  4. https://www.khronos.org/opencl/
  5. Bell, N. and Garlandy, M., 2008, "Ecient Sparse Matrix-Vector Multiplication on CUDA," NVIDIA Technical Report NVR-2008-004.
  6. Feng, X., Hai Jin, Zheng, R., Hu, K., Zeng, J. and Shao, Z., 2011, "Optimization of Sparse Matrix-Vector Multiplication with Variant CSR on GPUs," 22 2011 IEEE 17th International Conference on Parallel and Distributed Systems.
  7. Ashari, A., Sedaghati, N., Eisenlohr, J., Paqrthasarathy, S. and Sadayappan, P., 2014, "Fast Sparse Matrix-Vector Multiplication on GPUs for Graph Applications," Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis, pp. 781-792.
  8. Park, T. J., Woo, J. M. and Kim, C. H., 2011, "CUDA-based Parallel Bi-Conjugate Gradient Matrix Solver for BioFET Simulation," Journal of the Institute of Electronics Engineers of Korea, Vol. 48, No. 1, pp. 90-100.
  9. Chang, T. K., Park, J. S. and Kim, C., 2014, "Efficient Computation of Compressible Flow By Higher-order Method Accelerated Using GPU," J. Comput. Fluids Eng, Vol. 19, No. 3, pp. 52-61.
  10. https://www.nvidia.com/content/PDF/kepler/NVIDIA-Kepler-GK110-Architecture-Whitepaper.pdf
  11. http://developer.download.nvidia.com/assets/cuda/files/reduction.pdf
  12. Varghese, S. S., Frankel, S. H. and Fischer, P. F., 2007, "Direct Numerical Simulation of Stenotic Flow: Part 1. Steady Flow," J. Fluid Mech., Vol. 582, pp. 253-280. https://doi.org/10.1017/S0022112007005848
  13. Kang, K., Choi, H. G. and Yoo, J. Y., 2012. "Investigation of Fluid-structure Interactions using a Velocity-linked P2/P1 Finite Element Method and the Generalized-method," Int. J. Numer. Meth. Engng. pp. 1539-1547.