[Paper Review] OMP2HMPP: HMPP Source Code Generation from Programs with Pragma Extensions
OMP2HMPP is a source-to-source compiler that automatically translates OpenMP-extended C code into HMPP-compliant code for GPGPU acceleration, leveraging the Mercurium framework to analyze variable lifetimes and data dependencies. It achieves an average speedup of 113× over sequential execution and produces code nearly equivalent to hand-optimized HMPP versions, enabling portable high-performance computing across HPC and embedded GPUs.
High-performance computing are based more and more in heterogeneous architectures and GPGPUs have become one of the main integrated blocks in these, as the recently emerged Mali GPU in embedded systems or the NVIDIA GPUs in HPC servers. In both GPGPUs, programming could become a hurdle that can limit their adoption, since the programmer has to learn the hardware capabilities and the language to work with these. We present OMP2HMPP, a tool that, automatically trans-lates a high-level C source code(OpenMP) code into HMPP. The generated version rarely will differs from a hand-coded HMPP version, and will provide an important speedup, near 113%, that could be later improved by hand-coded CUDA. The generated code could be transported either to HPC servers and to embedded GPUs, due to the commonalities between them.
Motivation & Objective
- To reduce the complexity of GPGPU programming by automating the translation of OpenMP-extended C code into HMPP directives.
- To generate HMPP-optimized code that closely matches hand-coded versions in performance and structure.
- To enable portability of GPGPU applications across heterogeneous architectures, including HPC servers and embedded GPUs.
- To provide a performance-optimized starting point for developers who lack expertise in low-level GPU programming models.
- To explore future integration with tools like Par4All for end-to-end automatic parallelization from sequential C/C++.
Proposed method
- Uses the BSC Mercurium source-to-source compilation framework to parse and analyze the input OpenMP C code, extracting abstract syntax trees (ASTs) and symbol tables.
- Performs static analysis to determine variable scope, liveness, and data access patterns across OpenMP-parallelized regions.
- Applies HMPP directives—such as callsite, codelet, group, advancedload, delegatestore, synchronize, release, noupdate, and target—to map OpenMP regions to GPU kernels.
- Optimizes data transfers by using noupdate and advancedload to avoid redundant uploads and downloads, especially for variables used across multiple kernels.
- Employs asynchronous execution for GPU kernels where dependencies allow, improving concurrency and hiding latency.
- Generates HMPP-compliant C code that supports both CUDA and future OpenCL targets, ensuring portability across GPU platforms.
Experimental results
Research questions
- RQ1Can a source-to-source compiler automatically generate HMPP-compliant code from OpenMP-extended C code with minimal performance degradation?
- RQ2How closely can automatically generated HMPP code match the performance and structure of hand-optimized HMPP implementations?
- RQ3To what extent can the generated code achieve high-speedup on both HPC and embedded GPU platforms?
- RQ4What optimizations—such as data transfer minimization and asynchronous execution—can be automatically applied during translation?
- RQ5How does the performance of the generated code compare to sequential, OpenMP, and hand-coded CUDA versions?
Key findings
- OMP2HMPP achieves an average speedup of 113× over the sequential version on tested HPC and embedded GPU platforms.
- The generated code achieves an average speedup of over 31× compared to the original OpenMP version, demonstrating significant performance gains.
- The performance of the generated HMPP code is nearly indistinguishable from hand-optimized HMPP versions, with minimal differences in structure and data movement.
- The tool effectively reduces data transfer overhead by using noupdate and advancedload directives, avoiding redundant uploads and downloads.
- The generated code is portable across heterogeneous architectures, including NVIDIA Tesla GPUs in HPC servers and Mali GPUs in embedded systems.
- The performance of the generated code is within 1.7× of hand-coded CUDA versions for most benchmarks, indicating strong optimization potential for further tuning.
Better researchstarts right now
From reading papers to final review, dramatically reduce your research time.
No credit card · Free plan available
This review was created by AI and reviewed by human editors.