changeset 10877:ecf802144350

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
author drwhite
date Tue, 12 Apr 2016 14:46:02 -0400
parents b39019876702
children c1b104997b4d bb590d2e0935
files src/share/vm/oops/methodData.cpp
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/oops/methodData.cpp	Wed Apr 13 13:53:05 2016 +0200
+++ b/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)) {