comparison src/share/vm/oops/klass.cpp @ 5820:87ee5ee27509

Added tag jdk8-b132 for changeset 0c94c41dcd70
author katleman
date Tue, 04 Mar 2014 11:51:03 -0800
parents 9758d9f36299
children
comparison
equal deleted inserted replaced
38:bba65a9ef16f 39:fbe57fbff1e0
672 guarantee(obj->klass()->is_klass(), "klass field is not a klass"); 672 guarantee(obj->klass()->is_klass(), "klass field is not a klass");
673 } 673 }
674 674
675 #ifndef PRODUCT 675 #ifndef PRODUCT
676 676
677 void Klass::verify_vtable_index(int i) { 677 bool Klass::verify_vtable_index(int i) {
678 if (oop_is_instance()) { 678 if (oop_is_instance()) {
679 assert(i>=0 && i<((InstanceKlass*)this)->vtable_length()/vtableEntry::size(), "index out of bounds"); 679 int limit = ((InstanceKlass*)this)->vtable_length()/vtableEntry::size();
680 assert(i >= 0 && i < limit, err_msg("index %d out of bounds %d", i, limit));
680 } else { 681 } else {
681 assert(oop_is_array(), "Must be"); 682 assert(oop_is_array(), "Must be");
682 assert(i>=0 && i<((ArrayKlass*)this)->vtable_length()/vtableEntry::size(), "index out of bounds"); 683 int limit = ((ArrayKlass*)this)->vtable_length()/vtableEntry::size();
683 } 684 assert(i >= 0 && i < limit, err_msg("index %d out of bounds %d", i, limit));
685 }
686 return true;
687 }
688
689 bool Klass::verify_itable_index(int i) {
690 assert(oop_is_instance(), "");
691 int method_count = klassItable::method_count_for_interface(this);
692 assert(i >= 0 && i < method_count, "index out of bounds");
693 return true;
684 } 694 }
685 695
686 #endif 696 #endif