8005114: VM is crashing in ciKlass*ciObjArrayKlass::element_klass() if metaspaces are full

Missing test for loaded klass in c1

Reviewed-by: kvn
This commit is contained in:
Roland Westrelin 2013-02-04 09:11:21 +01:00
parent 7d8f623180
commit f13dbb00cf

View file

@ -188,7 +188,7 @@ ciType* LoadIndexed::exact_type() const {
ciType* LoadIndexed::declared_type() const {
ciType* array_type = array()->declared_type();
if (array_type == NULL) {
if (array_type == NULL || !array_type->is_loaded()) {
return NULL;
}
assert(array_type->is_array_klass(), "what else?");