Skip to content

Commit

Permalink
rename
Browse files Browse the repository at this point in the history
  • Loading branch information
LizBing committed Feb 15, 2024
1 parent d65b659 commit faa6f66
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1095,7 +1095,7 @@ public void addAnnotation(Address addr, OopHandle handle) {

} else if (collHeap instanceof G1CollectedHeap) {
G1CollectedHeap heap = (G1CollectedHeap)collHeap;
HeapRegion region = heap.hrm().getByAddress(handle);
G1HeapRegion region = heap.hrm().getByAddress(handle);

if (region == null) {
// intentionally skip
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
// Mirror class for HeapRegion. Currently we don't actually include
// any of its fields but only iterate over it.

public class HeapRegion extends ContiguousSpace implements LiveRegionsProvider {
public class G1HeapRegion extends ContiguousSpace implements LiveRegionsProvider {
private static AddressField bottomField;
private static AddressField topField;
private static AddressField endField;
Expand All @@ -55,7 +55,7 @@ public class HeapRegion extends ContiguousSpace implements LiveRegionsProvider {
private static long typeFieldOffset;
private static long pointerSize;

private HeapRegionType type;
private G1HeapRegionType type;

static {
VM.registerVMInitializedObserver(new Observer() {
Expand Down Expand Up @@ -84,11 +84,11 @@ public static long grainBytes() {
return grainBytesField.getValue();
}

public HeapRegion(Address addr) {
public G1HeapRegion(Address addr) {
super(addr);
Address typeAddr = (addr instanceof OopHandle) ? addr.addOffsetToAsOopHandle(typeFieldOffset)
: addr.addOffsetTo(typeFieldOffset);
type = VMObjectFactory.newObject(HeapRegionType.class, typeAddr);
type = VMObjectFactory.newObject(G1HeapRegionType.class, typeAddr);
}

public Address bottom() { return bottomField.getValue(addr); }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@

package sun.jvm.hotspot.gc.g1;

public interface HeapRegionClosure {
public interface G1HeapRegionClosure {
public void doHeapRegion(HeapRegion hr);
}
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

// Mirror class for HeapRegionManager.

public class HeapRegionManager extends VMObject {
public class G1HeapRegionManager extends VMObject {
// G1HeapRegionTable _regions
private static long regionsFieldOffset;

Expand Down Expand Up @@ -74,7 +74,7 @@ public Iterator<HeapRegion> heapRegionIterator() {
return regions().heapRegionIterator(length());
}

public HeapRegionManager(Address addr) {
public G1HeapRegionManager(Address addr) {
super(addr);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@

// Mirror class for HeapRegionSetBase. Represents a group of regions.

public class HeapRegionSetBase extends VMObject {
public class G1HeapRegionSetBase extends VMObject {

// uint _length
private static CIntegerField lengthField;
Expand All @@ -62,7 +62,7 @@ public long length() {
return lengthField.getValue(addr);
}

public HeapRegionSetBase(Address addr) {
public G1HeapRegionSetBase(Address addr) {
super(addr);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
// Mirror class for HeapRegionType. Currently we don't actually include
// any of its fields but only iterate over it.

public class HeapRegionType extends VMObject {
public class G1HeapRegionType extends VMObject {

private static int freeTag;
private static int youngMask;
Expand Down Expand Up @@ -104,7 +104,7 @@ public boolean isOld() {
return (tagField.getValue(addr) & oldMask) != 0;
}

public HeapRegionType(Address addr) {
public G1HeapRegionType(Address addr) {
super(addr);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public void run() {
printValMB("CompressedClassSpaceSize = ", getFlagValue("CompressedClassSpaceSize", flagMap));
printValMB("MaxMetaspaceSize = ", getFlagValue("MaxMetaspaceSize", flagMap));
if (heap instanceof G1CollectedHeap) {
printValMB("G1HeapRegionSize = ", HeapRegion.grainBytes());
printValMB("G1HeapRegionSize = ", G1HeapRegion.grainBytes());
}

System.out.println();
Expand Down Expand Up @@ -250,8 +250,8 @@ public void printG1HeapSummary(PrintStream tty, G1CollectedHeap g1h) {
G1MonitoringSupport monitoringSupport = g1h.monitoringSupport();
long edenSpaceRegionNum = monitoringSupport.edenSpaceRegionNum();
long survivorSpaceRegionNum = monitoringSupport.survivorSpaceRegionNum();
HeapRegionSetBase oldSet = g1h.oldSet();
HeapRegionSetBase humongousSet = g1h.humongousSet();
G1HeapRegionSetBase oldSet = g1h.oldSet();
G1HeapRegionSetBase humongousSet = g1h.humongousSet();
long oldGenRegionNum = oldSet.length() + humongousSet.length();
printG1Space(tty, "G1 Heap:", g1h.n_regions(),
g1h.used(), g1h.capacity());
Expand Down

0 comments on commit faa6f66

Please sign in to comment.