Mercurial > hg > truffle
changeset 19861:7d933ffe6df6
Remove fine grained debug scopes in the canonicalizer.
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Sun, 15 Mar 2015 14:22:50 +0100 |
parents | d4c45ab543c8 |
children | e808c8324035 |
files | graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/CanonicalizerPhase.java |
diffstat | 1 files changed, 9 insertions(+), 16 deletions(-) [+] |
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/CanonicalizerPhase.java Sun Mar 15 14:16:21 2015 +0100 +++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/CanonicalizerPhase.java Sun Mar 15 14:22:50 2015 +0100 @@ -24,7 +24,6 @@ import com.oracle.graal.api.meta.*; import com.oracle.graal.debug.*; -import com.oracle.graal.debug.Debug.Scope; import com.oracle.graal.graph.*; import com.oracle.graal.graph.Graph.Mark; import com.oracle.graal.graph.Graph.NodeEventListener; @@ -254,30 +253,24 @@ } if (nodeClass.isCanonicalizable()) { METRIC_CANONICALIZATION_CONSIDERED_NODES.increment(); - try (Scope s = Debug.scope("CanonicalizeNode", node)) { - Node canonical; - try (AutoCloseable verify = getCanonicalizeableContractAssertion(node)) { - canonical = ((Canonicalizable) node).canonical(tool); - if (canonical == node && nodeClass.isCommutative()) { - canonical = ((BinaryCommutative<?>) node).maybeCommuteInputs(); - } - } - if (performReplacement(node, canonical)) { - return true; + Node canonical; + try (AutoCloseable verify = getCanonicalizeableContractAssertion(node)) { + canonical = ((Canonicalizable) node).canonical(tool); + if (canonical == node && nodeClass.isCommutative()) { + canonical = ((BinaryCommutative<?>) node).maybeCommuteInputs(); } } catch (Throwable e) { throw Debug.handle(e); } + if (performReplacement(node, canonical)) { + return true; + } } if (nodeClass.isSimplifiable() && simplify) { Debug.log(3, "Canonicalizer: simplifying %s", node); METRIC_SIMPLIFICATION_CONSIDERED_NODES.increment(); - try (Scope s = Debug.scope("SimplifyNode", node)) { - node.simplify(tool); - } catch (Throwable e) { - throw Debug.handle(e); - } + node.simplify(tool); return node.isDeleted(); } return false;