RFR: 8353264: ZGC: Windows heap unreserving is broken
Stefan Karlsson
stefank at openjdk.org
Wed Apr 2 20:16:58 UTC 2025
On Wed, 2 Apr 2025 16:13:30 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
> > > Okay.
>
> > > Curious, was this a day zero problem?
>
> > I think it was. For completeness, this is the unreserve paths you need to hit to hit this bug:
>
> Ah okay, this is probably rare. I wondered whether it affects the unmapper path.
The unmapper converts the mapped memory (virtual to the physical memory) to be just reserved memory (but using Window's placeholder mechanism). So, the memory is not unreserved by the unmapper. I hope this makes sense.
> Because AFAIU, that would have led to out-of-address space at some point with high probability.
If you try to call this faulty unreserve implementation then the JVM will immediately shut down. So, I don't think this bug will cause and address-space leak.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/24377#issuecomment-2773620289
More information about the hotspot-gc-dev
mailing list