# HG changeset patch # User Gilles Duboscq # Date 1377096975 -7200 # Node ID 366136516cc6449b5f33e66dbcfbc14a6dc76de4 # Parent e119ba892b45987c7c26dfc12525b52cdee33449 ObjectStamp: Detect allways null cases in castTo. AlwaysNull stamps can keep their type information diff -r e119ba892b45 -r 366136516cc6 graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/type/ObjectStamp.java --- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/type/ObjectStamp.java Wed Aug 21 16:20:53 2013 +0200 +++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/type/ObjectStamp.java Wed Aug 21 16:56:15 2013 +0200 @@ -188,9 +188,9 @@ joinExactType = other.exactType; } else { joinType = null; - if (joinExactType || (!type.isInterface() && !other.type.isInterface())) { - joinAlwaysNull = true; - } + } + if (joinExactType || (!type.isInterface() && !other.type.isInterface())) { + joinAlwaysNull = true; } } } @@ -198,8 +198,6 @@ if (joinNonNull) { return StampFactory.illegal(); } - joinExactType = false; - joinType = null; } else if (joinExactType && Modifier.isAbstract(joinType.getModifiers()) && !joinType.isArray()) { return StampFactory.illegal(); }