public class GCTrace extends SS
B 345678 12
(Object 345678 was created in the boot image with a size of 12 bytes)
U 59843 234 47298
(Update object 59843 at the slot at offset 234 to refer to 47298)
S 1233 12345
(Update static slot 1233 to refer to 12345)
T 4567 78924
(The TIB of 4567 is set to refer to 78924)
D 342789
(Object 342789 became unreachable)
A 6860 24 346648 3
(Object 6860 was allocated, requiring 24 bytes, with fp 346648 on
thread 3; this allocation has perfect knowledge)
a 6884 24 346640 5
(Object 6864 was allocated, requiring 24 bytes, with fp 346640 on
thread 5; this allocation DOES NOT have perfect knowledge)
I 6860 24 346648 3
(Object 6860 was allocated into immortal space, requiring 24 bytes,
with fp 346648 on thread 3; this allocation has perfect knowledge)
i 6884 24 346640 5
(Object 6864 was allocated into immortal space, requiring 24 bytes,
with fp 346640 on thread 5; this allocation DOES NOT have perfect
knowledge)
48954->[345]LObject;:blah()V:23 Ljava/lang/Foo;
(Citation for: a) where the was allocated, fp of 48954,
at the method with ID 345 -- or void Object.blah() -- and bytecode
with offset 23; b) the object allocated is of type java.lang.Foo)
D 342789 361460
(Object 342789 became unreachable after 361460 was allocated)
This class implements a simple semi-space collector. See the Jones
& Lins GC book, section 2.2 for an overview of the basic
algorithm. This implementation also includes a large object space
(LOS), and an uncollected "immortal" space.All plans make a clear distinction between global and thread-local activities. Global activities must be synchronized, whereas no synchronization is required for thread-local activities. Instances of Plan map 1:1 to "kernel threads" (aka CPUs). Thus instance methods allow fast, unsychronized access to Plan utilities such as allocation and collection. Each instance rests on static resources (such as memory and virtual memory resources) which are "global" and therefore "static" members of Plan. This mapping of threads to instances is crucial to understanding the correctness and performance proprties of this plan.
| Modifier and Type | Field and Description |
|---|---|
static boolean |
deathScan |
static boolean |
finalDead |
static boolean |
lastGCWasTracing |
static int |
TRACE |
static boolean |
traceInducedGC |
static RawPageSpace |
traceSpace |
ALLOC_SS, copySpace0, copySpace1, hi, SCAN_SS, SS0, SS1, ssTracepostSanityPhase, preSanityPhaseCLOSURE, collection, collectionAttempt, COMPLETE, completeClosurePhase, FINALIZABLE, finishPhase, FORWARD, FORWARD_FINALIZABLE, FORWARD_REFS, forwardPhase, INITIATE, initPhase, PHANTOM_REFS, POST_SANITY_PLACEHOLDER, PRE_SANITY_PLACEHOLDER, PREPARE, PREPARE_STACKS, prepareStacks, refTypeClosurePhase, RELEASE, rootClosurePhase, ROOTS, SANITY_BUILD_TABLE, SANITY_CHECK_TABLE, SANITY_COPY_ROOTS, SANITY_PREPARE, SANITY_RELEASE, SANITY_ROOTS, SANITY_SET_POSTGC, SANITY_SET_PREGC, sanityBuildPhase, sanityCheckPhase, SET_COLLECTION_KIND, SOFT_REFS, STACK_ROOTS, WEAK_REFS, WEAK_TRACK_REFSALLOC_CODE, ALLOC_COLD_CODE, ALLOC_DEFAULT, ALLOC_GCSPY, ALLOC_HOT_CODE, ALLOC_IMMORTAL, ALLOC_LARGE_CODE, ALLOC_LOS, ALLOC_NON_MOVING, ALLOC_NON_REFERENCE, ALLOC_PRIMITIVE_LOS, ALLOC_STACK, allocationSiteCount, ALLOCATORS, concurrentWorkers, controlCollectorContext, DEFAULT_MAX_NURSERY, DEFAULT_MIN_NURSERY, DEFAULT_SITE, defaultCollectorContext, emergencyCollection, GATHER_WRITE_BARRIER_STATS, GC_PREPARE, GC_PROPER, IMMORTAL, immortalSpace, insideHarness, internalTriggeredCollection, LARGE_CODE, largeCodeSpace, lastInternalTriggeredCollection, LOS, loSpace, MAX_NON_LOS_COPY_BYTES, MAX_NON_LOS_DEFAULT_ALLOC_BYTES, MAX_NON_LOS_NONMOVING_ALLOC_BYTES, META, metaDataSpace, NEEDS_LOG_BIT_IN_HEADER, NON_MOVING, NON_PARTICIPANT, nonMovingSpace, NOT_IN_GC, parallelWorkers, pretenureThreshold, SANITY, sanityChecker, sanitySpace, SCAN_BOOT_IMAGE, SMALL_CODE, smallCodeSpace, stacksPrepared, totalTime, USE_CODE_SPACE, userTriggeredCollection, VM_SPACE, vmSpace| Constructor and Description |
|---|
GCTrace()
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
collectionPhase(short phaseId)
Perform a (global) collection phase.
|
boolean |
collectionRequired(boolean spaceFull,
Space space)
This method controls the triggering of a GC.
|
static GCTrace |
global() |
boolean |
isLastGCFull() |
void |
notifyExit(int value)
The planExit method is called at RVM termination to allow the
trace process to finish.
|
void |
processOptions()
The processOptions method is called by the runtime immediately after
command-line arguments are available.
|
fromSpace, getCollectionReserve, getPagesAvail, getPagesUsed, registerSpecializedMethods, toSpace, willNeverMovereplacePhase, replacePlaceholderPhase, switchNurseryZeroingApproachavailableMemory, bootTimeWriteBarrier, concurrentCollectionRequired, determineThreadCount, enableAllocation, enableCollection, forceFullHeapCollection, freeMemory, fullyBooted, gcInProgress, gcInProgressProper, getAllocationSite, getPagesReserved, getSpecializedScanClass, getTotalPages, handleUserCollectionRequest, harnessBegin, harnessEnd, insertPhaseAfter, isCurrentGCNursery, isEmergencyCollection, isInitialized, isInternalTriggeredCollection, isUserTriggeredCollection, lastCollectionFullHeap, lastCollectionWasExhaustive, loadObjectReference, logPoll, poll, preCollectorSpawn, printDetailedTiming, printPostStats, printPreStats, printUsedPages, reservedMemory, resetCollectionTrigger, sanityExpectedRC, sanityLinearScan, setBuildTimeGCByte, setGCStatus, spawnCollectorThreads, stacksPrepared, startGCspyServer, storeObjectReference, stressTestGCRequired, totalMemory, triggerInternalCollectionRequest, usedMemorypublic static final RawPageSpace traceSpace
public static final int TRACE
public static boolean lastGCWasTracing
public static boolean traceInducedGC
public static boolean deathScan
public static boolean finalDead
public GCTrace()
public void processOptions()
StopTheWorldprocessOptions in class StopTheWorldpublic final void notifyExit(int value)
notifyExit in class Planvalue - The exit valuepublic final boolean collectionRequired(boolean spaceFull, Space space)
Plantrue to trigger a collection.collectionRequired in class PlanspaceFull - Space request failed, must recover pages within 'space'.space - TODOtrue if a collection is requested by the plan.public void collectionPhase(short phaseId)
collectionPhase in class SSphaseId - The unique id of the phase to perform.public boolean isLastGCFull()