mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8231606: _method_ordering is not set during CDS dynamic dump time
Add the missing DynamicDumpSharedSpaces check in sort_methods(); replace the (DumpSharedSpaces || DynamicDumpSharedSpaces) with the Arguments::is_dumping_archive() function call. Reviewed-by: iklam, coleenp, jiangli
This commit is contained in:
parent
72c2079fd0
commit
b08a8c5cc3
24 changed files with 73 additions and 54 deletions
|
@ -3004,7 +3004,7 @@ static const intArray* sort_methods(Array<Method*>* methods) {
|
|||
// We temporarily use the vtable_index field in the Method* to store the
|
||||
// class file index, so we can read in after calling qsort.
|
||||
// Put the method ordering in the shared archive.
|
||||
if (JvmtiExport::can_maintain_original_method_order() || DumpSharedSpaces) {
|
||||
if (JvmtiExport::can_maintain_original_method_order() || Arguments::is_dumping_archive()) {
|
||||
for (int index = 0; index < length; index++) {
|
||||
Method* const m = methods->at(index);
|
||||
assert(!m->valid_vtable_index(), "vtable index should not be set");
|
||||
|
@ -3018,7 +3018,7 @@ static const intArray* sort_methods(Array<Method*>* methods) {
|
|||
intArray* method_ordering = NULL;
|
||||
// If JVMTI original method ordering or sharing is enabled construct int
|
||||
// array remembering the original ordering
|
||||
if (JvmtiExport::can_maintain_original_method_order() || DumpSharedSpaces) {
|
||||
if (JvmtiExport::can_maintain_original_method_order() || Arguments::is_dumping_archive()) {
|
||||
method_ordering = new intArray(length, length, -1);
|
||||
for (int index = 0; index < length; index++) {
|
||||
Method* const m = methods->at(index);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue