< prev index next >

test/compiler/whitebox/CompilerWhiteBoxTest.java

Print this page




  53     /** Instance of WhiteBox */
  54     protected static final WhiteBox WHITE_BOX = WhiteBox.getWhiteBox();
  55     /** Value of {@code -XX:CompileThreshold} */
  56     protected static final int COMPILE_THRESHOLD
  57             = Integer.parseInt(getVMOption("CompileThreshold", "10000"));
  58     /** Value of {@code -XX:BackgroundCompilation} */
  59     protected static final boolean BACKGROUND_COMPILATION
  60             = Boolean.valueOf(getVMOption("BackgroundCompilation", "true"));
  61     /** Value of {@code -XX:TieredCompilation} */
  62     protected static final boolean TIERED_COMPILATION
  63             = Boolean.valueOf(getVMOption("TieredCompilation", "false"));
  64     /** Value of {@code -XX:TieredStopAtLevel} */
  65     protected static final int TIERED_STOP_AT_LEVEL
  66             = Integer.parseInt(getVMOption("TieredStopAtLevel", "0"));
  67     /** Flag for verbose output, true if {@code -Dverbose} specified */
  68     protected static final boolean IS_VERBOSE
  69             = System.getProperty("verbose") != null;
  70     /** invocation count to trigger compilation */
  71     public static final int THRESHOLD;
  72     /** invocation count to trigger OSR compilation */
  73     protected static final long BACKEDGE_THRESHOLD;
  74     /** Value of {@code java.vm.info} (interpreted|mixed|comp mode) */
  75     protected static final String MODE = System.getProperty("java.vm.info");
  76 
  77     static {
  78         if (TIERED_COMPILATION) {
  79             BACKEDGE_THRESHOLD = THRESHOLD = 150000;
  80         } else {
  81             THRESHOLD = COMPILE_THRESHOLD;
  82             BACKEDGE_THRESHOLD = COMPILE_THRESHOLD * Long.parseLong(getVMOption(
  83                     "OnStackReplacePercentage"));
  84         }
  85     }
  86 
  87     /**
  88      * Returns value of VM option.
  89      *
  90      * @param name option's name
  91      * @return value of option or {@code null}, if option doesn't exist
  92      * @throws NullPointerException if name is null
  93      */




  53     /** Instance of WhiteBox */
  54     protected static final WhiteBox WHITE_BOX = WhiteBox.getWhiteBox();
  55     /** Value of {@code -XX:CompileThreshold} */
  56     protected static final int COMPILE_THRESHOLD
  57             = Integer.parseInt(getVMOption("CompileThreshold", "10000"));
  58     /** Value of {@code -XX:BackgroundCompilation} */
  59     protected static final boolean BACKGROUND_COMPILATION
  60             = Boolean.valueOf(getVMOption("BackgroundCompilation", "true"));
  61     /** Value of {@code -XX:TieredCompilation} */
  62     protected static final boolean TIERED_COMPILATION
  63             = Boolean.valueOf(getVMOption("TieredCompilation", "false"));
  64     /** Value of {@code -XX:TieredStopAtLevel} */
  65     protected static final int TIERED_STOP_AT_LEVEL
  66             = Integer.parseInt(getVMOption("TieredStopAtLevel", "0"));
  67     /** Flag for verbose output, true if {@code -Dverbose} specified */
  68     protected static final boolean IS_VERBOSE
  69             = System.getProperty("verbose") != null;
  70     /** invocation count to trigger compilation */
  71     public static final int THRESHOLD;
  72     /** invocation count to trigger OSR compilation */
  73     public static final long BACKEDGE_THRESHOLD;
  74     /** Value of {@code java.vm.info} (interpreted|mixed|comp mode) */
  75     protected static final String MODE = System.getProperty("java.vm.info");
  76 
  77     static {
  78         if (TIERED_COMPILATION) {
  79             BACKEDGE_THRESHOLD = THRESHOLD = 150000;
  80         } else {
  81             THRESHOLD = COMPILE_THRESHOLD;
  82             BACKEDGE_THRESHOLD = COMPILE_THRESHOLD * Long.parseLong(getVMOption(
  83                     "OnStackReplacePercentage"));
  84         }
  85     }
  86 
  87     /**
  88      * Returns value of VM option.
  89      *
  90      * @param name option's name
  91      * @return value of option or {@code null}, if option doesn't exist
  92      * @throws NullPointerException if name is null
  93      */


< prev index next >