# HG changeset patch # User Andreas Woess # Date 1389554733 -3600 # Node ID 565bf188d39b5afeea1128b27d5487c2c75112f9 # Parent dd0ba029bf34294446c80cd293d641273e393c52 Fix graph mark comparison in TruffleCache diff -r dd0ba029bf34 -r 565bf188d39b graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/PartialEvaluator.java --- a/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/PartialEvaluator.java Sun Jan 12 18:43:35 2014 +0000 +++ b/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/PartialEvaluator.java Sun Jan 12 20:25:33 2014 +0100 @@ -141,7 +141,6 @@ new DebugHistogramAsciiPrinter(TTY.out().out()).print(histogram); } - // Additional inlining. canonicalizer.apply(graph, baseContext); HighTierContext tierContext = new HighTierContext(providers, assumptions, cache, new PhaseSuite(), OptimisticOptimizations.NONE); diff -r dd0ba029bf34 -r 565bf188d39b graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/TruffleCache.java --- a/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/TruffleCache.java Sun Jan 12 18:43:35 2014 +0000 +++ b/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/TruffleCache.java Sun Jan 12 20:25:33 2014 +0100 @@ -94,7 +94,8 @@ try (Scope s = Debug.scope("TruffleCache", new Object[]{providers.getMetaAccess(), method})) { final StructuredGraph graph = new StructuredGraph(method); - PhaseContext phaseContext = new PhaseContext(providers, new Assumptions(false)); + final PhaseContext phaseContext = new PhaseContext(providers, new Assumptions(false)); + Mark mark = graph.getMark(); new GraphBuilderPhase.Instance(phaseContext.getMetaAccess(), config, optimisticOptimizations).apply(graph); for (LocalNode l : graph.getNodes(LocalNode.class)) { @@ -113,7 +114,6 @@ CanonicalizerPhase canonicalizerPhase = new CanonicalizerPhase(!ImmutableCode.getValue()); PartialEscapePhase partialEscapePhase = new PartialEscapePhase(false, canonicalizerPhase); - Mark mark = null; while (true) { partialEscapePhase.apply(graph, phaseContext); @@ -127,7 +127,7 @@ boolean inliningProgress = false; for (MethodCallTargetNode methodCallTarget : graph.getNodes(MethodCallTargetNode.class)) { - if (graph.getMark().equals(mark)) { + if (!graph.getMark().equals(mark)) { // Make sure macro substitutions such as // CompilerDirectives.transferToInterpreter get processed first. for (Node newNode : graph.getNewNodes(mark)) {