java.lang.Object
Memory.Manager.MarkAndSweep
- All Implemented Interfaces:
- GCConstants
- public class MarkAndSweep
- extends java.lang.Object
- implements GCConstants
MarkAndSweep collector, adapted from Jikes RVM version
written by Dick Attanasio.
- Version:
- $Id: MarkAndSweep.java,v 1.5 2003/05/12 10:05:19 joewhaley Exp $
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
verbose
static int verbose
- Control chattering during progress of GC
movesObjects
public static final boolean movesObjects
- See Also:
- Constant Field Values
writeBarrier
public static final boolean writeBarrier
- See Also:
- Constant Field Values
SMALL_SPACE_MAX
static final int SMALL_SPACE_MAX
- See Also:
- Constant Field Values
GC_RETRY_COUNT
static final int GC_RETRY_COUNT
- See Also:
- Constant Field Values
flag2nd
static boolean flag2nd
gc_collect_now
static boolean gc_collect_now
bootHeap
private static Memory.Heap.BootHeap bootHeap
mallocHeap
private static Memory.Heap.MallocHeap mallocHeap
smallHeap
private static Memory.Heap.SegregatedListHeap smallHeap
immortalHeap
public static Memory.Heap.ImmortalHeap immortalHeap
largeHeap
private static Memory.Heap.LargeHeap largeHeap
gcInProgress
static boolean gcInProgress
MarkAndSweep
public MarkAndSweep()
gcInProgress
public static boolean gcInProgress()
- "getter" function for gcInProgress
init
public static void init()
- Setup done during bootimage building
boot
public static void boot()
showParameter
static void showParameter()
allocateObject
public static java.lang.Object allocateObject(int size,
java.lang.Object[] tib)
throws java.lang.OutOfMemoryError
- Allocate a "scalar" (non-array) Java object.
allocateArray
public static java.lang.Object allocateArray(int numElements,
int size,
java.lang.Object[] tib)
throws java.lang.OutOfMemoryError
- Allocate an array object.
heapExhausted
public static void heapExhausted(Memory.Heap.Heap heap,
int size,
int count)
- Handle heap exhaustion.
gcSetup
public static void gcSetup(int numSysThreads)
prepareNonParticipatingVPsForGC
private static void prepareNonParticipatingVPsForGC()
prepareNonParticipatingVPsForAllocation
private static void prepareNonParticipatingVPsForAllocation()
collect
public static void collect()
gc_getMatureSpace
static Memory.HeapAddress gc_getMatureSpace(int size)
gc_scanObjectOrArray
static void gc_scanObjectOrArray(Memory.HeapAddress objRef)
gc_emptyWorkQueue
static void gc_emptyWorkQueue()
gc
public static void gc()
gc1
public static void gc1(java.lang.String why,
int size)
totalMemory
public static long totalMemory()
freeMemory
public static long freeMemory()
allSmallFreeMemory
public static long allSmallFreeMemory()
allSmallUsableMemory
public static long allSmallUsableMemory()
gc_isLive
static boolean gc_isLive(Memory.HeapAddress ref)
setupProcessor
public static void setupProcessor(Scheduler.jq_NativeThread st)
printclass
public static void printclass(Memory.HeapAddress ref)
processWriteBufferEntry
static void processWriteBufferEntry(Memory.HeapAddress ref)
getLiveObject
public static java.lang.Object getLiveObject(java.lang.Object obj)
processFinalizerCandidate
public static boolean processFinalizerCandidate(Memory.HeapAddress ref)
processPtrField
public static void processPtrField(Memory.Address location)
- Process an object reference field during collection.
processPtrValue
public static Memory.HeapAddress processPtrValue(Memory.HeapAddress ref)
- Process an object reference (value) during collection.