-
Notifications
You must be signed in to change notification settings - Fork 137
Matias cds + logging/RedefineClasses.java crash fix. #1775
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: lworld
Are you sure you want to change the base?
Changes from all commits
9341c30
2f4f553
5a0a693
2f60f6d
416bf41
e17b338
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -305,7 +305,7 @@ void CDSConfig::ergo_init_classic_archive_paths() { | |
| } | ||
|
|
||
| void CDSConfig::check_internal_module_property(const char* key, const char* value) { | ||
| if (Arguments::is_incompatible_cds_internal_module_property(key) && !Arguments::patching_migrated_classes(key, value)) { | ||
| if (Arguments::is_incompatible_cds_internal_module_property(key)) { | ||
| stop_using_optimized_module_handling(); | ||
| aot_log_info(aot)("optimized module handling: disabled due to incompatible property: %s=%s", key, value); | ||
| } | ||
|
|
@@ -975,10 +975,6 @@ bool CDSConfig::are_vm_options_incompatible_with_dumping_heap() { | |
| } | ||
|
|
||
| bool CDSConfig::is_dumping_heap() { | ||
| if (is_valhalla_preview()) { | ||
| // Not working yet -- e.g., HeapShared::oop_hash() needs to be implemented for value oops | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't see an implementation of
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is something that doesn't work that for some reason I didn't run into on Friday.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It wasn't the oop_hash() reason that something didn't work, it was the wrong prototype header. |
||
| return false; | ||
| } | ||
| if (!(is_dumping_classic_static_archive() || is_dumping_final_static_archive()) | ||
| || are_vm_options_incompatible_with_dumping_heap() | ||
| || _disable_heap_dumping) { | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2928,6 +2928,19 @@ void CompiledEntrySignature::compute_calling_conventions(bool init) { | |
| GrowableArray<Method*>* supers = get_supers(); | ||
| for (int i = 0; i < supers->length(); ++i) { | ||
| Method* super_method = supers->at(i); | ||
| if (AOTCodeCache::is_using_adapter() && super_method->adapter()->get_sig_cc() == nullptr) { | ||
| // Calling conventions have to be regenerated at runtime and are accessed through method adapters, | ||
| // which are archived in the AOT code cache. If the adapters are not regenerated, the | ||
| // calling conventions should be regenerated here. | ||
| CompiledEntrySignature ces(super_method); | ||
| ces.compute_calling_conventions(); | ||
| if (ces.has_scalarized_args()) { | ||
| // Save a C heap allocated version of the scalarized signature and store it in the adapter | ||
| GrowableArray<SigEntry>* heap_sig = new (mtInternal) GrowableArray<SigEntry>(ces.sig_cc()->length(), mtInternal); | ||
| heap_sig->appendAll(ces.sig_cc()); | ||
| super_method->adapter()->set_sig_cc(heap_sig); | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't understand (yet) why the scalarized versions aren't already archived as part of the existing adapter archiving. Getting them saved/restored in the archive seems like the best approach, with this being a work around until that's sorted
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We explicitly null out the Opened https://bugs.openjdk.org/browse/JDK-8373348 a reminder to update the AOTCache support later |
||
| } | ||
| } | ||
| if (super_method->is_scalarized_arg(arg_num)) { | ||
| scalar_super = true; | ||
| } else { | ||
|
|
@@ -3382,6 +3395,7 @@ void AdapterHandlerEntry::remove_unshareable_info() { | |
| #endif // ASSERT | ||
| _adapter_blob = nullptr; | ||
| _linked = false; | ||
| _sig_cc = nullptr; | ||
| } | ||
|
|
||
| class CopyAdapterTableToArchive : StackObj { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AOTMapLogger::FakeRefArrayhas anFakeOop obj_at(int i)method for reading the elements. Do we need an equivalent forFakeFlatArray?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe we get away without having it due to the implementation of
FlatArrayKlass::oop_print_on?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it was nicer to have the printing logic in the flatArrayOop.cpp file rather than in some AOT file, so it's more like typeArrayOop. The refArray case wants to save the oops it finds for something.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Although I suppose this won't work if the flatArrayKlass has oops (something about read_oop_at())
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This code is weird. I don't know this code.