Specifications

Sun Services
Java™ Programming Language
Module 1, slide 11 of 23
Copyright 2005 Sun Microsystems, Inc. All Rights Reserved. Sun Services, Revision F
Garbage Collection
Allocated memory that is no longer needed should be
deallocated.
In other languages, deallocation is the programmer’s
responsibility.
The Java programming language provides a
system-level thread to track memory allocation.
Garbage collection has the following characteristics:
Checks for and frees memory no longer needed
Is done automatically
Can vary dramatically across JVM implementations