changeset 7241:26ffe1669cc8

avoid rare useless inlinings
author Christian Haeubl <haeubl@ssw.jku.at>
date Mon, 17 Dec 2012 14:35:43 +0100
parents 6bb5b2af957a
children 80b278b69b5e
files graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java	Mon Dec 17 13:44:56 2012 +0100
+++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/InliningUtil.java	Mon Dec 17 14:35:43 2012 +0100
@@ -826,6 +826,8 @@
             return logNotInlinedMethodAndReturnFalse(invoke, "the invoke is dead code");
         } else if (!invoke.useForInlining()) {
             return logNotInlinedMethodAndReturnFalse(invoke, "the invoke is marked to be not used for inlining");
+        } else if (invoke.methodCallTarget().receiver() != null && invoke.methodCallTarget().receiver().isConstant() && invoke.methodCallTarget().receiver().asConstant().isNull()) {
+            return logNotInlinedMethodAndReturnFalse(invoke, "receiver is null");
         } else {
             return true;
         }