Publication: ORCHID: A Framework for Complete CUDA to OpenMP Translation
Files
Date
Authors
Journal Title
Journal ISSN
Volume Title
Publisher
Access Restrictions
Abstract
As physical limits to further performance gains have emerged in recent years, modern hardware has become specialized for accelerated computation. This improved performance, but it also exposed more of the underlying parallelism and accelerator complexity directly to programmers. To aid programmability, various Parallel Programming Models (PPMs) have been developed to help programmers take advantage of hardware. But this trend has also made portability between PPMs more difficult. In particular, CUDA is tailored and licensed only for Nvidia GPUs, while OpenMP targets multicore CPUs. Without a way to port software between PPMs, users must choose hardware based on compatibility rather than suitability for their intended use.
There are many ways to translate code between PPMs, but they generally force a tradeoff between maintainability, functionality, and performance. Maintainability is often sacrificed because generated code becomes low-level or unnatural. Functionality is often limited because CUDA-specific semantics do not always have direct one-to-one mappings in OpenMP. Performance is also frequently lost through conservative lowerings. This thesis presents ORCHID, an automated CUDA-to-OpenMP translation framework that addresses these issues. ORCHID handles CUDA-specific semantics, introduces a novel fission algorithm for translating the GPU programming model to multicore CPUs, and preserves the maintainability of machine-generated code.
In the NAS (NASA Advanced Supercomputing) Parallel Benchmarks, ORCHID achieves full test coverage of the entire CUDA benchmark suite. It preserves the parallelism of the CUDA implementation on a multicore CPU and increases code coverage compared to previous source-to-source compilers by several orders of magnitude. This thesis also applies ORCHID to a robotics trajectory-optimization workload based on iterative Linear Quadratic Regulation (iLQR). These results show that translated code can remain correct, performant, and natural enough for developers to maintain.