# HG changeset patch # User Thomas Wuerthinger # Date 1305819061 -7200 # Node ID beea26b73b3fd36abc2f2808f9e90f85aa48710c # Parent a2f62de90c76644409ddb3f6713b9813318cfb33 Removed unused options and code. diff -r a2f62de90c76 -r beea26b73b3f graal/GraalCompiler/src/com/sun/c1x/C1XCompilation.java --- a/graal/GraalCompiler/src/com/sun/c1x/C1XCompilation.java Thu May 19 17:20:55 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/C1XCompilation.java Thu May 19 17:31:01 2011 +0200 @@ -166,7 +166,6 @@ * @return the block map for the specified method */ public BlockMap getBlockMap(RiMethod method) { - // PERF: cache the block map for methods that are compiled or inlined often BlockMap map = new BlockMap(method); map.build(); if (compiler.isObserved()) { diff -r a2f62de90c76 -r beea26b73b3f graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java --- a/graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java Thu May 19 17:20:55 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/C1XOptions.java Thu May 19 17:31:01 2011 +0200 @@ -62,16 +62,21 @@ // printing settings public static boolean PrintHIR = ____; - public static boolean PrintInliningFailures = ____; public static boolean PrintLIR = ____; public static boolean PrintCFGToFile = ____; + + // DOT output settings public static boolean PrintDOTGraphToFile = ____; public static boolean PrintDOTGraphToPdf = ____; + public static boolean OmitDOTFrameStates = true; + + // Ideal graph visualizer output settings public static int PrintIdealGraphLevel = 0; public static boolean PrintIdealGraphFile = ____; public static String PrintIdealGraphAddress = "127.0.0.1"; public static int PrintIdealGraphPort = 4444; - public static boolean OmitDOTFrameStates = true; + + // Other printing settings public static boolean PrintMetrics = ____; public static boolean PrintTimers = ____; public static boolean PrintCompilation = ____; @@ -86,51 +91,38 @@ public static boolean TraceLIRVisit = ____; public static boolean TraceAssembler = ____; public static int TraceBytecodeParserLevel = 0; - public static boolean PrintAssumptions = ____; public static boolean QuietBailout = ____; // state merging settings - public static boolean AssumeVerifiedBytecode = ____; - - // miscellaneous settings - public static boolean SupportObjectConstants = true; + public static boolean AssumeVerifiedBytecode = ____; // Linear scan settings - public static boolean CopyPointerStackArguments = true; + public static boolean CopyPointerStackArguments = true; // Code generator settings - public static boolean GenLIR = true; - public static boolean GenCode = true; + public static boolean GenLIR = true; + public static boolean GenCode = true; - public static boolean UseConstDirectCall = false; + public static boolean UseConstDirectCall = false; - public static boolean GenSpecialDivChecks = ____; - public static boolean GenAssertionCode = ____; - public static boolean AlignCallsForPatching = true; - public static boolean NullCheckUniquePc = ____; - public static boolean InvokeSnippetAfterArguments = ____; - public static boolean ResolveClassBeforeStaticInvoke = true; + public static boolean GenSpecialDivChecks = ____; + public static boolean GenAssertionCode = ____; + public static boolean AlignCallsForPatching = true; + public static boolean NullCheckUniquePc = ____; + public static boolean InvokeSnippetAfterArguments = ____; + public static boolean ResolveClassBeforeStaticInvoke = true; // Translating tableswitch instructions - public static int SequentialSwitchLimit = 4; - public static int RangeTestsSwitchDensity = 5; + public static int SequentialSwitchLimit = 4; + public static int RangeTestsSwitchDensity = 5; - public static int InitialCodeBufferSize = 232; - public static boolean DetailedAsserts = true; + public static boolean DetailedAsserts = ____; // Runtime settings - public static int ReadPrefetchInstr = 0; - public static int StackShadowPages = 2; + public static int ReadPrefetchInstr = 0; + public static int StackShadowPages = 2; // Assembler settings - public static boolean CommentedAssembly = ____; - public static boolean PrintLIRWithAssembly = ____; - public static int Atomics = 0; - public static boolean UseNormalNop = true; - public static boolean UseAddressNop = true; - public static boolean UseIncDec = ____; - public static boolean UseXmmLoadAndClearUpper = ____; - public static boolean UseXmmRegToRegMoveAll = ____; - - public static boolean StressImplicitExceptions = ____; + public static boolean CommentedAssembly = ____; + public static boolean PrintLIRWithAssembly = ____; } diff -r a2f62de90c76 -r beea26b73b3f graal/GraalCompiler/src/com/sun/c1x/graph/BlockMap.java --- a/graal/GraalCompiler/src/com/sun/c1x/graph/BlockMap.java Thu May 19 17:20:55 2011 +0200 +++ b/graal/GraalCompiler/src/com/sun/c1x/graph/BlockMap.java Thu May 19 17:31:01 2011 +0200 @@ -165,10 +165,6 @@ iterateOverBytecodes(); addExceptionEdges(); computeBlockOrder(); - - // Discard big arrays so that they can be GCed - blockMap = null; - canTrap = null; } private void makeExceptionEntries() { @@ -301,7 +297,7 @@ } case WIDE: { - if (canTrap != null && ProfileInformationStub.trappedFrequently(method, bci)) { + if (canTrap != null) { canTrap.set(bci); } @@ -310,7 +306,7 @@ } default: { - if (canTrap != null && ProfileInformationStub.trappedFrequently(method, bci)) { + if (canTrap != null) { canTrap.set(bci); } diff -r a2f62de90c76 -r beea26b73b3f graal/GraalCompiler/src/com/sun/c1x/graph/ProfileInformationStub.java --- a/graal/GraalCompiler/src/com/sun/c1x/graph/ProfileInformationStub.java Thu May 19 17:20:55 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,59 +0,0 @@ -/* - * Copyright (c) 2011, 2011, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package com.sun.c1x.graph; - -import static com.sun.cri.bytecode.Bytecodes.*; - -import com.sun.c1x.*; -import com.sun.cri.bytecode.*; -import com.sun.cri.ri.*; - -/** - * A temporary placeholder to bring in profile information to Graal, until we have a definitive interface. - * That allows us to mark dependencies in code that will need fixup in the future. - * - * TODO this class and the signature of its methods i temporary - */ -public class ProfileInformationStub { - - public static boolean trappedFrequently(RiMethod method, int bci) { - - // TODO: Currently, the runtime system does not support deoptimization when a call trhows an exception, - // so mark is a trapping so that explicit exception handler edges are generated. - switch (Bytes.beU1(method.code(), bci)) { - case INVOKESTATIC: - case INVOKESPECIAL: - case INVOKEVIRTUAL: - case INVOKEINTERFACE: { - return true; - } - } - - if (C1XOptions.StressImplicitExceptions && canTrap(method.code()[bci])) { - return true; - } - - return false; - } - -}