Loop strip mining to decreases safepoint poll frequency
Roland Westrelin
rwestrel at redhat.com
Fri Mar 3 14:07:09 UTC 2017
> Something like this, then?
Actually || instead of && in the patch below when checking whether flags
have default value. Anyway, it's pushed.
Roland.
>
> diff --git a/src/share/vm/runtime/arguments.cpp b/src/share/vm/runtime/arguments.cpp
> --- a/src/share/vm/runtime/arguments.cpp
> +++ b/src/share/vm/runtime/arguments.cpp
> @@ -2630,8 +2630,16 @@
> }
> FLAG_SET_CMDLINE(bool, PostLoopMultiversioning, false);
> }
> - if (UseCountedLoopSafepoints) {
> + if (UseCountedLoopSafepoints && LoopStripMiningIter == 0) {
> + if (!FLAG_IS_DEFAULT(UseCountedLoopSafepoints) && !FLAG_IS_DEFAULT(LoopStripMiningIter)) {
> + warning("When counted loop safepoints are enabled, LoopStripMiningIter must be at least 1 (a safepoint every 1 iteration): setting it to 1");
> + }
> LoopStripMiningIter = 1;
> + } else if (!UseCountedLoopSafepoints && LoopStripMiningIter > 0) {
> + if (!FLAG_IS_DEFAULT(UseCountedLoopSafepoints) && !FLAG_IS_DEFAULT(LoopStripMiningIter)) {
> + warning("Disabling counted safepoints implies no loop strip mining: setting LoopStripMiningIter to 0");
> + }
> + LoopStripMiningIter = 0;
> }
> #endif
> return status;
>
> Roland.
More information about the shenandoah-dev
mailing list