Mercurial > hg > truffle
changeset 17094:86888df288ec
fixed case of Optionality constants
line wrap: on
line diff
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/GraalCompiler.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/GraalCompiler.java Wed Sep 10 11:44:39 2014 +0200 @@ -168,7 +168,7 @@ HighTierContext highTierContext = new HighTierContext(providers, assumptions, cache, graphBuilderSuite, optimisticOpts); if (graph.start().next() == null) { graphBuilderSuite.apply(graph, highTierContext); - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); } else { Debug.dump(graph, "initial state"); }
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/phases/HighTier.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/phases/HighTier.java Wed Sep 10 11:44:39 2014 +0200 @@ -58,7 +58,7 @@ appendPhase(new IterativeInliningPhase(canonicalizer)); } else { appendPhase(new InliningPhase(canonicalizer)); - appendPhase(new DeadCodeEliminationPhase(OPTIONAL)); + appendPhase(new DeadCodeEliminationPhase(Optional)); boolean reduceOrEliminate = FlowSensitiveReduction.getValue() || ConditionalElimination.getValue(); if (reduceOrEliminate && OptCanonicalizer.getValue()) {
--- a/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/phases/LowTier.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.compiler/src/com/oracle/graal/compiler/phases/LowTier.java Wed Sep 10 11:44:39 2014 +0200 @@ -64,6 +64,6 @@ appendPhase(new UseTrappingNullChecksPhase()); - appendPhase(new DeadCodeEliminationPhase(REQUIRED)); + appendPhase(new DeadCodeEliminationPhase(Required)); } }
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/phases/OnStackReplacementPhase.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/phases/OnStackReplacementPhase.java Wed Sep 10 11:44:39 2014 +0200 @@ -111,6 +111,6 @@ GraphUtil.killCFG(start); Debug.dump(graph, "OnStackReplacement result"); - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); } }
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ConvertDeoptimizeToGuardPhase.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ConvertDeoptimizeToGuardPhase.java Wed Sep 10 11:44:39 2014 +0200 @@ -103,7 +103,7 @@ } } - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); } private void visitDeoptBegin(BeginNode deoptBegin, DeoptimizationAction deoptAction, DeoptimizationReason deoptReason, StructuredGraph graph) {
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/DeadCodeEliminationPhase.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/DeadCodeEliminationPhase.java Wed Sep 10 11:44:39 2014 +0200 @@ -43,8 +43,8 @@ private static final DebugMetric metricNodesRemoved = Debug.metric("NodesRemoved"); public enum Optionality { - OPTIONAL, - REQUIRED; + Optional, + Required; } /** @@ -52,15 +52,15 @@ * {@link Options#ReduceDCE}. */ public DeadCodeEliminationPhase() { - this(Optionality.REQUIRED); + this(Optionality.Required); } /** * Creates a dead code elimination phase that will be run only if it is - * {@linkplain Optionality#REQUIRED non-optional} or {@link Options#ReduceDCE} is false. + * {@linkplain Optionality#Required non-optional} or {@link Options#ReduceDCE} is false. */ public DeadCodeEliminationPhase(Optionality optionality) { - this.optional = optionality == Optionality.OPTIONAL; + this.optional = optionality == Optionality.Optional; } private final boolean optional;
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/cfs/FlowSensitiveReduction.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/cfs/FlowSensitiveReduction.java Wed Sep 10 11:44:39 2014 +0200 @@ -151,7 +151,7 @@ for (PostponedDeopt postponed : postponedDeopts) { postponed.doRewrite(falseConstant); } - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); } for (MethodCallTargetNode mcn : graph.getNodes().filter(MethodCallTargetNode.class)) { if (mcn.isAlive() && FlowUtil.lacksUsages(mcn)) {
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/inlining/info/elem/InlineableGraph.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/inlining/info/elem/InlineableGraph.java Wed Sep 10 11:44:39 2014 +0200 @@ -247,7 +247,7 @@ } assert newGraph.start().next() != null : "graph needs to be populated by the GraphBuilderSuite"; - new DeadCodeEliminationPhase(OPTIONAL).apply(newGraph); + new DeadCodeEliminationPhase(Optional).apply(newGraph); if (OptCanonicalizer.getValue()) { canonicalizer.apply(newGraph, context);
--- a/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/ReplacementsImpl.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/ReplacementsImpl.java Wed Sep 10 11:44:39 2014 +0200 @@ -512,7 +512,7 @@ new CollapseFrameForSingleSideEffectPhase().apply(graph); break; } - new DeadCodeEliminationPhase(REQUIRED).apply(graph); + new DeadCodeEliminationPhase(Required).apply(graph); } /** @@ -614,7 +614,7 @@ */ protected void afterInlining(StructuredGraph graph) { new NodeIntrinsificationPhase(providers, snippetReflection).apply(graph); - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); if (OptCanonicalizer.getValue()) { new CanonicalizerPhase(true).apply(graph, new PhaseContext(providers, assumptions)); } @@ -687,7 +687,7 @@ end.disableSafepoint(); } - new DeadCodeEliminationPhase(REQUIRED).apply(graph); + new DeadCodeEliminationPhase(Required).apply(graph); } catch (Throwable e) { throw Debug.handle(e); }
--- a/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/SnippetTemplate.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.replacements/src/com/oracle/graal/replacements/SnippetTemplate.java Wed Sep 10 11:44:39 2014 +0200 @@ -671,7 +671,7 @@ } } - new DeadCodeEliminationPhase(REQUIRED).apply(snippetCopy); + new DeadCodeEliminationPhase(Required).apply(snippetCopy); assert checkAllVarargPlaceholdersAreDeleted(parameterCount, placeholders);
--- a/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/EffectsPhase.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/EffectsPhase.java Wed Sep 10 11:44:39 2014 +0200 @@ -101,7 +101,7 @@ Debug.dump(graph, "after " + getName() + " iteration"); } - new DeadCodeEliminationPhase(REQUIRED).apply(graph); + new DeadCodeEliminationPhase(Required).apply(graph); Set<Node> changedNodes = listener.getNodes(); for (Node node : graph.getNodes()) {
--- a/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/IterativeInliningPhase.java Wed Sep 10 11:36:45 2014 +0200 +++ b/graal/com.oracle.graal.virtual/src/com/oracle/graal/virtual/phases/ea/IterativeInliningPhase.java Wed Sep 10 11:44:39 2014 +0200 @@ -71,7 +71,7 @@ inlining.apply(graph, context); progress |= inlining.getInliningCount() > 0; - new DeadCodeEliminationPhase(OPTIONAL).apply(graph); + new DeadCodeEliminationPhase(Optional).apply(graph); boolean reduceOrEliminate = FlowSensitiveReduction.getValue() || ConditionalElimination.getValue(); if (reduceOrEliminate && OptCanonicalizer.getValue()) {