8149405: OOM Error running java/lang/invoke/MethodHandlesTest.java on windows-x86
Summary: Add missing ResourceMarks to release memory more quickly.
Reviewed-by: jmasa, kbarrett
--- a/hotspot/src/share/vm/oops/methodData.cpp Wed Apr 13 13:53:05 2016 +0200
+++ b/hotspot/src/share/vm/oops/methodData.cpp Tue Apr 12 14:46:02 2016 -0400
@@ -1729,6 +1729,7 @@
}
void MethodData::clean_method_data(BoolObjectClosure* is_alive) {
+ ResourceMark rm;
for (ProfileData* data = first_data();
is_valid(data);
data = next_data(data)) {
@@ -1745,6 +1746,7 @@
}
void MethodData::clean_weak_method_links() {
+ ResourceMark rm;
for (ProfileData* data = first_data();
is_valid(data);
data = next_data(data)) {
@@ -1758,6 +1760,7 @@
#ifdef ASSERT
void MethodData::verify_clean_weak_method_links() {
+ ResourceMark rm;
for (ProfileData* data = first_data();
is_valid(data);
data = next_data(data)) {