< prev index next >

src/share/vm/oops/klass.inline.hpp

Print this page

        

*** 61,71 **** inline Klass* Klass::decode_klass_not_null(narrowKlass v) { assert(!is_null(v), "narrow klass value can never be zero"); int shift = Universe::narrow_klass_shift(); Klass* result = (Klass*)(void*)((uintptr_t)Universe::narrow_klass_base() + ((uintptr_t)v << shift)); ! assert(check_klass_alignment(result), err_msg("address not aligned: " INTPTR_FORMAT, p2i((void*) result))); return result; } inline Klass* Klass::decode_klass(narrowKlass v) { return is_null(v) ? (Klass*)NULL : decode_klass_not_null(v); --- 61,71 ---- inline Klass* Klass::decode_klass_not_null(narrowKlass v) { assert(!is_null(v), "narrow klass value can never be zero"); int shift = Universe::narrow_klass_shift(); Klass* result = (Klass*)(void*)((uintptr_t)Universe::narrow_klass_base() + ((uintptr_t)v << shift)); ! assert(check_klass_alignment(result), "address not aligned: " INTPTR_FORMAT, p2i((void*) result)); return result; } inline Klass* Klass::decode_klass(narrowKlass v) { return is_null(v) ? (Klass*)NULL : decode_klass_not_null(v);
< prev index next >