Home

Safe and Leakproof Resource Management using Ada83 Limited Types


Author(s) : Henry G. Baker, 
Publisher : N/A
Publication Date : 1993
ISSN : N/A
Abstract : Safe, leakproof and automatic resource managers are essential to the implementation of every embedded system, yet the standard examples of Ada83 resource managers are either unsafe: they risk allocating the same resource for two different purposes, leaky: they risk permanently losing track of some resources, or non-automatic: they require explicit deallocation, which allows for a host of opportunities for single-point system failures. Nevertheless, it is possible to construct a safe, leakproof and automatic resource manager---at least for systems with only a single task---by a careful combination of certain features of Ada83, and a careful avoidance of other features. We illustrate our scheme with a safe, leakproof and fully automatic dynamic-string package. The same techniques also work for an arbitrary precision arithmetic package [Fisher83] and for managing the "roots " of a real-time garbage-collected heap [Baker78] [Baker91SP] [Baker92Tread]. Suggestions are offered to improve the use of limited private types in Ada9X for automatic, safe and leakproof resource management.,