From 33688e92b95f96e3d59e35e7a5f7b8e0a3e42e42 Mon Sep 17 00:00:00 2001 From: "Y. Srinivas Ramakrishna" Date: Thu, 11 Nov 2010 10:42:43 -0800 Subject: [PATCH] 6998802: ScavengeALot: assert(!gch->incremental_collection_failed()) failed: Twice in a row Weaken assert by excluding scavenges resulting from -XX:+ScavengeALot stress-testing option. Reviewed-by: jmasa, tonyp --- hotspot/src/share/vm/memory/defNewGeneration.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hotspot/src/share/vm/memory/defNewGeneration.cpp b/hotspot/src/share/vm/memory/defNewGeneration.cpp index 19f265a6729..e04dcf2ff58 100644 --- a/hotspot/src/share/vm/memory/defNewGeneration.cpp +++ b/hotspot/src/share/vm/memory/defNewGeneration.cpp @@ -838,7 +838,9 @@ void DefNewGeneration::gc_epilogue(bool full) { gch->incremental_collection_failed()) { seen_incremental_collection_failed = true; } else if (seen_incremental_collection_failed) { - assert(!gch->incremental_collection_failed(), "Twice in a row"); + assert(gch->gc_cause() == GCCause::_scavenge_alot || !gch->incremental_collection_failed(), + "Twice in a row"); + seen_incremental_collection_failed = false; } #endif // ASSERT