RFR: JDK-8295889: NMT preinit code does not handle allocation errors [v2]

Thomas Stuefe stuefe at openjdk.org
Wed Oct 26 05:45:33 UTC 2022


> The NMT preinit allocator (used for os::malloc and friends before the VM is initialized) does not handle malloc errors, nor does it handle overflows due to large sizes (it uses malloc headers too). Both cases need to be handled.
> 
> However, we can keep matters very simple. No need to propagate errors up to the caller; we can just fatal out on errors here since, in this phase, there is no alternative for failed allocations.

Thomas Stuefe has updated the pull request incrementally with one additional commit since the last revision:

  assert overflows (debug+release)

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

Changes:
  - all: https://git.openjdk.org/jdk/pull/10855/files
  - new: https://git.openjdk.org/jdk/pull/10855/files/76d9d5ba..ac9c3365

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jdk&pr=10855&range=01
 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=10855&range=00-01

  Stats: 6 lines in 1 file changed: 0 ins; 4 del; 2 mod
  Patch: https://git.openjdk.org/jdk/pull/10855.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/10855/head:pull/10855

PR: https://git.openjdk.org/jdk/pull/10855


More information about the hotspot-runtime-dev mailing list