--- a/src/hotspot/share/oops/methodData.cpp Mon Sep 23 14:39:11 2019 -0400
+++ b/src/hotspot/share/oops/methodData.cpp Mon Sep 23 14:49:04 2019 -0400
@@ -216,7 +216,7 @@
args_cell = TypeStackSlotEntries::compute_cell_count(inv.signature(), false, TypeProfileArgsLimit);
}
int ret_cell = 0;
- if (MethodData::profile_return_for_invoke(m, bci) && (inv.result_type() == T_OBJECT || inv.result_type() == T_ARRAY)) {
+ if (MethodData::profile_return_for_invoke(m, bci) && is_reference_type(inv.result_type())) {
ret_cell = ReturnTypeEntry::static_cell_count();
}
int header_cell = 0;
@@ -289,7 +289,7 @@
}
if (has_return()) {
- assert(inv.result_type() == T_OBJECT || inv.result_type() == T_ARRAY, "room for a ret type but doesn't return obj?");
+ assert(is_reference_type(inv.result_type()), "room for a ret type but doesn't return obj?");
_ret.post_initialize();
}
}
@@ -310,7 +310,7 @@
}
if (has_return()) {
- assert(inv.result_type() == T_OBJECT || inv.result_type() == T_ARRAY, "room for a ret type but doesn't return obj?");
+ assert(is_reference_type(inv.result_type()), "room for a ret type but doesn't return obj?");
_ret.post_initialize();
}
}