Skip to content

Commit 9d518b3

Browse files
committed
8310831: Some methods are missing from CDS regenerated JLI holder class
Reviewed-by: iklam, liach
1 parent 1dda79c commit 9d518b3

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/hotspot/share/cds/regeneratedClasses.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424

2525
#include "cds/archiveBuilder.hpp"
2626
#include "cds/regeneratedClasses.hpp"
27+
#include "classfile/vmSymbols.hpp"
2728
#include "memory/universe.hpp"
2829
#include "oops/instanceKlass.hpp"
2930
#include "oops/method.hpp"
@@ -62,8 +63,12 @@ void RegeneratedClasses::add_class(InstanceKlass* orig_klass, InstanceKlass* reg
6263
Method* regen_m = regen_klass->find_method(orig_m->name(), orig_m->signature());
6364
if (regen_m == nullptr) {
6465
ResourceMark rm;
65-
log_warning(aot)("Method in original class is missing from regenerated class: " INTPTR_FORMAT " %s",
66-
p2i(orig_m), orig_m->external_name());
66+
if (orig_m->name() != vmSymbols::object_initializer_name()) {
67+
// JLI Holder classes are never instantiated, they don't need to have constructors.
68+
// Not printing the warning if the method is a constructor.
69+
log_warning(aot)("Method in original class is missing from regenerated class: " INTPTR_FORMAT " %s",
70+
p2i(orig_m), orig_m->external_name());
71+
}
6772
} else {
6873
_regenerated_objs->put((address)orig_m, (address)regen_m);
6974
_original_objs->put((address)regen_m, (address)orig_m);

0 commit comments

Comments
 (0)