< prev index next >

src/hotspot/share/gc/shenandoah/shenandoah_globals.hpp

Print this page
@@ -60,11 +60,12 @@
    product(ccstr, ShenandoahGCMode, "satb",                                  \
            "GC mode to use.  Among other things, this defines which "        \
            "barriers are in in use. Possible values are:"                    \
            " satb - snapshot-at-the-beginning concurrent GC (three pass mark-evac-update);"  \
            " iu - incremental-update concurrent GC (three pass mark-evac-update);"  \
-           " passive - stop the world GC only (either degenerated or full)") \
+           " passive - stop the world GC only (either degenerated or full);" \
+           " generational - generational concurrent GC")                     \
                                                                              \
    product(ccstr, ShenandoahGCHeuristics, "adaptive",                        \
            "GC heuristics to use. This fine-tunes the GC mode selected, "    \
            "by choosing when to start the GC, how much to process on each "  \
            "cycle, and what other features to automatically enable. "        \

@@ -74,10 +75,16 @@
            " static -  trigger GC when free heap falls below the threshold;" \
            " aggressive - run GC continuously, try to evacuate everything;"  \
            " compact - run GC more frequently and with deeper targets to "   \
            "free up more memory.")                                           \
                                                                              \
+   product(ccstr, ShenandoahOldGCHeuristics, "adaptive",                     \
+           "Similar to ShenandoahGCHeuristics, but applied to the old "      \
+           "generation. This configuration is only used to trigger old "     \
+           "collections and does not change how regions are selected "       \
+           "for collection.")                                                \
+                                                                             \
    product(uintx, ShenandoahUnloadClassesFrequency, 1, EXPERIMENTAL,         \
            "Unload the classes every Nth cycle. Normally affects concurrent "\
            "GC cycles, as degenerated and full GCs would try to unload "     \
            "classes regardless. Set to zero to disable class unloading.")    \
                                                                              \

@@ -87,21 +94,27 @@
            "may select the region for collection even if it has little "     \
            "garbage. This also affects how much internal fragmentation the " \
            "collector accepts. In percents of heap region size.")            \
            range(0,100)                                                      \
                                                                              \
+   product(uintx, ShenandoahOldGarbageThreshold, 25, EXPERIMENTAL,           \
+           "How much garbage an old region has to contain before it would "  \
+           "be taken for collection.")                                       \
+           range(0,100)                                                      \
+                                                                             \
    product(uintx, ShenandoahInitFreeThreshold, 70, EXPERIMENTAL,             \
            "How much heap should be free before some heuristics trigger the "\
            "initial (learning) cycles. Affects cycle frequency on startup "  \
            "and after drastic state changes, e.g. after degenerated/full "   \
            "GC cycles. In percents of (soft) max heap size.")                \
            range(0,100)                                                      \
                                                                              \
    product(uintx, ShenandoahMinFreeThreshold, 10, EXPERIMENTAL,              \
-           "How much heap should be free before most heuristics trigger the "\
-           "collection, even without other triggers. Provides the safety "   \
-           "margin for many heuristics. In percents of (soft) max heap size.")\
+           "Percentage of free heap memory below which most heuristics "     \
+           "trigger collection independent of other triggers. Provides "     \
+           "a safety margin for many heuristics. In percents of (soft) "     \
+           "max heap size.")                                                 \
            range(0,100)                                                      \
                                                                              \
    product(uintx, ShenandoahAllocationThreshold, 0, EXPERIMENTAL,            \
            "How many new allocations should happen since the last GC cycle " \
            "before some heuristics trigger the collection. In percents of "  \

@@ -160,10 +173,15 @@
            "least with this interval. This is useful when large idle "       \
            "intervals are present, where GC can run without stealing "       \
            "time from active application. Time is in milliseconds. "         \
            "Setting this to 0 disables the feature.")                        \
                                                                              \
+   product(uintx, ShenandoahGuaranteedOldGCInterval, 10*60*1000,  EXPERIMENTAL,  \
+           "Run a collection of the old generation at least this often. "    \
+           "Heuristics may trigger collections more frequently. Time is in " \
+           "milliseconds. Setting this to 0 disables the feature.")          \
+                                                                             \
    product(bool, ShenandoahAlwaysClearSoftRefs, false, EXPERIMENTAL,         \
            "Unconditionally clear soft references, instead of using any "    \
            "other cleanup policy. This minimizes footprint at expense of"    \
            "more soft reference churn in applications.")                     \
                                                                              \

@@ -187,10 +205,19 @@
    product(int, ShenandoahRegionSamplingRate, 40, EXPERIMENTAL,              \
            "Sampling rate for heap region sampling. In milliseconds between "\
            "the samples. Higher values provide more fidelity, at expense "   \
            "of more sampling overhead.")                                     \
                                                                              \
