Design, implementation, and evaluation of a dynamic compilation framework for the yap system

A Faustino da Silva, V Santos Costa - International Conference on Logic …, 2007 - Springer
A Faustino da Silva, V Santos Costa
International Conference on Logic Programming, 2007Springer
We propose dynamic compilation for Prolog, in the style of Just-In-Time compilers. Our
approach adapts to the actual characteristics of the target program by (i) compiling only the
parts of the program that are executed frequently, and (ii) adapting to actual call patterns.
This allows aggressive optimization of the parts of the program that are really executed, and
better informed heuristics to drive these optimizations. Our compiler does need to support all
features in the language, only what is deemed important to performance. Complex execution …
Abstract
We propose dynamic compilation for Prolog, in the style of Just-In-Time compilers. Our approach adapts to the actual characteristics of the target program by (i) compiling only the parts of the program that are executed frequently, and (ii) adapting to actual call patterns. This allows aggressive optimization of the parts of the program that are really executed, and better informed heuristics to drive these optimizations. Our compiler does need to support all features in the language, only what is deemed important to performance. Complex execution patterns, such as the ones caused by error handling, may be left to the interpreter. On the other hand, compilation is now part of the run-time, and thus incurs run-time overheads. We have implemented dynamic compilation for YAP system. Our initial results suggest that dynamic compilation achieves very substantial performance improvements over the original interpreter, and that it can approach and even out-perform state-of-the-art native code systems. We believe that we have shown that dynamic compilation is worthwhile and fits naturally with Prolog execution.
Springer
Showing the best result for this search. See all results