mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 14:24:46 +02:00
7117052: instanceKlass::_init_state can be u1 type
Change instanceKlass::_init_state field to u1 type. Reviewed-by: bdelsart, coleenp, dholmes, phh, never
This commit is contained in:
parent
8e81e037e7
commit
f9f4ba0203
14 changed files with 27 additions and 19 deletions
|
@ -208,7 +208,7 @@ void instanceKlass::eager_initialize_impl(instanceKlassHandle this_oop) {
|
|||
// abort if someone beat us to the initialization
|
||||
if (!this_oop->is_not_initialized()) return; // note: not equivalent to is_initialized()
|
||||
|
||||
ClassState old_state = this_oop->_init_state;
|
||||
ClassState old_state = this_oop->init_state();
|
||||
link_class_impl(this_oop, true, THREAD);
|
||||
if (HAS_PENDING_EXCEPTION) {
|
||||
CLEAR_PENDING_EXCEPTION;
|
||||
|
@ -2479,7 +2479,7 @@ void instanceKlass::set_init_state(ClassState state) {
|
|||
bool good_state = as_klassOop()->is_shared() ? (_init_state <= state)
|
||||
: (_init_state < state);
|
||||
assert(good_state || state == allocated, "illegal state transition");
|
||||
_init_state = state;
|
||||
_init_state = (u1)state;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue