src/share/vm/c1/c1_globals.hpp

changeset 435
a61af66fc99e
child 777
37f87013dfd8
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/share/vm/c1/c1_globals.hpp	Sat Dec 01 00:00:00 2007 +0000
     1.3 @@ -0,0 +1,332 @@
     1.4 +/*
     1.5 + * Copyright 2000-2007 Sun Microsystems, Inc.  All Rights Reserved.
     1.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.7 + *
     1.8 + * This code is free software; you can redistribute it and/or modify it
     1.9 + * under the terms of the GNU General Public License version 2 only, as
    1.10 + * published by the Free Software Foundation.
    1.11 + *
    1.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
    1.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1.14 + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    1.15 + * version 2 for more details (a copy is included in the LICENSE file that
    1.16 + * accompanied this code).
    1.17 + *
    1.18 + * You should have received a copy of the GNU General Public License version
    1.19 + * 2 along with this work; if not, write to the Free Software Foundation,
    1.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    1.21 + *
    1.22 + * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
    1.23 + * CA 95054 USA or visit www.sun.com if you need additional information or
    1.24 + * have any questions.
    1.25 + *
    1.26 + */
    1.27 +
    1.28 +//
    1.29 +// Defines all global flags used by the client compiler.
    1.30 +//
    1.31 +#ifndef TIERED
    1.32 +  #define NOT_TIERED(x) x
    1.33 +#else
    1.34 +  #define NOT_TIERED(x)
    1.35 +#endif
    1.36 +
    1.37 +#define C1_FLAGS(develop, develop_pd, product, product_pd, notproduct)      \
    1.38 +                                                                            \
    1.39 +  /* Printing */                                                            \
    1.40 +  notproduct(bool, PrintC1Statistics, false,                                \
    1.41 +          "Print Compiler1 statistics" )                                    \
    1.42 +                                                                            \
    1.43 +  notproduct(bool, PrintInitialBlockList, false,                            \
    1.44 +          "Print block list of BlockListBuilder")                           \
    1.45 +                                                                            \
    1.46 +  notproduct(bool, PrintCFG, false,                                         \
    1.47 +          "Print control flow graph after each change")                     \
    1.48 +                                                                            \
    1.49 +  notproduct(bool, PrintCFG0, false,                                        \
    1.50 +          "Print control flow graph after construction")                    \
    1.51 +                                                                            \
    1.52 +  notproduct(bool, PrintCFG1, false,                                        \
    1.53 +          "Print control flow graph after optimizations")                   \
    1.54 +                                                                            \
    1.55 +  notproduct(bool, PrintCFG2, false,                                        \
    1.56 +          "Print control flow graph before code generation")                \
    1.57 +                                                                            \
    1.58 +  notproduct(bool, PrintIRDuringConstruction, false,                        \
    1.59 +          "Print IR as it's being constructed (helpful for debugging frontend)")\
    1.60 +                                                                            \
    1.61 +  notproduct(bool, PrintPhiFunctions, false,                                   \
    1.62 +          "Print phi functions when they are created and simplified")       \
    1.63 +                                                                            \
    1.64 +  notproduct(bool, PrintIR, false,                                          \
    1.65 +          "Print full intermediate representation after each change")       \
    1.66 +                                                                            \
    1.67 +  notproduct(bool, PrintIR0, false,                                         \
    1.68 +          "Print full intermediate representation after construction")      \
    1.69 +                                                                            \
    1.70 +  notproduct(bool, PrintIR1, false,                                         \
    1.71 +          "Print full intermediate representation after optimizations")     \
    1.72 +                                                                            \
    1.73 +  notproduct(bool, PrintIR2, false,                                         \
    1.74 +          "Print full intermediate representation before code generation")  \
    1.75 +                                                                            \
    1.76 +  notproduct(bool, PrintSimpleStubs, false,                                 \
    1.77 +          "Print SimpleStubs")                                              \
    1.78 +                                                                            \
    1.79 +  /* C1 optimizations */                                                    \
    1.80 +                                                                            \
    1.81 +  develop(bool, UseC1Optimizations, true,                                   \
    1.82 +          "Turn on C1 optimizations")                                       \
    1.83 +                                                                            \
    1.84 +  develop(bool, SelectivePhiFunctions, true,                                \
    1.85 +          "create phi functions at loop headers only when necessary")       \
    1.86 +                                                                            \
    1.87 +  develop(bool, DoCEE, true,                                                \
    1.88 +          "Do Conditional Expression Elimination to simplify CFG")          \
    1.89 +                                                                            \
    1.90 +  develop(bool, PrintCEE, false,                                            \
    1.91 +          "Print Conditional Expression Elimination")                       \
    1.92 +                                                                            \
    1.93 +  develop(bool, UseLocalValueNumbering, true,                               \
    1.94 +          "Use Local Value Numbering (embedded in GraphBuilder)")           \
    1.95 +                                                                            \
    1.96 +  develop(bool, UseGlobalValueNumbering, true,                              \
    1.97 +          "Use Global Value Numbering (separate phase)")                    \
    1.98 +                                                                            \
    1.99 +  develop(bool, PrintValueNumbering, false,                                 \
   1.100 +          "Print Value Numbering")                                          \
   1.101 +                                                                            \
   1.102 +  product(intx, ValueMapInitialSize, 11,                                    \
   1.103 +          "Initial size of a value map")                                    \
   1.104 +                                                                            \
   1.105 +  product(intx, ValueMapMaxLoopSize, 8,                                     \
   1.106 +          "maximum size of a loop optimized by global value numbering")     \
   1.107 +                                                                            \
   1.108 +  develop(bool, EliminateBlocks, true,                                      \
   1.109 +          "Eliminate unneccessary basic blocks")                            \
   1.110 +                                                                            \
   1.111 +  develop(bool, PrintBlockElimination, false,                               \
   1.112 +          "Print basic block elimination")                                  \
   1.113 +                                                                            \
   1.114 +  develop(bool, EliminateNullChecks, true,                                  \
   1.115 +          "Eliminate unneccessary null checks")                             \
   1.116 +                                                                            \
   1.117 +  develop(bool, PrintNullCheckElimination, false,                           \
   1.118 +          "Print null check elimination")                                   \
   1.119 +                                                                            \
   1.120 +  develop(bool, EliminateFieldAccess, true,                                 \
   1.121 +          "Optimize field loads and stores")                                \
   1.122 +                                                                            \
   1.123 +  develop(bool, InlineMethodsWithExceptionHandlers, true,                   \
   1.124 +          "Inline methods containing exception handlers "                   \
   1.125 +          "(NOTE: does not work with current backend)")                     \
   1.126 +                                                                            \
   1.127 +  develop(bool, InlineSynchronizedMethods, true,                            \
   1.128 +          "Inline synchronized methods")                                    \
   1.129 +                                                                            \
   1.130 +  develop(bool, InlineNIOCheckIndex, true,                                  \
   1.131 +          "Intrinsify java.nio.Buffer.checkIndex")                          \
   1.132 +                                                                            \
   1.133 +  develop(bool, CanonicalizeNodes, true,                                    \
   1.134 +          "Canonicalize graph nodes")                                       \
   1.135 +                                                                            \
   1.136 +  develop(bool, CanonicalizeExperimental, false,                            \
   1.137 +          "Canonicalize graph nodes, experimental code")                    \
   1.138 +                                                                            \
   1.139 +  develop(bool, PrintCanonicalization, false,                               \
   1.140 +          "Print graph node canonicalization")                              \
   1.141 +                                                                            \
   1.142 +  develop(bool, UseTableRanges, true,                                       \
   1.143 +          "Faster versions of lookup table using ranges")                   \
   1.144 +                                                                            \
   1.145 +  develop(bool, UseFastExceptionHandling, true,                             \
   1.146 +          "Faster handling of exceptions")                                  \
   1.147 +                                                                            \
   1.148 +  develop_pd(bool, RoundFPResults,                                          \
   1.149 +          "Indicates whether rounding is needed for floating point results")\
   1.150 +                                                                            \
   1.151 +  develop(intx, NestedInliningSizeRatio, 90,                                \
   1.152 +          "Percentage of prev. allowed inline size in recursive inlining")  \
   1.153 +                                                                            \
   1.154 +  notproduct(bool, PrintIRWithLIR, false,                                   \
   1.155 +          "Print IR instructions with generated LIR")                       \
   1.156 +                                                                            \
   1.157 +  notproduct(bool, PrintLIRWithAssembly, false,                             \
   1.158 +          "Show LIR instruction with generated assembly")                   \
   1.159 +                                                                            \
   1.160 +  develop(bool, CommentedAssembly, trueInDebug,                             \
   1.161 +          "Show extra info in PrintNMethods output")                        \
   1.162 +                                                                            \
   1.163 +  develop(bool, LIRTracePeephole, false,                                    \
   1.164 +          "Trace peephole optimizer")                                       \
   1.165 +                                                                            \
   1.166 +  develop(bool, LIRTraceExecution, false,                                   \
   1.167 +          "add LIR code which logs the execution of blocks")                \
   1.168 +                                                                            \
   1.169 +  product_pd(bool, LIRFillDelaySlots,                                       \
   1.170 +             "fill delays on on SPARC with LIR")                            \
   1.171 +                                                                            \
   1.172 +  develop_pd(bool, CSEArrayLength,                                          \
   1.173 +          "Create separate nodes for length in array accesses")             \
   1.174 +                                                                            \
   1.175 +  develop_pd(bool, TwoOperandLIRForm,                                       \
   1.176 +          "true if LIR requires src1 and dst to match in binary LIR ops")   \
   1.177 +                                                                            \
   1.178 +  develop(intx, TraceLinearScanLevel, 0,                                    \
   1.179 +          "Debug levels for the linear scan allocator")                     \
   1.180 +                                                                            \
   1.181 +  develop(bool, StressLinearScan, false,                                    \
   1.182 +          "scramble block order used by LinearScan (stress test)")          \
   1.183 +                                                                            \
   1.184 +  product(bool, TimeLinearScan, false,                                      \
   1.185 +          "detailed timing of LinearScan phases")                           \
   1.186 +                                                                            \
   1.187 +  develop(bool, TimeEachLinearScan, false,                                  \
   1.188 +          "print detailed timing of each LinearScan run")                   \
   1.189 +                                                                            \
   1.190 +  develop(bool, CountLinearScan, false,                                     \
   1.191 +          "collect statistic counters during LinearScan")                   \
   1.192 +                                                                            \
   1.193 +  /* C1 variable */                                                         \
   1.194 +                                                                            \
   1.195 +  develop(bool, C1Breakpoint, false,                                        \
   1.196 +          "Sets a breakpoint at entry of each compiled method")             \
   1.197 +                                                                            \
   1.198 +  develop(bool, ImplicitDiv0Checks, true,                                   \
   1.199 +          "Use implicit division by zero checks")                           \
   1.200 +                                                                            \
   1.201 +  develop(bool, PinAllInstructions, false,                                  \
   1.202 +          "All instructions are pinned")                                    \
   1.203 +                                                                            \
   1.204 +  develop(bool, ValueStackPinStackAll, true,                                \
   1.205 +          "Pinning in ValueStack pin everything")                           \
   1.206 +                                                                            \
   1.207 +  develop(bool, UseFastNewInstance, true,                                   \
   1.208 +          "Use fast inlined instance allocation")                           \
   1.209 +                                                                            \
   1.210 +  develop(bool, UseFastNewTypeArray, true,                                  \
   1.211 +          "Use fast inlined type array allocation")                         \
   1.212 +                                                                            \
   1.213 +  develop(bool, UseFastNewObjectArray, true,                                \
   1.214 +          "Use fast inlined object array allocation")                       \
   1.215 +                                                                            \
   1.216 +  develop(bool, UseFastLocking, true,                                       \
   1.217 +          "Use fast inlined locking code")                                  \
   1.218 +                                                                            \
   1.219 +  product(bool, FastTLABRefill, true,                                       \
   1.220 +          "Use fast TLAB refill code")                                      \
   1.221 +                                                                            \
   1.222 +  develop(bool, UseSlowPath, false,                                         \
   1.223 +          "For debugging: test slow cases by always using them")            \
   1.224 +                                                                            \
   1.225 +  develop(bool, GenerateArrayStoreCheck, true,                              \
   1.226 +          "Generates code for array store checks")                          \
   1.227 +                                                                            \
   1.228 +  develop(bool, DeoptC1, true,                                              \
   1.229 +          "Use deoptimization in C1")                                       \
   1.230 +                                                                            \
   1.231 +  develop(bool, DeoptOnAsyncException, true,                                \
   1.232 +          "Deoptimize upon Thread.stop(); improves precision of IR")        \
   1.233 +                                                                            \
   1.234 +  develop(bool, PrintBailouts, false,                                       \
   1.235 +          "Print bailout and its reason")                                   \
   1.236 +                                                                            \
   1.237 +  develop(bool, TracePatching, false,                                       \
   1.238 +         "Trace patching of field access on uninitialized classes")         \
   1.239 +                                                                            \
   1.240 +  develop(bool, PatchALot, false,                                           \
   1.241 +          "Marks all fields as having unloaded classes")                    \
   1.242 +                                                                            \
   1.243 +  develop(bool, PrintNotLoaded, false,                                      \
   1.244 +          "Prints where classes are not loaded during code generation")     \
   1.245 +                                                                            \
   1.246 +  notproduct(bool, VerifyOopMaps, false,                                    \
   1.247 +          "Adds oopmap verification code to the generated code")            \
   1.248 +                                                                            \
   1.249 +  develop(bool, PrintLIR, false,                                            \
   1.250 +          "print low-level IR")                                             \
   1.251 +                                                                            \
   1.252 +  develop(bool, BailoutAfterHIR, false,                                     \
   1.253 +          "bailout of compilation after building of HIR")                   \
   1.254 +                                                                            \
   1.255 +  develop(bool, BailoutAfterLIR, false,                                     \
   1.256 +          "bailout of compilation after building of LIR")                   \
   1.257 +                                                                            \
   1.258 +  develop(bool, BailoutOnExceptionHandlers, false,                          \
   1.259 +          "bailout of compilation for methods with exception handlers")     \
   1.260 +                                                                            \
   1.261 +  develop(bool, AlwaysEmitDebugInfo, false,                                 \
   1.262 +          "always emit debug info")                                         \
   1.263 +                                                                            \
   1.264 +  develop(bool, InstallMethods, true,                                       \
   1.265 +          "Install methods at the end of successful compilations")          \
   1.266 +                                                                            \
   1.267 +  product(intx, CompilationRepeat, 0,                                       \
   1.268 +          "Number of times to recompile method before returning result")    \
   1.269 +                                                                            \
   1.270 +  develop(intx, NMethodSizeLimit, (32*K)*wordSize,                          \
   1.271 +          "Maximum size of a compiled method.")                             \
   1.272 +                                                                            \
   1.273 +  develop(bool, TraceFPUStack, false,                                       \
   1.274 +          "Trace emulation of the FPU stack (intel only)")                  \
   1.275 +                                                                            \
   1.276 +  develop(bool, TraceFPURegisterUsage, false,                               \
   1.277 +          "Trace usage of FPU registers at start of blocks (intel only)")   \
   1.278 +                                                                            \
   1.279 +  develop(bool, OptimizeUnsafes, true,                                      \
   1.280 +          "Optimize raw unsafe ops")                                        \
   1.281 +                                                                            \
   1.282 +  develop(bool, PrintUnsafeOptimization, false,                             \
   1.283 +          "Print optimization of raw unsafe ops")                           \
   1.284 +                                                                            \
   1.285 +  develop(intx, InstructionCountCutoff, 37000,                              \
   1.286 +          "If GraphBuilder adds this many instructions, bails out")         \
   1.287 +                                                                            \
   1.288 +  product_pd(intx, SafepointPollOffset,                                     \
   1.289 +          "Offset added to polling address (Intel only)")                   \
   1.290 +                                                                            \
   1.291 +  product(bool, UseNewFeature1, false,                                      \
   1.292 +          "Enable new feature for testing.  This is a dummy flag.")         \
   1.293 +                                                                            \
   1.294 +  product(bool, UseNewFeature2, false,                                      \
   1.295 +          "Enable new feature for testing.  This is a dummy flag.")         \
   1.296 +                                                                            \
   1.297 +  product(bool, UseNewFeature3, false,                                      \
   1.298 +          "Enable new feature for testing.  This is a dummy flag.")         \
   1.299 +                                                                            \
   1.300 +  product(bool, UseNewFeature4, false,                                      \
   1.301 +          "Enable new feature for testing.  This is a dummy flag.")         \
   1.302 +                                                                            \
   1.303 +  develop(bool, ComputeExactFPURegisterUsage, true,                         \
   1.304 +          "Compute additional live set for fpu registers to simplify fpu stack merge (Intel only)") \
   1.305 +                                                                            \
   1.306 +  product(bool, Tier1ProfileCalls, true,                                    \
   1.307 +          "Profile calls when generating code for updating MDOs")           \
   1.308 +                                                                            \
   1.309 +  product(bool, Tier1ProfileVirtualCalls, true,                             \
   1.310 +          "Profile virtual calls when generating code for updating MDOs")   \
   1.311 +                                                                            \
   1.312 +  product(bool, Tier1ProfileInlinedCalls, true,                             \
   1.313 +          "Profile inlined calls when generating code for updating MDOs")   \
   1.314 +                                                                            \
   1.315 +  product(bool, Tier1ProfileBranches, true,                                 \
   1.316 +          "Profile branches when generating code for updating MDOs")        \
   1.317 +                                                                            \
   1.318 +  product(bool, Tier1ProfileCheckcasts, true,                               \
   1.319 +          "Profile checkcasts when generating code for updating MDOs")      \
   1.320 +                                                                            \
   1.321 +  product(bool, Tier1OptimizeVirtualCallProfiling, true,                    \
   1.322 +          "Use CHA and exact type results at call sites when updating MDOs") \
   1.323 +                                                                            \
   1.324 +  develop(bool, Tier1CountOnly, false,                                      \
   1.325 +          "Don't schedule tier 2 compiles. Enter VM only")                  \
   1.326 +                                                                            \
   1.327 +  develop(bool, PrintCFGToFile, false,                                      \
   1.328 +          "print control flow graph to a separate file during compilation") \
   1.329 +                                                                            \
   1.330 +
   1.331 +
   1.332 +// Read default values for c1 globals
   1.333 +// #include "incls/_c1_globals_pd.hpp.incl"
   1.334 +
   1.335 +C1_FLAGS(DECLARE_DEVELOPER_FLAG, DECLARE_PD_DEVELOPER_FLAG, DECLARE_PRODUCT_FLAG, DECLARE_PD_PRODUCT_FLAG, DECLARE_NOTPRODUCT_FLAG)

mercurial