c1_globals.hpp revision 1879
0N/A/*
1472N/A * Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
0N/A *
0N/A * This code is free software; you can redistribute it and/or modify it
0N/A * under the terms of the GNU General Public License version 2 only, as
0N/A * published by the Free Software Foundation.
0N/A *
0N/A * This code is distributed in the hope that it will be useful, but WITHOUT
0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
0N/A * version 2 for more details (a copy is included in the LICENSE file that
0N/A * accompanied this code).
0N/A *
0N/A * You should have received a copy of the GNU General Public License version
0N/A * 2 along with this work; if not, write to the Free Software Foundation,
0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
0N/A *
1472N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
1472N/A * or visit www.oracle.com if you need additional information or have any
1472N/A * questions.
0N/A *
0N/A */
0N/A
1879N/A#ifndef SHARE_VM_C1_C1_GLOBALS_HPP
1879N/A#define SHARE_VM_C1_C1_GLOBALS_HPP
1879N/A
1879N/A#include "runtime/globals.hpp"
1879N/A#ifdef TARGET_ARCH_x86
1879N/A# include "c1_globals_x86.hpp"
1879N/A#endif
1879N/A#ifdef TARGET_ARCH_sparc
1879N/A# include "c1_globals_sparc.hpp"
1879N/A#endif
1879N/A#ifdef TARGET_OS_FAMILY_linux
1879N/A# include "c1_globals_linux.hpp"
1879N/A#endif
1879N/A#ifdef TARGET_OS_FAMILY_solaris
1879N/A# include "c1_globals_solaris.hpp"
1879N/A#endif
1879N/A#ifdef TARGET_OS_FAMILY_windows
1879N/A# include "c1_globals_windows.hpp"
1879N/A#endif
1879N/A
0N/A//
0N/A// Defines all global flags used by the client compiler.
0N/A//
0N/A#define C1_FLAGS(develop, develop_pd, product, product_pd, notproduct) \
0N/A \
0N/A /* Printing */ \
0N/A notproduct(bool, PrintC1Statistics, false, \
0N/A "Print Compiler1 statistics" ) \
0N/A \
0N/A notproduct(bool, PrintInitialBlockList, false, \
0N/A "Print block list of BlockListBuilder") \
0N/A \
0N/A notproduct(bool, PrintCFG, false, \
0N/A "Print control flow graph after each change") \
0N/A \
0N/A notproduct(bool, PrintCFG0, false, \
0N/A "Print control flow graph after construction") \
0N/A \
0N/A notproduct(bool, PrintCFG1, false, \
0N/A "Print control flow graph after optimizations") \
0N/A \
0N/A notproduct(bool, PrintCFG2, false, \
0N/A "Print control flow graph before code generation") \
0N/A \
0N/A notproduct(bool, PrintIRDuringConstruction, false, \
0N/A "Print IR as it's being constructed (helpful for debugging frontend)")\
0N/A \
1703N/A notproduct(bool, PrintPhiFunctions, false, \
0N/A "Print phi functions when they are created and simplified") \
0N/A \
0N/A notproduct(bool, PrintIR, false, \
0N/A "Print full intermediate representation after each change") \
0N/A \
0N/A notproduct(bool, PrintIR0, false, \
0N/A "Print full intermediate representation after construction") \
0N/A \
0N/A notproduct(bool, PrintIR1, false, \
0N/A "Print full intermediate representation after optimizations") \
0N/A \
0N/A notproduct(bool, PrintIR2, false, \
0N/A "Print full intermediate representation before code generation") \
0N/A \
0N/A notproduct(bool, PrintSimpleStubs, false, \
0N/A "Print SimpleStubs") \
0N/A \
0N/A /* C1 optimizations */ \
0N/A \
0N/A develop(bool, UseC1Optimizations, true, \
0N/A "Turn on C1 optimizations") \
0N/A \
0N/A develop(bool, SelectivePhiFunctions, true, \
0N/A "create phi functions at loop headers only when necessary") \
0N/A \
1819N/A develop(bool, OptimizeIfOps, true, \
1819N/A "Optimize multiple IfOps") \
1819N/A \
0N/A develop(bool, DoCEE, true, \
0N/A "Do Conditional Expression Elimination to simplify CFG") \
0N/A \
0N/A develop(bool, PrintCEE, false, \
0N/A "Print Conditional Expression Elimination") \
0N/A \
0N/A develop(bool, UseLocalValueNumbering, true, \
0N/A "Use Local Value Numbering (embedded in GraphBuilder)") \
0N/A \
0N/A develop(bool, UseGlobalValueNumbering, true, \
0N/A "Use Global Value Numbering (separate phase)") \
0N/A \
0N/A develop(bool, PrintValueNumbering, false, \
0N/A "Print Value Numbering") \
0N/A \
0N/A product(intx, ValueMapInitialSize, 11, \
0N/A "Initial size of a value map") \
0N/A \
0N/A product(intx, ValueMapMaxLoopSize, 8, \
0N/A "maximum size of a loop optimized by global value numbering") \
0N/A \
0N/A develop(bool, EliminateBlocks, true, \
0N/A "Eliminate unneccessary basic blocks") \
0N/A \
0N/A develop(bool, PrintBlockElimination, false, \
0N/A "Print basic block elimination") \
0N/A \
0N/A develop(bool, EliminateNullChecks, true, \
0N/A "Eliminate unneccessary null checks") \
0N/A \
0N/A develop(bool, PrintNullCheckElimination, false, \
0N/A "Print null check elimination") \
0N/A \
0N/A develop(bool, EliminateFieldAccess, true, \
0N/A "Optimize field loads and stores") \
0N/A \
0N/A develop(bool, InlineMethodsWithExceptionHandlers, true, \
0N/A "Inline methods containing exception handlers " \
0N/A "(NOTE: does not work with current backend)") \
0N/A \
0N/A develop(bool, InlineSynchronizedMethods, true, \
0N/A "Inline synchronized methods") \
0N/A \
0N/A develop(bool, InlineNIOCheckIndex, true, \
0N/A "Intrinsify java.nio.Buffer.checkIndex") \
0N/A \
0N/A develop(bool, CanonicalizeNodes, true, \
0N/A "Canonicalize graph nodes") \
0N/A \
0N/A develop(bool, CanonicalizeExperimental, false, \
0N/A "Canonicalize graph nodes, experimental code") \
0N/A \
0N/A develop(bool, PrintCanonicalization, false, \
0N/A "Print graph node canonicalization") \
0N/A \
0N/A develop(bool, UseTableRanges, true, \
0N/A "Faster versions of lookup table using ranges") \
0N/A \
0N/A develop(bool, UseFastExceptionHandling, true, \
0N/A "Faster handling of exceptions") \
0N/A \
0N/A develop_pd(bool, RoundFPResults, \
0N/A "Indicates whether rounding is needed for floating point results")\
0N/A \
0N/A develop(intx, NestedInliningSizeRatio, 90, \
0N/A "Percentage of prev. allowed inline size in recursive inlining") \
0N/A \
0N/A notproduct(bool, PrintIRWithLIR, false, \
0N/A "Print IR instructions with generated LIR") \
0N/A \
0N/A notproduct(bool, PrintLIRWithAssembly, false, \
0N/A "Show LIR instruction with generated assembly") \
0N/A \
0N/A develop(bool, CommentedAssembly, trueInDebug, \
0N/A "Show extra info in PrintNMethods output") \
0N/A \
0N/A develop(bool, LIRTracePeephole, false, \
0N/A "Trace peephole optimizer") \
0N/A \
0N/A develop(bool, LIRTraceExecution, false, \
0N/A "add LIR code which logs the execution of blocks") \
0N/A \
0N/A product_pd(bool, LIRFillDelaySlots, \
0N/A "fill delays on on SPARC with LIR") \
0N/A \
0N/A develop_pd(bool, CSEArrayLength, \
0N/A "Create separate nodes for length in array accesses") \
0N/A \
0N/A develop_pd(bool, TwoOperandLIRForm, \
0N/A "true if LIR requires src1 and dst to match in binary LIR ops") \
0N/A \
0N/A develop(intx, TraceLinearScanLevel, 0, \
0N/A "Debug levels for the linear scan allocator") \
0N/A \
0N/A develop(bool, StressLinearScan, false, \
0N/A "scramble block order used by LinearScan (stress test)") \
0N/A \
0N/A product(bool, TimeLinearScan, false, \
0N/A "detailed timing of LinearScan phases") \
0N/A \
0N/A develop(bool, TimeEachLinearScan, false, \
0N/A "print detailed timing of each LinearScan run") \
0N/A \
0N/A develop(bool, CountLinearScan, false, \
0N/A "collect statistic counters during LinearScan") \
0N/A \
0N/A /* C1 variable */ \
0N/A \
0N/A develop(bool, C1Breakpoint, false, \
0N/A "Sets a breakpoint at entry of each compiled method") \
0N/A \
0N/A develop(bool, ImplicitDiv0Checks, true, \
0N/A "Use implicit division by zero checks") \
0N/A \
0N/A develop(bool, PinAllInstructions, false, \
0N/A "All instructions are pinned") \
0N/A \
0N/A develop(bool, ValueStackPinStackAll, true, \
0N/A "Pinning in ValueStack pin everything") \
0N/A \
0N/A develop(bool, UseFastNewInstance, true, \
0N/A "Use fast inlined instance allocation") \
0N/A \
0N/A develop(bool, UseFastNewTypeArray, true, \
0N/A "Use fast inlined type array allocation") \
0N/A \
0N/A develop(bool, UseFastNewObjectArray, true, \
0N/A "Use fast inlined object array allocation") \
0N/A \
0N/A develop(bool, UseFastLocking, true, \
0N/A "Use fast inlined locking code") \
0N/A \
0N/A develop(bool, UseSlowPath, false, \
0N/A "For debugging: test slow cases by always using them") \
0N/A \
0N/A develop(bool, GenerateArrayStoreCheck, true, \
0N/A "Generates code for array store checks") \
0N/A \
0N/A develop(bool, DeoptC1, true, \
0N/A "Use deoptimization in C1") \
0N/A \
0N/A develop(bool, PrintBailouts, false, \
0N/A "Print bailout and its reason") \
0N/A \
0N/A develop(bool, TracePatching, false, \
0N/A "Trace patching of field access on uninitialized classes") \
0N/A \
0N/A develop(bool, PatchALot, false, \
0N/A "Marks all fields as having unloaded classes") \
0N/A \
0N/A develop(bool, PrintNotLoaded, false, \
0N/A "Prints where classes are not loaded during code generation") \
0N/A \
0N/A notproduct(bool, VerifyOopMaps, false, \
0N/A "Adds oopmap verification code to the generated code") \
0N/A \
0N/A develop(bool, PrintLIR, false, \
0N/A "print low-level IR") \
0N/A \
0N/A develop(bool, BailoutAfterHIR, false, \
0N/A "bailout of compilation after building of HIR") \
0N/A \
0N/A develop(bool, BailoutAfterLIR, false, \
0N/A "bailout of compilation after building of LIR") \
0N/A \
0N/A develop(bool, BailoutOnExceptionHandlers, false, \
0N/A "bailout of compilation for methods with exception handlers") \
0N/A \
0N/A develop(bool, InstallMethods, true, \
0N/A "Install methods at the end of successful compilations") \
0N/A \
0N/A product(intx, CompilationRepeat, 0, \
0N/A "Number of times to recompile method before returning result") \
0N/A \
0N/A develop(intx, NMethodSizeLimit, (32*K)*wordSize, \
0N/A "Maximum size of a compiled method.") \
0N/A \
0N/A develop(bool, TraceFPUStack, false, \
0N/A "Trace emulation of the FPU stack (intel only)") \
0N/A \
0N/A develop(bool, TraceFPURegisterUsage, false, \
0N/A "Trace usage of FPU registers at start of blocks (intel only)") \
0N/A \
0N/A develop(bool, OptimizeUnsafes, true, \
0N/A "Optimize raw unsafe ops") \
0N/A \
0N/A develop(bool, PrintUnsafeOptimization, false, \
0N/A "Print optimization of raw unsafe ops") \
0N/A \
0N/A develop(intx, InstructionCountCutoff, 37000, \
0N/A "If GraphBuilder adds this many instructions, bails out") \
0N/A \
0N/A product_pd(intx, SafepointPollOffset, \
0N/A "Offset added to polling address (Intel only)") \
0N/A \
0N/A develop(bool, ComputeExactFPURegisterUsage, true, \
0N/A "Compute additional live set for fpu registers to simplify fpu stack merge (Intel only)") \
0N/A \
1703N/A product(bool, C1ProfileCalls, true, \
0N/A "Profile calls when generating code for updating MDOs") \
0N/A \
1703N/A product(bool, C1ProfileVirtualCalls, true, \
0N/A "Profile virtual calls when generating code for updating MDOs") \
0N/A \
1703N/A product(bool, C1ProfileInlinedCalls, true, \
0N/A "Profile inlined calls when generating code for updating MDOs") \
0N/A \
1703N/A product(bool, C1ProfileBranches, true, \
0N/A "Profile branches when generating code for updating MDOs") \
0N/A \
1703N/A product(bool, C1ProfileCheckcasts, true, \
0N/A "Profile checkcasts when generating code for updating MDOs") \
0N/A \
1703N/A product(bool, C1OptimizeVirtualCallProfiling, true, \
1703N/A "Use CHA and exact type results at call sites when updating MDOs")\
0N/A \
1703N/A product(bool, C1UpdateMethodData, trueInTiered, \
1703N/A "Update methodDataOops in Tier1-generated code") \
0N/A \
0N/A develop(bool, PrintCFGToFile, false, \
0N/A "print control flow graph to a separate file during compilation") \
0N/A \
0N/A
0N/A
0N/A// Read default values for c1 globals
0N/A
0N/AC1_FLAGS(DECLARE_DEVELOPER_FLAG, DECLARE_PD_DEVELOPER_FLAG, DECLARE_PRODUCT_FLAG, DECLARE_PD_PRODUCT_FLAG, DECLARE_NOTPRODUCT_FLAG)
1879N/A
1879N/A#endif // SHARE_VM_C1_C1_GLOBALS_HPP