RFR (S): 8239070: Memory leak when unsuccessfully mapping in archive regions
jianglizhou at google.com
Fri Feb 14 17:15:23 UTC 2020
Thanks for finding the memory leak. The leak fix probably should be
applied to JDK 11 as well (as a modified backport). I'll try to
Ioi's suggestion of refactoring region mapping code into a
FileMapInfo::map_heap_data_impl sounds okay to me.
On Fri, Feb 14, 2020 at 7:09 AM Thomas Schatzl
<thomas.schatzl at oracle.com> wrote:
> Hi all,
> can I have reviews for this change that plugs a (tiny) memory leak
> when we unsuccessfully map CDS archives into the Java heap?
> The FileMapInfo::map_heap_data() method allocates some array of
> MemRegions, and in case we fail to map the archive, we return that
> method without assigning it to something or deallocating that memory.
> Found while working on JDK-8238999, also out for review, and depending
> on it.
More information about the hotspot-gc-dev