CW 482

Quan Phan and Gerda Janssens
A proposal for runtime region support for Mercury programs

Abstract

Region-based memory management is an interesting compile-time memory management technique. Implementing region-based memory management for a language is twofold, firstly developing a static region analysis that annotates programs with region instructions and secondly providing a region-aware runtime system that can run the region-annotated programs. In this report we develop the runtime support needed by the region-annotated programs which are the result of a region analysis that has been developed for Mercury. We implement the runtime support in a region simulator which allows us to evaluate the memory behaviour of a region-annotated program as if it is executed in a fully-implemented region-based memory management system. Using the region analyser and the region simulator we experiment with several benchmark programs. The obtained memory consumption results are very encouraging, in some programs optimal memory management is achieved.

report.pdf (157K) / mailto: Q. Phan