Mercurial > hg > graal-jvmci-8
diff graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotConstantPool.java @ 21431:90c55b9ad309
only put type in HotSpotConstantPool cache if it's resolved
author | Lukas Stadler <lukas.stadler@oracle.com> |
---|---|
date | Wed, 20 May 2015 14:18:02 +0200 |
parents | 082417ac43e4 |
children |
line wrap: on
line diff
--- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotConstantPool.java Wed May 20 14:17:56 2015 +0200 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/meta/HotSpotConstantPool.java Wed May 20 14:18:02 2015 +0200 @@ -503,7 +503,9 @@ } else { final long metaspacePointer = runtime().getCompilerToVM().lookupKlassInPool(metaspaceConstantPool, cpi); JavaType result = getJavaType(metaspacePointer); - this.lastLookupType = new LookupTypeCacheElement(cpi, result); + if (result instanceof ResolvedJavaType) { + this.lastLookupType = new LookupTypeCacheElement(cpi, result); + } return result; } }