Transparent Memory Optimization using Slots - Archive ouverte HAL
Conference Papers Year : 2018

Transparent Memory Optimization using Slots

Abstract

Memory size limits the number of instances available in memory at a single time. This limitation affects applications that require large graphs of objects. Moose is an example of such applications. Moose is a tool used in software analysis. It parses and models software code in an object graph. Later it performs multiple operations (i.e., measuring, querying, mining and analysing the code) on such models. However, not all the information in the model is present, as the model is intended to be used with different applications and programming languages (not all applications or programming languages uses the same elements). Analysis of different models shows that between 30 and 50% of memory is wasted. Analysis models produced in an industrial context reveals that models composed of several millions of instances used up to 2Gb memory. In this work, we propose new slots and their combination to transparently optimize memory consumption: NilAwareS-lot optimizes automatically nils and LazyInitializationSlot handles the case where an empty collection is required and use by many clients. We show that performing a limited amount of changes, we improved the memory footprint of Moose models in around 30%. We also show that our solution has comparable performance with an ad hoc solution, but without the need for boilerplate code. To implement this solution, we leverage the existing Pharo support of slots, write barriers and efficient forwarders.
Fichier principal
Vignette du fichier
main.pdf (527.51 Ko) Télécharger le fichier
Origin Files produced by the author(s)
Loading...

Dates and versions

hal-02565748 , version 1 (06-05-2020)

Identifiers

  • HAL Id : hal-02565748 , version 1

Cite

Pablo Tesone, Santiago Bragagnolo, Stéphane Ducasse, Marcus Denker. Transparent Memory Optimization using Slots. International Workshop on Smalltalk Technologies 2018, Sep 2018, Cagliari, Italy. ⟨hal-02565748⟩
97 View
112 Download

Share

More