Python, the world’s most popular programming language, offers high productivity and a vast, robust, production-level ecosystem. However, its use in HPC has generally been limited to regions that are not performance critical due to performance limitations that arise from it being an interpreted language, its implementation of thread-safety, and its lack of a general, well-defined approach to parallelization. Instead, performance critical code is typically implemented in low-level languages, such as C/C++, which limits access to Python’s ecosystem. An earlier effort created PyOMP, an implementation of OpenMP in Python that demonstrated promising performance on CPUs but did not support GPUs. This paper presents our new design and implementation of PyOMP to support GPUs with significant extensions to interface Python to OpenMP GPU offloading and dynamic compilation. Using HPC proxy applications from HeCBench, we demonstrate performance competitive with OpenMP/GPU programs using C/C++ while maintaining the high productivity that has made Python so popular.

错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

Programming GPUs with OpenMP and Python

  • Giorgis Georgakoudis,
  • Todd A. Anderson,
  • Stuart Archibald,
  • Bronis R. de Supinski,
  • Timothy G. Mattson

摘要

Python, the world’s most popular programming language, offers high productivity and a vast, robust, production-level ecosystem. However, its use in HPC has generally been limited to regions that are not performance critical due to performance limitations that arise from it being an interpreted language, its implementation of thread-safety, and its lack of a general, well-defined approach to parallelization. Instead, performance critical code is typically implemented in low-level languages, such as C/C++, which limits access to Python’s ecosystem. An earlier effort created PyOMP, an implementation of OpenMP in Python that demonstrated promising performance on CPUs but did not support GPUs. This paper presents our new design and implementation of PyOMP to support GPUs with significant extensions to interface Python to OpenMP GPU offloading and dynamic compilation. Using HPC proxy applications from HeCBench, we demonstrate performance competitive with OpenMP/GPU programs using C/C++ while maintaining the high productivity that has made Python so popular.