From 06d37a2754e5ce19d9189634e53ad90b1729a8a0 Mon Sep 17 00:00:00 2001
From: Aleksey Shipilev <shade@openjdk.org>
Date: Thu, 24 Oct 2019 11:49:56 +0200
Subject: [PATCH] 8232908: Shenandoah: compact heuristics has incorrect trigger
 "Free is lower than allocated recently"

Reviewed-by: rkennke
---
 .../shenandoah/heuristics/shenandoahCompactHeuristics.cpp  | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/src/hotspot/share/gc/shenandoah/heuristics/shenandoahCompactHeuristics.cpp b/src/hotspot/share/gc/shenandoah/heuristics/shenandoahCompactHeuristics.cpp
index ece6827c99e..7cedfcb820d 100644
--- a/src/hotspot/share/gc/shenandoah/heuristics/shenandoahCompactHeuristics.cpp
+++ b/src/hotspot/share/gc/shenandoah/heuristics/shenandoahCompactHeuristics.cpp
@@ -65,13 +65,6 @@ bool ShenandoahCompactHeuristics::should_start_gc() const {
     return true;
   }
 
-  if (available < threshold_bytes_allocated) {
-    log_info(gc)("Trigger: Free (" SIZE_FORMAT "%s) is lower than allocated recently (" SIZE_FORMAT "%s)",
-                 byte_size_in_proper_unit(available),                 proper_unit_for_byte_size(available),
-                 byte_size_in_proper_unit(threshold_bytes_allocated), proper_unit_for_byte_size(threshold_bytes_allocated));
-    return true;
-  }
-
   size_t bytes_allocated = heap->bytes_allocated_since_gc_start();
   if (bytes_allocated > threshold_bytes_allocated) {
     log_info(gc)("Trigger: Allocated since last cycle (" SIZE_FORMAT "%s) is larger than allocation threshold (" SIZE_FORMAT "%s)",