RFR: 8357662: applications/runthese/RunThese8H.java Crash: 'Failed to uncommit metaspace'

Stefan Karlsson stefank at openjdk.org
Wed Jun 11 09:11:30 UTC 2025


On Tue, 10 Jun 2025 12:25:01 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

> Make the fatal error a log warning and return. The metaspace commit accounting is done after this return.  Tested with this always returning here, and it seems okay.  Tested with this change tier 1-4 and 8.

I'm not sure this is safe.

Could you explain how you come to the conclusion that failing to uncommit shouldn't be considered fatal? If the failure mode really is that we failed to split the memory mapping then I don't think we can be sure that the OS left the memory reservation the way the JVM has book keeped it. In other situations like this we have found that this could lead to other threads allocating into memory that another sub-system thinks that it has reserved (and owns), which can lead to various memory corruption issues.

-------------

PR Comment: https://git.openjdk.org/jdk/pull/25720#issuecomment-2961842406


More information about the hotspot-runtime-dev mailing list