A LLVM extension for the generation of low overhead runtime program specializer
Résumé
Program specialization is a common way to improve program performance. From a generic implementation of an algorithm, a derived implementation is generated by fixing some inputs. Many tools and languages enable this optimization at compile time, like C++, or at run-time, like Tempo. However, most of those tools are tied to a language (mostly C) and extensions made to it. In the case of run-time specializers, most of them manipulate an intermediate representation during code generation, that can lead to a waste of resources. In this paper, we introduce an LLVM extension that aims to generate low-overhead runtime program specializers. Given a program in an annotated LLVM IR, we use dedicated passes and a modified back-end to generate a specialized code generator. This approach removes the need to manipulate any IR at run-time. We also present some experiment performed on an ARM processor.