60
61 _tenured_generation_full,
62 _metadata_GC_threshold,
63
64 _cms_generation_full,
65 _cms_initial_mark,
66 _cms_final_remark,
67 _cms_concurrent_mark,
68
69 _old_generation_expanded_on_last_scavenge,
70 _old_generation_too_full_to_scavenge,
71 _adaptive_size_policy,
72
73 _g1_inc_collection_pause,
74 _g1_humongous_allocation,
75
76 _last_ditch_collection,
77 _last_gc_cause
78 };
79
80 inline static bool is_user_requested_gc(GCCause::Cause cause) {
81 return (cause == GCCause::_java_lang_system_gc ||
82 cause == GCCause::_jvmti_force_gc);
83 }
84
85 inline static bool is_serviceability_requested_gc(GCCause::Cause
86 cause) {
87 return (cause == GCCause::_jvmti_force_gc ||
88 cause == GCCause::_heap_inspection ||
89 cause == GCCause::_heap_dump);
90 }
91
92 inline static bool is_tenured_allocation_failure_gc(GCCause::Cause cause) {
93 assert(cause != GCCause::_old_generation_too_full_to_scavenge &&
94 cause != GCCause::_old_generation_expanded_on_last_scavenge,
95 err_msg("This GCCause may be correct but is not expected yet: %s",
96 to_string(cause)));
97 return (cause == GCCause::_tenured_generation_full ||
98 cause == GCCause::_cms_generation_full ||
99 cause == GCCause::_adaptive_size_policy);
|
60
61 _tenured_generation_full,
62 _metadata_GC_threshold,
63
64 _cms_generation_full,
65 _cms_initial_mark,
66 _cms_final_remark,
67 _cms_concurrent_mark,
68
69 _old_generation_expanded_on_last_scavenge,
70 _old_generation_too_full_to_scavenge,
71 _adaptive_size_policy,
72
73 _g1_inc_collection_pause,
74 _g1_humongous_allocation,
75
76 _last_ditch_collection,
77 _last_gc_cause
78 };
79
80 inline static bool is_system_gc(GCCause::Cause cause) {
81 return (cause == GCCause::_java_lang_system_gc);
82 }
83
84 inline static bool is_user_requested_gc(GCCause::Cause cause) {
85 return (cause == GCCause::_java_lang_system_gc ||
86 cause == GCCause::_jvmti_force_gc);
87 }
88
89 inline static bool is_serviceability_requested_gc(GCCause::Cause
90 cause) {
91 return (cause == GCCause::_jvmti_force_gc ||
92 cause == GCCause::_heap_inspection ||
93 cause == GCCause::_heap_dump);
94 }
95
96 inline static bool is_tenured_allocation_failure_gc(GCCause::Cause cause) {
97 assert(cause != GCCause::_old_generation_too_full_to_scavenge &&
98 cause != GCCause::_old_generation_expanded_on_last_scavenge,
99 err_msg("This GCCause may be correct but is not expected yet: %s",
100 to_string(cause)));
101 return (cause == GCCause::_tenured_generation_full ||
102 cause == GCCause::_cms_generation_full ||
103 cause == GCCause::_adaptive_size_policy);
|