An object-oriented program is modified to create objects within specified
regions, allowing memory de-allocation to take place for entire regions
at once. The contents and associations between the regions are described
by one or more shape graphs, which are created from an analysis of the
program code. The region association metadata stored by the shape graphs
allows the region-based memory management to take place while requiring
no more than one region to be passed to methods for each object passed.