mirror of
https://github.com/openjdk/jdk.git
synced 2026-03-25 07:09:55 +00:00
8359394: GC cause cleanup
Reviewed-by: shade, ysr, stefank
This commit is contained in:
parent
2fe1298447
commit
dec42bebb8
@ -89,11 +89,14 @@ const char* GCCause::to_string(GCCause::Cause cause) {
|
||||
case _dcmd_gc_run:
|
||||
return "Diagnostic Command";
|
||||
|
||||
case _shenandoah_stop_vm:
|
||||
return "Stopping VM";
|
||||
|
||||
case _shenandoah_allocation_failure_evac:
|
||||
return "Allocation Failure During Evacuation";
|
||||
|
||||
case _shenandoah_stop_vm:
|
||||
return "Stopping VM";
|
||||
case _shenandoah_humongous_allocation_failure:
|
||||
return "Humongous Allocation Failure";
|
||||
|
||||
case _shenandoah_concurrent_gc:
|
||||
return "Concurrent GC";
|
||||
|
||||
@ -55,7 +55,6 @@ class GCCause : public AllStatic {
|
||||
|
||||
/* implementation independent, but reserved for GC use */
|
||||
_no_gc,
|
||||
_no_cause_specified,
|
||||
_allocation_failure,
|
||||
|
||||
/* implementation specific */
|
||||
@ -99,14 +98,13 @@ class GCCause : public AllStatic {
|
||||
cause == GCCause::_wb_full_gc);
|
||||
}
|
||||
|
||||
inline static bool is_serviceability_requested_gc(GCCause::Cause
|
||||
cause) {
|
||||
inline static bool is_serviceability_requested_gc(GCCause::Cause cause) {
|
||||
return (cause == GCCause::_jvmti_force_gc ||
|
||||
cause == GCCause::_heap_inspection ||
|
||||
cause == GCCause::_heap_dump);
|
||||
}
|
||||
|
||||
// Causes for collection of the tenured gernation
|
||||
// Causes for collection of the tenured generation
|
||||
inline static bool is_tenured_allocation_failure_gc(GCCause::Cause cause) {
|
||||
// _allocation_failure is the generic cause a collection which could result
|
||||
// in the collection of the tenured generation if there is not enough space
|
||||
@ -117,8 +115,7 @@ class GCCause : public AllStatic {
|
||||
// Causes for collection of the young generation
|
||||
inline static bool is_allocation_failure_gc(GCCause::Cause cause) {
|
||||
// _allocation_failure is the generic cause a collection for allocation failure
|
||||
return (cause == GCCause::_allocation_failure ||
|
||||
cause == GCCause::_shenandoah_allocation_failure_evac);
|
||||
return cause == GCCause::_allocation_failure;
|
||||
}
|
||||
|
||||
// Return a string describing the GCCause.
|
||||
|
||||
@ -99,8 +99,7 @@ static bool should_use_gclocker() {
|
||||
}
|
||||
|
||||
bool VM_GC_Operation::doit_prologue() {
|
||||
assert(((_gc_cause != GCCause::_no_gc) &&
|
||||
(_gc_cause != GCCause::_no_cause_specified)), "Illegal GCCause");
|
||||
assert(_gc_cause != GCCause::_no_gc, "Illegal GCCause");
|
||||
|
||||
// To be able to handle a GC the VM initialization needs to be completed.
|
||||
if (!is_init_completed()) {
|
||||
|
||||
@ -42,7 +42,7 @@
|
||||
|
||||
ShenandoahControlThread::ShenandoahControlThread() :
|
||||
ShenandoahController(),
|
||||
_requested_gc_cause(GCCause::_no_cause_specified),
|
||||
_requested_gc_cause(GCCause::_no_gc),
|
||||
_degen_point(ShenandoahGC::_degenerated_outside_cycle) {
|
||||
set_name("Shenandoah Control Thread");
|
||||
create_and_start();
|
||||
|
||||
@ -39,7 +39,6 @@ public enum GCCause {
|
||||
_wb_breakpoint ("WhiteBox Initiated Run to Breakpoint"),
|
||||
|
||||
_no_gc ("No GC"),
|
||||
_no_cause_specified ("Unknown GCCause"),
|
||||
_allocation_failure ("Allocation Failure"),
|
||||
|
||||
_codecache_GC_threshold ("CodeCache GC Threshold"),
|
||||
@ -54,8 +53,9 @@ public enum GCCause {
|
||||
|
||||
_dcmd_gc_run ("Diagnostic Command"),
|
||||
|
||||
_shenandoah_allocation_failure_evac ("Allocation Failure During Evacuation"),
|
||||
_shenandoah_stop_vm ("Stopping VM"),
|
||||
_shenandoah_allocation_failure_evac ("Allocation Failure During Evacuation"),
|
||||
_shenandoah_humongous_allocation_failure("Humongous Allocation Failure"),
|
||||
_shenandoah_concurrent_gc ("Concurrent GC"),
|
||||
_shenandoah_upgrade_to_full_gc ("Upgrade To Full GC"),
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user