org.mmtk.plan.generational
Class GenConstraints

java.lang.Object
  extended by org.mmtk.plan.PlanConstraints
      extended by org.mmtk.plan.SimpleConstraints
          extended by org.mmtk.plan.StopTheWorldConstraints
              extended by org.mmtk.plan.generational.GenConstraints
Direct Known Subclasses:
GenCopyConstraints, GenImmixConstraints, GenMSConstraints

public class GenConstraints
extends StopTheWorldConstraints

This class and its subclasses communicate to the host VM/Runtime any features of the selected plan that it needs to know. This is separate from the main Plan/PlanLocal class in order to bypass any issues with ordering of static initialization.


Constructor Summary
GenConstraints()
           
 
Method Summary
 int gcHeaderBits()
           
 int gcHeaderWords()
           
 boolean generational()
           
 int maxNonLOSDefaultAllocBytes()
           
 boolean movesObjects()
           
 boolean needsLogBitInHeader()
           
 boolean needsObjectReferenceNonHeapWriteBarrier()
           
 boolean needsObjectReferenceWriteBarrier()
           
 int numSpecializedScans()
           
 boolean objectReferenceBulkCopySupported()
           
 
Methods inherited from class org.mmtk.plan.PlanConstraints
addressBulkCopySupported, booleanBulkCopySupported, byteBulkCopySupported, charBulkCopySupported, doubleBulkCopySupported, extentBulkCopySupported, floatBulkCopySupported, generateGCTrace, intBulkCopySupported, longBulkCopySupported, maxNonLOSCopyBytes, maxNonLOSNonMovingAllocBytes, needsAddressReadBarrier, needsAddressWriteBarrier, needsBooleanReadBarrier, needsBooleanWriteBarrier, needsByteReadBarrier, needsByteWriteBarrier, needsCharReadBarrier, needsCharWriteBarrier, needsConcurrentWorkers, needsDoubleReadBarrier, needsDoubleWriteBarrier, needsExtentReadBarrier, needsExtentWriteBarrier, needsFloatReadBarrier, needsFloatWriteBarrier, needsForwardAfterLiveness, needsIntReadBarrier, needsIntWriteBarrier, needsJavaLangReferenceReadBarrier, needsLinearScan, needsLongReadBarrier, needsLongWriteBarrier, needsObjectReferenceNonHeapReadBarrier, needsObjectReferenceReadBarrier, needsOffsetReadBarrier, needsOffsetWriteBarrier, needsShortReadBarrier, needsShortWriteBarrier, needsWordReadBarrier, needsWordWriteBarrier, offsetBulkCopySupported, shortBulkCopySupported, withGCspy, wordBulkCopySupported
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GenConstraints

public GenConstraints()
Method Detail

generational

public boolean generational()
Overrides:
generational in class PlanConstraints
Returns:
Is this plan generational in nature.

movesObjects

public boolean movesObjects()
Overrides:
movesObjects in class PlanConstraints
Returns:
true if this Plan moves objects.

gcHeaderBits

public int gcHeaderBits()
Specified by:
gcHeaderBits in class PlanConstraints
Returns:
The number of header bits that are required.

gcHeaderWords

public int gcHeaderWords()
Specified by:
gcHeaderWords in class PlanConstraints
Returns:
The number of header words that are required.

needsObjectReferenceWriteBarrier

public boolean needsObjectReferenceWriteBarrier()
Overrides:
needsObjectReferenceWriteBarrier in class PlanConstraints
Returns:
true if this Plan requires write barriers on object references.

needsObjectReferenceNonHeapWriteBarrier

public boolean needsObjectReferenceNonHeapWriteBarrier()
Overrides:
needsObjectReferenceNonHeapWriteBarrier in class PlanConstraints
Returns:
true if this Plan requires non-heap write barriers on object references.

objectReferenceBulkCopySupported

public boolean objectReferenceBulkCopySupported()
Overrides:
objectReferenceBulkCopySupported in class PlanConstraints
Returns:
true if this Plan can perform bulk object arraycopy barriers.

numSpecializedScans

public int numSpecializedScans()
Overrides:
numSpecializedScans in class PlanConstraints
Returns:
The specialized scan methods required

needsLogBitInHeader

public boolean needsLogBitInHeader()
Overrides:
needsLogBitInHeader in class PlanConstraints
Returns:
true if this Plan requires a header bit for object logging

maxNonLOSDefaultAllocBytes

public int maxNonLOSDefaultAllocBytes()
Overrides:
maxNonLOSDefaultAllocBytes in class PlanConstraints
Returns:
The maximum size of an object that may be allocated directly into the nursery