Interactive Compilation Interface (GCC-ICI)
Comparison of different plugin APIs
The main aim of the Interactive Compilation Interface (ICI) is to enable external access to GCC transformations to be able to tune default optimization heuristic to improve program execution time, code size, etc using external plugins and tools without Makefile changes. Current ICI version support compile-time selection and reordering of passes. Additional information and publicationsComparison of different plugin APIs can be found at the development website. MILEPOST project uses ICI and static feature extractor pass with a long term goal to develop a modular, extensible, machine-learning based self-optimizing compiler that automatically learns the best optimization heuristics based on the behavior of the platform.
Here is our current patch against GCC 4.3. Current version allows function-level optimization and specialization by selecting or reordering only appropriate passes. It uses external plugins to monitor and improve default compiler optimization heuristic. We plan to combine it with the Function Adaptation to make statically-compiled programs adaptable to changing inputs, program behavior and environments (architecture, OS, virtual layers, libraries, etc) at run-time based on static function versioning and dynamic monitoring of performance counters.
We are currently extending ICI with the following:
- add fine-grain tuning of cost model for majority of optimizations/code generation passes (vectorization, GRAPHITE, unrolling, inlining, register allocation, instruction scheduling)
- add function cloning to apply function specific optimizations through external plugins
- add function adaptation routines to enable self-tuning static binaries adaptable to changes in program behavior and environment
- add ability to compile a function clone with different ISA (for reconfigurable architectures or for CPU-GPU-like heterogeneous multicore architectures)
Related projects: