mirror of
https://github.com/openjdk/jdk.git
synced 2026-02-25 09:40:10 +00:00
7181632: nsk classLoad001_14 failure and CompileTheWorld crash after 7178145
Need to copy the inlined exception table to the new constMethodOop during method rewriting. Reviewed-by: coleenp, dholmes
This commit is contained in:
parent
e13a29b3f2
commit
494465e698
@ -1082,6 +1082,7 @@ methodHandle methodOopDesc:: clone_with_new_data(methodHandle m, u_char* new_cod
|
||||
newm->set_method_size(new_method_size);
|
||||
assert(newm->code_size() == new_code_length, "check");
|
||||
assert(newm->checked_exceptions_length() == checked_exceptions_len, "check");
|
||||
assert(newm->exception_table_length() == exception_table_len, "check");
|
||||
assert(newm->localvariable_table_length() == localvariable_len, "check");
|
||||
// Copy new byte codes
|
||||
memcpy(newm->code_base(), new_code, new_code_length);
|
||||
@ -1097,6 +1098,12 @@ methodHandle methodOopDesc:: clone_with_new_data(methodHandle m, u_char* new_cod
|
||||
m->checked_exceptions_start(),
|
||||
checked_exceptions_len * sizeof(CheckedExceptionElement));
|
||||
}
|
||||
// Copy exception table
|
||||
if (exception_table_len > 0) {
|
||||
memcpy(newm->exception_table_start(),
|
||||
m->exception_table_start(),
|
||||
exception_table_len * sizeof(ExceptionTableElement));
|
||||
}
|
||||
// Copy local variable number table
|
||||
if (localvariable_len > 0) {
|
||||
memcpy(newm->localvariable_table_start(),
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user