In this chapter, we will continue with our hands-on experience with PyOpenCL. We will follow our CUDA program example that we discussed in the previous chapter and will try to make it a cross-platform venture with ROCm's HIP. In order to do this, we will use the hipify tool that we learned to build in Chapter 4, Fundamentals of GPU Programming. With hipify, we will try to create .cpp files from .cu files. With a practical approach, we will see the entire process of converting CUDA code into HIP code.
C programming enthusiasts will be encouraged to invoke AMD and NVIDIA GPUs within their program code with HIP, while Python programming enthusiasts will be motivated to use PyOpenCL to invoke AMD and NVIDIA GPUs within their program code. We will first start with the understanding of how a ROCm HIP-C program works. The fundamental concepts behind...