Porting CUDA to HIP

Conclusion

If you’re worried about your CUDA code getting trapped in the dead end of vendor lock-in, you’re in luck. HIP is a versatile replacement for CUDA, and it comes with an all-open platform that supports other GPU-based hardware environments. The tools described in this paper provide an automated path for porting your CUDA programs to the open ROCm environment.

Once you have successfully ported your CUDA program to ROCm, you’ll have access to AMD’s powerful family of GPU-based products, including the Radeon Instinct™ accelerators. If you also plan to continue to use your program with Nvidia hardware, you can maintain the source code in HIP and compile it for either AMD or Nvidia hardware from a single codebase.

Info

[1] ROCm platform

[2] HIP installation

[3] The Clang Manual for Compiling CUDA Code

[4] HACC

[5] Caffe deep learning framework