Mercurial > hg > truffle
changeset 11386:366136516cc6
ObjectStamp: Detect allways null cases in castTo. AlwaysNull stamps can keep their type information
author | Gilles Duboscq <duboscq@ssw.jku.at> |
---|---|
date | Wed, 21 Aug 2013 16:56:15 +0200 |
parents | e119ba892b45 |
children | 9088d13767f3 |
files | graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/type/ObjectStamp.java |
diffstat | 1 files changed, 3 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- 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(); }