changeset 24115:244adb543e36

missing checks in HotSpotMemoryAccessProviderImpl can cause VM assertions to fail - part 5 (JDK-8177673)
author Doug Simon <doug.simon@oracle.com>
date Sat, 01 Apr 2017 12:37:10 +0200
parents 2b760c6b0561
children df038ccc5943
files jvmci/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/jvmci/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java	Sat Apr 01 00:53:40 2017 +0200
+++ b/jvmci/jdk.vm.ci.hotspot/src/jdk/vm/ci/hotspot/HotSpotMemoryAccessProviderImpl.java	Sat Apr 01 12:37:10 2017 +0200
@@ -61,7 +61,7 @@
             HotSpotObjectConstantImpl constant = (HotSpotObjectConstantImpl) base;
             HotSpotResolvedObjectType type = constant.getType();
             Object object = constant.object();
-            if (object instanceof Class) {
+            if (object instanceof Class && kind != JavaKind.Object) {
                 // Cannot check bounds when reading from a java.lang.Class as
                 // we don't have the bounds for the variable length part of
                 // the object tail containing the static fields of the