RFR: 8304442: Allocate VirtualMemoryTracker into Arena

Johan Sjölen jsjolen at openjdk.org
Tue Mar 28 08:59:32 UTC 2023


On Mon, 27 Mar 2023 17:55:27 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

> These sorted regions are never deleted?

They are, via `VMT::remove_released_region`.

> src/hotspot/share/services/virtualMemoryTracker.cpp line 127:
> 
>> 125:     _committed_regions(VirtualMemoryTracker::_backing_arena) {
>> 126:     *this = rr;
>> 127: }
> 
> (preexisting) since you have a copy constructor, should you have a deleted operator=?

Yeah, I also thought it was weird that Rule-of-3 isn't obeyed here. Just at a glance, seems like the default destructor does the right thing (calling destructor for each member).

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

PR Comment: https://git.openjdk.org/jdk/pull/13190#issuecomment-1486471985
PR Review Comment: https://git.openjdk.org/jdk/pull/13190#discussion_r1150255012


More information about the hotspot-runtime-dev mailing list