mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-16 09:04:41 +02:00
7032407: Crash in LinkResolver::runtime_resolve_virtual_method()
Make CDS reorder vtables so that dump time vtables match run time order, so when redefine classes reinitializes them, they aren't in the wrong order. Reviewed-by: dcubed, acorn
This commit is contained in:
parent
2a5436b3d3
commit
8acea1848a
7 changed files with 75 additions and 13 deletions
|
@ -453,6 +453,14 @@ void Klass::remove_unshareable_info() {
|
|||
ik->unlink_class();
|
||||
}
|
||||
}
|
||||
// Clear the Java vtable if the oop has one.
|
||||
// The vtable isn't shareable because it's in the wrong order wrt the methods
|
||||
// once the method names get moved and resorted.
|
||||
klassVtable* vt = vtable();
|
||||
if (vt != NULL) {
|
||||
assert(oop_is_instance() || oop_is_array(), "nothing else has vtable");
|
||||
vt->clear_vtable();
|
||||
}
|
||||
set_subklass(NULL);
|
||||
set_next_sibling(NULL);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue