Moving Forward with AHS for G1

Man Cao manc at google.com
Thu Apr 10 20:18:07 UTC 2025


Re Erik:

> Could you elaborate the concrete scenario you have in mind? What use case
do you have in mind where AHS is not enough, while external heap control is?

One example is a customized container environment that requires
non-standard approaches to read container memory usage and container memory
limit, i.e., the application cannot use standard cgroup's
memory.memsw.usage_in_bytes, memory.memsw.max_usage_in_bytes control
files. Instead,
the customized container could provide its own library for the application
to get container usage and limit.

Without CurrentMaxHeapSize or a high-precedence SoftMaxHeapSize, the JVM
has no way to use the container-provided library to get signals
for memory pressure. With such JVM flags, the application could use the
container-provided library to calculate a value for those JVM flags based
on memory pressure, and pass that information to the JVM.

-Man
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/hotspot-gc-dev/attachments/20250410/4c37cc39/attachment.htm>


More information about the hotspot-gc-dev mailing list