Dynamic Compilation for Transprecision Applications on Heterogeneous Platform
This journal article describes a part of our HybroGen functionalities : the ability to generate binary applications that can adapt the numbers types at run-time, with a very low compilation overhead. It’s published in the Journal of Low Power Electronics and Applications J. Low Power Electron. Appl. 2021, 11(3), 28; https://doi.org/10.3390/jlpea11030028
The Hybrogen compiler is not yet open source, nevertheless, input and output program sources can be seen on this page: https://github.com/oprecomp/HybroLang The output code can be run using a hardware platform or an instruction set level emulator such as Qemu.
The main point of this article is the description of code generation scenarios illustrated in the following figure. The red parts correspond to a classical program execution, the yellow correspond to the code generation part.
Abstract : This article describes a software environment called HybroGen, which helps to experiment binary code generation at run time. As computing architectures are getting more complex, the application performance is becoming data-dependent. The proposed experimental platform is helpful in programming applications that can be reconfigured at run time in order to be adapted for a new data environment. The HybroGen platform is adapted to heterogeneous architectures and can generate instructions for different targets. This platform allows to go farther than classical JIT compilation in many directions: the code generator is smaller by three orders of magnitude and faster by three orders of magnitude, compared to JIT (Just-In-Time) platforms, and allows making code transformation that is impossible in traditional compilation schemes, such as code generation for non von Neumann accelerators or dynamic code transformations for transprecision. The latter is illustrated in a code example: the square root with Newton’s algorithm. We also illustrate the proposed HybroGen platform with two other examples: a multiplication with a specialization on a value determined at run time, and a conversion of degrees Celsius to degrees Fahrenheit. This article presents a proof of concept of the proposed HybroGen platform in terms of its functionalities, and demonstrates the working status.