< prev index next >

src/hotspot/share/gc/shenandoah/shenandoahArguments.cpp

Print this page
rev 53264 : Enable TLHS by default (again)


 117            !FLAG_IS_DEFAULT(ShenandoahCASBarrier)             ||
 118            !FLAG_IS_DEFAULT(ShenandoahAcmpBarrier)            ||
 119            !FLAG_IS_DEFAULT(ShenandoahCloneBarrier)
 120           )) {
 121     warning("Unusual barrier configuration, disabling C2 barrier verification");
 122     FLAG_SET_DEFAULT(ShenandoahVerifyOptoBarriers, false);
 123   }
 124 #else
 125   guarantee(!ShenandoahVerifyOptoBarriers, "Should be disabled");
 126 #endif // ASSERT
 127 #endif // COMPILER2
 128 
 129   if (AlwaysPreTouch) {
 130     // Shenandoah handles pre-touch on its own. It does not let the
 131     // generic storage code to do the pre-touch before Shenandoah has
 132     // a chance to do it on its own.
 133     FLAG_SET_DEFAULT(AlwaysPreTouch, false);
 134     FLAG_SET_DEFAULT(ShenandoahAlwaysPreTouch, true);
 135   }
 136 
 137   // Shenandoah C2 optimizations apparently dislike the shape of thread-local handshakes.
 138   // Disable it by default, unless we enable it specifically for debugging.
 139   if (FLAG_IS_DEFAULT(ThreadLocalHandshakes)) {
 140     if (ThreadLocalHandshakes) {
 141       FLAG_SET_DEFAULT(ThreadLocalHandshakes, false);
 142     }
 143   } else {
 144     if (ThreadLocalHandshakes) {
 145       warning("Thread-local handshakes are not working correctly with Shenandoah at the moment. Enable at your own risk.");
 146     }
 147   }
 148 
 149   // Record more information about previous cycles for improved debugging pleasure
 150   if (FLAG_IS_DEFAULT(LogEventsBufferEntries)) {
 151     FLAG_SET_DEFAULT(LogEventsBufferEntries, 250);
 152   }
 153 
 154   if (ShenandoahAlwaysPreTouch) {
 155     if (!FLAG_IS_DEFAULT(ShenandoahUncommit)) {
 156       warning("AlwaysPreTouch is enabled, disabling ShenandoahUncommit");
 157     }
 158     FLAG_SET_DEFAULT(ShenandoahUncommit, false);
 159   }
 160 
 161   // If class unloading is disabled, no unloading for concurrent cycles as well.
 162   // If class unloading is enabled, users should opt-in for unloading during
 163   // concurrent cycles.
 164   if (!ClassUnloading || !FLAG_IS_CMDLINE(ClassUnloadingWithConcurrentMark)) {
 165     log_info(gc)("Consider -XX:+ClassUnloadingWithConcurrentMark if large pause times "
 166                  "are observed on class-unloading sensitive workloads");
 167     FLAG_SET_DEFAULT(ClassUnloadingWithConcurrentMark, false);
 168   }




 117            !FLAG_IS_DEFAULT(ShenandoahCASBarrier)             ||
 118            !FLAG_IS_DEFAULT(ShenandoahAcmpBarrier)            ||
 119            !FLAG_IS_DEFAULT(ShenandoahCloneBarrier)
 120           )) {
 121     warning("Unusual barrier configuration, disabling C2 barrier verification");
 122     FLAG_SET_DEFAULT(ShenandoahVerifyOptoBarriers, false);
 123   }
 124 #else
 125   guarantee(!ShenandoahVerifyOptoBarriers, "Should be disabled");
 126 #endif // ASSERT
 127 #endif // COMPILER2
 128 
 129   if (AlwaysPreTouch) {
 130     // Shenandoah handles pre-touch on its own. It does not let the
 131     // generic storage code to do the pre-touch before Shenandoah has
 132     // a chance to do it on its own.
 133     FLAG_SET_DEFAULT(AlwaysPreTouch, false);
 134     FLAG_SET_DEFAULT(ShenandoahAlwaysPreTouch, true);
 135   }
 136 












 137   // Record more information about previous cycles for improved debugging pleasure
 138   if (FLAG_IS_DEFAULT(LogEventsBufferEntries)) {
 139     FLAG_SET_DEFAULT(LogEventsBufferEntries, 250);
 140   }
 141 
 142   if (ShenandoahAlwaysPreTouch) {
 143     if (!FLAG_IS_DEFAULT(ShenandoahUncommit)) {
 144       warning("AlwaysPreTouch is enabled, disabling ShenandoahUncommit");
 145     }
 146     FLAG_SET_DEFAULT(ShenandoahUncommit, false);
 147   }
 148 
 149   // If class unloading is disabled, no unloading for concurrent cycles as well.
 150   // If class unloading is enabled, users should opt-in for unloading during
 151   // concurrent cycles.
 152   if (!ClassUnloading || !FLAG_IS_CMDLINE(ClassUnloadingWithConcurrentMark)) {
 153     log_info(gc)("Consider -XX:+ClassUnloadingWithConcurrentMark if large pause times "
 154                  "are observed on class-unloading sensitive workloads");
 155     FLAG_SET_DEFAULT(ClassUnloadingWithConcurrentMark, false);
 156   }


< prev index next >