JDK21/24 ZGC Generational Extra Performance Overhead

Jack Ling lsc1943 at gmail.com
Tue Aug 5 01:59:43 UTC 2025


Hello ZGC team,

Recently we planned to upgrade JDK

Our application is a Netty based gateway to route HTTP requests from ALB to
upstream application servers.

During the performance tests, we observed if using ZGC generational, it
will cause extra 10% CPU overhead and the overall capacity was decreased
10% -15% which was a huge degradation. Unfortunately the normal ZGC was
disabled in JDK 24.

Attached JDK 21 and JDK 24 gc logs under the same workload, we could
observe much more concurrent time cost when using ZGC generational.

Would you help to advise what's the cause for the extra overhead using ZGC
generational and how to optimize, thank you!

-- 
Best Regards!
Jack Ling
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/zgc-dev/attachments/20250805/5121e09d/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gclogs.zip
Type: application/zip
Size: 533748 bytes
Desc: not available
URL: <https://mail.openjdk.org/pipermail/zgc-dev/attachments/20250805/5121e09d/gclogs-0001.zip>


More information about the zgc-dev mailing list