1 /* 2 * Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * This code is free software; you can redistribute it and/or modify it 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. 8 * 9 * This code is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 12 * version 2 for more details (a copy is included in the LICENSE file that 13 * accompanied this code). 14 * 15 * You should have received a copy of the GNU General Public License version 16 * 2 along with this work; if not, write to the Free Software Foundation, 17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 18 * 19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 20 * or visit www.oracle.com if you need additional information or have any 21 * questions. 22 * 23 */ 24 25 #ifndef SHARE_VM_OPTO_C2_GLOBALS_HPP 26 #define SHARE_VM_OPTO_C2_GLOBALS_HPP 27 28 #include "runtime/globals.hpp" 29 #ifdef TARGET_ARCH_x86 30 # include "c2_globals_x86.hpp" 31 #endif 32 #ifdef TARGET_ARCH_sparc 33 # include "c2_globals_sparc.hpp" 34 #endif 35 #ifdef TARGET_ARCH_arm 36 # include "c2_globals_arm.hpp" 37 #endif 38 #ifdef TARGET_ARCH_ppc 39 # include "c2_globals_ppc.hpp" 40 #endif 41 #ifdef TARGET_ARCH_aarch64 42 # include "c2_globals_aarch64.hpp" 43 #endif 44 #ifdef TARGET_OS_FAMILY_linux 45 # include "c2_globals_linux.hpp" 46 #endif 47 #ifdef TARGET_OS_FAMILY_solaris 48 # include "c2_globals_solaris.hpp" 49 #endif 50 #ifdef TARGET_OS_FAMILY_windows 51 # include "c2_globals_windows.hpp" 52 #endif 53 #ifdef TARGET_OS_FAMILY_aix 54 # include "c2_globals_aix.hpp" 55 #endif 56 #ifdef TARGET_OS_FAMILY_bsd 57 # include "c2_globals_bsd.hpp" 58 #endif 59 60 // 61 // Defines all globals flags used by the server compiler. 62 // 63 64 #define C2_FLAGS(develop, develop_pd, product, product_pd, diagnostic, experimental, notproduct, range, constraint) \ 65 \ 66 develop(bool, StressLCM, false, \ 67 "Randomize instruction scheduling in LCM") \ 68 \ 69 develop(bool, StressGCM, false, \ 70 "Randomize instruction scheduling in GCM") \ 71 \ 72 develop(intx, OptoPrologueNops, 0, \ 73 "Insert this many extra nop instructions " \ 74 "in the prologue of every nmethod") \ 75 range(0, 128) \ 76 \ 77 product_pd(intx, InteriorEntryAlignment, \ 78 "Code alignment for interior entry points " \ 79 "in generated code (in bytes)") \ 80 constraint(InteriorEntryAlignmentConstraintFunc, AfterErgo) \ 81 \ 82 product(intx, MaxLoopPad, (OptoLoopAlignment-1), \ 83 "Align a loop if padding size in bytes is less or equal to this " \ 84 "value") \ 85 range(0, max_jint) \ 86 \ 87 product(intx, MaxVectorSize, 64, \ 88 "Max vector size in bytes, " \ 89 "actual size could be less depending on elements type") \ 90 range(0, max_jint) \ 91 \ 92 product(bool, AlignVector, true, \ 93 "Perform vector store/load alignment in loop") \ 94 \ 95 product(intx, NumberOfLoopInstrToAlign, 4, \ 96 "Number of first instructions in a loop to align") \ 97 range(0, max_jint) \ 98 \ 99 notproduct(intx, IndexSetWatch, 0, \ 100 "Trace all operations on this IndexSet (-1 means all, 0 none)") \ 101 range(-1, 0) \ 102 \ 103 develop(intx, OptoNodeListSize, 4, \ 104 "Starting allocation size of Node_List data structures") \ 105 range(0, max_jint) \ 106 \ 107 develop(intx, OptoBlockListSize, 8, \ 108 "Starting allocation size of Block_List data structures") \ 109 range(0, max_jint) \ 110 \ 111 develop(intx, OptoPeepholeAt, -1, \ 112 "Apply peephole optimizations to this peephole rule") \ 113 \ 114 notproduct(bool, PrintIdeal, false, \ 115 "Print ideal graph before code generation") \ 116 \ 117 notproduct(bool, PrintOpto, false, \ 118 "Print compiler2 attempts") \ 119 \ 120 notproduct(bool, PrintOptoInlining, false, \ 121 "Print compiler2 inlining decisions") \ 122 \ 123 notproduct(bool, VerifyOpto, false, \ 124 "Apply more time consuming verification during compilation") \ 125 \ 126 notproduct(bool, VerifyIdealNodeCount, false, \ 127 "Verify that tracked dead ideal node count is accurate") \ 128 \ 129 notproduct(bool, PrintIdealNodeCount, false, \ 130 "Print liveness counts of ideal nodes") \ 131 \ 132 notproduct(bool, VerifyOptoOopOffsets, false, \ 133 "Check types of base addresses in field references") \ 134 \ 135 develop(bool, IdealizedNumerics, false, \ 136 "Check performance difference allowing FP " \ 137 "associativity and commutativity...") \ 138 \ 139 develop(bool, OptoBreakpoint, false, \ 140 "insert breakpoint at method entry") \ 141 \ 142 notproduct(bool, OptoBreakpointOSR, false, \ 143 "insert breakpoint at osr method entry") \ 144 \ 145 notproduct(intx, BreakAtNode, 0, \ 146 "Break at construction of this Node (either _idx or _debug_idx)") \ 147 \ 148 notproduct(bool, OptoBreakpointC2R, false, \ 149 "insert breakpoint at runtime stub entry") \ 150 \ 151 notproduct(bool, OptoNoExecute, false, \ 152 "Attempt to parse and compile but do not execute generated code") \ 153 \ 154 notproduct(bool, PrintOptoStatistics, false, \ 155 "Print New compiler statistics") \ 156 \ 157 diagnostic(bool, PrintOptoAssembly, false, \ 158 "Print New compiler assembly output") \ 159 \ 160 develop_pd(bool, OptoPeephole, \ 161 "Apply peephole optimizations after register allocation") \ 162 \ 163 develop(bool, OptoRemoveUseless, true, \ 164 "Remove useless nodes after parsing") \ 165 \ 166 notproduct(bool, PrintFrameConverterAssembly, false, \ 167 "Print New compiler assembly output for frame converters") \ 168 \ 169 notproduct(bool, PrintParseStatistics, false, \ 170 "Print nodes, transforms and new values made per bytecode parsed")\ 171 \ 172 notproduct(bool, PrintOptoPeephole, false, \ 173 "Print New compiler peephole replacements") \ 174 \ 175 develop(bool, PrintCFGBlockFreq, false, \ 176 "Print CFG block freqencies") \ 177 \ 178 develop(bool, TraceOptoParse, false, \ 179 "Trace bytecode parse and control-flow merge") \ 180 \ 181 product_pd(intx, LoopUnrollLimit, \ 182 "Unroll loop bodies with node count less than this") \ 183 range(0, max_jint / 4) \ 184 \ 185 product_pd(intx, LoopPercentProfileLimit, \ 186 "Unroll loop bodies with % node count of profile limit") \ 187 range(10, 100) \ 188 \ 189 product(intx, LoopMaxUnroll, 16, \ 190 "Maximum number of unrolls for main loop") \ 191 range(0, max_jint) \ 192 \ 193 product_pd(bool, SuperWordLoopUnrollAnalysis, \ 194 "Map number of unrolls for main loop via " \ 195 "Superword Level Parallelism analysis") \ 196 \ 197 notproduct(bool, TraceSuperWordLoopUnrollAnalysis, false, \ 198 "Trace what Superword Level Parallelism analysis applies") \ 199 \ 200 product(intx, LoopUnrollMin, 4, \ 201 "Minimum number of unroll loop bodies before checking progress" \ 202 "of rounds of unroll,optimize,..") \ 203 range(0, max_jint) \ 204 \ 205 develop(intx, UnrollLimitForProfileCheck, 1, \ 206 "Don't use profile_trip_cnt() to restrict unrolling until " \ 207 "unrolling would push the number of unrolled iterations above " \ 208 "UnrollLimitForProfileCheck. A higher value allows more " \ 209 "unrolling. Zero acts as a very large value." ) \ 210 range(0, max_intx) \ 211 \ 212 product(intx, MultiArrayExpandLimit, 6, \ 213 "Maximum number of individual allocations in an inline-expanded " \ 214 "multianewarray instruction") \ 215 range(0, max_jint) \ 216 \ 217 notproduct(bool, TraceProfileTripCount, false, \ 218 "Trace profile loop trip count information") \ 219 \ 220 product(bool, UseCountedLoopSafepoints, false, \ 221 "Force counted loops to keep a safepoint") \ 222 \ 223 product(bool, UseLoopPredicate, true, \ 224 "Generate a predicate to select fast/slow loop versions") \ 225 \ 226 develop(bool, TraceLoopPredicate, false, \ 227 "Trace generation of loop predicates") \ 228 \ 229 develop(bool, TraceLoopOpts, false, \ 230 "Trace executed loop optimizations") \ 231 \ 232 diagnostic(bool, LoopLimitCheck, true, \ 233 "Generate a loop limits check for overflow") \ 234 \ 235 develop(bool, TraceLoopLimitCheck, false, \ 236 "Trace generation of loop limits checks") \ 237 \ 238 diagnostic(bool, RangeLimitCheck, true, \ 239 "Additional overflow checks during range check elimination") \ 240 \ 241 develop(bool, TraceRangeLimitCheck, false, \ 242 "Trace additional overflow checks in RCE") \ 243 \ 244 diagnostic(bool, UnrollLimitCheck, true, \ 245 "Additional overflow checks during loop unroll") \ 246 \ 247 /* OptimizeFill not yet supported on PowerPC. */ \ 248 product(bool, OptimizeFill, true PPC64_ONLY(&& false), \ 249 "convert fill/copy loops into intrinsic") \ 250 \ 251 develop(bool, TraceOptimizeFill, false, \ 252 "print detailed information about fill conversion") \ 253 \ 254 develop(bool, OptoCoalesce, true, \ 255 "Use Conservative Copy Coalescing in the Register Allocator") \ 256 \ 257 develop(bool, UseUniqueSubclasses, true, \ 258 "Narrow an abstract reference to the unique concrete subclass") \ 259 \ 260 develop(bool, UseExactTypes, true, \ 261 "Use exact types to eliminate array store checks and v-calls") \ 262 \ 263 product(intx, TrackedInitializationLimit, 50, \ 264 "When initializing fields, track up to this many words") \ 265 range(0, 65535) \ 266 \ 267 product(bool, ReduceFieldZeroing, true, \ 268 "When initializing fields, try to avoid needless zeroing") \ 269 \ 270 product(bool, ReduceInitialCardMarks, true, \ 271 "When initializing fields, try to avoid needless card marks") \ 272 \ 273 product(bool, ReduceBulkZeroing, true, \ 274 "When bulk-initializing, try to avoid needless zeroing") \ 275 \ 276 product(bool, UseFPUForSpilling, false, \ 277 "Spill integer registers to FPU instead of stack when possible") \ 278 \ 279 develop_pd(intx, RegisterCostAreaRatio, \ 280 "Spill selection in reg allocator: scale area by (X/64K) before " \ 281 "adding cost") \ 282 \ 283 develop_pd(bool, UseCISCSpill, \ 284 "Use ADLC supplied cisc instructions during allocation") \ 285 \ 286 notproduct(bool, VerifyGraphEdges , false, \ 287 "Verify Bi-directional Edges") \ 288 \ 289 notproduct(bool, VerifyDUIterators, true, \ 290 "Verify the safety of all iterations of Bi-directional Edges") \ 291 \ 292 notproduct(bool, VerifyHashTableKeys, true, \ 293 "Verify the immutability of keys in the VN hash tables") \ 294 \ 295 notproduct(bool, VerifyRegisterAllocator , false, \ 296 "Verify Register Allocator") \ 297 \ 298 develop_pd(intx, FLOATPRESSURE, \ 299 "Number of float LRG's that constitute high register pressure") \ 300 range(0, max_jint) \ 301 \ 302 develop_pd(intx, INTPRESSURE, \ 303 "Number of integer LRG's that constitute high register pressure") \ 304 range(0, max_jint) \ 305 \ 306 notproduct(bool, TraceOptoPipelining, false, \ 307 "Trace pipelining information") \ 308 \ 309 notproduct(bool, TraceOptoOutput, false, \ 310 "Trace pipelining information") \ 311 \ 312 product_pd(bool, OptoScheduling, \ 313 "Instruction Scheduling after register allocation") \ 314 \ 315 product_pd(bool, OptoRegScheduling, \ 316 "Instruction Scheduling before register allocation for pressure") \ 317 \ 318 product(bool, PartialPeelLoop, true, \ 319 "Partial peel (rotate) loops") \ 320 \ 321 product(intx, PartialPeelNewPhiDelta, 0, \ 322 "Additional phis that can be created by partial peeling") \ 323 range(0, max_jint) \ 324 \ 325 notproduct(bool, TracePartialPeeling, false, \ 326 "Trace partial peeling (loop rotation) information") \ 327 \ 328 product(bool, PartialPeelAtUnsignedTests, true, \ 329 "Partial peel at unsigned tests if no signed test exists") \ 330 \ 331 product(bool, ReassociateInvariants, true, \ 332 "Enable reassociation of expressions with loop invariants.") \ 333 \ 334 product(bool, LoopUnswitching, true, \ 335 "Enable loop unswitching (a form of invariant test hoisting)") \ 336 \ 337 notproduct(bool, TraceLoopUnswitching, false, \ 338 "Trace loop unswitching") \ 339 \ 340 product(bool, AllowVectorizeOnDemand, true, \ 341 "Globally supress vectorization set in VectorizeMethod") \ 342 \ 343 product(bool, UseSuperWord, true, \ 344 "Transform scalar operations into superword operations") \ 345 \ 346 develop(bool, SuperWordRTDepCheck, false, \ 347 "Enable runtime dependency checks.") \ 348 \ 349 product(bool, SuperWordReductions, true, \ 350 "Enable reductions support in superword.") \ 351 \ 352 product(bool, UseCMoveUnconditionally, false, \ 353 "Use CMove (scalar and vector) ignoring profitability test.") \ 354 \ 355 product(bool, DoReserveCopyInSuperWord, true, \ 356 "Create reserve copy of graph in SuperWord.") \ 357 \ 358 notproduct(bool, TraceSuperWord, false, \ 359 "Trace superword transforms") \ 360 \ 361 notproduct(bool, TraceNewVectors, false, \ 362 "Trace creation of Vector nodes") \ 363 \ 364 product_pd(bool, OptoBundling, \ 365 "Generate nops to fill i-cache lines") \ 366 \ 367 product_pd(intx, ConditionalMoveLimit, \ 368 "Limit of ops to make speculative when using CMOVE") \ 369 range(0, max_jint) \ 370 \ 371 /* Set BranchOnRegister == false. See 4965987. */ \ 372 product(bool, BranchOnRegister, false, \ 373 "Use Sparc V9 branch-on-register opcodes") \ 374 \ 375 develop(bool, SparcV9RegsHiBitsZero, true, \ 376 "Assume Sparc V9 I&L registers on V8+ systems are zero-extended") \ 377 \ 378 product(bool, UseRDPCForConstantTableBase, false, \ 379 "Use Sparc RDPC instruction for the constant table base.") \ 380 \ 381 notproduct(bool, PrintIdealGraph, false, \ 382 "Print ideal graph to XML file / network interface. " \ 383 "By default attempts to connect to the visualizer on a socket.") \ 384 \ 385 notproduct(intx, PrintIdealGraphLevel, 0, \ 386 "Level of detail of the ideal graph printout. " \ 387 "System-wide value, 0=nothing is printed, 4=all details printed. "\ 388 "Level of detail of printouts can be set on a per-method level " \ 389 "as well by using CompileCommand=option.") \ 390 range(0, 4) \ 391 \ 392 notproduct(intx, PrintIdealGraphPort, 4444, \ 393 "Ideal graph printer to network port") \ 394 range(0, SHRT_MAX) \ 395 \ 396 notproduct(ccstr, PrintIdealGraphAddress, "127.0.0.1", \ 397 "IP address to connect to visualizer") \ 398 \ 399 notproduct(ccstr, PrintIdealGraphFile, NULL, \ 400 "File to dump ideal graph to. If set overrides the " \ 401 "use of the network") \ 402 \ 403 product(bool, UseBimorphicInlining, true, \ 404 "Profiling based inlining for two receivers") \ 405 \ 406 product(bool, UseOnlyInlinedBimorphic, true, \ 407 "Don't use BimorphicInlining if can't inline a second method") \ 408 \ 409 product(bool, InsertMemBarAfterArraycopy, true, \ 410 "Insert memory barrier after arraycopy call") \ 411 \ 412 develop(bool, SubsumeLoads, true, \ 413 "Attempt to compile while subsuming loads into machine " \ 414 "instructions.") \ 415 \ 416 develop(bool, StressRecompilation, false, \ 417 "Recompile each compiled method without subsuming loads " \ 418 "or escape analysis.") \ 419 \ 420 develop(intx, ImplicitNullCheckThreshold, 3, \ 421 "Don't do implicit null checks if NPE's in a method exceeds " \ 422 "limit") \ 423 range(0, max_jint) \ 424 \ 425 product(intx, LoopOptsCount, 43, \ 426 "Set level of loop optimization for tier 1 compiles") \ 427 range(5, 43) \ 428 \ 429 /* controls for heat-based inlining */ \ 430 \ 431 develop(intx, NodeCountInliningCutoff, 18000, \ 432 "If parser node generation exceeds limit stop inlining") \ 433 range(0, max_jint) \ 434 \ 435 develop(intx, NodeCountInliningStep, 1000, \ 436 "Target size of warm calls inlined between optimization passes") \ 437 range(0, max_jint) \ 438 \ 439 develop(bool, InlineWarmCalls, false, \ 440 "Use a heat-based priority queue to govern inlining") \ 441 \ 442 develop(intx, HotCallCountThreshold, 999999, \ 443 "large numbers of calls (per method invocation) force hotness") \ 444 range(0, max_intx) \ 445 \ 446 develop(intx, HotCallProfitThreshold, 999999, \ 447 "highly profitable inlining opportunities force hotness") \ 448 range(0, max_intx) \ 449 \ 450 develop(intx, HotCallTrivialWork, -1, \ 451 "trivial execution time (no larger than this) forces hotness") \ 452 range(-1, max_intx) \ 453 \ 454 develop(intx, HotCallTrivialSize, -1, \ 455 "trivial methods (no larger than this) force calls to be hot") \ 456 range(-1, max_intx) \ 457 \ 458 develop(intx, WarmCallMinCount, -1, \ 459 "number of calls (per method invocation) to enable inlining") \ 460 range(-1, max_intx) \ 461 \ 462 develop(intx, WarmCallMinProfit, -1, \ 463 "number of calls (per method invocation) to enable inlining") \ 464 range(-1, max_intx) \ 465 \ 466 develop(intx, WarmCallMaxWork, 999999, \ 467 "execution time of the largest inlinable method") \ 468 range(0, max_intx) \ 469 \ 470 develop(intx, WarmCallMaxSize, 999999, \ 471 "size of the largest inlinable method") \ 472 range(0, max_intx) \ 473 \ 474 product(intx, MaxNodeLimit, 80000, \ 475 "Maximum number of nodes") \ 476 range(1000, max_jint / 3) \ 477 \ 478 product(intx, NodeLimitFudgeFactor, 2000, \ 479 "Fudge Factor for certain optimizations") \ 480 constraint(NodeLimitFudgeFactorConstraintFunc, AfterErgo) \ 481 \ 482 product(bool, UseJumpTables, true, \ 483 "Use JumpTables instead of a binary search tree for switches") \ 484 \ 485 product(bool, UseDivMod, true, \ 486 "Use combined DivMod instruction if available") \ 487 \ 488 product_pd(intx, MinJumpTableSize, \ 489 "Minimum number of targets in a generated jump table") \ 490 range(0, max_intx) \ 491 \ 492 product(intx, MaxJumpTableSize, 65000, \ 493 "Maximum number of targets in a generated jump table") \ 494 range(0, max_intx) \ 495 \ 496 product(intx, MaxJumpTableSparseness, 5, \ 497 "Maximum sparseness for jumptables") \ 498 range(0, max_intx / 4) \ 499 \ 500 product(bool, EliminateLocks, true, \ 501 "Coarsen locks when possible") \ 502 \ 503 product(bool, EliminateNestedLocks, true, \ 504 "Eliminate nested locks of the same object when possible") \ 505 \ 506 notproduct(bool, PrintLockStatistics, false, \ 507 "Print precise statistics on the dynamic lock usage") \ 508 \ 509 diagnostic(bool, PrintPreciseBiasedLockingStatistics, false, \ 510 "Print per-lock-site statistics of biased locking in JVM") \ 511 \ 512 diagnostic(bool, PrintPreciseRTMLockingStatistics, false, \ 513 "Print per-lock-site statistics of rtm locking in JVM") \ 514 \ 515 notproduct(bool, PrintEliminateLocks, false, \ 516 "Print out when locks are eliminated") \ 517 \ 518 product(bool, EliminateAutoBox, true, \ 519 "Control optimizations for autobox elimination") \ 520 \ 521 diagnostic(bool, UseImplicitStableValues, true, \ 522 "Mark well-known stable fields as such (e.g. String.value)") \ 523 \ 524 product(intx, AutoBoxCacheMax, 128, \ 525 "Sets max value cached by the java.lang.Integer autobox cache") \ 526 range(0, max_jint) \ 527 \ 528 experimental(bool, AggressiveUnboxing, false, \ 529 "Control optimizations for aggressive boxing elimination") \ 530 \ 531 develop(bool, TracePostallocExpand, false, "Trace expanding nodes after" \ 532 " register allocation.") \ 533 \ 534 product(bool, DoEscapeAnalysis, true, \ 535 "Perform escape analysis") \ 536 \ 537 product(double, EscapeAnalysisTimeout, 20. DEBUG_ONLY(+40.), \ 538 "Abort EA when it reaches time limit (in sec)") \ 539 range(0, DBL_MAX) \ 540 \ 541 develop(bool, ExitEscapeAnalysisOnTimeout, true, \ 542 "Exit or throw assert in EA when it reaches time limit") \ 543 \ 544 notproduct(bool, PrintEscapeAnalysis, false, \ 545 "Print the results of escape analysis") \ 546 \ 547 product(bool, EliminateAllocations, true, \ 548 "Use escape analysis to eliminate allocations") \ 549 \ 550 notproduct(bool, PrintEliminateAllocations, false, \ 551 "Print out when allocations are eliminated") \ 552 \ 553 product(intx, EliminateAllocationArraySizeLimit, 64, \ 554 "Array size (number of elements) limit for scalar replacement") \ 555 range(0, max_jint) \ 556 \ 557 product(bool, OptimizePtrCompare, true, \ 558 "Use escape analysis to optimize pointers compare") \ 559 \ 560 notproduct(bool, PrintOptimizePtrCompare, false, \ 561 "Print information about optimized pointers compare") \ 562 \ 563 notproduct(bool, VerifyConnectionGraph , true, \ 564 "Verify Connection Graph construction in Escape Analysis") \ 565 \ 566 product(bool, UseOptoBiasInlining, true, \ 567 "Generate biased locking code in C2 ideal graph") \ 568 \ 569 product(bool, OptimizeStringConcat, true, \ 570 "Optimize the construction of Strings by StringBuilder") \ 571 \ 572 notproduct(bool, PrintOptimizeStringConcat, false, \ 573 "Print information about transformations performed on Strings") \ 574 \ 575 product(intx, ValueSearchLimit, 1000, \ 576 "Recursion limit in PhaseMacroExpand::value_from_mem_phi") \ 577 range(0, max_jint) \ 578 \ 579 product(intx, MaxLabelRootDepth, 1100, \ 580 "Maximum times call Label_Root to prevent stack overflow") \ 581 range(100, max_jint) \ 582 \ 583 diagnostic(intx, DominatorSearchLimit, 1000, \ 584 "Iterations limit in Node::dominates") \ 585 range(0, max_jint) \ 586 \ 587 product(bool, BlockLayoutByFrequency, true, \ 588 "Use edge frequencies to drive block ordering") \ 589 \ 590 product(intx, BlockLayoutMinDiamondPercentage, 20, \ 591 "Miniumum %% of a successor (predecessor) for which block " \ 592 "layout a will allow a fork (join) in a single chain") \ 593 range(0, 100) \ 594 \ 595 product(bool, BlockLayoutRotateLoops, true, \ 596 "Allow back branches to be fall throughs in the block layour") \ 597 \ 598 develop(bool, InlineReflectionGetCallerClass, true, \ 599 "inline sun.reflect.Reflection.getCallerClass(), known to be " \ 600 "part of base library DLL") \ 601 \ 602 develop(bool, InlineObjectCopy, true, \ 603 "inline Object.clone and Arrays.copyOf[Range] intrinsics") \ 604 \ 605 develop(bool, SpecialStringCompareTo, true, \ 606 "special version of string compareTo") \ 607 \ 608 develop(bool, SpecialStringIndexOf, true, \ 609 "special version of string indexOf") \ 610 \ 611 develop(bool, SpecialStringEquals, true, \ 612 "special version of string equals") \ 613 \ 614 develop(bool, SpecialArraysEquals, true, \ 615 "special version of Arrays.equals(char[],char[])") \ 616 \ 617 product(bool, SpecialEncodeISOArray, true, \ 618 "special version of ISO_8859_1$Encoder.encodeISOArray") \ 619 \ 620 develop(bool, BailoutToInterpreterForThrows, false, \ 621 "Compiled methods which throws/catches exceptions will be " \ 622 "deopt and intp.") \ 623 \ 624 develop(bool, ConvertCmpD2CmpF, true, \ 625 "Convert cmpD to cmpF when one input is constant in float range") \ 626 \ 627 develop(bool, ConvertFloat2IntClipping, true, \ 628 "Convert float2int clipping idiom to integer clipping") \ 629 \ 630 develop(bool, Use24BitFPMode, true, \ 631 "Set 24-bit FPU mode on a per-compile basis ") \ 632 \ 633 develop(bool, Use24BitFP, true, \ 634 "use FP instructions that produce 24-bit precise results") \ 635 \ 636 develop(bool, MonomorphicArrayCheck, true, \ 637 "Uncommon-trap array store checks that require full type check") \ 638 \ 639 notproduct(bool, TracePhaseCCP, false, \ 640 "Print progress during Conditional Constant Propagation") \ 641 \ 642 develop(bool, PrintDominators, false, \ 643 "Print out dominator trees for GVN") \ 644 \ 645 diagnostic(bool, TraceSpilling, false, \ 646 "Trace spilling") \ 647 \ 648 diagnostic(bool, TraceTypeProfile, false, \ 649 "Trace type profile") \ 650 \ 651 develop(bool, PoisonOSREntry, true, \ 652 "Detect abnormal calls to OSR code") \ 653 \ 654 develop(bool, SoftMatchFailure, trueInProduct, \ 655 "If the DFA fails to match a node, print a message and bail out") \ 656 \ 657 develop(bool, InlineAccessors, true, \ 658 "inline accessor methods (get/set)") \ 659 \ 660 product(intx, TypeProfileMajorReceiverPercent, 90, \ 661 "% of major receiver type to all profiled receivers") \ 662 range(0, 100) \ 663 \ 664 diagnostic(bool, PrintIntrinsics, false, \ 665 "prints attempted and successful inlining of intrinsics") \ 666 \ 667 develop(bool, StressReflectiveCode, false, \ 668 "Use inexact types at allocations, etc., to test reflection") \ 669 \ 670 diagnostic(bool, DebugInlinedCalls, true, \ 671 "If false, restricts profiled locations to the root method only") \ 672 \ 673 notproduct(bool, VerifyLoopOptimizations, false, \ 674 "verify major loop optimizations") \ 675 \ 676 diagnostic(bool, ProfileDynamicTypes, true, \ 677 "do extra type profiling and use it more aggressively") \ 678 \ 679 develop(bool, TraceIterativeGVN, false, \ 680 "Print progress during Iterative Global Value Numbering") \ 681 \ 682 develop(bool, VerifyIterativeGVN, false, \ 683 "Verify Def-Use modifications during sparse Iterative Global " \ 684 "Value Numbering") \ 685 \ 686 notproduct(bool, TraceCISCSpill, false, \ 687 "Trace allocators use of cisc spillable instructions") \ 688 \ 689 product(bool, SplitIfBlocks, true, \ 690 "Clone compares and control flow through merge points to fold " \ 691 "some branches") \ 692 \ 693 develop(intx, FreqCountInvocations, 1, \ 694 "Scaling factor for branch frequencies (deprecated)") \ 695 range(1, max_intx) \ 696 \ 697 product(intx, AliasLevel, 3, \ 698 "0 for no aliasing, 1 for oop/field/static/array split, " \ 699 "2 for class split, 3 for unique instances") \ 700 range(0, 3) \ 701 constraint(AliasLevelConstraintFunc,AfterErgo) \ 702 \ 703 develop(bool, VerifyAliases, false, \ 704 "perform extra checks on the results of alias analysis") \ 705 \ 706 product(bool, IncrementalInline, true, \ 707 "do post parse inlining") \ 708 \ 709 develop(bool, AlwaysIncrementalInline, false, \ 710 "do all inlining incrementally") \ 711 \ 712 product(intx, LiveNodeCountInliningCutoff, 40000, \ 713 "max number of live nodes in a method") \ 714 range(0, max_juint / 8) \ 715 \ 716 diagnostic(bool, OptimizeExpensiveOps, true, \ 717 "Find best control for expensive operations") \ 718 \ 719 product(bool, UseMathExactIntrinsics, true, \ 720 "Enables intrinsification of various java.lang.Math functions") \ 721 \ 722 product(bool, UseMultiplyToLenIntrinsic, false, \ 723 "Enables intrinsification of BigInteger.multiplyToLen()") \ 724 \ 725 product(bool, UseSquareToLenIntrinsic, false, \ 726 "Enables intrinsification of BigInteger.squareToLen()") \ 727 \ 728 product(bool, UseMulAddIntrinsic, false, \ 729 "Enables intrinsification of BigInteger.mulAdd()") \ 730 \ 731 product(bool, UseMontgomeryMultiplyIntrinsic, false, \ 732 "Enables intrinsification of BigInteger.montgomeryMultiply()") \ 733 \ 734 product(bool, UseMontgomerySquareIntrinsic, false, \ 735 "Enables intrinsification of BigInteger.montgomerySquare()") \ 736 \ 737 product(bool, UseTypeSpeculation, true, \ 738 "Speculatively propagate types from profiles") \ 739 \ 740 diagnostic(bool, UseInlineDepthForSpeculativeTypes, true, \ 741 "Carry inline depth of profile point with speculative type " \ 742 "and give priority to profiling from lower inline depth") \ 743 \ 744 product_pd(bool, TrapBasedRangeChecks, \ 745 "Generate code for range checks that uses a cmp and trap " \ 746 "instruction raising SIGTRAP. Used on PPC64.") \ 747 \ 748 product(intx, ArrayCopyLoadStoreMaxElem, 8, \ 749 "Maximum number of arraycopy elements inlined as a sequence of" \ 750 "loads/stores") \ 751 range(0, max_intx) \ 752 \ 753 develop(bool, StressArrayCopyMacroNode, false, \ 754 "Perform ArrayCopy load/store replacement during IGVN only") \ 755 \ 756 develop(bool, RenumberLiveNodes, true, \ 757 "Renumber live nodes") \ 758 759 C2_FLAGS(DECLARE_DEVELOPER_FLAG, \ 760 DECLARE_PD_DEVELOPER_FLAG, \ 761 DECLARE_PRODUCT_FLAG, \ 762 DECLARE_PD_PRODUCT_FLAG, \ 763 DECLARE_DIAGNOSTIC_FLAG, \ 764 DECLARE_EXPERIMENTAL_FLAG, \ 765 DECLARE_NOTPRODUCT_FLAG, \ 766 IGNORE_RANGE, \ 767 IGNORE_CONSTRAINT) 768 769 #endif // SHARE_VM_OPTO_C2_GLOBALS_HPP