8152271: MemberNameTable doesn't purge stale entries

Intern MemberNames in table instead of allocating new entries

Reviewed-by: vlivanov, sspitsyn, dholmes
This commit is contained in:
Coleen Phillimore 2016-06-15 09:48:24 -04:00
parent 6ef961edbd
commit eba25b33b9
7 changed files with 55 additions and 19 deletions

View file

@ -695,7 +695,7 @@ JVM_ENTRY(jobject, JVM_Clone(JNIEnv* env, jobject handle))
// This can safepoint and redefine method, so need both new_obj and method
// in a handle, for two different reasons. new_obj can move, method can be
// deleted if nothing is using it on the stack.
m->method_holder()->add_member_name(new_obj());
m->method_holder()->add_member_name(new_obj(), false);
}
}