< prev index next >

hotspot/test/runtime/CommandLine/OptionsValidation/TestOptionsWithRanges.java

Print this page




  72     }
  73 
  74     public static void main(String[] args) throws Exception {
  75         int failedTests;
  76         List<JVMOption> allOptions;
  77 
  78         allOptionsAsMap = JVMOptionsUtils.getOptionsWithRangeAsMap(origin -> (!(origin.contains("develop") || origin.contains("notproduct"))));
  79 
  80         /* Shared flags can cause JVM to exit with error code 2 */
  81         setAllowedExitCodes("SharedReadWriteSize", 2);
  82         setAllowedExitCodes("SharedReadOnlySize", 2);
  83         setAllowedExitCodes("SharedMiscDataSize", 2);
  84         setAllowedExitCodes("SharedMiscCodeSize", 2);
  85 
  86         /*
  87          * Remove CICompilerCount from testing because currently it can hang system
  88          */
  89         excludeTestMaxRange("CICompilerCount");
  90 
  91         /*
  92          * JDK-8136766
  93          * Temporarily remove ThreadStackSize from testing because Windows can set it to 0
  94          * (for default OS size) but other platforms insist it must be greater than 0
  95         */
  96         excludeTestRange("ThreadStackSize");
  97 
  98         /*
  99          * Remove the flag controlling the size of the stack because the
 100          * flag has direct influence on the physical memory usage of
 101          * the VM.
 102          */
 103         allOptionsAsMap.remove("CompilerThreadStackSize");
 104 
 105         /*
 106          * Exclude MallocMaxTestWords as it is expected to exit VM at small values (>=0)
 107          */
 108         excludeTestMinRange("MallocMaxTestWords");
 109 
 110         /*
 111          * Exclude below options as their maximum value would consume too much memory
 112          * and would affect other tests that run in parallel.
 113          */
 114         excludeTestMaxRange("ConcGCThreads");
 115         excludeTestMaxRange("G1ConcRefinementThreads");
 116         excludeTestMaxRange("G1RSetRegionEntries");
 117         excludeTestMaxRange("G1RSetSparseRegionEntries");
 118         excludeTestMaxRange("G1UpdateBufferSize");
 119         excludeTestMaxRange("InitialBootClassLoaderMetaspaceSize");
 120         excludeTestMaxRange("InitialHeapSize");
 121         excludeTestMaxRange("MaxHeapSize");
 122         excludeTestMaxRange("MaxRAM");
 123         excludeTestMaxRange("NewSize");
 124         excludeTestMaxRange("OldSize");
 125         excludeTestMaxRange("ParallelGCThreads");
 126 


 127         excludeTestMaxRange("VMThreadStackSize");
 128 
 129         /*
 130          * Remove parameters controlling the code cache. As these
 131          * parameters have implications on the physical memory
 132          * reserved by the VM, setting them to large values may hang
 133          * the system and/or may cause concurrently executed tests to
 134          * fail. These parameters are rigorously checked when the code
 135          * cache is initialized (see
 136          * hotspot/src/shared/vm/code/codeCache.cpp), therefore
 137          * omitting testing for them does not pose a problem.
 138          */
 139         excludeTestMaxRange("InitialCodeCacheSize");
 140         excludeTestMaxRange("CodeCacheMinimumUseSpace");
 141         excludeTestMaxRange("ReservedCodeCacheSize");
 142         excludeTestMaxRange("NonProfiledCodeHeapSize");
 143         excludeTestMaxRange("ProfiledCodeHeapSize");
 144         excludeTestMaxRange("NonNMethodCodeHeapSize");
 145         excludeTestMaxRange("CodeCacheExpansionSize");
 146 


  72     }
  73 
  74     public static void main(String[] args) throws Exception {
  75         int failedTests;
  76         List<JVMOption> allOptions;
  77 
  78         allOptionsAsMap = JVMOptionsUtils.getOptionsWithRangeAsMap(origin -> (!(origin.contains("develop") || origin.contains("notproduct"))));
  79 
  80         /* Shared flags can cause JVM to exit with error code 2 */
  81         setAllowedExitCodes("SharedReadWriteSize", 2);
  82         setAllowedExitCodes("SharedReadOnlySize", 2);
  83         setAllowedExitCodes("SharedMiscDataSize", 2);
  84         setAllowedExitCodes("SharedMiscCodeSize", 2);
  85 
  86         /*
  87          * Remove CICompilerCount from testing because currently it can hang system
  88          */
  89         excludeTestMaxRange("CICompilerCount");
  90 
  91         /*














  92          * Exclude MallocMaxTestWords as it is expected to exit VM at small values (>=0)
  93          */
  94         excludeTestMinRange("MallocMaxTestWords");
  95 
  96         /*
  97          * Exclude below options as their maximum value would consume too much memory
  98          * and would affect other tests that run in parallel.
  99          */
 100         excludeTestMaxRange("ConcGCThreads");
 101         excludeTestMaxRange("G1ConcRefinementThreads");
 102         excludeTestMaxRange("G1RSetRegionEntries");
 103         excludeTestMaxRange("G1RSetSparseRegionEntries");
 104         excludeTestMaxRange("G1UpdateBufferSize");
 105         excludeTestMaxRange("InitialBootClassLoaderMetaspaceSize");
 106         excludeTestMaxRange("InitialHeapSize");
 107         excludeTestMaxRange("MaxHeapSize");
 108         excludeTestMaxRange("MaxRAM");
 109         excludeTestMaxRange("NewSize");
 110         excludeTestMaxRange("OldSize");
 111         excludeTestMaxRange("ParallelGCThreads");
 112 
 113         excludeTestMaxRange("CompilerThreadStackSize");
 114         excludeTestMaxRange("ThreadStackSize");
 115         excludeTestMaxRange("VMThreadStackSize");
 116 
 117         /*
 118          * Remove parameters controlling the code cache. As these
 119          * parameters have implications on the physical memory
 120          * reserved by the VM, setting them to large values may hang
 121          * the system and/or may cause concurrently executed tests to
 122          * fail. These parameters are rigorously checked when the code
 123          * cache is initialized (see
 124          * hotspot/src/shared/vm/code/codeCache.cpp), therefore
 125          * omitting testing for them does not pose a problem.
 126          */
 127         excludeTestMaxRange("InitialCodeCacheSize");
 128         excludeTestMaxRange("CodeCacheMinimumUseSpace");
 129         excludeTestMaxRange("ReservedCodeCacheSize");
 130         excludeTestMaxRange("NonProfiledCodeHeapSize");
 131         excludeTestMaxRange("ProfiledCodeHeapSize");
 132         excludeTestMaxRange("NonNMethodCodeHeapSize");
 133         excludeTestMaxRange("CodeCacheExpansionSize");
 134 
< prev index next >