org.jikesrvm.compilers.baseline
Class JSRSubroutineInfo

java.lang.Object
  extended by org.jikesrvm.compilers.baseline.JSRSubroutineInfo

final class JSRSubroutineInfo
extends Object

This class is used during the building of reference/non-reference maps for a method. Once a JSR/RET combination has been processed, other JSR may be encountered that "jump" to the same subroutine. To calculate the maps of the instruction that is immediately after the JSR, we need the maps at the time of the JSR and the maps at the time of the RET.


Field Summary
 byte[] endReferenceMap
           
 int endReferenceTop
           
private  boolean hasMismatch
           
private static int JSRMismatchCount
           
private static int JSRRoutineCount
           
private static int JSRRoutinesWithMismatch
           
(package private)  int localsTop
           
 byte[] startReferenceMap
           
 int subroutineByteCodeStart
           
 
Constructor Summary
JSRSubroutineInfo(int subroutineByteCodeStart, byte[] startReferenceMap, int localsTop)
           
 
Method Summary
 byte[] computeResultingMaps(int mapLength)
           
 void newEndMaps(byte[] endReferenceMap, int endReferenceTop)
           
 void newStartMaps(byte[] startReferenceMap)
           
static void printStatistics()
          Prints out statistics about JSR subroutines and their starting maps
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

subroutineByteCodeStart

public int subroutineByteCodeStart

startReferenceMap

public byte[] startReferenceMap

localsTop

int localsTop

endReferenceMap

public byte[] endReferenceMap

endReferenceTop

public int endReferenceTop

JSRRoutineCount

private static int JSRRoutineCount

JSRMismatchCount

private static int JSRMismatchCount

JSRRoutinesWithMismatch

private static int JSRRoutinesWithMismatch

hasMismatch

private boolean hasMismatch
Constructor Detail

JSRSubroutineInfo

public JSRSubroutineInfo(int subroutineByteCodeStart,
                         byte[] startReferenceMap,
                         int localsTop)
Method Detail

newStartMaps

public void newStartMaps(byte[] startReferenceMap)

newEndMaps

public void newEndMaps(byte[] endReferenceMap,
                       int endReferenceTop)

computeResultingMaps

public byte[] computeResultingMaps(int mapLength)

printStatistics

public static void printStatistics()
Prints out statistics about JSR subroutines and their starting maps