changeset 7303:713dfbf84b10

8061259: ParNew promotion failed is serialized on a lock Reviewed-by: kbarrett, brutisso Contributed-by: jwha@google.com
author brutisso
date Fri, 16 Jan 2015 09:40:13 +0100
parents 0643c076b6c3
children 6f31df24cec0
files src/share/vm/gc_implementation/parNew/parNewGeneration.cpp
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp	Tue Apr 14 19:45:47 2015 +0000
+++ b/src/share/vm/gc_implementation/parNew/parNewGeneration.cpp	Fri Jan 16 09:40:13 2015 +0100
@@ -1197,8 +1197,10 @@
         return real_forwardee(old);
     }
 
-    new_obj = _next_gen->par_promote(par_scan_state->thread_num(),
-                                       old, m, sz);
+    if (!_promotion_failed) {
+      new_obj = _next_gen->par_promote(par_scan_state->thread_num(),
+                                        old, m, sz);
+    }
 
     if (new_obj == NULL) {
       // promotion failed, forward to self