globals.hpp revision 11663:d3d20ddd3ff3
1298192Sdelphij/* 2298192Sdelphij * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. 3298192Sdelphij * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4298192Sdelphij * 5298192Sdelphij * This code is free software; you can redistribute it and/or modify it 6298192Sdelphij * under the terms of the GNU General Public License version 2 only, as 7298192Sdelphij * published by the Free Software Foundation. 8298192Sdelphij * 9298192Sdelphij * This code is distributed in the hope that it will be useful, but WITHOUT 10298192Sdelphij * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11298192Sdelphij * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12298192Sdelphij * version 2 for more details (a copy is included in the LICENSE file that 13298192Sdelphij * accompanied this code). 14298192Sdelphij * 15298192Sdelphij * You should have received a copy of the GNU General Public License version 16298192Sdelphij * 2 along with this work; if not, write to the Free Software Foundation, 17298192Sdelphij * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18298192Sdelphij * 19298192Sdelphij * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20298192Sdelphij * or visit www.oracle.com if you need additional information or have any 21298192Sdelphij * questions. 22298192Sdelphij * 23298192Sdelphij */ 24298192Sdelphij 25298192Sdelphij#ifndef SHARE_VM_RUNTIME_GLOBALS_HPP 26298192Sdelphij#define SHARE_VM_RUNTIME_GLOBALS_HPP 27298192Sdelphij 28298192Sdelphij#include "utilities/debug.hpp" 29298192Sdelphij#include "utilities/macros.hpp" 30298192Sdelphij 31298192Sdelphij#include <float.h> // for DBL_MAX 32298192Sdelphij 33298192Sdelphij// use this for flags that are true per default in the tiered build 34298192Sdelphij// but false in non-tiered builds, and vice versa 35298192Sdelphij#ifdef TIERED 36298192Sdelphij#define trueInTiered true 37298192Sdelphij#define falseInTiered false 38298192Sdelphij#else 39298192Sdelphij#define trueInTiered false 40298192Sdelphij#define falseInTiered true 41298192Sdelphij#endif 42298192Sdelphij 43298192Sdelphij#include CPU_HEADER(globals) 44298192Sdelphij#include OS_HEADER(globals) 45298192Sdelphij#include OS_CPU_HEADER(globals) 46298192Sdelphij#ifdef COMPILER1 47288143Sdelphij#include CPU_HEADER(c1_globals) 48288143Sdelphij#include OS_HEADER(c1_globals) 49288143Sdelphij#endif 50288143Sdelphij#ifdef COMPILER2 51288143Sdelphij#include CPU_HEADER(c2_globals) 52288143Sdelphij#include OS_HEADER(c2_globals) 53288143Sdelphij#endif 54288143Sdelphij#ifdef SHARK 55288143Sdelphij#ifdef ZERO 56288143Sdelphij# include "shark_globals_zero.hpp" 57288143Sdelphij#endif 58288143Sdelphij#endif 59288143Sdelphij 60288143Sdelphij#if !defined(COMPILER1) && !defined(COMPILER2) && !defined(SHARK) && !INCLUDE_JVMCI 61288143Sdelphijdefine_pd_global(bool, BackgroundCompilation, false); 62288143Sdelphijdefine_pd_global(bool, UseTLAB, false); 63287453Sdelphijdefine_pd_global(bool, CICompileOSR, false); 64287453Sdelphijdefine_pd_global(bool, UseTypeProfile, false); 65287453Sdelphijdefine_pd_global(bool, UseOnStackReplacement, false); 66287453Sdelphijdefine_pd_global(bool, InlineIntrinsics, false); 67284277Sdelphijdefine_pd_global(bool, PreferInterpreterNativeStubs, true); 68284237Sdelphijdefine_pd_global(bool, ProfileInterpreter, false); 69284277Sdelphijdefine_pd_global(bool, ProfileTraps, false); 70284277Sdelphijdefine_pd_global(bool, TieredCompilation, false); 71284237Sdelphij 72284237Sdelphijdefine_pd_global(intx, CompileThreshold, 0); 73284237Sdelphij 74284237Sdelphijdefine_pd_global(intx, OnStackReplacePercentage, 0); 75284237Sdelphijdefine_pd_global(bool, ResizeTLAB, false); 76284237Sdelphijdefine_pd_global(intx, FreqInlineSize, 0); 77284237Sdelphijdefine_pd_global(size_t, NewSizeThreadIncrease, 4*K); 78284237Sdelphijdefine_pd_global(intx, InlineClassNatives, true); 79284237Sdelphijdefine_pd_global(intx, InlineUnsafeOps, true); 80284237Sdelphijdefine_pd_global(intx, InitialCodeCacheSize, 160*K); 81284237Sdelphijdefine_pd_global(intx, ReservedCodeCacheSize, 32*M); 82284237Sdelphijdefine_pd_global(intx, NonProfiledCodeHeapSize, 0); 83284237Sdelphijdefine_pd_global(intx, ProfiledCodeHeapSize, 0); 84284237Sdelphijdefine_pd_global(intx, NonNMethodCodeHeapSize, 32*M); 85284237Sdelphij 86284237Sdelphijdefine_pd_global(intx, CodeCacheExpansionSize, 32*K); 87284237Sdelphijdefine_pd_global(intx, CodeCacheMinBlockLength, 1); 88284237Sdelphijdefine_pd_global(intx, CodeCacheMinimumUseSpace, 200*K); 89284237Sdelphijdefine_pd_global(size_t, MetaspaceSize, ScaleForWordSize(4*M)); 90284237Sdelphijdefine_pd_global(bool, NeverActAsServerClassMachine, true); 91284237Sdelphijdefine_pd_global(uint64_t,MaxRAM, 1ULL*G); 92284237Sdelphij#define CI_COMPILER_COUNT 0 93284237Sdelphij#else 94284237Sdelphij 95284237Sdelphij#if defined(COMPILER2) || INCLUDE_JVMCI 96284237Sdelphij#define CI_COMPILER_COUNT 2 97284237Sdelphij#else 98284237Sdelphij#define CI_COMPILER_COUNT 1 99284237Sdelphij#endif // COMPILER2 || INCLUDE_JVMCI 100284237Sdelphij 101284237Sdelphij#endif // no compilers 102284237Sdelphij 103284237Sdelphij// string type aliases used only in this file 104284237Sdelphijtypedef const char* ccstr; 105284237Sdelphijtypedef const char* ccstrlist; // represents string arguments which accumulate 106284237Sdelphij 107284237Sdelphij// function type that will construct default range string 108284237Sdelphijtypedef const char* (*RangeStrFunc)(void); 109284237Sdelphij 110284237Sdelphijstruct Flag { 111284237Sdelphij enum Flags { 112284237Sdelphij // latest value origin 113284237Sdelphij DEFAULT = 0, 114284237Sdelphij COMMAND_LINE = 1, 115284237Sdelphij ENVIRON_VAR = 2, 116284237Sdelphij CONFIG_FILE = 3, 117284237Sdelphij MANAGEMENT = 4, 118284237Sdelphij ERGONOMIC = 5, 119284237Sdelphij ATTACH_ON_DEMAND = 6, 120276577Sdelphij INTERNAL = 7, 121276577Sdelphij 122276577Sdelphij LAST_VALUE_ORIGIN = INTERNAL, 123276577Sdelphij VALUE_ORIGIN_BITS = 4, 124276577Sdelphij VALUE_ORIGIN_MASK = right_n_bits(VALUE_ORIGIN_BITS), 125276577Sdelphij 126276577Sdelphij // flag kind 127276577Sdelphij KIND_PRODUCT = 1 << 4, 128276577Sdelphij KIND_MANAGEABLE = 1 << 5, 129276577Sdelphij KIND_DIAGNOSTIC = 1 << 6, 130276577Sdelphij KIND_EXPERIMENTAL = 1 << 7, 131276577Sdelphij KIND_NOT_PRODUCT = 1 << 8, 132276577Sdelphij KIND_DEVELOP = 1 << 9, 133276577Sdelphij KIND_PLATFORM_DEPENDENT = 1 << 10, 134276577Sdelphij KIND_READ_WRITE = 1 << 11, 135276577Sdelphij KIND_C1 = 1 << 12, 136276577Sdelphij KIND_C2 = 1 << 13, 137276577Sdelphij KIND_ARCH = 1 << 14, 138276577Sdelphij KIND_SHARK = 1 << 15, 139276577Sdelphij KIND_LP64_PRODUCT = 1 << 16, 140276577Sdelphij KIND_COMMERCIAL = 1 << 17, 141276577Sdelphij KIND_JVMCI = 1 << 18, 142276577Sdelphij 143276577Sdelphij // set this bit if the flag was set on the command line 144276577Sdelphij ORIG_COMMAND_LINE = 1 << 19, 145276577Sdelphij 146275698Sdelphij KIND_MASK = ~(VALUE_ORIGIN_MASK | ORIG_COMMAND_LINE) 147275698Sdelphij }; 148275698Sdelphij 149275698Sdelphij enum Error { 150275698Sdelphij // no error 151275698Sdelphij SUCCESS = 0, 152275698Sdelphij // flag name is missing 153275698Sdelphij MISSING_NAME, 154275698Sdelphij // flag value is missing 155275698Sdelphij MISSING_VALUE, 156275698Sdelphij // error parsing the textual form of the value 157275698Sdelphij WRONG_FORMAT, 158275698Sdelphij // flag is not writable 159275698Sdelphij NON_WRITABLE, 160275698Sdelphij // flag value is outside of its bounds 161275698Sdelphij OUT_OF_BOUNDS, 162275698Sdelphij // flag value violates its constraint 163275698Sdelphij VIOLATES_CONSTRAINT, 164275698Sdelphij // there is no flag with the given name 165275698Sdelphij INVALID_FLAG, 166275698Sdelphij // the flag can only be set only on command line during invocation of the VM 167275698Sdelphij COMMAND_LINE_ONLY, 168275698Sdelphij // the flag may only be set once 169275698Sdelphij SET_ONLY_ONCE, 170275698Sdelphij // the flag is not writable in this combination of product/debug build 171276577Sdelphij CONSTANT, 172276577Sdelphij // other, unspecified error related to setting the flag 173275698Sdelphij ERR_OTHER 174275698Sdelphij }; 175275698Sdelphij 176275698Sdelphij enum MsgType { 177275698Sdelphij NONE = 0, 178275698Sdelphij DIAGNOSTIC_FLAG_BUT_LOCKED, 179275698Sdelphij EXPERIMENTAL_FLAG_BUT_LOCKED, 180275698Sdelphij DEVELOPER_FLAG_BUT_PRODUCT_BUILD, 181275698Sdelphij NOTPRODUCT_FLAG_BUT_PRODUCT_BUILD 182275698Sdelphij }; 183275698Sdelphij 184275698Sdelphij const char* _type; 185275698Sdelphij const char* _name; 186275698Sdelphij void* _addr; 187275698Sdelphij NOT_PRODUCT(const char* _doc;) 188275698Sdelphij Flags _flags; 189275698Sdelphij 190275698Sdelphij // points to all Flags static array 191275698Sdelphij static Flag* flags; 192275698Sdelphij 193275698Sdelphij // number of flags 194275698Sdelphij static size_t numFlags; 195275698Sdelphij 196275698Sdelphij static Flag* find_flag(const char* name) { return find_flag(name, strlen(name), true, true); }; 197275698Sdelphij static Flag* find_flag(const char* name, size_t length, bool allow_locked = false, bool return_flag = false); 198275698Sdelphij static Flag* fuzzy_match(const char* name, size_t length, bool allow_locked = false); 199275698Sdelphij 200275698Sdelphij static const char* get_int_default_range_str(); 201275698Sdelphij static const char* get_uint_default_range_str(); 202275698Sdelphij static const char* get_intx_default_range_str(); 203275698Sdelphij static const char* get_uintx_default_range_str(); 204275698Sdelphij static const char* get_uint64_t_default_range_str(); 205275698Sdelphij static const char* get_size_t_default_range_str(); 206275698Sdelphij static const char* get_double_default_range_str(); 207275698Sdelphij 208275698Sdelphij Flag::Error check_writable(bool changed); 209275698Sdelphij 210275698Sdelphij bool is_bool() const; 211275698Sdelphij bool get_bool() const; 212275698Sdelphij Flag::Error set_bool(bool value); 213275698Sdelphij 214267897Sdelphij bool is_int() const; 215267897Sdelphij int get_int() const; 216267897Sdelphij Flag::Error set_int(int value); 217267897Sdelphij 218267897Sdelphij bool is_uint() const; 219267897Sdelphij uint get_uint() const; 220267897Sdelphij Flag::Error set_uint(uint value); 221267897Sdelphij 222267897Sdelphij bool is_intx() const; 223267897Sdelphij intx get_intx() const; 224267897Sdelphij Flag::Error set_intx(intx value); 225267897Sdelphij 226267897Sdelphij bool is_uintx() const; 227267897Sdelphij uintx get_uintx() const; 228267897Sdelphij Flag::Error set_uintx(uintx value); 229267897Sdelphij 230267897Sdelphij bool is_uint64_t() const; 231267897Sdelphij uint64_t get_uint64_t() const; 232267897Sdelphij Flag::Error set_uint64_t(uint64_t value); 233267897Sdelphij 234267897Sdelphij bool is_size_t() const; 235267897Sdelphij size_t get_size_t() const; 236267897Sdelphij Flag::Error set_size_t(size_t value); 237267897Sdelphij 238267897Sdelphij bool is_double() const; 239267897Sdelphij double get_double() const; 240267897Sdelphij Flag::Error set_double(double value); 241267897Sdelphij 242267897Sdelphij bool is_ccstr() const; 243267897Sdelphij bool ccstr_accumulates() const; 244267897Sdelphij ccstr get_ccstr() const; 245267897Sdelphij Flag::Error set_ccstr(ccstr value); 246267897Sdelphij 247267897Sdelphij Flags get_origin(); 248267897Sdelphij void set_origin(Flags origin); 249267897Sdelphij 250267897Sdelphij bool is_default(); 251267897Sdelphij bool is_ergonomic(); 252267897Sdelphij bool is_command_line(); 253267897Sdelphij void set_command_line(); 254267897Sdelphij 255267897Sdelphij bool is_product() const; 256267897Sdelphij bool is_manageable() const; 257267897Sdelphij bool is_diagnostic() const; 258267897Sdelphij bool is_experimental() const; 259267897Sdelphij bool is_notproduct() const; 260267897Sdelphij bool is_develop() const; 261267897Sdelphij bool is_read_write() const; 262267897Sdelphij bool is_commercial() const; 263267897Sdelphij 264267897Sdelphij bool is_constant_in_binary() const; 265267897Sdelphij 266267897Sdelphij bool is_unlocker() const; 267267897Sdelphij bool is_unlocked() const; 268267897Sdelphij bool is_writeable() const; 269267897Sdelphij bool is_external() const; 270267897Sdelphij 271267897Sdelphij bool is_unlocker_ext() const; 272267897Sdelphij bool is_unlocked_ext() const; 273267897Sdelphij bool is_writeable_ext() const; 274267897Sdelphij bool is_external_ext() const; 275267897Sdelphij 276267897Sdelphij void unlock_diagnostic(); 277267897Sdelphij 278267897Sdelphij Flag::MsgType get_locked_message(char*, int) const; 279267897Sdelphij void get_locked_message_ext(char*, int) const; 280267897Sdelphij 281267897Sdelphij // printRanges will print out flags type, name and range values as expected by -XX:+PrintFlagsRanges 282267897Sdelphij void print_on(outputStream* st, bool withComments = false, bool printRanges = false); 283267897Sdelphij void print_kind_and_origin(outputStream* st); 284267897Sdelphij void print_as_flag(outputStream* st); 285267897Sdelphij 286267897Sdelphij static const char* flag_error_str(Flag::Error error); 287267897Sdelphij}; 288267897Sdelphij 289267897Sdelphij// debug flags control various aspects of the VM and are global accessible 290267897Sdelphij 291267897Sdelphij// use FlagSetting to temporarily change some debug flag 292267897Sdelphij// e.g. FlagSetting fs(DebugThisAndThat, true); 293267897Sdelphij// restored to previous value upon leaving scope 294267897Sdelphijclass FlagSetting { 295267897Sdelphij bool val; 296267897Sdelphij bool* flag; 297267897Sdelphij public: 298267897Sdelphij FlagSetting(bool& fl, bool newValue) { flag = &fl; val = fl; fl = newValue; } 299267897Sdelphij ~FlagSetting() { *flag = val; } 300267897Sdelphij}; 301267897Sdelphij 302267897Sdelphij 303267897Sdelphijclass CounterSetting { 304267897Sdelphij intx* counter; 305267897Sdelphij public: 306267897Sdelphij CounterSetting(intx* cnt) { counter = cnt; (*counter)++; } 307267897Sdelphij ~CounterSetting() { (*counter)--; } 308267897Sdelphij}; 309267897Sdelphij 310267897Sdelphijclass IntFlagSetting { 311267897Sdelphij int val; 312267897Sdelphij int* flag; 313267897Sdelphij public: 314267897Sdelphij IntFlagSetting(int& fl, int newValue) { flag = &fl; val = fl; fl = newValue; } 315267897Sdelphij ~IntFlagSetting() { *flag = val; } 316267897Sdelphij}; 317267897Sdelphij 318267897Sdelphijclass UIntFlagSetting { 319267897Sdelphij uint val; 320267897Sdelphij uint* flag; 321267897Sdelphij public: 322267897Sdelphij UIntFlagSetting(uint& fl, uint newValue) { flag = &fl; val = fl; fl = newValue; } 323267897Sdelphij ~UIntFlagSetting() { *flag = val; } 324267897Sdelphij}; 325267897Sdelphij 326267897Sdelphijclass UIntXFlagSetting { 327267897Sdelphij uintx val; 328267897Sdelphij uintx* flag; 329267897Sdelphij public: 330267897Sdelphij UIntXFlagSetting(uintx& fl, uintx newValue) { flag = &fl; val = fl; fl = newValue; } 331267897Sdelphij ~UIntXFlagSetting() { *flag = val; } 332267897Sdelphij}; 333267897Sdelphij 334267897Sdelphijclass DoubleFlagSetting { 335267897Sdelphij double val; 336267897Sdelphij double* flag; 337267897Sdelphij public: 338267897Sdelphij DoubleFlagSetting(double& fl, double newValue) { flag = &fl; val = fl; fl = newValue; } 339267897Sdelphij ~DoubleFlagSetting() { *flag = val; } 340267897Sdelphij}; 341267897Sdelphij 342267897Sdelphijclass SizeTFlagSetting { 343267897Sdelphij size_t val; 344267897Sdelphij size_t* flag; 345267897Sdelphij public: 346267897Sdelphij SizeTFlagSetting(size_t& fl, size_t newValue) { flag = &fl; val = fl; fl = newValue; } 347267897Sdelphij ~SizeTFlagSetting() { *flag = val; } 348267897Sdelphij}; 349267897Sdelphij 350267897Sdelphij// Helper class for temporarily saving the value of a flag during a scope. 351267897Sdelphijtemplate <size_t SIZE> 352267897Sdelphijclass FlagGuard { 353267897Sdelphij unsigned char _value[SIZE]; 354267897Sdelphij void* const _addr; 355267897Sdelphij 356267897Sdelphij // Hide operator new, this class should only be allocated on the stack. 357267897Sdelphij // NOTE: Cannot include memory/allocation.hpp here due to circular 358267897Sdelphij // dependencies. 359267897Sdelphij void* operator new(size_t size) throw(); 360267897Sdelphij void* operator new [](size_t size) throw(); 361267897Sdelphij 362267897Sdelphij public: 363267897Sdelphij FlagGuard(void* flag_addr) : _addr(flag_addr) { 364267897Sdelphij memcpy(_value, _addr, SIZE); 365267897Sdelphij } 366267897Sdelphij 367267897Sdelphij ~FlagGuard() { 368267897Sdelphij memcpy(_addr, _value, SIZE); 369267897Sdelphij } 370267897Sdelphij}; 371267897Sdelphij 372267897Sdelphij#define FLAG_GUARD(f) FlagGuard<sizeof(f)> f ## _guard(&f) 373267897Sdelphij 374267897Sdelphijclass CommandLineFlags { 375267897Sdelphijpublic: 376267897Sdelphij static Flag::Error boolAt(const char* name, size_t len, bool* value, bool allow_locked = false, bool return_flag = false); 377267897Sdelphij static Flag::Error boolAt(const char* name, bool* value, bool allow_locked = false, bool return_flag = false) { return boolAt(name, strlen(name), value, allow_locked, return_flag); } 378267897Sdelphij static Flag::Error boolAtPut(Flag* flag, bool* value, Flag::Flags origin); 379267897Sdelphij static Flag::Error boolAtPut(const char* name, size_t len, bool* value, Flag::Flags origin); 380267897Sdelphij static Flag::Error boolAtPut(const char* name, bool* value, Flag::Flags origin) { return boolAtPut(name, strlen(name), value, origin); } 381267897Sdelphij 382267897Sdelphij static Flag::Error intAt(const char* name, size_t len, int* value, bool allow_locked = false, bool return_flag = false); 383267897Sdelphij static Flag::Error intAt(const char* name, int* value, bool allow_locked = false, bool return_flag = false) { return intAt(name, strlen(name), value, allow_locked, return_flag); } 384267897Sdelphij static Flag::Error intAtPut(Flag* flag, int* value, Flag::Flags origin); 385267897Sdelphij static Flag::Error intAtPut(const char* name, size_t len, int* value, Flag::Flags origin); 386267897Sdelphij static Flag::Error intAtPut(const char* name, int* value, Flag::Flags origin) { return intAtPut(name, strlen(name), value, origin); } 387267897Sdelphij 388267897Sdelphij static Flag::Error uintAt(const char* name, size_t len, uint* value, bool allow_locked = false, bool return_flag = false); 389267897Sdelphij static Flag::Error uintAt(const char* name, uint* value, bool allow_locked = false, bool return_flag = false) { return uintAt(name, strlen(name), value, allow_locked, return_flag); } 390267897Sdelphij static Flag::Error uintAtPut(Flag* flag, uint* value, Flag::Flags origin); 391267897Sdelphij static Flag::Error uintAtPut(const char* name, size_t len, uint* value, Flag::Flags origin); 392267897Sdelphij static Flag::Error uintAtPut(const char* name, uint* value, Flag::Flags origin) { return uintAtPut(name, strlen(name), value, origin); } 393267897Sdelphij 394267897Sdelphij static Flag::Error intxAt(const char* name, size_t len, intx* value, bool allow_locked = false, bool return_flag = false); 395267897Sdelphij static Flag::Error intxAt(const char* name, intx* value, bool allow_locked = false, bool return_flag = false) { return intxAt(name, strlen(name), value, allow_locked, return_flag); } 396267897Sdelphij static Flag::Error intxAtPut(Flag* flag, intx* value, Flag::Flags origin); 397267897Sdelphij static Flag::Error intxAtPut(const char* name, size_t len, intx* value, Flag::Flags origin); 398267897Sdelphij static Flag::Error intxAtPut(const char* name, intx* value, Flag::Flags origin) { return intxAtPut(name, strlen(name), value, origin); } 399267897Sdelphij 400267897Sdelphij static Flag::Error uintxAt(const char* name, size_t len, uintx* value, bool allow_locked = false, bool return_flag = false); 401267897Sdelphij static Flag::Error uintxAt(const char* name, uintx* value, bool allow_locked = false, bool return_flag = false) { return uintxAt(name, strlen(name), value, allow_locked, return_flag); } 402267897Sdelphij static Flag::Error uintxAtPut(Flag* flag, uintx* value, Flag::Flags origin); 403267897Sdelphij static Flag::Error uintxAtPut(const char* name, size_t len, uintx* value, Flag::Flags origin); 404267897Sdelphij static Flag::Error uintxAtPut(const char* name, uintx* value, Flag::Flags origin) { return uintxAtPut(name, strlen(name), value, origin); } 405267897Sdelphij 406267897Sdelphij static Flag::Error size_tAt(const char* name, size_t len, size_t* value, bool allow_locked = false, bool return_flag = false); 407267897Sdelphij static Flag::Error size_tAt(const char* name, size_t* value, bool allow_locked = false, bool return_flag = false) { return size_tAt(name, strlen(name), value, allow_locked, return_flag); } 408267897Sdelphij static Flag::Error size_tAtPut(Flag* flag, size_t* value, Flag::Flags origin); 409267897Sdelphij static Flag::Error size_tAtPut(const char* name, size_t len, size_t* value, Flag::Flags origin); 410267897Sdelphij static Flag::Error size_tAtPut(const char* name, size_t* value, Flag::Flags origin) { return size_tAtPut(name, strlen(name), value, origin); } 411267897Sdelphij 412267897Sdelphij static Flag::Error uint64_tAt(const char* name, size_t len, uint64_t* value, bool allow_locked = false, bool return_flag = false); 413267897Sdelphij static Flag::Error uint64_tAt(const char* name, uint64_t* value, bool allow_locked = false, bool return_flag = false) { return uint64_tAt(name, strlen(name), value, allow_locked, return_flag); } 414267897Sdelphij static Flag::Error uint64_tAtPut(Flag* flag, uint64_t* value, Flag::Flags origin); 415267897Sdelphij static Flag::Error uint64_tAtPut(const char* name, size_t len, uint64_t* value, Flag::Flags origin); 416267897Sdelphij static Flag::Error uint64_tAtPut(const char* name, uint64_t* value, Flag::Flags origin) { return uint64_tAtPut(name, strlen(name), value, origin); } 417267897Sdelphij 418267897Sdelphij static Flag::Error doubleAt(const char* name, size_t len, double* value, bool allow_locked = false, bool return_flag = false); 419267897Sdelphij static Flag::Error doubleAt(const char* name, double* value, bool allow_locked = false, bool return_flag = false) { return doubleAt(name, strlen(name), value, allow_locked, return_flag); } 420267897Sdelphij static Flag::Error doubleAtPut(Flag* flag, double* value, Flag::Flags origin); 421267897Sdelphij static Flag::Error doubleAtPut(const char* name, size_t len, double* value, Flag::Flags origin); 422267897Sdelphij static Flag::Error doubleAtPut(const char* name, double* value, Flag::Flags origin) { return doubleAtPut(name, strlen(name), value, origin); } 423267897Sdelphij 424267897Sdelphij static Flag::Error ccstrAt(const char* name, size_t len, ccstr* value, bool allow_locked = false, bool return_flag = false); 425267897Sdelphij static Flag::Error ccstrAt(const char* name, ccstr* value, bool allow_locked = false, bool return_flag = false) { return ccstrAt(name, strlen(name), value, allow_locked, return_flag); } 426267897Sdelphij // Contract: Flag will make private copy of the incoming value. 427267897Sdelphij // Outgoing value is always malloc-ed, and caller MUST call free. 428267897Sdelphij static Flag::Error ccstrAtPut(const char* name, size_t len, ccstr* value, Flag::Flags origin); 429267897Sdelphij static Flag::Error ccstrAtPut(const char* name, ccstr* value, Flag::Flags origin) { return ccstrAtPut(name, strlen(name), value, origin); } 430267897Sdelphij 431267897Sdelphij // Returns false if name is not a command line flag. 432267897Sdelphij static bool wasSetOnCmdline(const char* name, bool* value); 433267897Sdelphij static void printSetFlags(outputStream* out); 434267897Sdelphij 435267897Sdelphij // printRanges will print out flags type, name and range values as expected by -XX:+PrintFlagsRanges 436267897Sdelphij static void printFlags(outputStream* out, bool withComments, bool printRanges = false); 437267897Sdelphij 438267897Sdelphij static void verify() PRODUCT_RETURN; 439267897Sdelphij}; 440267897Sdelphij 441267897Sdelphij// use this for flags that are true by default in the debug version but 442267897Sdelphij// false in the optimized version, and vice versa 443267897Sdelphij#ifdef ASSERT 444267897Sdelphij#define trueInDebug true 445267897Sdelphij#define falseInDebug false 446267897Sdelphij#else 447267897Sdelphij#define trueInDebug false 448267897Sdelphij#define falseInDebug true 449267897Sdelphij#endif 450267897Sdelphij 451267897Sdelphij// use this for flags that are true per default in the product build 452267897Sdelphij// but false in development builds, and vice versa 453267897Sdelphij#ifdef PRODUCT 454267897Sdelphij#define trueInProduct true 455267897Sdelphij#define falseInProduct false 456234449Sobrien#else 457234449Sobrien#define trueInProduct false 458234449Sobrien#define falseInProduct true 459234449Sobrien#endif 460234449Sobrien 461234449Sobrien// develop flags are settable / visible only during development and are constant in the PRODUCT version 462234449Sobrien// product flags are always settable / visible 463234449Sobrien// notproduct flags are settable / visible only during development and are not declared in the PRODUCT version 464234449Sobrien 465234449Sobrien// A flag must be declared with one of the following types: 466234449Sobrien// bool, int, uint, intx, uintx, size_t, ccstr, double, or uint64_t. 467234449Sobrien// The type "ccstr" is an alias for "const char*" and is used 468234449Sobrien// only in this file, because the macrology requires single-token type names. 469234449Sobrien 470234449Sobrien// Note: Diagnostic options not meant for VM tuning or for product modes. 471234449Sobrien// They are to be used for VM quality assurance or field diagnosis 472234449Sobrien// of VM bugs. They are hidden so that users will not be encouraged to 473234449Sobrien// try them as if they were VM ordinary execution options. However, they 474234449Sobrien// are available in the product version of the VM. Under instruction 475234449Sobrien// from support engineers, VM customers can turn them on to collect 476234449Sobrien// diagnostic information about VM problems. To use a VM diagnostic 477234449Sobrien// option, you must first specify +UnlockDiagnosticVMOptions. 478234449Sobrien// (This master switch also affects the behavior of -Xprintflags.) 479234449Sobrien// 480234449Sobrien// experimental flags are in support of features that are not 481234449Sobrien// part of the officially supported product, but are available 482234449Sobrien// for experimenting with. They could, for example, be performance 483234449Sobrien// features that may not have undergone full or rigorous QA, but which may 484234449Sobrien// help performance in some cases and released for experimentation 485234449Sobrien// by the community of users and developers. This flag also allows one to 486234449Sobrien// be able to build a fully supported product that nonetheless also 487234449Sobrien// ships with some unsupported, lightly tested, experimental features. 488234449Sobrien// Like the UnlockDiagnosticVMOptions flag above, there is a corresponding 489234449Sobrien// UnlockExperimentalVMOptions flag, which allows the control and 490234449Sobrien// modification of the experimental flags. 491234449Sobrien// 492234449Sobrien// Nota bene: neither diagnostic nor experimental options should be used casually, 493234449Sobrien// and they are not supported on production loads, except under explicit 494234449Sobrien// direction from support engineers. 495234449Sobrien// 496234449Sobrien// manageable flags are writeable external product flags. 497234449Sobrien// They are dynamically writeable through the JDK management interface 498234449Sobrien// (com.sun.management.HotSpotDiagnosticMXBean API) and also through JConsole. 499234449Sobrien// These flags are external exported interface (see CCC). The list of 500234449Sobrien// manageable flags can be queried programmatically through the management 501234449Sobrien// interface. 502234449Sobrien// 503234449Sobrien// A flag can be made as "manageable" only if 504234449Sobrien// - the flag is defined in a CCC as an external exported interface. 505234449Sobrien// - the VM implementation supports dynamic setting of the flag. 506234449Sobrien// This implies that the VM must *always* query the flag variable 507234449Sobrien// and not reuse state related to the flag state at any given time. 508234449Sobrien// - you want the flag to be queried programmatically by the customers. 509234449Sobrien// 510234449Sobrien// product_rw flags are writeable internal product flags. 511234449Sobrien// They are like "manageable" flags but for internal/private use. 512234449Sobrien// The list of product_rw flags are internal/private flags which 513234449Sobrien// may be changed/removed in a future release. It can be set 514234449Sobrien// through the management interface to get/set value 515234449Sobrien// when the name of flag is supplied. 516234449Sobrien// 517234449Sobrien// A flag can be made as "product_rw" only if 518234449Sobrien// - the VM implementation supports dynamic setting of the flag. 519234449Sobrien// This implies that the VM must *always* query the flag variable 520234449Sobrien// and not reuse state related to the flag state at any given time. 521234449Sobrien// 522234449Sobrien// Note that when there is a need to support develop flags to be writeable, 523234449Sobrien// it can be done in the same way as product_rw. 524234449Sobrien// 525234449Sobrien// range is a macro that will expand to min and max arguments for range 526234449Sobrien// checking code if provided - see commandLineFlagRangeList.hpp 527234449Sobrien// 528234449Sobrien// constraint is a macro that will expand to custom function call 529234449Sobrien// for constraint checking if provided - see commandLineFlagConstraintList.hpp 530234449Sobrien// 531234449Sobrien// writeable is a macro that controls if and how the value can change during the runtime 532234449Sobrien// 533234449Sobrien// writeable(Always) is optional and allows the flag to have its value changed 534234449Sobrien// without any limitations at any time 535234449Sobrien// 536234449Sobrien// writeable(Once) flag value's can be only set once during the lifetime of VM 537234449Sobrien// 538234449Sobrien// writeable(CommandLineOnly) flag value's can be only set from command line 539234449Sobrien// (multiple times allowed) 540234449Sobrien// 541234449Sobrien 542234449Sobrien 543234449Sobrien#define RUNTIME_FLAGS(develop, \ 544234449Sobrien develop_pd, \ 545234449Sobrien product, \ 546234449Sobrien product_pd, \ 547234449Sobrien diagnostic, \ 548234449Sobrien diagnostic_pd, \ 549234449Sobrien experimental, \ 550234449Sobrien notproduct, \ 551234449Sobrien manageable, \ 552234449Sobrien product_rw, \ 553234449Sobrien lp64_product, \ 554234449Sobrien range, \ 555234449Sobrien constraint, \ 556234449Sobrien writeable) \ 557234449Sobrien \ 558234449Sobrien lp64_product(bool, UseCompressedOops, false, \ 559234449Sobrien "Use 32-bit object references in 64-bit VM. " \ 560234449Sobrien "lp64_product means flag is always constant in 32 bit VM") \ 561234449Sobrien \ 562234449Sobrien lp64_product(bool, UseCompressedClassPointers, false, \ 563234449Sobrien "Use 32-bit class pointers in 64-bit VM. " \ 564234449Sobrien "lp64_product means flag is always constant in 32 bit VM") \ 565234449Sobrien \ 566234449Sobrien notproduct(bool, CheckCompressedOops, true, \ 567234449Sobrien "Generate checks in encoding/decoding code in debug VM") \ 568234449Sobrien \ 569234449Sobrien product(uintx, HeapSearchSteps, 3 PPC64_ONLY(+17), \ 570234449Sobrien "Heap allocation steps through preferred address regions to find" \ 571234449Sobrien " where it can allocate the heap. Number of steps to take per " \ 572234449Sobrien "region.") \ 573234449Sobrien range(1, max_uintx) \ 574234449Sobrien \ 575234449Sobrien lp64_product(intx, ObjectAlignmentInBytes, 8, \ 576234449Sobrien "Default object alignment in bytes, 8 is minimum") \ 577234449Sobrien range(8, 256) \ 578234449Sobrien constraint(ObjectAlignmentInBytesConstraintFunc,AtParse) \ 579234449Sobrien \ 580234449Sobrien product(bool, AssumeMP, false, \ 581234449Sobrien "Instruct the VM to assume multiple processors are available") \ 582234449Sobrien \ 583234449Sobrien /* UseMembar is theoretically a temp flag used for memory barrier */ \ 584234449Sobrien /* removal testing. It was supposed to be removed before FCS but has */ \ 585234449Sobrien /* been re-added (see 6401008) */ \ 586234449Sobrien product_pd(bool, UseMembar, \ 587234449Sobrien "(Unstable) Issues membars on thread state transitions") \ 588234449Sobrien \ 589234449Sobrien develop(bool, CleanChunkPoolAsync, true, \ 590234449Sobrien "Clean the chunk pool asynchronously") \ 591234449Sobrien \ 592234449Sobrien experimental(bool, AlwaysSafeConstructors, false, \ 593234449Sobrien "Force safe construction, as if all fields are final.") \ 594234449Sobrien \ 595234449Sobrien diagnostic(bool, UnlockDiagnosticVMOptions, trueInDebug, \ 596234449Sobrien "Enable normal processing of flags relating to field diagnostics")\ 597234449Sobrien \ 598234449Sobrien experimental(bool, UnlockExperimentalVMOptions, false, \ 599234449Sobrien "Enable normal processing of flags relating to experimental " \ 600234449Sobrien "features") \ 601234449Sobrien \ 602234449Sobrien product(bool, JavaMonitorsInStackTrace, true, \ 603234449Sobrien "Print information about Java monitor locks when the stacks are" \ 604234449Sobrien "dumped") \ 605234449Sobrien \ 606234449Sobrien product_pd(bool, UseLargePages, \ 607234449Sobrien "Use large page memory") \ 608234449Sobrien \ 609234449Sobrien product_pd(bool, UseLargePagesIndividualAllocation, \ 610234449Sobrien "Allocate large pages individually for better affinity") \ 611234449Sobrien \ 612234449Sobrien develop(bool, LargePagesIndividualAllocationInjectError, false, \ 613234449Sobrien "Fail large pages individual allocation") \ 614234449Sobrien \ 615234449Sobrien product(bool, UseLargePagesInMetaspace, false, \ 616234449Sobrien "Use large page memory in metaspace. " \ 617234449Sobrien "Only used if UseLargePages is enabled.") \ 618234449Sobrien \ 619234449Sobrien product(bool, UseNUMA, false, \ 620234449Sobrien "Use NUMA if available") \ 621234449Sobrien \ 622234449Sobrien product(bool, UseNUMAInterleaving, false, \ 623234449Sobrien "Interleave memory across NUMA nodes if available") \ 624234449Sobrien \ 625234449Sobrien product(size_t, NUMAInterleaveGranularity, 2*M, \ 626234449Sobrien "Granularity to use for NUMA interleaving on Windows OS") \ 627234449Sobrien range(os::vm_allocation_granularity(), NOT_LP64(2*G) LP64_ONLY(8192*G)) \ 628234449Sobrien \ 629234449Sobrien product(bool, ForceNUMA, false, \ 630234449Sobrien "Force NUMA optimizations on single-node/UMA systems") \ 631234449Sobrien \ 632234449Sobrien product(uintx, NUMAChunkResizeWeight, 20, \ 633234449Sobrien "Percentage (0-100) used to weight the current sample when " \ 634234449Sobrien "computing exponentially decaying average for " \ 635234449Sobrien "AdaptiveNUMAChunkSizing") \ 636234449Sobrien range(0, 100) \ 637234449Sobrien \ 638234449Sobrien product(size_t, NUMASpaceResizeRate, 1*G, \ 639234449Sobrien "Do not reallocate more than this amount per collection") \ 640234449Sobrien range(0, max_uintx) \ 641234449Sobrien \ 642234449Sobrien product(bool, UseAdaptiveNUMAChunkSizing, true, \ 643234449Sobrien "Enable adaptive chunk sizing for NUMA") \ 644234449Sobrien \ 645234449Sobrien product(bool, NUMAStats, false, \ 646234449Sobrien "Print NUMA stats in detailed heap information") \ 647234449Sobrien \ 648234449Sobrien product(uintx, NUMAPageScanRate, 256, \ 649234449Sobrien "Maximum number of pages to include in the page scan procedure") \ 650234449Sobrien range(0, max_uintx) \ 651234449Sobrien \ 652234449Sobrien product_pd(bool, NeedsDeoptSuspend, \ 653234449Sobrien "True for register window machines (sparc/ia64)") \ 654234449Sobrien \ 655234449Sobrien product(intx, UseSSE, 99, \ 656234449Sobrien "Highest supported SSE instructions set on x86/x64") \ 657234449Sobrien range(0, 99) \ 658234449Sobrien \ 659234449Sobrien product(bool, UseAES, false, \ 660234449Sobrien "Control whether AES instructions can be used on x86/x64") \ 661234449Sobrien \ 662234449Sobrien product(bool, UseSHA, false, \ 663234449Sobrien "Control whether SHA instructions can be used " \ 664234449Sobrien "on SPARC, on ARM and on x86") \ 665234449Sobrien \ 666234449Sobrien diagnostic(bool, UseGHASHIntrinsics, false, \ 667234449Sobrien "Use intrinsics for GHASH versions of crypto") \ 668234449Sobrien \ 669234449Sobrien product(size_t, LargePageSizeInBytes, 0, \ 670234449Sobrien "Large page size (0 to let VM choose the page size)") \ 671234449Sobrien range(0, max_uintx) \ 672234449Sobrien \ 673234449Sobrien product(size_t, LargePageHeapSizeThreshold, 128*M, \ 674234449Sobrien "Use large pages if maximum heap is at least this big") \ 675234449Sobrien range(0, max_uintx) \ 676234449Sobrien \ 677234449Sobrien product(bool, ForceTimeHighResolution, false, \ 678234449Sobrien "Using high time resolution (for Win32 only)") \ 679234449Sobrien \ 680234449Sobrien develop(bool, TracePcPatching, false, \ 681234449Sobrien "Trace usage of frame::patch_pc") \ 682234449Sobrien \ 683234449Sobrien develop(bool, TraceJumps, false, \ 684234449Sobrien "Trace assembly jumps in thread ring buffer") \ 685234449Sobrien \ 686234449Sobrien develop(bool, TraceRelocator, false, \ 687234449Sobrien "Trace the bytecode relocator") \ 688234449Sobrien \ 689234449Sobrien develop(bool, TraceLongCompiles, false, \ 690234449Sobrien "Print out every time compilation is longer than " \ 691234449Sobrien "a given threshold") \ 692234449Sobrien \ 693234449Sobrien develop(bool, SafepointALot, false, \ 694234449Sobrien "Generate a lot of safepoints. This works with " \ 695234449Sobrien "GuaranteedSafepointInterval") \ 696234449Sobrien \ 697234449Sobrien product_pd(bool, BackgroundCompilation, \ 698234449Sobrien "A thread requesting compilation is not blocked during " \ 699234449Sobrien "compilation") \ 700234449Sobrien \ 701234449Sobrien product(bool, PrintVMQWaitTime, false, \ 702234449Sobrien "Print out the waiting time in VM operation queue") \ 703234449Sobrien \ 704234449Sobrien develop(bool, TraceOopMapGeneration, false, \ 705234449Sobrien "Show OopMapGeneration") \ 706234449Sobrien \ 707234449Sobrien product(bool, MethodFlushing, true, \ 708234449Sobrien "Reclamation of zombie and not-entrant methods") \ 709234449Sobrien \ 710234449Sobrien develop(bool, VerifyStack, false, \ 711234449Sobrien "Verify stack of each thread when it is entering a runtime call") \ 712234449Sobrien \ 713234449Sobrien diagnostic(bool, ForceUnreachable, false, \ 714234449Sobrien "Make all non code cache addresses to be unreachable by " \ 715234449Sobrien "forcing use of 64bit literal fixups") \ 716234449Sobrien \ 717234449Sobrien notproduct(bool, StressDerivedPointers, false, \ 718234449Sobrien "Force scavenge when a derived pointer is detected on stack " \ 719234449Sobrien "after rtm call") \ 720234449Sobrien \ 721234449Sobrien develop(bool, TraceDerivedPointers, false, \ 722234449Sobrien "Trace traversal of derived pointers on stack") \ 723234449Sobrien \ 724234449Sobrien notproduct(bool, TraceCodeBlobStacks, false, \ 725234449Sobrien "Trace stack-walk of codeblobs") \ 726234449Sobrien \ 727234449Sobrien product(bool, PrintJNIResolving, false, \ 728234449Sobrien "Used to implement -v:jni") \ 729234449Sobrien \ 730234449Sobrien notproduct(bool, PrintRewrites, false, \ 731234449Sobrien "Print methods that are being rewritten") \ 732234449Sobrien \ 733234449Sobrien product(bool, UseInlineCaches, true, \ 734234449Sobrien "Use Inline Caches for virtual calls ") \ 735234449Sobrien \ 736234449Sobrien diagnostic(bool, InlineArrayCopy, true, \ 737234449Sobrien "Inline arraycopy native that is known to be part of " \ 738234449Sobrien "base library DLL") \ 739234449Sobrien \ 740234449Sobrien diagnostic(bool, InlineObjectHash, true, \ 741234449Sobrien "Inline Object::hashCode() native that is known to be part " \ 742234449Sobrien "of base library DLL") \ 743234449Sobrien \ 744234449Sobrien diagnostic(bool, InlineNatives, true, \ 745234449Sobrien "Inline natives that are known to be part of base library DLL") \ 746234449Sobrien \ 747234449Sobrien diagnostic(bool, InlineMathNatives, true, \ 748234449Sobrien "Inline SinD, CosD, etc.") \ 749234449Sobrien \ 750234449Sobrien diagnostic(bool, InlineClassNatives, true, \ 751234449Sobrien "Inline Class.isInstance, etc") \ 752234449Sobrien \ 753234449Sobrien diagnostic(bool, InlineThreadNatives, true, \ 754234449Sobrien "Inline Thread.currentThread, etc") \ 755234449Sobrien \ 756234449Sobrien diagnostic(bool, InlineUnsafeOps, true, \ 757234449Sobrien "Inline memory ops (native methods) from Unsafe") \ 758234449Sobrien \ 759234449Sobrien product(bool, CriticalJNINatives, true, \ 760234449Sobrien "Check for critical JNI entry points") \ 761234449Sobrien \ 762192350Sdelphij notproduct(bool, StressCriticalJNINatives, false, \ 763192350Sdelphij "Exercise register saving code in critical natives") \ 764192350Sdelphij \ 765192350Sdelphij diagnostic(bool, UseAESIntrinsics, false, \ 766192350Sdelphij "Use intrinsics for AES versions of crypto") \ 767192350Sdelphij \ 768192350Sdelphij diagnostic(bool, UseAESCTRIntrinsics, false, \ 769192350Sdelphij "Use intrinsics for the paralleled version of AES/CTR crypto") \ 770192350Sdelphij \ 771192350Sdelphij diagnostic(bool, UseSHA1Intrinsics, false, \ 772192350Sdelphij "Use intrinsics for SHA-1 crypto hash function. " \ 773192350Sdelphij "Requires that UseSHA is enabled.") \ 774192350Sdelphij \ 775192350Sdelphij diagnostic(bool, UseSHA256Intrinsics, false, \ 776192350Sdelphij "Use intrinsics for SHA-224 and SHA-256 crypto hash functions. " \ 777192350Sdelphij "Requires that UseSHA is enabled.") \ 778192350Sdelphij \ 779192350Sdelphij diagnostic(bool, UseSHA512Intrinsics, false, \ 780192350Sdelphij "Use intrinsics for SHA-384 and SHA-512 crypto hash functions. " \ 781192350Sdelphij "Requires that UseSHA is enabled.") \ 782192350Sdelphij \ 783192350Sdelphij diagnostic(bool, UseCRC32Intrinsics, false, \ 784192350Sdelphij "use intrinsics for java.util.zip.CRC32") \ 785192350Sdelphij \ 786192350Sdelphij diagnostic(bool, UseCRC32CIntrinsics, false, \ 787192350Sdelphij "use intrinsics for java.util.zip.CRC32C") \ 788192350Sdelphij \ 789192350Sdelphij diagnostic(bool, UseAdler32Intrinsics, false, \ 790192350Sdelphij "use intrinsics for java.util.zip.Adler32") \ 791192350Sdelphij \ 792192350Sdelphij diagnostic(bool, UseVectorizedMismatchIntrinsic, false, \ 793192350Sdelphij "Enables intrinsification of ArraysSupport.vectorizedMismatch()") \ 794192350Sdelphij \ 795192350Sdelphij diagnostic(ccstrlist, DisableIntrinsic, "", \ 796192350Sdelphij "do not expand intrinsics whose (internal) names appear here") \ 797192350Sdelphij \ 798192350Sdelphij develop(bool, TraceCallFixup, false, \ 799192350Sdelphij "Trace all call fixups") \ 800192350Sdelphij \ 801192350Sdelphij develop(bool, DeoptimizeALot, false, \ 802192350Sdelphij "Deoptimize at every exit from the runtime system") \ 803192350Sdelphij \ 804192350Sdelphij notproduct(ccstrlist, DeoptimizeOnlyAt, "", \ 805192350Sdelphij "A comma separated list of bcis to deoptimize at") \ 806192350Sdelphij \ 807192350Sdelphij product(bool, DeoptimizeRandom, false, \ 808192350Sdelphij "Deoptimize random frames on random exit from the runtime system")\ 809192350Sdelphij \ 810192350Sdelphij notproduct(bool, ZombieALot, false, \ 811192350Sdelphij "Create zombies (non-entrant) at exit from the runtime system") \ 812192350Sdelphij \ 813192350Sdelphij product(bool, UnlinkSymbolsALot, false, \ 814192350Sdelphij "Unlink unreferenced symbols from the symbol table at safepoints")\ 815192350Sdelphij \ 816192350Sdelphij notproduct(bool, WalkStackALot, false, \ 817192350Sdelphij "Trace stack (no print) at every exit from the runtime system") \ 818191771Sobrien \ 819191771Sobrien product(bool, Debugging, false, \ 820191771Sobrien "Set when executing debug methods in debug.cpp " \ 821191771Sobrien "(to prevent triggering assertions)") \ 822191771Sobrien \ 823191771Sobrien notproduct(bool, StrictSafepointChecks, trueInDebug, \ 824191771Sobrien "Enable strict checks that safepoints cannot happen for threads " \ 825191771Sobrien "that use NoSafepointVerifier") \ 826191771Sobrien \ 827191771Sobrien notproduct(bool, VerifyLastFrame, false, \ 828191771Sobrien "Verify oops on last frame on entry to VM") \ 829191771Sobrien \ 830191771Sobrien product(bool, FailOverToOldVerifier, true, \ 831191771Sobrien "Fail over to old verifier when split verifier fails") \ 832191771Sobrien \ 833191771Sobrien develop(bool, ShowSafepointMsgs, false, \ 834191771Sobrien "Show message about safepoint synchronization") \ 835191771Sobrien \ 836191771Sobrien product(bool, SafepointTimeout, false, \ 837191771Sobrien "Time out and warn or fail after SafepointTimeoutDelay " \ 838191771Sobrien "milliseconds if failed to reach safepoint") \ 839191771Sobrien \ 840191771Sobrien develop(bool, DieOnSafepointTimeout, false, \ 841191771Sobrien "Die upon failure to reach safepoint (see SafepointTimeout)") \ 842191771Sobrien \ 843191771Sobrien /* 50 retries * (5 * current_retry_count) millis = ~6.375 seconds */ \ 844191771Sobrien /* typically, at most a few retries are needed */ \ 845191771Sobrien product(intx, SuspendRetryCount, 50, \ 846191771Sobrien "Maximum retry count for an external suspend request") \ 847191771Sobrien range(0, max_intx) \ 848191771Sobrien \ 849191771Sobrien product(intx, SuspendRetryDelay, 5, \ 850191771Sobrien "Milliseconds to delay per retry (* current_retry_count)") \ 851191771Sobrien range(0, max_intx) \ 852191771Sobrien \ 853191771Sobrien product(bool, AssertOnSuspendWaitFailure, false, \ 854191771Sobrien "Assert/Guarantee on external suspend wait failure") \ 855191771Sobrien \ 856191771Sobrien product(bool, TraceSuspendWaitFailures, false, \ 857191771Sobrien "Trace external suspend wait failures") \ 858191771Sobrien \ 859191771Sobrien product(bool, MaxFDLimit, true, \ 860191771Sobrien "Bump the number of file descriptors to maximum in Solaris") \ 861191771Sobrien \ 862191771Sobrien diagnostic(bool, LogEvents, true, \ 863191771Sobrien "Enable the various ring buffer event logs") \ 864191771Sobrien \ 865191771Sobrien diagnostic(uintx, LogEventsBufferEntries, 10, \ 866191771Sobrien "Number of ring buffer event logs") \ 867191771Sobrien range(1, NOT_LP64(1*K) LP64_ONLY(1*M)) \ 868191771Sobrien \ 869191771Sobrien product(bool, BytecodeVerificationRemote, true, \ 870191771Sobrien "Enable the Java bytecode verifier for remote classes") \ 871191771Sobrien \ 872191771Sobrien product(bool, BytecodeVerificationLocal, false, \ 873191771Sobrien "Enable the Java bytecode verifier for local classes") \ 874191771Sobrien \ 875191771Sobrien develop(bool, ForceFloatExceptions, trueInDebug, \ 876191771Sobrien "Force exceptions on FP stack under/overflow") \ 877191771Sobrien \ 878191771Sobrien develop(bool, VerifyStackAtCalls, false, \ 879191771Sobrien "Verify that the stack pointer is unchanged after calls") \ 880191771Sobrien \ 881191771Sobrien develop(bool, TraceJavaAssertions, false, \ 882191771Sobrien "Trace java language assertions") \ 883191771Sobrien \ 884191771Sobrien notproduct(bool, CheckAssertionStatusDirectives, false, \ 885191771Sobrien "Temporary - see javaClasses.cpp") \ 886191771Sobrien \ 887191771Sobrien notproduct(bool, PrintMallocFree, false, \ 888191771Sobrien "Trace calls to C heap malloc/free allocation") \ 889191771Sobrien \ 890191771Sobrien notproduct(bool, VerifyCodeCache, false, \ 891191771Sobrien "Verify code cache on memory allocation/deallocation") \ 892191771Sobrien \ 893191771Sobrien develop(bool, UseMallocOnly, false, \ 894191771Sobrien "Use only malloc/free for allocation (no resource area/arena)") \ 895191771Sobrien \ 896191771Sobrien develop(bool, PrintMalloc, false, \ 897191771Sobrien "Print all malloc/free calls") \ 898191771Sobrien \ 899191771Sobrien develop(bool, PrintMallocStatistics, false, \ 900191771Sobrien "Print malloc/free statistics") \ 901191771Sobrien \ 902191771Sobrien develop(bool, ZapResourceArea, trueInDebug, \ 903191771Sobrien "Zap freed resource/arena space with 0xABABABAB") \ 904191771Sobrien \ 905191771Sobrien notproduct(bool, ZapVMHandleArea, trueInDebug, \ 906191771Sobrien "Zap freed VM handle space with 0xBCBCBCBC") \ 907191771Sobrien \ 908186691Sobrien develop(bool, ZapJNIHandleArea, trueInDebug, \ 909175296Sobrien "Zap freed JNI handle space with 0xFEFEFEFE") \ 910186691Sobrien \ 911186691Sobrien notproduct(bool, ZapStackSegments, trueInDebug, \ 912186691Sobrien "Zap allocated/freed stack segments with 0xFADFADED") \ 913186691Sobrien \ 914191771Sobrien develop(bool, ZapUnusedHeapArea, trueInDebug, \ 915191771Sobrien "Zap unused heap space with 0xBAADBABE") \ 916191771Sobrien \ 917191771Sobrien develop(bool, CheckZapUnusedHeapArea, false, \ 918191771Sobrien "Check zapping of unused heap space") \ 919191771Sobrien \ 920186691Sobrien develop(bool, ZapFillerObjects, trueInDebug, \ 921186691Sobrien "Zap filler objects with 0xDEAFBABE") \ 922186691Sobrien \ 923186691Sobrien develop(bool, PrintVMMessages, true, \ 924186691Sobrien "Print VM messages on console") \ 925186691Sobrien \ 926186691Sobrien notproduct(uintx, ErrorHandlerTest, 0, \ 927186691Sobrien "If > 0, provokes an error after VM initialization; the value " \ 928186691Sobrien "determines which error to provoke. See test_error_handler() " \ 929186691Sobrien "in debug.cpp.") \ 930186691Sobrien \ 931186691Sobrien notproduct(uintx, TestCrashInErrorHandler, 0, \ 932186691Sobrien "If > 0, provokes an error inside VM error handler (a secondary " \ 933186691Sobrien "crash). see test_error_handler() in debug.cpp.") \ 934186691Sobrien \ 935186691Sobrien notproduct(bool, TestSafeFetchInErrorHandler, false, \ 936186691Sobrien "If true, tests SafeFetch inside error handler.") \ 937186691Sobrien \ 938186691Sobrien develop(bool, Verbose, false, \ 939186691Sobrien "Print additional debugging information from other modes") \ 940186691Sobrien \ 941186691Sobrien develop(bool, PrintMiscellaneous, false, \ 942186691Sobrien "Print uncategorized debugging information (requires +Verbose)") \ 943186691Sobrien \ 944186691Sobrien develop(bool, WizardMode, false, \ 945186691Sobrien "Print much more debugging information") \ 946186691Sobrien \ 947186691Sobrien product(bool, ShowMessageBoxOnError, false, \ 948186691Sobrien "Keep process alive on VM fatal error") \ 949186691Sobrien \ 950186691Sobrien product(bool, CreateCoredumpOnCrash, true, \ 951186691Sobrien "Create core/mini dump on VM fatal error") \ 952186691Sobrien \ 953186691Sobrien product(uint64_t, ErrorLogTimeout, 2 * 60, \ 954186691Sobrien "Timeout, in seconds, to limit the time spent on writing an " \ 955186691Sobrien "error log in case of a crash.") \ 956186691Sobrien range(0, (uint64_t)max_jlong/1000) \ 957186691Sobrien \ 958186691Sobrien product_pd(bool, UseOSErrorReporting, \ 959186691Sobrien "Let VM fatal error propagate to the OS (ie. WER on Windows)") \ 960186691Sobrien \ 961186691Sobrien product(bool, SuppressFatalErrorMessage, false, \ 962186691Sobrien "Report NO fatal error message (avoid deadlock)") \ 963186691Sobrien \ 964186691Sobrien product(ccstrlist, OnError, "", \ 965186691Sobrien "Run user-defined commands on fatal error; see VMError.cpp " \ 966186691Sobrien "for examples") \ 967186691Sobrien \ 968186691Sobrien product(ccstrlist, OnOutOfMemoryError, "", \ 969186691Sobrien "Run user-defined commands on first java.lang.OutOfMemoryError") \ 970186691Sobrien \ 971191771Sobrien manageable(bool, HeapDumpBeforeFullGC, false, \ 972186691Sobrien "Dump heap to file before any major stop-the-world GC") \ 973186691Sobrien \ 974186691Sobrien manageable(bool, HeapDumpAfterFullGC, false, \ 975186691Sobrien "Dump heap to file after any major stop-the-world GC") \ 976186691Sobrien \ 977191771Sobrien manageable(bool, HeapDumpOnOutOfMemoryError, false, \ 978186691Sobrien "Dump heap to file when java.lang.OutOfMemoryError is thrown") \ 979186691Sobrien \ 980191771Sobrien manageable(ccstr, HeapDumpPath, NULL, \ 981186691Sobrien "When HeapDumpOnOutOfMemoryError is on, the path (filename or " \ 982186691Sobrien "directory) of the dump file (defaults to java_pid<pid>.hprof " \ 983191771Sobrien "in the working directory)") \ 984186691Sobrien \ 985186691Sobrien develop(bool, BreakAtWarning, false, \ 986191771Sobrien "Execute breakpoint upon encountering VM warning") \ 987186691Sobrien \ 988186691Sobrien develop(bool, UseFakeTimers, false, \ 989186691Sobrien "Tell whether the VM should use system time or a fake timer") \ 990186691Sobrien \ 991186691Sobrien product(ccstr, NativeMemoryTracking, "off", \ 992186691Sobrien "Native memory tracking options") \ 993186691Sobrien \ 994186691Sobrien diagnostic(bool, PrintNMTStatistics, false, \ 995186691Sobrien "Print native memory tracking summary data if it is on") \ 996186691Sobrien \ 997191771Sobrien diagnostic(bool, LogCompilation, false, \ 998186691Sobrien "Log compilation activity in detail to LogFile") \ 999186691Sobrien \ 1000186691Sobrien product(bool, PrintCompilation, false, \ 1001186691Sobrien "Print compilations") \ 1002191771Sobrien \ 1003186691Sobrien diagnostic(bool, TraceNMethodInstalls, false, \ 1004186691Sobrien "Trace nmethod installation") \ 1005186691Sobrien \ 1006186691Sobrien diagnostic(intx, ScavengeRootsInCode, 2, \ 1007186691Sobrien "0: do not allow scavengable oops in the code cache; " \ 1008186691Sobrien "1: allow scavenging from the code cache; " \ 1009186691Sobrien "2: emit as many constants as the compiler can see") \ 1010186691Sobrien range(0, 2) \ 1011186691Sobrien \ 1012186691Sobrien product(bool, AlwaysRestoreFPU, false, \ 1013186691Sobrien "Restore the FPU control word after every JNI call (expensive)") \ 1014186691Sobrien \ 1015186691Sobrien diagnostic(bool, PrintCompilation2, false, \ 1016186691Sobrien "Print additional statistics per compilation") \ 1017186691Sobrien \ 1018186691Sobrien diagnostic(bool, PrintAdapterHandlers, false, \ 1019186691Sobrien "Print code generated for i2c/c2i adapters") \ 1020186691Sobrien \ 1021186691Sobrien diagnostic(bool, VerifyAdapterCalls, trueInDebug, \ 1022186691Sobrien "Verify that i2c/c2i adapters are called properly") \ 1023186691Sobrien \ 1024186691Sobrien develop(bool, VerifyAdapterSharing, false, \ 1025186691Sobrien "Verify that the code for shared adapters is the equivalent") \ 1026186691Sobrien \ 1027186691Sobrien diagnostic(bool, PrintAssembly, false, \ 1028191771Sobrien "Print assembly code (using external disassembler.so)") \ 1029186691Sobrien \ 1030186691Sobrien diagnostic(ccstr, PrintAssemblyOptions, NULL, \ 1031186691Sobrien "Print options string passed to disassembler.so") \ 1032186691Sobrien \ 1033186691Sobrien notproduct(bool, PrintNMethodStatistics, false, \ 1034186691Sobrien "Print a summary statistic for the generated nmethods") \ 1035186691Sobrien \ 1036186691Sobrien diagnostic(bool, PrintNMethods, false, \ 1037186691Sobrien "Print assembly code for nmethods when generated") \ 1038186691Sobrien \ 1039186691Sobrien diagnostic(bool, PrintNativeNMethods, false, \ 1040186691Sobrien "Print assembly code for native nmethods when generated") \ 1041186691Sobrien \ 1042186691Sobrien develop(bool, PrintDebugInfo, false, \ 1043186691Sobrien "Print debug information for all nmethods when generated") \ 1044186691Sobrien \ 1045186691Sobrien develop(bool, PrintRelocations, false, \ 1046186691Sobrien "Print relocation information for all nmethods when generated") \ 1047175296Sobrien \ 1048175296Sobrien develop(bool, PrintDependencies, false, \ 1049175296Sobrien "Print dependency information for all nmethods when generated") \ 1050175296Sobrien \ 1051175296Sobrien develop(bool, PrintExceptionHandlers, false, \ 1052175296Sobrien "Print exception handler tables for all nmethods when generated") \ 1053186691Sobrien \ 1054175296Sobrien develop(bool, StressCompiledExceptionHandlers, false, \ 1055175296Sobrien "Exercise compiled exception handlers") \ 1056175296Sobrien \ 1057175296Sobrien develop(bool, InterceptOSException, false, \ 1058175296Sobrien "Start debugger when an implicit OS (e.g. NULL) " \ 1059175296Sobrien "exception happens") \ 1060175296Sobrien \ 1061186691Sobrien product(bool, PrintCodeCache, false, \ 1062175296Sobrien "Print the code cache memory usage when exiting") \ 1063175296Sobrien \ 1064175296Sobrien develop(bool, PrintCodeCache2, false, \ 1065175296Sobrien "Print detailed usage information on the code cache when exiting")\ 1066186691Sobrien \ 1067175296Sobrien product(bool, PrintCodeCacheOnCompilation, false, \ 1068191771Sobrien "Print the code cache memory usage each time a method is " \ 1069175296Sobrien "compiled") \ 1070186691Sobrien \ 1071175296Sobrien diagnostic(bool, PrintStubCode, false, \ 1072175296Sobrien "Print generated stub code") \ 1073175296Sobrien \ 1074186691Sobrien product(bool, StackTraceInThrowable, true, \ 1075175296Sobrien "Collect backtrace in throwable when exception happens") \ 1076175296Sobrien \ 1077175296Sobrien product(bool, OmitStackTraceInFastThrow, true, \ 1078186691Sobrien "Omit backtraces for some 'hot' exceptions in optimized code") \ 1079175296Sobrien \ 1080175296Sobrien product(bool, ProfilerPrintByteCodeStatistics, false, \ 1081175296Sobrien "Print bytecode statistics when dumping profiler output") \ 1082175296Sobrien \ 1083175296Sobrien product(bool, ProfilerRecordPC, false, \ 1084175296Sobrien "Collect ticks for each 16 byte interval of compiled code") \ 1085186691Sobrien \ 1086175296Sobrien product(bool, ProfileVM, false, \ 1087175296Sobrien "Profile ticks that fall within VM (either in the VM Thread " \ 1088175296Sobrien "or VM code called through stubs)") \ 1089175296Sobrien \ 1090186691Sobrien product(bool, ProfileIntervals, false, \ 1091175296Sobrien "Print profiles for each interval (see ProfileIntervalsTicks)") \ 1092175296Sobrien \ 1093175296Sobrien notproduct(bool, ProfilerCheckIntervals, false, \ 1094175296Sobrien "Collect and print information on spacing of profiler ticks") \ 1095175296Sobrien \ 1096186691Sobrien product(bool, PrintWarnings, true, \ 1097175296Sobrien "Print JVM warnings to output stream") \ 1098175296Sobrien \ 1099175296Sobrien notproduct(uintx, WarnOnStalledSpinLock, 0, \ 1100186691Sobrien "Print warnings for stalled SpinLocks") \ 1101175296Sobrien \ 1102175296Sobrien product(bool, RegisterFinalizersAtInit, true, \ 1103175296Sobrien "Register finalizable objects at end of Object.<init> or " \ 1104175296Sobrien "after allocation") \ 1105175296Sobrien \ 1106175296Sobrien develop(bool, RegisterReferences, true, \ 1107175296Sobrien "Tell whether the VM should register soft/weak/final/phantom " \ 1108175296Sobrien "references") \ 1109186691Sobrien \ 1110175296Sobrien develop(bool, IgnoreRewrites, false, \ 1111175296Sobrien "Suppress rewrites of bytecodes in the oopmap generator. " \ 1112175296Sobrien "This is unsafe!") \ 1113175296Sobrien \ 1114175296Sobrien develop(bool, PrintCodeCacheExtension, false, \ 1115191771Sobrien "Print extension of code cache") \ 1116175296Sobrien \ 1117175296Sobrien develop(bool, UsePrivilegedStack, true, \ 1118175296Sobrien "Enable the security JVM functions") \ 1119175296Sobrien \ 1120175296Sobrien develop(bool, ProtectionDomainVerification, true, \ 1121175296Sobrien "Verify protection domain before resolution in system dictionary")\ 1122175296Sobrien \ 1123175296Sobrien product(bool, ClassUnloading, true, \ 1124175296Sobrien "Do unloading of classes") \ 1125175296Sobrien \ 1126186691Sobrien product(bool, ClassUnloadingWithConcurrentMark, true, \ 1127169962Sobrien "Do unloading of classes with a concurrent marking cycle") \ 1128169962Sobrien \ 1129169962Sobrien develop(bool, DisableStartThread, false, \ 1130186691Sobrien "Disable starting of additional Java threads " \ 1131169962Sobrien "(for debugging only)") \ 1132169962Sobrien \ 1133169962Sobrien develop(bool, MemProfiling, false, \ 1134169962Sobrien "Write memory usage profiling to log file") \ 1135186691Sobrien \ 1136169962Sobrien notproduct(bool, PrintSystemDictionaryAtExit, false, \ 1137169962Sobrien "Print the system dictionary at exit") \ 1138169962Sobrien \ 1139169962Sobrien experimental(intx, PredictedLoadedClassCount, 0, \ 1140169962Sobrien "Experimental: Tune loaded class cache starting size") \ 1141169962Sobrien \ 1142186691Sobrien diagnostic(bool, UnsyncloadClass, false, \ 1143169962Sobrien "Unstable: VM calls loadClass unsynchronized. Custom " \ 1144169962Sobrien "class loader must call VM synchronized for findClass " \ 1145191771Sobrien "and defineClass.") \ 1146169962Sobrien \ 1147169962Sobrien product(bool, AlwaysLockClassLoader, false, \ 1148186691Sobrien "Require the VM to acquire the class loader lock before calling " \ 1149169962Sobrien "loadClass() even for class loaders registering " \ 1150169962Sobrien "as parallel capable") \ 1151169962Sobrien \ 1152169962Sobrien product(bool, AllowParallelDefineClass, false, \ 1153186691Sobrien "Allow parallel defineClass requests for class loaders " \ 1154169962Sobrien "registering as parallel capable") \ 1155169962Sobrien \ 1156169962Sobrien product(bool, MustCallLoadClassInternal, false, \ 1157186691Sobrien "Call loadClassInternal() rather than loadClass()") \ 1158169962Sobrien \ 1159169962Sobrien product_pd(bool, DontYieldALot, \ 1160169962Sobrien "Throw away obvious excess yield calls") \ 1161169962Sobrien \ 1162169962Sobrien product(bool, ConvertSleepToYield, true, \ 1163169962Sobrien "Convert sleep(0) to thread yield ") \ 1164191771Sobrien \ 1165169962Sobrien product(bool, ConvertYieldToSleep, false, \ 1166169962Sobrien "Convert yield to a sleep of MinSleepInterval to simulate Win32 " \ 1167169962Sobrien "behavior") \ 1168169962Sobrien \ 1169169962Sobrien develop(bool, UseDetachedThreads, true, \ 1170169962Sobrien "Use detached threads that are recycled upon termination " \ 1171169962Sobrien "(for Solaris only)") \ 1172191771Sobrien \ 1173169962Sobrien product(bool, UseLWPSynchronization, true, \ 1174169962Sobrien "Use LWP-based instead of libthread-based synchronization " \ 1175169962Sobrien "(SPARC only)") \ 1176169962Sobrien \ 1177169962Sobrien experimental(ccstr, SyncKnobs, NULL, \ 1178169962Sobrien "(Unstable) Various monitor synchronization tunables") \ 1179169962Sobrien \ 1180169962Sobrien experimental(intx, EmitSync, 0, \ 1181169962Sobrien "(Unsafe, Unstable) " \ 1182169962Sobrien "Control emission of inline sync fast-path code") \ 1183169962Sobrien \ 1184169962Sobrien product(intx, MonitorBound, 0, "Bound Monitor population") \ 1185169962Sobrien range(0, max_jint) \ 1186169962Sobrien \ 1187169962Sobrien product(bool, MonitorInUseLists, true, "Track Monitors for Deflation") \ 1188169962Sobrien \ 1189169962Sobrien experimental(intx, SyncFlags, 0, "(Unsafe, Unstable) " \ 1190169962Sobrien "Experimental Sync flags") \ 1191169962Sobrien \ 1192169962Sobrien experimental(intx, SyncVerbose, 0, "(Unstable)") \ 1193169962Sobrien \ 1194169962Sobrien diagnostic(bool, InlineNotify, true, "intrinsify subset of notify") \ 1195169962Sobrien \ 1196169962Sobrien experimental(intx, ClearFPUAtPark, 0, "(Unsafe, Unstable)") \ 1197169962Sobrien \ 1198169962Sobrien experimental(intx, hashCode, 5, \ 1199169962Sobrien "(Unstable) select hashCode generation algorithm") \ 1200169962Sobrien \ 1201169962Sobrien product(bool, FilterSpuriousWakeups, true, \ 1202169962Sobrien "When true prevents OS-level spurious, or premature, wakeups " \ 1203169962Sobrien "from Object.wait (Ignored for Windows)") \ 1204169962Sobrien \ 1205169962Sobrien experimental(intx, NativeMonitorTimeout, -1, "(Unstable)") \ 1206169962Sobrien \ 1207169962Sobrien experimental(intx, NativeMonitorFlags, 0, "(Unstable)") \ 1208169962Sobrien \ 1209169962Sobrien experimental(intx, NativeMonitorSpinLimit, 20, "(Unstable)") \ 1210169962Sobrien \ 1211169962Sobrien develop(bool, UsePthreads, false, \ 1212169962Sobrien "Use pthread-based instead of libthread-based synchronization " \ 1213169962Sobrien "(SPARC only)") \ 1214169962Sobrien \ 1215169962Sobrien product(bool, ReduceSignalUsage, false, \ 1216169962Sobrien "Reduce the use of OS signals in Java and/or the VM") \ 1217169962Sobrien \ 1218169962Sobrien develop_pd(bool, ShareVtableStubs, \ 1219169962Sobrien "Share vtable stubs (smaller code but worse branch prediction") \ 1220169962Sobrien \ 1221169962Sobrien develop(bool, LoadLineNumberTables, true, \ 1222169962Sobrien "Tell whether the class file parser loads line number tables") \ 1223169962Sobrien \ 1224169962Sobrien develop(bool, LoadLocalVariableTables, true, \ 1225169962Sobrien "Tell whether the class file parser loads local variable tables") \ 1226169962Sobrien \ 1227169962Sobrien develop(bool, LoadLocalVariableTypeTables, true, \ 1228169962Sobrien "Tell whether the class file parser loads local variable type" \ 1229169962Sobrien "tables") \ 1230169962Sobrien \ 1231186691Sobrien product(bool, AllowUserSignalHandlers, false, \ 1232169942Sobrien "Do not complain if the application installs signal handlers " \ 1233169942Sobrien "(Solaris & Linux only)") \ 1234169942Sobrien \ 1235169942Sobrien product(bool, UseSignalChaining, true, \ 1236169942Sobrien "Use signal-chaining to invoke signal handlers installed " \ 1237169942Sobrien "by the application (Solaris & Linux only)") \ 1238169942Sobrien \ 1239169942Sobrien product(bool, AllowJNIEnvProxy, false, \ 1240186691Sobrien "Allow JNIEnv proxies for jdbx") \ 1241169942Sobrien \ 1242169942Sobrien product(bool, RestoreMXCSROnJNICalls, false, \ 1243191771Sobrien "Restore MXCSR when returning from JNI calls") \ 1244169942Sobrien \ 1245169942Sobrien product(bool, CheckJNICalls, false, \ 1246169942Sobrien "Verify all arguments to JNI calls") \ 1247169942Sobrien \ 1248169942Sobrien product(bool, CheckEndorsedAndExtDirs, false, \ 1249169942Sobrien "Verify the endorsed and extension directories are not used") \ 1250169942Sobrien \ 1251169942Sobrien product(bool, UseFastJNIAccessors, true, \ 1252169942Sobrien "Use optimized versions of Get<Primitive>Field") \ 1253169942Sobrien \ 1254169942Sobrien product(intx, MaxJNILocalCapacity, 65536, \ 1255169942Sobrien "Maximum allowable local JNI handle capacity to " \ 1256169942Sobrien "EnsureLocalCapacity() and PushLocalFrame(), " \ 1257186691Sobrien "where <= 0 is unlimited, default: 65536") \ 1258191771Sobrien range(min_intx, max_intx) \ 1259169942Sobrien \ 1260169942Sobrien product(bool, EagerXrunInit, false, \ 1261169942Sobrien "Eagerly initialize -Xrun libraries; allows startup profiling, " \ 1262169942Sobrien "but not all -Xrun libraries may support the state of the VM " \ 1263169942Sobrien "at this time") \ 1264169942Sobrien \ 1265169942Sobrien product(bool, PreserveAllAnnotations, false, \ 1266169942Sobrien "Preserve RuntimeInvisibleAnnotations as well " \ 1267169942Sobrien "as RuntimeVisibleAnnotations") \ 1268186691Sobrien \ 1269169942Sobrien develop(uintx, PreallocatedOutOfMemoryErrorCount, 4, \ 1270169942Sobrien "Number of OutOfMemoryErrors preallocated with backtrace") \ 1271169942Sobrien \ 1272169942Sobrien product(bool, UseXMMForArrayCopy, false, \ 1273186691Sobrien "Use SSE2 MOVQ instruction for Arraycopy") \ 1274169942Sobrien \ 1275169942Sobrien product(intx, FieldsAllocationStyle, 1, \ 1276169942Sobrien "0 - type based with oops first, " \ 1277169942Sobrien "1 - with oops last, " \ 1278169942Sobrien "2 - oops in super and sub classes are together") \ 1279169942Sobrien range(0, 2) \ 1280169942Sobrien \ 1281169942Sobrien product(bool, CompactFields, true, \ 1282169942Sobrien "Allocate nonstatic fields in gaps between previous fields") \ 1283169942Sobrien \ 1284169942Sobrien notproduct(bool, PrintFieldLayout, false, \ 1285169942Sobrien "Print field layout for each class") \ 1286169942Sobrien \ 1287169942Sobrien /* Need to limit the extent of the padding to reasonable size. */\ 1288169942Sobrien /* 8K is well beyond the reasonable HW cache line size, even with */\ 1289186691Sobrien /* aggressive prefetching, while still leaving the room for segregating */\ 1290169942Sobrien /* among the distinct pages. */\ 1291169942Sobrien product(intx, ContendedPaddingWidth, 128, \ 1292169942Sobrien "How many bytes to pad the fields/classes marked @Contended with")\ 1293169942Sobrien range(0, 8192) \ 1294169942Sobrien constraint(ContendedPaddingWidthConstraintFunc,AfterErgo) \ 1295169942Sobrien \ 1296169942Sobrien product(bool, EnableContended, true, \ 1297169942Sobrien "Enable @Contended annotation support") \ 1298169942Sobrien \ 1299169942Sobrien product(bool, RestrictContended, true, \ 1300169942Sobrien "Restrict @Contended to trusted classes") \ 1301169942Sobrien \ 1302169942Sobrien product(bool, UseBiasedLocking, true, \ 1303186691Sobrien "Enable biased locking in JVM") \ 1304169942Sobrien \ 1305169942Sobrien product(intx, BiasedLockingStartupDelay, 4000, \ 1306169942Sobrien "Number of milliseconds to wait before enabling biased locking") \ 1307169942Sobrien range(0, (intx)(max_jint-(max_jint%PeriodicTask::interval_gran))) \ 1308169942Sobrien constraint(BiasedLockingStartupDelayFunc,AfterErgo) \ 1309267897Sdelphij \ 1310169942Sobrien diagnostic(bool, PrintBiasedLockingStatistics, false, \ 1311186691Sobrien "Print statistics of biased locking in JVM") \ 1312169942Sobrien \ 1313169942Sobrien product(intx, BiasedLockingBulkRebiasThreshold, 20, \ 1314169942Sobrien "Threshold of number of revocations per type to try to " \ 1315169942Sobrien "rebias all objects in the heap of that type") \ 1316169942Sobrien range(0, max_intx) \ 1317186691Sobrien constraint(BiasedLockingBulkRebiasThresholdFunc,AfterErgo) \ 1318159764Sobrien \ 1319159764Sobrien product(intx, BiasedLockingBulkRevokeThreshold, 40, \ 1320159764Sobrien "Threshold of number of revocations per type to permanently " \ 1321159764Sobrien "revoke biases of all objects in the heap of that type") \ 1322159764Sobrien range(0, max_intx) \ 1323159764Sobrien constraint(BiasedLockingBulkRevokeThresholdFunc,AfterErgo) \ 1324159764Sobrien \ 1325186691Sobrien product(intx, BiasedLockingDecayTime, 25000, \ 1326159764Sobrien "Decay time (in milliseconds) to re-enable bulk rebiasing of a " \ 1327159764Sobrien "type after previous bulk rebias") \ 1328159764Sobrien range(500, max_intx) \ 1329159764Sobrien constraint(BiasedLockingDecayTimeFunc,AfterErgo) \ 1330186691Sobrien \ 1331159764Sobrien product(bool, ExitOnOutOfMemoryError, false, \ 1332159764Sobrien "JVM exits on the first occurrence of an out-of-memory error") \ 1333267897Sdelphij \ 1334159764Sobrien product(bool, CrashOnOutOfMemoryError, false, \ 1335186691Sobrien "JVM aborts, producing an error log and core/mini dump, on the " \ 1336159764Sobrien "first occurrence of an out-of-memory error") \ 1337159764Sobrien \ 1338159764Sobrien /* tracing */ \ 1339186691Sobrien \ 1340159764Sobrien develop(bool, StressRewriter, false, \ 1341159764Sobrien "Stress linktime bytecode rewriting") \ 1342159764Sobrien \ 1343159764Sobrien product(ccstr, TraceJVMTI, NULL, \ 1344159764Sobrien "Trace flags for JVMTI functions and events") \ 1345159764Sobrien \ 1346159764Sobrien /* This option can change an EMCP method into an obsolete method. */ \ 1347186691Sobrien /* This can affect tests that except specific methods to be EMCP. */ \ 1348191771Sobrien /* This option should be used with caution. */ \ 1349159764Sobrien product(bool, StressLdcRewrite, false, \ 1350267897Sdelphij "Force ldc -> ldc_w rewrite during RedefineClasses") \ 1351159764Sobrien \ 1352186691Sobrien /* change to false by default sometime after Mustang */ \ 1353159764Sobrien product(bool, VerifyMergedCPBytecodes, true, \ 1354159764Sobrien "Verify bytecodes after RedefineClasses constant pool merging") \ 1355159764Sobrien \ 1356186691Sobrien develop(bool, TraceBytecodes, false, \ 1357159764Sobrien "Trace bytecode execution") \ 1358159764Sobrien \ 1359191771Sobrien develop(bool, TraceICs, false, \ 1360159764Sobrien "Trace inline cache changes") \ 1361191771Sobrien \ 1362159764Sobrien notproduct(bool, TraceInvocationCounterOverflow, false, \ 1363186691Sobrien "Trace method invocation counter overflow") \ 1364159764Sobrien \ 1365159764Sobrien develop(bool, TraceInlineCacheClearing, false, \ 1366159764Sobrien "Trace clearing of inline caches in nmethods") \ 1367159764Sobrien \ 1368186691Sobrien develop(bool, TraceDependencies, false, \ 1369159764Sobrien "Trace dependencies") \ 1370159764Sobrien \ 1371159764Sobrien develop(bool, VerifyDependencies, trueInDebug, \ 1372186691Sobrien "Exercise and verify the compilation dependency mechanism") \ 1373159764Sobrien \ 1374159764Sobrien develop(bool, TraceNewOopMapGeneration, false, \ 1375159764Sobrien "Trace OopMapGeneration") \ 1376159764Sobrien \ 1377159764Sobrien develop(bool, TraceNewOopMapGenerationDetailed, false, \ 1378159764Sobrien "Trace OopMapGeneration: print detailed cell states") \ 1379186691Sobrien \ 1380159764Sobrien develop(bool, TimeOopMap, false, \ 1381159764Sobrien "Time calls to GenerateOopMap::compute_map() in sum") \ 1382159764Sobrien \ 1383159764Sobrien develop(bool, TimeOopMap2, false, \ 1384159764Sobrien "Time calls to GenerateOopMap::compute_map() individually") \ 1385159764Sobrien \ 1386159764Sobrien develop(bool, TraceOopMapRewrites, false, \ 1387159764Sobrien "Trace rewriting of method oops during oop map generation") \ 1388159764Sobrien \ 1389159764Sobrien develop(bool, TraceICBuffer, false, \ 1390159764Sobrien "Trace usage of IC buffer") \ 1391159764Sobrien \ 1392159764Sobrien develop(bool, TraceCompiledIC, false, \ 1393191771Sobrien "Trace changes of compiled IC") \ 1394159764Sobrien \ 1395159764Sobrien /* gc */ \ 1396159764Sobrien \ 1397159764Sobrien product(bool, UseSerialGC, false, \ 1398191771Sobrien "Use the Serial garbage collector") \ 1399191771Sobrien \ 1400191771Sobrien product(bool, UseG1GC, false, \ 1401191771Sobrien "Use the Garbage-First garbage collector") \ 1402191771Sobrien \ 1403191771Sobrien product(bool, UseParallelGC, false, \ 1404191771Sobrien "Use the Parallel Scavenge garbage collector") \ 1405191771Sobrien \ 1406191771Sobrien product(bool, UseParallelOldGC, false, \ 1407159764Sobrien "Use the Parallel Old garbage collector") \ 1408186691Sobrien \ 1409159764Sobrien product(uintx, HeapMaximumCompactionInterval, 20, \ 1410159764Sobrien "How often should we maximally compact the heap (not allowing " \ 1411159764Sobrien "any dead space)") \ 1412159764Sobrien range(0, max_uintx) \ 1413159764Sobrien \ 1414186691Sobrien product(uintx, HeapFirstMaximumCompactionCount, 3, \ 1415159764Sobrien "The collection count for the first maximum compaction") \ 1416186691Sobrien range(0, max_uintx) \ 1417133359Sobrien \ 1418139368Sobrien product(bool, UseMaximumCompactionOnSystemGC, true, \ 1419139368Sobrien "Use maximum compaction in the Parallel Old garbage collector " \ 1420139368Sobrien "for a system GC") \ 1421186691Sobrien \ 1422139368Sobrien product(uintx, ParallelOldDeadWoodLimiterMean, 50, \ 1423139368Sobrien "The mean used by the parallel compact dead wood " \ 1424139368Sobrien "limiter (a number between 0-100)") \ 1425139368Sobrien range(0, 100) \ 1426186691Sobrien \ 1427139368Sobrien product(uintx, ParallelOldDeadWoodLimiterStdDev, 80, \ 1428186691Sobrien "The standard deviation used by the parallel compact dead wood " \ 1429139368Sobrien "limiter (a number between 0-100)") \ 1430139368Sobrien range(0, 100) \ 1431139368Sobrien \ 1432186691Sobrien product(uint, ParallelGCThreads, 0, \ 1433139368Sobrien "Number of parallel threads parallel gc will use") \ 1434139368Sobrien constraint(ParallelGCThreadsConstraintFunc,AfterErgo) \ 1435139368Sobrien \ 1436139368Sobrien diagnostic(bool, UseSemaphoreGCThreadsSynchronization, true, \ 1437186691Sobrien "Use semaphore synchronization for the GC Threads, " \ 1438139368Sobrien "instead of synchronization based on mutexes") \ 1439139368Sobrien \ 1440139368Sobrien product(bool, UseDynamicNumberOfGCThreads, false, \ 1441191771Sobrien "Dynamically choose the number of parallel threads " \ 1442139368Sobrien "parallel gc will use") \ 1443139368Sobrien \ 1444186691Sobrien diagnostic(bool, ForceDynamicNumberOfGCThreads, false, \ 1445133359Sobrien "Force dynamic selection of the number of " \ 1446191771Sobrien "parallel threads parallel gc will use to aid debugging") \ 1447133359Sobrien \ 1448133359Sobrien product(size_t, HeapSizePerGCThread, ScaleForWordSize(64*M), \ 1449133359Sobrien "Size of heap (bytes) per GC thread used in calculating the " \ 1450133359Sobrien "number of GC threads") \ 1451133359Sobrien range((size_t)os::vm_page_size(), (size_t)max_uintx) \ 1452133359Sobrien \ 1453133359Sobrien product(uint, ConcGCThreads, 0, \ 1454186691Sobrien "Number of threads concurrent gc will use") \ 1455133359Sobrien constraint(ConcGCThreadsConstraintFunc,AfterErgo) \ 1456133359Sobrien \ 1457133359Sobrien product(uintx, GCTaskTimeStampEntries, 200, \ 1458133359Sobrien "Number of time stamp entries per gc worker thread") \ 1459133359Sobrien range(1, max_uintx) \ 1460186691Sobrien \ 1461133359Sobrien product(bool, AlwaysTenure, false, \ 1462133359Sobrien "Always tenure objects in eden (ParallelGC only)") \ 1463133359Sobrien \ 1464133359Sobrien product(bool, NeverTenure, false, \ 1465133359Sobrien "Never tenure objects in eden, may tenure on overflow " \ 1466186691Sobrien "(ParallelGC only)") \ 1467133359Sobrien \ 1468133359Sobrien product(bool, ScavengeBeforeFullGC, true, \ 1469133359Sobrien "Scavenge youngest generation before each full GC.") \ 1470133359Sobrien \ 1471133359Sobrien product(bool, UseConcMarkSweepGC, false, \ 1472133359Sobrien "Use Concurrent Mark-Sweep GC in the old generation") \ 1473133359Sobrien \ 1474133359Sobrien product(bool, ExplicitGCInvokesConcurrent, false, \ 1475186691Sobrien "A System.gc() request invokes a concurrent collection; " \ 1476133359Sobrien "(effective only when using concurrent collectors)") \ 1477133359Sobrien \ 1478133359Sobrien product(bool, ExplicitGCInvokesConcurrentAndUnloadsClasses, false, \ 1479133359Sobrien "A System.gc() request invokes a concurrent collection and " \ 1480133359Sobrien "also unloads classes during such a concurrent gc cycle " \ 1481133359Sobrien "(effective only when UseConcMarkSweepGC)") \ 1482133359Sobrien \ 1483133359Sobrien product(bool, GCLockerInvokesConcurrent, false, \ 1484133359Sobrien "The exit of a JNI critical section necessitating a scavenge, " \ 1485133359Sobrien "also kicks off a background concurrent collection") \ 1486133359Sobrien \ 1487133359Sobrien product(uintx, GCLockerEdenExpansionPercent, 5, \ 1488133359Sobrien "How much the GC can expand the eden by while the GC locker " \ 1489133359Sobrien "is active (as a percentage)") \ 1490133359Sobrien range(0, 100) \ 1491133359Sobrien \ 1492133359Sobrien diagnostic(uintx, GCLockerRetryAllocationCount, 2, \ 1493186691Sobrien "Number of times to retry allocations when " \ 1494133359Sobrien "blocked by the GC locker") \ 1495133359Sobrien range(0, max_uintx) \ 1496133359Sobrien \ 1497133359Sobrien product(bool, UseCMSBestFit, true, \ 1498186691Sobrien "Use CMS best fit allocation strategy") \ 1499133359Sobrien \ 1500133359Sobrien product(bool, UseParNewGC, false, \ 1501133359Sobrien "Use parallel threads in the new generation") \ 1502186691Sobrien \ 1503133359Sobrien product(uintx, ParallelGCBufferWastePct, 10, \ 1504133359Sobrien "Wasted fraction of parallel allocation buffer") \ 1505133359Sobrien range(0, 100) \ 1506133359Sobrien \ 1507133359Sobrien product(uintx, TargetPLABWastePct, 10, \ 1508133359Sobrien "Target wasted space in last buffer as percent of overall " \ 1509186691Sobrien "allocation") \ 1510133359Sobrien range(1, 100) \ 1511133359Sobrien \ 1512133359Sobrien product(uintx, PLABWeight, 75, \ 1513133359Sobrien "Percentage (0-100) used to weight the current sample when " \ 1514133359Sobrien "computing exponentially decaying average for ResizePLAB") \ 1515133359Sobrien range(0, 100) \ 1516186691Sobrien \ 1517133359Sobrien product(bool, ResizePLAB, true, \ 1518133359Sobrien "Dynamically resize (survivor space) promotion LAB's") \ 1519133359Sobrien \ 1520133359Sobrien product(int, ParGCArrayScanChunk, 50, \ 1521133359Sobrien "Scan a subset of object array and push remainder, if array is " \ 1522133359Sobrien "bigger than this") \ 1523186691Sobrien range(1, max_jint/3) \ 1524133359Sobrien \ 1525133359Sobrien product(bool, ParGCUseLocalOverflow, false, \ 1526133359Sobrien "Instead of a global overflow list, use local overflow stacks") \ 1527133359Sobrien \ 1528133359Sobrien product(bool, ParGCTrimOverflow, true, \ 1529133359Sobrien "Eagerly trim the local overflow lists " \ 1530133359Sobrien "(when ParGCUseLocalOverflow)") \ 1531133359Sobrien \ 1532133359Sobrien notproduct(bool, ParGCWorkQueueOverflowALot, false, \ 1533186691Sobrien "Simulate work queue overflow in ParNew") \ 1534133359Sobrien \ 1535133359Sobrien notproduct(uintx, ParGCWorkQueueOverflowInterval, 1000, \ 1536133359Sobrien "An `interval' counter that determines how frequently " \ 1537133359Sobrien "we simulate overflow; a smaller number increases frequency") \ 1538186691Sobrien \ 1539133359Sobrien product(uintx, ParGCDesiredObjsFromOverflowList, 20, \ 1540133359Sobrien "The desired number of objects to claim from the overflow list") \ 1541133359Sobrien range(0, max_uintx) \ 1542186691Sobrien \ 1543133359Sobrien diagnostic(uintx, ParGCStridesPerThread, 2, \ 1544133359Sobrien "The number of strides per worker thread that we divide up the " \ 1545133359Sobrien "card table scanning work into") \ 1546133359Sobrien range(1, max_uintx) \ 1547186691Sobrien constraint(ParGCStridesPerThreadConstraintFunc,AfterErgo) \ 1548133359Sobrien \ 1549133359Sobrien diagnostic(intx, ParGCCardsPerStrideChunk, 256, \ 1550133359Sobrien "The number of cards in each chunk of the parallel chunks used " \ 1551133359Sobrien "during card table scanning") \ 1552133359Sobrien range(1, max_intx) \ 1553186691Sobrien constraint(ParGCCardsPerStrideChunkConstraintFunc,AfterMemoryInit)\ 1554133359Sobrien \ 1555133359Sobrien product(uintx, OldPLABWeight, 50, \ 1556133359Sobrien "Percentage (0-100) used to weight the current sample when " \ 1557133359Sobrien "computing exponentially decaying average for resizing " \ 1558186691Sobrien "OldPLABSize") \ 1559133359Sobrien range(0, 100) \ 1560133359Sobrien \ 1561133359Sobrien product(bool, ResizeOldPLAB, true, \ 1562133359Sobrien "Dynamically resize (old gen) promotion LAB's") \ 1563133359Sobrien \ 1564133359Sobrien product(size_t, CMSOldPLABMax, 1024, \ 1565133359Sobrien "Maximum size of CMS gen promotion LAB caches per worker " \ 1566133359Sobrien "per block size") \ 1567133359Sobrien range(1, max_uintx) \ 1568186691Sobrien constraint(CMSOldPLABMaxConstraintFunc,AfterMemoryInit) \ 1569133359Sobrien \ 1570133359Sobrien product(size_t, CMSOldPLABMin, 16, \ 1571133359Sobrien "Minimum size of CMS gen promotion LAB caches per worker " \ 1572186691Sobrien "per block size") \ 1573133359Sobrien range(1, max_uintx) \ 1574133359Sobrien constraint(CMSOldPLABMinConstraintFunc,AfterMemoryInit) \ 1575133359Sobrien \ 1576186691Sobrien product(uintx, CMSOldPLABNumRefills, 4, \ 1577133359Sobrien "Nominal number of refills of CMS gen promotion LAB cache " \ 1578133359Sobrien "per worker per block size") \ 1579133359Sobrien range(1, max_uintx) \ 1580186691Sobrien \ 1581133359Sobrien product(bool, CMSOldPLABResizeQuicker, false, \ 1582133359Sobrien "React on-the-fly during a scavenge to a sudden " \ 1583133359Sobrien "change in block demand rate") \ 1584133359Sobrien \ 1585186691Sobrien product(uintx, CMSOldPLABToleranceFactor, 4, \ 1586133359Sobrien "The tolerance of the phase-change detector for on-the-fly " \ 1587133359Sobrien "PLAB resizing during a scavenge") \ 1588133359Sobrien range(1, max_uintx) \ 1589133359Sobrien \ 1590133359Sobrien product(uintx, CMSOldPLABReactivityFactor, 2, \ 1591186691Sobrien "The gain in the feedback loop for on-the-fly PLAB resizing " \ 1592133359Sobrien "during a scavenge") \ 1593133359Sobrien range(1, max_uintx) \ 1594133359Sobrien \ 1595133359Sobrien product(bool, AlwaysPreTouch, false, \ 1596133359Sobrien "Force all freshly committed pages to be pre-touched") \ 1597133359Sobrien \ 1598133359Sobrien product_pd(size_t, CMSYoungGenPerWorker, \ 1599186691Sobrien "The maximum size of young gen chosen by default per GC worker " \ 1600133359Sobrien "thread available") \ 1601133359Sobrien range(1, max_uintx) \ 1602133359Sobrien \ 1603133359Sobrien product(uintx, CMSIncrementalSafetyFactor, 10, \ 1604133359Sobrien "Percentage (0-100) used to add conservatism when computing the " \ 1605133359Sobrien "duty cycle") \ 1606133359Sobrien range(0, 100) \ 1607133359Sobrien \ 1608133359Sobrien product(uintx, CMSExpAvgFactor, 50, \ 1609 "Percentage (0-100) used to weight the current sample when " \ 1610 "computing exponential averages for CMS statistics") \ 1611 range(0, 100) \ 1612 \ 1613 product(uintx, CMS_FLSWeight, 75, \ 1614 "Percentage (0-100) used to weight the current sample when " \ 1615 "computing exponentially decaying averages for CMS FLS " \ 1616 "statistics") \ 1617 range(0, 100) \ 1618 \ 1619 product(uintx, CMS_FLSPadding, 1, \ 1620 "The multiple of deviation from mean to use for buffering " \ 1621 "against volatility in free list demand") \ 1622 range(0, max_juint) \ 1623 \ 1624 product(uintx, FLSCoalescePolicy, 2, \ 1625 "CMS: aggressiveness level for coalescing, increasing " \ 1626 "from 0 to 4") \ 1627 range(0, 4) \ 1628 \ 1629 product(bool, FLSAlwaysCoalesceLarge, false, \ 1630 "CMS: larger free blocks are always available for coalescing") \ 1631 \ 1632 product(double, FLSLargestBlockCoalesceProximity, 0.99, \ 1633 "CMS: the smaller the percentage the greater the coalescing " \ 1634 "force") \ 1635 range(0.0, 1.0) \ 1636 \ 1637 product(double, CMSSmallCoalSurplusPercent, 1.05, \ 1638 "CMS: the factor by which to inflate estimated demand of small " \ 1639 "block sizes to prevent coalescing with an adjoining block") \ 1640 range(0.0, DBL_MAX) \ 1641 \ 1642 product(double, CMSLargeCoalSurplusPercent, 0.95, \ 1643 "CMS: the factor by which to inflate estimated demand of large " \ 1644 "block sizes to prevent coalescing with an adjoining block") \ 1645 range(0.0, DBL_MAX) \ 1646 \ 1647 product(double, CMSSmallSplitSurplusPercent, 1.10, \ 1648 "CMS: the factor by which to inflate estimated demand of small " \ 1649 "block sizes to prevent splitting to supply demand for smaller " \ 1650 "blocks") \ 1651 range(0.0, DBL_MAX) \ 1652 \ 1653 product(double, CMSLargeSplitSurplusPercent, 1.00, \ 1654 "CMS: the factor by which to inflate estimated demand of large " \ 1655 "block sizes to prevent splitting to supply demand for smaller " \ 1656 "blocks") \ 1657 range(0.0, DBL_MAX) \ 1658 \ 1659 product(bool, CMSExtrapolateSweep, false, \ 1660 "CMS: cushion for block demand during sweep") \ 1661 \ 1662 product(uintx, CMS_SweepWeight, 75, \ 1663 "Percentage (0-100) used to weight the current sample when " \ 1664 "computing exponentially decaying average for inter-sweep " \ 1665 "duration") \ 1666 range(0, 100) \ 1667 \ 1668 product(uintx, CMS_SweepPadding, 1, \ 1669 "The multiple of deviation from mean to use for buffering " \ 1670 "against volatility in inter-sweep duration") \ 1671 range(0, max_juint) \ 1672 \ 1673 product(uintx, CMS_SweepTimerThresholdMillis, 10, \ 1674 "Skip block flux-rate sampling for an epoch unless inter-sweep " \ 1675 "duration exceeds this threshold in milliseconds") \ 1676 range(0, max_uintx) \ 1677 \ 1678 product(bool, CMSClassUnloadingEnabled, true, \ 1679 "Whether class unloading enabled when using CMS GC") \ 1680 \ 1681 product(uintx, CMSClassUnloadingMaxInterval, 0, \ 1682 "When CMS class unloading is enabled, the maximum CMS cycle " \ 1683 "count for which classes may not be unloaded") \ 1684 range(0, max_uintx) \ 1685 \ 1686 product(uintx, CMSIndexedFreeListReplenish, 4, \ 1687 "Replenish an indexed free list with this number of chunks") \ 1688 range(1, max_uintx) \ 1689 \ 1690 product(bool, CMSReplenishIntermediate, true, \ 1691 "Replenish all intermediate free-list caches") \ 1692 \ 1693 product(bool, CMSSplitIndexedFreeListBlocks, true, \ 1694 "When satisfying batched demand, split blocks from the " \ 1695 "IndexedFreeList whose size is a multiple of requested size") \ 1696 \ 1697 product(bool, CMSLoopWarn, false, \ 1698 "Warn in case of excessive CMS looping") \ 1699 \ 1700 /* where does the range max value of (max_jint - 1) come from? */ \ 1701 product(size_t, MarkStackSizeMax, NOT_LP64(4*M) LP64_ONLY(512*M), \ 1702 "Maximum size of marking stack") \ 1703 range(1, (max_jint - 1)) \ 1704 \ 1705 product(size_t, MarkStackSize, NOT_LP64(32*K) LP64_ONLY(4*M), \ 1706 "Size of marking stack") \ 1707 constraint(MarkStackSizeConstraintFunc,AfterErgo) \ 1708 \ 1709 notproduct(bool, CMSMarkStackOverflowALot, false, \ 1710 "Simulate frequent marking stack / work queue overflow") \ 1711 \ 1712 notproduct(uintx, CMSMarkStackOverflowInterval, 1000, \ 1713 "An \"interval\" counter that determines how frequently " \ 1714 "to simulate overflow; a smaller number increases frequency") \ 1715 \ 1716 product(uintx, CMSMaxAbortablePrecleanLoops, 0, \ 1717 "Maximum number of abortable preclean iterations, if > 0") \ 1718 range(0, max_uintx) \ 1719 \ 1720 product(intx, CMSMaxAbortablePrecleanTime, 5000, \ 1721 "Maximum time in abortable preclean (in milliseconds)") \ 1722 range(0, max_intx) \ 1723 \ 1724 product(uintx, CMSAbortablePrecleanMinWorkPerIteration, 100, \ 1725 "Nominal minimum work per abortable preclean iteration") \ 1726 range(0, max_uintx) \ 1727 \ 1728 manageable(intx, CMSAbortablePrecleanWaitMillis, 100, \ 1729 "Time that we sleep between iterations when not given " \ 1730 "enough work per iteration") \ 1731 range(0, max_intx) \ 1732 \ 1733 /* 4096 = CardTableModRefBS::card_size_in_words * BitsPerWord */ \ 1734 product(size_t, CMSRescanMultiple, 32, \ 1735 "Size (in cards) of CMS parallel rescan task") \ 1736 range(1, SIZE_MAX / 4096) \ 1737 constraint(CMSRescanMultipleConstraintFunc,AfterMemoryInit) \ 1738 \ 1739 /* 4096 = CardTableModRefBS::card_size_in_words * BitsPerWord */ \ 1740 product(size_t, CMSConcMarkMultiple, 32, \ 1741 "Size (in cards) of CMS concurrent MT marking task") \ 1742 range(1, SIZE_MAX / 4096) \ 1743 constraint(CMSConcMarkMultipleConstraintFunc,AfterMemoryInit) \ 1744 \ 1745 product(bool, CMSAbortSemantics, false, \ 1746 "Whether abort-on-overflow semantics is implemented") \ 1747 \ 1748 product(bool, CMSParallelInitialMarkEnabled, true, \ 1749 "Use the parallel initial mark.") \ 1750 \ 1751 product(bool, CMSParallelRemarkEnabled, true, \ 1752 "Whether parallel remark enabled (only if ParNewGC)") \ 1753 \ 1754 product(bool, CMSParallelSurvivorRemarkEnabled, true, \ 1755 "Whether parallel remark of survivor space " \ 1756 "enabled (effective only if CMSParallelRemarkEnabled)") \ 1757 \ 1758 product(bool, CMSPLABRecordAlways, true, \ 1759 "Always record survivor space PLAB boundaries (effective only " \ 1760 "if CMSParallelSurvivorRemarkEnabled)") \ 1761 \ 1762 product(bool, CMSEdenChunksRecordAlways, true, \ 1763 "Always record eden chunks used for the parallel initial mark " \ 1764 "or remark of eden") \ 1765 \ 1766 product(bool, CMSConcurrentMTEnabled, true, \ 1767 "Whether multi-threaded concurrent work enabled " \ 1768 "(effective only if ParNewGC)") \ 1769 \ 1770 product(bool, CMSPrecleaningEnabled, true, \ 1771 "Whether concurrent precleaning enabled") \ 1772 \ 1773 product(uintx, CMSPrecleanIter, 3, \ 1774 "Maximum number of precleaning iteration passes") \ 1775 range(0, 9) \ 1776 \ 1777 product(uintx, CMSPrecleanDenominator, 3, \ 1778 "CMSPrecleanNumerator:CMSPrecleanDenominator yields convergence " \ 1779 "ratio") \ 1780 range(1, max_uintx) \ 1781 constraint(CMSPrecleanDenominatorConstraintFunc,AfterErgo) \ 1782 \ 1783 product(uintx, CMSPrecleanNumerator, 2, \ 1784 "CMSPrecleanNumerator:CMSPrecleanDenominator yields convergence " \ 1785 "ratio") \ 1786 range(0, max_uintx-1) \ 1787 constraint(CMSPrecleanNumeratorConstraintFunc,AfterErgo) \ 1788 \ 1789 product(bool, CMSPrecleanRefLists1, true, \ 1790 "Preclean ref lists during (initial) preclean phase") \ 1791 \ 1792 product(bool, CMSPrecleanRefLists2, false, \ 1793 "Preclean ref lists during abortable preclean phase") \ 1794 \ 1795 product(bool, CMSPrecleanSurvivors1, false, \ 1796 "Preclean survivors during (initial) preclean phase") \ 1797 \ 1798 product(bool, CMSPrecleanSurvivors2, true, \ 1799 "Preclean survivors during abortable preclean phase") \ 1800 \ 1801 product(uintx, CMSPrecleanThreshold, 1000, \ 1802 "Do not iterate again if number of dirty cards is less than this")\ 1803 range(100, max_uintx) \ 1804 \ 1805 product(bool, CMSCleanOnEnter, true, \ 1806 "Clean-on-enter optimization for reducing number of dirty cards") \ 1807 \ 1808 product(uintx, CMSRemarkVerifyVariant, 1, \ 1809 "Choose variant (1,2) of verification following remark") \ 1810 range(1, 2) \ 1811 \ 1812 product(size_t, CMSScheduleRemarkEdenSizeThreshold, 2*M, \ 1813 "If Eden size is below this, do not try to schedule remark") \ 1814 range(0, max_uintx) \ 1815 \ 1816 product(uintx, CMSScheduleRemarkEdenPenetration, 50, \ 1817 "The Eden occupancy percentage (0-100) at which " \ 1818 "to try and schedule remark pause") \ 1819 range(0, 100) \ 1820 \ 1821 product(uintx, CMSScheduleRemarkSamplingRatio, 5, \ 1822 "Start sampling eden top at least before young gen " \ 1823 "occupancy reaches 1/<ratio> of the size at which " \ 1824 "we plan to schedule remark") \ 1825 range(1, max_uintx) \ 1826 \ 1827 product(uintx, CMSSamplingGrain, 16*K, \ 1828 "The minimum distance between eden samples for CMS (see above)") \ 1829 range(ObjectAlignmentInBytes, max_uintx) \ 1830 constraint(CMSSamplingGrainConstraintFunc,AfterMemoryInit) \ 1831 \ 1832 product(bool, CMSScavengeBeforeRemark, false, \ 1833 "Attempt scavenge before the CMS remark step") \ 1834 \ 1835 product(uintx, CMSWorkQueueDrainThreshold, 10, \ 1836 "Don't drain below this size per parallel worker/thief") \ 1837 range(1, max_juint) \ 1838 constraint(CMSWorkQueueDrainThresholdConstraintFunc,AfterErgo) \ 1839 \ 1840 manageable(intx, CMSWaitDuration, 2000, \ 1841 "Time in milliseconds that CMS thread waits for young GC") \ 1842 range(min_jint, max_jint) \ 1843 \ 1844 develop(uintx, CMSCheckInterval, 1000, \ 1845 "Interval in milliseconds that CMS thread checks if it " \ 1846 "should start a collection cycle") \ 1847 \ 1848 product(bool, CMSYield, true, \ 1849 "Yield between steps of CMS") \ 1850 \ 1851 product(size_t, CMSBitMapYieldQuantum, 10*M, \ 1852 "Bitmap operations should process at most this many bits " \ 1853 "between yields") \ 1854 range(1, max_uintx) \ 1855 constraint(CMSBitMapYieldQuantumConstraintFunc,AfterMemoryInit) \ 1856 \ 1857 product(bool, CMSPrintChunksInDump, false, \ 1858 "If logging for the \"gc\" and \"promotion\" tags is enabled on" \ 1859 "trace level include more detailed information about the" \ 1860 "free chunks") \ 1861 \ 1862 product(bool, CMSPrintObjectsInDump, false, \ 1863 "If logging for the \"gc\" and \"promotion\" tags is enabled on" \ 1864 "trace level include more detailed information about the" \ 1865 "allocated objects") \ 1866 \ 1867 diagnostic(bool, FLSVerifyAllHeapReferences, false, \ 1868 "Verify that all references across the FLS boundary " \ 1869 "are to valid objects") \ 1870 \ 1871 diagnostic(bool, FLSVerifyLists, false, \ 1872 "Do lots of (expensive) FreeListSpace verification") \ 1873 \ 1874 diagnostic(bool, FLSVerifyIndexTable, false, \ 1875 "Do lots of (expensive) FLS index table verification") \ 1876 \ 1877 develop(bool, FLSVerifyDictionary, false, \ 1878 "Do lots of (expensive) FLS dictionary verification") \ 1879 \ 1880 develop(bool, VerifyBlockOffsetArray, false, \ 1881 "Do (expensive) block offset array verification") \ 1882 \ 1883 diagnostic(bool, BlockOffsetArrayUseUnallocatedBlock, false, \ 1884 "Maintain _unallocated_block in BlockOffsetArray " \ 1885 "(currently applicable only to CMS collector)") \ 1886 \ 1887 product(intx, RefDiscoveryPolicy, 0, \ 1888 "Select type of reference discovery policy: " \ 1889 "reference-based(0) or referent-based(1)") \ 1890 range(ReferenceProcessor::DiscoveryPolicyMin, \ 1891 ReferenceProcessor::DiscoveryPolicyMax) \ 1892 \ 1893 product(bool, ParallelRefProcEnabled, false, \ 1894 "Enable parallel reference processing whenever possible") \ 1895 \ 1896 product(bool, ParallelRefProcBalancingEnabled, true, \ 1897 "Enable balancing of reference processing queues") \ 1898 \ 1899 product(uintx, CMSTriggerRatio, 80, \ 1900 "Percentage of MinHeapFreeRatio in CMS generation that is " \ 1901 "allocated before a CMS collection cycle commences") \ 1902 range(0, 100) \ 1903 \ 1904 product(uintx, CMSBootstrapOccupancy, 50, \ 1905 "Percentage CMS generation occupancy at which to " \ 1906 "initiate CMS collection for bootstrapping collection stats") \ 1907 range(0, 100) \ 1908 \ 1909 product(intx, CMSInitiatingOccupancyFraction, -1, \ 1910 "Percentage CMS generation occupancy to start a CMS collection " \ 1911 "cycle. A negative value means that CMSTriggerRatio is used") \ 1912 range(min_intx, 100) \ 1913 \ 1914 product(uintx, InitiatingHeapOccupancyPercent, 45, \ 1915 "The percent occupancy (IHOP) of the current old generation " \ 1916 "capacity above which a concurrent mark cycle will be initiated " \ 1917 "Its value may change over time if adaptive IHOP is enabled, " \ 1918 "otherwise the value remains constant. " \ 1919 "In the latter case a value of 0 will result as frequent as " \ 1920 "possible concurrent marking cycles. A value of 100 disables " \ 1921 "concurrent marking. " \ 1922 "Fragmentation waste in the old generation is not considered " \ 1923 "free space in this calculation. (G1 collector only)") \ 1924 range(0, 100) \ 1925 \ 1926 manageable(intx, CMSTriggerInterval, -1, \ 1927 "Commence a CMS collection cycle (at least) every so many " \ 1928 "milliseconds (0 permanently, -1 disabled)") \ 1929 range(-1, max_intx) \ 1930 \ 1931 product(bool, UseCMSInitiatingOccupancyOnly, false, \ 1932 "Only use occupancy as a criterion for starting a CMS collection")\ 1933 \ 1934 product(uintx, CMSIsTooFullPercentage, 98, \ 1935 "An absolute ceiling above which CMS will always consider the " \ 1936 "unloading of classes when class unloading is enabled") \ 1937 range(0, 100) \ 1938 \ 1939 develop(bool, CMSTestInFreeList, false, \ 1940 "Check if the coalesced range is already in the " \ 1941 "free lists as claimed") \ 1942 \ 1943 notproduct(bool, CMSVerifyReturnedBytes, false, \ 1944 "Check that all the garbage collected was returned to the " \ 1945 "free lists") \ 1946 \ 1947 notproduct(bool, ScavengeALot, false, \ 1948 "Force scavenge at every Nth exit from the runtime system " \ 1949 "(N=ScavengeALotInterval)") \ 1950 \ 1951 develop(bool, FullGCALot, false, \ 1952 "Force full gc at every Nth exit from the runtime system " \ 1953 "(N=FullGCALotInterval)") \ 1954 \ 1955 notproduct(bool, GCALotAtAllSafepoints, false, \ 1956 "Enforce ScavengeALot/GCALot at all potential safepoints") \ 1957 \ 1958 notproduct(bool, PromotionFailureALot, false, \ 1959 "Use promotion failure handling on every youngest generation " \ 1960 "collection") \ 1961 \ 1962 develop(uintx, PromotionFailureALotCount, 1000, \ 1963 "Number of promotion failures occurring at PLAB " \ 1964 "refill attempts (ParNew) or promotion attempts " \ 1965 "(other young collectors)") \ 1966 \ 1967 develop(uintx, PromotionFailureALotInterval, 5, \ 1968 "Total collections between promotion failures a lot") \ 1969 \ 1970 experimental(uintx, WorkStealingSleepMillis, 1, \ 1971 "Sleep time when sleep is used for yields") \ 1972 \ 1973 experimental(uintx, WorkStealingYieldsBeforeSleep, 5000, \ 1974 "Number of yields before a sleep is done during work stealing") \ 1975 \ 1976 experimental(uintx, WorkStealingHardSpins, 4096, \ 1977 "Number of iterations in a spin loop between checks on " \ 1978 "time out of hard spin") \ 1979 \ 1980 experimental(uintx, WorkStealingSpinToYieldRatio, 10, \ 1981 "Ratio of hard spins to calls to yield") \ 1982 \ 1983 develop(uintx, ObjArrayMarkingStride, 512, \ 1984 "Number of object array elements to push onto the marking stack " \ 1985 "before pushing a continuation entry") \ 1986 \ 1987 develop(bool, MetadataAllocationFailALot, false, \ 1988 "Fail metadata allocations at intervals controlled by " \ 1989 "MetadataAllocationFailALotInterval") \ 1990 \ 1991 develop(uintx, MetadataAllocationFailALotInterval, 1000, \ 1992 "Metadata allocation failure a lot interval") \ 1993 \ 1994 notproduct(bool, ExecuteInternalVMTests, false, \ 1995 "Enable execution of internal VM tests") \ 1996 \ 1997 notproduct(bool, VerboseInternalVMTests, false, \ 1998 "Turn on logging for internal VM tests.") \ 1999 \ 2000 product(bool, ExecutingUnitTests, false, \ 2001 "Whether the JVM is running unit tests or not") \ 2002 \ 2003 product_pd(bool, UseTLAB, "Use thread-local object allocation") \ 2004 \ 2005 product_pd(bool, ResizeTLAB, \ 2006 "Dynamically resize TLAB size for threads") \ 2007 \ 2008 product(bool, ZeroTLAB, false, \ 2009 "Zero out the newly created TLAB") \ 2010 \ 2011 product(bool, FastTLABRefill, true, \ 2012 "Use fast TLAB refill code") \ 2013 \ 2014 product(bool, TLABStats, true, \ 2015 "Provide more detailed and expensive TLAB statistics.") \ 2016 \ 2017 product_pd(bool, NeverActAsServerClassMachine, \ 2018 "Never act like a server-class machine") \ 2019 \ 2020 product(bool, AlwaysActAsServerClassMachine, false, \ 2021 "Always act like a server-class machine") \ 2022 \ 2023 product_pd(uint64_t, MaxRAM, \ 2024 "Real memory size (in bytes) used to set maximum heap size") \ 2025 range(0, 0XFFFFFFFFFFFFFFFF) \ 2026 \ 2027 product(size_t, ErgoHeapSizeLimit, 0, \ 2028 "Maximum ergonomically set heap size (in bytes); zero means use " \ 2029 "MaxRAM / MaxRAMFraction") \ 2030 range(0, max_uintx) \ 2031 \ 2032 product(uintx, MaxRAMFraction, 4, \ 2033 "Maximum fraction (1/n) of real memory used for maximum heap " \ 2034 "size") \ 2035 range(1, max_uintx) \ 2036 \ 2037 product(uintx, MinRAMFraction, 2, \ 2038 "Minimum fraction (1/n) of real memory used for maximum heap " \ 2039 "size on systems with small physical memory size") \ 2040 range(1, max_uintx) \ 2041 \ 2042 product(uintx, InitialRAMFraction, 64, \ 2043 "Fraction (1/n) of real memory used for initial heap size") \ 2044 range(1, max_uintx) \ 2045 \ 2046 develop(uintx, MaxVirtMemFraction, 2, \ 2047 "Maximum fraction (1/n) of virtual memory used for ergonomically "\ 2048 "determining maximum heap size") \ 2049 \ 2050 product(bool, UseAutoGCSelectPolicy, false, \ 2051 "Use automatic collection selection policy") \ 2052 \ 2053 product(uintx, AutoGCSelectPauseMillis, 5000, \ 2054 "Automatic GC selection pause threshold in milliseconds") \ 2055 range(0, max_uintx) \ 2056 \ 2057 product(bool, UseAdaptiveSizePolicy, true, \ 2058 "Use adaptive generation sizing policies") \ 2059 \ 2060 product(bool, UsePSAdaptiveSurvivorSizePolicy, true, \ 2061 "Use adaptive survivor sizing policies") \ 2062 \ 2063 product(bool, UseAdaptiveGenerationSizePolicyAtMinorCollection, true, \ 2064 "Use adaptive young-old sizing policies at minor collections") \ 2065 \ 2066 product(bool, UseAdaptiveGenerationSizePolicyAtMajorCollection, true, \ 2067 "Use adaptive young-old sizing policies at major collections") \ 2068 \ 2069 product(bool, UseAdaptiveSizePolicyWithSystemGC, false, \ 2070 "Include statistics from System.gc() for adaptive size policy") \ 2071 \ 2072 product(bool, UseAdaptiveGCBoundary, false, \ 2073 "Allow young-old boundary to move") \ 2074 \ 2075 develop(intx, PSAdaptiveSizePolicyResizeVirtualSpaceAlot, -1, \ 2076 "Resize the virtual spaces of the young or old generations") \ 2077 range(-1, 1) \ 2078 \ 2079 product(uintx, AdaptiveSizeThroughPutPolicy, 0, \ 2080 "Policy for changing generation size for throughput goals") \ 2081 range(0, 1) \ 2082 \ 2083 product(uintx, AdaptiveSizePolicyInitializingSteps, 20, \ 2084 "Number of steps where heuristics is used before data is used") \ 2085 range(0, max_uintx) \ 2086 \ 2087 develop(uintx, AdaptiveSizePolicyReadyThreshold, 5, \ 2088 "Number of collections before the adaptive sizing is started") \ 2089 \ 2090 product(uintx, AdaptiveSizePolicyOutputInterval, 0, \ 2091 "Collection interval for printing information; zero means never") \ 2092 range(0, max_uintx) \ 2093 \ 2094 product(bool, UseAdaptiveSizePolicyFootprintGoal, true, \ 2095 "Use adaptive minimum footprint as a goal") \ 2096 \ 2097 product(uintx, AdaptiveSizePolicyWeight, 10, \ 2098 "Weight given to exponential resizing, between 0 and 100") \ 2099 range(0, 100) \ 2100 \ 2101 product(uintx, AdaptiveTimeWeight, 25, \ 2102 "Weight given to time in adaptive policy, between 0 and 100") \ 2103 range(0, 100) \ 2104 \ 2105 product(uintx, PausePadding, 1, \ 2106 "How much buffer to keep for pause time") \ 2107 range(0, max_juint) \ 2108 \ 2109 product(uintx, PromotedPadding, 3, \ 2110 "How much buffer to keep for promotion failure") \ 2111 range(0, max_juint) \ 2112 \ 2113 product(uintx, SurvivorPadding, 3, \ 2114 "How much buffer to keep for survivor overflow") \ 2115 range(0, max_juint) \ 2116 \ 2117 product(uintx, ThresholdTolerance, 10, \ 2118 "Allowed collection cost difference between generations") \ 2119 range(0, 100) \ 2120 \ 2121 product(uintx, AdaptiveSizePolicyCollectionCostMargin, 50, \ 2122 "If collection costs are within margin, reduce both by full " \ 2123 "delta") \ 2124 range(0, 100) \ 2125 \ 2126 product(uintx, YoungGenerationSizeIncrement, 20, \ 2127 "Adaptive size percentage change in young generation") \ 2128 range(0, 100) \ 2129 \ 2130 product(uintx, YoungGenerationSizeSupplement, 80, \ 2131 "Supplement to YoungedGenerationSizeIncrement used at startup") \ 2132 range(0, 100) \ 2133 \ 2134 product(uintx, YoungGenerationSizeSupplementDecay, 8, \ 2135 "Decay factor to YoungedGenerationSizeSupplement") \ 2136 range(1, max_uintx) \ 2137 \ 2138 product(uintx, TenuredGenerationSizeIncrement, 20, \ 2139 "Adaptive size percentage change in tenured generation") \ 2140 range(0, 100) \ 2141 \ 2142 product(uintx, TenuredGenerationSizeSupplement, 80, \ 2143 "Supplement to TenuredGenerationSizeIncrement used at startup") \ 2144 range(0, 100) \ 2145 \ 2146 product(uintx, TenuredGenerationSizeSupplementDecay, 2, \ 2147 "Decay factor to TenuredGenerationSizeIncrement") \ 2148 range(1, max_uintx) \ 2149 \ 2150 product(uintx, MaxGCPauseMillis, max_uintx - 1, \ 2151 "Adaptive size policy maximum GC pause time goal in millisecond, "\ 2152 "or (G1 Only) the maximum GC time per MMU time slice") \ 2153 range(1, max_uintx - 1) \ 2154 constraint(MaxGCPauseMillisConstraintFunc,AfterErgo) \ 2155 \ 2156 product(uintx, GCPauseIntervalMillis, 0, \ 2157 "Time slice for MMU specification") \ 2158 constraint(GCPauseIntervalMillisConstraintFunc,AfterErgo) \ 2159 \ 2160 product(uintx, MaxGCMinorPauseMillis, max_uintx, \ 2161 "Adaptive size policy maximum GC minor pause time goal " \ 2162 "in millisecond") \ 2163 range(0, max_uintx) \ 2164 \ 2165 product(uintx, GCTimeRatio, 99, \ 2166 "Adaptive size policy application time to GC time ratio") \ 2167 range(0, max_juint) \ 2168 \ 2169 product(uintx, AdaptiveSizeDecrementScaleFactor, 4, \ 2170 "Adaptive size scale down factor for shrinking") \ 2171 range(1, max_uintx) \ 2172 \ 2173 product(bool, UseAdaptiveSizeDecayMajorGCCost, true, \ 2174 "Adaptive size decays the major cost for long major intervals") \ 2175 \ 2176 product(uintx, AdaptiveSizeMajorGCDecayTimeScale, 10, \ 2177 "Time scale over which major costs decay") \ 2178 range(0, max_uintx) \ 2179 \ 2180 product(uintx, MinSurvivorRatio, 3, \ 2181 "Minimum ratio of young generation/survivor space size") \ 2182 range(3, max_uintx) \ 2183 \ 2184 product(uintx, InitialSurvivorRatio, 8, \ 2185 "Initial ratio of young generation/survivor space size") \ 2186 range(0, max_uintx) \ 2187 \ 2188 product(size_t, BaseFootPrintEstimate, 256*M, \ 2189 "Estimate of footprint other than Java Heap") \ 2190 range(0, max_uintx) \ 2191 \ 2192 product(bool, UseGCOverheadLimit, true, \ 2193 "Use policy to limit of proportion of time spent in GC " \ 2194 "before an OutOfMemory error is thrown") \ 2195 \ 2196 product(uintx, GCTimeLimit, 98, \ 2197 "Limit of the proportion of time spent in GC before " \ 2198 "an OutOfMemoryError is thrown (used with GCHeapFreeLimit)") \ 2199 range(0, 100) \ 2200 \ 2201 product(uintx, GCHeapFreeLimit, 2, \ 2202 "Minimum percentage of free space after a full GC before an " \ 2203 "OutOfMemoryError is thrown (used with GCTimeLimit)") \ 2204 range(0, 100) \ 2205 \ 2206 develop(uintx, AdaptiveSizePolicyGCTimeLimitThreshold, 5, \ 2207 "Number of consecutive collections before gc time limit fires") \ 2208 range(1, max_uintx) \ 2209 \ 2210 product(intx, PrefetchCopyIntervalInBytes, -1, \ 2211 "How far ahead to prefetch destination area (<= 0 means off)") \ 2212 range(-1, max_jint) \ 2213 \ 2214 product(intx, PrefetchScanIntervalInBytes, -1, \ 2215 "How far ahead to prefetch scan area (<= 0 means off)") \ 2216 range(-1, max_jint) \ 2217 \ 2218 product(intx, PrefetchFieldsAhead, -1, \ 2219 "How many fields ahead to prefetch in oop scan (<= 0 means off)") \ 2220 range(-1, max_jint) \ 2221 \ 2222 diagnostic(bool, VerifyDuringStartup, false, \ 2223 "Verify memory system before executing any Java code " \ 2224 "during VM initialization") \ 2225 \ 2226 diagnostic(bool, VerifyBeforeExit, trueInDebug, \ 2227 "Verify system before exiting") \ 2228 \ 2229 diagnostic(bool, VerifyBeforeGC, false, \ 2230 "Verify memory system before GC") \ 2231 \ 2232 diagnostic(bool, VerifyAfterGC, false, \ 2233 "Verify memory system after GC") \ 2234 \ 2235 diagnostic(bool, VerifyDuringGC, false, \ 2236 "Verify memory system during GC (between phases)") \ 2237 \ 2238 diagnostic(ccstrlist, VerifySubSet, "", \ 2239 "Memory sub-systems to verify when Verify*GC flag(s) " \ 2240 "are enabled. One or more sub-systems can be specified " \ 2241 "in a comma separated string. Sub-systems are: " \ 2242 "threads, heap, symbol_table, string_table, codecache, " \ 2243 "dictionary, classloader_data_graph, metaspace, jni_handles, " \ 2244 "c-heap, codecache_oops") \ 2245 \ 2246 diagnostic(bool, GCParallelVerificationEnabled, true, \ 2247 "Enable parallel memory system verification") \ 2248 \ 2249 diagnostic(bool, DeferInitialCardMark, false, \ 2250 "When +ReduceInitialCardMarks, explicitly defer any that " \ 2251 "may arise from new_pre_store_barrier") \ 2252 \ 2253 product(bool, UseCondCardMark, false, \ 2254 "Check for already marked card before updating card table") \ 2255 \ 2256 diagnostic(bool, VerifyRememberedSets, false, \ 2257 "Verify GC remembered sets") \ 2258 \ 2259 diagnostic(bool, VerifyObjectStartArray, true, \ 2260 "Verify GC object start array if verify before/after") \ 2261 \ 2262 product(bool, DisableExplicitGC, false, \ 2263 "Ignore calls to System.gc()") \ 2264 \ 2265 notproduct(bool, CheckMemoryInitialization, false, \ 2266 "Check memory initialization") \ 2267 \ 2268 diagnostic(bool, BindCMSThreadToCPU, false, \ 2269 "Bind CMS Thread to CPU if possible") \ 2270 \ 2271 diagnostic(uintx, CPUForCMSThread, 0, \ 2272 "When BindCMSThreadToCPU is true, the CPU to bind CMS thread to") \ 2273 range(0, max_juint) \ 2274 \ 2275 product(bool, BindGCTaskThreadsToCPUs, false, \ 2276 "Bind GCTaskThreads to CPUs if possible") \ 2277 \ 2278 product(bool, UseGCTaskAffinity, false, \ 2279 "Use worker affinity when asking for GCTasks") \ 2280 \ 2281 product(uintx, ProcessDistributionStride, 4, \ 2282 "Stride through processors when distributing processes") \ 2283 range(0, max_juint) \ 2284 \ 2285 product(uintx, CMSCoordinatorYieldSleepCount, 10, \ 2286 "Number of times the coordinator GC thread will sleep while " \ 2287 "yielding before giving up and resuming GC") \ 2288 range(0, max_juint) \ 2289 \ 2290 product(uintx, CMSYieldSleepCount, 0, \ 2291 "Number of times a GC thread (minus the coordinator) " \ 2292 "will sleep while yielding before giving up and resuming GC") \ 2293 range(0, max_juint) \ 2294 \ 2295 product(bool, PrintGC, false, \ 2296 "Print message at garbage collection. " \ 2297 "Deprecated, use -Xlog:gc instead.") \ 2298 \ 2299 product(bool, PrintGCDetails, false, \ 2300 "Print more details at garbage collection. " \ 2301 "Deprecated, use -Xlog:gc* instead.") \ 2302 \ 2303 develop(intx, ConcGCYieldTimeout, 0, \ 2304 "If non-zero, assert that GC threads yield within this " \ 2305 "number of milliseconds") \ 2306 range(0, max_intx) \ 2307 \ 2308 develop(bool, TraceFinalizerRegistration, false, \ 2309 "Trace registration of final references") \ 2310 \ 2311 notproduct(bool, TraceScavenge, false, \ 2312 "Trace scavenge") \ 2313 \ 2314 product(bool, IgnoreEmptyClassPaths, false, \ 2315 "Ignore empty path elements in -classpath") \ 2316 \ 2317 product(size_t, InitialBootClassLoaderMetaspaceSize, \ 2318 NOT_LP64(2200*K) LP64_ONLY(4*M), \ 2319 "Initial size of the boot class loader data metaspace") \ 2320 range(30*K, max_uintx/BytesPerWord) \ 2321 constraint(InitialBootClassLoaderMetaspaceSizeConstraintFunc, AfterErgo)\ 2322 \ 2323 product(bool, TraceYoungGenTime, false, \ 2324 "Trace accumulated time for young collection") \ 2325 \ 2326 product(bool, TraceOldGenTime, false, \ 2327 "Trace accumulated time for old collection") \ 2328 \ 2329 product(bool, PrintHeapAtSIGBREAK, true, \ 2330 "Print heap layout in response to SIGBREAK") \ 2331 \ 2332 manageable(bool, PrintClassHistogram, false, \ 2333 "Print a histogram of class instances") \ 2334 \ 2335 develop(bool, TraceGCTaskManager, false, \ 2336 "Trace actions of the GC task manager") \ 2337 \ 2338 develop(bool, TraceGCTaskQueue, false, \ 2339 "Trace actions of the GC task queues") \ 2340 \ 2341 develop(bool, TraceParallelOldGCMarkingPhase, false, \ 2342 "Trace marking phase in ParallelOldGC") \ 2343 \ 2344 develop(bool, TraceParallelOldGCDensePrefix, false, \ 2345 "Trace dense prefix computation for ParallelOldGC") \ 2346 \ 2347 develop(bool, IgnoreLibthreadGPFault, false, \ 2348 "Suppress workaround for libthread GP fault") \ 2349 \ 2350 experimental(double, ObjectCountCutOffPercent, 0.5, \ 2351 "The percentage of the used heap that the instances of a class " \ 2352 "must occupy for the class to generate a trace event") \ 2353 range(0.0, 100.0) \ 2354 \ 2355 /* JVMTI heap profiling */ \ 2356 \ 2357 diagnostic(bool, TraceJVMTIObjectTagging, false, \ 2358 "Trace JVMTI object tagging calls") \ 2359 \ 2360 diagnostic(bool, VerifyBeforeIteration, false, \ 2361 "Verify memory system before JVMTI iteration") \ 2362 \ 2363 /* compiler interface */ \ 2364 \ 2365 develop(bool, CIPrintCompilerName, false, \ 2366 "when CIPrint is active, print the name of the active compiler") \ 2367 \ 2368 diagnostic(bool, CIPrintCompileQueue, false, \ 2369 "display the contents of the compile queue whenever a " \ 2370 "compilation is enqueued") \ 2371 \ 2372 develop(bool, CIPrintRequests, false, \ 2373 "display every request for compilation") \ 2374 \ 2375 product(bool, CITime, false, \ 2376 "collect timing information for compilation") \ 2377 \ 2378 develop(bool, CITimeVerbose, false, \ 2379 "be more verbose in compilation timings") \ 2380 \ 2381 develop(bool, CITimeEach, false, \ 2382 "display timing information after each successful compilation") \ 2383 \ 2384 develop(bool, CICountOSR, false, \ 2385 "use a separate counter when assigning ids to osr compilations") \ 2386 \ 2387 develop(bool, CICompileNatives, true, \ 2388 "compile native methods if supported by the compiler") \ 2389 \ 2390 develop_pd(bool, CICompileOSR, \ 2391 "compile on stack replacement methods if supported by the " \ 2392 "compiler") \ 2393 \ 2394 develop(bool, CIPrintMethodCodes, false, \ 2395 "print method bytecodes of the compiled code") \ 2396 \ 2397 develop(bool, CIPrintTypeFlow, false, \ 2398 "print the results of ciTypeFlow analysis") \ 2399 \ 2400 develop(bool, CITraceTypeFlow, false, \ 2401 "detailed per-bytecode tracing of ciTypeFlow analysis") \ 2402 \ 2403 develop(intx, OSROnlyBCI, -1, \ 2404 "OSR only at this bci. Negative values mean exclude that bci") \ 2405 \ 2406 /* compiler */ \ 2407 \ 2408 /* notice: the max range value here is max_jint, not max_intx */ \ 2409 /* because of overflow issue */ \ 2410 product(intx, CICompilerCount, CI_COMPILER_COUNT, \ 2411 "Number of compiler threads to run") \ 2412 range(0, max_jint) \ 2413 constraint(CICompilerCountConstraintFunc, AtParse) \ 2414 \ 2415 product(intx, CompilationPolicyChoice, 0, \ 2416 "which compilation policy (0-3)") \ 2417 range(0, 3) \ 2418 \ 2419 develop(bool, UseStackBanging, true, \ 2420 "use stack banging for stack overflow checks (required for " \ 2421 "proper StackOverflow handling; disable only to measure cost " \ 2422 "of stackbanging)") \ 2423 \ 2424 develop(bool, UseStrictFP, true, \ 2425 "use strict fp if modifier strictfp is set") \ 2426 \ 2427 develop(bool, GenerateSynchronizationCode, true, \ 2428 "generate locking/unlocking code for synchronized methods and " \ 2429 "monitors") \ 2430 \ 2431 develop(bool, GenerateRangeChecks, true, \ 2432 "Generate range checks for array accesses") \ 2433 \ 2434 diagnostic_pd(bool, ImplicitNullChecks, \ 2435 "Generate code for implicit null checks") \ 2436 \ 2437 product_pd(bool, TrapBasedNullChecks, \ 2438 "Generate code for null checks that uses a cmp and trap " \ 2439 "instruction raising SIGTRAP. This is only used if an access to" \ 2440 "null (+offset) will not raise a SIGSEGV, i.e.," \ 2441 "ImplicitNullChecks don't work (PPC64).") \ 2442 \ 2443 product(bool, PrintSafepointStatistics, false, \ 2444 "Print statistics about safepoint synchronization") \ 2445 \ 2446 product(intx, PrintSafepointStatisticsCount, 300, \ 2447 "Total number of safepoint statistics collected " \ 2448 "before printing them out") \ 2449 range(1, max_intx) \ 2450 \ 2451 product(intx, PrintSafepointStatisticsTimeout, -1, \ 2452 "Print safepoint statistics only when safepoint takes " \ 2453 "more than PrintSafepointSatisticsTimeout in millis") \ 2454 LP64_ONLY(range(-1, max_intx/MICROUNITS)) \ 2455 NOT_LP64(range(-1, max_intx)) \ 2456 \ 2457 product(bool, Inline, true, \ 2458 "Enable inlining") \ 2459 \ 2460 product(bool, ClipInlining, true, \ 2461 "Clip inlining if aggregate method exceeds DesiredMethodLimit") \ 2462 \ 2463 develop(bool, UseCHA, true, \ 2464 "Enable CHA") \ 2465 \ 2466 product(bool, UseTypeProfile, true, \ 2467 "Check interpreter profile for historically monomorphic calls") \ 2468 \ 2469 diagnostic(bool, PrintInlining, false, \ 2470 "Print inlining optimizations") \ 2471 \ 2472 product(bool, UsePopCountInstruction, false, \ 2473 "Use population count instruction") \ 2474 \ 2475 develop(bool, EagerInitialization, false, \ 2476 "Eagerly initialize classes if possible") \ 2477 \ 2478 diagnostic(bool, LogTouchedMethods, false, \ 2479 "Log methods which have been ever touched in runtime") \ 2480 \ 2481 diagnostic(bool, PrintTouchedMethodsAtExit, false, \ 2482 "Print all methods that have been ever touched in runtime") \ 2483 \ 2484 develop(bool, TraceMethodReplacement, false, \ 2485 "Print when methods are replaced do to recompilation") \ 2486 \ 2487 develop(bool, PrintMethodFlushing, false, \ 2488 "Print the nmethods being flushed") \ 2489 \ 2490 diagnostic(bool, PrintMethodFlushingStatistics, false, \ 2491 "print statistics about method flushing") \ 2492 \ 2493 diagnostic(intx, HotMethodDetectionLimit, 100000, \ 2494 "Number of compiled code invocations after which " \ 2495 "the method is considered as hot by the flusher") \ 2496 range(1, max_jint) \ 2497 \ 2498 diagnostic(intx, MinPassesBeforeFlush, 10, \ 2499 "Minimum number of sweeper passes before an nmethod " \ 2500 "can be flushed") \ 2501 range(0, max_intx) \ 2502 \ 2503 product(bool, UseCodeAging, true, \ 2504 "Insert counter to detect warm methods") \ 2505 \ 2506 diagnostic(bool, StressCodeAging, false, \ 2507 "Start with counters compiled in") \ 2508 \ 2509 develop(bool, UseRelocIndex, false, \ 2510 "Use an index to speed random access to relocations") \ 2511 \ 2512 develop(bool, StressCodeBuffers, false, \ 2513 "Exercise code buffer expansion and other rare state changes") \ 2514 \ 2515 diagnostic(bool, DebugNonSafepoints, trueInDebug, \ 2516 "Generate extra debugging information for non-safepoints in " \ 2517 "nmethods") \ 2518 \ 2519 product(bool, PrintVMOptions, false, \ 2520 "Print flags that appeared on the command line") \ 2521 \ 2522 product(bool, IgnoreUnrecognizedVMOptions, false, \ 2523 "Ignore unrecognized VM options") \ 2524 \ 2525 product(bool, PrintCommandLineFlags, false, \ 2526 "Print flags specified on command line or set by ergonomics") \ 2527 \ 2528 product(bool, PrintFlagsInitial, false, \ 2529 "Print all VM flags before argument processing and exit VM") \ 2530 \ 2531 product(bool, PrintFlagsFinal, false, \ 2532 "Print all VM flags after argument and ergonomic processing") \ 2533 \ 2534 notproduct(bool, PrintFlagsWithComments, false, \ 2535 "Print all VM flags with default values and descriptions and " \ 2536 "exit") \ 2537 \ 2538 product(bool, PrintFlagsRanges, false, \ 2539 "Print VM flags and their ranges and exit VM") \ 2540 \ 2541 diagnostic(bool, SerializeVMOutput, true, \ 2542 "Use a mutex to serialize output to tty and LogFile") \ 2543 \ 2544 diagnostic(bool, DisplayVMOutput, true, \ 2545 "Display all VM output on the tty, independently of LogVMOutput") \ 2546 \ 2547 diagnostic(bool, LogVMOutput, false, \ 2548 "Save VM output to LogFile") \ 2549 \ 2550 diagnostic(ccstr, LogFile, NULL, \ 2551 "If LogVMOutput or LogCompilation is on, save VM output to " \ 2552 "this file [default: ./hotspot_pid%p.log] (%p replaced with pid)")\ 2553 \ 2554 product(ccstr, ErrorFile, NULL, \ 2555 "If an error occurs, save the error data to this file " \ 2556 "[default: ./hs_err_pid%p.log] (%p replaced with pid)") \ 2557 \ 2558 product(bool, DisplayVMOutputToStderr, false, \ 2559 "If DisplayVMOutput is true, display all VM output to stderr") \ 2560 \ 2561 product(bool, DisplayVMOutputToStdout, false, \ 2562 "If DisplayVMOutput is true, display all VM output to stdout") \ 2563 \ 2564 product(bool, UseHeavyMonitors, false, \ 2565 "use heavyweight instead of lightweight Java monitors") \ 2566 \ 2567 product(bool, PrintStringTableStatistics, false, \ 2568 "print statistics about the StringTable and SymbolTable") \ 2569 \ 2570 diagnostic(bool, VerifyStringTableAtExit, false, \ 2571 "verify StringTable contents at exit") \ 2572 \ 2573 notproduct(bool, PrintSymbolTableSizeHistogram, false, \ 2574 "print histogram of the symbol table") \ 2575 \ 2576 notproduct(bool, ExitVMOnVerifyError, false, \ 2577 "standard exit from VM if bytecode verify error " \ 2578 "(only in debug mode)") \ 2579 \ 2580 diagnostic(ccstr, AbortVMOnException, NULL, \ 2581 "Call fatal if this exception is thrown. Example: " \ 2582 "java -XX:AbortVMOnException=java.lang.NullPointerException Foo") \ 2583 \ 2584 diagnostic(ccstr, AbortVMOnExceptionMessage, NULL, \ 2585 "Call fatal if the exception pointed by AbortVMOnException " \ 2586 "has this message") \ 2587 \ 2588 develop(bool, DebugVtables, false, \ 2589 "add debugging code to vtable dispatch") \ 2590 \ 2591 notproduct(bool, PrintVtableStats, false, \ 2592 "print vtables stats at end of run") \ 2593 \ 2594 develop(bool, TraceCreateZombies, false, \ 2595 "trace creation of zombie nmethods") \ 2596 \ 2597 notproduct(bool, IgnoreLockingAssertions, false, \ 2598 "disable locking assertions (for speed)") \ 2599 \ 2600 product(bool, RangeCheckElimination, true, \ 2601 "Eliminate range checks") \ 2602 \ 2603 develop_pd(bool, UncommonNullCast, \ 2604 "track occurrences of null in casts; adjust compiler tactics") \ 2605 \ 2606 develop(bool, TypeProfileCasts, true, \ 2607 "treat casts like calls for purposes of type profiling") \ 2608 \ 2609 develop(bool, DelayCompilationDuringStartup, true, \ 2610 "Delay invoking the compiler until main application class is " \ 2611 "loaded") \ 2612 \ 2613 develop(bool, CompileTheWorld, false, \ 2614 "Compile all methods in all classes in bootstrap class path " \ 2615 "(stress test)") \ 2616 \ 2617 develop(bool, CompileTheWorldPreloadClasses, true, \ 2618 "Preload all classes used by a class before start loading") \ 2619 \ 2620 notproduct(intx, CompileTheWorldSafepointInterval, 100, \ 2621 "Force a safepoint every n compiles so sweeper can keep up") \ 2622 \ 2623 develop(bool, FillDelaySlots, true, \ 2624 "Fill delay slots (on SPARC only)") \ 2625 \ 2626 develop(bool, TimeLivenessAnalysis, false, \ 2627 "Time computation of bytecode liveness analysis") \ 2628 \ 2629 develop(bool, TraceLivenessGen, false, \ 2630 "Trace the generation of liveness analysis information") \ 2631 \ 2632 notproduct(bool, TraceLivenessQuery, false, \ 2633 "Trace queries of liveness analysis information") \ 2634 \ 2635 notproduct(bool, CollectIndexSetStatistics, false, \ 2636 "Collect information about IndexSets") \ 2637 \ 2638 develop(bool, UseLoopSafepoints, true, \ 2639 "Generate Safepoint nodes in every loop") \ 2640 \ 2641 develop(intx, FastAllocateSizeLimit, 128*K, \ 2642 /* Note: This value is zero mod 1<<13 for a cheap sparc set. */ \ 2643 "Inline allocations larger than this in doublewords must go slow")\ 2644 \ 2645 product(bool, AggressiveOpts, false, \ 2646 "Enable aggressive optimizations - see arguments.cpp") \ 2647 \ 2648 product_pd(bool, CompactStrings, \ 2649 "Enable Strings to use single byte chars in backing store") \ 2650 \ 2651 product_pd(uintx, TypeProfileLevel, \ 2652 "=XYZ, with Z: Type profiling of arguments at call; " \ 2653 "Y: Type profiling of return value at call; " \ 2654 "X: Type profiling of parameters to methods; " \ 2655 "X, Y and Z in 0=off ; 1=jsr292 only; 2=all methods") \ 2656 constraint(TypeProfileLevelConstraintFunc, AfterErgo) \ 2657 \ 2658 product(intx, TypeProfileArgsLimit, 2, \ 2659 "max number of call arguments to consider for type profiling") \ 2660 range(0, 16) \ 2661 \ 2662 product(intx, TypeProfileParmsLimit, 2, \ 2663 "max number of incoming parameters to consider for type profiling"\ 2664 ", -1 for all") \ 2665 range(-1, 64) \ 2666 \ 2667 /* statistics */ \ 2668 develop(bool, CountCompiledCalls, false, \ 2669 "Count method invocations") \ 2670 \ 2671 notproduct(bool, CountRuntimeCalls, false, \ 2672 "Count VM runtime calls") \ 2673 \ 2674 develop(bool, CountJNICalls, false, \ 2675 "Count jni method invocations") \ 2676 \ 2677 notproduct(bool, CountJVMCalls, false, \ 2678 "Count jvm method invocations") \ 2679 \ 2680 notproduct(bool, CountRemovableExceptions, false, \ 2681 "Count exceptions that could be replaced by branches due to " \ 2682 "inlining") \ 2683 \ 2684 notproduct(bool, ICMissHistogram, false, \ 2685 "Produce histogram of IC misses") \ 2686 \ 2687 /* interpreter */ \ 2688 product_pd(bool, RewriteBytecodes, \ 2689 "Allow rewriting of bytecodes (bytecodes are not immutable)") \ 2690 \ 2691 product_pd(bool, RewriteFrequentPairs, \ 2692 "Rewrite frequently used bytecode pairs into a single bytecode") \ 2693 \ 2694 diagnostic(bool, PrintInterpreter, false, \ 2695 "Print the generated interpreter code") \ 2696 \ 2697 product(bool, UseInterpreter, true, \ 2698 "Use interpreter for non-compiled methods") \ 2699 \ 2700 develop(bool, UseFastSignatureHandlers, true, \ 2701 "Use fast signature handlers for native calls") \ 2702 \ 2703 product(bool, UseLoopCounter, true, \ 2704 "Increment invocation counter on backward branch") \ 2705 \ 2706 product_pd(bool, UseOnStackReplacement, \ 2707 "Use on stack replacement, calls runtime if invoc. counter " \ 2708 "overflows in loop") \ 2709 \ 2710 notproduct(bool, TraceOnStackReplacement, false, \ 2711 "Trace on stack replacement") \ 2712 \ 2713 product_pd(bool, PreferInterpreterNativeStubs, \ 2714 "Use always interpreter stubs for native methods invoked via " \ 2715 "interpreter") \ 2716 \ 2717 develop(bool, CountBytecodes, false, \ 2718 "Count number of bytecodes executed") \ 2719 \ 2720 develop(bool, PrintBytecodeHistogram, false, \ 2721 "Print histogram of the executed bytecodes") \ 2722 \ 2723 develop(bool, PrintBytecodePairHistogram, false, \ 2724 "Print histogram of the executed bytecode pairs") \ 2725 \ 2726 diagnostic(bool, PrintSignatureHandlers, false, \ 2727 "Print code generated for native method signature handlers") \ 2728 \ 2729 develop(bool, VerifyOops, false, \ 2730 "Do plausibility checks for oops") \ 2731 \ 2732 develop(bool, CheckUnhandledOops, false, \ 2733 "Check for unhandled oops in VM code") \ 2734 \ 2735 develop(bool, VerifyJNIFields, trueInDebug, \ 2736 "Verify jfieldIDs for instance fields") \ 2737 \ 2738 notproduct(bool, VerifyJNIEnvThread, false, \ 2739 "Verify JNIEnv.thread == Thread::current() when entering VM " \ 2740 "from JNI") \ 2741 \ 2742 develop(bool, VerifyFPU, false, \ 2743 "Verify FPU state (check for NaN's, etc.)") \ 2744 \ 2745 develop(bool, VerifyThread, false, \ 2746 "Watch the thread register for corruption (SPARC only)") \ 2747 \ 2748 develop(bool, VerifyActivationFrameSize, false, \ 2749 "Verify that activation frame didn't become smaller than its " \ 2750 "minimal size") \ 2751 \ 2752 develop(bool, TraceFrequencyInlining, false, \ 2753 "Trace frequency based inlining") \ 2754 \ 2755 develop_pd(bool, InlineIntrinsics, \ 2756 "Inline intrinsics that can be statically resolved") \ 2757 \ 2758 product_pd(bool, ProfileInterpreter, \ 2759 "Profile at the bytecode level during interpretation") \ 2760 \ 2761 develop(bool, TraceProfileInterpreter, false, \ 2762 "Trace profiling at the bytecode level during interpretation. " \ 2763 "This outputs the profiling information collected to improve " \ 2764 "jit compilation.") \ 2765 \ 2766 develop_pd(bool, ProfileTraps, \ 2767 "Profile deoptimization traps at the bytecode level") \ 2768 \ 2769 product(intx, ProfileMaturityPercentage, 20, \ 2770 "number of method invocations/branches (expressed as % of " \ 2771 "CompileThreshold) before using the method's profile") \ 2772 range(0, 100) \ 2773 \ 2774 diagnostic(bool, PrintMethodData, false, \ 2775 "Print the results of +ProfileInterpreter at end of run") \ 2776 \ 2777 develop(bool, VerifyDataPointer, trueInDebug, \ 2778 "Verify the method data pointer during interpreter profiling") \ 2779 \ 2780 develop(bool, VerifyCompiledCode, false, \ 2781 "Include miscellaneous runtime verifications in nmethod code; " \ 2782 "default off because it disturbs nmethod size heuristics") \ 2783 \ 2784 notproduct(bool, CrashGCForDumpingJavaThread, false, \ 2785 "Manually make GC thread crash then dump java stack trace; " \ 2786 "Test only") \ 2787 \ 2788 /* compilation */ \ 2789 product(bool, UseCompiler, true, \ 2790 "Use Just-In-Time compilation") \ 2791 \ 2792 develop(bool, TraceCompilationPolicy, false, \ 2793 "Trace compilation policy") \ 2794 \ 2795 develop(bool, TimeCompilationPolicy, false, \ 2796 "Time the compilation policy") \ 2797 \ 2798 product(bool, UseCounterDecay, true, \ 2799 "Adjust recompilation counters") \ 2800 \ 2801 develop(intx, CounterHalfLifeTime, 30, \ 2802 "Half-life time of invocation counters (in seconds)") \ 2803 \ 2804 develop(intx, CounterDecayMinIntervalLength, 500, \ 2805 "The minimum interval (in milliseconds) between invocation of " \ 2806 "CounterDecay") \ 2807 \ 2808 product(bool, AlwaysCompileLoopMethods, false, \ 2809 "When using recompilation, never interpret methods " \ 2810 "containing loops") \ 2811 \ 2812 product(bool, DontCompileHugeMethods, true, \ 2813 "Do not compile methods > HugeMethodLimit") \ 2814 \ 2815 /* Bytecode escape analysis estimation. */ \ 2816 product(bool, EstimateArgEscape, true, \ 2817 "Analyze bytecodes to estimate escape state of arguments") \ 2818 \ 2819 product(intx, BCEATraceLevel, 0, \ 2820 "How much tracing to do of bytecode escape analysis estimates " \ 2821 "(0-3)") \ 2822 range(0, 3) \ 2823 \ 2824 product(intx, MaxBCEAEstimateLevel, 5, \ 2825 "Maximum number of nested calls that are analyzed by BC EA") \ 2826 range(0, max_jint) \ 2827 \ 2828 product(intx, MaxBCEAEstimateSize, 150, \ 2829 "Maximum bytecode size of a method to be analyzed by BC EA") \ 2830 range(0, max_jint) \ 2831 \ 2832 product(intx, AllocatePrefetchStyle, 1, \ 2833 "0 = no prefetch, " \ 2834 "1 = generate prefetch instructions for each allocation, " \ 2835 "2 = use TLAB watermark to gate allocation prefetch, " \ 2836 "3 = generate one prefetch instruction per cache line") \ 2837 range(0, 3) \ 2838 \ 2839 product(intx, AllocatePrefetchDistance, -1, \ 2840 "Distance to prefetch ahead of allocation pointer. " \ 2841 "-1: use system-specific value (automatically determined") \ 2842 constraint(AllocatePrefetchDistanceConstraintFunc, AfterMemoryInit)\ 2843 \ 2844 product(intx, AllocatePrefetchLines, 3, \ 2845 "Number of lines to prefetch ahead of array allocation pointer") \ 2846 range(1, 64) \ 2847 \ 2848 product(intx, AllocateInstancePrefetchLines, 1, \ 2849 "Number of lines to prefetch ahead of instance allocation " \ 2850 "pointer") \ 2851 range(1, 64) \ 2852 \ 2853 product(intx, AllocatePrefetchStepSize, 16, \ 2854 "Step size in bytes of sequential prefetch instructions") \ 2855 range(1, 512) \ 2856 constraint(AllocatePrefetchStepSizeConstraintFunc,AfterMemoryInit)\ 2857 \ 2858 product(intx, AllocatePrefetchInstr, 0, \ 2859 "Select instruction to prefetch ahead of allocation pointer") \ 2860 constraint(AllocatePrefetchInstrConstraintFunc, AfterMemoryInit) \ 2861 \ 2862 /* deoptimization */ \ 2863 develop(bool, TraceDeoptimization, false, \ 2864 "Trace deoptimization") \ 2865 \ 2866 develop(bool, PrintDeoptimizationDetails, false, \ 2867 "Print more information about deoptimization") \ 2868 \ 2869 develop(bool, DebugDeoptimization, false, \ 2870 "Tracing various information while debugging deoptimization") \ 2871 \ 2872 product(intx, SelfDestructTimer, 0, \ 2873 "Will cause VM to terminate after a given time (in minutes) " \ 2874 "(0 means off)") \ 2875 range(0, max_intx) \ 2876 \ 2877 product(intx, MaxJavaStackTraceDepth, 1024, \ 2878 "The maximum number of lines in the stack trace for Java " \ 2879 "exceptions (0 means all)") \ 2880 range(0, max_jint/2) \ 2881 \ 2882 develop(bool, TraceStackWalk, false, \ 2883 "Trace stack walking") \ 2884 \ 2885 /* notice: the max range value here is max_jint, not max_intx */ \ 2886 /* because of overflow issue */ \ 2887 diagnostic(intx, GuaranteedSafepointInterval, 1000, \ 2888 "Guarantee a safepoint (at least) every so many milliseconds " \ 2889 "(0 means none)") \ 2890 range(0, max_jint) \ 2891 \ 2892 product(intx, SafepointTimeoutDelay, 10000, \ 2893 "Delay in milliseconds for option SafepointTimeout") \ 2894 LP64_ONLY(range(0, max_intx/MICROUNITS)) \ 2895 NOT_LP64(range(0, max_intx)) \ 2896 \ 2897 product(intx, NmethodSweepActivity, 10, \ 2898 "Removes cold nmethods from code cache if > 0. Higher values " \ 2899 "result in more aggressive sweeping") \ 2900 range(0, 2000) \ 2901 \ 2902 notproduct(bool, LogSweeper, false, \ 2903 "Keep a ring buffer of sweeper activity") \ 2904 \ 2905 notproduct(intx, SweeperLogEntries, 1024, \ 2906 "Number of records in the ring buffer of sweeper activity") \ 2907 \ 2908 notproduct(intx, MemProfilingInterval, 500, \ 2909 "Time between each invocation of the MemProfiler") \ 2910 \ 2911 develop(intx, MallocCatchPtr, -1, \ 2912 "Hit breakpoint when mallocing/freeing this pointer") \ 2913 \ 2914 notproduct(ccstrlist, SuppressErrorAt, "", \ 2915 "List of assertions (file:line) to muzzle") \ 2916 \ 2917 develop(intx, StackPrintLimit, 100, \ 2918 "number of stack frames to print in VM-level stack dump") \ 2919 \ 2920 notproduct(intx, MaxElementPrintSize, 256, \ 2921 "maximum number of elements to print") \ 2922 \ 2923 notproduct(intx, MaxSubklassPrintSize, 4, \ 2924 "maximum number of subklasses to print when printing klass") \ 2925 \ 2926 product(intx, MaxInlineLevel, 9, \ 2927 "maximum number of nested calls that are inlined") \ 2928 range(0, max_jint) \ 2929 \ 2930 product(intx, MaxRecursiveInlineLevel, 1, \ 2931 "maximum number of nested recursive calls that are inlined") \ 2932 range(0, max_jint) \ 2933 \ 2934 develop(intx, MaxForceInlineLevel, 100, \ 2935 "maximum number of nested calls that are forced for inlining " \ 2936 "(using CompileCommand or marked w/ @ForceInline)") \ 2937 range(0, max_jint) \ 2938 \ 2939 product_pd(intx, InlineSmallCode, \ 2940 "Only inline already compiled methods if their code size is " \ 2941 "less than this") \ 2942 range(0, max_jint) \ 2943 \ 2944 product(intx, MaxInlineSize, 35, \ 2945 "The maximum bytecode size of a method to be inlined") \ 2946 range(0, max_jint) \ 2947 \ 2948 product_pd(intx, FreqInlineSize, \ 2949 "The maximum bytecode size of a frequent method to be inlined") \ 2950 range(0, max_jint) \ 2951 \ 2952 product(intx, MaxTrivialSize, 6, \ 2953 "The maximum bytecode size of a trivial method to be inlined") \ 2954 range(0, max_jint) \ 2955 \ 2956 product(intx, MinInliningThreshold, 250, \ 2957 "The minimum invocation count a method needs to have to be " \ 2958 "inlined") \ 2959 range(0, max_jint) \ 2960 \ 2961 develop(intx, MethodHistogramCutoff, 100, \ 2962 "The cutoff value for method invocation histogram (+CountCalls)") \ 2963 \ 2964 diagnostic(intx, ProfilerNumberOfInterpretedMethods, 25, \ 2965 "Number of interpreted methods to show in profile") \ 2966 \ 2967 diagnostic(intx, ProfilerNumberOfCompiledMethods, 25, \ 2968 "Number of compiled methods to show in profile") \ 2969 \ 2970 diagnostic(intx, ProfilerNumberOfStubMethods, 25, \ 2971 "Number of stub methods to show in profile") \ 2972 \ 2973 diagnostic(intx, ProfilerNumberOfRuntimeStubNodes, 25, \ 2974 "Number of runtime stub nodes to show in profile") \ 2975 \ 2976 product(intx, ProfileIntervalsTicks, 100, \ 2977 "Number of ticks between printing of interval profile " \ 2978 "(+ProfileIntervals)") \ 2979 range(0, max_intx) \ 2980 \ 2981 notproduct(intx, ScavengeALotInterval, 1, \ 2982 "Interval between which scavenge will occur with +ScavengeALot") \ 2983 \ 2984 notproduct(intx, FullGCALotInterval, 1, \ 2985 "Interval between which full gc will occur with +FullGCALot") \ 2986 \ 2987 notproduct(intx, FullGCALotStart, 0, \ 2988 "For which invocation to start FullGCAlot") \ 2989 \ 2990 notproduct(intx, FullGCALotDummies, 32*K, \ 2991 "Dummy object allocated with +FullGCALot, forcing all objects " \ 2992 "to move") \ 2993 \ 2994 develop(intx, DontYieldALotInterval, 10, \ 2995 "Interval between which yields will be dropped (milliseconds)") \ 2996 \ 2997 develop(intx, MinSleepInterval, 1, \ 2998 "Minimum sleep() interval (milliseconds) when " \ 2999 "ConvertSleepToYield is off (used for Solaris)") \ 3000 \ 3001 develop(intx, ProfilerPCTickThreshold, 15, \ 3002 "Number of ticks in a PC buckets to be a hotspot") \ 3003 \ 3004 notproduct(intx, DeoptimizeALotInterval, 5, \ 3005 "Number of exits until DeoptimizeALot kicks in") \ 3006 \ 3007 notproduct(intx, ZombieALotInterval, 5, \ 3008 "Number of exits until ZombieALot kicks in") \ 3009 \ 3010 diagnostic(intx, MallocVerifyInterval, 0, \ 3011 "If non-zero, verify C heap after every N calls to " \ 3012 "malloc/realloc/free") \ 3013 range(0, max_intx) \ 3014 \ 3015 diagnostic(intx, MallocVerifyStart, 0, \ 3016 "If non-zero, start verifying C heap after Nth call to " \ 3017 "malloc/realloc/free") \ 3018 range(0, max_intx) \ 3019 \ 3020 diagnostic(uintx, MallocMaxTestWords, 0, \ 3021 "If non-zero, maximum number of words that malloc/realloc can " \ 3022 "allocate (for testing only)") \ 3023 range(0, max_uintx) \ 3024 \ 3025 product(intx, TypeProfileWidth, 2, \ 3026 "Number of receiver types to record in call/cast profile") \ 3027 range(0, 8) \ 3028 \ 3029 experimental(intx, MethodProfileWidth, 0, \ 3030 "Number of methods to record in call profile") \ 3031 \ 3032 develop(intx, BciProfileWidth, 2, \ 3033 "Number of return bci's to record in ret profile") \ 3034 \ 3035 product(intx, PerMethodRecompilationCutoff, 400, \ 3036 "After recompiling N times, stay in the interpreter (-1=>'Inf')") \ 3037 range(-1, max_intx) \ 3038 \ 3039 product(intx, PerBytecodeRecompilationCutoff, 200, \ 3040 "Per-BCI limit on repeated recompilation (-1=>'Inf')") \ 3041 range(-1, max_intx) \ 3042 \ 3043 product(intx, PerMethodTrapLimit, 100, \ 3044 "Limit on traps (of one kind) in a method (includes inlines)") \ 3045 range(0, max_jint) \ 3046 \ 3047 experimental(intx, PerMethodSpecTrapLimit, 5000, \ 3048 "Limit on speculative traps (of one kind) in a method " \ 3049 "(includes inlines)") \ 3050 range(0, max_jint) \ 3051 \ 3052 product(intx, PerBytecodeTrapLimit, 4, \ 3053 "Limit on traps (of one kind) at a particular BCI") \ 3054 range(0, max_jint) \ 3055 \ 3056 experimental(intx, SpecTrapLimitExtraEntries, 3, \ 3057 "Extra method data trap entries for speculation") \ 3058 \ 3059 develop(intx, InlineFrequencyRatio, 20, \ 3060 "Ratio of call site execution to caller method invocation") \ 3061 range(0, max_jint) \ 3062 \ 3063 diagnostic_pd(intx, InlineFrequencyCount, \ 3064 "Count of call site execution necessary to trigger frequent " \ 3065 "inlining") \ 3066 range(0, max_jint) \ 3067 \ 3068 develop(intx, InlineThrowCount, 50, \ 3069 "Force inlining of interpreted methods that throw this often") \ 3070 range(0, max_jint) \ 3071 \ 3072 develop(intx, InlineThrowMaxSize, 200, \ 3073 "Force inlining of throwing methods smaller than this") \ 3074 range(0, max_jint) \ 3075 \ 3076 develop(intx, ProfilerNodeSize, 1024, \ 3077 "Size in K to allocate for the Profile Nodes of each thread") \ 3078 range(0, 1024) \ 3079 \ 3080 /* gc parameters */ \ 3081 product(size_t, InitialHeapSize, 0, \ 3082 "Initial heap size (in bytes); zero means use ergonomics") \ 3083 constraint(InitialHeapSizeConstraintFunc,AfterErgo) \ 3084 \ 3085 product(size_t, MaxHeapSize, ScaleForWordSize(96*M), \ 3086 "Maximum heap size (in bytes)") \ 3087 constraint(MaxHeapSizeConstraintFunc,AfterErgo) \ 3088 \ 3089 product(size_t, OldSize, ScaleForWordSize(4*M), \ 3090 "Initial tenured generation size (in bytes)") \ 3091 range(0, max_uintx) \ 3092 \ 3093 product(size_t, NewSize, ScaleForWordSize(1*M), \ 3094 "Initial new generation size (in bytes)") \ 3095 constraint(NewSizeConstraintFunc,AfterErgo) \ 3096 \ 3097 product(size_t, MaxNewSize, max_uintx, \ 3098 "Maximum new generation size (in bytes), max_uintx means set " \ 3099 "ergonomically") \ 3100 range(0, max_uintx) \ 3101 \ 3102 product_pd(size_t, HeapBaseMinAddress, \ 3103 "OS specific low limit for heap base address") \ 3104 constraint(HeapBaseMinAddressConstraintFunc,AfterErgo) \ 3105 \ 3106 product(size_t, PretenureSizeThreshold, 0, \ 3107 "Maximum size in bytes of objects allocated in DefNew " \ 3108 "generation; zero means no maximum") \ 3109 range(0, max_uintx) \ 3110 \ 3111 product(size_t, MinTLABSize, 2*K, \ 3112 "Minimum allowed TLAB size (in bytes)") \ 3113 range(1, max_uintx/2) \ 3114 constraint(MinTLABSizeConstraintFunc,AfterMemoryInit) \ 3115 \ 3116 product(size_t, TLABSize, 0, \ 3117 "Starting TLAB size (in bytes); zero means set ergonomically") \ 3118 constraint(TLABSizeConstraintFunc,AfterMemoryInit) \ 3119 \ 3120 product(size_t, YoungPLABSize, 4096, \ 3121 "Size of young gen promotion LAB's (in HeapWords)") \ 3122 constraint(YoungPLABSizeConstraintFunc,AfterMemoryInit) \ 3123 \ 3124 product(size_t, OldPLABSize, 1024, \ 3125 "Size of old gen promotion LAB's (in HeapWords), or Number " \ 3126 "of blocks to attempt to claim when refilling CMS LAB's") \ 3127 constraint(OldPLABSizeConstraintFunc,AfterMemoryInit) \ 3128 \ 3129 product(uintx, TLABAllocationWeight, 35, \ 3130 "Allocation averaging weight") \ 3131 range(0, 100) \ 3132 \ 3133 /* Limit the lower bound of this flag to 1 as it is used */ \ 3134 /* in a division expression. */ \ 3135 product(uintx, TLABWasteTargetPercent, 1, \ 3136 "Percentage of Eden that can be wasted") \ 3137 range(1, 100) \ 3138 \ 3139 product(uintx, TLABRefillWasteFraction, 64, \ 3140 "Maximum TLAB waste at a refill (internal fragmentation)") \ 3141 range(1, max_juint) \ 3142 \ 3143 product(uintx, TLABWasteIncrement, 4, \ 3144 "Increment allowed waste at slow allocation") \ 3145 range(0, max_jint) \ 3146 constraint(TLABWasteIncrementConstraintFunc,AfterMemoryInit) \ 3147 \ 3148 product(uintx, SurvivorRatio, 8, \ 3149 "Ratio of eden/survivor space size") \ 3150 range(1, max_uintx-2) \ 3151 constraint(SurvivorRatioConstraintFunc,AfterMemoryInit) \ 3152 \ 3153 product(uintx, NewRatio, 2, \ 3154 "Ratio of old/new generation sizes") \ 3155 range(0, max_uintx-1) \ 3156 \ 3157 product_pd(size_t, NewSizeThreadIncrease, \ 3158 "Additional size added to desired new generation size per " \ 3159 "non-daemon thread (in bytes)") \ 3160 range(0, max_uintx) \ 3161 \ 3162 product_pd(size_t, MetaspaceSize, \ 3163 "Initial threshold (in bytes) at which a garbage collection " \ 3164 "is done to reduce Metaspace usage") \ 3165 constraint(MetaspaceSizeConstraintFunc,AfterErgo) \ 3166 \ 3167 product(size_t, MaxMetaspaceSize, max_uintx, \ 3168 "Maximum size of Metaspaces (in bytes)") \ 3169 constraint(MaxMetaspaceSizeConstraintFunc,AfterErgo) \ 3170 \ 3171 product(size_t, CompressedClassSpaceSize, 1*G, \ 3172 "Maximum size of class area in Metaspace when compressed " \ 3173 "class pointers are used") \ 3174 range(1*M, 3*G) \ 3175 \ 3176 manageable(uintx, MinHeapFreeRatio, 40, \ 3177 "The minimum percentage of heap free after GC to avoid expansion."\ 3178 " For most GCs this applies to the old generation. In G1 and" \ 3179 " ParallelGC it applies to the whole heap.") \ 3180 range(0, 100) \ 3181 constraint(MinHeapFreeRatioConstraintFunc,AfterErgo) \ 3182 \ 3183 manageable(uintx, MaxHeapFreeRatio, 70, \ 3184 "The maximum percentage of heap free after GC to avoid shrinking."\ 3185 " For most GCs this applies to the old generation. In G1 and" \ 3186 " ParallelGC it applies to the whole heap.") \ 3187 range(0, 100) \ 3188 constraint(MaxHeapFreeRatioConstraintFunc,AfterErgo) \ 3189 \ 3190 product(bool, ShrinkHeapInSteps, true, \ 3191 "When disabled, informs the GC to shrink the java heap directly" \ 3192 " to the target size at the next full GC rather than requiring" \ 3193 " smaller steps during multiple full GCs.") \ 3194 \ 3195 product(intx, SoftRefLRUPolicyMSPerMB, 1000, \ 3196 "Number of milliseconds per MB of free space in the heap") \ 3197 range(0, max_intx) \ 3198 constraint(SoftRefLRUPolicyMSPerMBConstraintFunc,AfterMemoryInit) \ 3199 \ 3200 product(size_t, MinHeapDeltaBytes, ScaleForWordSize(128*K), \ 3201 "The minimum change in heap space due to GC (in bytes)") \ 3202 range(0, max_uintx) \ 3203 \ 3204 product(size_t, MinMetaspaceExpansion, ScaleForWordSize(256*K), \ 3205 "The minimum expansion of Metaspace (in bytes)") \ 3206 range(0, max_uintx) \ 3207 \ 3208 product(uintx, MaxMetaspaceFreeRatio, 70, \ 3209 "The maximum percentage of Metaspace free after GC to avoid " \ 3210 "shrinking") \ 3211 range(0, 100) \ 3212 constraint(MaxMetaspaceFreeRatioConstraintFunc,AfterErgo) \ 3213 \ 3214 product(uintx, MinMetaspaceFreeRatio, 40, \ 3215 "The minimum percentage of Metaspace free after GC to avoid " \ 3216 "expansion") \ 3217 range(0, 99) \ 3218 constraint(MinMetaspaceFreeRatioConstraintFunc,AfterErgo) \ 3219 \ 3220 product(size_t, MaxMetaspaceExpansion, ScaleForWordSize(4*M), \ 3221 "The maximum expansion of Metaspace without full GC (in bytes)") \ 3222 range(0, max_uintx) \ 3223 \ 3224 product(uintx, QueuedAllocationWarningCount, 0, \ 3225 "Number of times an allocation that queues behind a GC " \ 3226 "will retry before printing a warning") \ 3227 range(0, max_uintx) \ 3228 \ 3229 diagnostic(uintx, VerifyGCStartAt, 0, \ 3230 "GC invoke count where +VerifyBefore/AfterGC kicks in") \ 3231 range(0, max_uintx) \ 3232 \ 3233 diagnostic(intx, VerifyGCLevel, 0, \ 3234 "Generation level at which to start +VerifyBefore/AfterGC") \ 3235 range(0, 1) \ 3236 \ 3237 product(uintx, MaxTenuringThreshold, 15, \ 3238 "Maximum value for tenuring threshold") \ 3239 range(0, markOopDesc::max_age + 1) \ 3240 constraint(MaxTenuringThresholdConstraintFunc,AfterErgo) \ 3241 \ 3242 product(uintx, InitialTenuringThreshold, 7, \ 3243 "Initial value for tenuring threshold") \ 3244 range(0, markOopDesc::max_age + 1) \ 3245 constraint(InitialTenuringThresholdConstraintFunc,AfterErgo) \ 3246 \ 3247 product(uintx, TargetSurvivorRatio, 50, \ 3248 "Desired percentage of survivor space used after scavenge") \ 3249 range(0, 100) \ 3250 \ 3251 product(uintx, MarkSweepDeadRatio, 5, \ 3252 "Percentage (0-100) of the old gen allowed as dead wood. " \ 3253 "Serial mark sweep treats this as both the minimum and maximum " \ 3254 "value. " \ 3255 "CMS uses this value only if it falls back to mark sweep. " \ 3256 "Par compact uses a variable scale based on the density of the " \ 3257 "generation and treats this as the maximum value when the heap " \ 3258 "is either completely full or completely empty. Par compact " \ 3259 "also has a smaller default value; see arguments.cpp.") \ 3260 range(0, 100) \ 3261 \ 3262 product(uint, MarkSweepAlwaysCompactCount, 4, \ 3263 "How often should we fully compact the heap (ignoring the dead " \ 3264 "space parameters)") \ 3265 range(1, max_juint) \ 3266 \ 3267 develop(uintx, GCExpandToAllocateDelayMillis, 0, \ 3268 "Delay between expansion and allocation (in milliseconds)") \ 3269 \ 3270 develop(uintx, GCWorkerDelayMillis, 0, \ 3271 "Delay in scheduling GC workers (in milliseconds)") \ 3272 \ 3273 product(intx, DeferThrSuspendLoopCount, 4000, \ 3274 "(Unstable) Number of times to iterate in safepoint loop " \ 3275 "before blocking VM threads ") \ 3276 range(-1, max_jint-1) \ 3277 \ 3278 product(intx, DeferPollingPageLoopCount, -1, \ 3279 "(Unsafe,Unstable) Number of iterations in safepoint loop " \ 3280 "before changing safepoint polling page to RO ") \ 3281 range(-1, max_jint-1) \ 3282 \ 3283 product(intx, SafepointSpinBeforeYield, 2000, "(Unstable)") \ 3284 range(0, max_intx) \ 3285 \ 3286 product(bool, PSChunkLargeArrays, true, \ 3287 "Process large arrays in chunks") \ 3288 \ 3289 product(uintx, GCDrainStackTargetSize, 64, \ 3290 "Number of entries we will try to leave on the stack " \ 3291 "during parallel gc") \ 3292 range(0, max_juint) \ 3293 \ 3294 /* stack parameters */ \ 3295 product_pd(intx, StackYellowPages, \ 3296 "Number of yellow zone (recoverable overflows) pages of size " \ 3297 "4KB. If pages are bigger yellow zone is aligned up.") \ 3298 range(MIN_STACK_YELLOW_PAGES, (DEFAULT_STACK_YELLOW_PAGES+5)) \ 3299 \ 3300 product_pd(intx, StackRedPages, \ 3301 "Number of red zone (unrecoverable overflows) pages of size " \ 3302 "4KB. If pages are bigger red zone is aligned up.") \ 3303 range(MIN_STACK_RED_PAGES, (DEFAULT_STACK_RED_PAGES+2)) \ 3304 \ 3305 product_pd(intx, StackReservedPages, \ 3306 "Number of reserved zone (reserved to annotated methods) pages" \ 3307 " of size 4KB. If pages are bigger reserved zone is aligned up.") \ 3308 range(MIN_STACK_RESERVED_PAGES, (DEFAULT_STACK_RESERVED_PAGES+10))\ 3309 \ 3310 product(bool, RestrictReservedStack, true, \ 3311 "Restrict @ReservedStackAccess to trusted classes") \ 3312 \ 3313 /* greater stack shadow pages can't generate instruction to bang stack */ \ 3314 product_pd(intx, StackShadowPages, \ 3315 "Number of shadow zone (for overflow checking) pages of size " \ 3316 "4KB. If pages are bigger shadow zone is aligned up. " \ 3317 "This should exceed the depth of the VM and native call stack.") \ 3318 range(MIN_STACK_SHADOW_PAGES, (DEFAULT_STACK_SHADOW_PAGES+30)) \ 3319 \ 3320 product_pd(intx, ThreadStackSize, \ 3321 "Thread Stack Size (in Kbytes)") \ 3322 range(0, (max_intx-os::vm_page_size())/(1 * K)) \ 3323 \ 3324 product_pd(intx, VMThreadStackSize, \ 3325 "Non-Java Thread Stack Size (in Kbytes)") \ 3326 range(0, max_intx/(1 * K)) \ 3327 \ 3328 product_pd(intx, CompilerThreadStackSize, \ 3329 "Compiler Thread Stack Size (in Kbytes)") \ 3330 range(0, max_intx/(1 * K)) \ 3331 \ 3332 develop_pd(size_t, JVMInvokeMethodSlack, \ 3333 "Stack space (bytes) required for JVM_InvokeMethod to complete") \ 3334 \ 3335 /* code cache parameters */ \ 3336 /* ppc64/tiered compilation has large code-entry alignment. */ \ 3337 develop(uintx, CodeCacheSegmentSize, \ 3338 64 PPC64_ONLY(+64) NOT_PPC64(TIERED_ONLY(+64)), \ 3339 "Code cache segment size (in bytes) - smallest unit of " \ 3340 "allocation") \ 3341 range(1, 1024) \ 3342 constraint(CodeCacheSegmentSizeConstraintFunc, AfterErgo) \ 3343 \ 3344 develop_pd(intx, CodeEntryAlignment, \ 3345 "Code entry alignment for generated code (in bytes)") \ 3346 constraint(CodeEntryAlignmentConstraintFunc, AfterErgo) \ 3347 \ 3348 product_pd(intx, OptoLoopAlignment, \ 3349 "Align inner loops to zero relative to this modulus") \ 3350 range(1, 16) \ 3351 constraint(OptoLoopAlignmentConstraintFunc, AfterErgo) \ 3352 \ 3353 product_pd(uintx, InitialCodeCacheSize, \ 3354 "Initial code cache size (in bytes)") \ 3355 range(0, max_uintx) \ 3356 \ 3357 develop_pd(uintx, CodeCacheMinimumUseSpace, \ 3358 "Minimum code cache size (in bytes) required to start VM.") \ 3359 range(0, max_uintx) \ 3360 \ 3361 product(bool, SegmentedCodeCache, false, \ 3362 "Use a segmented code cache") \ 3363 \ 3364 product_pd(uintx, ReservedCodeCacheSize, \ 3365 "Reserved code cache size (in bytes) - maximum code cache size") \ 3366 range(0, max_uintx) \ 3367 \ 3368 product_pd(uintx, NonProfiledCodeHeapSize, \ 3369 "Size of code heap with non-profiled methods (in bytes)") \ 3370 range(0, max_uintx) \ 3371 \ 3372 product_pd(uintx, ProfiledCodeHeapSize, \ 3373 "Size of code heap with profiled methods (in bytes)") \ 3374 range(0, max_uintx) \ 3375 \ 3376 product_pd(uintx, NonNMethodCodeHeapSize, \ 3377 "Size of code heap with non-nmethods (in bytes)") \ 3378 range(0, max_uintx) \ 3379 \ 3380 product_pd(uintx, CodeCacheExpansionSize, \ 3381 "Code cache expansion size (in bytes)") \ 3382 range(0, max_uintx) \ 3383 \ 3384 develop_pd(uintx, CodeCacheMinBlockLength, \ 3385 "Minimum number of segments in a code cache block") \ 3386 range(1, 100) \ 3387 \ 3388 notproduct(bool, ExitOnFullCodeCache, false, \ 3389 "Exit the VM if we fill the code cache") \ 3390 \ 3391 product(bool, UseCodeCacheFlushing, true, \ 3392 "Remove cold/old nmethods from the code cache") \ 3393 \ 3394 product(uintx, StartAggressiveSweepingAt, 10, \ 3395 "Start aggressive sweeping if X[%] of the code cache is free." \ 3396 "Segmented code cache: X[%] of the non-profiled heap." \ 3397 "Non-segmented code cache: X[%] of the total code cache") \ 3398 range(0, 100) \ 3399 \ 3400 /* interpreter debugging */ \ 3401 develop(intx, BinarySwitchThreshold, 5, \ 3402 "Minimal number of lookupswitch entries for rewriting to binary " \ 3403 "switch") \ 3404 \ 3405 develop(intx, StopInterpreterAt, 0, \ 3406 "Stop interpreter execution at specified bytecode number") \ 3407 \ 3408 develop(intx, TraceBytecodesAt, 0, \ 3409 "Trace bytecodes starting with specified bytecode number") \ 3410 \ 3411 /* compiler interface */ \ 3412 develop(intx, CIStart, 0, \ 3413 "The id of the first compilation to permit") \ 3414 \ 3415 develop(intx, CIStop, max_jint, \ 3416 "The id of the last compilation to permit") \ 3417 \ 3418 develop(intx, CIStartOSR, 0, \ 3419 "The id of the first osr compilation to permit " \ 3420 "(CICountOSR must be on)") \ 3421 \ 3422 develop(intx, CIStopOSR, max_jint, \ 3423 "The id of the last osr compilation to permit " \ 3424 "(CICountOSR must be on)") \ 3425 \ 3426 develop(intx, CIBreakAtOSR, -1, \ 3427 "The id of osr compilation to break at") \ 3428 \ 3429 develop(intx, CIBreakAt, -1, \ 3430 "The id of compilation to break at") \ 3431 \ 3432 product(ccstrlist, CompileOnly, "", \ 3433 "List of methods (pkg/class.name) to restrict compilation to") \ 3434 \ 3435 product(ccstr, CompileCommandFile, NULL, \ 3436 "Read compiler commands from this file [.hotspot_compiler]") \ 3437 \ 3438 diagnostic(ccstr, CompilerDirectivesFile, NULL, \ 3439 "Read compiler directives from this file") \ 3440 \ 3441 product(ccstrlist, CompileCommand, "", \ 3442 "Prepend to .hotspot_compiler; e.g. log,java/lang/String.<init>") \ 3443 \ 3444 develop(bool, ReplayCompiles, false, \ 3445 "Enable replay of compilations from ReplayDataFile") \ 3446 \ 3447 product(ccstr, ReplayDataFile, NULL, \ 3448 "File containing compilation replay information" \ 3449 "[default: ./replay_pid%p.log] (%p replaced with pid)") \ 3450 \ 3451 product(ccstr, InlineDataFile, NULL, \ 3452 "File containing inlining replay information" \ 3453 "[default: ./inline_pid%p.log] (%p replaced with pid)") \ 3454 \ 3455 develop(intx, ReplaySuppressInitializers, 2, \ 3456 "Control handling of class initialization during replay: " \ 3457 "0 - don't do anything special; " \ 3458 "1 - treat all class initializers as empty; " \ 3459 "2 - treat class initializers for application classes as empty; " \ 3460 "3 - allow all class initializers to run during bootstrap but " \ 3461 " pretend they are empty after starting replay") \ 3462 range(0, 3) \ 3463 \ 3464 develop(bool, ReplayIgnoreInitErrors, false, \ 3465 "Ignore exceptions thrown during initialization for replay") \ 3466 \ 3467 product(bool, DumpReplayDataOnError, true, \ 3468 "Record replay data for crashing compiler threads") \ 3469 \ 3470 product(bool, CICompilerCountPerCPU, false, \ 3471 "1 compiler thread for log(N CPUs)") \ 3472 \ 3473 develop(intx, CIFireOOMAt, -1, \ 3474 "Fire OutOfMemoryErrors throughout CI for testing the compiler " \ 3475 "(non-negative value throws OOM after this many CI accesses " \ 3476 "in each compile)") \ 3477 notproduct(intx, CICrashAt, -1, \ 3478 "id of compilation to trigger assert in compiler thread for " \ 3479 "the purpose of testing, e.g. generation of replay data") \ 3480 notproduct(bool, CIObjectFactoryVerify, false, \ 3481 "enable potentially expensive verification in ciObjectFactory") \ 3482 \ 3483 /* Priorities */ \ 3484 product_pd(bool, UseThreadPriorities, "Use native thread priorities") \ 3485 \ 3486 product(intx, ThreadPriorityPolicy, 0, \ 3487 "0 : Normal. "\ 3488 " VM chooses priorities that are appropriate for normal "\ 3489 " applications. On Solaris NORM_PRIORITY and above are mapped "\ 3490 " to normal native priority. Java priorities below " \ 3491 " NORM_PRIORITY map to lower native priority values. On "\ 3492 " Windows applications are allowed to use higher native "\ 3493 " priorities. However, with ThreadPriorityPolicy=0, VM will "\ 3494 " not use the highest possible native priority, "\ 3495 " THREAD_PRIORITY_TIME_CRITICAL, as it may interfere with "\ 3496 " system threads. On Linux thread priorities are ignored "\ 3497 " because the OS does not support static priority in "\ 3498 " SCHED_OTHER scheduling class which is the only choice for "\ 3499 " non-root, non-realtime applications. "\ 3500 "1 : Aggressive. "\ 3501 " Java thread priorities map over to the entire range of "\ 3502 " native thread priorities. Higher Java thread priorities map "\ 3503 " to higher native thread priorities. This policy should be "\ 3504 " used with care, as sometimes it can cause performance "\ 3505 " degradation in the application and/or the entire system. On "\ 3506 " Linux this policy requires root privilege.") \ 3507 range(0, 1) \ 3508 \ 3509 product(bool, ThreadPriorityVerbose, false, \ 3510 "Print priority changes") \ 3511 \ 3512 product(intx, CompilerThreadPriority, -1, \ 3513 "The native priority at which compiler threads should run " \ 3514 "(-1 means no change)") \ 3515 range(min_jint, max_jint) \ 3516 constraint(CompilerThreadPriorityConstraintFunc, AfterErgo) \ 3517 \ 3518 product(intx, VMThreadPriority, -1, \ 3519 "The native priority at which the VM thread should run " \ 3520 "(-1 means no change)") \ 3521 range(-1, 127) \ 3522 \ 3523 product(bool, CompilerThreadHintNoPreempt, true, \ 3524 "(Solaris only) Give compiler threads an extra quanta") \ 3525 \ 3526 product(bool, VMThreadHintNoPreempt, false, \ 3527 "(Solaris only) Give VM thread an extra quanta") \ 3528 \ 3529 product(intx, JavaPriority1_To_OSPriority, -1, \ 3530 "Map Java priorities to OS priorities") \ 3531 range(-1, 127) \ 3532 \ 3533 product(intx, JavaPriority2_To_OSPriority, -1, \ 3534 "Map Java priorities to OS priorities") \ 3535 range(-1, 127) \ 3536 \ 3537 product(intx, JavaPriority3_To_OSPriority, -1, \ 3538 "Map Java priorities to OS priorities") \ 3539 range(-1, 127) \ 3540 \ 3541 product(intx, JavaPriority4_To_OSPriority, -1, \ 3542 "Map Java priorities to OS priorities") \ 3543 range(-1, 127) \ 3544 \ 3545 product(intx, JavaPriority5_To_OSPriority, -1, \ 3546 "Map Java priorities to OS priorities") \ 3547 range(-1, 127) \ 3548 \ 3549 product(intx, JavaPriority6_To_OSPriority, -1, \ 3550 "Map Java priorities to OS priorities") \ 3551 range(-1, 127) \ 3552 \ 3553 product(intx, JavaPriority7_To_OSPriority, -1, \ 3554 "Map Java priorities to OS priorities") \ 3555 range(-1, 127) \ 3556 \ 3557 product(intx, JavaPriority8_To_OSPriority, -1, \ 3558 "Map Java priorities to OS priorities") \ 3559 range(-1, 127) \ 3560 \ 3561 product(intx, JavaPriority9_To_OSPriority, -1, \ 3562 "Map Java priorities to OS priorities") \ 3563 range(-1, 127) \ 3564 \ 3565 product(intx, JavaPriority10_To_OSPriority,-1, \ 3566 "Map Java priorities to OS priorities") \ 3567 range(-1, 127) \ 3568 \ 3569 experimental(bool, UseCriticalJavaThreadPriority, false, \ 3570 "Java thread priority 10 maps to critical scheduling priority") \ 3571 \ 3572 experimental(bool, UseCriticalCompilerThreadPriority, false, \ 3573 "Compiler thread(s) run at critical scheduling priority") \ 3574 \ 3575 experimental(bool, UseCriticalCMSThreadPriority, false, \ 3576 "ConcurrentMarkSweep thread runs at critical scheduling priority")\ 3577 \ 3578 /* compiler debugging */ \ 3579 notproduct(intx, CompileTheWorldStartAt, 1, \ 3580 "First class to consider when using +CompileTheWorld") \ 3581 \ 3582 notproduct(intx, CompileTheWorldStopAt, max_jint, \ 3583 "Last class to consider when using +CompileTheWorld") \ 3584 \ 3585 develop(intx, NewCodeParameter, 0, \ 3586 "Testing Only: Create a dedicated integer parameter before " \ 3587 "putback") \ 3588 \ 3589 /* new oopmap storage allocation */ \ 3590 develop(intx, MinOopMapAllocation, 8, \ 3591 "Minimum number of OopMap entries in an OopMapSet") \ 3592 \ 3593 /* Background Compilation */ \ 3594 develop(intx, LongCompileThreshold, 50, \ 3595 "Used with +TraceLongCompiles") \ 3596 \ 3597 /* recompilation */ \ 3598 product_pd(intx, CompileThreshold, \ 3599 "number of interpreted method invocations before (re-)compiling") \ 3600 constraint(CompileThresholdConstraintFunc, AfterErgo) \ 3601 \ 3602 product(double, CompileThresholdScaling, 1.0, \ 3603 "Factor to control when first compilation happens " \ 3604 "(both with and without tiered compilation): " \ 3605 "values greater than 1.0 delay counter overflow, " \ 3606 "values between 0 and 1.0 rush counter overflow, " \ 3607 "value of 1.0 leaves compilation thresholds unchanged " \ 3608 "value of 0.0 is equivalent to -Xint. " \ 3609 "" \ 3610 "Flag can be set as per-method option. " \ 3611 "If a value is specified for a method, compilation thresholds " \ 3612 "for that method are scaled by both the value of the global flag "\ 3613 "and the value of the per-method flag.") \ 3614 range(0.0, DBL_MAX) \ 3615 \ 3616 product(intx, Tier0InvokeNotifyFreqLog, 7, \ 3617 "Interpreter (tier 0) invocation notification frequency") \ 3618 range(0, 30) \ 3619 \ 3620 product(intx, Tier2InvokeNotifyFreqLog, 11, \ 3621 "C1 without MDO (tier 2) invocation notification frequency") \ 3622 range(0, 30) \ 3623 \ 3624 product(intx, Tier3InvokeNotifyFreqLog, 10, \ 3625 "C1 with MDO profiling (tier 3) invocation notification " \ 3626 "frequency") \ 3627 range(0, 30) \ 3628 \ 3629 product(intx, Tier23InlineeNotifyFreqLog, 20, \ 3630 "Inlinee invocation (tiers 2 and 3) notification frequency") \ 3631 range(0, 30) \ 3632 \ 3633 product(intx, Tier0BackedgeNotifyFreqLog, 10, \ 3634 "Interpreter (tier 0) invocation notification frequency") \ 3635 range(0, 30) \ 3636 \ 3637 product(intx, Tier2BackedgeNotifyFreqLog, 14, \ 3638 "C1 without MDO (tier 2) invocation notification frequency") \ 3639 range(0, 30) \ 3640 \ 3641 product(intx, Tier3BackedgeNotifyFreqLog, 13, \ 3642 "C1 with MDO profiling (tier 3) invocation notification " \ 3643 "frequency") \ 3644 range(0, 30) \ 3645 \ 3646 product(intx, Tier2CompileThreshold, 0, \ 3647 "threshold at which tier 2 compilation is invoked") \ 3648 range(0, max_jint) \ 3649 \ 3650 product(intx, Tier2BackEdgeThreshold, 0, \ 3651 "Back edge threshold at which tier 2 compilation is invoked") \ 3652 range(0, max_jint) \ 3653 \ 3654 product(intx, Tier3InvocationThreshold, 200, \ 3655 "Compile if number of method invocations crosses this " \ 3656 "threshold") \ 3657 range(0, max_jint) \ 3658 \ 3659 product(intx, Tier3MinInvocationThreshold, 100, \ 3660 "Minimum invocation to compile at tier 3") \ 3661 range(0, max_jint) \ 3662 \ 3663 product(intx, Tier3CompileThreshold, 2000, \ 3664 "Threshold at which tier 3 compilation is invoked (invocation " \ 3665 "minimum must be satisfied)") \ 3666 range(0, max_jint) \ 3667 \ 3668 product(intx, Tier3BackEdgeThreshold, 60000, \ 3669 "Back edge threshold at which tier 3 OSR compilation is invoked") \ 3670 range(0, max_jint) \ 3671 \ 3672 product(intx, Tier4InvocationThreshold, 5000, \ 3673 "Compile if number of method invocations crosses this " \ 3674 "threshold") \ 3675 range(0, max_jint) \ 3676 \ 3677 product(intx, Tier4MinInvocationThreshold, 600, \ 3678 "Minimum invocation to compile at tier 4") \ 3679 range(0, max_jint) \ 3680 \ 3681 product(intx, Tier4CompileThreshold, 15000, \ 3682 "Threshold at which tier 4 compilation is invoked (invocation " \ 3683 "minimum must be satisfied") \ 3684 range(0, max_jint) \ 3685 \ 3686 product(intx, Tier4BackEdgeThreshold, 40000, \ 3687 "Back edge threshold at which tier 4 OSR compilation is invoked") \ 3688 range(0, max_jint) \ 3689 \ 3690 product(intx, Tier3DelayOn, 5, \ 3691 "If C2 queue size grows over this amount per compiler thread " \ 3692 "stop compiling at tier 3 and start compiling at tier 2") \ 3693 range(0, max_jint) \ 3694 \ 3695 product(intx, Tier3DelayOff, 2, \ 3696 "If C2 queue size is less than this amount per compiler thread " \ 3697 "allow methods compiled at tier 2 transition to tier 3") \ 3698 range(0, max_jint) \ 3699 \ 3700 product(intx, Tier3LoadFeedback, 5, \ 3701 "Tier 3 thresholds will increase twofold when C1 queue size " \ 3702 "reaches this amount per compiler thread") \ 3703 range(0, max_jint) \ 3704 \ 3705 product(intx, Tier4LoadFeedback, 3, \ 3706 "Tier 4 thresholds will increase twofold when C2 queue size " \ 3707 "reaches this amount per compiler thread") \ 3708 range(0, max_jint) \ 3709 \ 3710 product(intx, TieredCompileTaskTimeout, 50, \ 3711 "Kill compile task if method was not used within " \ 3712 "given timeout in milliseconds") \ 3713 range(0, max_intx) \ 3714 \ 3715 product(intx, TieredStopAtLevel, 4, \ 3716 "Stop at given compilation level") \ 3717 range(0, 4) \ 3718 \ 3719 product(intx, Tier0ProfilingStartPercentage, 200, \ 3720 "Start profiling in interpreter if the counters exceed tier 3 " \ 3721 "thresholds by the specified percentage") \ 3722 range(0, max_jint) \ 3723 \ 3724 product(uintx, IncreaseFirstTierCompileThresholdAt, 50, \ 3725 "Increase the compile threshold for C1 compilation if the code " \ 3726 "cache is filled by the specified percentage") \ 3727 range(0, 99) \ 3728 \ 3729 product(intx, TieredRateUpdateMinTime, 1, \ 3730 "Minimum rate sampling interval (in milliseconds)") \ 3731 range(0, max_intx) \ 3732 \ 3733 product(intx, TieredRateUpdateMaxTime, 25, \ 3734 "Maximum rate sampling interval (in milliseconds)") \ 3735 range(0, max_intx) \ 3736 \ 3737 product_pd(bool, TieredCompilation, \ 3738 "Enable tiered compilation") \ 3739 \ 3740 product(bool, PrintTieredEvents, false, \ 3741 "Print tiered events notifications") \ 3742 \ 3743 product_pd(intx, OnStackReplacePercentage, \ 3744 "NON_TIERED number of method invocations/branches (expressed as " \ 3745 "% of CompileThreshold) before (re-)compiling OSR code") \ 3746 constraint(OnStackReplacePercentageConstraintFunc, AfterErgo) \ 3747 \ 3748 product(intx, InterpreterProfilePercentage, 33, \ 3749 "NON_TIERED number of method invocations/branches (expressed as " \ 3750 "% of CompileThreshold) before profiling in the interpreter") \ 3751 range(0, 100) \ 3752 \ 3753 develop(intx, MaxRecompilationSearchLength, 10, \ 3754 "The maximum number of frames to inspect when searching for " \ 3755 "recompilee") \ 3756 \ 3757 develop(intx, MaxInterpretedSearchLength, 3, \ 3758 "The maximum number of interpreted frames to skip when searching "\ 3759 "for recompilee") \ 3760 \ 3761 develop(intx, DesiredMethodLimit, 8000, \ 3762 "The desired maximum method size (in bytecodes) after inlining") \ 3763 \ 3764 develop(intx, HugeMethodLimit, 8000, \ 3765 "Don't compile methods larger than this if " \ 3766 "+DontCompileHugeMethods") \ 3767 \ 3768 /* New JDK 1.4 reflection implementation */ \ 3769 \ 3770 develop(intx, FastSuperclassLimit, 8, \ 3771 "Depth of hardwired instanceof accelerator array") \ 3772 \ 3773 /* Properties for Java libraries */ \ 3774 \ 3775 product(uint64_t, MaxDirectMemorySize, 0, \ 3776 "Maximum total size of NIO direct-buffer allocations") \ 3777 range(0, max_jlong) \ 3778 \ 3779 /* Flags used for temporary code during development */ \ 3780 \ 3781 diagnostic(bool, UseNewCode, false, \ 3782 "Testing Only: Use the new version while testing") \ 3783 \ 3784 diagnostic(bool, UseNewCode2, false, \ 3785 "Testing Only: Use the new version while testing") \ 3786 \ 3787 diagnostic(bool, UseNewCode3, false, \ 3788 "Testing Only: Use the new version while testing") \ 3789 \ 3790 /* flags for performance data collection */ \ 3791 \ 3792 product(bool, UsePerfData, true, \ 3793 "Flag to disable jvmstat instrumentation for performance testing "\ 3794 "and problem isolation purposes") \ 3795 \ 3796 product(bool, PerfDataSaveToFile, false, \ 3797 "Save PerfData memory to hsperfdata_<pid> file on exit") \ 3798 \ 3799 product(ccstr, PerfDataSaveFile, NULL, \ 3800 "Save PerfData memory to the specified absolute pathname. " \ 3801 "The string %p in the file name (if present) " \ 3802 "will be replaced by pid") \ 3803 \ 3804 product(intx, PerfDataSamplingInterval, 50, \ 3805 "Data sampling interval (in milliseconds)") \ 3806 range(PeriodicTask::min_interval, max_jint) \ 3807 constraint(PerfDataSamplingIntervalFunc, AfterErgo) \ 3808 \ 3809 develop(bool, PerfTraceDataCreation, false, \ 3810 "Trace creation of Performance Data Entries") \ 3811 \ 3812 develop(bool, PerfTraceMemOps, false, \ 3813 "Trace PerfMemory create/attach/detach calls") \ 3814 \ 3815 product(bool, PerfDisableSharedMem, false, \ 3816 "Store performance data in standard memory") \ 3817 \ 3818 product(intx, PerfDataMemorySize, 32*K, \ 3819 "Size of performance data memory region. Will be rounded " \ 3820 "up to a multiple of the native os page size.") \ 3821 range(128, 32*64*K) \ 3822 \ 3823 product(intx, PerfMaxStringConstLength, 1024, \ 3824 "Maximum PerfStringConstant string length before truncation") \ 3825 range(32, 32*K) \ 3826 \ 3827 product(bool, PerfAllowAtExitRegistration, false, \ 3828 "Allow registration of atexit() methods") \ 3829 \ 3830 product(bool, PerfBypassFileSystemCheck, false, \ 3831 "Bypass Win32 file system criteria checks (Windows Only)") \ 3832 \ 3833 product(intx, UnguardOnExecutionViolation, 0, \ 3834 "Unguard page and retry on no-execute fault (Win32 only) " \ 3835 "0=off, 1=conservative, 2=aggressive") \ 3836 range(0, 2) \ 3837 \ 3838 /* Serviceability Support */ \ 3839 \ 3840 product(bool, ManagementServer, false, \ 3841 "Create JMX Management Server") \ 3842 \ 3843 product(bool, DisableAttachMechanism, false, \ 3844 "Disable mechanism that allows tools to attach to this VM") \ 3845 \ 3846 product(bool, StartAttachListener, false, \ 3847 "Always start Attach Listener at VM startup") \ 3848 \ 3849 manageable(bool, PrintConcurrentLocks, false, \ 3850 "Print java.util.concurrent locks in thread dump") \ 3851 \ 3852 product(bool, TransmitErrorReport, false, \ 3853 "Enable error report transmission on erroneous termination") \ 3854 \ 3855 product(ccstr, ErrorReportServer, NULL, \ 3856 "Override built-in error report server address") \ 3857 \ 3858 /* Shared spaces */ \ 3859 \ 3860 product(bool, UseSharedSpaces, true, \ 3861 "Use shared spaces for metadata") \ 3862 \ 3863 product(bool, VerifySharedSpaces, false, \ 3864 "Verify shared spaces (false for default archive, true for " \ 3865 "archive specified by -XX:SharedArchiveFile)") \ 3866 \ 3867 product(bool, RequireSharedSpaces, false, \ 3868 "Require shared spaces for metadata") \ 3869 \ 3870 product(bool, DumpSharedSpaces, false, \ 3871 "Special mode: JVM reads a class list, loads classes, builds " \ 3872 "shared spaces, and dumps the shared spaces to a file to be " \ 3873 "used in future JVM runs") \ 3874 \ 3875 product(bool, PrintSharedSpaces, false, \ 3876 "Print usage of shared spaces") \ 3877 \ 3878 product(bool, PrintSharedArchiveAndExit, false, \ 3879 "Print shared archive file contents") \ 3880 \ 3881 product(bool, PrintSharedDictionary, false, \ 3882 "If PrintSharedArchiveAndExit is true, also print the shared " \ 3883 "dictionary") \ 3884 \ 3885 product(size_t, SharedReadWriteSize, DEFAULT_SHARED_READ_WRITE_SIZE, \ 3886 "Size of read-write space for metadata (in bytes)") \ 3887 range(MIN_SHARED_READ_WRITE_SIZE, MAX_SHARED_READ_WRITE_SIZE) \ 3888 constraint(SharedReadWriteSizeConstraintFunc,AfterErgo) \ 3889 \ 3890 product(size_t, SharedReadOnlySize, DEFAULT_SHARED_READ_ONLY_SIZE, \ 3891 "Size of read-only space for metadata (in bytes)") \ 3892 range(MIN_SHARED_READ_ONLY_SIZE, MAX_SHARED_READ_ONLY_SIZE) \ 3893 constraint(SharedReadOnlySizeConstraintFunc,AfterErgo) \ 3894 \ 3895 product(size_t, SharedMiscDataSize, DEFAULT_SHARED_MISC_DATA_SIZE, \ 3896 "Size of the shared miscellaneous data area (in bytes)") \ 3897 range(MIN_SHARED_MISC_DATA_SIZE, MAX_SHARED_MISC_DATA_SIZE) \ 3898 constraint(SharedMiscDataSizeConstraintFunc,AfterErgo) \ 3899 \ 3900 product(size_t, SharedMiscCodeSize, DEFAULT_SHARED_MISC_CODE_SIZE, \ 3901 "Size of the shared miscellaneous code area (in bytes)") \ 3902 range(MIN_SHARED_MISC_CODE_SIZE, MAX_SHARED_MISC_CODE_SIZE) \ 3903 constraint(SharedMiscCodeSizeConstraintFunc,AfterErgo) \ 3904 \ 3905 product(size_t, SharedBaseAddress, LP64_ONLY(32*G) \ 3906 NOT_LP64(LINUX_ONLY(2*G) NOT_LINUX(0)), \ 3907 "Address to allocate shared memory region for class data") \ 3908 range(0, SIZE_MAX) \ 3909 \ 3910 product(uintx, SharedSymbolTableBucketSize, 4, \ 3911 "Average number of symbols per bucket in shared table") \ 3912 range(2, 246) \ 3913 \ 3914 diagnostic(bool, IgnoreUnverifiableClassesDuringDump, false, \ 3915 "Do not quit -Xshare:dump even if we encounter unverifiable " \ 3916 "classes. Just exclude them from the shared dictionary.") \ 3917 \ 3918 diagnostic(bool, PrintMethodHandleStubs, false, \ 3919 "Print generated stub code for method handles") \ 3920 \ 3921 develop(bool, TraceMethodHandles, false, \ 3922 "trace internal method handle operations") \ 3923 \ 3924 diagnostic(bool, VerifyMethodHandles, trueInDebug, \ 3925 "perform extra checks when constructing method handles") \ 3926 \ 3927 diagnostic(bool, ShowHiddenFrames, false, \ 3928 "show method handle implementation frames (usually hidden)") \ 3929 \ 3930 experimental(bool, TrustFinalNonStaticFields, false, \ 3931 "trust final non-static declarations for constant folding") \ 3932 \ 3933 diagnostic(bool, FoldStableValues, true, \ 3934 "Optimize loads from stable fields (marked w/ @Stable)") \ 3935 \ 3936 develop(bool, TraceInvokeDynamic, false, \ 3937 "trace internal invoke dynamic operations") \ 3938 \ 3939 diagnostic(bool, PauseAtStartup, false, \ 3940 "Causes the VM to pause at startup time and wait for the pause " \ 3941 "file to be removed (default: ./vm.paused.<pid>)") \ 3942 \ 3943 diagnostic(ccstr, PauseAtStartupFile, NULL, \ 3944 "The file to create and for whose removal to await when pausing " \ 3945 "at startup. (default: ./vm.paused.<pid>)") \ 3946 \ 3947 diagnostic(bool, PauseAtExit, false, \ 3948 "Pause and wait for keypress on exit if a debugger is attached") \ 3949 \ 3950 product(bool, ExtendedDTraceProbes, false, \ 3951 "Enable performance-impacting dtrace probes") \ 3952 \ 3953 product(bool, DTraceMethodProbes, false, \ 3954 "Enable dtrace probes for method-entry and method-exit") \ 3955 \ 3956 product(bool, DTraceAllocProbes, false, \ 3957 "Enable dtrace probes for object allocation") \ 3958 \ 3959 product(bool, DTraceMonitorProbes, false, \ 3960 "Enable dtrace probes for monitor events") \ 3961 \ 3962 product(bool, RelaxAccessControlCheck, false, \ 3963 "Relax the access control checks in the verifier") \ 3964 \ 3965 product(uintx, StringTableSize, defaultStringTableSize, \ 3966 "Number of buckets in the interned String table") \ 3967 range(minimumStringTableSize, 111*defaultStringTableSize) \ 3968 \ 3969 experimental(uintx, SymbolTableSize, defaultSymbolTableSize, \ 3970 "Number of buckets in the JVM internal Symbol table") \ 3971 range(minimumSymbolTableSize, 111*defaultSymbolTableSize) \ 3972 \ 3973 product(bool, UseStringDeduplication, false, \ 3974 "Use string deduplication") \ 3975 \ 3976 product(uintx, StringDeduplicationAgeThreshold, 3, \ 3977 "A string must reach this age (or be promoted to an old region) " \ 3978 "to be considered for deduplication") \ 3979 range(1, markOopDesc::max_age) \ 3980 \ 3981 diagnostic(bool, StringDeduplicationResizeALot, false, \ 3982 "Force table resize every time the table is scanned") \ 3983 \ 3984 diagnostic(bool, StringDeduplicationRehashALot, false, \ 3985 "Force table rehash every time the table is scanned") \ 3986 \ 3987 diagnostic(bool, WhiteBoxAPI, false, \ 3988 "Enable internal testing APIs") \ 3989 \ 3990 experimental(intx, SurvivorAlignmentInBytes, 0, \ 3991 "Default survivor space alignment in bytes") \ 3992 constraint(SurvivorAlignmentInBytesConstraintFunc,AfterErgo) \ 3993 \ 3994 product(bool , AllowNonVirtualCalls, false, \ 3995 "Obey the ACC_SUPER flag and allow invokenonvirtual calls") \ 3996 \ 3997 product(ccstr, DumpLoadedClassList, NULL, \ 3998 "Dump the names all loaded classes, that could be stored into " \ 3999 "the CDS archive, in the specified file") \ 4000 \ 4001 product(ccstr, SharedClassListFile, NULL, \ 4002 "Override the default CDS class list") \ 4003 \ 4004 diagnostic(ccstr, SharedArchiveFile, NULL, \ 4005 "Override the default location of the CDS archive file") \ 4006 \ 4007 product(ccstr, ExtraSharedClassListFile, NULL, \ 4008 "Extra classlist for building the CDS archive file") \ 4009 \ 4010 experimental(size_t, ArrayAllocatorMallocLimit, \ 4011 SOLARIS_ONLY(64*K) NOT_SOLARIS((size_t)-1), \ 4012 "Allocation less than this value will be allocated " \ 4013 "using malloc. Larger allocations will use mmap.") \ 4014 \ 4015 experimental(bool, AlwaysAtomicAccesses, false, \ 4016 "Accesses to all variables should always be atomic") \ 4017 \ 4018 product(bool, EnableTracing, false, \ 4019 "Enable event-based tracing") \ 4020 \ 4021 product(bool, UseLockedTracing, false, \ 4022 "Use locked-tracing when doing event-based tracing") \ 4023 \ 4024 diagnostic(bool, UseUnalignedAccesses, false, \ 4025 "Use unaligned memory accesses in Unsafe") \ 4026 \ 4027 product_pd(bool, PreserveFramePointer, \ 4028 "Use the FP register for holding the frame pointer " \ 4029 "and not as a general purpose register.") \ 4030 \ 4031 diagnostic(bool, CheckIntrinsics, true, \ 4032 "When a class C is loaded, check that " \ 4033 "(1) all intrinsics defined by the VM for class C are present "\ 4034 "in the loaded class file and are marked with the " \ 4035 "@HotSpotIntrinsicCandidate annotation, that " \ 4036 "(2) there is an intrinsic registered for all loaded methods " \ 4037 "that are annotated with the @HotSpotIntrinsicCandidate " \ 4038 "annotation, and that " \ 4039 "(3) no orphan methods exist for class C (i.e., methods for " \ 4040 "which the VM declares an intrinsic but that are not declared "\ 4041 "in the loaded class C. " \ 4042 "Check (3) is available only in debug builds.") \ 4043 \ 4044 diagnostic_pd(intx, InitArrayShortSize, \ 4045 "Threshold small size (in bytes) for clearing arrays. " \ 4046 "Anything this size or smaller may get converted to discrete " \ 4047 "scalar stores.") \ 4048 range(0, max_intx) \ 4049 constraint(InitArrayShortSizeConstraintFunc, AfterErgo) \ 4050 \ 4051 diagnostic(bool, CompilerDirectivesIgnoreCompileCommands, false, \ 4052 "Disable backwards compatibility for compile commands.") \ 4053 \ 4054 diagnostic(bool, CompilerDirectivesPrint, false, \ 4055 "Print compiler directives on installation.") \ 4056 diagnostic(int, CompilerDirectivesLimit, 50, \ 4057 "Limit on number of compiler directives.") 4058 4059 4060/* 4061 * Macros for factoring of globals 4062 */ 4063 4064// Interface macros 4065#define DECLARE_PRODUCT_FLAG(type, name, value, doc) extern "C" type name; 4066#define DECLARE_PD_PRODUCT_FLAG(type, name, doc) extern "C" type name; 4067#define DECLARE_DIAGNOSTIC_FLAG(type, name, value, doc) extern "C" type name; 4068#define DECLARE_PD_DIAGNOSTIC_FLAG(type, name, doc) extern "C" type name; 4069#define DECLARE_EXPERIMENTAL_FLAG(type, name, value, doc) extern "C" type name; 4070#define DECLARE_MANAGEABLE_FLAG(type, name, value, doc) extern "C" type name; 4071#define DECLARE_PRODUCT_RW_FLAG(type, name, value, doc) extern "C" type name; 4072#ifdef PRODUCT 4073#define DECLARE_DEVELOPER_FLAG(type, name, value, doc) const type name = value; 4074#define DECLARE_PD_DEVELOPER_FLAG(type, name, doc) const type name = pd_##name; 4075#define DECLARE_NOTPRODUCT_FLAG(type, name, value, doc) const type name = value; 4076#else 4077#define DECLARE_DEVELOPER_FLAG(type, name, value, doc) extern "C" type name; 4078#define DECLARE_PD_DEVELOPER_FLAG(type, name, doc) extern "C" type name; 4079#define DECLARE_NOTPRODUCT_FLAG(type, name, value, doc) extern "C" type name; 4080#endif // PRODUCT 4081// Special LP64 flags, product only needed for now. 4082#ifdef _LP64 4083#define DECLARE_LP64_PRODUCT_FLAG(type, name, value, doc) extern "C" type name; 4084#else 4085#define DECLARE_LP64_PRODUCT_FLAG(type, name, value, doc) const type name = value; 4086#endif // _LP64 4087 4088// Implementation macros 4089#define MATERIALIZE_PRODUCT_FLAG(type, name, value, doc) type name = value; 4090#define MATERIALIZE_PD_PRODUCT_FLAG(type, name, doc) type name = pd_##name; 4091#define MATERIALIZE_DIAGNOSTIC_FLAG(type, name, value, doc) type name = value; 4092#define MATERIALIZE_PD_DIAGNOSTIC_FLAG(type, name, doc) type name = pd_##name; 4093#define MATERIALIZE_EXPERIMENTAL_FLAG(type, name, value, doc) type name = value; 4094#define MATERIALIZE_MANAGEABLE_FLAG(type, name, value, doc) type name = value; 4095#define MATERIALIZE_PRODUCT_RW_FLAG(type, name, value, doc) type name = value; 4096#ifdef PRODUCT 4097#define MATERIALIZE_DEVELOPER_FLAG(type, name, value, doc) 4098#define MATERIALIZE_PD_DEVELOPER_FLAG(type, name, doc) 4099#define MATERIALIZE_NOTPRODUCT_FLAG(type, name, value, doc) 4100#else 4101#define MATERIALIZE_DEVELOPER_FLAG(type, name, value, doc) type name = value; 4102#define MATERIALIZE_PD_DEVELOPER_FLAG(type, name, doc) type name = pd_##name; 4103#define MATERIALIZE_NOTPRODUCT_FLAG(type, name, value, doc) type name = value; 4104#endif // PRODUCT 4105#ifdef _LP64 4106#define MATERIALIZE_LP64_PRODUCT_FLAG(type, name, value, doc) type name = value; 4107#else 4108#define MATERIALIZE_LP64_PRODUCT_FLAG(type, name, value, doc) /* flag is constant */ 4109#endif // _LP64 4110 4111// Only materialize src code for range checking when required, ignore otherwise 4112#define IGNORE_RANGE(a, b) 4113// Only materialize src code for contraint checking when required, ignore otherwise 4114#define IGNORE_CONSTRAINT(func,type) 4115 4116#define IGNORE_WRITEABLE(type) 4117 4118RUNTIME_FLAGS(DECLARE_DEVELOPER_FLAG, \ 4119 DECLARE_PD_DEVELOPER_FLAG, \ 4120 DECLARE_PRODUCT_FLAG, \ 4121 DECLARE_PD_PRODUCT_FLAG, \ 4122 DECLARE_DIAGNOSTIC_FLAG, \ 4123 DECLARE_PD_DIAGNOSTIC_FLAG, \ 4124 DECLARE_EXPERIMENTAL_FLAG, \ 4125 DECLARE_NOTPRODUCT_FLAG, \ 4126 DECLARE_MANAGEABLE_FLAG, \ 4127 DECLARE_PRODUCT_RW_FLAG, \ 4128 DECLARE_LP64_PRODUCT_FLAG, \ 4129 IGNORE_RANGE, \ 4130 IGNORE_CONSTRAINT, \ 4131 IGNORE_WRITEABLE) 4132 4133RUNTIME_OS_FLAGS(DECLARE_DEVELOPER_FLAG, \ 4134 DECLARE_PD_DEVELOPER_FLAG, \ 4135 DECLARE_PRODUCT_FLAG, \ 4136 DECLARE_PD_PRODUCT_FLAG, \ 4137 DECLARE_DIAGNOSTIC_FLAG, \ 4138 DECLARE_PD_DIAGNOSTIC_FLAG, \ 4139 DECLARE_NOTPRODUCT_FLAG, \ 4140 IGNORE_RANGE, \ 4141 IGNORE_CONSTRAINT, \ 4142 IGNORE_WRITEABLE) 4143 4144ARCH_FLAGS(DECLARE_DEVELOPER_FLAG, \ 4145 DECLARE_PRODUCT_FLAG, \ 4146 DECLARE_DIAGNOSTIC_FLAG, \ 4147 DECLARE_EXPERIMENTAL_FLAG, \ 4148 DECLARE_NOTPRODUCT_FLAG, \ 4149 IGNORE_RANGE, \ 4150 IGNORE_CONSTRAINT, \ 4151 IGNORE_WRITEABLE) 4152 4153// Extensions 4154 4155#include "runtime/globals_ext.hpp" 4156 4157#endif // SHARE_VM_RUNTIME_GLOBALS_HPP 4158