Home → Magazine Archive → November 2013 (Vol. 56, No. 11) → Leaking Space → Abstract

Leaking Space

By Neil Mitchell

Communications of the ACM, Vol. 56 No. 11, Pages 44-52
10.1145/2524713.2524722

[article image]


back to top 

A space leak occurs when a computer program uses more memory than necessary. In contrast to memory leaks, where the leaked memory is never released, the memory consumed by a space leak is released, but later than expected. This article presents example space leaks and how to spot and eliminate them.

Let's first consider two "real-life" space leaks. Xena, the xylophone enthusiast, buys a 26-volume printed encyclopedia, but she only wants to read the article on xylophones. The encyclopedia occupies a lot of space on her bookshelf. Xena could throw away all but the X volume, reducing the shelf requirements; or she could cut out the xylophone article, leaving only a single piece of paper. In this example, Xena is storing lots of information but is interested in only a small subset of it.

0 Comments

No entries found