Abstract—Current computer architectures are
multi-threaded and make use of multiple CPU cores. Most
garbage collections policies for the Java Virtual Machine
include a stop-the-world phase, which means that all threads
are suspended. A considerable portion of the execution time of
Java programs is spent in these stop-the-world garbage
collections. To improve this behavior, a thread-local allocation
and garbage collection that only affects single threads, has been
proposed. Unfortunately, only objects that are not accessible by
other threads ("do not escape") are eligible for this kind of
allocation. It is therefore necessary to reliably predict the
escaping of objects. The work presented in this paper analyzes
the escaping of objects based on the line of code (program
counter – PC) the object was allocated at. The results show that
on average 60-80% of the objects do not escape and can
therefore be locally allocated.
Index Terms—Escape analysis, garbage collection, java
virtual machine, memory management.
Manfred Jendrosch is with the Faculty of Computer Science, University
of New Brunswick, Fredericton, NB, E3B 5A3, Canada and the Faculty of
Computer Science, Bonn-Rhein-Sieg University of Applied Sciences, Sankt
Augustin, 53757, Germany (e-mail: manfred.jendrosch@unb.ca).
Gerhard W. Dueck is with the Faculty of Computer Science, University
of New Brunswick, Fredericton, NB, E3B 5A3, Canada (e-mail:
gdueck@unb.ca).
Charlie Gracie is with IBM Canada Ltd, Kanata, ON, K2V 1C8, Canada
(e-mail: charlie_gracie@ca.ibm.com).
André Hinkenjann is with the Faculty of Computer Science, Bonn-
Rhein-Sieg University of Applied Sciences, Sankt Augustin, 53757,
Germany (e-mail: andre.hinkenjann@h-brs.de).
[PDF]
Cite: Manfred Jendrosch, Gerhard W. Dueck, Charlie Gracie, and André Hinkenjann, "PC Based Escape Analysis in the Java Virtual Machine," Lecture Notes on Software Engineering vol. 2, no. 1, pp. 16-20, 2014.