Chameleon

Ohad Shacham, Martin Vechev, Eran Yahav
2009 SIGPLAN notices  
Languages such as Java and C#, as well as scripting languages like Python, and Ruby, make extensive use of Collection classes. A collection implementation represents a fixed choice in the dimensions of operation time, space utilization, and synchronization. Using the collection in a manner not consistent with this fixed choice can cause significant performance degradation. In this paper, we present CHAMELEON, a low-overhead automatic tool that assists the programmer in choosing the appropriate
more » ... ng the appropriate collection implementation for her application. During program execution, CHAMELEON computes elaborate trace and heap-based metrics on collection behavior. These metrics are consumed on-thefly by a rules engine which outputs a list of suggested collection adaptation strategies. The tool can apply these corrective strategies automatically or present them to the programmer. We have implemented CHAMELEON on top of a IBM's J9 production JVM, and evaluated it over a small set of benchmarks. We show that for some applications, using CHAMELEON leads to a significant improvement of the memory footprint of the application. The main contributions of this paper can be summarized as follows: • A semantic profiler which tracks useful collection usage patterns across space and time. The profiler aggregates and sorts data for each collection allocation-context. • A collection-aware garbage collector which continuously gathers statistics for a collection ADT rather than individual objects.
doi:10.1145/1543135.1542522 fatcat:wchtxewh6jebdlm7sdypxbc24u