Skip to content

Commit

Permalink
JDK-8336911
Browse files Browse the repository at this point in the history
  • Loading branch information
MBaesken committed Oct 2, 2024
1 parent 855c8a7 commit 5debdae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/hotspot/share/gc/z/zDirector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,8 @@ static double calculate_young_to_old_worker_ratio(const ZDirectorStats& stats) {
const size_t reclaimed_per_old_gc = stats._old_stats._stat_heap._reclaimed_avg;
const double current_young_bytes_freed_per_gc_time = double(reclaimed_per_young_gc) / double(young_gc_time);
const double current_old_bytes_freed_per_gc_time = double(reclaimed_per_old_gc) / double(old_gc_time);
const double old_vs_young_efficiency_ratio = current_old_bytes_freed_per_gc_time / current_young_bytes_freed_per_gc_time;
const double old_vs_young_efficiency_ratio = current_young_bytes_freed_per_gc_time == 0 ? std::numeric_limits<double>::infinity()
: current_old_bytes_freed_per_gc_time / current_young_bytes_freed_per_gc_time;

return old_vs_young_efficiency_ratio;
}
Expand Down

0 comments on commit 5debdae

Please sign in to comment.