--- a/hotspot/src/share/vm/memory/defNewGeneration.cpp Fri Apr 09 13:08:34 2010 -0400
+++ b/hotspot/src/share/vm/memory/defNewGeneration.cpp Tue Apr 13 13:52:10 2010 -0700
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2008 Sun Microsystems, Inc. All Rights Reserved.
+ * Copyright 2001-2010 Sun Microsystems, Inc. All Rights Reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -594,6 +594,10 @@
_tenuring_threshold =
age_table()->compute_tenuring_threshold(to()->capacity()/HeapWordSize);
+ // A successful scavenge should restart the GC time limit count which is
+ // for full GC's.
+ AdaptiveSizePolicy* size_policy = gch->gen_policy()->size_policy();
+ size_policy->reset_gc_overhead_limit_count();
if (PrintGC && !PrintGCDetails) {
gch->print_heap_change(gch_prev_used);
}