From 3f21c8bd1f0cd7f27df940505b249ba7798940cf Mon Sep 17 00:00:00 2001 From: Axel Boldt-Christmas Date: Thu, 31 Jul 2025 13:08:29 +0000 Subject: [PATCH] 8361897: gc/z/TestUncommit.java fails with Uncommitted too slow Reviewed-by: stefank, jsikstro --- test/hotspot/jtreg/gc/z/TestUncommit.java | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/hotspot/jtreg/gc/z/TestUncommit.java b/test/hotspot/jtreg/gc/z/TestUncommit.java index 0ba4c55f22a..afb736501dd 100644 --- a/test/hotspot/jtreg/gc/z/TestUncommit.java +++ b/test/hotspot/jtreg/gc/z/TestUncommit.java @@ -108,7 +108,16 @@ public class TestUncommit { throw new Exception("Uncommitted too fast"); } + // In typical conditions (system not over-provisioned or slow), + // uncommitting is expected to complete within 3 * ZUncommitDelay after + // the last commit. To accommodate less ideal environments, only + // durations exceeding 5 * ZUncommitDelay are flagged as errors. + if (actualDelay > delay * 3) { + log(" *** Uncommit slower than expected. ***"); + } + + if (actualDelay > delay * 5) { throw new Exception("Uncommitted too slow"); }