# HG changeset patch # Parent aad3b13d566cae3a3b5696156448fe7834a5e2c7 diff -r aad3b13d566c -r 5baa92919f28 src/hotspot/share/ci/ciInstanceKlass.cpp --- a/src/hotspot/share/ci/ciInstanceKlass.cpp Tue Dec 10 23:07:28 2019 +0100 +++ b/src/hotspot/share/ci/ciInstanceKlass.cpp Thu Dec 12 19:04:44 2019 +0100 @@ -65,7 +65,6 @@ _is_anonymous = ik->is_anonymous(); _nonstatic_fields = NULL; // initialized lazily by compute_nonstatic_fields: _has_injected_fields = -1; - _has_object_fields = -1; _implementor = NULL; // we will fill these lazily // Ensure that the metadata wrapped by the ciMetadata is kept alive by GC. @@ -123,7 +122,6 @@ _has_nonstatic_fields = false; _nonstatic_fields = NULL; _has_injected_fields = -1; - _has_object_fields = -1; _is_anonymous = false; _loader = loader; _protection_domain = protection_domain; @@ -556,19 +554,6 @@ _has_injected_fields = has_injected_fields; } -void ciInstanceKlass::compute_object_fields() { - for (int i = 0; i < nof_nonstatic_fields(); i++) { - ciField* f = nonstatic_field_at(i); - if (f->layout_type() == T_OBJECT) { - assert(_has_object_fields == -1 || _has_object_fields == 1, "broken concurrent initialization"); - _has_object_fields = 1; - return; - } - } - assert(_has_object_fields == -1 || _has_object_fields == 0, "broken concurrent initialization"); - _has_object_fields = 0; -} - // ------------------------------------------------------------------ // ciInstanceKlass::find_method // diff -r aad3b13d566c -r 5baa92919f28 src/hotspot/share/ci/ciInstanceKlass.hpp --- a/src/hotspot/share/ci/ciInstanceKlass.hpp Tue Dec 10 23:07:28 2019 +0100 +++ b/src/hotspot/share/ci/ciInstanceKlass.hpp Thu Dec 12 19:04:44 2019 +0100 @@ -66,7 +66,6 @@ ciConstantPoolCache* _field_cache; // cached map index->field GrowableArray* _nonstatic_fields; int _has_injected_fields; // any non static injected fields? lazily initialized. - int _has_object_fields; // any object fields? lazily initialized. // The possible values of the _implementor fall into following three cases: // NULL: no implementor. @@ -76,7 +75,6 @@ void compute_injected_fields(); bool compute_injected_fields_helper(); - void compute_object_fields(); protected: ciInstanceKlass(Klass* k); @@ -204,13 +202,6 @@ return _has_injected_fields > 0 ? true : false; } - bool has_object_fields() { - if (_has_object_fields == -1) { - compute_object_fields(); - } - return _has_object_fields > 0 ? true : false; - } - // nth nonstatic field (presented by ascending address) ciField* nonstatic_field_at(int i) { assert(_nonstatic_fields != NULL, "");