< prev index next >

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

Print this page

  1 /*
  2  * Copyright (c) 2018, 2021, Red Hat, Inc. All rights reserved.
  3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  4  *
  5  * This code is free software; you can redistribute it and/or modify it
  6  * under the terms of the GNU General Public License version 2 only, as
  7  * published by the Free Software Foundation.
  8  *
  9  * This code is distributed in the hope that it will be useful, but WITHOUT
 10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 12  * version 2 for more details (a copy is included in the LICENSE file that
 13  * accompanied this code).
 14  *
 15  * You should have received a copy of the GNU General Public License version
 16  * 2 along with this work; if not, write to the Free Software Foundation,
 17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 18  *
 19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 20  * or visit www.oracle.com if you need additional information or have any
 21  * questions.
 22  *
 23  */
 24 
 25 #include "precompiled.hpp"
 26 #include "gc/shared/gcArguments.hpp"
 27 #include "gc/shared/tlab_globals.hpp"
 28 #include "gc/shared/workerPolicy.hpp"
 29 #include "gc/shenandoah/shenandoahArguments.hpp"
 30 #include "gc/shenandoah/shenandoahCollectorPolicy.hpp"
 31 #include "gc/shenandoah/shenandoahHeap.inline.hpp"
 32 #include "gc/shenandoah/shenandoahHeapRegion.hpp"
 33 #include "runtime/globals_extension.hpp"
 34 #include "runtime/java.hpp"
 35 #include "utilities/defaultStream.hpp"
 36 
 37 void ShenandoahArguments::initialize() {
 38 #if !(defined AARCH64 || defined AMD64 || defined IA32 || defined PPC64)
 39   vm_exit_during_initialization("Shenandoah GC is not supported on this platform.");
 40 #endif
 41 
 42 #if 0 // leave this block as stepping stone for future platforms
 43   log_warning(gc)("Shenandoah GC is not fully supported on this platform:");
 44   log_warning(gc)("  concurrent modes are not supported, only STW cycles are enabled;");
 45   log_warning(gc)("  arch-specific barrier code is not implemented, disabling barriers;");
 46 
 47   FLAG_SET_DEFAULT(ShenandoahGCHeuristics,           "passive");
 48 
 49   FLAG_SET_DEFAULT(ShenandoahSATBBarrier,            false);
 50   FLAG_SET_DEFAULT(ShenandoahLoadRefBarrier,         false);
 51   FLAG_SET_DEFAULT(ShenandoahIUBarrier,              false);
 52   FLAG_SET_DEFAULT(ShenandoahCASBarrier,             false);
 53   FLAG_SET_DEFAULT(ShenandoahCloneBarrier,           false);
 54 
 55   FLAG_SET_DEFAULT(ShenandoahVerifyOptoBarriers,     false);
 56 #endif
 57   if (UseLargePages) {
 58     size_t large_page_size = os::large_page_size();

  1 /*
  2  * Copyright (c) 2018, 2022, Red Hat, Inc. All rights reserved.
  3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  4  *
  5  * This code is free software; you can redistribute it and/or modify it
  6  * under the terms of the GNU General Public License version 2 only, as
  7  * published by the Free Software Foundation.
  8  *
  9  * This code is distributed in the hope that it will be useful, but WITHOUT
 10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 12  * version 2 for more details (a copy is included in the LICENSE file that
 13  * accompanied this code).
 14  *
 15  * You should have received a copy of the GNU General Public License version
 16  * 2 along with this work; if not, write to the Free Software Foundation,
 17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 18  *
 19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 20  * or visit www.oracle.com if you need additional information or have any
 21  * questions.
 22  *
 23  */
 24 
 25 #include "precompiled.hpp"
 26 #include "gc/shared/gcArguments.hpp"
 27 #include "gc/shared/tlab_globals.hpp"
 28 #include "gc/shared/workerPolicy.hpp"
 29 #include "gc/shenandoah/shenandoahArguments.hpp"
 30 #include "gc/shenandoah/shenandoahCollectorPolicy.hpp"
 31 #include "gc/shenandoah/shenandoahHeap.inline.hpp"
 32 #include "gc/shenandoah/shenandoahHeapRegion.hpp"
 33 #include "runtime/globals_extension.hpp"
 34 #include "runtime/java.hpp"
 35 #include "utilities/defaultStream.hpp"
 36 
 37 void ShenandoahArguments::initialize() {
 38 #if !(defined AARCH64 || defined AMD64 || defined IA32 || defined PPC64 || defined RISCV64)
 39   vm_exit_during_initialization("Shenandoah GC is not supported on this platform.");
 40 #endif
 41 
 42 #if 0 // leave this block as stepping stone for future platforms
 43   log_warning(gc)("Shenandoah GC is not fully supported on this platform:");
 44   log_warning(gc)("  concurrent modes are not supported, only STW cycles are enabled;");
 45   log_warning(gc)("  arch-specific barrier code is not implemented, disabling barriers;");
 46 
 47   FLAG_SET_DEFAULT(ShenandoahGCHeuristics,           "passive");
 48 
 49   FLAG_SET_DEFAULT(ShenandoahSATBBarrier,            false);
 50   FLAG_SET_DEFAULT(ShenandoahLoadRefBarrier,         false);
 51   FLAG_SET_DEFAULT(ShenandoahIUBarrier,              false);
 52   FLAG_SET_DEFAULT(ShenandoahCASBarrier,             false);
 53   FLAG_SET_DEFAULT(ShenandoahCloneBarrier,           false);
 54 
 55   FLAG_SET_DEFAULT(ShenandoahVerifyOptoBarriers,     false);
 56 #endif
 57   if (UseLargePages) {
 58     size_t large_page_size = os::large_page_size();
< prev index next >