public abstract class Space extends VMObject
A Space describes a heap area. Class Space is an abstract base class.
Space supports allocation, size computation and GC support is provided.
Invariant: bottom() and end() are on page_size boundaries and:
bottom() <= top() <= end()
top() is inclusive and end() is exclusive.
Modifier and Type | Method and Description |
---|---|
Address |
bottom() |
OopHandle |
bottomAsOopHandle()
Support for iteration over heap -- not sure how this will
interact with GC in reflective system, but necessary for the
debugging mechanism
|
long |
capacity()
Returned value is in bytes
|
boolean |
contains(Address p)
Testers
|
Address |
end() |
abstract long |
free()
Returned value is in bytes
|
abstract java.util.List |
getLiveRegions()
returns all MemRegions where live objects are
|
OopHandle |
nextOopHandle(OopHandle handle,
long size)
Support for iteration over heap -- not sure how this will
interact with GC in reflective system, but necessary for the
debugging mechanism
|
void |
print() |
void |
printOn(java.io.PrintStream tty) |
abstract long |
used()
Returned value is in bytes
|
MemRegion |
usedRegion()
Returns a subregion of the space containing all the objects in
the space.
|
equals, getAddress, hashCode, toString
public Space(Address addr)
public Address bottom()
public Address end()
public MemRegion usedRegion()
public OopHandle bottomAsOopHandle()
public OopHandle nextOopHandle(OopHandle handle, long size)
public abstract java.util.List getLiveRegions()
public long capacity()
public abstract long used()
public abstract long free()
public boolean contains(Address p)
public void print()
public void printOn(java.io.PrintStream tty)
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 2016, Oracle and/or its affiliates. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.