Handling ``Out of Memory'' Errors

by John Boyland.

Abstract

An ``out of memory'' error can be catastrophic for a program, especially one written in a language such as Java that uses memory allocation frequently. Handling such an error can easily lead to its re-occurrence. A handler will often need memory while it is freeing resources (by persisting data to secondary storage, or clearing caches). A simple technique involves pre-allocating a large chunk of memory that is then freed at the start of the handler. I report some experience using this technique and discuss some of the problems that arise when reasoning about the behavior of memory error handlers.

BibTeX Style Reference

@inproceedings(boyland:05out-of-memory,
  title = 	{Position Paper: Handling ``Out Of Memory'' Errors},
  author =      {John Boyland},
  booktitle = 	{ECOOP 2005 Workshop on Exceptional Handling in
		 Object-Oriented Systems},
  month = 	jul,
  year = 	2005,
  editor = 	{Anand Tripathi},
  nothing =	{})

How to Get a Copy

A PDF preprint is available here. The slides for the presentation are also available.


Last Modified: August 1, 2005

Handling ``Out of Memory'' Errors / boyland@cs.uwm.edu