changeset 4672:7167f487cc31

fix NPE in tests caused by recordMethodContents
author Lukas Stadler <lukas.stadler@jku.at>
date Wed, 22 Feb 2012 17:27:11 +0100
parents 70b7b7071e68
children 8021e46f4a99 03ea39a3cf68
files graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/phases/InliningPhase.java
diffstat 1 files changed, 3 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/phases/InliningPhase.java	Wed Feb 22 17:05:20 2012 +0100
+++ b/graal/com.oracle.max.graal.compiler/src/com/oracle/max/graal/compiler/phases/InliningPhase.java	Wed Feb 22 17:27:11 2012 +0100
@@ -199,7 +199,9 @@
 
     @Override
     public void recordMethodContentsAssumption(RiResolvedMethod method) {
-        assumptions.recordMethodContents(method);
+        if (assumptions != null) {
+            assumptions.recordMethodContents(method);
+        }
     }
 
     private static int computeInliningLevel(Invoke invoke) {