Review request: 8024638: Count and expose the amount of committed memory in the metaspaces

Stefan Karlsson stefan.karlsson at
Wed Sep 11 09:10:23 PDT 2013

This change adds code to track the committed memory in the metaspaces.

This fix is a prerequisite for:
   8024547: MaxMetaspaceSize should limit the committed memory used by 
the metaspaces

The patch is built upon this change, which is also out for review:

Changes in the patch:

- Renamed VirtualSpaceList::_virtual_space_total to 

- Introduced a VirtualSpaceList::_committed_words.

- Added a new function VirtualSpace::actual_committed_size(), which 
reports the memory committed by the OS. The per-existing  function 
VirtualSpace::committed_size() only reports the amount of memory asked 
for by calls to VirtualSpace::expand_by, which can be significantly less 
because of OS allocation granularities and large pages.

- Added code to tracks when the VirtualSpaces in the VirtualSpaceNodes 
are created, deleted, and expanded.

- Added unit tests.


More information about the hotspot-dev mailing list