+   product(bool, ShenandoahLogRegionSampling, false,                         \
+           "Save region sampling stream to ShenandoahRegionSamplingFile")    \
+                                                                             \
+   product(ccstr, ShenandoahRegionSamplingFile,                              \
+           "./shenandoahSnapshots_pid%p.log",                                \
+           "If ShenandoahLogRegionSampling is on, save sampling data stream "\
+           "to this file [default: ./shenandoahSnapshots_pid%p.log] "        \
+           "(%p replaced with pid)")                                         \
+                                                                             \
    product(uintx, ShenandoahControlIntervalMin, 1, EXPERIMENTAL,             \
            "The minimum sleep interval for the control loop that drives "    \
            "the cycles. Lower values would increase GC responsiveness "      \
            "to changing heap conditions, at the expense of higher perf "     \
            "overhead. Time is in milliseconds.")                             \

@@ -221,10 +248,14 @@
            " 4 = previous level, plus all marked objects")                   \
                                                                              \
    product(bool, ShenandoahElasticTLAB, true, DIAGNOSTIC,                    \
            "Use Elastic TLABs with Shenandoah")                              \
                                                                              \
+   product(bool, ShenandoahUsePLAB, true, DIAGNOSTIC,                        \
+           "Use PLABs for object promotions with Shenandoah, "               \
+           "if in generational mode and UseTLAB is also set.")               \
+                                                                             \
    product(uintx, ShenandoahEvacReserve, 5, EXPERIMENTAL,                    \
            "How much of heap to reserve for evacuations. Larger values make "\
            "GC evacuate more live objects on every cycle, while leaving "    \
            "less headroom for application to allocate in. In percents of "   \
            "total heap size.")                                               \

@@ -241,10 +272,16 @@
            "Allow evacuations to overflow the reserved space. Enabling it "  \
            "will make evacuations more resilient when evacuation "           \
            "reserve/waste is incorrect, at the risk that application "       \
            "runs out of memory too early.")                                  \
                                                                              \
+   product(double, ShenandoahOldEvacReserve, 5.0, EXPERIMENTAL,              \
+           "How much of old generation to withhold from evacuations. "       \
+            "Larger values will result in fewer live objects being "         \
+            "evacuated in the old generation.")                              \
+           range(1,100)                                                      \
+                                                                             \
    product(bool, ShenandoahPacing, true, EXPERIMENTAL,                       \
            "Pace application allocations to give GC chance to start "        \
            "and complete before allocation failure is reached.")             \
                                                                              \
    product(uintx, ShenandoahPacingMaxDelay, 10, EXPERIMENTAL,                \

@@ -364,10 +401,41 @@
    product(bool, ShenandoahLoopOptsAfterExpansion, true, DIAGNOSTIC,         \
            "Attempt more loop opts after barrier expansion.")                \
                                                                              \
    product(bool, ShenandoahSelfFixing, true, DIAGNOSTIC,                     \
            "Fix references with load reference barrier. Disabling this "     \
-           "might degrade performance.")
+           "might degrade performance.")                                     \
+                                                                             \
+   product(uintx, ShenandoahTenuredRegionUsageBias, 192, EXPERIMENTAL,       \
+           "The collection set is comprised of heap regions that contain "   \
+           "the greatest amount of garbage.  "                               \
+           "For purposes of selecting regions to be included in the "        \
+           "collection set, regions that have reached the tenure age will "  \
+           "be treated as if their contained garbage is the actual "         \
+           "contained garbage multiplied by "                                \
+           "(ShenandoahTenuredRegionUsageBias / 128 (e.g. 150% for the "     \
+           "default value) as many times as the region's age meets or "      \
+           "exceeds the tenure age.  For example, if tenure age is 7, "      \
+           "the region age is 9, ShenandoahTenuredRegionUsageBias is "       \
+           "192, and the region is 12.5% garbage, this region "              \
+           "will by treated as if its garbage content is "                   \
+           "1/8 * 27/8 = 42.2% when comparing this region to untenured "     \
+           "regions.")                                                       \
+           range(128, 256)                                                   \
+                                                                             \
+   product(bool, ShenandoahPromoteTenuredObjects, true, DIAGNOSTIC,          \
+           "Turn on/off evacuating individual tenured young objects "        \
+           " to the old generation.")                                        \
+                                                                             \
+   product(bool, ShenandoahAllowOldMarkingPreemption, true, DIAGNOSTIC,      \
+           "Allow young generation collections to suspend concurrent"        \
+           " marking in the old generation.")                                \
+                                                                             \
+   product(uintx, ShenandoahAgingCyclePeriod, 1, EXPERIMENTAL,               \
+           "With generational mode, increment the age of objects and"        \
+           "regions each time this many young-gen GC cycles are completed.")
+  // end of GC_SHENANDOAH_FLAGS
  
- // end of GC_SHENANDOAH_FLAGS
+ // 2^ShenandoahTenuredRegionUsageBiasLogBase2 is 128
+ #define ShenandoahTenuredRegionUsageBiasLogBase2 7
  
  #endif // SHARE_GC_SHENANDOAH_SHENANDOAH_GLOBALS_HPP
< prev index next >